nodejs/deps/zstd/unofficial.gni
Cheng 44e2671b44
build: fix GN build failure
PR-URL: https://github.com/nodejs/node/pull/57013
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
2025-02-15 12:11:49 +00:00

29 lines
922 B
Plaintext

# This file is used by GN for building, which is NOT the build system used for
# building official binaries.
# Please edit the gyp files if you are making changes to build system.
# The actual configurations are put inside a template in unofficial.gni to
# prevent accidental edits from contributors.
template("zstd_gn_build") {
config("zstd_config") {
include_dirs = [ "./lib" ]
}
gypi_values = exec_script("../../tools/gypi_to_gn.py",
[ rebase_path("zstd.gyp") ],
"scope",
[ "zstd.gyp" ])
source_set(target_name) {
forward_variables_from(invoker, "*")
public_configs = [ ":zstd_config" ]
sources = gypi_values.zstd_sources
defines = [ "XXH_NAMESPACE=ZSTD_", "ZSTD_MULTITHREAD", "ZSTD_DISABLE_ASM" ]
cflags_c = [ "-Wno-unused-function" ]
if (is_posix) {
ldflags = [ "-pthread" ]
}
}
}