Re: Why is my library linking to the wrong path?
| From: | Luke Scott | Date: | Wed, 11 Apr 2012 23:29:58 +0000 |
| Subject: | Re: Why is my library linking to the wrong path? | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-59764@lists.php.net to get a copy of this message | ||
> I'm using the line:
>
> PHP_ADD_LIBRARY_WITH_PATH(v8, $V8_DIR/$PHP_LIBDIR, V8PHP_SHARED_LIBADD)
>
> Where the path is /phpdev/lib. But my extension is actually linking to
> /v8/out/x64.release/libv8.dylib instead of /phpdev/lib/libv8.dylib even though
> /v8/out/x64.release no longer exists.
>
> What am I doing wrong?
>
> Luke
Was probably super obvious, but install_name_tool is how you fix the issue.
First use the "-id" parameter on the .dylib to fix the dylib. Then recompile
(or fix with -change flag).
Luke