diff options
| author | Konnov Konstantin <panter.dsd@gmail.com> | 2020-05-27 08:11:06 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-05-26 22:11:06 -0700 |
| commit | a95a5022aecd513b247f069d9055709f43319a7a (patch) | |
| tree | 50d7821ed015e94cff73affe77f8cd1a5db34f04 | |
| parent | 6ca5fb670a5ae70eeeae326f90d0560c935a1c11 (diff) | |
| download | vcpkg-a95a5022aecd513b247f069d9055709f43319a7a.tar.gz vcpkg-a95a5022aecd513b247f069d9055709f43319a7a.zip | |
[protobuf] Fix RPATH error for static build (#11504)
* [protobuf] Fix RPATH error for static build.
* Update version
Co-authored-by: Konstantin Konnov <konstantin.konnov@litmus.io>
| -rw-r--r-- | ports/protobuf/CONTROL | 4 | ||||
| -rw-r--r-- | ports/protobuf/fix-static-build.patch | 13 | ||||
| -rw-r--r-- | ports/protobuf/portfile.cmake | 1 |
3 files changed, 16 insertions, 2 deletions
diff --git a/ports/protobuf/CONTROL b/ports/protobuf/CONTROL index 1b8551bf5..5a72ae6fb 100644 --- a/ports/protobuf/CONTROL +++ b/ports/protobuf/CONTROL @@ -1,8 +1,8 @@ Source: protobuf -Version: 3.12.0 +Version: 3.12.0-1 Homepage: https://github.com/google/protobuf Description: Protocol Buffers - Google's data interchange format Feature: zlib Description: ZLib based features like Gzip streams -Build-Depends: zlib
\ No newline at end of file +Build-Depends: zlib diff --git a/ports/protobuf/fix-static-build.patch b/ports/protobuf/fix-static-build.patch new file mode 100644 index 000000000..22d99435c --- /dev/null +++ b/ports/protobuf/fix-static-build.patch @@ -0,0 +1,13 @@ +diff --git a/cmake/install.cmake b/cmake/install.cmake +index be47c54..8b1bd97 100644 +--- a/cmake/install.cmake ++++ b/cmake/install.cmake +@@ -31,7 +31,7 @@ endforeach() + if (protobuf_BUILD_PROTOC_BINARIES) + install(TARGETS protoc EXPORT protobuf-targets + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT protoc) +- if (UNIX AND NOT APPLE) ++ if (UNIX AND NOT APPLE AND NOT protobuf_MSVC_STATIC_RUNTIME) + set_property(TARGET protoc + PROPERTY INSTALL_RPATH "$ORIGIN/../${CMAKE_INSTALL_LIBDIR}") + elseif (APPLE) diff --git a/ports/protobuf/portfile.cmake b/ports/protobuf/portfile.cmake index 230e0b9cd..8ddd9fe23 100644 --- a/ports/protobuf/portfile.cmake +++ b/ports/protobuf/portfile.cmake @@ -7,6 +7,7 @@ vcpkg_from_github( PATCHES fix-uwp.patch fix-android-log.patch + fix-static-build.patch ) if(CMAKE_HOST_WIN32 AND NOT VCPKG_TARGET_ARCHITECTURE MATCHES "x64" AND NOT VCPKG_TARGET_ARCHITECTURE MATCHES "x86") |
