config.gcc (LIBC_GLIBC, [...]): Move constants to top level.
authorMaxim Kuvyrkov <maxim@codesourcery.com>
Mon, 19 Jul 2010 20:05:46 +0000 (20:05 +0000)
committerMaxim Kuvyrkov <mkuvyrkov@gcc.gnu.org>
Mon, 19 Jul 2010 20:05:46 +0000 (20:05 +0000)
* config.gcc (LIBC_GLIBC, LIBC_UCLIBC, LIBC_BIONIC): Move constants
to top level.
* config/linux.h (LINUX_TARGET_OS_CPP_BUILTINS): Move Android-specific
definitions ...
* config/linux-android.h (ANDROID_TARGET_OS_CPP_BUILTINS): ... here.
New macro.
* config/arm/linux-eabi.h (TARGET_OS_CPP_BUILTINS): Use it.

From-SVN: r162315

gcc/ChangeLog
gcc/config.gcc
gcc/config/arm/linux-eabi.h
gcc/config/linux-android.h
gcc/config/linux.h

index 1f37815b0c52d4d2d84e7e1109959327223cfdd2..5ce760f92efede25535dffe0ba97b916d596d5e7 100644 (file)
@@ -1,3 +1,13 @@
+2010-07-20  Maxim Kuvyrkov  <maxim@codesourcery.com>
+
+       * config.gcc (LIBC_GLIBC, LIBC_UCLIBC, LIBC_BIONIC): Move constants
+       to top level.
+       * config/linux.h (LINUX_TARGET_OS_CPP_BUILTINS): Move Android-specific
+       definitions ...
+       * config/linux-android.h (ANDROID_TARGET_OS_CPP_BUILTINS): ... here.
+       New macro.
+       * config/arm/linux-eabi.h (TARGET_OS_CPP_BUILTINS): Use it.
+
 2010-07-19  Richard Sandiford  <rdsandiford@googlemail.com>
 
        * gengtype.c (start_root_entry): New function, split out from
index 31ea32e56f0df58bffc95cf95c75ab23d7990f1b..12b245d219d930939428c7047ebbb9d94e88b4c1 100644 (file)
@@ -405,6 +405,9 @@ case ${target} in
        ;;
 esac
 
+# Common C libraries.
+tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3"
+
 # Common parts for widely ported systems.
 case ${target} in
 *-*-darwin*)
@@ -508,8 +511,6 @@ case ${target} in
     *-*-gnu*)
       tmake_file="$tmake_file t-gnu";;
   esac
-  # Common C libraries.
-  tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3"
   # glibc / uclibc / bionic switch.
   # uclibc and bionic aren't usable for GNU/Hurd and neither for GNU/k*BSD.
   case $target in
index e69035e590dc139d8868d76ac25e5f76c2242661..1c034bc0496acacc22525eb1e5025745260c4295 100644 (file)
@@ -27,6 +27,7 @@
     {                                          \
       TARGET_BPABI_CPP_BUILTINS();             \
       LINUX_TARGET_OS_CPP_BUILTINS();          \
+      ANDROID_TARGET_OS_CPP_BUILTINS();                \
     }                                          \
   while (false)
 
index a43bab5b0357145cba876fdedcfb4533f724d064..94c52748fdb54f351a11a33fb38e812318dc4940 100644 (file)
    along with GCC; see the file COPYING3.  If not see
    <http://www.gnu.org/licenses/>.  */
 
+#define ANDROID_TARGET_OS_CPP_BUILTINS()                       \
+    do {                                                       \
+       if (OPTION_ANDROID)                                     \
+         builtin_define ("__ANDROID__");                       \
+    } while (0)
+
 #if ANDROID_DEFAULT
 # define NOANDROID "mno-android"
 #else
index 241e65668f015abb18cfb61bd6eb7fc4093d71f7..e283a9a3305581e2ee7c98e6e62ee4df5e18a800 100644 (file)
@@ -96,8 +96,6 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
        builtin_assert ("system=linux");                        \
        builtin_assert ("system=unix");                         \
        builtin_assert ("system=posix");                        \
-       if (OPTION_ANDROID)                                     \
-         builtin_define ("__ANDROID__");                       \
     } while (0)
 
 #if defined(HAVE_LD_EH_FRAME_HDR)