[Zrouter-src] ZRouter.org: push to ZRouter Makefile

zrouter-src at zrouter.org zrouter-src at zrouter.org
Mon Jan 16 11:50:35 UTC 2012


details:   http://zrouter.org/hg/zrouter//rev/eb82a92a14b5
changeset: 315:eb82a92a14b5
user:      ray at terran.dlink.ua
date:      Mon Jan 16 13:52:07 2012 +0200
description:
Introduce local options file ${ZROUTER_ROOT}/Makefile.local.opts
That file will hold local options that must not be commited to main repo.
Someone who work with only one box, can store here main parameters.
For example:
TARGET_PAIR?=D-Link/DIR-615-E4
FREEBSD_SRC_TREE=/path/to/FreeBSD/sources

'?=' allow to override TARGET_PAIR from make command line.

diffstat:

 Makefile |  15 ++++++++++-----
 1 files changed, 10 insertions(+), 5 deletions(-)

diffs (32 lines):

diff -r 4ebb17a0404b -r eb82a92a14b5 Makefile
--- a/Makefile	Mon Jan 16 13:36:47 2012 +0200
+++ b/Makefile	Mon Jan 16 13:52:07 2012 +0200
@@ -1,6 +1,16 @@
 
 .include <bsd.own.mk>
 
+# ZROUTER_ROOT can be set in environment
+.if !defined(ZROUTER_ROOT)
+ZROUTER_ROOT=${.CURDIR}
+.endif
+
+.if exists(${ZROUTER_ROOT}/Makefile.local.opts)
+.warning Using options from ${ZROUTER_ROOT}/Makefile.local.opts
+.include "${ZROUTER_ROOT}/Makefile.local.opts"
+.endif
+
 #
 # Defaults
 #
@@ -21,11 +31,6 @@
 .error "missing FreeBSD source tree: FREEBSD_SRC_TREE=${FREEBSD_SRC_TREE}"
 .endif
 
-# ZROUTER_ROOT can be set in environment
-.if !defined(ZROUTER_ROOT)
-ZROUTER_ROOT=${.CURDIR}
-.endif
-
 # ZROUTER_OBJ can be set in environment
 ZROUTER_OBJ?=${OBJ_DIR}/${ZROUTER_ROOT}
 MAKEOBJDIRPREFIX?=${OBJ_DIR}/${ZROUTER_ROOT}/


More information about the Zrouter-src mailing list