qtbase: unify Linux and Darwin patchsets

This commit is contained in:
Thomas Tuegel 2017-04-17 08:04:19 -05:00
parent 4bd911dcd6
commit 0d0858202c
No known key found for this signature in database
GPG Key ID: 22CBF5249D4B4D59
4 changed files with 103 additions and 500 deletions

View File

@ -1,384 +0,0 @@
Index: qtbase-opensource-src-5.8.0/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
===================================================================
--- qtbase-opensource-src-5.8.0.orig/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
+++ qtbase-opensource-src-5.8.0/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
@@ -9,30 +9,6 @@ if (CMAKE_VERSION VERSION_LESS 3.0.0)
endif()
!!ENDIF
-!!IF !isEmpty(CMAKE_USR_MOVE_WORKAROUND)
-!!IF !isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
-set(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"$$[QT_INSTALL_PREFIX]\")
-!!ELSE
-get_filename_component(_IMPORT_PREFIX \"${CMAKE_CURRENT_LIST_FILE}\" PATH)
-# Use original install prefix when loaded through a
-# cross-prefix symbolic link such as /lib -> /usr/lib.
-get_filename_component(_realCurr \"${_IMPORT_PREFIX}\" REALPATH)
-get_filename_component(_realOrig \"$$CMAKE_INSTALL_LIBS_DIR/cmake/Qt5$${CMAKE_MODULE_NAME}\" REALPATH)
-if(_realCurr STREQUAL _realOrig)
- get_filename_component(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"$$CMAKE_INSTALL_LIBS_DIR/$${CMAKE_RELATIVE_INSTALL_LIBS_DIR}\" ABSOLUTE)
-else()
- get_filename_component(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"${CMAKE_CURRENT_LIST_DIR}/$${CMAKE_RELATIVE_INSTALL_DIR}\" ABSOLUTE)
-endif()
-unset(_realOrig)
-unset(_realCurr)
-unset(_IMPORT_PREFIX)
-!!ENDIF
-!!ELIF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
-get_filename_component(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"${CMAKE_CURRENT_LIST_DIR}/$${CMAKE_RELATIVE_INSTALL_DIR}\" ABSOLUTE)
-!!ELSE
-set(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"$$[QT_INSTALL_PREFIX]\")
-!!ENDIF
-
!!IF !equals(TEMPLATE, aux)
# For backwards compatibility only. Use Qt5$${CMAKE_MODULE_NAME}_VERSION instead.
set(Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING "$$eval(QT.$${MODULE}.MAJOR_VERSION).$$eval(QT.$${MODULE}.MINOR_VERSION).$$eval(QT.$${MODULE}.PATCH_VERSION)")
@@ -59,7 +35,10 @@ macro(_populate_$${CMAKE_MODULE_NAME}_ta
set_property(TARGET Qt5::$${CMAKE_MODULE_NAME} APPEND PROPERTY IMPORTED_CONFIGURATIONS ${Configuration})
!!IF isEmpty(CMAKE_DLL_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
+ set(imported_location \"@NIX_OUT@/$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
+ if(NOT EXISTS \"${imported_location}\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
+ endif()
!!ELSE
set(imported_location \"$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
!!ENDIF
@@ -74,45 +53,17 @@ macro(_populate_$${CMAKE_MODULE_NAME}_ta
\"IMPORTED_LINK_INTERFACE_LIBRARIES_${Configuration}\" \"${_Qt5$${CMAKE_MODULE_NAME}_LIB_DEPENDENCIES}\"
)
-!!IF !isEmpty(CMAKE_WINDOWS_BUILD)
-!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- set(imported_implib \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
-!!ELSE
- set(imported_implib \"IMPORTED_IMPLIB_${Configuration}\" \"$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
-!!ENDIF
- _qt5_$${CMAKE_MODULE_NAME}_check_file_exists(${imported_implib})
- if(NOT \"${IMPLIB_LOCATION}\" STREQUAL \"\")
- set_target_properties(Qt5::$${CMAKE_MODULE_NAME} PROPERTIES
- \"IMPORTED_IMPLIB_${Configuration}\" ${imported_implib}
- )
- endif()
-!!ENDIF
endmacro()
!!ENDIF
if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
!!IF !no_module_headers
-!!IF !isEmpty(CMAKE_BUILD_IS_FRAMEWORK)
- set(_Qt5$${CMAKE_MODULE_NAME}_OWN_INCLUDE_DIRS
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework\"
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Headers\"
- )
-!!IF isEmpty(CMAKE_NO_PRIVATE_INCLUDES)
- set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Versions/$$section(VERSION, ., 0, 0)/Headers/$$VERSION/\"
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Versions/$$section(VERSION, ., 0, 0)/Headers/$$VERSION/$${MODULE_INCNAME}\"
- )
-!!ELSE
- set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS \"\")
-!!ENDIF
-!!ELSE
!!IF isEmpty(CMAKE_INCLUDE_DIR_IS_ABSOLUTE)
- set(_Qt5$${CMAKE_MODULE_NAME}_OWN_INCLUDE_DIRS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$$CMAKE_INCLUDE_DIR\" \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}\")
+ set(_Qt5$${CMAKE_MODULE_NAME}_OWN_INCLUDE_DIRS \"@NIX_OUT@/lib\" \"@NIX_OUT@/lib/$${MODULE_INCNAME}.framework/Headers\")
!!IF isEmpty(CMAKE_NO_PRIVATE_INCLUDES)
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}/$$VERSION\"
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}/$$VERSION/$${MODULE_INCNAME}\"
+ \"\"
)
!!ELSE
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS \"\")
@@ -128,7 +80,7 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS \"\")
!!ENDIF
!!ENDIF
-!!ENDIF
+
!!IF !isEmpty(CMAKE_ADD_SOURCE_INCLUDE_DIRS)
include(\"${CMAKE_CURRENT_LIST_DIR}/ExtraSourceIncludes.cmake\" OPTIONAL)
!!ENDIF
@@ -253,28 +205,19 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!IF !isEmpty(CMAKE_FIND_OTHER_LIBRARY_BUILD)
!!IF isEmpty(CMAKE_DEBUG_TYPE)
-!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
-!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- if (EXISTS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
-!!ELSE // CMAKE_LIB_DIR_IS_ABSOLUTE
- if (EXISTS \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
-!!ENDIF // CMAKE_LIB_DIR_IS_ABSOLUTE
- _populate_$${CMAKE_MODULE_NAME}_target_properties(DEBUG \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" \"\" )
-!!ELSE // CMAKE_STATIC_WINDOWS_BUILD
if (EXISTS
!!IF isEmpty(CMAKE_DLL_DIR_IS_ABSOLUTE)
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_DLL_DIR}$${CMAKE_LIB_FILE_LOCATION_DEBUG}\"
+ \"@NIX_OUT@/$${CMAKE_DLL_DIR}$${CMAKE_LIB_FILE_LOCATION_DEBUG}\"
!!ELSE
\"$${CMAKE_LIB_FILE_LOCATION_DEBUG}\"
!!ENDIF
AND EXISTS
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
+ \"@NIX_DEV@/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
!!ELSE
\"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
!!ENDIF
_populate_$${CMAKE_MODULE_NAME}_target_properties(DEBUG \"$${CMAKE_LIB_FILE_LOCATION_DEBUG}\" \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
-!!ENDIF // CMAKE_STATIC_WINDOWS_BUILD
endif()
!!ENDIF // CMAKE_DEBUG_TYPE
!!ENDIF // CMAKE_FIND_OTHER_LIBRARY_BUILD
@@ -282,36 +225,23 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!ENDIF // CMAKE_RELEASE_TYPE
!!IF !isEmpty(CMAKE_DEBUG_TYPE)
-!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
- _populate_$${CMAKE_MODULE_NAME}_target_properties(DEBUG \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" \"\" )
-!!ELSE
_populate_$${CMAKE_MODULE_NAME}_target_properties(DEBUG \"$${CMAKE_LIB_FILE_LOCATION_DEBUG}\" \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
-!!ENDIF // CMAKE_STATIC_WINDOWS_BUILD
!!IF !isEmpty(CMAKE_FIND_OTHER_LIBRARY_BUILD)
!!IF isEmpty(CMAKE_RELEASE_TYPE)
-!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
-!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- if (EXISTS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
-!!ELSE // CMAKE_LIB_DIR_IS_ABSOLUTE
- if (EXISTS \"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
-!!ENDIF // CMAKE_LIB_DIR_IS_ABSOLUTE
- _populate_$${CMAKE_MODULE_NAME}_target_properties(RELEASE \"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" \"\" )
-!!ELSE // CMAKE_STATIC_WINDOWS_BUILD
if (EXISTS
!!IF isEmpty(CMAKE_DLL_DIR_IS_ABSOLUTE)
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_DLL_DIR}$${CMAKE_LIB_FILE_LOCATION_RELEASE}\"
+ \"@NIX_OUT@/$${CMAKE_DLL_DIR}$${CMAKE_LIB_FILE_LOCATION_RELEASE}\"
!!ELSE
\"$${CMAKE_LIB_FILE_LOCATION_RELEASE}\"
!!ENDIF
AND EXISTS
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
+ \"@NIX_DEV@/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
!!ELSE
\"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
!!ENDIF
_populate_$${CMAKE_MODULE_NAME}_target_properties(RELEASE \"$${CMAKE_LIB_FILE_LOCATION_RELEASE}\" \"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
-!!ENDIF // CMAKE_STATIC_WINDOWS_BUILD
endif()
!!ENDIF // CMAKE_RELEASE_TYPE
!!ENDIF // CMAKE_FIND_OTHER_LIBRARY_BUILD
@@ -328,11 +258,7 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
macro(_populate_$${CMAKE_MODULE_NAME}_plugin_properties Plugin Configuration PLUGIN_LOCATION)
set_property(TARGET Qt5::${Plugin} APPEND PROPERTY IMPORTED_CONFIGURATIONS ${Configuration})
-!!IF isEmpty(CMAKE_PLUGIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_PLUGIN_DIR}${PLUGIN_LOCATION}\")
-!!ELSE
- set(imported_location \"$${CMAKE_PLUGIN_DIR}${PLUGIN_LOCATION}\")
-!!ENDIF
+ set(imported_location \"${PLUGIN_LOCATION}\")
_qt5_$${CMAKE_MODULE_NAME}_check_file_exists(${imported_location})
set_target_properties(Qt5::${Plugin} PROPERTIES
\"IMPORTED_LOCATION_${Configuration}\" ${imported_location}
Index: qtbase-opensource-src-5.8.0/src/gui/Qt5GuiConfigExtras.cmake.in
===================================================================
--- qtbase-opensource-src-5.8.0.orig/src/gui/Qt5GuiConfigExtras.cmake.in
+++ qtbase-opensource-src-5.8.0/src/gui/Qt5GuiConfigExtras.cmake.in
@@ -2,7 +2,7 @@
!!IF !isEmpty(CMAKE_ANGLE_EGL_DLL_RELEASE)
!!IF isEmpty(CMAKE_INCLUDE_DIR_IS_ABSOLUTE)
-set(Qt5Gui_EGL_INCLUDE_DIRS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$$CMAKE_INCLUDE_DIR/QtANGLE\")
+set(Qt5Gui_EGL_INCLUDE_DIRS \"@NIX_DEV@/$$CMAKE_INCLUDE_DIR/QtANGLE\")
!!ELSE
set(Qt5Gui_EGL_INCLUDE_DIRS \"$$CMAKE_INCLUDE_DIR/QtANGLE\")
!!ENDIF
@@ -17,13 +17,13 @@ macro(_populate_qt5gui_gl_target_propert
set_property(TARGET Qt5::${TargetName} APPEND PROPERTY IMPORTED_CONFIGURATIONS ${Configuration})
!!IF isEmpty(CMAKE_DLL_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Gui_install_prefix}/$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
+ set(imported_location \"@NIX_OUT@/$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
!!ELSE
set(imported_location \"$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
!!ENDIF
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- set(imported_implib \"${_qt5Gui_install_prefix}/$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
+ set(imported_implib \"@NIX_DEV@/$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
!!ELSE
set(imported_implib \"$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
!!ENDIF
Index: qtbase-opensource-src-5.8.0/src/widgets/Qt5WidgetsConfigExtras.cmake.in
===================================================================
--- qtbase-opensource-src-5.8.0.orig/src/widgets/Qt5WidgetsConfigExtras.cmake.in
+++ qtbase-opensource-src-5.8.0/src/widgets/Qt5WidgetsConfigExtras.cmake.in
@@ -3,7 +3,7 @@ if (NOT TARGET Qt5::uic)
add_executable(Qt5::uic IMPORTED)
!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Widgets_install_prefix}/$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\")
!!ELSE
set(imported_location \"$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\")
!!ENDIF
Index: qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtras.cmake.in
===================================================================
--- qtbase-opensource-src-5.8.0.orig/src/corelib/Qt5CoreConfigExtras.cmake.in
+++ qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtras.cmake.in
@@ -3,7 +3,7 @@ if (NOT TARGET Qt5::qmake)
add_executable(Qt5::qmake IMPORTED)
!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\")
!!ELSE
set(imported_location \"$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\")
!!ENDIF
@@ -18,7 +18,7 @@ if (NOT TARGET Qt5::moc)
add_executable(Qt5::moc IMPORTED)
!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\")
!!ELSE
set(imported_location \"$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\")
!!ENDIF
@@ -35,7 +35,7 @@ if (NOT TARGET Qt5::rcc)
add_executable(Qt5::rcc IMPORTED)
!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\")
!!ELSE
set(imported_location \"$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\")
!!ENDIF
@@ -131,7 +131,7 @@ if (NOT TARGET Qt5::WinMain)
!!IF !isEmpty(CMAKE_RELEASE_TYPE)
set_property(TARGET Qt5::WinMain APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_RELEASE}\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_RELEASE}\")
!!ELSE
set(imported_location \"$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_RELEASE}\")
!!ENDIF
@@ -145,7 +145,7 @@ if (NOT TARGET Qt5::WinMain)
set_property(TARGET Qt5::WinMain APPEND PROPERTY IMPORTED_CONFIGURATIONS DEBUG)
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_DEBUG}\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_DEBUG}\")
!!ELSE
set(imported_location \"$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_DEBUG}\")
!!ENDIF
Index: qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
===================================================================
--- qtbase-opensource-src-5.8.0.orig/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
+++ qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
@@ -1,6 +1,6 @@
!!IF isEmpty(CMAKE_INSTALL_DATA_DIR_IS_ABSOLUTE)
-set(_qt5_corelib_extra_includes \"${_qt5Core_install_prefix}/$${CMAKE_INSTALL_DATA_DIR}/mkspecs/$${CMAKE_MKSPEC}\")
+set(_qt5_corelib_extra_includes \"@NIX_DEV@/$${CMAKE_INSTALL_DATA_DIR}/mkspecs/$${CMAKE_MKSPEC}\")
!!ELSE
set(_qt5_corelib_extra_includes \"$${CMAKE_INSTALL_DATA_DIR}mkspecs/$${CMAKE_MKSPEC}\")
!!ENDIF
Index: qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
===================================================================
--- qtbase-opensource-src-5.8.0.orig/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
+++ qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
@@ -1,6 +1,6 @@
!!IF isEmpty(CMAKE_HOST_DATA_DIR_IS_ABSOLUTE)
-set(_qt5_corelib_extra_includes \"${_qt5Core_install_prefix}/$${CMAKE_HOST_DATA_DIR}/mkspecs/$${CMAKE_MKSPEC}\")
+set(_qt5_corelib_extra_includes \"@NIX_DEV@/$${CMAKE_HOST_DATA_DIR}/mkspecs/$${CMAKE_MKSPEC}\")
!!ELSE
set(_qt5_corelib_extra_includes \"$${CMAKE_HOST_DATA_DIR}mkspecs/$${CMAKE_MKSPEC}\")
!!ENDIF
Index: qtbase-opensource-src-5.8.0/src/dbus/Qt5DBusConfigExtras.cmake.in
===================================================================
--- qtbase-opensource-src-5.8.0.orig/src/dbus/Qt5DBusConfigExtras.cmake.in
+++ qtbase-opensource-src-5.8.0/src/dbus/Qt5DBusConfigExtras.cmake.in
@@ -3,7 +3,7 @@ if (NOT TARGET Qt5::qdbuscpp2xml)
add_executable(Qt5::qdbuscpp2xml IMPORTED)
!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5DBus_install_prefix}/$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\")
!!ELSE
set(imported_location \"$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\")
!!ENDIF
@@ -18,7 +18,7 @@ if (NOT TARGET Qt5::qdbusxml2cpp)
add_executable(Qt5::qdbusxml2cpp IMPORTED)
!!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE)
- set(imported_location \"${_qt5DBus_install_prefix}/$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\")
+ set(imported_location \"@NIX_DEV@/$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\")
!!ELSE
set(imported_location \"$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\")
!!ENDIF
Index: qtbase-opensource-src-5.8.0/mkspecs/features/create_cmake.prf
===================================================================
--- qtbase-opensource-src-5.8.0.orig/mkspecs/features/create_cmake.prf
+++ qtbase-opensource-src-5.8.0/mkspecs/features/create_cmake.prf
@@ -136,28 +136,28 @@ contains(CONFIG, plugin) {
win32 {
isEmpty(CMAKE_STATIC_TYPE) {
- CMAKE_PLUGIN_LOCATION_RELEASE = $$PLUGIN_TYPE/$${TARGET}.dll
- CMAKE_PLUGIN_LOCATION_DEBUG = $$PLUGIN_TYPE/$${TARGET}d.dll
+ CMAKE_PLUGIN_LOCATION_RELEASE = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/$${TARGET}.dll
+ CMAKE_PLUGIN_LOCATION_DEBUG = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/$${TARGET}d.dll
} else:mingw {
- CMAKE_PLUGIN_LOCATION_RELEASE = $$PLUGIN_TYPE/lib$${TARGET}.a
- CMAKE_PLUGIN_LOCATION_DEBUG = $$PLUGIN_TYPE/lib$${TARGET}d.a
+ CMAKE_PLUGIN_LOCATION_RELEASE = $${CMAKE_PLUGIN_DIR}/$$PLUGIN_TYPE/lib$${TARGET}.a
+ CMAKE_PLUGIN_LOCATION_DEBUG = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/lib$${TARGET}d.a
} else { # MSVC static
- CMAKE_PLUGIN_LOCATION_RELEASE = $$PLUGIN_TYPE/$${TARGET}.lib
- CMAKE_PLUGIN_LOCATION_DEBUG = $$PLUGIN_TYPE/$${TARGET}d.lib
+ CMAKE_PLUGIN_LOCATION_RELEASE = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/$${TARGET}.lib
+ CMAKE_PLUGIN_LOCATION_DEBUG = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/$${TARGET}d.lib
}
} else {
mac {
isEmpty(CMAKE_STATIC_TYPE): CMAKE_PlUGIN_EXT = .dylib
else: CMAKE_PlUGIN_EXT = .a
- CMAKE_PLUGIN_LOCATION_RELEASE = $$PLUGIN_TYPE/lib$${TARGET}$${CMAKE_PlUGIN_EXT}
- CMAKE_PLUGIN_LOCATION_DEBUG = $$PLUGIN_TYPE/lib$${TARGET}$${CMAKE_PlUGIN_EXT}
+ CMAKE_PLUGIN_LOCATION_RELEASE = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/lib$${TARGET}$${CMAKE_PlUGIN_EXT}
+ CMAKE_PLUGIN_LOCATION_DEBUG = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/lib$${TARGET}$${CMAKE_PlUGIN_EXT}
} else {
isEmpty(CMAKE_STATIC_TYPE): CMAKE_PlUGIN_EXT = .so
else: CMAKE_PlUGIN_EXT = .a
- CMAKE_PLUGIN_LOCATION_RELEASE = $$PLUGIN_TYPE/lib$${TARGET}$${CMAKE_PlUGIN_EXT}
- CMAKE_PLUGIN_LOCATION_DEBUG = $$PLUGIN_TYPE/lib$${TARGET}$${CMAKE_PlUGIN_EXT}
+ CMAKE_PLUGIN_LOCATION_RELEASE = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/lib$${TARGET}$${CMAKE_PlUGIN_EXT}
+ CMAKE_PLUGIN_LOCATION_DEBUG = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/lib$${TARGET}$${CMAKE_PlUGIN_EXT}
}
}
cmake_target_file.input = $$PWD/data/cmake/Qt5PluginTarget.cmake.in
Index: qtbase-opensource-src-5.8.0/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
===================================================================
--- qtbase-opensource-src-5.8.0.orig/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
+++ qtbase-opensource-src-5.8.0/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
@@ -2,10 +2,10 @@
add_library(Qt5::$$CMAKE_PLUGIN_NAME MODULE IMPORTED)
!!IF !isEmpty(CMAKE_RELEASE_TYPE)
-_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME RELEASE \"$${CMAKE_PLUGIN_LOCATION_RELEASE}\")
+_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME RELEASE \"@NIX_OUT@/$${CMAKE_PLUGIN_LOCATION_RELEASE}\")
!!ENDIF
!!IF !isEmpty(CMAKE_DEBUG_TYPE)
-_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME DEBUG \"$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
+_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME DEBUG \"@NIX_OUT@/$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
!!ENDIF
list(APPEND Qt5$${CMAKE_MODULE_NAME}_PLUGINS Qt5::$$CMAKE_PLUGIN_NAME)

View File

@ -1,7 +1,7 @@
Index: qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
Index: qtbase-opensource-src-5.8.0/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
+++ qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
--- qtbase-opensource-src-5.8.0.orig/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
+++ qtbase-opensource-src-5.8.0/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
@@ -9,30 +9,6 @@ if (CMAKE_VERSION VERSION_LESS 3.0.0)
endif()
!!ENDIF
@ -45,7 +45,7 @@ Index: qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5BasicConfig.cm
!!ELSE
set(imported_location \"$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
!!ENDIF
@@ -74,45 +53,18 @@ macro(_populate_$${CMAKE_MODULE_NAME}_ta
@@ -74,19 +53,6 @@ macro(_populate_$${CMAKE_MODULE_NAME}_ta
\"IMPORTED_LINK_INTERFACE_LIBRARIES_${Configuration}\" \"${_Qt5$${CMAKE_MODULE_NAME}_LIB_DEPENDENCIES}\"
)
@ -65,23 +65,26 @@ Index: qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5BasicConfig.cm
endmacro()
!!ENDIF
if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
@@ -95,24 +61,24 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!IF !no_module_headers
-!!IF !isEmpty(CMAKE_BUILD_IS_FRAMEWORK)
- set(_Qt5$${CMAKE_MODULE_NAME}_OWN_INCLUDE_DIRS
!!IF !isEmpty(CMAKE_BUILD_IS_FRAMEWORK)
set(_Qt5$${CMAKE_MODULE_NAME}_OWN_INCLUDE_DIRS
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework\"
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Headers\"
- )
-!!IF isEmpty(CMAKE_NO_PRIVATE_INCLUDES)
- set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS
+ \"@NIX_OUT@/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework\"
+ \"@NIX_OUT@/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Headers\"
)
!!IF isEmpty(CMAKE_NO_PRIVATE_INCLUDES)
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Versions/$$section(VERSION, ., 0, 0)/Headers/$$VERSION/\"
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Versions/$$section(VERSION, ., 0, 0)/Headers/$$VERSION/$${MODULE_INCNAME}\"
- )
-!!ELSE
- set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS \"\")
-!!ENDIF
-!!ELSE
+ \"@NIX_OUT@/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Versions/$$section(VERSION, ., 0, 0)/Headers/$$VERSION/\"
+ \"@NIX_OUT@/$${CMAKE_LIB_DIR}Qt$${CMAKE_MODULE_NAME}.framework/Versions/$$section(VERSION, ., 0, 0)/Headers/$$VERSION/$${MODULE_INCNAME}\"
)
!!ELSE
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS \"\")
!!ENDIF
!!ELSE
!!IF isEmpty(CMAKE_INCLUDE_DIR_IS_ABSOLUTE)
- set(_Qt5$${CMAKE_MODULE_NAME}_OWN_INCLUDE_DIRS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$$CMAKE_INCLUDE_DIR\" \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}\")
+ set(_Qt5$${CMAKE_MODULE_NAME}_OWN_INCLUDE_DIRS \"@NIX_DEV@/$$CMAKE_INCLUDE_DIR\" \"@NIX_DEV@/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}\")
@ -94,27 +97,17 @@ Index: qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5BasicConfig.cm
)
!!ELSE
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS \"\")
@@ -128,7 +80,7 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS \"\")
!!ENDIF
!!ENDIF
-!!ENDIF
+
!!IF !isEmpty(CMAKE_ADD_SOURCE_INCLUDE_DIRS)
include(\"${CMAKE_CURRENT_LIST_DIR}/ExtraSourceIncludes.cmake\" OPTIONAL)
!!ENDIF
@@ -253,28 +205,19 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!IF !isEmpty(CMAKE_FIND_OTHER_LIBRARY_BUILD)
@@ -255,7 +221,7 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!IF isEmpty(CMAKE_DEBUG_TYPE)
-!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
-!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- if (EXISTS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
-!!ELSE // CMAKE_LIB_DIR_IS_ABSOLUTE
- if (EXISTS \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
-!!ENDIF // CMAKE_LIB_DIR_IS_ABSOLUTE
- _populate_$${CMAKE_MODULE_NAME}_target_properties(DEBUG \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" \"\" )
-!!ELSE // CMAKE_STATIC_WINDOWS_BUILD
+ if (EXISTS \"@NIX_OUT@/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
!!ELSE // CMAKE_LIB_DIR_IS_ABSOLUTE
if (EXISTS \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
!!ENDIF // CMAKE_LIB_DIR_IS_ABSOLUTE
@@ -263,13 +229,13 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!ELSE // CMAKE_STATIC_WINDOWS_BUILD
if (EXISTS
!!IF isEmpty(CMAKE_DLL_DIR_IS_ABSOLUTE)
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_DLL_DIR}$${CMAKE_LIB_FILE_LOCATION_DEBUG}\"
@ -129,31 +122,17 @@ Index: qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5BasicConfig.cm
!!ELSE
\"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
!!ENDIF
_populate_$${CMAKE_MODULE_NAME}_target_properties(DEBUG \"$${CMAKE_LIB_FILE_LOCATION_DEBUG}\" \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
-!!ENDIF // CMAKE_STATIC_WINDOWS_BUILD
endif()
!!ENDIF // CMAKE_DEBUG_TYPE
!!ENDIF // CMAKE_FIND_OTHER_LIBRARY_BUILD
@@ -282,36 +225,23 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!ENDIF // CMAKE_RELEASE_TYPE
!!IF !isEmpty(CMAKE_DEBUG_TYPE)
-!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
- _populate_$${CMAKE_MODULE_NAME}_target_properties(DEBUG \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" \"\" )
-!!ELSE
_populate_$${CMAKE_MODULE_NAME}_target_properties(DEBUG \"$${CMAKE_LIB_FILE_LOCATION_DEBUG}\" \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
-!!ENDIF // CMAKE_STATIC_WINDOWS_BUILD
!!IF !isEmpty(CMAKE_FIND_OTHER_LIBRARY_BUILD)
@@ -292,7 +258,7 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!IF isEmpty(CMAKE_RELEASE_TYPE)
-!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
-!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- if (EXISTS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
-!!ELSE // CMAKE_LIB_DIR_IS_ABSOLUTE
- if (EXISTS \"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
-!!ENDIF // CMAKE_LIB_DIR_IS_ABSOLUTE
- _populate_$${CMAKE_MODULE_NAME}_target_properties(RELEASE \"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" \"\" )
-!!ELSE // CMAKE_STATIC_WINDOWS_BUILD
+ if (EXISTS \"@NIX_DEV@/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
!!ELSE // CMAKE_LIB_DIR_IS_ABSOLUTE
if (EXISTS \"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
!!ENDIF // CMAKE_LIB_DIR_IS_ABSOLUTE
@@ -300,13 +266,13 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
!!ELSE // CMAKE_STATIC_WINDOWS_BUILD
if (EXISTS
!!IF isEmpty(CMAKE_DLL_DIR_IS_ABSOLUTE)
- \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_DLL_DIR}$${CMAKE_LIB_FILE_LOCATION_RELEASE}\"
@ -168,12 +147,7 @@ Index: qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5BasicConfig.cm
!!ELSE
\"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
!!ENDIF
_populate_$${CMAKE_MODULE_NAME}_target_properties(RELEASE \"$${CMAKE_LIB_FILE_LOCATION_RELEASE}\" \"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" )
-!!ENDIF // CMAKE_STATIC_WINDOWS_BUILD
endif()
!!ENDIF // CMAKE_RELEASE_TYPE
!!ENDIF // CMAKE_FIND_OTHER_LIBRARY_BUILD
@@ -328,11 +258,7 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
@@ -328,11 +294,7 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME
macro(_populate_$${CMAKE_MODULE_NAME}_plugin_properties Plugin Configuration PLUGIN_LOCATION)
set_property(TARGET Qt5::${Plugin} APPEND PROPERTY IMPORTED_CONFIGURATIONS ${Configuration})
@ -186,10 +160,10 @@ Index: qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5BasicConfig.cm
_qt5_$${CMAKE_MODULE_NAME}_check_file_exists(${imported_location})
set_target_properties(Qt5::${Plugin} PROPERTIES
\"IMPORTED_LOCATION_${Configuration}\" ${imported_location}
Index: qtbase-opensource-src-5.7.0/src/gui/Qt5GuiConfigExtras.cmake.in
Index: qtbase-opensource-src-5.8.0/src/gui/Qt5GuiConfigExtras.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/src/gui/Qt5GuiConfigExtras.cmake.in
+++ qtbase-opensource-src-5.7.0/src/gui/Qt5GuiConfigExtras.cmake.in
--- qtbase-opensource-src-5.8.0.orig/src/gui/Qt5GuiConfigExtras.cmake.in
+++ qtbase-opensource-src-5.8.0/src/gui/Qt5GuiConfigExtras.cmake.in
@@ -2,7 +2,7 @@
!!IF !isEmpty(CMAKE_ANGLE_EGL_DLL_RELEASE)
@ -215,10 +189,10 @@ Index: qtbase-opensource-src-5.7.0/src/gui/Qt5GuiConfigExtras.cmake.in
!!ELSE
set(imported_implib \"$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
!!ENDIF
Index: qtbase-opensource-src-5.7.0/src/widgets/Qt5WidgetsConfigExtras.cmake.in
Index: qtbase-opensource-src-5.8.0/src/widgets/Qt5WidgetsConfigExtras.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/src/widgets/Qt5WidgetsConfigExtras.cmake.in
+++ qtbase-opensource-src-5.7.0/src/widgets/Qt5WidgetsConfigExtras.cmake.in
--- qtbase-opensource-src-5.8.0.orig/src/widgets/Qt5WidgetsConfigExtras.cmake.in
+++ qtbase-opensource-src-5.8.0/src/widgets/Qt5WidgetsConfigExtras.cmake.in
@@ -3,7 +3,7 @@ if (NOT TARGET Qt5::uic)
add_executable(Qt5::uic IMPORTED)
@ -228,10 +202,10 @@ Index: qtbase-opensource-src-5.7.0/src/widgets/Qt5WidgetsConfigExtras.cmake.in
!!ELSE
set(imported_location \"$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\")
!!ENDIF
Index: qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtras.cmake.in
Index: qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtras.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/src/corelib/Qt5CoreConfigExtras.cmake.in
+++ qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtras.cmake.in
--- qtbase-opensource-src-5.8.0.orig/src/corelib/Qt5CoreConfigExtras.cmake.in
+++ qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtras.cmake.in
@@ -3,7 +3,7 @@ if (NOT TARGET Qt5::qmake)
add_executable(Qt5::qmake IMPORTED)
@ -277,10 +251,10 @@ Index: qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtras.cmake.in
!!ELSE
set(imported_location \"$${CMAKE_LIB_DIR}$${CMAKE_WINMAIN_FILE_LOCATION_DEBUG}\")
!!ENDIF
Index: qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
Index: qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
+++ qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
--- qtbase-opensource-src-5.8.0.orig/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
+++ qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
@@ -1,6 +1,6 @@
!!IF isEmpty(CMAKE_INSTALL_DATA_DIR_IS_ABSOLUTE)
@ -289,10 +263,10 @@ Index: qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtrasMkspecDirForIn
!!ELSE
set(_qt5_corelib_extra_includes \"$${CMAKE_INSTALL_DATA_DIR}mkspecs/$${CMAKE_MKSPEC}\")
!!ENDIF
Index: qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
Index: qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
+++ qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
--- qtbase-opensource-src-5.8.0.orig/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
+++ qtbase-opensource-src-5.8.0/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmake.in
@@ -1,6 +1,6 @@
!!IF isEmpty(CMAKE_HOST_DATA_DIR_IS_ABSOLUTE)
@ -301,10 +275,10 @@ Index: qtbase-opensource-src-5.7.0/src/corelib/Qt5CoreConfigExtrasMkspecDir.cmak
!!ELSE
set(_qt5_corelib_extra_includes \"$${CMAKE_HOST_DATA_DIR}mkspecs/$${CMAKE_MKSPEC}\")
!!ENDIF
Index: qtbase-opensource-src-5.7.0/src/dbus/Qt5DBusConfigExtras.cmake.in
Index: qtbase-opensource-src-5.8.0/src/dbus/Qt5DBusConfigExtras.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/src/dbus/Qt5DBusConfigExtras.cmake.in
+++ qtbase-opensource-src-5.7.0/src/dbus/Qt5DBusConfigExtras.cmake.in
--- qtbase-opensource-src-5.8.0.orig/src/dbus/Qt5DBusConfigExtras.cmake.in
+++ qtbase-opensource-src-5.8.0/src/dbus/Qt5DBusConfigExtras.cmake.in
@@ -3,7 +3,7 @@ if (NOT TARGET Qt5::qdbuscpp2xml)
add_executable(Qt5::qdbuscpp2xml IMPORTED)
@ -323,10 +297,27 @@ Index: qtbase-opensource-src-5.7.0/src/dbus/Qt5DBusConfigExtras.cmake.in
!!ELSE
set(imported_location \"$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\")
!!ENDIF
Index: qtbase-opensource-src-5.7.0/mkspecs/features/create_cmake.prf
Index: qtbase-opensource-src-5.8.0/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/mkspecs/features/create_cmake.prf
+++ qtbase-opensource-src-5.7.0/mkspecs/features/create_cmake.prf
--- qtbase-opensource-src-5.8.0.orig/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
+++ qtbase-opensource-src-5.8.0/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
@@ -2,10 +2,10 @@
add_library(Qt5::$$CMAKE_PLUGIN_NAME MODULE IMPORTED)
!!IF !isEmpty(CMAKE_RELEASE_TYPE)
-_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME RELEASE \"$${CMAKE_PLUGIN_LOCATION_RELEASE}\")
+_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME RELEASE \"@NIX_OUT@/$${CMAKE_PLUGIN_LOCATION_RELEASE}\")
!!ENDIF
!!IF !isEmpty(CMAKE_DEBUG_TYPE)
-_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME DEBUG \"$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
+_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME DEBUG \"@NIX_OUT@/$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
!!ENDIF
list(APPEND Qt5$${CMAKE_MODULE_NAME}_PLUGINS Qt5::$$CMAKE_PLUGIN_NAME)
Index: qtbase-opensource-src-5.8.0/mkspecs/features/create_cmake.prf
===================================================================
--- qtbase-opensource-src-5.8.0.orig/mkspecs/features/create_cmake.prf
+++ qtbase-opensource-src-5.8.0/mkspecs/features/create_cmake.prf
@@ -136,28 +136,28 @@ contains(CONFIG, plugin) {
win32 {
@ -338,7 +329,7 @@ Index: qtbase-opensource-src-5.7.0/mkspecs/features/create_cmake.prf
} else:mingw {
- CMAKE_PLUGIN_LOCATION_RELEASE = $$PLUGIN_TYPE/lib$${TARGET}.a
- CMAKE_PLUGIN_LOCATION_DEBUG = $$PLUGIN_TYPE/lib$${TARGET}d.a
+ CMAKE_PLUGIN_LOCATION_RELEASE = $${CMAKE_PLUGIN_DIR}/$$PLUGIN_TYPE/lib$${TARGET}.a
+ CMAKE_PLUGIN_LOCATION_RELEASE = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/lib$${TARGET}.a
+ CMAKE_PLUGIN_LOCATION_DEBUG = $${CMAKE_PLUGIN_DIR}$$PLUGIN_TYPE/lib$${TARGET}d.a
} else { # MSVC static
- CMAKE_PLUGIN_LOCATION_RELEASE = $$PLUGIN_TYPE/$${TARGET}.lib
@ -366,20 +357,3 @@ Index: qtbase-opensource-src-5.7.0/mkspecs/features/create_cmake.prf
}
}
cmake_target_file.input = $$PWD/data/cmake/Qt5PluginTarget.cmake.in
Index: qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
===================================================================
--- qtbase-opensource-src-5.7.0.orig/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
+++ qtbase-opensource-src-5.7.0/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
@@ -2,10 +2,10 @@
add_library(Qt5::$$CMAKE_PLUGIN_NAME MODULE IMPORTED)
!!IF !isEmpty(CMAKE_RELEASE_TYPE)
-_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME RELEASE \"$${CMAKE_PLUGIN_LOCATION_RELEASE}\")
+_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME RELEASE \"@NIX_OUT@/$${CMAKE_PLUGIN_LOCATION_RELEASE}\")
!!ENDIF
!!IF !isEmpty(CMAKE_DEBUG_TYPE)
-_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME DEBUG \"$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
+_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME DEBUG \"@NIX_OUT@/$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
!!ENDIF
list(APPEND Qt5$${CMAKE_MODULE_NAME}_PLUGINS Qt5::$$CMAKE_PLUGIN_NAME)

View File

@ -37,8 +37,7 @@ stdenv.mkDerivation {
outputs = [ "out" "dev" ];
patches =
copyPathsToStore (lib.readPathsFromFile ./. ./series)
++ [(if stdenv.isDarwin then ./cmake-paths-darwin.patch else ./cmake-paths.patch)];
copyPathsToStore (lib.readPathsFromFile ./. ./series);
postPatch =
''
@ -280,15 +279,33 @@ stdenv.mkDerivation {
''
# Don't retain build-time dependencies like gdb.
sed '/QMAKE_DEFAULT_.*DIRS/ d' -i $dev/mkspecs/qconfig.pri
''
# Move libtool archives and qmake projects
# Move libtool archives into $dev
+ ''
if [ "z''${!outputLib}" != "z''${!outputDev}" ]; then
pushd "''${!outputLib}"
find lib -name '*.a' -o -name '*.la'${if stdenv.isDarwin then "" else "-o -name '*.prl'"} | \
while read -r file; do
mkdir -p "''${!outputDev}/$(dirname "$file")"
mv "''${!outputLib}/$file" "''${!outputDev}/$file"
done
find lib -name '*.a' -o -name '*.la' | while read -r file; do
mkdir -p "''${!outputDev}/$(dirname "$file")"
mv "''${!outputLib}/$file" "''${!outputDev}/$file"
done
popd
fi
''
# Move qmake project files into $dev.
# Don't move .prl files on darwin because they end up in
# "dev/lib/Foo.framework/Foo.prl" which interferes with subsequent
# use of lndir in the qtbase setup-hook. On Linux, the .prl files
# are in lib, and so do not cause a subsequent recreation of deep
# framework directory trees.
+ lib.optionalString (!stdenv.isDarwin) ''
if [ "z''${!outputLib}" != "z''${!outputDev}" ]; then
pushd "''${!outputLib}"
find lib -name '*.prl' | while read -r file; do
mkdir -p "''${!outputDev}/$(dirname "$file")"
mv "''${!outputLib}/$file" "''${!outputDev}/$file"
done
popd
fi
''
@ -299,11 +316,6 @@ stdenv.mkDerivation {
-e "/^host_bins=/ c host_bins=$dev/bin"
''
# Don' move .prl files on darwin because they end up in
# "dev/lib/Foo.framework/Foo.prl" which interferes with subsequent
# use of lndir in the qtbase setup-hook. On Linux, the .prl files
# are in lib, and so do not cause a subsequent recreation of deep
# framework directory trees.
+ lib.optionalString stdenv.isDarwin ''
fixDarwinDylibNames_rpath() {
local flags=()

View File

@ -8,3 +8,4 @@ compose-search-path.patch
libressl.patch
qpa-plugin-path.patch
dlopen-gl.patch
cmake-paths.patch