On Sunday, August 23, 2015 04:46:17 AM Oleg Zhylin via CMake wrote:
> Hi All,
> I still need help with 0015708: Use CMAKE_MACOSX_RPATH to link a library
> outside build tree - MantisBT. Could you please suggest are there any CMake
> mechanisms to ensure a library outside build tree on mac is linked with
> either @rpath and using hard-coded path on build machine? Either option
> would actually help. 
> |   |
> |   |   |   |   |   |
> | 0015708: Use CMAKE_MACOSX_RPATH to link a library outside build tree -
> | MantisBTThis issue is Mac OS X specific. I would like to link a library
> | lib_xxx that sits outside my build tree at some arbitrary location. It
> | will be at the same location in all systems.  |
> | 
> | View on www.cmake.org | Preview by Yahoo |
> | 
> |   |
> 
>  WBR ovz

There is no CMake mechanism to control references when linking with external 
libraries.  If you still want to do this, you'll need to edit the references 
in your binaries after linking.


You'll be much better off if you modify the external libraries.

For @rpath, use a command like this:
<install_name_tool -id @rpath/libwupienginemac.dylib 
/path/to/libwupienginemac.dylib>

or

For absolute path
<install_name_tool -id /path/to/libwupienginemac.dylib 
/path/to/libwupienginemac.dylib>

If those external libraries have additional dependencies using 
@executable_path, you may also need to use "install_name_tool -change ..."

Clint
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Reply via email to