diff options
| -rw-r--r-- | ports/coolprop/CONTROL | 2 | ||||
| -rw-r--r-- | ports/coolprop/fmt-fix.patch | 39 | ||||
| -rw-r--r-- | ports/coolprop/portfile.cmake | 10 |
3 files changed, 46 insertions, 5 deletions
diff --git a/ports/coolprop/CONTROL b/ports/coolprop/CONTROL index 72ccae87b..01e67e0df 100644 --- a/ports/coolprop/CONTROL +++ b/ports/coolprop/CONTROL @@ -1,4 +1,4 @@ Source: coolprop -Version: 6.1.0-3 +Version: 6.1.0-4 Description: Thermophysical properties for the masses Build-Depends: catch, eigen3, pybind11, if97, fmt, rapidjson, msgpack, refprop-headers diff --git a/ports/coolprop/fmt-fix.patch b/ports/coolprop/fmt-fix.patch new file mode 100644 index 000000000..bf2d11deb --- /dev/null +++ b/ports/coolprop/fmt-fix.patch @@ -0,0 +1,39 @@ +diff --git a/include/CPstrings.h b/include/CPstrings.h
+index 2e5a5af..87f6b7c 100644
+--- a/include/CPstrings.h
++++ b/include/CPstrings.h
+@@ -5,6 +5,8 @@
+ #include <iterator>
+ #include <algorithm>
+ #include <functional>
++ #include <vector>
++ #include <string>
+
+ #if !defined(NO_CPPFORMAT)
+ #ifndef FMT_HEADER_ONLY
+@@ -13,9 +15,6 @@
+ #include "fmt/format.h" // For addition of the string formatting functions and macros from cppformat
+ #include "fmt/printf.h" // For sprintf
+ #undef FMT_HEADER_ONLY
+-#else
+- #include <vector>
+- #include <string>
+ #endif
+
+ #include "Exceptions.h"
+@@ -57,11 +56,11 @@
+ // Missing string formatting function, this old guy is needed for ancient gcc compilers on PowerPC for VxWorks
+ inline std::string format(const char* fmt, ...);
+ #else
+- // Missing std::string formatting function - provided by the cppformat library
+- inline std::string format(const char *format, fmt::ArgList args) {
+- return fmt::sprintf(format, args);
++ template<class...Args>
++ std::string format(const Args & ... args)
++ {
++ return fmt::sprintf(args...);
+ }
+- FMT_VARIADIC(std::string, format, const char *)
+ #endif
+
+ // Missing string split - like in Python
diff --git a/ports/coolprop/portfile.cmake b/ports/coolprop/portfile.cmake index c5b3a8cee..2406ea819 100644 --- a/ports/coolprop/portfile.cmake +++ b/ports/coolprop/portfile.cmake @@ -7,6 +7,8 @@ vcpkg_from_github( REF 0e934e842e9ce83eea64fda1d4ab8e59adf9d8cd SHA512 a44eafc84f2b88259d7bcf6cfa81daeb81ea9d55bd356e59b3ef77b6f68ea405961c7cb54ba899e3896bb2a02d3e01119a4a51f72899126c8da6081fa2ece948 HEAD_REF master + PATCHES + ${CMAKE_CURRENT_LIST_DIR}/fmt-fix.patch ) vcpkg_find_acquire_program(PYTHON2) @@ -16,8 +18,8 @@ set(ENV{PATH} "$ENV{PATH};${PYTHON2_DIR}") file(REMOVE_RECURSE ${SOURCE_PATH}/externals) # Patch up the file locations -file(COPY - ${CURRENT_INSTALLED_DIR}/include/catch.hpp +file(COPY + ${CURRENT_INSTALLED_DIR}/include/catch.hpp DESTINATION ${SOURCE_PATH}/externals/Catch/single_include ) @@ -30,12 +32,12 @@ file(COPY DESTINATION ${SOURCE_PATH}/externals/Eigen/unsupported ) -file(COPY +file(COPY ${CURRENT_INSTALLED_DIR}/include/rapidjson DESTINATION ${SOURCE_PATH}/externals/rapidjson/include ) -file(COPY +file(COPY ${CURRENT_INSTALLED_DIR}/include/IF97.h DESTINATION ${SOURCE_PATH}/externals/IF97 ) |
