|
|
4fe85b |
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
4fe85b |
From: Andrey Borzenkov <arvidjaar@gmail.com>
|
|
|
4fe85b |
Date: Tue, 7 Jan 2014 18:43:02 +0400
|
|
|
4fe85b |
Subject: [PATCH] fix 32 bit compilation on MinGW-w64
|
|
|
4fe85b |
|
|
|
4fe85b |
Use _FILE_OFFSET_BITS macro to distinguish between native MinGW and
|
|
|
4fe85b |
32 bit under MinGW-64. The latter does not require fseeko/ftello
|
|
|
4fe85b |
redefinition which it already does in case of _FILE_OFFSET_BITS=64.
|
|
|
4fe85b |
---
|
|
|
4fe85b |
include/grub/osdep/hostfile_windows.h | 3 +++
|
|
|
4fe85b |
ChangeLog | 5 +++++
|
|
|
4fe85b |
2 files changed, 8 insertions(+)
|
|
|
4fe85b |
|
|
|
4fe85b |
diff --git a/include/grub/osdep/hostfile_windows.h b/include/grub/osdep/hostfile_windows.h
|
|
|
4fe85b |
index 36615b2c451..79efcfa5084 100644
|
|
|
4fe85b |
--- a/include/grub/osdep/hostfile_windows.h
|
|
|
4fe85b |
+++ b/include/grub/osdep/hostfile_windows.h
|
|
|
4fe85b |
@@ -69,8 +69,11 @@ enum grub_util_fd_open_flags_t
|
|
|
4fe85b |
|
|
|
4fe85b |
#if defined (__MINGW32__) && !defined (__MINGW64__)
|
|
|
4fe85b |
|
|
|
4fe85b |
+/* 32 bit on MinGW-64 already redefines them if _FILE_OFFSET_BITS=64 */
|
|
|
4fe85b |
+#if !defined(_FILE_OFFSET_BITS)
|
|
|
4fe85b |
#define fseeko fseeko64
|
|
|
4fe85b |
#define ftello ftello64
|
|
|
4fe85b |
+#endif
|
|
|
4fe85b |
|
|
|
4fe85b |
#endif
|
|
|
4fe85b |
|
|
|
4fe85b |
diff --git a/ChangeLog b/ChangeLog
|
|
|
4fe85b |
index 8c1ececa1ed..e87f0a7a4a4 100644
|
|
|
4fe85b |
--- a/ChangeLog
|
|
|
4fe85b |
+++ b/ChangeLog
|
|
|
4fe85b |
@@ -1,3 +1,8 @@
|
|
|
4fe85b |
+2014-01-07 Andrey Borzenkov <arvidjaar@gmail.com>
|
|
|
4fe85b |
+
|
|
|
4fe85b |
+ * include/grub/osdep/hostfile_windows.h: Do not redefine fseeko/ftello
|
|
|
4fe85b |
+ on MinGW-64 when compiling for 32 bits.
|
|
|
4fe85b |
+
|
|
|
4fe85b |
2013-12-30 Andrey Borzenkov <arvidjaar@gmail.com>
|
|
|
4fe85b |
|
|
|
4fe85b |
* grub-core/Makefile.core.def: strip .eh_frame section for arm64-efi.
|