[waf] Add check for and link against libexecinfo on FreeBSD
This commit is contained in:
parent
f285ad372e
commit
de3515cd27
|
@ -16,6 +16,8 @@ def configure(conf):
|
|||
|
||||
def build(bld):
|
||||
libs = ['glib', 'gthread', 'gmodule', 'ev']
|
||||
if sys.platform.startswith('freebsd'):
|
||||
libs += ['execinfo']
|
||||
|
||||
source = '''
|
||||
actions.c
|
||||
|
|
8
wscript
8
wscript
|
@ -154,8 +154,12 @@ def configure(conf):
|
|||
conf.check(header_name='sys/resource.h')
|
||||
conf.check(header_name='sys/sendfile.h')
|
||||
conf.check(header_name='sys/un.h')
|
||||
conf.check(header_name='execinfo.h')
|
||||
|
||||
|
||||
if sys.platform.startswith('freebsd'):
|
||||
conf.check(lib='execinfo', uselib_store='execinfo', define_name="HAVE_EXECINFO_H")
|
||||
else:
|
||||
conf.check(header_name='execinfo.h', define_name="HAVE_EXECINFO_H")
|
||||
|
||||
# check for available functions
|
||||
if sys.platform == 'linux2':
|
||||
conf.check(function_name='sendfile', header_name='sys/sendfile.h', define_name='HAVE_SENDFILE')
|
||||
|
|
Loading…
Reference in New Issue