2 # Process this file with autoconf to produce a configure script.
5 AC_INIT(cpplib, [ ], gcc-bugs@gcc.gnu.org, cpplib)
6 AC_CONFIG_SRCDIR(ucnid.h)
7 AC_CONFIG_MACRO_DIR(../config)
12 # Checks for programs.
16 MISSING=`cd $ac_aux_dir && ${PWDCMD-pwd}`/missing
17 AC_CHECK_PROGS([ACLOCAL], [aclocal], [$MISSING aclocal])
18 AC_CHECK_PROGS([AUTOCONF], [autoconf], [$MISSING autoconf])
19 AC_CHECK_PROGS([AUTOHEADER], [autoheader], [$MISSING autoheader])
21 # Checks for header files.
24 AC_CHECK_HEADERS(iconv.h locale.h fcntl.h limits.h stddef.h \
25 stdlib.h strings.h string.h sys/file.h unistd.h)
27 # Checks for typedefs, structures, and compiler characteristics.
36 AC_CHECK_FUNCS(putc_unlocked fputc_unlocked fputs_unlocked \
37 fwrite_unlocked fprintf_unlocked)
38 AC_CHECK_DECLS([abort, errno, putc_unlocked, fputc_unlocked,
39 fputs_unlocked, fwrite_unlocked, fprintf_unlocked])
41 # Checks for library functions.
45 ZW_GNU_GETTEXT_SISTER_DIR
47 AC_CACHE_CHECK(for uchar, gcc_cv_type_uchar,
52 [if ((uchar *)0) return 0;
53 if (sizeof(uchar)) return 0;],
54 ac_cv_type_uchar=yes, ac_cv_type_uchar=no)])
55 if test $ac_cv_type_uchar = yes; then
56 AC_DEFINE(HAVE_UCHAR, 1,
57 [Define if <sys/types.h> defines \`uchar'.])
62 # More defines and substitutions.
63 PACKAGE="$PACKAGE_TARNAME"
64 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Define to the name of this package.])
67 if test "x$enable_nls" != xno; then
68 USED_CATALOGS='$(CATALOGS)'
72 AC_SUBST(USED_CATALOGS)
74 AC_ARG_ENABLE(maintainer-mode,
75 [ --enable-maintainer-mode enable rules only needed by maintainers],,
76 enable_maintainer_mode=no)
78 if test "x$enable_maintainer_mode" = xno; then
85 AC_ARG_ENABLE(checking,
86 [ --enable-checking enable expensive run-time checks],,
89 if test $enable_checking != no ; then
90 AC_DEFINE(ENABLE_CHECKING, 1,
91 [Define if you want more run-time sanity checks.])
98 arm*-*-symbianelf* | \
101 hppa*64*-*-* | parisc*64*-*-* | \
107 sparc64*-*-* | ultrasparc-*-freebsd* | \
108 sparcv9-*-solaris2* | \
109 sparc-*-solaris2.[789] | sparc-*-solaris2.1[0-9] | \
111 need_64bit_hwint=yes ;;
113 need_64bit_hwint=no ;;
116 case $need_64bit_hwint:$ac_cv_sizeof_long in
117 *:8 | no:*) host_wide_int=long ;;
118 *) host_wide_int='long long' ;;
122 AC_DEFINE_UNQUOTED(HOST_WIDE_INT, $host_wide_int,
123 [Define to the widest efficient host integer type at least
124 as wide as the target's size_t type.])
128 AC_CONFIG_HEADERS(config.h:config.in, [echo timestamp > stamp-h1])
129 AC_CONFIG_FILES(Makefile)