summaryrefslogtreecommitdiff
path: root/lang
diff options
context:
space:
mode:
authordmcmahill <dmcmahill>2003-02-06 21:52:19 +0000
committerdmcmahill <dmcmahill>2003-02-06 21:52:19 +0000
commit57e5a66f712fcdb08b610cfe1e3a7f29f000eda1 (patch)
tree8c9362a144ff13e6b67efccfc258170edba30e14 /lang
parent90e2518f479b5cb93c2b387d1c78ab3374df08a4 (diff)
downloadpkgsrc-57e5a66f712fcdb08b610cfe1e3a7f29f000eda1.tar.gz
on alpha, turn off optimization for the first part of the build. This
works around a bug with optimization in gcc-2.95.3 which prevents building this pkg. Optimization is still turned on during the build of the final libraries and compilers.
Diffstat (limited to 'lang')
-rw-r--r--lang/gcc3/Makefile23
1 files changed, 22 insertions, 1 deletions
diff --git a/lang/gcc3/Makefile b/lang/gcc3/Makefile
index 174e5a22ff3..451b620f4c4 100644
--- a/lang/gcc3/Makefile
+++ b/lang/gcc3/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.4 2003/01/28 22:03:27 jlam Exp $
+# $NetBSD: Makefile,v 1.5 2003/02/06 21:52:19 dmcmahill Exp $
# Make sure that the version number in "Makefile.gcc" matches this.
DISTNAME= gcc-3.2.1
@@ -69,3 +69,24 @@ post-install:
# Make bootstrap with compiler != gcc possible.
LDFLAGS= ${_STRIPFLAG_CC}
+
+# On NetBSD, the gcc-2.95.3 for:
+#
+# alpha
+#
+# have an optimization bug when compiling with -O2 that is tickled by:
+#
+# java/parse.o
+#
+# note that we don't override CFLAGS and CPPFLAGS because we want the
+# crosscompiled compiler to be build with optimization. This only
+# disables optimization for the stage 1 build.
+#
+.if ${OPSYS} == "NetBSD"
+. if (${MACHINE_ARCH} == "alpha")
+CONFIG_CFLAGS= ${CFLAGS:C/-O[0-9]*//g}
+CONFIG_CPPFLAGS= ${CPPFLAGS:C/-O[0-9]*//g}
+CONFIGURE_ENV+= CFLAGS="${CONFIG_CFLAGS}" CPPFLAGS="${CONFIG_CPPFLAGS}"
+. endif
+.endif
+