This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [google] Disable getpagesize() for Android toolchain (issue4515131)


Hi

I've tested the

#ifndef __ANDROID__

on arm qemu without regression. And also built Android toolchain
without this error.

thanks
Carrot


2011-05-26  Jing Yu  <jingyu@google.com>

        * ChangeLog.google-main: New file.
        * getpagesize.c(getpagesize): Disable it for bionic.


Index: ChangeLog.google-main
===================================================================
--- ChangeLog.google-main	(revision 0)
+++ ChangeLog.google-main	(revision 0)
@@ -0,0 +1,5 @@
+Copyright (C) 2011 Free Software Foundation, Inc.
+
+Copying and distribution of this file, with or without modification,
+are permitted in any medium without royalty provided the copyright
+notice and this notice are preserved.
Index: getpagesize.c
===================================================================
--- getpagesize.c	(revision 174099)
+++ getpagesize.c	(working copy)
@@ -60,11 +60,13 @@ BUGS
 # endif /* PAGESIZE */
 #endif /* GNU_OUR_PAGESIZE */

+#ifndef __ANDROID__
 int
 getpagesize (void)
 {
   return (GNU_OUR_PAGESIZE);
 }
+#endif

 #else /* VMS */


On Wed, May 25, 2011 at 2:07 AM, Doug Kwan (éæå) <dougkwan@google.com> wrote:
> Shouldn't we test
>
> ifndef __ANDROID__
>
> instead?
>
> -Doug
>
> On Tue, May 24, 2011 at 2:39 AM, Guozhi Wei <carrot@google.com> wrote:
>> Hi
>>
>> This patch is for google/main.
>>
>> In order to be compatible with current bionic and sysroot, we need to disable
>> getpagesize(). After getpagesize() in bionic is changed and ndk contains that
>> change, we can reenable it.
>>
>> Jing can give more details about it.
>>
>> This patch has been tested on arm qemu without regression.
>>
>> thanks
>> Carrot
>>
>> 2011-05-24 ÂJing Yu Â<jingyu@google.com>
>>
>> Â Â Â Â* ChangeLog.google-main: New file.
>> Â Â Â Â* getpagesize.c(getpagesize): Disable it for bionic.
>>
>>
>> Index: ChangeLog.google-main
>> ===================================================================
>> --- ChangeLog.google-main    (revision 0)
>> +++ ChangeLog.google-main    (revision 0)
>> @@ -0,0 +1,5 @@
>> +Copyright (C) 2011 Free Software Foundation, Inc.
>> +
>> +Copying and distribution of this file, with or without modification,
>> +are permitted in any medium without royalty provided the copyright
>> +notice and this notice are preserved.
>> Index: getpagesize.c
>> ===================================================================
>> --- getpagesize.c    (revision 174099)
>> +++ getpagesize.c    (working copy)
>> @@ -60,11 +60,13 @@ BUGS
>> Â# endif /* PAGESIZE */
>> Â#endif /* GNU_OUR_PAGESIZE */
>>
>> +#if DEFAULT_LIBC != LIBC_BIONIC
>> Âint
>> Âgetpagesize (void)
>> Â{
>> Â return (GNU_OUR_PAGESIZE);
>> Â}
>> +#endif
>>
>> Â#else /* VMS */
>>
>>
>> --
>> This patch is available for review at http://codereview.appspot.com/4515131
>>
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]