aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexandro Sanchez <alexandro@phi.nz>2020-06-02 01:03:29 +0200
committerGitHub <noreply@github.com>2020-06-01 16:03:29 -0700
commit10eac5e7716311687035ef2a1fedbbb78cc48210 (patch)
tree3e82bc636d4959e86f6b4082e9a98605d5cbb630
parentc954caf7bc1499f168e8deb3138937e633747ffe (diff)
downloadvcpkg-10eac5e7716311687035ef2a1fedbbb78cc48210.tar.gz
vcpkg-10eac5e7716311687035ef2a1fedbbb78cc48210.zip
[freerdp] Optional 'urbdrc' feature (#11639)
Signed-off-by: Alexandro Sanchez Bach <alexandro@phi.nz>
-rw-r--r--ports/freerdp/CONTROL8
-rw-r--r--ports/freerdp/portfile.cmake13
2 files changed, 15 insertions, 6 deletions
diff --git a/ports/freerdp/CONTROL b/ports/freerdp/CONTROL
index 4a0cadf16..6191d0fbb 100644
--- a/ports/freerdp/CONTROL
+++ b/ports/freerdp/CONTROL
@@ -1,5 +1,9 @@
Source: freerdp
-Version: 2.0.0
+Version: 2.0.0-1
Homepage: https://github.com/FreeRDP/FreeRDP
Description: A free implementation of the Remote Desktop Protocol (RDP)
-Build-Depends: openssl, libusb, glib (!windows)
+Build-Depends: openssl, glib (!windows)
+
+Feature: urbdrc
+Description: USB redirection channel support
+Build-Depends: libusb
diff --git a/ports/freerdp/portfile.cmake b/ports/freerdp/portfile.cmake
index c4f401540..e6d9fb289 100644
--- a/ports/freerdp/portfile.cmake
+++ b/ports/freerdp/portfile.cmake
@@ -26,11 +26,16 @@ file(WRITE "${SOURCE_PATH}/.source_version" "${SOURCE_VERSION}-vcpkg")
file(REMOVE ${SOURCE_PATH}/cmake/FindOpenSSL.cmake) # Remove outdated Module
+vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
+ urbdrc CHANNEL_URBDRC
+)
+
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
OPTIONS
${FREERDP_CRT_LINKAGE}
+ ${FEATURE_OPTIONS}
)
vcpkg_install_cmake()
@@ -53,13 +58,13 @@ if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
file(COPY ${FREERDP_DLL} DESTINATION ${CURRENT_PACKAGES_DIR}/bin)
file(REMOVE ${FREERDP_DLL})
endforeach()
-
+
file(GLOB_RECURSE FREERDP_DLLS "${CURRENT_PACKAGES_DIR}/debug/lib/*.dll")
foreach(FREERDP_DLL ${FREERDP_DLLS})
file(COPY ${FREERDP_DLL} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin)
file(REMOVE ${FREERDP_DLL})
endforeach()
-else()
+else()
file(GLOB_RECURSE FREERDP_TOOLS "${CURRENT_PACKAGES_DIR}/bin/*")
foreach(FREERDP_TOOL ${FREERDP_TOOLS})
file(COPY ${FREERDP_TOOL} DESTINATION ${CURRENT_PACKAGES_DIR}/tools/${PORT})
@@ -112,7 +117,7 @@ vcpkg_replace_string(${CURRENT_PACKAGES_DIR}/share/FreeRDP-Client/FreeRDP-Client
"bin/freerdp-client2${VCPKG_TARGET_SHARED_LIBRARY_SUFFIX}"
)
-if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
+if(VCPKG_TARGET_IS_WINDOWS AND VCPKG_LIBRARY_LINKAGE STREQUAL "static")
file(GLOB OBJS ${CURRENT_PACKAGES_DIR}/debug/*.lib)
file(REMOVE ${OBJS})
file(GLOB OBJS ${CURRENT_PACKAGES_DIR}/*.lib)
@@ -124,4 +129,4 @@ file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include
${CURRENT_PACKAGES_DIR}/debug/lib/cmake
${CURRENT_PACKAGES_DIR}/lib/cmake)
-file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright) \ No newline at end of file
+file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)