aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorHugo Parente Lima <hugo.lima@openbossa.org>2010-06-17 17:25:00 -0300
committerHugo Parente Lima <hugo.lima@openbossa.org>2010-06-17 19:53:20 -0300
commit33f7ff2b4d26cede665a087178ca444c6d0894dd (patch)
tree0cdd5e915d098d299e14e08782e5d1607be35706 /CMakeLists.txt
parente34105a7499fe1c2edd6fbee6dc2acb3993f5827 (diff)
Fix bug#242 - "PySide is installed into wrong path on Mac OS X"
If the cmake variable SITE_PACKAGE is set, we wont try to detect the SITE_PACKAGES variable. Reviewed: Marcelo Lira <marcelo.lira@openbossa.org> Luciano Wolf <luciano.wolf@openbossa.org>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt16
1 files changed, 10 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4b26d1c89..d0461bf30 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -113,13 +113,17 @@ add_custom_target(dist
echo "Source package created at ${CMAKE_BINARY_DIR}/${ARCHIVE_NAME}.tar.bz2.\n"
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})
-execute_process(
- COMMAND ${PYTHON_EXECUTABLE} -c "from distutils import sysconfig; \\
- print sysconfig.get_python_lib(1,0,prefix='${CMAKE_INSTALL_PREFIX}')"
- OUTPUT_VARIABLE SITE_PACKAGE
- OUTPUT_STRIP_TRAILING_WHITESPACE)
if (NOT SITE_PACKAGE)
- message(FATAL_ERROR "Could not detect Python module installation directory.")
+ execute_process(
+ COMMAND ${PYTHON_EXECUTABLE} -c "from distutils import sysconfig; \\
+ print sysconfig.get_python_lib(1,0,prefix='${CMAKE_INSTALL_PREFIX}')"
+ OUTPUT_VARIABLE SITE_PACKAGE
+ OUTPUT_STRIP_TRAILING_WHITESPACE)
+ if (NOT SITE_PACKAGE)
+ message(FATAL_ERROR "Could not detect Python module installation directory.")
+ elseif (APPLE)
+ message(STATUS "!!! The generated bindings will be installed on ${SITE_PACKAGE}, is it right!?")
+ endif()
endif()
set(GENERATOR_EXTRA_FLAGS --generatorSet=shiboken --enable-parent-ctor-heuristic --enable-pyside-extensions --enable-return-value-heuristic)