[qt5-base, qt5-imageformat] fix issues on osx (#9705)

* [qt5-imageformats] freeglut is not a dependency on osx

* [qt5-base] fontconfig can require iconv on linux and osx

* include the jasper fix to get CI coverage?

* trying to get ci coverage for qt on osx

* Revert "trying to get ci coverage for qt on osx"

This reverts commit 8b9b188839.

* apply the correct ci hack

* fix wrapper to include macosx debug suffix

* update baseline

* first try to fix the Qt5 cmake configs at the root.

* fix missing backslash

* fix plugin patch

* fix qt config patch

* remove 90% of fixcmake.py

* update baseline

* experimental removal of fixcmake.py and dll copying into tools/qt5/bin

* fix experimental dll copying.

* fix static windows builds

* fix static builds

* fix plugin copy

* add quotes around configuration to make it work

* remove dll debug messages

* note about the cmake fix

* revert fontconfig changes on linux. Make qt.conf relative and not absolute

* make qt.conf relative

* trying to fix ogre osx ci regression

* fix silly path error

* Revert "trying to fix ogre osx ci regression"

This reverts commit 708d8250d6.

* add ogre:x64-osx=fail to CI baseline

* retry on osx

* fix configure error. since in qt5-base everything is in the package directory and not in the installed

* revert change to ci.baseline

* update ci baseline

* bump control

* update baseline

* ws change to osg-qt

* reset ci baseline to upstream/master

* update baseline

* fix osg-qt?

* skip ms-angle on osx and linux since the normal angle port should be used!

* update ci baseline

* try adding fontconfig manually

* update ci baseline to remove osg-qt for the time being

* remove manual library.
This commit is contained in:
Alexander Neumann 2020-04-10 02:08:01 +02:00 committed by GitHub
parent 0edffcf125
commit 941d546454
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 180 additions and 137 deletions

View File

@ -1,4 +1,4 @@
Source: osg-qt
Version: Qt4
Description: osgQt - Qt project for making use of OpenSceneGraph(OSG)
Version: Qt4-1
Description: osgQt - Qt project for making use of OpenSceneGraph(OSG)
Build-Depends: osg, protobuf, qt5-base

View File

@ -1,4 +1,3 @@
include(vcpkg_common_functions)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
@ -6,10 +5,14 @@ vcpkg_from_github(
REF Qt4
SHA512 426a4ba88f680978d24817248b99c68cafa4517144e6e3d2480612870c4a224bb955539cacb438274d4ee1c93c36d94f8437d142070b2ecde2b81517bf357e71
HEAD_REF master
PATCHES
PATCHES
OsgMacroUtils.patch
)
if(VCPKG_TARGET_IS_OSX)
string(APPEND VCPKG_CXX_FLAGS " -stdlib=libc++")
string(APPEND VCPKG_C_FLAGS "") # both must be set
endif()
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
@ -22,5 +25,5 @@ vcpkg_install_cmake()
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
# Handle License
file(COPY ${SOURCE_PATH}/LICENSE.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/osg-qt)
file(RENAME ${CURRENT_PACKAGES_DIR}/share/osg-qt/LICENSE.txt ${CURRENT_PACKAGES_DIR}/share/osg-qt/copyright)
file(COPY ${SOURCE_PATH}/LICENSE.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT})
file(RENAME ${CURRENT_PACKAGES_DIR}/share/${PORT}/LICENSE.txt ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright)

View File

@ -2,4 +2,4 @@ Source: pango
Version: 1.40.11-6
Homepage: https://ftp.gnome.org/pub/GNOME/sources/pango/
Description: Text and font handling library.
Build-Depends: glib, gettext, cairo, fontconfig, freetype, harfbuzz[glib] (!(windows&static))
Build-Depends: glib, gettext, cairo, fontconfig, freetype, harfbuzz[glib] (!(windows&static)&!osx)

View File

@ -78,6 +78,25 @@ function(qt_build_submodule SOURCE_PATH)
endforeach()
if(EXISTS "${CURRENT_PACKAGES_DIR}/tools/qt5/bin")
file(COPY "${CURRENT_PACKAGES_DIR}/tools/qt5/bin" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/${PORT}")
set(CURRENT_INSTALLED_DIR_BACKUP "${CURRENT_INSTALLED_DIR}")
set(CURRENT_INSTALLED_DIR "./../../.." ) # Making the qt.conf relative and not absolute
configure_file(${CURRENT_INSTALLED_DIR_BACKUP}/tools/qt5/qt_release.conf ${CURRENT_PACKAGES_DIR}/tools/${PORT}/bin/qt.conf) # This makes the tools at least useable for release
set(CURRENT_INSTALLED_DIR "${CURRENT_INSTALLED_DIR_BACKUP}")
vcpkg_copy_tool_dependencies("${CURRENT_PACKAGES_DIR}/tools/${PORT}/bin")
if(VCPKG_TARGET_IS_WINDOWS AND VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
file(GLOB_RECURSE DLL_DEPS_AVAIL "${CURRENT_INSTALLED_DIR}/tools/qt5/bin/*.dll")
string(REPLACE "${CURRENT_INSTALLED_DIR}/tools/qt5/bin/" "" DLL_DEPS_AVAIL "${DLL_DEPS_AVAIL}")
file(GLOB_RECURSE DLL_DEPS_NEEDED "${CURRENT_PACKAGES_DIR}/tools/${PORT}/bin/*.dll")
string(REPLACE "${CURRENT_PACKAGES_DIR}/tools/${PORT}/bin/" "" DLL_DEPS_NEEDED "${DLL_DEPS_NEEDED}")
if(DLL_DEPS_AVAIL AND DLL_DEPS_NEEDED)
list(REMOVE_ITEM DLL_DEPS_NEEDED ${DLL_DEPS_AVAIL})
endif()
foreach(dll_dep ${DLL_DEPS_NEEDED})
string(REGEX REPLACE "[^/]+$" "" dll_subpath "${dll_dep}")
file(COPY "${CURRENT_PACKAGES_DIR}/tools/${PORT}/bin/${dll_dep}" DESTINATION "${CURRENT_PACKAGES_DIR}/tools/qt5/bin/${dll_subpath}")
endforeach()
endif()
endif()
endfunction()

View File

@ -1,25 +1,14 @@
function(qt_fix_cmake PACKAGE_DIR_TO_FIX PORT_TO_FIX)
set(BACKUP_PATH "$ENV{PATH}")
#Find Python and add it to the path
vcpkg_find_acquire_program(PYTHON2)
get_filename_component(PYTHON2_EXE_PATH ${PYTHON2} DIRECTORY)
vcpkg_add_to_path("${PYTHON2_EXE_PATH}")
#Fix the cmake files if they exist
if(EXISTS ${PACKAGE_DIR_TO_FIX}/lib/cmake)
vcpkg_execute_required_process(
COMMAND ${PYTHON2} ${CURRENT_INSTALLED_DIR}/share/qt5/fixcmake.py ${PORT_TO_FIX}
WORKING_DIRECTORY ${PACKAGE_DIR_TO_FIX}/lib/cmake
LOGNAME fix-cmake
)
endif()
if(EXISTS ${PACKAGE_DIR_TO_FIX}/share/cmake)
vcpkg_execute_required_process(
COMMAND ${PYTHON2} ${CURRENT_INSTALLED_DIR}/share/qt5/fixcmake.py ${PORT_TO_FIX}
WORKING_DIRECTORY ${PACKAGE_DIR_TO_FIX}/share/cmake
LOGNAME fix-cmake
)
endif()
file(GLOB_RECURSE cmakefiles ${PACKAGE_DIR_TO_FIX}/share/cmake/*.cmake ${PACKAGE_DIR_TO_FIX}/lib/cmake/*.cmake)
foreach(cmakefile ${cmakefiles})
file(READ "${cmakefile}" _contents)
if(_contents MATCHES "_install_prefix}/tools/qt5/bin/([a-z0-9]+)") # there are only about 3 to 5 cmake files which require the fix in ports: qt5-tools qt5-xmlpattern at5-activeqt qt5-quick
string(REGEX REPLACE "_install_prefix}/tools/qt5/bin/([a-z0-9]+)" "_install_prefix}/tools/${PORT_TO_FIX}/bin/\\1" _contents "${_contents}")
file(WRITE "${cmakefile}" "${_contents}")
endif()
endforeach()
#Install cmake files
if(EXISTS ${PACKAGE_DIR_TO_FIX}/lib/cmake)
file(MAKE_DIRECTORY ${PACKAGE_DIR_TO_FIX}/share)
@ -29,5 +18,4 @@ function(qt_fix_cmake PACKAGE_DIR_TO_FIX PORT_TO_FIX)
if(EXISTS ${PACKAGE_DIR_TO_FIX}/debug/lib/cmake)
file(REMOVE_RECURSE ${PACKAGE_DIR_TO_FIX}/debug/lib/cmake)
endif()
set(ENV{PATH} "${BACKUP_PATH}")
endfunction()

View File

@ -1,88 +0,0 @@
import os
import re
import sys
from glob import glob
port="qt5"
if len(sys.argv) > 1:
port=sys.argv[1]
files = [y for x in os.walk('.') for y in glob(os.path.join(x[0], '*.cmake'))]
tooldir="/tools/"+port+"/bin/"
for f in files:
openedfile = open(f, "r")
builder = ""
dllpatterndebug = re.compile("_install_prefix}/bin/Qt5.*d+(.dll|.so)")
libpatterndebug = re.compile("_install_prefix}/lib/Qt5.*d+(.lib|.a)")
exepattern = re.compile("_install_prefix}/bin/[a-z]+(.exe|)")
toolexepattern = re.compile("_install_prefix}/tools/qt5/bin/[a-z]+(.exe|)")
tooldllpattern = re.compile("_install_prefix}/tools/qt5/bin/Qt5.*d+(.dll|.so)")
populatepluginpattern = re.compile("_populate_[^_]+_plugin_properties\([^ ]+ RELEASE")
populatetargetpattern = re.compile("_populate_[^_]+_target_properties\(RELEASE ")
for line in openedfile:
if "_install_prefix}/tools/qt5/${LIB_LOCATION}" in line:
builder += " if (${Configuration} STREQUAL \"RELEASE\")"
builder += "\n " + line.replace("/tools/qt5/bin", "/bin/")
builder += " else()" #This requires a release and debug build since Qt will check that the file exists!
#It would be better to use an elseif here with a EXISTS check but that requires a more complicated regex to build the complete filepath since each module uses its own _(qtmodule)_install_prefix
#so single configuration builds of Qt are currently not supported. Thus =>
#TODO: Make single configuration builds of Qt work correctly!
builder += "\n " + line.replace("/tools/qt5/debug/bin", "/debug/bin/")
builder += " endif()\n"
elif "_install_prefix}/bin/${LIB_LOCATION}" in line:
builder += " if (${Configuration} STREQUAL \"RELEASE\")"
builder += "\n " + line
builder += " else()" #This requires a release and debug build!
builder += "\n " + line.replace("/bin/", "/debug/bin/")
builder += " endif()\n"
elif "_install_prefix}/lib/${LIB_LOCATION}" in line:
builder += " if (${Configuration} STREQUAL \"RELEASE\")"
builder += "\n " + line
builder += " else()" #This requires a release and debug build!
builder += "\n " + line.replace("/lib/", "/debug/lib/")
builder += " endif()\n"
elif "_install_prefix}/lib/${IMPLIB_LOCATION}" in line:
builder += " if (${Configuration} STREQUAL \"RELEASE\")"
builder += "\n " + line
builder += " else()" #This requires a release and debug build!
builder += "\n " + line.replace("/lib/", "/debug/lib/")
builder += " endif()\n"
elif "_install_prefix}/plugins/${PLUGIN_LOCATION}" in line:
builder += " if (${Configuration} STREQUAL \"RELEASE\")"
builder += "\n " + line
builder += " else()" #This requires a release and debug build!
builder += "\n " + line.replace("/plugins/", "/debug/plugins/")
builder += " endif()\n"
elif "_install_prefix}/lib/qtmaind.lib" in line:
# qtmaind.lib has been moved to manual-link:
builder += line.replace("/lib/", "/debug/lib/manual-link/")
elif "_install_prefix}/lib/qtmain.lib" in line:
# qtmain(d).lib has been moved to manual-link:
builder += line.replace("/lib/", "/lib/manual-link/")
builder += " set(imported_location_debug \"${_qt5Core_install_prefix}/debug/lib/manual-link/qtmaind.lib\")\n"
builder += "\n"
builder += " set_target_properties(Qt5::WinMain PROPERTIES\n"
builder += " IMPORTED_LOCATION_DEBUG ${imported_location_debug}\n"
builder += " )\n"
elif populatepluginpattern.search(line) != None:
builder += line
builder += line.replace("RELEASE", "DEBUG").replace(".dll", "d.dll").replace(".lib", "d.lib")
elif populatetargetpattern.search(line) != None:
builder += line
builder += line.replace("RELEASE", "DEBUG").replace(".dll", "d.dll").replace(".lib", "d.lib")
elif dllpatterndebug.search(line) != None:
builder += line.replace("/bin/", "/debug/bin/")
elif libpatterndebug.search(line) != None:
builder += line.replace("/lib/", "/debug/lib/")
elif tooldllpattern.search(line) != None:
builder += line.replace("/tools/qt5/bin", "/debug/bin/")
elif exepattern.search(line) != None:
builder += line.replace("/bin/", tooldir)
elif toolexepattern.search(line) != None:
builder += line.replace("/tools/qt5/bin/",tooldir)
else:
builder += line
new_file = open(f, "w")
new_file.write(builder)
new_file.close()

View File

@ -0,0 +1,78 @@
diff --git a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
index c72989288..a88234dca 100644
--- a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
+++ b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
@@ -53,7 +53,11 @@ macro(_populate_$${CMAKE_MODULE_NAME}_target_properties Configuration LIB_LOCATI
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}\")
+ if(\"${Configuration}\" STREQUAL \"DEBUG\")
+ set(imported_location \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/debug/$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
+ else()
+ set(imported_location \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
+ endif()
!!ELSE
set(imported_location \"$${CMAKE_DLL_DIR}${LIB_LOCATION}\")
!!ENDIF
@@ -69,8 +73,12 @@ macro(_populate_$${CMAKE_MODULE_NAME}_target_properties Configuration LIB_LOCATI
)
!!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}\")
+ if(\"${Configuration}\" STREQUAL \"DEBUG\")
+ set(imported_implib \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/debug/$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
+ else()
+ set(imported_implib \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
+ endif()
!!ELSE
set(imported_implib \"IMPORTED_IMPLIB_${Configuration}\" \"$${CMAKE_LIB_DIR}${IMPLIB_LOCATION}\")
!!ENDIF
@@ -270,9 +278,8 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
!!ENDIF // CMAKE_STATIC_WINDOWS_BUILD
!!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}\" )
+ if (EXISTS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/debug/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
!!ELSE // CMAKE_LIB_DIR_IS_ABSOLUTE
if (EXISTS \"$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\" )
@@ -281,20 +288,19 @@ 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}\"
+ \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/debug/$${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}\" )
+ \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/debug/$${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
!!ENDIF // CMAKE_RELEASE_TYPE
@@ -347,7 +353,12 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
set_property(TARGET Qt5::${Plugin} APPEND PROPERTY IMPORTED_CONFIGURATIONS ${Configuration})
!!IF isEmpty(CMAKE_PLUGIN_DIR_IS_ABSOLUTE)
+ if(\"${Configuration}\" STREQUAL \"DEBUG\")
+ set(imported_location \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/debug/$${CMAKE_PLUGIN_DIR}${PLUGIN_LOCATION}\")
+ else()
set(imported_location \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_PLUGIN_DIR}${PLUGIN_LOCATION}\")
+ endif()
+
!!ELSE
set(imported_location \"$${CMAKE_PLUGIN_DIR}${PLUGIN_LOCATION}\")
!!ENDIF

View File

@ -0,0 +1,22 @@
diff --git a/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in b/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
index 5baf0fdb1..185abfffd 100644
--- a/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
+++ b/mkspecs/features/data/cmake/Qt5PluginTarget.cmake.in
@@ -1,11 +1,11 @@
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}\")
-!!ENDIF
-!!IF !isEmpty(CMAKE_DEBUG_TYPE)
-_populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME DEBUG \"$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
-!!ENDIF
+if(EXISTS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_PLUGIN_DIR}$${CMAKE_PLUGIN_LOCATION_RELEASE}\")
+ _populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME RELEASE \"$${CMAKE_PLUGIN_LOCATION_RELEASE}\")
+endif()
+if(EXISTS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/debug/$${CMAKE_PLUGIN_DIR}$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
+ _populate_$${CMAKE_MODULE_NAME}_plugin_properties($$CMAKE_PLUGIN_NAME DEBUG \"$${CMAKE_PLUGIN_LOCATION_DEBUG}\")
+endif()
list(APPEND Qt5$${CMAKE_MODULE_NAME}_PLUGINS Qt5::$$CMAKE_PLUGIN_NAME)

View File

@ -42,6 +42,9 @@ qt_download_submodule( OUT_SOURCE_PATH SOURCE_PATH
#patches/static_opengl.patch #Use this patch if you really want to statically link angle on windows (e.g. using -opengl es2 and -static).
#Be carefull since it requires definining _GDI32_ for all dependent projects due to redefinition errors in the
#the windows supplied gl.h header and the angle gl.h otherwise.
#CMake fixes
patches/Qt5BasicConfig.patch
patches/Qt5PluginTarget.patch
patches/Qt5GuiConfigExtras.patch # Patches the library search behavior for EGL since angle is not build with Qt
)
@ -62,7 +65,6 @@ set(ENV{_CL_} "/utf-8")
set(CORE_OPTIONS
-confirm-license
-opensource
#-no-fontconfig
#-simulator_and_device
#-ltcg
#-combined-angle-lib
@ -236,14 +238,14 @@ elseif(VCPKG_TARGET_IS_OSX)
"SQLITE_LIBS=${SQLITE_RELEASE} -ldl -lpthread"
"HARFBUZZ_LIBS=${HARFBUZZ_RELEASE} -framework ApplicationServices"
"OPENSSL_LIBS=${SSL_RELEASE} ${EAY_RELEASE} -ldl -lpthread"
"FONTCONFIG_LIBS=${FONTCONFIG_RELEASE} ${FREETYPE_RELEASE} ${EXPAT_RELEASE}"
"FONTCONFIG_LIBS=${FONTCONFIG_RELEASE} ${FREETYPE_RELEASE} ${EXPAT_RELEASE} -liconv"
)
list(APPEND DEBUG_OPTIONS
"PSQL_LIBS=${PSQL_DEBUG} ${SSL_DEBUG} ${EAY_DEBUG} -ldl -lpthread"
"SQLITE_LIBS=${SQLITE_DEBUG} -ldl -lpthread"
"HARFBUZZ_LIBS=${HARFBUZZ_DEBUG} -framework ApplicationServices"
"OPENSSL_LIBS=${SSL_DEBUG} ${EAY_DEBUG} -ldl -lpthread"
"FONTCONFIG_LIBS=${FONTCONFIG_DEBUG} ${FREETYPE_DEBUG} ${EXPAT_DEBUG}"
"FONTCONFIG_LIBS=${FONTCONFIG_DEBUG} ${FREETYPE_DEBUG} ${EXPAT_DEBUG} -liconv"
)
endif()
@ -287,7 +289,7 @@ else()
file(RENAME ${CURRENT_PACKAGES_DIR}/lib/cmake ${CURRENT_PACKAGES_DIR}/share/cmake)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/cmake) # TODO: check if important debug information for cmake is lost
#This needs a new VCPKG policy.
#This needs a new VCPKG policy or a static angle build (ANGLE needs to be fixed in VCPKG!)
if(VCPKG_TARGET_IS_WINDOWS AND ${VCPKG_LIBRARY_LINKAGE} MATCHES "static") # Move angle dll libraries
message(STATUS "Moving ANGLE dlls from /bin to /tools/qt5-angle/bin. In static builds dlls are not allowed in /bin")
if(EXISTS "${CURRENT_PACKAGES_DIR}/bin")
@ -300,12 +302,28 @@ else()
endif()
endif()
#TODO: Replace python script with cmake script
vcpkg_execute_required_process(
COMMAND ${PYTHON3} ${CMAKE_CURRENT_LIST_DIR}/fixcmake.py
WORKING_DIRECTORY ${CURRENT_PACKAGES_DIR}/share/cmake
LOGNAME fix-cmake
)
## Fix location of qtmain(d).lib. Has been moved into manual-link. Add debug version
if(VCPKG_TARGET_IS_WINDOWS AND NOT VCPKG_BUILD_TYPE)
set(cmakefile "${CURRENT_PACKAGES_DIR}/share/cmake/Qt5Core/Qt5CoreConfigExtras.cmake")
file(READ "${cmakefile}" _contents)
string(REPLACE "set_property(TARGET Qt5::WinMain APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)" "set_property(TARGET Qt5::WinMain APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE DEBUG)" _contents "${_contents}")
string(REPLACE
[[set(imported_location "${_qt5Core_install_prefix}/lib/qtmain.lib")]]
[[set(imported_location_release "${_qt5Core_install_prefix}/lib/manual-link/qtmain.lib")
set(imported_location_debug "${_qt5Core_install_prefix}/debug/lib/manual-link/qtmaind.lib")]]
_contents "${_contents}")
string(REPLACE
[[ set_target_properties(Qt5::WinMain PROPERTIES
IMPORTED_LOCATION_RELEASE ${imported_location}
)]]
[[ set_target_properties(Qt5::WinMain PROPERTIES
IMPORTED_LOCATION_RELEASE ${imported_location_release}
IMPORTED_LOCATION_DEBUG ${imported_location_debug}
)]]
_contents "${_contents}")
file(WRITE "${cmakefile}" "${_contents}")
endif()
file(COPY ${CMAKE_CURRENT_LIST_DIR}/vcpkg-cmake-wrapper.cmake DESTINATION ${CURRENT_PACKAGES_DIR}/share/qt5core)
if(EXISTS ${CURRENT_PACKAGES_DIR}/tools/qt5/bin)
file(COPY ${CURRENT_PACKAGES_DIR}/tools/qt5/bin DESTINATION ${CURRENT_PACKAGES_DIR}/tools/${PORT})
@ -316,12 +334,15 @@ else()
if(EXISTS ${CURRENT_PACKAGES_DIR}/tools/qt5/bin/qt.conf)
file(REMOVE "${CURRENT_PACKAGES_DIR}/tools/qt5/bin/qt.conf")
endif()
set(CURRENT_INSTALLED_DIR_BACKUP "${CURRENT_INSTALLED_DIR}")
set(CURRENT_INSTALLED_DIR "./../../.." ) # Making the qt.conf relative and not absolute
configure_file(${CURRENT_PACKAGES_DIR}/tools/qt5/qt_release.conf ${CURRENT_PACKAGES_DIR}/tools/qt5/bin/qt.conf) # This makes the tools at least useable for release
set(CURRENT_INSTALLED_DIR "${CURRENT_INSTALLED_DIR_BACKUP}")
qt_install_copyright(${SOURCE_PATH})
endif()
#install scripts for other qt ports
file(COPY
${CMAKE_CURRENT_LIST_DIR}/fixcmake.py
${CMAKE_CURRENT_LIST_DIR}/cmake/qt_port_hashes.cmake
${CMAKE_CURRENT_LIST_DIR}/cmake/qt_port_functions.cmake
${CMAKE_CURRENT_LIST_DIR}/cmake/qt_fix_makefile_install.cmake

View File

@ -3,7 +3,7 @@ _find_package(${ARGS})
function(add_qt_library _target)
foreach(_lib IN LISTS ARGN)
#The fact that we are within this file means we are using the VCPKG toolchain. Has such we only need to search in VCPKG paths!
find_library(${_lib}_LIBRARY_DEBUG NAMES ${_lib}d ${_lib} NAMES_PER_DIR PATH_SUFFIXES lib plugins/platforms PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug" NO_DEFAULT_PATH)
find_library(${_lib}_LIBRARY_DEBUG NAMES ${_lib}_debug ${_lib}d ${_lib} NAMES_PER_DIR PATH_SUFFIXES lib plugins/platforms PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug" NO_DEFAULT_PATH)
find_library(${_lib}_LIBRARY_RELEASE NAMES ${_lib} NAMES_PER_DIR PATH_SUFFIXES lib plugins/platforms PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}" NO_DEFAULT_PATH)
if(${_lib}_LIBRARY_RELEASE)
list(APPEND interface_lib \$<\$<NOT:\$<CONFIG:DEBUG>>:${${_lib}_LIBRARY_RELEASE}>)

View File

@ -1,4 +1,4 @@
Source: qt5-imageformats
Version: 5.12.5-2
Version: 5.12.5-3
Description: Qt5 Image Formats Module - Plugins for additional image formats: TIFF, MNG, TGA, WBMP
Build-Depends: qt5-base, tiff, libwebp, jasper

View File

@ -14,8 +14,10 @@ find_library(TIFF_DEBUG NAMES tiffd PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" N
find_library(JASPER_RELEASE NAMES jasper PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH)
find_library(JASPER_DEBUG NAMES jasperd jasper libjasperd libjasper PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH)
find_library(FREEGLUT_RELEASE NAMES freeglut glut PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH)
find_library(FREEGLUT_DEBUG NAMES freeglutd freeglut glutd glut PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH)
if(NOT VCPKG_TARGET_IS_OSX)
find_library(FREEGLUT_RELEASE NAMES freeglut glut PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH)
find_library(FREEGLUT_DEBUG NAMES freeglutd freeglut glutd glut PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH)
endif()
find_library(WEBP_RELEASE NAMES webp PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH)
find_library(WEBP_DEBUG NAMES webpd webp PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH)

View File

@ -304,7 +304,6 @@ cudnn:arm-uwp=fail
cudnn:x64-uwp=fail
cudnn:x64-windows-static=fail
cudnn:x86-windows=fail
cutelyst2:x64-osx=fail
date:arm64-windows=fail
dbow2:x64-osx=fail
dcmtk:arm64-windows=fail
@ -659,7 +658,6 @@ jemalloc:x64-uwp=fail
jemalloc:x64-windows-static=fail
jinja2cpplight:arm-uwp=fail
jinja2cpplight:x64-uwp=fail
kd-soap:x64-osx=fail
keystone:arm64-windows=fail
keystone:arm-uwp=fail
keystone:x64-uwp=fail
@ -1124,7 +1122,7 @@ mpir:arm64-windows=fail
mpir:arm-uwp=fail
mpir:x64-uwp=fail
#Conflicts with angle and qt-5base
#Conflicts with angle
ms-angle:arm64-windows = skip
ms-angle:arm-uwp = skip
ms-angle:x64-linux = skip
@ -1328,6 +1326,8 @@ osgearth:x64-osx=fail
osgearth:x64-linux=fail
osgearth:x64-windows-static=fail
osg-qt:x64-windows-static=fail
# Missing Fontconfig linkage in vcpkg_cmake_wrapper. Will be fixed by #9860 with the removal of the wrapper.
osg-qt:x64-osx=fail
osg-qt:x64-linux=ignore
otl:x64-windows=ignore
otl:x64-windows-static=ignore
@ -1450,7 +1450,6 @@ python3:x64-uwp=fail
qca:x64-linux=fail
qca:x64-osx=fail
qca:x64-windows-static=fail
qcustomplot:x64-osx=fail
qhull:arm-uwp=ignore
qhull:x64-windows-static=ignore
qhull:x64-uwp=ignore
@ -1458,7 +1457,6 @@ qpid-proton:arm-uwp=fail
qpid-proton:x64-uwp=fail
qpid-proton:x64-windows-static=fail
qscintilla:x64-linux=fail
qscintilla:x64-osx=fail
qt5-activeqt:x64-linux=fail
qt5-activeqt:x64-osx=fail
qt5-macextras:x64-linux=fail