Skip to content

Commit

Permalink
Remove INSTALL_NAME_DIR target property
Browse files Browse the repository at this point in the history
Using INSTALL_NAME_DIR target property forces the install name to be an
absolute path instead of `@rpath/{target_name}` [1]. This causes problems
when one tries to relocate the target once it is installed.
This patch removes this target property. If a project needs to keep
the absolute path, CMake variables such as INSTALL_NAME_DIR can be set at
configuration to do so.

[1] https://gitlab.kitware.com/cmake/cmake/issues/16589
  • Loading branch information
Francois Budin authored and jcfr committed Sep 21, 2017
1 parent 8462a54 commit fa7c647
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -309,14 +309,6 @@ add_library(PythonQt SHARED
)
set_target_properties(PythonQt PROPERTIES DEFINE_SYMBOL PYTHONQT_EXPORTS)

#
# That should solve linkage error on Mac when the project is used in a superbuild setup
# See http://blog.onesadcookie.com/2008/01/installname-magic.html
#
set_target_properties(PythonQt PROPERTIES
INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib"
)

target_compile_options(PythonQt PRIVATE
$<$<CXX_COMPILER_ID:MSVC>:/bigobj>
)
Expand Down

0 comments on commit fa7c647

Please sign in to comment.