diff options
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 8 | ||||
-rw-r--r-- | gcc/c-pch.c | 12 | ||||
-rw-r--r-- | gcc/objc/lang-specs.h | 10 |
3 files changed, 17 insertions, 13 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1debc69..0802120 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2003-03-07 Geoffrey Keating <geoffk@apple.com> + + * objc/lang-specs.h (objective-c-header): Use .gch not .pch; + support -no-integrated-cpp. + + * c-pch.c (get_ident): Use c_language_kind and flag_objc rather + than langhooks.name. + 2003-03-07 Michael Matz <matz@suse.de> * df.h (enum df_ref_flags.DF_REF_STRIPPED): New. diff --git a/gcc/c-pch.c b/gcc/c-pch.c index 7e67248..d8c6b9e 100644 --- a/gcc/c-pch.c +++ b/gcc/c-pch.c @@ -52,14 +52,10 @@ get_ident() static const char template[IDENT_LENGTH] = "gpch.010"; memcpy (result, template, IDENT_LENGTH); - if (strcmp (lang_hooks.name, "GNU C") == 0) - result[4] = 'C'; - else if (strcmp (lang_hooks.name, "GNU C++") == 0) - result[4] = '+'; - else if (strcmp (lang_hooks.name, "GNU Objective-C") == 0) - result[4] = 'o'; - else if (strcmp (lang_hooks.name, "GNU Objective-C++") == 0) - result[4] = 'O'; + if (c_language == clk_c) + result[4] = flag_objc ? 'o' : 'C'; + else if (c_language == clk_cplusplus) + result[4] = flag_objc ? 'O' : '+'; else abort (); return result; diff --git a/gcc/objc/lang-specs.h b/gcc/objc/lang-specs.h index 379547f..0e7a46f 100644 --- a/gcc/objc/lang-specs.h +++ b/gcc/objc/lang-specs.h @@ -44,11 +44,11 @@ Boston, MA 02111-1307, USA. */ %{!E:%{!M:%{!MM:\ %{traditional|ftraditional|traditional-cpp:\ %eGNU Objective C no longer supports traditional compilation}\ - %{save-temps:cc1obj -E %(cpp_options) %b.mi \n\ + %{save-temps|no-integrated-cpp:cc1obj -E %(cpp_options) %b.mi \n\ cc1obj -fpreprocessed %b.mi %(cc1_options) %{gen-decls}\ - -o %g.s %{!o*:--output-pch=%i.pch}\ + -o %g.s %{!o*:--output-pch=%i.gch}\ %W{o*:--output-pch=%*}%V}\ - %{!save-temps:\ + %{!save-temps:%{!no-integrated-cpp:\ cc1obj %(cpp_unique_options) %(cc1_options) %{gen-decls}\ - -o %g.s %{!o*:--output-pch=%i.pch}\ - %W{o*:--output-pch=%*}%V}}}}", 0}, + -o %g.s %{!o*:--output-pch=%i.gch}\ + %W{o*:--output-pch=%*}%V}}}}}", 0}, |