diff options
| author | Thierry Bastian <thierryb@filewave.com> | 2017-09-01 13:42:51 +0200 |
|---|---|---|
| committer | Thierry Bastian <thierryb@filewave.com> | 2017-09-01 13:42:51 +0200 |
| commit | a610f62587fa9caac9a70f5d17305284c441dad3 (patch) | |
| tree | b02b78e1b1a605c1179f11ed0943511ea9f2f02d | |
| parent | 03edddef2402d7a578c7714b6b28d3734e3d3940 (diff) | |
| download | vcpkg-a610f62587fa9caac9a70f5d17305284c441dad3.tar.gz vcpkg-a610f62587fa9caac9a70f5d17305284c441dad3.zip | |
protobuf: switching to 3.4
| -rw-r--r-- | ports/protobuf/0001-fix-missing-export.patch | 13 | ||||
| -rw-r--r-- | ports/protobuf/001-add-compiler-flag.patch | 25 | ||||
| -rw-r--r-- | ports/protobuf/portfile.cmake | 9 |
3 files changed, 20 insertions, 27 deletions
diff --git a/ports/protobuf/0001-fix-missing-export.patch b/ports/protobuf/0001-fix-missing-export.patch deleted file mode 100644 index c7d5ff6c8..000000000 --- a/ports/protobuf/0001-fix-missing-export.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/src/google/protobuf/generated_message_util.h b/src/google/protobuf/generated_message_util.h -index 4417446..a7154b4 100644 ---- a/src/google/protobuf/generated_message_util.h -+++ b/src/google/protobuf/generated_message_util.h -@@ -164,7 +164,7 @@ class ExplicitlyConstructed { - - // Default empty string object. Don't use this directly. Instead, call - // GetEmptyString() to get the reference. --extern ExplicitlyConstructed< ::std::string> fixed_address_empty_string; -+LIBPROTOBUF_EXPORT extern ExplicitlyConstructed< ::std::string> fixed_address_empty_string; - LIBPROTOBUF_EXPORT extern ProtobufOnceType empty_string_once_init_; - LIBPROTOBUF_EXPORT void InitEmptyString(); - diff --git a/ports/protobuf/001-add-compiler-flag.patch b/ports/protobuf/001-add-compiler-flag.patch index aec510f44..dd1285cea 100644 --- a/ports/protobuf/001-add-compiler-flag.patch +++ b/ports/protobuf/001-add-compiler-flag.patch @@ -1,14 +1,13 @@ diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt -index 7618ba21..bd92b09d 100644 +index 7618ba2..d282a60 100644 --- a/cmake/CMakeLists.txt +++ b/cmake/CMakeLists.txt -@@ -165,8 +165,11 @@ endif (protobuf_UNICODE) +@@ -165,8 +165,10 @@ endif (protobuf_UNICODE) include(libprotobuf-lite.cmake) include(libprotobuf.cmake) -include(libprotoc.cmake) -include(protoc.cmake) -+ +if(protobuf_BUILD_COMPILER) + include(libprotoc.cmake) + include(protoc.cmake) @@ -16,18 +15,26 @@ index 7618ba21..bd92b09d 100644 if (protobuf_BUILD_TESTS) include(tests.cmake) + diff --git a/cmake/install.cmake b/cmake/install.cmake -index 28dc90dc..52c1f721 100644 +index 441bf55..4158820 100644 --- a/cmake/install.cmake +++ b/cmake/install.cmake -@@ -1,9 +1,12 @@ +@@ -1,14 +1,17 @@ include(GNUInstallDirs) +-configure_file(${CMAKE_CURRENT_SOURCE_DIR}/protobuf.pc.cmake +set(LIBRARIES_TO_SET_DEST libprotobuf-lite libprotobuf) +if(protobuf_BUILD_COMPILER) + list(APPEND LIBRARIES_TO_SET_DEST libprotoc) +endif() + ++configure_file(${CMAKE_CURRENT_SOURCE_DIR}/libprotobuf.cmake + ${CMAKE_CURRENT_BINARY_DIR}/protobuf.pc @ONLY) +-configure_file(${CMAKE_CURRENT_SOURCE_DIR}/protobuf-lite.pc.cmake ++configure_file(${CMAKE_CURRENT_SOURCE_DIR}/libprotobuf-lite.cmake + ${CMAKE_CURRENT_BINARY_DIR}/protobuf-lite.pc @ONLY) + foreach(_library - libprotobuf-lite - libprotobuf @@ -36,7 +43,7 @@ index 28dc90dc..52c1f721 100644 set_property(TARGET ${_library} PROPERTY INTERFACE_INCLUDE_DIRECTORIES $<BUILD_INTERFACE:${protobuf_source_dir}/src> -@@ -14,8 +17,10 @@ foreach(_library +@@ -19,8 +22,10 @@ foreach(_library ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT ${_library}) endforeach() @@ -47,9 +54,9 @@ index 28dc90dc..52c1f721 100644 + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT protoc) +endif() - file(STRINGS extract_includes.bat.in _extract_strings - REGEX "^copy") -@@ -94,7 +99,12 @@ configure_file(protobuf-options.cmake + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/protobuf.pc ${CMAKE_CURRENT_BINARY_DIR}/protobuf-lite.pc DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig") + +@@ -101,7 +106,12 @@ configure_file(protobuf-options.cmake ${CMAKE_INSTALL_CMAKEDIR}/protobuf-options.cmake @ONLY) # Allows the build directory to be used as a find directory. diff --git a/ports/protobuf/portfile.cmake b/ports/protobuf/portfile.cmake index fa81e0542..daf72a495 100644 --- a/ports/protobuf/portfile.cmake +++ b/ports/protobuf/portfile.cmake @@ -1,16 +1,16 @@ include(vcpkg_common_functions) -set(PROTOBUF_VERSION 3.3.0) +set(PROTOBUF_VERSION 3.4.0) vcpkg_download_distfile(ARCHIVE_FILE URLS "https://github.com/google/protobuf/releases/download/v${PROTOBUF_VERSION}/protobuf-cpp-${PROTOBUF_VERSION}.tar.gz" FILENAME "protobuf-cpp-${PROTOBUF_VERSION}.tar.gz" - SHA512 ef01300bdda4a1a33a6056aea1d55e9d66ab1ca644aa2d9d5633cfc0bccfe4c24fdfa1015889b2c1c568e89ad053c701de1aca45196a6439130b7bb8f461595f + SHA512 ce9bd9bc818c4a8e8b08c83e8a4eba6fca008a64a5ad9d322b19683b1de2b5fa622ed99093323f3c9d0820ef23430f7ee07f6930f7f877d334e5d36df9b0be0e ) vcpkg_download_distfile(TOOL_ARCHIVE_FILE URLS "https://github.com/google/protobuf/releases/download/v${PROTOBUF_VERSION}/protoc-${PROTOBUF_VERSION}-win32.zip" FILENAME "protoc-${PROTOBUF_VERSION}-win32.zip" - SHA512 9b4902b3187fb978a8153aaf050314a3ca9ca161b0712a3672ccdfabb7f5a57035e71c2dfde9a0b99f9417e159dcbdedaf9a2b1917d712dc3d9d554bba0d4ee8 + SHA512 b874c3f47b39ac78f5675e05220318683004a365c248bf47ba50d8c66c8ed7763432451bab30524e131e1185a2bdaa6e6071b389eb61ad58b1b95974cf39d41b ) set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/protobuf-${PROTOBUF_VERSION}) @@ -23,8 +23,7 @@ vcpkg_extract_source_archive(${ARCHIVE_FILE}) # Add a flag that can be set to disable the protobuf compiler vcpkg_apply_patches( SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/protobuf-${PROTOBUF_VERSION} - PATCHES "${CMAKE_CURRENT_LIST_DIR}/0001-fix-missing-export.patch" - "${CMAKE_CURRENT_LIST_DIR}/001-add-compiler-flag.patch" + PATCHES "${CMAKE_CURRENT_LIST_DIR}/001-add-compiler-flag.patch" ) |
