mirror of
https://github.com/google/brotli.git
synced 2024-11-08 13:20:05 +00:00
Remove the underscore in the name of brotli libraries. #326
This commit is contained in:
parent
85817beba8
commit
ed2748abbf
14
BUILD
14
BUILD
@ -66,7 +66,7 @@ cc_library(
|
|||||||
)
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "brotli_common",
|
name = "brotlicommon",
|
||||||
srcs = [":common_sources"],
|
srcs = [":common_sources"],
|
||||||
hdrs = [":common_headers"],
|
hdrs = [":common_headers"],
|
||||||
copts = STRICT_C_OPTIONS,
|
copts = STRICT_C_OPTIONS,
|
||||||
@ -74,20 +74,20 @@ cc_library(
|
|||||||
)
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "brotli_dec",
|
name = "brotlidec",
|
||||||
srcs = [":dec_sources"],
|
srcs = [":dec_sources"],
|
||||||
hdrs = [":dec_headers"],
|
hdrs = [":dec_headers"],
|
||||||
copts = STRICT_C_OPTIONS,
|
copts = STRICT_C_OPTIONS,
|
||||||
deps = [":brotli_common"],
|
deps = [":brotlicommon"],
|
||||||
)
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "brotli_enc",
|
name = "brotlienc",
|
||||||
srcs = [":enc_sources"],
|
srcs = [":enc_sources"],
|
||||||
hdrs = [":enc_headers"],
|
hdrs = [":enc_headers"],
|
||||||
copts = STRICT_C_OPTIONS,
|
copts = STRICT_C_OPTIONS,
|
||||||
linkopts = ["-lm"],
|
linkopts = ["-lm"],
|
||||||
deps = [":brotli_common"],
|
deps = [":brotlicommon"],
|
||||||
)
|
)
|
||||||
|
|
||||||
cc_binary(
|
cc_binary(
|
||||||
@ -96,7 +96,7 @@ cc_binary(
|
|||||||
copts = STRICT_C_OPTIONS,
|
copts = STRICT_C_OPTIONS,
|
||||||
linkstatic = 1,
|
linkstatic = 1,
|
||||||
deps = [
|
deps = [
|
||||||
":brotli_dec",
|
":brotlidec",
|
||||||
":brotli_enc",
|
":brotlienc",
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
|
@ -106,7 +106,7 @@ endif()
|
|||||||
unset(LOG2_RES)
|
unset(LOG2_RES)
|
||||||
|
|
||||||
set(BROTLI_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/include")
|
set(BROTLI_INCLUDE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}/include")
|
||||||
set(BROTLI_LIBRARIES_CORE brotli_enc brotli_dec brotli_common)
|
set(BROTLI_LIBRARIES_CORE brotlienc brotlidec brotlicommon)
|
||||||
set(BROTLI_LIBRARIES ${BROTLI_LIBRARIES_CORE} ${LIBM_LIBRARY})
|
set(BROTLI_LIBRARIES ${BROTLI_LIBRARIES_CORE} ${LIBM_LIBRARY})
|
||||||
mark_as_advanced(BROTLI_INCLUDE_DIRS BROTLI_LIBRARIES)
|
mark_as_advanced(BROTLI_INCLUDE_DIRS BROTLI_LIBRARIES)
|
||||||
|
|
||||||
@ -118,14 +118,14 @@ elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
|
|||||||
add_definitions(-DOS_MACOSX)
|
add_definitions(-DOS_MACOSX)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_library(brotli_common
|
add_library(brotlicommon
|
||||||
common/dictionary.c)
|
common/dictionary.c)
|
||||||
add_library(brotli_dec
|
add_library(brotlidec
|
||||||
dec/bit_reader.c
|
dec/bit_reader.c
|
||||||
dec/decode.c
|
dec/decode.c
|
||||||
dec/huffman.c
|
dec/huffman.c
|
||||||
dec/state.c)
|
dec/state.c)
|
||||||
add_library(brotli_enc
|
add_library(brotlienc
|
||||||
enc/backward_references.c
|
enc/backward_references.c
|
||||||
enc/bit_cost.c
|
enc/bit_cost.c
|
||||||
enc/block_splitter.c
|
enc/block_splitter.c
|
||||||
@ -145,7 +145,7 @@ add_library(brotli_enc
|
|||||||
# Older CMake versions does not understand INCLUDE_DIRECTORIES property.
|
# Older CMake versions does not understand INCLUDE_DIRECTORIES property.
|
||||||
include_directories(${BROTLI_INCLUDE_DIRS})
|
include_directories(${BROTLI_INCLUDE_DIRS})
|
||||||
|
|
||||||
foreach(lib brotli_common brotli_dec brotli_enc)
|
foreach(lib brotlicommon brotlidec brotlienc)
|
||||||
target_link_libraries(${lib} ${LIBM_LIBRARY})
|
target_link_libraries(${lib} ${LIBM_LIBRARY})
|
||||||
set_property(TARGET ${lib} APPEND PROPERTY INCLUDE_DIRECTORIES ${BROTLI_INCLUDE_DIRS})
|
set_property(TARGET ${lib} APPEND PROPERTY INCLUDE_DIRECTORIES ${BROTLI_INCLUDE_DIRS})
|
||||||
set_target_properties(${lib} PROPERTIES
|
set_target_properties(${lib} PROPERTIES
|
||||||
@ -155,8 +155,8 @@ foreach(lib brotli_common brotli_dec brotli_enc)
|
|||||||
set_property(TARGET ${lib} APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${BROTLI_INCLUDE_DIRS}")
|
set_property(TARGET ${lib} APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${BROTLI_INCLUDE_DIRS}")
|
||||||
endforeach()
|
endforeach()
|
||||||
if (BUILD_SHARED_LIBS)
|
if (BUILD_SHARED_LIBS)
|
||||||
target_link_libraries(brotli_dec brotli_common)
|
target_link_libraries(brotlidec brotlicommon)
|
||||||
target_link_libraries(brotli_enc brotli_common)
|
target_link_libraries(brotlienc brotlicommon)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# For projects stuck on older versions of CMake, this will set the
|
# For projects stuck on older versions of CMake, this will set the
|
||||||
|
28
premake5.lua
28
premake5.lua
@ -26,46 +26,46 @@ configuration "linux"
|
|||||||
configuration { "macosx" }
|
configuration { "macosx" }
|
||||||
defines { "OS_MACOSX" }
|
defines { "OS_MACOSX" }
|
||||||
|
|
||||||
project "brotli_common"
|
project "brotlicommon"
|
||||||
kind "SharedLib"
|
kind "SharedLib"
|
||||||
language "C"
|
language "C"
|
||||||
files { "common/**.h", "common/**.c" }
|
files { "common/**.h", "common/**.c" }
|
||||||
|
|
||||||
project "brotli_common_static"
|
project "brotlicommon_static"
|
||||||
kind "StaticLib"
|
kind "StaticLib"
|
||||||
targetname "brotli_common"
|
targetname "brotlicommon"
|
||||||
language "C"
|
language "C"
|
||||||
files { "common/**.h", "common/**.c" }
|
files { "common/**.h", "common/**.c" }
|
||||||
|
|
||||||
project "brotli_dec"
|
project "brotlidec"
|
||||||
kind "SharedLib"
|
kind "SharedLib"
|
||||||
language "C"
|
language "C"
|
||||||
files { "dec/**.h", "dec/**.c" }
|
files { "dec/**.h", "dec/**.c" }
|
||||||
links "brotli_common"
|
links "brotlicommon"
|
||||||
|
|
||||||
project "brotli_dec_static"
|
project "brotlidec_static"
|
||||||
kind "StaticLib"
|
kind "StaticLib"
|
||||||
targetname "brotli_dec"
|
targetname "brotlidec"
|
||||||
language "C"
|
language "C"
|
||||||
files { "dec/**.h", "dec/**.c" }
|
files { "dec/**.h", "dec/**.c" }
|
||||||
links "brotli_common_static"
|
links "brotlicommon_static"
|
||||||
|
|
||||||
project "brotli_enc"
|
project "brotlienc"
|
||||||
kind "SharedLib"
|
kind "SharedLib"
|
||||||
language "C"
|
language "C"
|
||||||
files { "enc/**.h", "enc/**.c" }
|
files { "enc/**.h", "enc/**.c" }
|
||||||
links "brotli_common"
|
links "brotlicommon"
|
||||||
|
|
||||||
project "brotli_enc_static"
|
project "brotlienc_static"
|
||||||
kind "StaticLib"
|
kind "StaticLib"
|
||||||
targetname "brotli_enc"
|
targetname "brotlienc"
|
||||||
language "C"
|
language "C"
|
||||||
files { "enc/**.h", "enc/**.c" }
|
files { "enc/**.h", "enc/**.c" }
|
||||||
links "brotli_common_static"
|
links "brotlicommon_static"
|
||||||
|
|
||||||
project "bro"
|
project "bro"
|
||||||
kind "ConsoleApp"
|
kind "ConsoleApp"
|
||||||
language "C"
|
language "C"
|
||||||
linkoptions "-static"
|
linkoptions "-static"
|
||||||
files { "tools/bro.c" }
|
files { "tools/bro.c" }
|
||||||
links { "brotli_common_static", "brotli_dec_static", "brotli_enc_static" }
|
links { "brotlicommon_static", "brotlidec_static", "brotlienc_static" }
|
||||||
|
Loading…
Reference in New Issue
Block a user