aboutsummaryrefslogtreecommitdiff
path: root/ports/qca/portfile.cmake
diff options
context:
space:
mode:
authordevel71 <devel71@hotmail.de>2016-11-26 13:51:09 +0100
committerdevel71 <devel71@hotmail.de>2016-11-26 13:51:09 +0100
commitcb778ecfbd78f03e8a9361ff9376df108f6bb906 (patch)
tree92069a13c4389554e8a24338a3a7ea6888fc05d0 /ports/qca/portfile.cmake
parent877b237f6f22fdc098051f550c7b9dcf26afe3ec (diff)
downloadvcpkg-cb778ecfbd78f03e8a9361ff9376df108f6bb906.tar.gz
vcpkg-cb778ecfbd78f03e8a9361ff9376df108f6bb906.zip
[qca] fix cmake file location
Added qt5 Build-Depends to CONTROL file.
Diffstat (limited to 'ports/qca/portfile.cmake')
-rw-r--r--ports/qca/portfile.cmake36
1 files changed, 19 insertions, 17 deletions
diff --git a/ports/qca/portfile.cmake b/ports/qca/portfile.cmake
index cc391b517..fa38970d3 100644
--- a/ports/qca/portfile.cmake
+++ b/ports/qca/portfile.cmake
@@ -7,7 +7,6 @@ if (VCPKG_LIBRARY_LINKAGE STREQUAL static)
endif()
include(vcpkg_common_functions)
-include(${CMAKE_CURRENT_LIST_DIR}/qca_load_qtenv.cmake)
find_program(GIT git)
@@ -39,48 +38,51 @@ message(STATUS "Adding worktree done")
set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/)
-# Apply the patch to install 'crypto' and 'cmake targets' folder
+# Apply the patch to install to the expected folders
vcpkg_apply_patches(
SOURCE_PATH ${SOURCE_PATH}
PATCHES ${CMAKE_CURRENT_LIST_DIR}/0001-fix-path-for-vcpkg.patch
)
+# Configure and build
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
CURRENT_PACKAGES_DIR ${CURRENT_PACKAGES_DIR}
OPTIONS
- #-DSOURCE=${SOURCE_PATH}
-DBUILD_SHARED_LIBS=ON
-DUSE_RELATIVE_PATHS=ON
-DQT4_BUILD=OFF
-DBUILD_TESTS=OFF
-DBUILD_TOOLS=OFF
- -DQCA_SUFFIX=qt5
+ -DQCA_SUFFIX=OFF #
OPTIONS_DEBUG
- -DQCA_PLUGINS_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/debug/bin/Qca-qt5
+ -DQCA_PLUGINS_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/debug/bin/Qca #
OPTIONS_RELEASE
- -DQCA_PLUGINS_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/bin/Qca-qt5
+ -DQCA_PLUGINS_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/bin/Qca #
)
vcpkg_install_cmake()
+# Patch and copy cmake files
message(STATUS "Patching files")
-file(RENAME
- ${CURRENT_PACKAGES_DIR}/debug/share/cmake/Qca-qt5/Qca-qt5Targets-debug.cmake
- ${CURRENT_PACKAGES_DIR}/share/cmake/Qca-qt5/Qca-qt5Targets-debug.cmake
+file(READ
+ ${CURRENT_PACKAGES_DIR}/debug/share/qca/cmake/QcaTargets-debug.cmake
+ QCA_DEBUG_CONFIG
)
-
-set(T_DEBUG ${CURRENT_PACKAGES_DIR}/share/cmake/Qca-qt5/Qca-qt5Targets-debug.cmake)
-set(T_TARGETS ${CURRENT_PACKAGES_DIR}/share/cmake/Qca-qt5/Qca-qt5Targets.cmake)
-
-file(READ ${T_DEBUG} QCA_DEBUG_CONFIG)
string(REPLACE "\${_IMPORT_PREFIX}" "\${_IMPORT_PREFIX}/debug" QCA_DEBUG_CONFIG "${QCA_DEBUG_CONFIG}")
-file(WRITE ${T_DEBUG} "${QCA_DEBUG_CONFIG}")
+file(WRITE
+ ${CURRENT_PACKAGES_DIR}/share/qca/cmake/QcaTargets-debug.cmake
+ "${QCA_DEBUG_CONFIG}"
+)
-file(READ ${T_TARGETS} QCA_TARGET_CONFIG)
+file(READ ${CURRENT_PACKAGES_DIR}/share/qca/cmake/QcaTargets.cmake
+ QCA_TARGET_CONFIG
+)
string(REPLACE "packages/qca_" "installed/" QCA_TARGET_CONFIG "${QCA_TARGET_CONFIG}")
-file(WRITE ${T_TARGETS} "${QCA_TARGET_CONFIG}")
+file(WRITE ${CURRENT_PACKAGES_DIR}/share/qca/cmake/QcaTargets.cmake
+ "${QCA_TARGET_CONFIG}"
+)
# Remove unneeded dirs
file(REMOVE_RECURSE