summaryrefslogtreecommitdiff
path: root/Build/source/m4/kpse-largefile.m4
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2013-06-24 11:36:53 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2013-06-24 11:36:53 +0000
commit8a9fa865b4d372ab53ccc70fe46a25273c49e9af (patch)
tree96a83e43801be4faa0662613ff4ef46adf58d04b /Build/source/m4/kpse-largefile.m4
parent432d51af8c3f6760dc1dda1f229f9a27e34d4a44 (diff)
Update build system
git-svn-id: svn://tug.org/texlive/trunk@30903 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/m4/kpse-largefile.m4')
-rw-r--r--Build/source/m4/kpse-largefile.m425
1 files changed, 25 insertions, 0 deletions
diff --git a/Build/source/m4/kpse-largefile.m4 b/Build/source/m4/kpse-largefile.m4
new file mode 100644
index 00000000000..b9af9acee3f
--- /dev/null
+++ b/Build/source/m4/kpse-largefile.m4
@@ -0,0 +1,25 @@
+# Public macros for the TeX Live (TL) tree.
+# Copyright (C) 2013 Peter Breitenlohner <tex-live@tug.org>
+#
+# This file is free software; the copyright holder
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# KPSE_LARGEFILE(MAKE-VAR,[EXTRA-DEFINE])
+# ---------------------------------------
+# Append -D's required for largefile support to MAKE-VAR.
+AC_DEFUN([KPSE_LARGEFILE], [dnl
+AC_REQUIRE([AC_SYS_LARGEFILE])[]dnl
+AC_REQUIRE([AC_FUNC_FSEEKO])[]dnl
+if test "x$enable_largefile" != xno; then
+ AS_CASE([$ac_cv_sys_file_offset_bits],
+ [no], [],
+ [unknown], [AS_CASE([$ac_cv_sys_large_files],
+ [no | unknown], [],
+ [$1="$$1 -D_LARGE_FILES"])],
+ [$1="$$1 m4_ifval([$2], [-D$2 ])-D_FILE_OFFSET_BITS=64"])
+fi
+AS_CASE([$ac_cv_sys_largefile_source],
+ [no | unknown], [],
+ [$1="$$1 -D_LARGEFILE_SOURCE"])
+]) # KPSE_LARGEFILE