diff options
| author | Alexander Karatarakis <alkarata@microsoft.com> | 2018-05-29 13:35:00 -0700 |
|---|---|---|
| committer | Alexander Karatarakis <alkarata@microsoft.com> | 2018-05-29 13:35:09 -0700 |
| commit | aca60bfbd7e557d445fe63c0252401c9be03b8e2 (patch) | |
| tree | 836648f360bd338104a71b666463e5e229376d2d /ports/coolprop/fmt-fix.patch | |
| parent | b82bbc4945a550c070af351fd769885047b54557 (diff) | |
| download | vcpkg-aca60bfbd7e557d445fe63c0252401c9be03b8e2.tar.gz vcpkg-aca60bfbd7e557d445fe63c0252401c9be03b8e2.zip | |
[coolprop] Add patch for fmt 5.0
Diffstat (limited to 'ports/coolprop/fmt-fix.patch')
| -rw-r--r-- | ports/coolprop/fmt-fix.patch | 39 |
1 files changed, 39 insertions, 0 deletions
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
|
