2 GITHUB_ORG_URI := https://github.com/yaml
3 TEST_SUITE_URL := $(GITHUB_ORG_URI)/yaml-test-suite
4 LIBYAML_DIR ?= $(PWD)/libyaml-parser-emitter/libyaml
9 @echo 'test - Run the tests'
10 @echo 'clean - Remove generated files'
11 @echo 'help - Show help'
13 # Depends on parser and emitter but, building parser will also build emitter.
14 # Building twice makes things fail. Note: Some environments like on OS X, the
15 # shell resets the {DY,}LD_LIBRARY_PATH vars, so we work around it like so:
16 test: data src/libyaml-parser
17 (export MY_LD_LIBRARY_PATH=$(LIBYAML_DIR)/src/.libs; prove -lv test)
23 git clone $(TEST_SUITE_URL) $@ --branch=$@
25 %/libyaml-parser %/libyaml-emitter: %
26 (cd $<; make clean build)
27 (cd $<; make clean build)
29 libyaml-parser-emitter:
30 git clone $(GITHUB_ORG_URI)/$@ $@