diff mbox

[i386,Android] Enable __ANDROID__ macro for Android i386 target

Message ID CAMbmDYZbV7k31dYEy_Yc-gFJS-E7rwjcLv7Y0nXugmqrjEWQTg@mail.gmail.com
State New
Headers show

Commit Message

Ilya Enkovich Feb. 27, 2012, 2:39 p.m. UTC
>
> Undef TARGET_OS_CPP_BUILTINS and define TARGET_OS_CPP_BUILTINS
> in linux.h with GNU_USER_TARGET_OS_CPP_BUILTINS and
> ANDROID_TARGET_OS_CPP_BUILTINS.
>
>
> --
> H.J.

Hello,

Here is a variant with linux.h modification. Does it look fine?

Thanks,
Ilya
--
2012-02-27  Enkovich Ilya  <ilya.enkovich@intel.com>

	* gcc/config/i386/linux.h (TARGET_OS_CPP_BUILTINS): New.

Comments

Ilya Enkovich March 13, 2012, 11:12 a.m. UTC | #1
Ping

27 февраля 2012 г. 6:39 пользователь Ilya Enkovich
<enkovich.gnu@gmail.com> написал:
>>
>> Undef TARGET_OS_CPP_BUILTINS and define TARGET_OS_CPP_BUILTINS
>> in linux.h with GNU_USER_TARGET_OS_CPP_BUILTINS and
>> ANDROID_TARGET_OS_CPP_BUILTINS.
>>
>>
>> --
>> H.J.
>
> Hello,
>
> Here is a variant with linux.h modification. Does it look fine?
>
> Thanks,
> Ilya
> --
> 2012-02-27  Enkovich Ilya  <ilya.enkovich@intel.com>
>
>        * gcc/config/i386/linux.h (TARGET_OS_CPP_BUILTINS): New.
>
>
> diff --git a/gcc/config/i386/linux.h b/gcc/config/i386/linux.h
> index 73681fe..03c7b29 100644
> --- a/gcc/config/i386/linux.h
> +++ b/gcc/config/i386/linux.h
> @@ -22,3 +22,12 @@ along with GCC; see the file COPYING3.  If not see
>
>  #define GNU_USER_LINK_EMULATION "elf_i386"
>  #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
> +
> +#undef TARGET_OS_CPP_BUILTINS
> +#define TARGET_OS_CPP_BUILTINS()               \
> +  do                                           \
> +    {                                          \
> +       GNU_USER_TARGET_OS_CPP_BUILTINS();      \
> +       ANDROID_TARGET_OS_CPP_BUILTINS();       \
> +    }                                          \
> +  while (0)
Ilya Enkovich March 27, 2012, 1:56 p.m. UTC | #2
Ping

13 марта 2012 г. 15:12 пользователь Ilya Enkovich
<enkovich.gnu@gmail.com> написал:
> Ping
>
> 27 февраля 2012 г. 6:39 пользователь Ilya Enkovich
> <enkovich.gnu@gmail.com> написал:
>>>
>>> Undef TARGET_OS_CPP_BUILTINS and define TARGET_OS_CPP_BUILTINS
>>> in linux.h with GNU_USER_TARGET_OS_CPP_BUILTINS and
>>> ANDROID_TARGET_OS_CPP_BUILTINS.
>>>
>>>
>>> --
>>> H.J.
>>
>> Hello,
>>
>> Here is a variant with linux.h modification. Does it look fine?
>>
>> Thanks,
>> Ilya
>> --
>> 2012-02-27  Enkovich Ilya  <ilya.enkovich@intel.com>
>>
>>        * gcc/config/i386/linux.h (TARGET_OS_CPP_BUILTINS): New.
>>
>>
>> diff --git a/gcc/config/i386/linux.h b/gcc/config/i386/linux.h
>> index 73681fe..03c7b29 100644
>> --- a/gcc/config/i386/linux.h
>> +++ b/gcc/config/i386/linux.h
>> @@ -22,3 +22,12 @@ along with GCC; see the file COPYING3.  If not see
>>
>>  #define GNU_USER_LINK_EMULATION "elf_i386"
>>  #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
>> +
>> +#undef TARGET_OS_CPP_BUILTINS
>> +#define TARGET_OS_CPP_BUILTINS()               \
>> +  do                                           \
>> +    {                                          \
>> +       GNU_USER_TARGET_OS_CPP_BUILTINS();      \
>> +       ANDROID_TARGET_OS_CPP_BUILTINS();       \
>> +    }                                          \
>> +  while (0)
Jing Yu March 28, 2012, 10:58 p.m. UTC | #3
This patch looks good for Android toolchain. But I am not a maintainer.
Can any x86 backend maintainer help to review the patch?

Thanks,
Jing

On Tue, Mar 27, 2012 at 6:56 AM, Ilya Enkovich <enkovich.gnu@gmail.com> wrote:
> Ping
>
> 13 марта 2012 г. 15:12 пользователь Ilya Enkovich
> <enkovich.gnu@gmail.com> написал:
>> Ping
>>
>> 27 февраля 2012 г. 6:39 пользователь Ilya Enkovich
>> <enkovich.gnu@gmail.com> написал:
>>>>
>>>> Undef TARGET_OS_CPP_BUILTINS and define TARGET_OS_CPP_BUILTINS
>>>> in linux.h with GNU_USER_TARGET_OS_CPP_BUILTINS and
>>>> ANDROID_TARGET_OS_CPP_BUILTINS.
>>>>
>>>>
>>>> --
>>>> H.J.
>>>
>>> Hello,
>>>
>>> Here is a variant with linux.h modification. Does it look fine?
>>>
>>> Thanks,
>>> Ilya
>>> --
>>> 2012-02-27  Enkovich Ilya  <ilya.enkovich@intel.com>
>>>
>>>        * gcc/config/i386/linux.h (TARGET_OS_CPP_BUILTINS): New.
>>>
>>>
>>> diff --git a/gcc/config/i386/linux.h b/gcc/config/i386/linux.h
>>> index 73681fe..03c7b29 100644
>>> --- a/gcc/config/i386/linux.h
>>> +++ b/gcc/config/i386/linux.h
>>> @@ -22,3 +22,12 @@ along with GCC; see the file COPYING3.  If not see
>>>
>>>  #define GNU_USER_LINK_EMULATION "elf_i386"
>>>  #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
>>> +
>>> +#undef TARGET_OS_CPP_BUILTINS
>>> +#define TARGET_OS_CPP_BUILTINS()               \
>>> +  do                                           \
>>> +    {                                          \
>>> +       GNU_USER_TARGET_OS_CPP_BUILTINS();      \
>>> +       ANDROID_TARGET_OS_CPP_BUILTINS();       \
>>> +    }                                          \
>>> +  while (0)
Maxim Kuvyrkov March 29, 2012, 4:51 a.m. UTC | #4
On 28/02/2012, at 3:39 AM, Ilya Enkovich wrote:

>> 
>> Undef TARGET_OS_CPP_BUILTINS and define TARGET_OS_CPP_BUILTINS
>> in linux.h with GNU_USER_TARGET_OS_CPP_BUILTINS and
>> ANDROID_TARGET_OS_CPP_BUILTINS.
>> 
>> 
>> --
>> H.J.
> 
> Hello,
> 
> Here is a variant with linux.h modification. Does it look fine?
> 
> Thanks,
> Ilya
> --
> 2012-02-27  Enkovich Ilya  <ilya.enkovich@intel.com>
> 
> 	* gcc/config/i386/linux.h (TARGET_OS_CPP_BUILTINS): New.
> 
> 
> diff --git a/gcc/config/i386/linux.h b/gcc/config/i386/linux.h
> index 73681fe..03c7b29 100644
> --- a/gcc/config/i386/linux.h
> +++ b/gcc/config/i386/linux.h
> @@ -22,3 +22,12 @@ along with GCC; see the file COPYING3.  If not see
> 
> #define GNU_USER_LINK_EMULATION "elf_i386"
> #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
> +
> +#undef TARGET_OS_CPP_BUILTINS
> +#define TARGET_OS_CPP_BUILTINS()		\
> +  do						\
> +    {						\
> +	GNU_USER_TARGET_OS_CPP_BUILTINS();	\
> +	ANDROID_TARGET_OS_CPP_BUILTINS();	\
> +    }						\
> +  while (0)


This is OK provided (1) i386/linux.h renamed to i386/linux32.h as per review of your other patch, (2) this change is made to "new" i386/linux.h, and (3) Uros and any other i386 doesn't object.

Please hold off this patch until your other Android *_SPEC changes are approved.

Thank you,

--
Maxim Kuvyrkov
CodeSourcery / Mentor Graphics
Jan Hubicka March 29, 2012, 5:50 p.m. UTC | #5
> >
> > Undef TARGET_OS_CPP_BUILTINS and define TARGET_OS_CPP_BUILTINS
> > in linux.h with GNU_USER_TARGET_OS_CPP_BUILTINS and
> > ANDROID_TARGET_OS_CPP_BUILTINS.
> >
> >
> > --
> > H.J.
> 
> Hello,
> 
> Here is a variant with linux.h modification. Does it look fine?
OK,
Honza
diff mbox

Patch

diff --git a/gcc/config/i386/linux.h b/gcc/config/i386/linux.h
index 73681fe..03c7b29 100644
--- a/gcc/config/i386/linux.h
+++ b/gcc/config/i386/linux.h
@@ -22,3 +22,12 @@  along with GCC; see the file COPYING3.  If not see

 #define GNU_USER_LINK_EMULATION "elf_i386"
 #define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
+
+#undef TARGET_OS_CPP_BUILTINS
+#define TARGET_OS_CPP_BUILTINS()		\
+  do						\
+    {						\
+	GNU_USER_TARGET_OS_CPP_BUILTINS();	\
+	ANDROID_TARGET_OS_CPP_BUILTINS();	\
+    }						\
+  while (0)