summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorBen Noordhuis <info@bnoordhuis.nl>2017-10-12 12:04:02 +0200
committerJoyee Cheung <joyeec9h3@gmail.com>2017-10-15 12:06:56 +0800
commit41573427445022b172f3386fa576e51e8d30c782 (patch)
treec8f6e8472f7781da88532685c1ce9decbaa3c3c2 /Makefile
parent7f55349079705a9e1d43024ed45c1351907f3d8e (diff)
downloadandroid-node-v8-41573427445022b172f3386fa576e51e8d30c782.tar.gz
android-node-v8-41573427445022b172f3386fa576e51e8d30c782.tar.bz2
android-node-v8-41573427445022b172f3386fa576e51e8d30c782.zip
build: use local node-gyp for benchmark addon
Move the logic for building the benchmark/misc/function_call to the top-level Makefile and use our local copy of node-gyp. PR-URL: https://github.com/nodejs/node/pull/16160 Fixes: https://github.com/nodejs/node/issues/16154 Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile11
1 files changed, 9 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 84b4e2c35c..755542eb07 100644
--- a/Makefile
+++ b/Makefile
@@ -227,6 +227,14 @@ test-valgrind: all
test-check-deopts: all
$(PYTHON) tools/test.py --mode=release --check-deopts parallel sequential -J
+benchmark/misc/function_call/build/Release/binding.node: all \
+ benchmark/misc/function_call/binding.cc \
+ benchmark/misc/function_call/binding.gyp
+ $(NODE) deps/npm/node_modules/node-gyp/bin/node-gyp rebuild \
+ --python="$(PYTHON)" \
+ --directory="$(shell pwd)/benchmark/misc/function_call" \
+ --nodedir="$(shell pwd)"
+
# Implicitly depends on $(NODE_EXE). We don't depend on it explicitly because
# it always triggers a rebuild due to it being a .PHONY rule. See the comment
# near the build-addons rule for more background.
@@ -904,8 +912,7 @@ bench-http: all
bench-fs: all
@$(NODE) benchmark/run.js fs
-bench-misc: all
- @$(MAKE) -C benchmark/misc/function_call/
+bench-misc: benchmark/misc/function_call/build/Release/binding.node
@$(NODE) benchmark/run.js misc
bench-array: all