summaryrefslogtreecommitdiff
path: root/.Makefile.inc
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-06-01 14:25:23 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-06-01 14:25:23 +0000
commit828011aeaf136e67fb69ce16fb4265667ccda008 (patch)
tree7c8359e766cb52c6005196718be2edde1aea1936 /.Makefile.inc
parentad13d2293ae8b4353d8051abe63f063622ca623a (diff)
Makefile updates: Fix BSD make conditionals
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11397 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to '.Makefile.inc')
-rw-r--r--.Makefile.inc30
1 files changed, 15 insertions, 15 deletions
diff --git a/.Makefile.inc b/.Makefile.inc
index 1b2010e33..0a51ad40d 100644
--- a/.Makefile.inc
+++ b/.Makefile.inc
@@ -6,22 +6,21 @@
# Please do not edit unless you know what you're doing.
#
-COMPILE_ROOT = $(shell pwd)
+@GNU_ONLY COMPILE_ROOT = $(shell pwd)
+@BSD_ONLY COMPILE_ROOT != pwd
-ifdef D
- ifeq ("$(origin D)", "command line")
+@IFDEF D
NICEFLAGS = @DEVELOPER@
HEADER = debug-header
- endif
-endif
+@ENDIF
-ifndef NICEFLAGS
+@IFNDEF NICEFLAGS
NICEFLAGS = @FLAGS@
-endif
+@ENDIF
-ifndef HEADER
+@IFNDEF HEADER
HEADER = std-header
-endif
+@ENDIF
NICEFLAGS += -I$(COMPILE_ROOT)/include
@@ -36,16 +35,17 @@ LAUNCHDPATH = "/System/Library/LaunchDaemons"
LIBPATH = "@LIBRARY_DIR@"
MODULES = @MODULES@
INSTMODE = 0755
-MAKEFLAGS += --no-print-directory
+@GNU_ONLY MAKEFLAGS += --no-print-directory
-ifdef V
+@IFDEF V
RUNCC = $(CC)
-else
- MAKEFLAGS += --silent
+@ELSE
+ @GNU_ONLY MAKEFLAGS += --silent
RUNCC = $(COMPILE_ROOT)/make/run-cc.pl $(CC)
-endif
+@ENDIF
-export COMPILE_ROOT RUNCC FLAGS NICEFLAGS CC LDLIBS MODULES MODPATH LIBPATH INSTMODE
+@GNU_ONLY export COMPILE_ROOT RUNCC FLAGS NICEFLAGS CC LDLIBS MODULES MODPATH LIBPATH INSTMODE
+@BSD_ONLY MAKEARGS = -s 'RUNCC=${RUNCC}' 'FLAGS=${FLAGS}' 'NICEFLAGS=${NICEFLAGS}' 'CC=${CC}' 'LDLIBS=${LDLIBS}' 'MODULES=${MODULES}' 'MODPATH=${MODPATH}' 'LIBPATH=${LIBPATH}' 'INSTMODE=${INSTMODE}'
all: ircd mods finishmessage