The -install_name option is _already_ being specified by cmake
somewhere so when I tried your suggestion, I get an error during link
phase that the -install_name option is being specified twice.
Is there a master config file somewhere for cmake that I can just
edit? How else would cmake know to put in this option?
On Feb 8, 2006, at 9:47 AM, Brad King wrote:
mike jackson wrote:
I am building the official VTK 5.x release on OS X and I would
like to
add a custom link argument for all the generated libraries. I am
building dynamic libraries and I would like to set the "install-name"
of each library to "@executable_path/../Plugins" so I can include the
libs in my .app package. Normally I would set this in the Xcode build
settings but since I am using cmake I have no idea where to set that.
The link argument would normally be something like "-install_name
@executable_path/../Plugins/libvtkCommon.dylib"
The VTK CMake code provides an interface to allow some
customization of the build. Create a file Common/
LocalUserOptions.cmake in either the VTK build tree or the source
tree. Add this line:
SET_TARGET_PROPERTIES(vtkCommon PROPERTIES LINK_FLAGS
"-install_name @executable_path/../Plugins/libvtkCommon.dylib")
Re-run CMake on the build tree and then build again. The vtkCommon
library should be linked with this option. Then do the same for
the other kits.
-Brad
--------
Mike Jackson
imikejackson <at> gmail <dot> com
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake