aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/ponder
diff options
context:
space:
mode:
Diffstat (limited to 'vcpkg/ports/ponder')
-rw-r--r--vcpkg/ports/ponder/github-121.patch21
-rw-r--r--vcpkg/ports/ponder/no-install-unused.patch27
-rw-r--r--vcpkg/ports/ponder/portfile.cmake39
-rw-r--r--vcpkg/ports/ponder/vcpkg.json17
4 files changed, 104 insertions, 0 deletions
diff --git a/vcpkg/ports/ponder/github-121.patch b/vcpkg/ports/ponder/github-121.patch
new file mode 100644
index 0000000..e756442
--- /dev/null
+++ b/vcpkg/ports/ponder/github-121.patch
@@ -0,0 +1,21 @@
+From 83b292f263b92082e981a82f5777d927a61772ee Mon Sep 17 00:00:00 2001
+From: Cheney-Wang <v-xincwa@microsoft.com>
+Date: Fri, 13 Mar 2020 02:50:33 -0700
+Subject: [PATCH] Include <ostream> in config.h
+
+---
+ include/ponder/config.hpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/include/ponder/config.hpp b/include/ponder/config.hpp
+index cd035c19..814403cd 100644
+--- a/include/ponder/config.hpp
++++ b/include/ponder/config.hpp
+@@ -60,6 +60,7 @@
+ #if defined(_MSC_VER)
+ #pragma warning(disable: 4275) // non dll-interface class 'X' used as base for dll-interface class 'Y'
+ #pragma warning(disable: 4251) // class 'X' needs to have dll-interface to be used by clients of class 'Y'
++ #include <ostream> //In future MSVC, <string> doesn't transitively <ostream>, ponder will compile failed with error C2027 and C2065, so add <ostream> for fixing these issues.
+ #endif
+
+ #if defined(__GNUC__) && __GNUC__ <= 4 && __GNUC_MINOR__ < 9
diff --git a/vcpkg/ports/ponder/no-install-unused.patch b/vcpkg/ports/ponder/no-install-unused.patch
new file mode 100644
index 0000000..e540dd9
--- /dev/null
+++ b/vcpkg/ports/ponder/no-install-unused.patch
@@ -0,0 +1,27 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 091f56d..715f86e 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -325,14 +325,14 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/PonderConfig.cmake ${CMAKE_CURRENT_BIN
+ COMPONENT devel
+ )
+
+-install(FILES README.md COPYING.txt
+- DESTINATION ${INSTALL_MISC_DIR}
+-)
+-
+-install(DIRECTORY cmake
+- DESTINATION ${INSTALL_MISC_DIR}
+- COMPONENT utils
+-)
++#install(FILES README.md COPYING.txt
++# DESTINATION ${INSTALL_MISC_DIR}
++#)
++
++#install(DIRECTORY cmake
++# DESTINATION ${INSTALL_MISC_DIR}
++# COMPONENT utils
++#)
+
+ ###############################
+ # packaging
diff --git a/vcpkg/ports/ponder/portfile.cmake b/vcpkg/ports/ponder/portfile.cmake
new file mode 100644
index 0000000..94eede7
--- /dev/null
+++ b/vcpkg/ports/ponder/portfile.cmake
@@ -0,0 +1,39 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO billyquith/ponder
+ REF 3.0.0
+ SHA512 b6ba1ce9fa0584b16085c56afb70e31f204a66b57193c1a4225bfe18abbda561bb71b3279dd0a4f1b21867b985ef5ce78c8e360f3fc654c61ce61c44d35c5f38
+ HEAD_REF master
+ PATCHES
+ no-install-unused.patch
+ github-121.patch
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ DISABLE_PARALLEL_CONFIGURE
+ OPTIONS
+ -DUSES_RAPIDJSON=OFF
+ -DUSES_RAPIDXML=OFF
+ -DBUILD_TEST=OFF
+)
+
+vcpkg_cmake_install()
+
+vcpkg_cmake_config_fixup(CONFIG_PATH lib/${PORT}/cmake)
+vcpkg_fixup_pkgconfig()
+
+file(REMOVE_RECURSE
+ "${CURRENT_PACKAGES_DIR}/debug/include"
+ "${CURRENT_PACKAGES_DIR}/debug/lib/${PORT}"
+ "${CURRENT_PACKAGES_DIR}/debug/share"
+ "${CURRENT_PACKAGES_DIR}/lib/${PORT}"
+)
+
+if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
+ vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/${PORT}/config.hpp" "ifndef PONDER_STATIC" "if 0 //ifndef PONDER_STATIC")
+endif()
+
+# Handle copyright
+configure_file("${SOURCE_PATH}/COPYING.txt" "${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright" COPYONLY)
+
diff --git a/vcpkg/ports/ponder/vcpkg.json b/vcpkg/ports/ponder/vcpkg.json
new file mode 100644
index 0000000..b881cb9
--- /dev/null
+++ b/vcpkg/ports/ponder/vcpkg.json
@@ -0,0 +1,17 @@
+{
+ "name": "ponder",
+ "version": "3.0.0",
+ "port-version": 5,
+ "description": "A C++ multi-purpose reflection library.",
+ "homepage": "https://github.com/billyquith/ponder",
+ "dependencies": [
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ]
+}