diff options
| author | NancyLi1013 <46708020+NancyLi1013@users.noreply.github.com> | 2020-06-02 07:02:26 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-06-01 16:02:26 -0700 |
| commit | c954caf7bc1499f168e8deb3138937e633747ffe (patch) | |
| tree | b3a089b1e6ec5c5aa914873094b64d8a037e07c9 | |
| parent | 53a17b9885ec11df9df64ef4c2e42a060b3d754a (diff) | |
| download | vcpkg-c954caf7bc1499f168e8deb3138937e633747ffe.tar.gz vcpkg-c954caf7bc1499f168e8deb3138937e633747ffe.zip | |
[gli] Add CMake config support (#11634)
* [gli] Add cmake config support
* Disable test
| -rw-r--r-- | ports/gli/CONTROL | 4 | ||||
| -rw-r--r-- | ports/gli/disable-test.patch | 13 | ||||
| -rw-r--r-- | ports/gli/portfile.cmake | 23 |
3 files changed, 31 insertions, 9 deletions
diff --git a/ports/gli/CONTROL b/ports/gli/CONTROL index 6ba55d18d..ffd0ea804 100644 --- a/ports/gli/CONTROL +++ b/ports/gli/CONTROL @@ -1,5 +1,5 @@ Source: gli -Version: dd17acf +Version: dd17acf-1 Build-Depends: glm Description: OpenGL Image (GLI) -Homepage: https://gli.g-truc.net +Homepage: https://gli.g-truc.net
\ No newline at end of file diff --git a/ports/gli/disable-test.patch b/ports/gli/disable-test.patch new file mode 100644 index 000000000..d6bf0d7ce --- /dev/null +++ b/ports/gli/disable-test.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 6eb1a68..610c0bc 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -71,7 +71,7 @@ endmacro(addExternalPackageGTC)
+ # Add subdirectory
+
+ add_subdirectory(gli)
+-add_subdirectory(test)
++#add_subdirectory(test)
+ #add_subdirectory(doc)
+
+ ################################
diff --git a/ports/gli/portfile.cmake b/ports/gli/portfile.cmake index beae5e530..c958eb95b 100644 --- a/ports/gli/portfile.cmake +++ b/ports/gli/portfile.cmake @@ -1,5 +1,4 @@ #header-only library -include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH @@ -7,13 +6,23 @@ vcpkg_from_github( REF dd17acf9cc7fc6e6abe9f9ec69949eeeee1ccd82 SHA512 9e3a4ab9ee73d5c271b8346cf81339cd3cd0c20d20991524b816313b6a99e8d3a01863316a38cf1a52ef9c5b31d689ecccf6248b12d1d270460c048bf904650b HEAD_REF master + PATCHES + disable-test.patch ) +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA +) + +vcpkg_install_cmake() + +vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/gli TARGET_PATH share/gli) + +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib) +file(REMOVE ${CURRENT_PACKAGES_DIR}/include/gli/CMakeLists.txt) + # Put the license file where vcpkg expects it # manual.md contains the "licenses" section for the project -file(COPY ${SOURCE_PATH}/manual.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/gli/) -file(RENAME ${CURRENT_PACKAGES_DIR}/share/gli/manual.md ${CURRENT_PACKAGES_DIR}/share/gli/copyright) - -# Copy the glm header files -file(GLOB HEADER_FILES "${SOURCE_PATH}/gli/*.hpp" "${SOURCE_PATH}/gli/core") -file(COPY ${HEADER_FILES} DESTINATION ${CURRENT_PACKAGES_DIR}/include/gli) +file(INSTALL ${SOURCE_PATH}/manual.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
\ No newline at end of file |
