Browse Source

[build] look for malloc.h and mallopt()

master
Glenn Strauss 4 months ago
parent
commit
1783550154
  1. 2
      SConstruct
  2. 2
      configure.ac
  3. 2
      src/CMakeLists.txt
  4. 2
      src/config.h.cmake
  5. 2
      src/meson.build

2
SConstruct

@ -371,6 +371,7 @@ if 1:
'getopt.h',
'inttypes.h',
'linux/random.h',
'malloc.h',
'poll.h',
'port.h',
'pwd.h',
@ -428,6 +429,7 @@ if 1:
'localtime_r',
'lstat',
'madvise',
'mallopt',
'memcpy',
'mempcpy',
'memset_s',

2
configure.ac

@ -96,6 +96,7 @@ AC_HEADER_SYS_WAIT
AC_CHECK_HEADERS([\
getopt.h \
inttypes.h \
malloc.h \
poll.h \
port.h \
pwd.h \
@ -1499,6 +1500,7 @@ AC_CHECK_FUNCS([\
localtime_r \
lstat \
madvise \
mallopt \
memcpy \
mempcpy \
memset \

2
src/CMakeLists.txt

@ -109,6 +109,7 @@ check_include_files(unistd.h HAVE_UNISTD_H)
check_include_files(pthread.h HAVE_PTHREAD_H)
check_include_files(getopt.h HAVE_GETOPT_H)
check_include_files(inttypes.h HAVE_INTTYPES_H)
check_include_files(malloc.h HAVE_MALLOC_H)
check_include_files(poll.h HAVE_POLL_H)
check_include_files(port.h HAVE_PORT_H)
check_include_files(pwd.h HAVE_PWD_H)
@ -172,6 +173,7 @@ check_function_exists(kqueue HAVE_KQUEUE)
check_function_exists(localtime_r HAVE_LOCALTIME_R)
check_function_exists(lstat HAVE_LSTAT)
check_function_exists(madvise HAVE_MADVISE)
check_function_exists(mallopt HAVE_MALLOPT)
check_function_exists(memcpy HAVE_MEMCPY)
check_function_exists(mempcpy HAVE_MEMPCPY)
check_function_exists(memset HAVE_MEMSET)

2
src/config.h.cmake

@ -75,6 +75,7 @@
#cmakedefine HAVE_PCRE_H
#cmakedefine HAVE_LIBPCRE
#cmakedefine HAVE_MALLOC_H
#cmakedefine HAVE_POLL_H
#cmakedefine HAVE_PWD_H
@ -126,6 +127,7 @@
#cmakedefine HAVE_LOCALTIME_R
#cmakedefine HAVE_LSTAT
#cmakedefine HAVE_MADVISE
#cmakedefine HAVE_MALLOPT
#cmakedefine HAVE_MEMCPY
#cmakedefine HAVE_MEMPCPY
#cmakedefine HAVE_MEMSET

2
src/meson.build

@ -48,6 +48,7 @@ conf_data.set('HAVE_UNISTD_H', compiler.has_header('unistd.h'))
conf_data.set('HAVE_PTHREAD_H', compiler.has_header('pthread.h'))
conf_data.set('HAVE_GETOPT_H', compiler.has_header('getopt.h'))
conf_data.set('HAVE_INTTYPES_H', compiler.has_header('inttypes.h'))
conf_data.set('HAVE_MALLOC_H', compiler.has_header('malloc.h'))
conf_data.set('HAVE_POLL_H', compiler.has_header('poll.h'))
conf_data.set('HAVE_PORT_H', compiler.has_header('port.h'))
conf_data.set('HAVE_PWD_H', compiler.has_header('pwd.h'))
@ -124,6 +125,7 @@ conf_data.set('HAVE_KQUEUE', compiler.has_function('kqueue', args: defs))
conf_data.set('HAVE_LOCALTIME_R', compiler.has_function('localtime_r', args: defs))
conf_data.set('HAVE_LSTAT', compiler.has_function('lstat', args: defs))
conf_data.set('HAVE_MADVISE', compiler.has_function('madvise', args: defs))
conf_data.set('HAVE_MALLOPT', compiler.has_function('mallopt', args: defs))
conf_data.set('HAVE_MEMCPY', compiler.has_function('memcpy', args: defs))
conf_data.set('HAVE_MEMPCPY', compiler.has_function('mempcpy', args: defs))
conf_data.set('HAVE_MEMSET', compiler.has_function('memset', args: defs))

Loading…
Cancel
Save