From 01242c5ccb5abe2cf0b1ad7ad619d606827bd4bb Mon Sep 17 00:00:00 2001 From: "dr scofield (aka dirk husemann)" Date: Thu, 3 Sep 2009 18:31:02 +0200 Subject: [PATCH] making Makefile a bit more robust: can now cope with missing ruby in a better way. --- Makefile | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 46ddc2f19e..493cdca619 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,14 @@ -NANT = $(shell if test "$$EMACS" = "t" ; then echo "nant"; else echo "./nant-color"; fi) +# hey, emacs! this is a -*- makefile -*- +# +# OpenSim makefile +# + +RUBY = $(strip $(shell which ruby 2>/dev/null)) +ifeq ($(RUBY),) +NANT = nant +else +NANT = $(shell if test "$$EMACS" = "t" ; then echo "nant"; else echo "./nant-color"; fi) +endif all: prebuild # @export PATH=/usr/local/bin:$(PATH) @@ -14,7 +24,7 @@ prebuild: clean: # @export PATH=/usr/local/bin:$(PATH) - ${NANT} clean + -${NANT} clean test: prebuild ${NANT} test