fix meson.build
Co-authored-by: Ariadne Conill <ariadne@dereferenced.org>pull/249/head
parent
434cb2935e
commit
f7bebba664
|
@ -12,6 +12,18 @@
|
|||
/* Define to 1 if you have the `reallocarray' function. */
|
||||
#mesondefine HAVE_REALLOCARRAY
|
||||
|
||||
/* Define to 1 if you have the `strlcat' function. */
|
||||
#mesondefine HAVE_DECL_STRLCAT
|
||||
|
||||
/* Define to 1 if you have the `strlcpy' function. */
|
||||
#mesondefine HAVE_DECL_STRLCPY
|
||||
|
||||
/* Define to 1 if you have the `strndup' function. */
|
||||
#mesondefine HAVE_DECL_STRNDUP
|
||||
|
||||
/* Define to 1 if you have the `reallocarray' function. */
|
||||
#mesondefine HAVE_DECL_REALLOCARRAY
|
||||
|
||||
/* Name of package */
|
||||
#mesondefine PACKAGE
|
||||
|
||||
|
|
|
@ -30,8 +30,12 @@ check_functions = [
|
|||
]
|
||||
|
||||
foreach f : check_functions
|
||||
name = f[0].to_upper().underscorify()
|
||||
if cc.has_function(f[0], prefix : '#define _BSD_SOURCE\n#include <@0@>'.format(f[1])) and cc.has_header_symbol(f[1], f[0], prefix : '#define _BSD_SOURCE')
|
||||
cdata.set('HAVE_@0@'.format(f[0].to_upper().underscorify()), 1)
|
||||
cdata.set('HAVE_@0@'.format(name), 1)
|
||||
cdata.set('HAVE_DECL_@0@'.format(name), 1)
|
||||
else
|
||||
cdata.set('HAVE_DECL_@0@'.format(name), 0)
|
||||
endif
|
||||
endforeach
|
||||
|
||||
|
|
Loading…
Reference in New Issue