summaryrefslogtreecommitdiff
path: root/buildtools/wafsamba/samba_conftests.py
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-04-20 23:17:32 +1000
committerAndrew Tridgell <tridge@samba.org>2010-04-20 23:43:33 +1000
commit5e69259671d317aebaae54ec9adc30e58f70076f (patch)
tree583c7f6ec06684b6dc000510f8f39f1ce321dd7b /buildtools/wafsamba/samba_conftests.py
parenta9f5bfb3a5324f09a07657a8bb28bb4510485d31 (diff)
downloadsamba-5e69259671d317aebaae54ec9adc30e58f70076f.tar.gz
samba-5e69259671d317aebaae54ec9adc30e58f70076f.tar.bz2
samba-5e69259671d317aebaae54ec9adc30e58f70076f.zip
build: added uname display and SYSTEM_UNAME define
suggestion from Metze
Diffstat (limited to 'buildtools/wafsamba/samba_conftests.py')
-rw-r--r--buildtools/wafsamba/samba_conftests.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/buildtools/wafsamba/samba_conftests.py b/buildtools/wafsamba/samba_conftests.py
index e86f9393fe..17947582eb 100644
--- a/buildtools/wafsamba/samba_conftests.py
+++ b/buildtools/wafsamba/samba_conftests.py
@@ -237,3 +237,22 @@ WriteMakefile(
conf.check_message_2('ok')
return True
+
+
+@conf
+def CHECK_UNAME(conf, flags=None, msg=None, define=None):
+ '''return uname result'''
+ cmd = ['uname']
+ if flags is not None:
+ cmd.append(flags)
+ if msg is None:
+ msg = 'Checking uname'
+ conf.COMPOUND_START(msg)
+ ret = Utils.cmd_output(cmd)
+ ret = ret.strip()
+ conf.COMPOUND_END(ret)
+ if define:
+ conf.DEFINE(define, ret, quote=True)
+ return ret
+
+