This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH]: sh-linux: Define NO_IMPLICIT_EXTERN_C and CPLUSPLUS_CPP_SPEC
- From: kaz Kojima <kkojima at rr dot iij4u dot or dot jp>
- To: gcc-patches at gcc dot gnu dot org
- Date: Wed, 18 Dec 2002 11:04:19 +0900
- Subject: [PATCH]: sh-linux: Define NO_IMPLICIT_EXTERN_C and CPLUSPLUS_CPP_SPEC
Hi,
The attached patch makes sh-linux port closer to the other linux
ports and avoids many spurious fails in g++ testsuite. Committed
to mainline.
BTW, there are about 16 real regressions in mainline g++ testsuite
on sh4-unknown-liunx-gnu which passed at 3.4-bib 20021202. I'm
trying to find the cause of these new regressions.
Regards,
kaz
--
2002-12-18 Kaz kojima <kkojima@gcc.gnu.org>
* config/sh/linux.h (NO_IMPLICIT_EXTERN_C, CPLUSPLUS_CPP_SPEC):
Define.
diff -urN ORIG/gcc/gcc/config/sh/linux.h LOCAL/gcc/gcc/config/sh/linux.h
--- ORIG/gcc/gcc/config/sh/linux.h Tue Dec 17 07:12:52 2002
+++ LOCAL/gcc/gcc/config/sh/linux.h Wed Dec 18 07:27:24 2002
@@ -30,6 +30,13 @@
/* This was defined in linux.h. Define it here also. */
#define HANDLE_PRAGMA_PACK_PUSH_POP
+/* Don't assume anything about the header files. */
+#define NO_IMPLICIT_EXTERN_C
+
+/* The GNU C++ standard library requires that these macros be defined. */
+#undef CPLUSPLUS_CPP_SPEC
+#define CPLUSPLUS_CPP_SPEC "-D_GNU_SOURCE %(cpp)"
+
/* Enable DWARF 2 exceptions. */
#undef DWARF2_UNWIND_INFO
#define DWARF2_UNWIND_INFO 1