Add support for NetBSD by generalizing BSD OS tests.

This commit is contained in:
nia 2020-02-12 04:03:08 +00:00 committed by Paul Davis
parent b490100c1b
commit 9be75befbe
3 changed files with 4 additions and 4 deletions

View File

@ -86,7 +86,7 @@ def build(bld):
'PACKAGE="' + I18N_PACKAGE + str(bld.env['MAJOR']) + '"',
'LIBARDOUR="' + bld.env['lwrcase_dirname'] + '"',
]
if re.search ("freebsd", sys.platform) != None or re.search ("openbsd", sys.platform) != None:
if re.search ("bsd", sys.platform) != None:
obj.defines.append('_POSIX_C_SOURCE=200809')
obj.defines.append('_XOPEN_SOURCE=700')

View File

@ -21,6 +21,6 @@ def build(bld):
obj.source = [ 'abicheck.c' ]
obj.target = 'gcc-glibmm-abi-check'
obj.name = 'gcc-glibmm-abi-check'
if re.search ("freebsd", sys.platform) == None:
if re.search ("bsd", sys.platform) == None:
obj.lib = 'dl'
obj.install_path = None

View File

@ -656,7 +656,7 @@ int main() { return 0; }''',
if opt.stl_debug:
cxx_flags.append("-D_GLIBCXX_DEBUG")
if re.search ("freebsd", sys.platform) != None or re.search ("openbsd", sys.platform) != None:
if re.search ("bsd", sys.platform) != None:
linker_flags.append('-lexecinfo')
if conf.env['DEBUG_RT_ALLOC']:
@ -1059,7 +1059,7 @@ def configure(conf):
# executing a test program is n/a when cross-compiling
if Options.options.dist_target != 'mingw':
if Options.options.dist_target != 'msvc' and re.search ("openbsd", sys.platform) == None:
if Options.options.dist_target != 'msvc' and re.search ("(open|net)bsd", sys.platform) == None:
if re.search ("freebsd", sys.platform) != None:
conf.check_cc(
msg="Checking for function 'dlopen' in dlfcn.h",