This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

3.0.2 PATCH: Define CPLUSPLUS_CPP_SPEC for Solaris 2/Intel


Looking through the remaining testsuite failures on i386-pc-solaris2.9, I
noticed two groups that are easily fixable:

FAIL: g++.brendan/crash20.C (test for excess errors)
FAIL: g++.law/code-gen5.C (test for excess errors)
FAIL: g++.law/ctors6.C (test for excess errors)
FAIL: g++.other/headers1.C (test for excess errors)
FAIL: g++.robertl/eb3.C (test for excess errors)

all failed as follows:

libstdc++-v3/include/bits/std_cmath.h: In function `float std::modf(float, float*)':
libstdc++-v3/include/bits/std_cmath.h:356: `::modff' undeclared (first use here)

while modff() is declared in <math.h>, but only inside #ifdef
__EXTENSIONS__.  The patch below fixes this by defining CPLUSPLUS_CPP_SPEC
identically to the Solaris 2/SPARC version.

Bootstrapped on i386-pc-solaris2.9 without regressions, removing the
failures above.

Ok for branch and mainline?

	Rainer

-----------------------------------------------------------------------------
Rainer Orth, Faculty of Technology, Bielefeld University

Email: ro@TechFak.Uni-Bielefeld.DE



Tue Sep 25 15:09:03 2001  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>

	* config/i386/sol2.h (CPLUSPLUS_CPP_SPEC): Define.

Index: gcc/config/i386/sol2.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/i386/sol2.h,v
retrieving revision 1.10.4.2
diff -u -p -r1.10.4.2 sol2.h
--- sol2.h	2001/07/03 12:33:09	1.10.4.2
+++ sol2.h	2001/09/25 17:24:53
@@ -82,6 +89,14 @@ Boston, MA 02111-1307, USA.  */
    %{pthreads:-D_REENTRANT -D_PTHREADS} \
    %{!pthreads:%{threads:-D_REENTRANT -D_SOLARIS_THREADS}} \
    %{compat-bsd:-iwithprefixbefore ucbinclude -I/usr/ucbinclude}"
+
+/* For C++ we need to add some additional macro definitions required
+   by the C++ standard library.  */
+#define CPLUSPLUS_CPP_SPEC "\
+-D_XOPEN_SOURCE=500 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1 \
+-D__EXTENSIONS__ \
+%(cpp) \
+"
 
 #undef LIB_SPEC
 #define LIB_SPEC \


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]