add Rsconsfile

This commit is contained in:
Josh Holtrop 2018-07-25 21:30:14 -04:00
parent 50cd9efd86
commit 663ed8c465
3 changed files with 10 additions and 16 deletions

1
.gitignore vendored
View File

@ -1,5 +1,6 @@
/.lock-waf* /.lock-waf*
/.waf* /.waf*
/.rsconscache
/build/ /build/
/test/tmp/ /test/tmp/
/coverage/ /coverage/

View File

@ -1,20 +1,7 @@
.PHONY: all
all: all:
./waf build --targets jes @rscons
.PHONY: clean .PHONY: clean
clean: clean:
./waf clean @rscons -c
ifneq ($(FILTER),)
GTEST_FILTER := --gtest_filter=$(FILTER)
endif
.PHONY: build_tests
build_tests:
./waf build --targets tests
.PHONY: test
test: build_tests
./build/tests $(GTEST_FILTER)
@-rm -rf coverage
-gcovinator -b build -s src

6
Rsconsfile Normal file
View File

@ -0,0 +1,6 @@
Rscons::Environment.new do |env|
env["sources"] = Dir[
"src/**/*.d",
"src/**/*.c"]
env.Program("#{env.build_root}/jes", "${sources}")
end