2022-11-05 07:28:36 +00:00
|
|
|
{
|
|
|
|
"targets": [
|
|
|
|
{
|
|
|
|
"target_name": "kzg",
|
|
|
|
"cflags!": ["-fno-exceptions"],
|
|
|
|
"cflags_cc!": ["-fno-exceptions"],
|
2022-11-16 23:47:13 +00:00
|
|
|
"xcode_settings": {
|
|
|
|
"CLANG_CXX_LIBRARY": "libc++",
|
|
|
|
"MACOSX_DEPLOYMENT_TARGET": "13.0"
|
|
|
|
},
|
2022-11-17 00:23:06 +00:00
|
|
|
"defines": ["NAPI_DISABLE_CPP_EXCEPTIONS"],
|
2022-11-05 07:28:36 +00:00
|
|
|
"sources": ["kzg.cxx"],
|
|
|
|
"include_dirs": [
|
2022-11-05 07:46:26 +00:00
|
|
|
"<(module_root_dir)/dist/deps/blst/bindings",
|
|
|
|
"<(module_root_dir)/dist/deps/c-kzg",
|
2022-11-05 07:28:36 +00:00
|
|
|
"<!@(node -p \"require('node-addon-api').include\")"
|
|
|
|
],
|
|
|
|
"libraries": [
|
2022-11-08 01:08:21 +00:00
|
|
|
"<(module_root_dir)/c_kzg_4844.o",
|
|
|
|
"<(module_root_dir)/libblst.a"
|
2022-11-05 07:28:36 +00:00
|
|
|
],
|
|
|
|
"dependencies": ["<!(node -p \"require('node-addon-api').gyp\")"],
|
|
|
|
"actions": [
|
|
|
|
{
|
|
|
|
"action_name": "build_blst",
|
|
|
|
"inputs": ["<(module_root_dir)/dist/deps/blst/build.sh"],
|
|
|
|
"outputs": ["<(module_root_dir)/libblst.a"],
|
|
|
|
"action": ["<(module_root_dir)/dist/deps/blst/build.sh"]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"action_name": "build_ckzg",
|
|
|
|
"inputs": [
|
|
|
|
"<(module_root_dir)/dist/deps/c-kzg/c_kzg_4844.c",
|
|
|
|
"<(module_root_dir)/libblst.a"
|
|
|
|
],
|
|
|
|
"outputs": ["<(module_root_dir)/c_kzg_4844.o"],
|
|
|
|
"action": [
|
2022-11-07 19:45:36 +00:00
|
|
|
"cc",
|
2022-11-05 07:28:36 +00:00
|
|
|
"-I<(module_root_dir)/dist/deps/blst/bindings",
|
|
|
|
"-O2",
|
|
|
|
"-c",
|
|
|
|
"<(module_root_dir)/dist/deps/c-kzg/c_kzg_4844.c"
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"target_name": "action_after_build",
|
|
|
|
"type": "none",
|
|
|
|
"dependencies": ["kzg"],
|
|
|
|
"copies": [
|
|
|
|
{
|
|
|
|
"files": ["./build/Release/kzg.node"],
|
|
|
|
"destination": "./dist"
|
2022-11-08 16:38:07 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"files": ["./build/Release/kzg.node"],
|
|
|
|
"destination": "./"
|
2022-11-05 07:28:36 +00:00
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|