build: fix test-gc weakref build rule
authorBen Noordhuis <info@bnoordhuis.nl>
Wed, 23 Oct 2013 11:42:53 +0000 (13:42 +0200)
committerTimothy J Fontaine <tjfontaine@gmail.com>
Wed, 23 Oct 2013 16:17:32 +0000 (09:17 -0700)
Make the build rule depend on the build artifact (weakref.node) itself
rather than the directory it's built in.  Depending on the directory
means that a build failure won't trigger a rebuild on the next
invocation because the directory's timestamp has been updated.

Makefile

index b0d3375..a37c912 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -94,16 +94,16 @@ test-http1: all
 test-valgrind: all
        $(PYTHON) tools/test.py --mode=release --valgrind simple message
 
-test/gc/node_modules/weak/build:
+test/gc/node_modules/weak/build/Release/weakref.node:
        @if [ ! -f node ]; then make all; fi
        ./node deps/npm/node_modules/node-gyp/bin/node-gyp rebuild \
                --directory="$(shell pwd)/test/gc/node_modules/weak" \
                --nodedir="$(shell pwd)"
 
-test-gc: all test/gc/node_modules/weak/build
+test-gc: all test/gc/node_modules/weak/build/Release/weakref.node
        $(PYTHON) tools/test.py --mode=release gc
 
-test-all: all test/gc/node_modules/weak/build
+test-all: all test/gc/node_modules/weak/build/Release/weakref.node
        $(PYTHON) tools/test.py --mode=debug,release
        make test-npm