build: add missing configure function checks for test/interactive-wayland

Signed-off-by: Ran Benita <ran234@gmail.com>
master
Ran Benita 2017-08-16 20:23:54 +03:00
parent f468f0b243
commit 76348754e3
2 changed files with 7 additions and 1 deletions

View File

@ -68,7 +68,7 @@ AS_IF([test ! -f "src/xkbcomp/parser.c" -a "x$YACC_INST" = x], [
])
# Checks for library functions.
AC_CHECK_FUNCS([eaccess euidaccess mmap])
AC_CHECK_FUNCS([eaccess euidaccess mmap mkostemp posix_fallocate])
AC_CHECK_FUNCS([secure_getenv __secure_getenv])
AS_IF([test "x$ac_cv_func_secure_getenv" = xno -a \

View File

@ -84,6 +84,12 @@ endif
if cc.has_header_symbol('sys/mman.h', 'mmap')
configh_data.set('HAVE_MMAP', 1)
endif
if cc.has_header_symbol('stdlib.h', 'mkostemp', prefix: '#define _GNU_SOURCE')
configh_data.set('HAVE_MKOSTEMP', 1)
endif
if cc.has_header_symbol('fcntl.h', 'posix_fallocate', prefix: '#define _GNU_SOURCE')
configh_data.set('HAVE_POSIX_FALLOCATE', 1)
endif
if cc.has_header_symbol('stdlib.h', 'secure_getenv', prefix: '#define _GNU_SOURCE')
configh_data.set('HAVE_SECURE_GETENV', 1)
elif cc.has_header_symbol('stdlib.h', '__secure_getenv', prefix: '#define _GNU_SOURCE')