r17954 by jghali - fix python 2.x detection when 2.x and 3.x are installed side-by-side + lcms2 includes being incorrectly picked up in some situations

scribus-commit scribus-commit at lists.scribus.net
Tue Dec 11 20:37:49 UTC 2012


Author: jghali
Date: Tue Dec 11 20:37:49 2012
New Revision: 17954

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=17954
Log:
fix python 2.x detection when 2.x and 3.x are installed side-by-side + lcms2 includes being incorrectly picked up in some situations

Modified:
    trunk/Scribus/CMakeLists.txt
    trunk/Scribus/scribus/colormgmt/CMakeLists.txt

Modified: trunk/Scribus/CMakeLists.txt
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17954&path=/trunk/Scribus/CMakeLists.txt
==============================================================================
--- trunk/Scribus/CMakeLists.txt (original)
+++ trunk/Scribus/CMakeLists.txt Tue Dec 11 20:37:49 2012
@@ -529,7 +529,7 @@
   ENDIF(OSG_FOUND)
 ENDIF (WANT_NOOSG)
 
-#<< JPEG, TIFF, PYTHON
+#<< JPEG, TIFF
 FIND_PACKAGE(JPEG REQUIRED)
 IF (JPEG_FOUND)
   MESSAGE("JPEG Library Found OK")
@@ -541,13 +541,17 @@
 ELSE(TIFF_FOUND)
   MESSAGE(FATAL_ERROR "Could not find the TIFF Library")
 ENDIF(TIFF_FOUND)
+#<< JPEG, TIFF
+
+#<< PYTHON
+SET(PythonLibs_FIND_VERSION 2)
 FIND_PACKAGE(PythonLibs REQUIRED)
 IF (PYTHON_LIBRARY)
   MESSAGE("Python Library Found OK")
   SET(HAVE_PYTHON 1)
   SET(COMPILE_PYTHON 1)
 ENDIF(PYTHON_LIBRARY)
-#>> JPEG, TIFF, PYTHON
+#>> PYTHON
 
 #<< FreeType2
 IF (${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} LESS 2.6)
@@ -832,7 +836,6 @@
   ${FREETYPE_INCLUDE_DIR}
   ${FONTCONFIG_INCLUDE_DIR}
   ${JPEG_INCLUDE_DIR}
-  ${LCMS_INCLUDE_DIR}
   ${LIBXML2_INCLUDE_DIR}
   ${TIFF_INCLUDE_DIR}
   ${ZLIB_INCLUDE_DIR}
@@ -840,6 +843,12 @@
   ${OSG_INCLUDE_DIR}
   ${GSL_INCLUDE_DIR}
 )
+
+IF (LCMS2_FOUND)
+  INCLUDE_DIRECTORIES( ${LCMS2_INCLUDE_DIR} )
+ELSE (LCMS2_FOUND)
+  INCLUDE_DIRECTORIES( ${LCMS_INCLUDE_DIR} )
+ENDIF (LCMS2_FOUND)
 
 ##############################################################################################################
 ########## Uninstall Setup                                                                          ##########

Modified: trunk/Scribus/scribus/colormgmt/CMakeLists.txt
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17954&path=/trunk/Scribus/scribus/colormgmt/CMakeLists.txt
==============================================================================
--- trunk/Scribus/scribus/colormgmt/CMakeLists.txt (original)
+++ trunk/Scribus/scribus/colormgmt/CMakeLists.txt Tue Dec 11 20:37:49 2012
@@ -1,16 +1,17 @@
 INCLUDE_DIRECTORIES(
 ${CMAKE_SOURCE_DIR}
 ${CMAKE_SOURCE_DIR}/scribus
-${LCMS_INCLUDE_DIR}
 )
 
 IF(HAVE_LCMS2)
+	INCLUDE_DIRECTORIES( ${LCMS2_INCLUDE_DIR} )
 	SET(SCRIBUS_LCMS_IMPL_SOURCES
 		sclcms2colormgmtengineimpl.cpp
 		sclcms2colorprofileimpl.cpp
 		sclcms2colortransformimpl.cpp
 	)
 ELSE(HAVE_LCMS2)
+	INCLUDE_DIRECTORIES( ${LCMS_INCLUDE_DIR} )
 	SET(SCRIBUS_LCMS_IMPL_SOURCES
 		sclcmscolormgmtengineimpl.cpp
 		sclcmscolorprofileimpl.cpp




More information about the scribus-commit mailing list