ayaports/user/protobuf/exclude.patch

41 lines
1.5 KiB
Diff
Raw Normal View History

2023-11-28 23:47:03 +00:00
don't install the utf8_range lib into disk.
also remove it from .pc/cmake, it's statically linked into protobuf and never needed on disk after
--
diff --git a/cmake/install.cmake b/cmake/install.cmake
index e7eb210..73e1897 100644
--- a/cmake/install.cmake
+++ b/cmake/install.cmake
@@ -4,7 +4,6 @@ foreach(_target IN LISTS protobuf_ABSL_USED_TARGETS)
string(REPLACE :: _ _modified_target ${_target})
list(APPEND _pc_targets ${_modified_target})
endforeach()
-list(APPEND _pc_targets "utf8_range")
set(_protobuf_PC_REQUIRES "")
set(_sep "")
diff --git a/cmake/protobuf-config.cmake.in b/cmake/protobuf-config.cmake.in
index 44805c7..1a8d243 100644
--- a/cmake/protobuf-config.cmake.in
+++ b/cmake/protobuf-config.cmake.in
@@ -4,7 +4,6 @@ include("${CMAKE_CURRENT_LIST_DIR}/protobuf-options.cmake")
# Depend packages
@_protobuf_FIND_ZLIB@
@_protobuf_FIND_ABSL@
-@_protobuf_FIND_UTF8_RANGE@
# Imported targets
include("${CMAKE_CURRENT_LIST_DIR}/protobuf-targets.cmake")
diff --git a/cmake/utf8_range.cmake b/cmake/utf8_range.cmake
index f411a8c..770f94c 100644
--- a/cmake/utf8_range.cmake
+++ b/cmake/utf8_range.cmake
@@ -8,7 +8,7 @@ if (NOT TARGET utf8_range)
endif()
set(utf8_range_ENABLE_INSTALL ${protobuf_INSTALL} CACHE BOOL "Set install")
- add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/third_party/utf8_range third_party/utf8_range)
+ add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/third_party/utf8_range third_party/utf8_range EXCLUDE_FROM_ALL)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/third_party/utf8_range)
endif ()