Install python modules at the right places.

This commit is contained in:
Jean-Paul Chaput 2010-05-22 22:15:47 +00:00
parent f64001a35d
commit 1407845847
2 changed files with 20 additions and 1 deletions

View File

@ -11,6 +11,24 @@ SET(CMAKE_CXX_FLAGS_DEBUG "-g -Wall" CACHE STRING "Debug options." FORCE)
SET(CMAKE_C_FLAGS_RELEASE "-O3 -DNDEBUG -Wall" CACHE STRING "Release options." FORCE)
SET(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG -Wall" CACHE STRING "Release options." FORCE)
MACRO(SETUP_PROJECT_PATHS project)
IF( NOT("$ENV{${project}_TOP}" STREQUAL "") )
MESSAGE("-- ${project}_TOP is set to $ENV{${project}_TOP}")
SET(PROJECT_MODULE_PATH "${DESTDIR}$ENV{${project}_TOP}/share/cmake/Modules/")
LIST(INSERT CMAKE_MODULE_PATH 0 "${PROJECT_MODULE_PATH}")
ENDIF( NOT("$ENV{${project}_TOP}" STREQUAL "") )
IF( NOT("$ENV{${project}_USER_TOP}" STREQUAL "") )
MESSAGE("-- ${project}_USER_TOP is set to $ENV{${project}_USER_TOP}")
SET(PROJECT_MODULE_PATH "${DESTDIR}$ENV{${project}_USER_TOP}/share/cmake/Modules/")
LIST(INSERT CMAKE_MODULE_PATH 0 "${PROJECT_MODULE_PATH}")
ENDIF( NOT("$ENV{${project}_USER_TOP}" STREQUAL "") )
LIST(REMOVE_DUPLICATES CMAKE_MODULE_PATH)
ENDMACRO(SETUP_PROJECT_PATHS project)
SETUP_PROJECT_PATHS(VLSISAPD)
LIST(INSERT CMAKE_MODULE_PATH 0 "${HURRICANE_SOURCE_DIR}/cmake_modules/")
OPTION(BUILD_DOC "Build the documentation (doxygen)" OFF)
@ -35,6 +53,7 @@ FIND_PACKAGE(BISON REQUIRED)
FIND_PACKAGE(FLEX REQUIRED)
FIND_PACKAGE(Boost 1.33.1 COMPONENTS regex REQUIRED)
FIND_PACKAGE(PythonLibs REQUIRED)
FIND_PACKAGE(PythonSitePackages REQUIRED)
IF(BUILD_DOC)
FIND_PACKAGE(Doxygen)
ENDIF(BUILD_DOC)

View File

@ -93,4 +93,4 @@
target_link_libraries ( Hurricane isobar hurricane ${PYTHON_LIBRARIES} )
install ( TARGETS isobar DESTINATION lib${LIB_SUFFIX} )
install ( TARGETS Hurricane DESTINATION lib${LIB_SUFFIX}/python )
install ( TARGETS Hurricane DESTINATION ${PYTHON_SITE_PACKAGES} )