aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNancyLi1013 <46708020+NancyLi1013@users.noreply.github.com>2019-05-18 14:48:40 -0700
committerRobert Schumacher <roschuma@microsoft.com>2019-05-18 14:48:40 -0700
commit469543f9429e6b8f0699cb17d6309f127ae8eb59 (patch)
treee5c21450b334fc3b4526d37f61e70749775bd2e4
parenta462daf2518a8f5ae23bfb3b1b41cd29043a64e2 (diff)
downloadvcpkg-469543f9429e6b8f0699cb17d6309f127ae8eb59.tar.gz
vcpkg-469543f9429e6b8f0699cb17d6309f127ae8eb59.zip
[aliyun-oss-c-sdk] Add new port (#6441)
* [aliyun-oss-c-sdk] Add new port * [aliyun-oss-c-sdk] Update the CONTROL file and add the dependency.
-rw-r--r--ports/aliyun-oss-c-sdk/CONTROL4
-rw-r--r--ports/aliyun-oss-c-sdk/patch.patch12
-rw-r--r--ports/aliyun-oss-c-sdk/portfile.cmake26
3 files changed, 42 insertions, 0 deletions
diff --git a/ports/aliyun-oss-c-sdk/CONTROL b/ports/aliyun-oss-c-sdk/CONTROL
new file mode 100644
index 000000000..430541401
--- /dev/null
+++ b/ports/aliyun-oss-c-sdk/CONTROL
@@ -0,0 +1,4 @@
+Source: aliyun-oss-c-sdk
+Version: 3.7.1-1
+Description: Alibaba Cloud Object Storage Service (OSS) is a cloud storage service provided by Alibaba Cloud, featuring massive capacity, security, a low cost, and high reliability.
+Build-Depends: curl, apr-util
diff --git a/ports/aliyun-oss-c-sdk/patch.patch b/ports/aliyun-oss-c-sdk/patch.patch
new file mode 100644
index 000000000..31c18d897
--- /dev/null
+++ b/ports/aliyun-oss-c-sdk/patch.patch
@@ -0,0 +1,12 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 0abcb93..75195a9 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -150,5 +150,5 @@ INSTALL(FILES
+ oss_c_sdk/oss_xml.h
+ DESTINATION include/oss_c_sdk)
+
+-add_subdirectory(oss_c_sdk_sample)
+-add_subdirectory(oss_c_sdk_test)
++#add_subdirectory(oss_c_sdk_sample)
++#add_subdirectory(oss_c_sdk_test)
diff --git a/ports/aliyun-oss-c-sdk/portfile.cmake b/ports/aliyun-oss-c-sdk/portfile.cmake
new file mode 100644
index 000000000..2e3a2c73e
--- /dev/null
+++ b/ports/aliyun-oss-c-sdk/portfile.cmake
@@ -0,0 +1,26 @@
+include(vcpkg_common_functions)
+
+if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
+ message(FATAL_ERROR "${PORT} does not currently support UWP")
+endif()
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO aliyun/aliyun-oss-c-sdk
+ REF 3.7.1
+ SHA512 0c289832d87ea7fae60d0846617bc839a1529ab6d59c2bb520e2826b0374953e8078179c4043c5c85a56c38985189aa584036104a504da4cf1ea2d35a53c8fde
+ HEAD_REF master
+ PATCHES
+ patch.patch
+)
+
+vcpkg_configure_cmake(
+ SOURCE_PATH ${SOURCE_PATH}
+ PREFER_NINJA
+)
+
+vcpkg_install_cmake()
+
+file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
+file(COPY ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT}/)
+file(RENAME ${CURRENT_PACKAGES_DIR}/share/${PORT}/LICENSE ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright)