]
# We get -1 if the size cannot be determined
- have = cc.sizeof(decl, prefix : decl_headers, args : '-D_GNU_SOURCE') > 0
-
- if have == true
- conf.set10('HAVE_' + decl.underscorify().to_upper(), have)
+ if cc.sizeof(decl, prefix : decl_headers, args : '-D_GNU_SOURCE') > 0
+ conf.set10('HAVE_' + decl.underscorify().to_upper(), true)
endif
endforeach
#include <sys/resource.h>'''],
]
- have = cc.has_function(ident[0], prefix : ident[1], args : '-D_GNU_SOURCE')
- if have == true
- conf.set10('HAVE_' + ident[0].to_upper(), have)
+ if cc.has_function(ident[0], prefix : ident[1], args : '-D_GNU_SOURCE')
+ conf.set10('HAVE_' + ident[0].to_upper(), true)
endif
endforeach
]
# We get -1 if the size cannot be determined
- have = cc.sizeof(decl, prefix : seccomp_headers, args : '-D_GNU_SOURCE') > 0
-
- if have == true
- conf.set10('HAVE_' + decl.underscorify().to_upper(), have)
+ if cc.sizeof(decl, prefix : seccomp_headers, args : '-D_GNU_SOURCE') > 0
+ conf.set10('HAVE_' + decl.underscorify().to_upper(), true)
endif
endforeach
endif
'netns_ifaddrs.h')
if cc.has_function('getline', prefix : '#include <stdio.h>', args : '-D_GNU_SOURCE')
- conf.set10('HAVE_GETLINE', have)
+ conf.set10('HAVE_GETLINE', true)
else
include_sources += files(
'getline.c',
endif
if cc.has_function('fexecve', prefix : '#include <unistd.h>', args : '-D_GNU_SOURCE')
- conf.set10('HAVE_FEXECVE', have)
+ conf.set10('HAVE_FEXECVE', true)
else
include_sources += files(
'fexecve.c',
'''
if cc.has_function('getgrgid_r', prefix : getgr_headers, args : '-D_GNU_SOURCE')
- conf.set10('HAVE_GETGRGID_R', have)
+ conf.set10('HAVE_GETGRGID_R', true)
else
include_sources += files(
'getgrgid_r.c',
have_hasmntopt = cc.has_function('hasmntopt', prefix : mntent_headers, args : '-D_GNU_SOURCE')
if have_hasmntopt
- conf.set10('HAVE_HASMNTOPT', have)
+ conf.set10('HAVE_HASMNTOPT', true)
endif
have_setmntent = cc.has_function('setmntent', prefix : mntent_headers, args : '-D_GNU_SOURCE')
if have_setmntent
- conf.set10('HAVE_SETMNTENT', have)
+ conf.set10('HAVE_SETMNTENT', true)
endif
have_endmntent = cc.has_function('endmntent', prefix : mntent_headers, args : '-D_GNU_SOURCE')
if have_endmntent
- conf.set10('HAVE_ENDMNTENT', have)
+ conf.set10('HAVE_ENDMNTENT', true)
endif
if have_hasmntopt == false or have_setmntent == false or have_endmntent == false
endif
if cc.has_function('strlcpy', prefix : '#include <string.h>', args : '-D_GNU_SOURCE')
- conf.set10('HAVE_STRLCPY', have)
+ conf.set10('HAVE_STRLCPY', true)
else
include_sources += files(
'strlcpy.c',
endif
if cc.has_function('strlcat', prefix : '#include <string.h>', args : '-D_GNU_SOURCE')
- conf.set10('HAVE_STRLCAT', have)
+ conf.set10('HAVE_STRLCAT', true)
else
include_sources += files(
'strlcat.c',
endif
if cc.has_function('strchrnul', prefix : '#include <string.h>', args : '-D_GNU_SOURCE')
- conf.set10('HAVE_STRCHRNUL', have)
+ conf.set10('HAVE_STRCHRNUL', true)
else
include_sources += files(
'strchrnul.c',
endif
if cc.has_function('openpty', prefix : '#include <pty.h>', args : '-D_GNU_SOURCE')
- conf.set10('HAVE_OPENPTY', have)
+ conf.set10('HAVE_OPENPTY', true)
else
include_sources += files(
'openpty.c',