r24858 by craig - Update 1.7.0.svn dependencies. Require hunspell, deprecate Qt6,

scribus-commit scribus-commit at lists.scribus.net
Sun Jan 30 15:30:08 UTC 2022


Author: craig
Date: Sun Jan 30 15:30:08 2022
New Revision: 24858

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=24858
Log:
Update 1.7.0.svn dependencies. Require hunspell, deprecate Qt6,
deprecate Python 2

Modified:
    trunk/Scribus/CMakeLists_Dependencies.cmake

Modified: trunk/Scribus/CMakeLists_Dependencies.cmake
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24858&path=/trunk/Scribus/CMakeLists_Dependencies.cmake
==============================================================================
--- trunk/Scribus/CMakeLists_Dependencies.cmake	(original)
+++ trunk/Scribus/CMakeLists_Dependencies.cmake	Sun Jan 30 15:30:08 2022
@@ -2,116 +2,51 @@
 ########## Find Dependencies                                                                        ##########
 
 #<< Qt
-#Qt less than 6
 set(CMAKE_PREFIX_PATH "${QT_PREFIX}/lib/cmake")
 set(CMAKE_INCLUDE_CURRENT_DIR ON)
 
-if (NOT WANT_QT6)
-	message(STATUS "Qt5 Requested")
-	set(QT_MIN_VERSION "5.14.0")
-	add_compile_definitions(QT_DISABLE_DEPRECATED_BEFORE=0x050E00)
-	find_package(Qt5Core ${QT_MIN_VERSION} REQUIRED)
-	if(NOT Qt5Core_FOUND)
-		message(FATAL_ERROR "ERROR: No QT 5 found")
-	endif()
-	find_package(Qt5Widgets ${QT_MIN_VERSION} REQUIRED)
-	if(NOT Qt5Widgets_FOUND)
-		message(FATAL_ERROR "ERROR: No QT Widgets found")
-	endif()
-	find_package(Qt5Gui ${QT_MIN_VERSION} REQUIRED)
-	if(NOT Qt5Gui_FOUND)
-		message(FATAL_ERROR "ERROR: No Qt5Gui found")
-	endif()
-	find_package(Qt5Xml ${QT_MIN_VERSION} REQUIRED)
-	if(NOT Qt5Xml_FOUND)
-		message(FATAL_ERROR "ERROR: No QT 5 XML found")
-	endif()
-	find_package(Qt5Network ${QT_MIN_VERSION} REQUIRED)
-	if(NOT Qt5Network_FOUND)
-		message(FATAL_ERROR "ERROR: No Qt5Network found")
-	endif()
-	find_package(Qt5OpenGL ${QT_MIN_VERSION} REQUIRED)
-	if(NOT Qt5OpenGL_FOUND)
-		message(FATAL_ERROR "ERROR: No Qt5OpenGL found")
-	endif()
-	find_package(Qt5LinguistTools ${QT_MIN_VERSION} REQUIRED)
-	if(NOT Qt5LinguistTools_FOUND)
-		message(FATAL_ERROR "ERROR: No Qt5LinguistTools found")
-	endif()
-	#find_package(Qt5Quick ${QT_MIN_VERSION} REQUIRED)
-	#if(Qt5Quick_FOUND)
-	#    message(STATUS "----- USE Qt5Quick -----")
-	#else()
-	#    message(FATAL_ERROR "ERROR: No Qt5Quick found")
-	#endif()
-	find_package(Qt5PrintSupport ${QT_MIN_VERSION} REQUIRED)
-	if(NOT Qt5PrintSupport_FOUND)
-		message(FATAL_ERROR "ERROR: No Qt5PrintSupport found")
-	endif()
-	include_directories(${Qt5Core_INCLUDE_DIRS})
-	add_definitions(${Qt5Core_DEFINITIONS})
-	include_directories(${Qt5Widgets_INCLUDE_DIRS})
-	add_definitions(${Qt5Widgets_DEFINITIONS})
-	include_directories(${Qt5Gui_INCLUDE_DIRS})
-	add_definitions(${Qt5Gui_DEFINITIONS})
-	include_directories(${Qt5Xml_INCLUDE_DIRS})
-	add_definitions(${Qt5Xml_DEFINITIONS})
-	include_directories(${Qt5Network_INCLUDE_DIRS})
-	add_definitions(${Qt5Network_DEFINITIONS})
-	include_directories(${Qt5OpenGL_INCLUDE_DIRS})
-	add_definitions(${Qt5OpenGL_DEFINITIONS})
-	include_directories(${Qt5PrintSupport_INCLUDE_DIRS})
-	add_definitions(${Qt5PrintSupport_DEFINITIONS})
-
-	message(STATUS "Qt Version Found: ${Qt5Widgets_VERSION}")
-else()
-#WANT QT6
-    message(STATUS "Qt6 Requested")
-	set(QT_MIN_VERSION "6.2.0")
-
-	find_package(Qt6 COMPONENTS Core REQUIRED)
-	add_definitions(${Qt6Core_DEFINITIONS})
-	include_directories(${Qt6Core_INCLUDE_DIRS})
-
-	find_package(Qt6 COMPONENTS Core5Compat REQUIRED)
-	include_directories(${Qt6Core5Compat_INCLUDE_DIRS})
-	add_definitions(${Qt6Core5Compat_DEFINITIONS})
-
-	find_package(Qt6 COMPONENTS Gui REQUIRED)
-	include_directories(${Qt6Gui_INCLUDE_DIRS})
-	add_definitions(${Qt6Gui_DEFINITIONS})
-
-	find_package(Qt6 COMPONENTS Widgets REQUIRED)
-	include_directories(${Qt6Widgets_INCLUDE_DIRS})
-	add_definitions(${Qt6Widgets_DEFINITIONS})
-
-	find_package(Qt6 COMPONENTS Network REQUIRED)
-	include_directories(${Qt6Network_INCLUDE_DIRS})
-	add_definitions(${Qt6Network_DEFINITIONS})
-
-	find_package(Qt6 COMPONENTS OpenGL REQUIRED)
-	include_directories(${Qt6OpenGL_INCLUDE_DIRS})
-	add_definitions(${Qt6OpenGL_DEFINITIONS})
-
-	find_package(Qt6 COMPONENTS PrintSupport REQUIRED)
-	include_directories(${Qt6PrintSupport_INCLUDE_DIRS})
-	add_definitions(${Qt6PrintSupport_DEFINITIONS})
-
-	find_package(Qt6 COMPONENTS Xml REQUIRED)
-	include_directories(${Qt6Xml_INCLUDE_DIRS})
-	add_definitions(${Qt6Xml_DEFINITIONS})
-
-	find_package(Qt6 COMPONENTS LinguistTools REQUIRED)
-	include_directories(${Qt6LinguistTools_INCLUDE_DIRS})
-	add_definitions(${Qt6LinguistTools_DEFINITIONS})
-
-	message(STATUS "Qt Version Found: ${Qt6Widgets_VERSION}")
-endif()
-
-
-
-
-#<< ZLIB, PNG
+set(QT_MIN_VERSION "6.2.0")
+
+find_package(Qt6 COMPONENTS Core REQUIRED)
+add_definitions(${Qt6Core_DEFINITIONS})
+include_directories(${Qt6Core_INCLUDE_DIRS})
+
+find_package(Qt6 COMPONENTS Core5Compat REQUIRED)
+include_directories(${Qt6Core5Compat_INCLUDE_DIRS})
+add_definitions(${Qt6Core5Compat_DEFINITIONS})
+
+find_package(Qt6 COMPONENTS Gui REQUIRED)
+include_directories(${Qt6Gui_INCLUDE_DIRS})
+add_definitions(${Qt6Gui_DEFINITIONS})
+
+find_package(Qt6 COMPONENTS Widgets REQUIRED)
+include_directories(${Qt6Widgets_INCLUDE_DIRS})
+add_definitions(${Qt6Widgets_DEFINITIONS})
+
+find_package(Qt6 COMPONENTS Network REQUIRED)
+include_directories(${Qt6Network_INCLUDE_DIRS})
+add_definitions(${Qt6Network_DEFINITIONS})
+
+find_package(Qt6 COMPONENTS OpenGL REQUIRED)
+include_directories(${Qt6OpenGL_INCLUDE_DIRS})
+add_definitions(${Qt6OpenGL_DEFINITIONS})
+
+find_package(Qt6 COMPONENTS PrintSupport REQUIRED)
+include_directories(${Qt6PrintSupport_INCLUDE_DIRS})
+add_definitions(${Qt6PrintSupport_DEFINITIONS})
+
+find_package(Qt6 COMPONENTS Xml REQUIRED)
+include_directories(${Qt6Xml_INCLUDE_DIRS})
+add_definitions(${Qt6Xml_DEFINITIONS})
+
+find_package(Qt6 COMPONENTS LinguistTools REQUIRED)
+include_directories(${Qt6LinguistTools_INCLUDE_DIRS})
+add_definitions(${Qt6LinguistTools_DEFINITIONS})
+
+message(STATUS "Qt Version Found: ${Qt6Widgets_VERSION}")
+
+
+#<<PNG
 if (WIN32)
 	# On win32 we can use Qt's zlib and libpng, so we use some
 	# custom cmake includes. This permits us to honour the
@@ -119,16 +54,14 @@
 	set(PNG_DIR ${CMAKE_MODULE_PATH})
 	set(ZLIB_DIR ${CMAKE_MODULE_PATH})
 endif()
+#>> PNG
+#<< ZLIB
 find_package(ZLIB REQUIRED)
 if (ZLIB_FOUND)
 	message("ZLIB Library Found OK")
 	set(HAVE_LIBZ ON)
 endif()
-#find_package(PNG REQUIRED)
-#if (PNG_FOUND)
-#	message("PNG Library Found OK")
-#endif()
-#>> ZLIB, PNG
+#>> ZLIB
 
 if (WANT_NOOSG)
 	message("Building without 3D Extension")
@@ -166,28 +99,15 @@
 #<< JPEG, TIFF
 
 #<< PYTHON
-if (NOT WANT_PYTHON_2X)
-	message("Python 3.x Selected")
-	find_package (Python3 REQUIRED COMPONENTS Interpreter Development)
-	if (Python3_Development_FOUND)
-		message("Python 3.x Library Found OK (Version ${Python3_VERSION})")
-		message("Interpreter: ${Python3_EXECUTABLE}")
-		message("Include directories: ${Python3_INCLUDE_DIRS}")
-		message("Library directories: ${Python3_LIBRARY_DIRS}")
-		message("Runtime library directories: ${Python3_RUNTIME_LIBRARY_DIRS}")
-		set(HAVE_PYTHON ON)
-	endif()
-else()
-	message("Python 2.x Requested")
-	find_package (Python2 REQUIRED COMPONENTS Interpreter Development)
-	if (Python2_Development_FOUND)
-		message("Python 2.x Library Found OK (Version ${Python2_VERSION})")
-		message("Interpreter: ${Python2_EXECUTABLE}")
-		message("Include directories: ${Python2_INCLUDE_DIRS}")
-		message("Library directories: ${Python2_LIBRARY_DIRS}")
-		message("Runtime library directories: ${Python2_RUNTIME_LIBRARY_DIRS}")
-		set(HAVE_PYTHON ON)
-	endif()
+message("Python 3.x Selected")
+find_package (Python3 REQUIRED COMPONENTS Interpreter Development)
+if (Python3_Development_FOUND)
+	message("Python 3.x Library Found OK (Version ${Python3_VERSION})")
+	message("Interpreter: ${Python3_EXECUTABLE}")
+	message("Include directories: ${Python3_INCLUDE_DIRS}")
+	message("Library directories: ${Python3_LIBRARY_DIRS}")
+	message("Runtime library directories: ${Python3_RUNTIME_LIBRARY_DIRS}")
+	set(HAVE_PYTHON ON)
 endif()
 #>> PYTHON
 
@@ -253,15 +173,12 @@
 #>>FontConfig
 
 #<<HUNSPELL for Spelling support
-option(WANT_HUNSPELL "Enable support for spell checking with hunspell" ON)
-if (WANT_HUNSPELL)
-	find_package(hunspell)
-	if (hunspell_FOUND)
-		message("hunspell Found OK")
-		set(HAVE_HUNSPELL ON)
-	else()
-		message("hunspell or its developer libraries NOT found - Disabling support for spell checking")
-	endif()
+find_package(hunspell REQUIRED)
+if (hunspell_FOUND)
+	message("hunspell Found OK")
+	set(HAVE_HUNSPELL ON)
+else()
+	message("hunspell or its developer libraries NOT found - Disabling support for spell checking")
 endif()
 #>>HUNSPELL for Spelling support
 




More information about the scribus-commit mailing list