From 9a1cd09a10b475a2b18059a7ac6cb6915e9dfaf0 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Wed, 17 Mar 2010 20:26:03 +1100 Subject: build: added ADD_CFLAGS() and started of Samba4 build --- lib/replace/wscript | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'lib/replace/wscript') diff --git a/lib/replace/wscript b/lib/replace/wscript index 04665a0ec1..d40843522c 100644 --- a/lib/replace/wscript +++ b/lib/replace/wscript @@ -14,9 +14,12 @@ def set_options(opt): opt.add_option('--sbindir', help=("system admin executables [PREFIX/sbin]"), action="store", dest='SBINDIR', default=None) - opt.add_option('--disable-rpath', - help=("Disable use of rpath"), - action="store_true", dest='disable_rpath', default=False) + opt.add_option('--enable-rpath', + help=("Enable use of rpath for installed binaries"), + action="store_true", dest='enable_rpath', default=False) + opt.add_option('--enable-developer', + help=("Turn on developer warnings and debugging"), + action="store_true", dest='developer', default=False) @wafsamba.runonce def configure(conf): @@ -30,6 +33,12 @@ def configure(conf): conf.CONFIG_PATH('SBINDIR', '/sbin') conf.check_tool('compiler_cc') + + if Options.options.developer: + conf.ADD_CFLAGS('-Wall -g -DDEVELOPER') + + conf.env['RPATH_ON_INSTALL'] = Options.options.enable_rpath + conf.DEFUN('_GNU_SOURCE', 1) conf.DEFUN('_XOPEN_SOURCE_EXTENDED', 1) conf.DEFUN('LIBREPLACE_NETWORK_CHECKS', 1) -- cgit