[qt5] Remove absolute paths from .prl files

This commit is contained in:
Robert Schumacher 2018-03-28 07:36:51 -07:00
parent 1bec90d155
commit ba47c71551
4 changed files with 22 additions and 2 deletions

View File

@ -1,4 +1,4 @@
Source: qt5-base Source: qt5-base
Version: 5.9.2-5 Version: 5.9.2-6
Description: Qt5 Application Framework Base Module. Includes Core, GUI, Widgets, Networking, SQL, Concurrent and other essential qt components. Description: Qt5 Application Framework Base Module. Includes Core, GUI, Widgets, Networking, SQL, Concurrent and other essential qt components.
Build-Depends: zlib, libjpeg-turbo, libpng, freetype, pcre2, harfbuzz, sqlite3, libpq, double-conversion, openssl Build-Depends: zlib, libjpeg-turbo, libpng, freetype, pcre2, harfbuzz, sqlite3, libpq, double-conversion, openssl

View File

@ -167,6 +167,16 @@ if(EXISTS ${CURRENT_PACKAGES_DIR}/lib/qtmain.lib)
file(REMOVE ${CURRENT_PACKAGES_DIR}/debug/lib/qtmaind.prl) file(REMOVE ${CURRENT_PACKAGES_DIR}/debug/lib/qtmaind.prl)
endif() endif()
file(GLOB_RECURSE PRL_FILES "${CURRENT_PACKAGES_DIR}/lib/*.prl" "${CURRENT_PACKAGES_DIR}/debug/lib/*.prl")
file(TO_CMAKE_PATH "${CURRENT_INSTALLED_DIR}/lib" CMAKE_RELEASE_LIB_PATH)
file(TO_CMAKE_PATH "${CURRENT_INSTALLED_DIR}/debug/lib" CMAKE_DEBUG_LIB_PATH)
foreach(PRL_FILE IN LISTS PRL_FILES)
file(READ "${PRL_FILE}" _contents)
string(REPLACE "${CMAKE_RELEASE_LIB_PATH}" "\$\$[QT_INSTALL_LIBS]" _contents "${_contents}")
string(REPLACE "${CMAKE_DEBUG_LIB_PATH}" "\$\$[QT_INSTALL_LIBS]" _contents "${_contents}")
file(WRITE "${PRL_FILE}" "${_contents}")
endforeach()
file(COPY ${CMAKE_CURRENT_LIST_DIR}/qtdeploy.ps1 DESTINATION ${CURRENT_PACKAGES_DIR}/plugins) file(COPY ${CMAKE_CURRENT_LIST_DIR}/qtdeploy.ps1 DESTINATION ${CURRENT_PACKAGES_DIR}/plugins)
file(COPY ${CMAKE_CURRENT_LIST_DIR}/qtdeploy.ps1 DESTINATION ${CURRENT_PACKAGES_DIR}/debug/plugins) file(COPY ${CMAKE_CURRENT_LIST_DIR}/qtdeploy.ps1 DESTINATION ${CURRENT_PACKAGES_DIR}/debug/plugins)

View File

@ -1,3 +1,3 @@
Source: qt5-modularscripts Source: qt5-modularscripts
Version: 2 Version: 3
Description: Vcpkg helpers to package qt5 modules Description: Vcpkg helpers to package qt5 modules

View File

@ -78,6 +78,16 @@ function(qt_modular_library NAME HASH)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/cmake) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/cmake)
endif() endif()
file(GLOB_RECURSE PRL_FILES "${CURRENT_PACKAGES_DIR}/lib/*.prl" "${CURRENT_PACKAGES_DIR}/debug/lib/*.prl")
file(TO_CMAKE_PATH "${CURRENT_INSTALLED_DIR}/lib" CMAKE_RELEASE_LIB_PATH)
file(TO_CMAKE_PATH "${CURRENT_INSTALLED_DIR}/debug/lib" CMAKE_DEBUG_LIB_PATH)
foreach(PRL_FILE IN LISTS PRL_FILES)
file(READ "${PRL_FILE}" _contents)
string(REPLACE "${CMAKE_RELEASE_LIB_PATH}" "\$\$[QT_INSTALL_LIBS]" _contents "${_contents}")
string(REPLACE "${CMAKE_DEBUG_LIB_PATH}" "\$\$[QT_INSTALL_LIBS]" _contents "${_contents}")
file(WRITE "${PRL_FILE}" "${_contents}")
endforeach()
file(GLOB RELEASE_LIBS "${CURRENT_PACKAGES_DIR}/lib/*") file(GLOB RELEASE_LIBS "${CURRENT_PACKAGES_DIR}/lib/*")
if(NOT RELEASE_LIBS) if(NOT RELEASE_LIBS)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib)