That's easier for the callers.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
-def CURRENT_CFLAGS(bld, target, cflags, allow_warnings=False, hide_symbols=False):
+def CURRENT_CFLAGS(bld, target, cflags,
+ allow_warnings=False,
+ use_hostcc=False,
+ hide_symbols=False):
'''work out the current flags. local flags are added first'''
- ret = TO_LIST(cflags)
+ ret = []
+ if use_hostcc:
+ ret += ['-D_SAMBA_HOSTCC_']
+ ret += TO_LIST(cflags)
if not 'EXTRA_CFLAGS' in bld.env:
list = []
else:
target = modname,
samba_cflags = CURRENT_CFLAGS(bld, modname, cflags,
allow_warnings=allow_warnings,
+ use_hostcc=use_hostcc,
hide_symbols=hide_symbols),
depends_on = depends_on,
samba_deps = TO_LIST(deps),