aboutsummaryrefslogtreecommitdiffstats
path: root/buildtools/wafsamba
diff options
context:
space:
mode:
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>2016-03-08 10:23:09 +1300
committerAndrew Bartlett <abartlet@samba.org>2016-03-09 13:52:26 +0100
commit1c796547f20fa3c7c2e93fd5ce6ee8453a2bb435 (patch)
tree99b00397e4579ff8473a0e88653b87e7961f9048 /buildtools/wafsamba
parentc1b68fa0b82cba05a32350a1e0b22842203c9274 (diff)
downloadsamba-1c796547f20fa3c7c2e93fd5ce6ee8453a2bb435.tar.gz
samba-1c796547f20fa3c7c2e93fd5ce6ee8453a2bb435.tar.xz
samba-1c796547f20fa3c7c2e93fd5ce6ee8453a2bb435.zip
configure: set HAVE___ATTRIBUTE__ for heimdal
Without this, heimdal ends up defining __attribute__ away, causing gcc-6 compile errors with -Werror=return-type because it can't tell when functions have __attribute__((noreturn)). Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Wed Mar 9 13:52:26 CET 2016 on sn-devel-144
Diffstat (limited to 'buildtools/wafsamba')
-rwxr-xr-xbuildtools/wafsamba/wscript16
1 files changed, 16 insertions, 0 deletions
diff --git a/buildtools/wafsamba/wscript b/buildtools/wafsamba/wscript
index 586cc4be5f1..8802e5a39d4 100755
--- a/buildtools/wafsamba/wscript
+++ b/buildtools/wafsamba/wscript
@@ -402,6 +402,22 @@ def configure(conf):
addmain=False,
msg='Checking for library destructor support')
+ conf.CHECK_CODE('''
+ void test_attribute(void) __attribute__ (());
+
+ void test_attribute(void)
+ {
+ return;
+ }
+
+ int main(void) {
+ return 0;
+ }
+ ''',
+ 'HAVE___ATTRIBUTE__',
+ addmain=False,
+ msg='Checking for __attribute__')
+
if sys.platform.startswith('aix'):
conf.DEFINE('_ALL_SOURCE', 1, add_to_cflags=True)
# Might not be needed if ALL_SOURCE is defined