summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorJay Berkenbilt <ejb@ql.org>2012-06-20 17:20:57 +0200
committerJay Berkenbilt <ejb@ql.org>2012-06-20 21:20:26 +0200
commit5d4cad9c02e9d4f31477fed0e3b20b35c83936f8 (patch)
tree38768f5e4a797e09de304b1e184021f5b280da29 /configure.ac
parent24e2b2b76f1f0051f240c8371b2352c4cde85bf9 (diff)
downloadqpdf-5d4cad9c02e9d4f31477fed0e3b20b35c83936f8.tar.zst
ABI change: fix use of off_t, size_t, and integer types
Significantly improve the code's use of off_t for file offsets, size_t for memory sizes, and integer types in cases where there has to be compatibility with external interfaces. Rework sections of the code that would have prevented qpdf from working on files larger than 2 (or maybe 4) GB in size.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac21
1 files changed, 21 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 05082956..3e89f978 100644
--- a/configure.ac
+++ b/configure.ac
@@ -37,8 +37,29 @@ if test "$BUILD_INTERNAL_LIBS" = "0"; then
AC_SEARCH_LIBS(pcre_compile,pcre,,[MISSING_PCRE=1; MISSING_ANY=1])
fi
+AC_SYS_LARGEFILE
+AC_FUNC_FSEEKO
AC_TYPE_UINT16_T
AC_TYPE_UINT32_T
+
+AC_MSG_CHECKING(for whether printf supports %ll)
+AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
+#include <stdio.h>
+#include <string.h>
+#include <sys/types.h>
+int
+main()
+{
+ long long a = 160591605916059ll;
+ char t[50];
+ sprintf(t, "%lld", a);
+}
+]])],[qpdf_PRINTF_LL=yes],[qpdf_PRINTF_LL=no])
+AC_MSG_RESULT($qpdf_PRINTF_LL)
+if test "$qpdf_PRINTF_LL" = "yes"; then
+ AC_DEFINE([HAVE_PRINTF_LL], [1], [Whether printf supports %ll])
+fi
+
AC_CHECK_FUNCS(random)
# Check if LD supports linker scripts, and define conditional