+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.
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;
%{!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},