summaryrefslogtreecommitdiff
path: root/gcc/config
diff options
context:
space:
mode:
authorro <ro@138bc75d-0d04-0410-961f-82ee72b054a4>2001-06-11 14:48:11 +0000
committerro <ro@138bc75d-0d04-0410-961f-82ee72b054a4>2001-06-11 14:48:11 +0000
commitbf1b7a69299ff8f64bc94530bf7ab846d666bae3 (patch)
treed8184510a65eba36093710a23674d77bcbe84cc4 /gcc/config
parent4361b500fab14c0bcb3f383af33e958ef12c32f3 (diff)
downloadgcc-bf1b7a69299ff8f64bc94530bf7ab846d666bae3.tar.gz
* config/alpha/alpha.h (CPP_SPEC): Don't define __LANGUAGE_C and
variants for .cpp/.cp/.c++ files. Move definition of __LANGUAGE_C_PLUS_PLUS ... (CPLUSPLUS_CPP_SPEC): ... here. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@43190 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config')
-rw-r--r--gcc/config/alpha/alpha.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/gcc/config/alpha/alpha.h b/gcc/config/alpha/alpha.h
index badeaffc326..148a6cffaeb 100644
--- a/gcc/config/alpha/alpha.h
+++ b/gcc/config/alpha/alpha.h
@@ -21,14 +21,20 @@ the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
+/* For C++ we need to ensure that __LANGUAGE_C_PLUS_PLUS is defined independent
+ of the source file extension. */
+#define CPLUSPLUS_CPP_SPEC "\
+-D__LANGUAGE_C_PLUS_PLUS__ -D__LANGUAGE_C_PLUS_PLUS -D__cplusplus \
+%(cpp) \
+"
+
/* Write out the correct language type definition for the header files.
Unless we have assembler language, write out the symbols for C. */
#define CPP_SPEC "\
%{!undef:\
%{.S:-D__LANGUAGE_ASSEMBLY__ -D__LANGUAGE_ASSEMBLY %{!ansi:-DLANGUAGE_ASSEMBLY }}\
-%{.cc|.cxx|.C:-D__LANGUAGE_C_PLUS_PLUS__ -D__LANGUAGE_C_PLUS_PLUS -D__cplusplus }\
%{.m:-D__LANGUAGE_OBJECTIVE_C__ -D__LANGUAGE_OBJECTIVE_C }\
-%{!.S:%{!.cc:%{!.cxx:%{!.C:%{!.m:-D__LANGUAGE_C__ -D__LANGUAGE_C %{!ansi:-DLANGUAGE_C }}}}}}\
+%{!.S:%{!.cc:%{!.cxx:%{!.cpp:%{!.cp:%{!.c++:%{!.C:%{!.m:-D__LANGUAGE_C__ -D__LANGUAGE_C %{!ansi:-DLANGUAGE_C }}}}}}}}}\
%{mieee:-D_IEEE_FP }\
%{mieee-with-inexact:-D_IEEE_FP -D_IEEE_FP_INEXACT }}\
%(cpp_cpu) %(cpp_subtarget)"