aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-bsp/grub/files/0001-configure.ac-support-disabling-largefile.patch
blob: e22dc00f6f0c73407a941a725684169a968547b3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
Upstream-Status: Pending

Subject: configure.ac: support disabling largefile

Do not check off_t size when largefile is disabled.

Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
---
 configure.ac | 19 ++++++++++++-------
 1 file changed, 12 insertions(+), 7 deletions(-)

diff --git a/configure.ac b/configure.ac
index df20991..14ff7ac 100644
--- a/configure.ac
+++ b/configure.ac
@@ -306,13 +306,18 @@ if test x$grub_cv_apple_cc = xyes ; then
   HOST_LDFLAGS="$HOST_LDFLAGS -Wl,-allow_stack_execute"
 fi
 
-case "$host_os" in
-  cygwin | windows* | mingw32* | aros*)
-     ;;
-  *)
-     AC_CHECK_SIZEOF(off_t)
-     test x"$ac_cv_sizeof_off_t" = x8 || AC_MSG_ERROR([Large file support is required]);;
-esac
+AC_ARG_ENABLE([largefile],
+              [AS_HELP_STRING([--enable-largefile],
+                             [Enable large file support (default=guessed)])])
+if test x"$enable_largefile" = xyes ; then
+  case "$host_os" in
+    cygwin | windows* | mingw32* | aros*)
+       ;;
+    *)
+       AC_CHECK_SIZEOF(off_t)
+       test x"$ac_cv_sizeof_off_t" = x8 || AC_MSG_ERROR([Large file support is required]);;
+  esac
+fi
 
 if test x$USE_NLS = xno; then
   HOST_CFLAGS="$HOST_CFLAGS -fno-builtin-gettext"
-- 
1.9.1