From 81786900f287ee8315c5af5d85a4cebbeefd944a Mon Sep 17 00:00:00 2001 From: adamdunkels Date: Thu, 18 Jun 2009 08:42:08 +0000 Subject: [PATCH] Makefile for automated nightly building of example code --- tools/release-tools/compile-examples/Makefile | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 tools/release-tools/compile-examples/Makefile diff --git a/tools/release-tools/compile-examples/Makefile b/tools/release-tools/compile-examples/Makefile new file mode 100644 index 000000000..e5c0038db --- /dev/null +++ b/tools/release-tools/compile-examples/Makefile @@ -0,0 +1,32 @@ +all: + @rm -f *.output + @echo Compiling on: + @uname -a + @$(MAKE) -s -k compile || cat *.output + +compile: rime-examples energest-demo shell hello-world \ + ipso-ipv6-raven jcreate multi-threading sky sky-ip sky-shell \ + webserver-ipv6 webserver-ipv6-raven + +energest-demo: example-energest-demo.sky +shell: example-example-shell.native example-example-shell.netsim +hello-world: example-hello-world.sky example-hello-world.native \ + example-hello-world.netsim example-hello-world.minimal-net example-hello-world.msb430 +rime-examples: example-rime.sky example-rime.netsim example-rime.esb +ipso-ipv6-raven: example-ipso-ipv6-raven.raven +jcreate: example-jcreate.sky +multi-threading: example-multi-threading.sky \ + example-multi-threading.native example-multi-threading.msb430 +sky: example-sky.sky +sky-ip: example-sky-ip.sky +sky-shell: example-sky-shell.sky +webserver-ipv6: example-webserver-ipv6.sky +webserver-ipv6-raven: example-webserver-ipv6-raven.avr-raven + +example-%: + @((echo; echo ------------------- $* -------------------; \ + cd ../../../examples/${basename $*} ; $(MAKE) TARGET=${subst .,,${suffix $*}} clean;\ + ($(MAKE) TARGET=${subst .,,${suffix $*}} > /dev/null 2>&1 ) ; \ + $(MAKE) TARGET=${subst .,,${suffix $*}}) > $*.output 2>&1 && echo "$* succeeded" && rm $*.output) || \ + (echo; echo "$* failed"; exit 1) +# (cd ../../../examples/${basename $*}; make TARGET=${subst .,,${suffix $*}})