X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=gdcmPython%2FCMakeLists.txt;h=c54b80a88817a5edbc8e3a3067861815653e6a4b;hb=c4e7cd167fff93d40374a4cd88dbeab78797127f;hp=ba6957394782755a5969540ee17088996ffde128;hpb=def46e1406409aebffa69097d83d7e1730352497;p=gdcm.git diff --git a/gdcmPython/CMakeLists.txt b/gdcmPython/CMakeLists.txt index ba695739..c54b80a8 100644 --- a/gdcmPython/CMakeLists.txt +++ b/gdcmPython/CMakeLists.txt @@ -2,6 +2,7 @@ INCLUDE_DIRECTORIES( ${GDCM_SOURCE_DIR}/src + ${GDCM_SOURCE_DIR}/gdcmPython ${PYTHON_INCLUDE_PATH} ${GDCM_BINARY_DIR}/ ) @@ -28,6 +29,11 @@ SET_SOURCE_FILES_PROPERTIES(gdcm.i PROPERTIES CPLUSPLUS ON) # BUG: This is only needed with cmake <= 2.0.5 SET_SOURCE_FILES_PROPERTIES(gdcm.i PROPERTIES SWIG_FLAGS "") # END OF BUG +#FIXME : +#where must we put the keyword SHARED +#- just like in ADD_LIBRARY(vtkgdcmPython SHARED ${gdcmWrapSOURCES}) - +#to allow use of a static/shared libray ? +# JPRx SWIG_ADD_MODULE(gdcm python gdcm.i) #gdcm_wrap.cxx, or gdcmPYTHON_wrap.cxx SWIG_LINK_LIBRARIES(gdcm gdcm ${PYTHON_LIBRARIES}) @@ -125,10 +131,17 @@ IF(WIN32) "${GDCM_BINARY_DIR}\n" "${GDCM_BINARY_DIR}/bin/release\n" ) + FILE(WRITE ${GDCM_BINARY_DIR}/gdcmPython/InstallOnly/gdcmPython.pth + "${GDCM_SOURCE_DIR}\n" + "${GDCM_SOURCE_DIR}/bin\n" + ) ELSE(WIN32) FILE(WRITE ${GDCM_BINARY_DIR}/gdcmPython/gdcmPython.pth "${CMAKE_INSTALL_PREFIX}/lib/gdcm\n" ) + FILE(WRITE ${GDCM_BINARY_DIR}/gdcmPython/InstallOnly/gdcmPython.pth + "/usr/lib/gdcm\n" + ) ENDIF(WIN32) # Install a python path file in site-packages that tells @@ -143,7 +156,7 @@ IF(UNIX) STRING(REGEX REPLACE "/usr" "" PYTHON_DIR ${PYTHON_DIR}) INSTALL_FILES(${PYTHON_DIR}/site-packages FILES - "${GDCM_BINARY_DIR}/gdcmPython/gdcmPython.pth" + "${GDCM_BINARY_DIR}/gdcmPython/InstallOnly/gdcmPython.pth" ) INSTALL_FILES(/lib/gdcm/gdcmPython FILES "gdcm.py"