aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorrenatofilho <renato.filho@openbossa.org>2010-09-21 15:46:39 -0300
committerrenatofilho <renato.filho@openbossa.org>2010-09-21 15:54:02 -0300
commitc41f0dc385335890cacdb830054e24d34acd0246 (patch)
tree9c596a6540bd9e76210631503ea310a3b9f2020a /CMakeLists.txt
parent4229fa0082135c889094c6cea7baa970b5208587 (diff)
The CMake configuration for PySide and Shiboken use the PYTHON_LIBRARIES
variable to link against Python. This is not the correct way to link against Python on OS X. Instead of specifying a library or the framework, one simply uses the flag "-undefined dynamic_lookup". The symbols will be resolved at runtime when the extension module loads. Fixes bug #352: Thanks to Robert Kern <robert.kern@gmail.com> Reviewer: Hugo Parente Lima <hugo.pl@gmail.com> Luciano Wolf <luciano.wolf@openbossa.org>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt4
1 files changed, 3 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5ba7022b..47ab784f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -169,7 +169,9 @@ if(CMAKE_BUILD_TYPE STREQUAL "Debug")
else()
set(PYSIDE_PYTHON_LIBRARIES ${PYTHON_LIBRARIES})
endif()
-
+if(APPLE)
+ set(PYSIDE_PYTHON_LIBRARIES "-undefined dynamic_lookup")
+endif()
set(GENERATOR_EXTRA_FLAGS --generatorSet=shiboken --enable-parent-ctor-heuristic --enable-pyside-extensions --enable-return-value-heuristic)