summaryrefslogtreecommitdiff
path: root/buildtools
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2014-03-27 09:37:26 +0100
committerAndrew Bartlett <abartlet@samba.org>2014-04-02 09:03:41 +0200
commitd88f41f69865898dd814bb4dd3c46b9d153d1375 (patch)
tree74459e84a5a5edb69e2f84ae5de8b48415b87558 /buildtools
parent7f2d12c4c0c03a4a3b0262845968348697287033 (diff)
downloadsamba-d88f41f69865898dd814bb4dd3c46b9d153d1375.tar.gz
wafsamba: require a ';' after STATIC_*_MODULES_PROTO
Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'buildtools')
-rw-r--r--buildtools/wafsamba/samba_deps.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/buildtools/wafsamba/samba_deps.py b/buildtools/wafsamba/samba_deps.py
index 74a70cff7e5..c00744ea7a6 100644
--- a/buildtools/wafsamba/samba_deps.py
+++ b/buildtools/wafsamba/samba_deps.py
@@ -224,7 +224,8 @@ def add_init_functions(self):
sname = sname.replace('/','_')
cflags.append('-DSTATIC_%s_MODULES=%s' % (sname, sentinel))
if sentinel == 'NULL':
- cflags.append('-DSTATIC_%s_MODULES_PROTO=' % sname)
+ proto = "extern void __%s_dummy_module_proto(void)" % (sname)
+ cflags.append('-DSTATIC_%s_MODULES_PROTO=%s' % (sname, proto))
self.ccflags = cflags
return
@@ -238,12 +239,14 @@ def add_init_functions(self):
if init_fn_list == []:
cflags.append('-DSTATIC_%s_MODULES=%s' % (m, sentinel))
if sentinel == 'NULL':
- cflags.append('-DSTATIC_%s_MODULES_PROTO' % m)
+ proto = "extern void __%s_dummy_module_proto(void)" % (m)
+ cflags.append('-DSTATIC_%s_MODULES_PROTO=%s' % (m, proto))
else:
cflags.append('-DSTATIC_%s_MODULES=%s' % (m, ','.join(init_fn_list) + ',' + sentinel))
proto=''
for f in init_fn_list:
- proto = proto + '_MODULE_PROTO(%s)' % f
+ proto += '_MODULE_PROTO(%s)' % f
+ proto += "extern void __%s_dummy_module_proto(void)" % (m)
cflags.append('-DSTATIC_%s_MODULES_PROTO=%s' % (m, proto))
self.ccflags = cflags