2020-09-28 08:41:18 +08:00
|
|
|
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
2023-09-26 15:28:57 +08:00
|
|
|
index 61378cd..d868883 100644
|
2020-09-28 08:41:18 +08:00
|
|
|
--- a/CMakeLists.txt
|
|
|
|
+++ b/CMakeLists.txt
|
2023-09-26 15:28:57 +08:00
|
|
|
@@ -142,14 +142,13 @@ endif()
|
2020-09-28 08:41:18 +08:00
|
|
|
|
2023-09-26 15:28:57 +08:00
|
|
|
foreach(lib ${BROTLI_LIBRARIES_CORE})
|
2020-09-28 08:41:18 +08:00
|
|
|
target_link_libraries(${lib} ${LIBM_LIBRARY})
|
|
|
|
- set_property(TARGET ${lib} APPEND PROPERTY INCLUDE_DIRECTORIES ${BROTLI_INCLUDE_DIRS})
|
|
|
|
set_target_properties(${lib} PROPERTIES
|
|
|
|
VERSION "${BROTLI_ABI_COMPATIBILITY}.${BROTLI_ABI_AGE}.${BROTLI_ABI_REVISION}"
|
|
|
|
SOVERSION "${BROTLI_ABI_COMPATIBILITY}")
|
|
|
|
if(NOT BROTLI_EMSCRIPTEN)
|
|
|
|
set_target_properties(${lib} PROPERTIES POSITION_INDEPENDENT_CODE TRUE)
|
|
|
|
endif()
|
2023-09-26 15:28:57 +08:00
|
|
|
- set_property(TARGET ${lib} APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "$<BUILD_INTERFACE:${BROTLI_INCLUDE_DIRS}>")
|
2020-09-28 08:41:18 +08:00
|
|
|
+ set_property(TARGET ${lib} APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "$<BUILD_INTERFACE:${BROTLI_INCLUDE_DIRS}>" $<INSTALL_INTERFACE:include>)
|
|
|
|
endforeach()
|
|
|
|
|
|
|
|
if(NOT BROTLI_EMSCRIPTEN)
|
2023-09-26 15:28:57 +08:00
|
|
|
@@ -176,11 +175,14 @@ target_link_libraries(brotli ${BROTLI_LIBRARIES})
|
2020-09-28 08:41:18 +08:00
|
|
|
if(NOT BROTLI_BUNDLED_MODE)
|
|
|
|
install(
|
|
|
|
TARGETS brotli
|
|
|
|
- RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}"
|
|
|
|
+ RUNTIME DESTINATION tools/brotli
|
2022-12-03 01:39:16 +08:00
|
|
|
+ BUNDLE DESTINATION tools/brotli
|
2020-09-28 08:41:18 +08:00
|
|
|
+ CONFIGURATIONS Release
|
|
|
|
)
|
|
|
|
|
|
|
|
install(
|
|
|
|
TARGETS ${BROTLI_LIBRARIES_CORE}
|
|
|
|
+ EXPORT brotli
|
|
|
|
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
|
|
|
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
|
|
|
|
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}"
|
2023-09-26 15:28:57 +08:00
|
|
|
@@ -189,7 +191,10 @@ if(NOT BROTLI_BUNDLED_MODE)
|
2020-09-28 08:41:18 +08:00
|
|
|
install(
|
|
|
|
DIRECTORY ${BROTLI_INCLUDE_DIRS}/brotli
|
|
|
|
DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}"
|
|
|
|
+ CONFIGURATIONS Release
|
|
|
|
)
|
|
|
|
+
|
2023-09-26 15:28:57 +08:00
|
|
|
+ install(EXPORT brotli FILE unofficial-brotli-config.cmake NAMESPACE unofficial::brotli:: DESTINATION share/unofficial-brotli)
|
2020-09-28 08:41:18 +08:00
|
|
|
endif() # BROTLI_BUNDLED_MODE
|
|
|
|
|
2023-09-26 15:28:57 +08:00
|
|
|
# Tests
|