head 1.1; branch 1.1.1; access; symbols netbsd-11:1.1.1.1.0.2 brotli-1-2-1:1.1.1.1 GOOGLE:1.1.1; locks; strict; comment @# @; 1.1 date 2026.10.28.21.11.59; author mrg; state Exp; branches 1.1.1.1; next ; commitid 3cPg6n1vuoDZUh1H; 1.1.1.1 date 2026.10.28.21.11.59; author mrg; state Exp; branches 1.1.1.1.2.1; next ; commitid 3cPg6n1vuoDZUh1H; 1.1.1.1.2.1 date 2026.10.28.21.11.59; author martin; state dead; branches; next 1.1.1.1.2.2; commitid Zd6vMoBhuWqLbo1H; 1.1.1.1.2.2 date 2026.10.29.16.03.48; author martin; state Exp; branches; next ; commitid Zd6vMoBhuWqLbo1H; desc @@ 1.1 log @Initial revision @ text @# Description: # Brotli is a generic-purpose lossless compression algorithm. package( default_visibility = ["//visibility:public"], ) licenses(["notice"]) # MIT exports_files(["LICENSE"]) config_setting( name = "clang-cl", flag_values = { "@@bazel_tools//tools/cpp:compiler": "clang-cl", }, visibility = ["//visibility:public"], ) config_setting( name = "msvc", flag_values = { "@@bazel_tools//tools/cpp:compiler": "msvc-cl", }, visibility = ["//visibility:public"], ) STRICT_C_OPTIONS = select({ ":msvc": [], ":clang-cl": [ "/W4", "-Wconversion", "-Wlong-long", "-Wmissing-declarations", "-Wmissing-prototypes", "-Wno-strict-aliasing", "-Wshadow", "-Wsign-compare", "-Wno-sign-conversion", ], "//conditions:default": [ "--pedantic-errors", "-Wall", "-Wconversion", "-Werror", "-Wextra", "-Wlong-long", "-Wmissing-declarations", "-Wmissing-prototypes", "-Wno-strict-aliasing", "-Wshadow", "-Wsign-compare", ], }) filegroup( name = "public_headers", srcs = glob(["c/include/brotli/*.h"]), ) filegroup( name = "common_headers", srcs = glob(["c/common/*.h"]), ) filegroup( name = "common_sources", srcs = glob(["c/common/*.c"]), ) filegroup( name = "dec_headers", srcs = glob(["c/dec/*.h"]), ) filegroup( name = "dec_sources", srcs = glob(["c/dec/*.c"]), ) filegroup( name = "enc_headers", srcs = glob(["c/enc/*.h"]), ) filegroup( name = "enc_sources", srcs = glob(["c/enc/*.c"]), ) cc_library( name = "brotli_inc", hdrs = [":public_headers"], copts = STRICT_C_OPTIONS, strip_include_prefix = "c/include", ) cc_library( name = "brotlicommon", srcs = [":common_sources"], hdrs = [":common_headers"], copts = STRICT_C_OPTIONS, deps = [":brotli_inc"], ) cc_library( name = "brotlidec", srcs = [":dec_sources"], hdrs = [":dec_headers"], copts = STRICT_C_OPTIONS, deps = [":brotlicommon"], ) cc_library( name = "brotlienc", srcs = [":enc_sources"], hdrs = [":enc_headers"], copts = STRICT_C_OPTIONS, linkopts = select({ ":clang-cl": [], ":msvc": [], "//conditions:default": ["-lm"], }), deps = [":brotlicommon"], ) cc_binary( name = "brotli", srcs = ["c/tools/brotli.c"], copts = STRICT_C_OPTIONS, linkstatic = 1, deps = [ ":brotlidec", ":brotlienc", ], ) filegroup( name = "dictionary", srcs = ["c/common/dictionary.bin"], ) @ 1.1.1.1 log @Initial import of brotli 1.2.1, that fixes CVE 2026-111497. also includes enhancements in dictionary handling, static init of some data to reduce size, and minor other clean ups. the new go and python code, as well as the ignored C encoder are not included in this import as we don't use them, and they are more than half the space. @ text @@ 1.1.1.1.2.1 log @file BUILD.bazel was added on branch netbsd-11 on 2026-10-29 16:03:48 +0000 @ text @d1 141 @ 1.1.1.1.2.2 log @Pull up the following, requested by mrg in ticket #562: external/mit/brotli/dist/BUILD.bazel up to 1.1.1.1 external/mit/brotli/dist/c/common/dictionary_inc.h up to 1.1.1.1 external/mit/brotli/dist/c/common/shared_dictionary.c up to 1.1.1.1 external/mit/brotli/dist/c/common/shared_dictionary_internal.h up to 1.1.1.1 external/mit/brotli/dist/c/common/static_init.h up to 1.1.1.1 external/mit/brotli/dist/c/dec/prefix.c up to 1.1.1.1 external/mit/brotli/dist/c/dec/prefix_inc.h up to 1.1.1.1 external/mit/brotli/dist/c/dec/static_init.c up to 1.1.1.1 external/mit/brotli/dist/c/dec/static_init.h up to 1.1.1.1 external/mit/brotli/dist/c/include/brotli/shared_dictionary.h up to 1.1.1.1 external/mit/brotli/dist/docs/brotli.svg up to 1.1.1.1 external/mit/brotli/dist/scripts/download_testdata.sh up to 1.1.1.1 external/mit/brotli/dist/tests/testdata/zerosukkanooa.compressed up to 1.1.1.1 external/mit/brotli/dist/tests/cli_test.sh up to 1.1.1.1 external/mit/brotli/dist/SECURITY.md up to 1.1.1.1 external/mit/brotli/dist/.bazelignore up to 1.1.1.1 external/mit/brotli/dist/CHANGELOG.md up to 1.1.1.1 external/mit/brotli/dist/BUILD delete external/mit/brotli/dist/Makefile delete external/mit/brotli/dist/Makefile.am delete external/mit/brotli/dist/WORKSPACE delete external/mit/brotli/dist/bootstrap delete external/mit/brotli/dist/compiler_config_setting.bzl delete external/mit/brotli/dist/configure delete external/mit/brotli/dist/configure-cmake delete external/mit/brotli/dist/configure.ac delete external/mit/brotli/dist/premake5.lua delete external/mit/brotli/dist/c/enc/backward_references.c delete external/mit/brotli/dist/c/enc/backward_references.h delete external/mit/brotli/dist/c/enc/backward_references_hq.c delete external/mit/brotli/dist/c/enc/backward_references_hq.h delete external/mit/brotli/dist/c/enc/backward_references_inc.h delete external/mit/brotli/dist/c/enc/bit_cost.c delete external/mit/brotli/dist/c/enc/bit_cost.h delete external/mit/brotli/dist/c/enc/bit_cost_inc.h delete external/mit/brotli/dist/c/enc/block_encoder_inc.h delete external/mit/brotli/dist/c/enc/block_splitter.c delete external/mit/brotli/dist/c/enc/block_splitter.h delete external/mit/brotli/dist/c/enc/block_splitter_inc.h delete external/mit/brotli/dist/c/enc/brotli_bit_stream.c delete external/mit/brotli/dist/c/enc/brotli_bit_stream.h delete external/mit/brotli/dist/c/enc/cluster.c delete external/mit/brotli/dist/c/enc/cluster.h delete external/mit/brotli/dist/c/enc/cluster_inc.h delete external/mit/brotli/dist/c/enc/command.c delete external/mit/brotli/dist/c/enc/command.h delete external/mit/brotli/dist/c/enc/compress_fragment.c delete external/mit/brotli/dist/c/enc/compress_fragment.h delete external/mit/brotli/dist/c/enc/compress_fragment_two_pass.c delete external/mit/brotli/dist/c/enc/compress_fragment_two_pass.h delete external/mit/brotli/dist/c/enc/dictionary_hash.c delete external/mit/brotli/dist/c/enc/dictionary_hash.h delete external/mit/brotli/dist/c/enc/encode.c delete external/mit/brotli/dist/c/enc/encoder_dict.c delete external/mit/brotli/dist/c/enc/encoder_dict.h delete external/mit/brotli/dist/c/enc/entropy_encode.c delete external/mit/brotli/dist/c/enc/entropy_encode.h delete external/mit/brotli/dist/c/enc/entropy_encode_static.h delete external/mit/brotli/dist/c/enc/fast_log.c delete external/mit/brotli/dist/c/enc/fast_log.h delete external/mit/brotli/dist/c/enc/find_match_length.h delete external/mit/brotli/dist/c/enc/hash.h delete external/mit/brotli/dist/c/enc/hash_composite_inc.h delete external/mit/brotli/dist/c/enc/hash_forgetful_chain_inc.h delete external/mit/brotli/dist/c/enc/hash_longest_match64_inc.h delete external/mit/brotli/dist/c/enc/hash_longest_match_inc.h delete external/mit/brotli/dist/c/enc/hash_longest_match_quickly_inc.h delete external/mit/brotli/dist/c/enc/hash_rolling_inc.h delete external/mit/brotli/dist/c/enc/hash_to_binary_tree_inc.h delete external/mit/brotli/dist/c/enc/histogram.c delete external/mit/brotli/dist/c/enc/histogram.h delete external/mit/brotli/dist/c/enc/histogram_inc.h delete external/mit/brotli/dist/c/enc/literal_cost.c delete external/mit/brotli/dist/c/enc/literal_cost.h delete external/mit/brotli/dist/c/enc/memory.c delete external/mit/brotli/dist/c/enc/memory.h delete external/mit/brotli/dist/c/enc/metablock.c delete external/mit/brotli/dist/c/enc/metablock.h delete external/mit/brotli/dist/c/enc/metablock_inc.h delete external/mit/brotli/dist/c/enc/params.h delete external/mit/brotli/dist/c/enc/prefix.h delete external/mit/brotli/dist/c/enc/quality.h delete external/mit/brotli/dist/c/enc/utf8_util.c delete external/mit/brotli/dist/c/enc/ringbuffer.h delete external/mit/brotli/dist/c/enc/static_dict.c delete external/mit/brotli/dist/c/enc/static_dict.h delete external/mit/brotli/dist/c/enc/static_dict_lut.h delete external/mit/brotli/dist/c/enc/utf8_util.h delete external/mit/brotli/dist/c/enc/write_bits.h delete external/mit/brotli/dist/python/Makefile delete external/mit/brotli/dist/python/README.md delete external/mit/brotli/dist/python/_brotli.cc delete external/mit/brotli/dist/python/bro.py delete external/mit/brotli/dist/python/brotli.py delete external/mit/brotli/dist/python/tests/__init__.py delete external/mit/brotli/dist/python/tests/_test_utils.py delete external/mit/brotli/dist/python/tests/bro_test.py delete external/mit/brotli/dist/python/tests/compress_test.py delete external/mit/brotli/dist/python/tests/compressor_test.py delete external/mit/brotli/dist/python/tests/decompress_test.py delete external/mit/brotli/dist/python/tests/decompressor_test.py delete external/mit/brotli/dist/scripts/sources.lst delete external/mit/brotli/dist/tests/Makefile delete external/mit/brotli/dist/tests/compatibility_test.sh delete external/mit/brotli/dist/tests/roundtrip_test.sh delete external/mit/brotli/dist/CMakeLists.txt up to 1.1.1.2 external/mit/brotli/dist/CONTRIBUTING.md up to 1.1.1.2 external/mit/brotli/dist/MANIFEST.in up to 1.1.1.2 external/mit/brotli/dist/README up to 1.1.1.2 external/mit/brotli/dist/README.md up to 1.1.1.2 external/mit/brotli/dist/setup.cfg up to 1.1.1.2 external/mit/brotli/dist/setup.py up to 1.1.1.2 external/mit/brotli/dist/c/common/constants.c up to 1.1.1.2 external/mit/brotli/dist/c/common/constants.h up to 1.1.1.2 external/mit/brotli/dist/c/common/context.c up to 1.1.1.2 external/mit/brotli/dist/c/common/context.h up to 1.1.1.2 external/mit/brotli/dist/c/common/dictionary.c up to 1.1.1.2 external/mit/brotli/dist/c/common/dictionary.h up to 1.1.1.2 external/mit/brotli/dist/c/common/platform.c up to 1.1.1.2 external/mit/brotli/dist/c/common/platform.h up to 1.2 external/mit/brotli/dist/c/common/transform.c up to 1.1.1.2 external/mit/brotli/dist/c/common/transform.h up to 1.1.1.2 external/mit/brotli/dist/c/common/version.h up to 1.1.1.2 external/mit/brotli/dist/c/dec/bit_reader.c up to 1.1.1.2 external/mit/brotli/dist/c/dec/bit_reader.h up to 1.1.1.2 external/mit/brotli/dist/c/dec/decode.c up to 1.1.1.2 external/mit/brotli/dist/c/dec/huffman.c up to 1.1.1.2 external/mit/brotli/dist/c/dec/huffman.h up to 1.1.1.2 external/mit/brotli/dist/c/dec/prefix.h up to 1.1.1.2 external/mit/brotli/dist/c/dec/state.c up to 1.1.1.2 external/mit/brotli/dist/c/dec/state.h up to 1.1.1.2 external/mit/brotli/dist/c/include/brotli/decode.h up to 1.1.1.2 external/mit/brotli/dist/c/include/brotli/encode.h up to 1.1.1.2 external/mit/brotli/dist/c/include/brotli/port.h up to 1.1.1.2 external/mit/brotli/dist/c/include/brotli/types.h up to 1.1.1.2 external/mit/brotli/dist/c/tools/brotli.c up to 1.1.1.2 external/mit/brotli/dist/c/tools/brotli.md up to 1.1.1.2 external/mit/brotli/dist/docs/brotli.1 up to 1.1.1.2 external/mit/brotli/dist/docs/constants.h.3 up to 1.1.1.2 external/mit/brotli/dist/docs/decode.h.3 up to 1.1.1.2 external/mit/brotli/dist/docs/encode.h.3 up to 1.1.1.2 external/mit/brotli/dist/docs/types.h.3 up to 1.1.1.2 external/mit/brotli/dist/scripts/libbrotlicommon.pc.in up to 1.1.1.2 external/mit/brotli/dist/scripts/libbrotlidec.pc.in up to 1.1.1.2 external/mit/brotli/dist/scripts/libbrotlienc.pc.in up to 1.1.1.2 Initial import of brotli 1.2.1, that fixes CVE 2026-111497. @ text @a0 141 # Description: # Brotli is a generic-purpose lossless compression algorithm. package( default_visibility = ["//visibility:public"], ) licenses(["notice"]) # MIT exports_files(["LICENSE"]) config_setting( name = "clang-cl", flag_values = { "@@bazel_tools//tools/cpp:compiler": "clang-cl", }, visibility = ["//visibility:public"], ) config_setting( name = "msvc", flag_values = { "@@bazel_tools//tools/cpp:compiler": "msvc-cl", }, visibility = ["//visibility:public"], ) STRICT_C_OPTIONS = select({ ":msvc": [], ":clang-cl": [ "/W4", "-Wconversion", "-Wlong-long", "-Wmissing-declarations", "-Wmissing-prototypes", "-Wno-strict-aliasing", "-Wshadow", "-Wsign-compare", "-Wno-sign-conversion", ], "//conditions:default": [ "--pedantic-errors", "-Wall", "-Wconversion", "-Werror", "-Wextra", "-Wlong-long", "-Wmissing-declarations", "-Wmissing-prototypes", "-Wno-strict-aliasing", "-Wshadow", "-Wsign-compare", ], }) filegroup( name = "public_headers", srcs = glob(["c/include/brotli/*.h"]), ) filegroup( name = "common_headers", srcs = glob(["c/common/*.h"]), ) filegroup( name = "common_sources", srcs = glob(["c/common/*.c"]), ) filegroup( name = "dec_headers", srcs = glob(["c/dec/*.h"]), ) filegroup( name = "dec_sources", srcs = glob(["c/dec/*.c"]), ) filegroup( name = "enc_headers", srcs = glob(["c/enc/*.h"]), ) filegroup( name = "enc_sources", srcs = glob(["c/enc/*.c"]), ) cc_library( name = "brotli_inc", hdrs = [":public_headers"], copts = STRICT_C_OPTIONS, strip_include_prefix = "c/include", ) cc_library( name = "brotlicommon", srcs = [":common_sources"], hdrs = [":common_headers"], copts = STRICT_C_OPTIONS, deps = [":brotli_inc"], ) cc_library( name = "brotlidec", srcs = [":dec_sources"], hdrs = [":dec_headers"], copts = STRICT_C_OPTIONS, deps = [":brotlicommon"], ) cc_library( name = "brotlienc", srcs = [":enc_sources"], hdrs = [":enc_headers"], copts = STRICT_C_OPTIONS, linkopts = select({ ":clang-cl": [], ":msvc": [], "//conditions:default": ["-lm"], }), deps = [":brotlicommon"], ) cc_binary( name = "brotli", srcs = ["c/tools/brotli.c"], copts = STRICT_C_OPTIONS, linkstatic = 1, deps = [ ":brotlidec", ":brotlienc", ], ) filegroup( name = "dictionary", srcs = ["c/common/dictionary.bin"], ) @