diff options
Diffstat (limited to 'core/SCsub')
-rw-r--r-- | core/SCsub | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/core/SCsub b/core/SCsub index 43deff3ad5..a0176f6c33 100644 --- a/core/SCsub +++ b/core/SCsub @@ -64,6 +64,31 @@ thirdparty_misc_sources = [ thirdparty_misc_sources = [thirdparty_misc_dir + file for file in thirdparty_misc_sources] env_thirdparty.add_source_files(thirdparty_obj, thirdparty_misc_sources) +# Brotli +if env["brotli"]: + thirdparty_brotli_dir = "#thirdparty/brotli/" + thirdparty_brotli_sources = [ + "common/constants.c", + "common/context.c", + "common/dictionary.c", + "common/platform.c", + "common/shared_dictionary.c", + "common/transform.c", + "dec/bit_reader.c", + "dec/decode.c", + "dec/huffman.c", + "dec/state.c", + ] + thirdparty_brotli_sources = [thirdparty_brotli_dir + file for file in thirdparty_brotli_sources] + + env_thirdparty.Prepend(CPPPATH=[thirdparty_brotli_dir + "include"]) + env.Prepend(CPPPATH=[thirdparty_brotli_dir + "include"]) + + if env.get("use_ubsan") or env.get("use_asan") or env.get("use_tsan") or env.get("use_lsan") or env.get("use_msan"): + env_thirdparty.Append(CPPDEFINES=["BROTLI_BUILD_PORTABLE"]) + + env_thirdparty.add_source_files(thirdparty_obj, thirdparty_brotli_sources) + # Zlib library, can be unbundled if env["builtin_zlib"]: thirdparty_zlib_dir = "#thirdparty/zlib/" |