# Some SCONS shortcuts
#----------------------------------------------------------------------
-CONCURRENCY_LEVEL ?= 2
+SCONS=./tools/scons
-ifdef final
- FINAL = "final=1"
-endif
+# DON'T call this default ... default is a valid scons target ;-)
+build: default
+.PHONY: build
-SCONS=scons -j $(CONCURRENCY_LEVEL) $(FINAL)
-
-default: build
-
-build:
- $(SCONS)
-
-clean:
+clean: message
$(SCONS) --clean all
+.PHONY: clean
-all_docs all_tests all:
- $(SCONS) $@
-
-%/test %/doc:
- $(SCONS) $@
+Makefile:
+ @true
-#----------------------------------------------------------------------
-# Subversion stuff
-#----------------------------------------------------------------------
-
-svn_version:
- @svnversion
-
-#----------------------------------------------------------------------
-# Building SENF requires some debian packages
-#----------------------------------------------------------------------
-DEB_BASE = build-essential
+# Forward everything else to scons
+%: message
+ $(SCONS) $@
-# This line parses the 'Build-Depends' entry from debian/control
-DEB_SENF = $(shell perl -an -F'[:,]' -e ' \
- BEGIN{ $$,=" " } \
- $$P=0 if /^\S/; \
- map {s/\(.*\)//} @F; \
- print @F if $$P; \
- if (/^Build-Depends:/) { print @F[1..$$\#F]; $$P=1 }' \
- debian/control | xargs echo)
+message:
+ @echo "================================================================="
+ @echo "SENF uses SCons as it's build system, so instead of calling"
+ @echo " $$ make <target>"
+ @echo
+ @echo "use"
+ @echo " $$ ./tools/scons <target>"
+ @echo
+ @echo "To get help on valid targets an configuration variables, call"
+ @echo " $$ ./tools/scons -h"
+ @echo
+ @echo "To get help on scons command line options, call"
+ @echo " $$ ./tools/scons -H"
+ @echo
+ @echo "(interesting options: -c, -U, -j <num-cpus>, --config=force)"
+ @echo "================================================================="
+ sleep 5
prerequisites:
- aptitude install $(DEB_BASE) $(DEB_SENF)
-
-package:
- $(SCONS) deb
+ ./debian/install-depends.sh
+.PHONY: prerequisites