diff options
Diffstat (limited to 'vcpkg/ports/awlib/fix-mac-build.patch')
| -rw-r--r-- | vcpkg/ports/awlib/fix-mac-build.patch | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/vcpkg/ports/awlib/fix-mac-build.patch b/vcpkg/ports/awlib/fix-mac-build.patch new file mode 100644 index 0000000..33eabd6 --- /dev/null +++ b/vcpkg/ports/awlib/fix-mac-build.patch @@ -0,0 +1,75 @@ +diff --git a/io/include/aw/io/mmap_file.h b/io/include/aw/io/mmap_file.h +index 9846973..65e82aa 100644 +--- a/io/include/aw/io/mmap_file.h ++++ b/io/include/aw/io/mmap_file.h +@@ -83,18 +83,18 @@ using win32::file_mapping; + inline file_mode get_file_mode(map_perms perms) + { + using mp = map_perms; +- switch (perms) { +- case mp::none: +- case mp::none|mp::exec: ++ switch (static_cast<unsigned>(perms)) { ++ case static_cast<unsigned>(mp::none): ++ case static_cast<unsigned>(mp::none|mp::exec): + return file_mode::none; +- case mp::read: +- case mp::read|mp::exec: ++ case static_cast<unsigned>(mp::read): ++ case static_cast<unsigned>(mp::read|mp::exec): + return file_mode::read; +- case mp::write: ++ case static_cast<unsigned>(mp::write): + return file_mode::write; +- case mp::write|mp::exec: +- case mp::rdwr: +- case mp::rdwr|mp::exec: ++ case static_cast<unsigned>(mp::write|mp::exec): ++ case static_cast<unsigned>(mp::rdwr): ++ case static_cast<unsigned>(mp::rdwr|mp::exec): + return file_mode::read|file_mode::write; + } + +diff --git a/types/include/aw/types/bits/variant_dispatch.h b/types/include/aw/types/bits/variant_dispatch.h +index 9d5dc3b..95a9394 100644 +--- a/types/include/aw/types/bits/variant_dispatch.h ++++ b/types/include/aw/types/bits/variant_dispatch.h +@@ -71,11 +71,11 @@ struct vh_recursive { + if constexpr (Length_left > 0) + { + if (index < Mid) +- return vh_recursive<Start,Mid,Ts...>::template dispatch(index, storage, f); ++ return vh_recursive<Start,Mid,Ts...>::dispatch(index, storage, f); + } + + if constexpr (Length_right > 1) +- return vh_recursive<Mid+1,End,Ts...>::template dispatch(index, storage, f); ++ return vh_recursive<Mid+1,End,Ts...>::dispatch(index, storage, f); + + _unreachable(); + } +diff --git a/types/include/aw/types/byte_buffer.h b/types/include/aw/types/byte_buffer.h +index 82f4693..b38c46a 100644 +--- a/types/include/aw/types/byte_buffer.h ++++ b/types/include/aw/types/byte_buffer.h +@@ -8,6 +8,7 @@ + */
+ #ifndef aw_types_byte_buffer_h
+ #define aw_types_byte_buffer_h
++#include <cstdlib>
+ #include <memory>
+ namespace aw {
+ /**
+diff --git a/types/include/aw/types/containers/queue.h b/types/include/aw/types/containers/queue.h +index af8f13b..8398e8c 100644 +--- a/types/include/aw/types/containers/queue.h ++++ b/types/include/aw/types/containers/queue.h +@@ -96,7 +96,7 @@ protected: + queue_base(queue_base&& other, Allocator const& alloc) noexcept + : impl(alloc) + { +- if (alloc == other.alloc) ++ if (alloc == static_cast<Allocator&>(other.impl)) + impl.swap(other.impl); + else + create_storage(other.allocated_size()); |