aboutsummaryrefslogtreecommitdiff
path: root/ports/flatbuffers
diff options
context:
space:
mode:
authorwangli28 <47812810+wangli28@users.noreply.github.com>2019-06-07 02:03:08 +0000
committerPhil Christensen <philc@microsoft.com>2019-06-06 19:03:08 -0700
commit5ef8bb9abc0f6a9551ac48006fc04b9d91cc5716 (patch)
tree7c9ddc14de53296dad369cb56c3bfa4063a09b8c /ports/flatbuffers
parentb9cf3384c38585273319ca2111629e955f8c4097 (diff)
downloadvcpkg-5ef8bb9abc0f6a9551ac48006fc04b9d91cc5716.tar.gz
vcpkg-5ef8bb9abc0f6a9551ac48006fc04b9d91cc5716.zip
[draco, flatbuffers, forge] Update to new version (#6796)
Diffstat (limited to 'ports/flatbuffers')
-rw-r--r--ports/flatbuffers/CONTROL2
-rw-r--r--ports/flatbuffers/fix-uwp-build.patch20
-rw-r--r--ports/flatbuffers/ignore_use_of_cmake_toolchain_file.patch6
-rw-r--r--ports/flatbuffers/no-werror.patch10
-rw-r--r--ports/flatbuffers/portfile.cmake9
5 files changed, 34 insertions, 13 deletions
diff --git a/ports/flatbuffers/CONTROL b/ports/flatbuffers/CONTROL
index c0b505eed..8ec903b30 100644
--- a/ports/flatbuffers/CONTROL
+++ b/ports/flatbuffers/CONTROL
@@ -1,4 +1,4 @@
Source: flatbuffers
-Version: 1.10.0-1
+Version: 1.11.0
Description: Memory Efficient Serialization Library http://google.github.io/flatbuffers/
FlatBuffers is an efficient cross platform serialization library for games and other memory constrained apps. It allows you to directly access serialized data without unpacking/parsing it first, while still having great forwards/backwards compatibility.
diff --git a/ports/flatbuffers/fix-uwp-build.patch b/ports/flatbuffers/fix-uwp-build.patch
new file mode 100644
index 000000000..7d8fe93a3
--- /dev/null
+++ b/ports/flatbuffers/fix-uwp-build.patch
@@ -0,0 +1,20 @@
+diff --git a/src/util.cpp b/src/util.cpp
+index c1bb197..658e116 100644
+--- a/src/util.cpp
++++ b/src/util.cpp
+@@ -239,9 +239,15 @@ bool ReadEnvironmentVariable(const char *var_name, std::string *_value) {
+ #ifdef _MSC_VER
+ __pragma(warning(disable : 4996)); // _CRT_SECURE_NO_WARNINGS
+ #endif
++#if _WIN32_WINNT < 0x0A00
+ auto env_str = std::getenv(var_name);
+ if (!env_str) return false;
+ if (_value) *_value = std::string(env_str);
++#else
++ //There is no support for environment variables in UWP
++ var_name; // Do nothing
++ *_value = std::string("");
++#endif
+ return true;
+ }
+
diff --git a/ports/flatbuffers/ignore_use_of_cmake_toolchain_file.patch b/ports/flatbuffers/ignore_use_of_cmake_toolchain_file.patch
index 2205f0b37..38e1f12ec 100644
--- a/ports/flatbuffers/ignore_use_of_cmake_toolchain_file.patch
+++ b/ports/flatbuffers/ignore_use_of_cmake_toolchain_file.patch
@@ -1,8 +1,8 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
-index a3388dd..699ea3b 100644
+index 119855a..945085a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
-@@ -104,7 +104,7 @@ set(FlatBuffers_GRPCTest_SRCS
+@@ -155,7 +155,7 @@ set(FlatBuffers_GRPCTest_SRCS
# source_group(Compiler FILES ${FlatBuffers_Compiler_SRCS})
# source_group(Tests FILES ${FlatBuffers_Tests_SRCS})
@@ -10,4 +10,4 @@ index a3388dd..699ea3b 100644
+if(EXISTS "${CMAKE_TOOLCHAIN_FILE}" AND NOT DEFINED VCPKG_TOOLCHAIN)
# do not apply any global settings if the toolchain
# is being configured externally
- elseif(APPLE)
+ message(STATUS "Using toolchain file: ${CMAKE_TOOLCHAIN_FILE}.")
diff --git a/ports/flatbuffers/no-werror.patch b/ports/flatbuffers/no-werror.patch
index 7c2d548b9..b354e229d 100644
--- a/ports/flatbuffers/no-werror.patch
+++ b/ports/flatbuffers/no-werror.patch
@@ -1,17 +1,18 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
-index a3388dd..f0626e5 100644
+index 119855a..6269362 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
-@@ -119,12 +119,16 @@ elseif(CMAKE_COMPILER_IS_GNUCXX)
+@@ -172,13 +172,17 @@ elseif(CMAKE_COMPILER_IS_GNUCXX)
"${CMAKE_CXX_FLAGS} -std=c++0x")
endif(CYGWIN)
set(CMAKE_CXX_FLAGS
- "${CMAKE_CXX_FLAGS} -Wall -pedantic -Werror -Wextra -Werror=shadow")
-+ "${CMAKE_CXX_FLAGS} -Wall -pedantic -Wextra -Werror=shadow")
++ "${CMAKE_CXX_FLAGS} -Wall -pedantic -Wextra -Werror=shadow")
+ set(FLATBUFFERS_PRIVATE_CXX_FLAGS "-Wold-style-cast")
if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 4.4)
if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 7.0)
set(CMAKE_CXX_FLAGS
- "${CMAKE_CXX_FLAGS} -faligned-new")
+ "${CMAKE_CXX_FLAGS} -faligned-new -Werror=implicit-fallthrough=2")
endif()
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 7.0)
+ set(CMAKE_CXX_FLAGS
@@ -20,4 +21,3 @@ index a3388dd..f0626e5 100644
set(CMAKE_CXX_FLAGS
"${CMAKE_CXX_FLAGS} -Wunused-result -Werror=unused-result -Wunused-parameter -Werror=unused-parameter")
endif()
-
diff --git a/ports/flatbuffers/portfile.cmake b/ports/flatbuffers/portfile.cmake
index e055766b6..b954affe8 100644
--- a/ports/flatbuffers/portfile.cmake
+++ b/ports/flatbuffers/portfile.cmake
@@ -5,12 +5,13 @@ vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO google/flatbuffers
- REF v1.10.0
- SHA512 b8382c8e9a45d6aca83270e93704b9ef2938e4ef9bb5165edbd8f286329e86353037ad6e54a99fd3d70b0c893d06cfd8766e00f05497e69be4b9e6c0506133d2
+ REF v1.11.0
+ SHA512 cbb2e1e6885255cc950e2fa8248b56a8bc2c6e52f6fc7ed9066e6ae5a1d53f1263594b83f4b944a672cf9d0e1e800e51ce7fa423eff45abf5056269879c286fe
HEAD_REF master
PATCHES
- ${CMAKE_CURRENT_LIST_DIR}/ignore_use_of_cmake_toolchain_file.patch
- ${CMAKE_CURRENT_LIST_DIR}/no-werror.patch
+ ignore_use_of_cmake_toolchain_file.patch
+ no-werror.patch
+ fix-uwp-build.patch
)
set(OPTIONS)