blob: 99afc8ca03de37d07fcf600f2e28386a838eaebc [file] [log] [blame]
David 'Digit' Turnera87c3182012-04-21 00:44:33 +02001From 4fe805f627c018d77091ea0aad92553c54d47567 Mon Sep 17 00:00:00 2001
2From: David 'Digit' Turner <digit@google.com>
3Date: Fri, 17 Feb 2012 19:35:45 +0100
David 'Digit' Turner2b29b0f2012-04-20 16:40:04 +02004Subject: Enable C++ exceptions and RTTI by default.
David 'Digit' Turner72497ce2010-11-24 17:28:16 +01005
6With this change, -fexceptions and -frtti become default options
7when compiling C++ sources.
David 'Digit' Turner72497ce2010-11-24 17:28:16 +01008---
9 gcc-4.4.3/gcc/config/linux-android.h | 4 ++--
David 'Digit' Turnera87c3182012-04-21 00:44:33 +020010 gcc-4.6/gcc/config/linux-android.h | 4 ++--
11 2 files changed, 4 insertions(+), 4 deletions(-)
David 'Digit' Turner72497ce2010-11-24 17:28:16 +010012
13diff --git a/gcc-4.4.3/gcc/config/linux-android.h b/gcc-4.4.3/gcc/config/linux-android.h
David 'Digit' Turner2b29b0f2012-04-20 16:40:04 +020014index 5ca3858..d938c22 100644
David 'Digit' Turner72497ce2010-11-24 17:28:16 +010015--- a/gcc-4.4.3/gcc/config/linux-android.h
16+++ b/gcc-4.4.3/gcc/config/linux-android.h
David 'Digit' Turner2b29b0f2012-04-20 16:40:04 +020017@@ -46,8 +46,8 @@
Andrew Hsieh9c513cc2012-10-23 21:31:08 +080018 "%{!fno-pic:%{!fno-PIC:%{!fpic:%{!fPIC: " ANDROID_PIC_DEFAULT "}}}}"
David 'Digit' Turner72497ce2010-11-24 17:28:16 +010019
20 #define ANDROID_CC1PLUS_SPEC \
21- "%{!fexceptions:%{!fno-exceptions: -fno-exceptions}} " \
22- "%{!frtti:%{!fno-rtti: -fno-rtti}}"
23+ "%{!fexceptions:%{!fno-exceptions: -fexceptions}} " \
24+ "%{!frtti:%{!fno-rtti: -frtti}}"
25
Andrew Hsieh9c513cc2012-10-23 21:31:08 +080026 #define ANDROID_ASM_SPEC \
27 "--noexecstack"
David 'Digit' Turnera87c3182012-04-21 00:44:33 +020028diff --git a/gcc-4.6/gcc/config/linux-android.h b/gcc-4.6/gcc/config/linux-android.h
29index 94c5274..7256082 100644
30--- a/gcc-4.6/gcc/config/linux-android.h
31+++ b/gcc-4.6/gcc/config/linux-android.h
32@@ -46,8 +46,8 @@
Andrew Hsieh9c513cc2012-10-23 21:31:08 +080033 "%{!fno-pic:%{!fno-PIC:%{!fpic:%{!fPIC: " ANDROID_PIC_DEFAULT "}}}}"
David 'Digit' Turnera87c3182012-04-21 00:44:33 +020034
35 #define ANDROID_CC1PLUS_SPEC \
36- "%{!fexceptions:%{!fno-exceptions: -fno-exceptions}} " \
37- "%{!frtti:%{!fno-rtti: -fno-rtti}}"
38+ "%{!fexceptions:%{!fno-exceptions: -fexceptions}} " \
39+ "%{!frtti:%{!fno-rtti: -frtti}}"
40
Andrew Hsieh9c513cc2012-10-23 21:31:08 +080041 #define ANDROID_ASM_SPEC \
42 "--noexecstack"
Andrew Hsiehe6aef482012-10-02 22:18:25 +080043diff --git a/gcc-4.7/gcc/config/linux-android.h b/gcc-4.7/gcc/config/linux-android.h
44index 94c5274..7256082 100644
45--- a/gcc-4.7/gcc/config/linux-android.h
46+++ b/gcc-4.7/gcc/config/linux-android.h
47@@ -46,8 +46,8 @@
Andrew Hsieh9c513cc2012-10-23 21:31:08 +080048 "%{!fno-pic:%{!fno-PIC:%{!fpic:%{!fPIC: " ANDROID_PIC_DEFAULT "}}}}"
Andrew Hsiehe6aef482012-10-02 22:18:25 +080049
50 #define ANDROID_CC1PLUS_SPEC \
51- "%{!fexceptions:%{!fno-exceptions: -fno-exceptions}} " \
52- "%{!frtti:%{!fno-rtti: -fno-rtti}}"
53+ "%{!fexceptions:%{!fno-exceptions: -fexceptions}} " \
54+ "%{!frtti:%{!fno-rtti: -frtti}}"
55
Andrew Hsieh9c513cc2012-10-23 21:31:08 +080056 #define ANDROID_ASM_SPEC \
57 "--noexecstack"
David 'Digit' Turner72497ce2010-11-24 17:28:16 +010058--
David 'Digit' Turner2b29b0f2012-04-20 16:40:04 +0200591.7.6.rc0
David 'Digit' Turner72497ce2010-11-24 17:28:16 +010060