check for alloca.h before including

This commit is contained in:
Tim Rühsen 2014-10-28 15:41:35 +01:00 committed by Tim Ruehsen
parent d86f4e6da1
commit f97f140105
8 changed files with 24 additions and 6 deletions

View File

@ -205,6 +205,9 @@ AC_ARG_WITH(psl-testfile,
PSL_TESTFILE="\$(top_srcdir)/data/test_psl.txt")
AC_SUBST(PSL_TESTFILE)
# check for alloca / alloca.h
AC_FUNC_ALLOCA
# Override the template file name of the generated .pc file, so that there
# is no need to rename the template file when the API version changes.
AC_CONFIG_FILES([Makefile

View File

@ -63,10 +63,12 @@
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <alloca.h>
#include <errno.h>
#include <langinfo.h>
#include <arpa/inet.h>
#ifdef HAVE_ALLOCA_H
# include <alloca.h>
#endif
#ifdef WITH_LIBICU
# include <unicode/uversion.h>

View File

@ -38,6 +38,9 @@
#include <time.h>
#include <ctype.h>
#include <sys/stat.h>
#ifdef HAVE_ALLOCA_H
# include <alloca.h>
#endif
#if defined(BUILTIN_GENERATOR_LIBICU) || defined(BUILTIN_GENERATOR_LIBIDN2) || defined(BUILTIN_GENERATOR_LIBIDN)
# define _GENERATE_BUILTIN_DATA

View File

@ -35,7 +35,9 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <alloca.h>
#ifdef HAVE_ALLOCA_H
# include <alloca.h>
#endif
#include <libpsl.h>

View File

@ -36,7 +36,9 @@
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <alloca.h>
#ifdef HAVE_ALLOCA_H
# include <alloca.h>
#endif
#include <libpsl.h>

View File

@ -35,7 +35,9 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <alloca.h>
#ifdef HAVE_ALLOCA_H
# include <alloca.h>
#endif
#include <libpsl.h>

View File

@ -35,7 +35,9 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <alloca.h>
#ifdef HAVE_ALLOCA_H
# include <alloca.h>
#endif
#include <libpsl.h>

View File

@ -36,7 +36,9 @@
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <alloca.h>
#ifdef HAVE_ALLOCA_H
# include <alloca.h>
#endif
#ifdef WITH_LIBICU
# include <unicode/uversion.h>