summaryrefslogtreecommitdiff
path: root/Build/source/texk/lcdf-typetools/configure.ac.orig
diff options
context:
space:
mode:
Diffstat (limited to 'Build/source/texk/lcdf-typetools/configure.ac.orig')
-rw-r--r--Build/source/texk/lcdf-typetools/configure.ac.orig47
1 files changed, 36 insertions, 11 deletions
diff --git a/Build/source/texk/lcdf-typetools/configure.ac.orig b/Build/source/texk/lcdf-typetools/configure.ac.orig
index c3fd4494eae..8291c068782 100644
--- a/Build/source/texk/lcdf-typetools/configure.ac.orig
+++ b/Build/source/texk/lcdf-typetools/configure.ac.orig
@@ -1,5 +1,5 @@
dnl Process this file with autoconf to produce a configure script.
-AC_INIT([lcdf-typetools], [2.90])
+AC_INIT([lcdf-typetools], [2.92])
AC_CONFIG_SRCDIR([NEWS])
AM_INIT_AUTOMAKE
AM_CONFIG_HEADER([autoconf.h])
@@ -245,30 +245,55 @@ AC_CHECK_HEADERS(new.h unistd.h)
dnl
-dnl functions such as strerror, working strtod, strtoul, time
-dnl headers such as unistd.h
+dnl endianness
+dnl
+
+AC_C_BIGENDIAN(, [AC_DEFINE([WORDS_LITTLEENDIAN], 1, [Define to 1 if your processor stores words with the least significant byte
+ first (like Intel and VAX, unlike Motorola and SPARC).])])
+
+
+dnl
+dnl functions such as strerror, working strtod, working strnlen, strtoul,
+dnl time headers such as unistd.h
dnl
AC_LANG_C
need_fixlibc=0
-AC_CHECK_FUNCS(strerror, :, [need_fixlibc=1])
+AC_CHECK_FUNCS([strerror], [:], [need_fixlibc=1])
-AC_CACHE_CHECK(whether strtod works, ac_cv_working_strtod,
+AC_CACHE_CHECK([for broken strtod], [ac_cv_broken_strtod],
[AC_TRY_RUN([#include <stdio.h>
#include <stdlib.h>
int main(int c, char **v) {
char s[] = "12 ";
char *endp;
double d = strtod(s, &endp);
- exit(*endp == 0 ? 1 : 0);
-}], [ac_cv_working_strtod=yes], [ac_cv_working_strtod=no],
-[ac_cv_working_strtod=yes])])
-if test "x$ac_cv_working_strtod" = xno; then
+ return (s + 2) == endp;
+}], [ac_cv_broken_strtod=yes], [ac_cv_broken_strtod=no],
+[ac_cv_broken_strtod=no])])
+if test "x$ac_cv_broken_strtod" = xyes; then
need_fixlibc=1
- AC_DEFINE(BROKEN_STRTOD, 1, [Define if strtod is broken.])
+ AC_DEFINE(HAVE_BROKEN_STRTOD, 1, [Define if strtod is broken.])
+fi
+
+AC_CHECK_DECLS([strnlen])
+AC_CHECK_FUNCS([strnlen], [have_strnlen=1], [need_fixlibc=1])
+if test "x$have_strnlen" = x1; then
+ AC_CACHE_CHECK([for broken strnlen], [ac_cv_broken_strnlen],
+ [AC_TRY_RUN([#include <string.h>
+#include <stdio.h>
+int main(int c, char **v) {
+ char s[] = "01234567891";
+ return strnlen(s, 10) == 10;
+}], [ac_cv_broken_strnlen=yes], [ac_cv_broken_strnlen=no],
+[ac_cv_broken_strnlen=no])])
+ if test "x$ac_cv_broken_strnlen" = xyes; then
+ need_fixlibc=1
+ AC_DEFINE([HAVE_BROKEN_STRNLEN], [1], [Define if strnlen is broken.])
+ fi
fi
-AC_CHECK_FUNCS([ctime ftruncate mkstemp sigaction strnlen strtoul waitpid])
+AC_CHECK_FUNCS([ctime ftruncate mkstemp sigaction strdup strtoul vsnprintf waitpid])
AC_CHECK_FUNC([floor], [:], [AC_CHECK_LIB(m, floor)])
AC_CHECK_FUNC([fabs], [:], [AC_CHECK_LIB(m, fabs)])
AC_CHECK_HEADERS([unistd.h fcntl.h sys/time.h sys/wait.h])