[prev in list] [next in list] [prev in thread] [next in thread]
List: gnulib-bug
Subject: Re: [PATCH] stdint, read-file: fix missing SIZE_MAX on Android
From: Paul Eggert <eggert () cs ! ucla ! edu>
Date: 2014-03-06 1:54:23
Message-ID: 5317D54F.60808 () cs ! ucla ! edu
[Download RAW message or body]
Kevin Cernekee wrote:
> How important is it to maintain compatibility with the older NDK releases?
I don't know. But this convinces me that your patch is better. I
rewrote the ChangeLog entry to avoid worries about copyright and
installed the attached. If you plan to contribute more we should start
the ball rolling on getting papers.
["stdint.diff" (text/plain)]
diff --git a/ChangeLog b/ChangeLog
index 4e1984c..2f847e6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2014-03-04 Kevin Cernekee <cernekee@gmail.com>
+
+ stdint, read-file: fix missing SIZE_MAX on Android (tiny change)
+ This is basically one of the options Bruno Haible proposed in:
+ http://lists.gnu.org/archive/html/bug-gnulib/2012-01/msg00282.html
+ * lib/sys_types.in.h (_GL_INCLUDING_UNISTD_H): New macro.
+ * lib/stdint.in.h: Use it.
+ * modules/stdint (Depends-on): Add sys_types.
+
2014-02-26 Pádraig Brady <P@draigBrady.com>
parse-datetime: fix crash or infloop in TZ="" parsing
diff --git a/lib/stdint.in.h b/lib/stdint.in.h
index 91fad37..98ee423 100644
--- a/lib/stdint.in.h
+++ b/lib/stdint.in.h
@@ -38,8 +38,7 @@
other system header files; just include the system's <stdint.h>.
Ideally we should test __BIONIC__ here, but it is only defined after
<sys/cdefs.h> has been included; hence test __ANDROID__ instead. */
-#if defined __ANDROID__ \
- && defined _SYS_TYPES_H_ && !defined __need_size_t
+#if defined __ANDROID__ && defined _GL_INCLUDING_SYS_TYPES_H
# @INCLUDE_NEXT@ @NEXT_STDINT_H@
#else
diff --git a/lib/sys_types.in.h b/lib/sys_types.in.h
index 803d7b1..b3bf9f2 100644
--- a/lib/sys_types.in.h
+++ b/lib/sys_types.in.h
@@ -23,7 +23,9 @@
#ifndef _@GUARD_PREFIX@_SYS_TYPES_H
/* The include_next requires a split double-inclusion guard. */
+# define _GL_INCLUDING_SYS_TYPES_H
#@INCLUDE_NEXT@ @NEXT_SYS_TYPES_H@
+# undef _GL_INCLUDING_SYS_TYPES_H
#ifndef _@GUARD_PREFIX@_SYS_TYPES_H
#define _@GUARD_PREFIX@_SYS_TYPES_H
diff --git a/modules/stdint b/modules/stdint
index 92eb59f..62a5797 100644
--- a/modules/stdint
+++ b/modules/stdint
@@ -14,6 +14,7 @@ m4/longlong.m4
Depends-on:
include_next
multiarch
+sys_types
configure.ac:
gl_STDINT_H
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic