487N/A#
487N/A# CDDL HEADER START
487N/A#
487N/A# The contents of this file are subject to the terms of the
487N/A# Common Development and Distribution License (the "License").
487N/A# You may not use this file except in compliance with the License.
487N/A#
487N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
487N/A# or http://www.opensolaris.org/os/licensing.
487N/A# See the License for the specific language governing permissions
487N/A# and limitations under the License.
487N/A#
487N/A# When distributing Covered Code, include this CDDL HEADER in each
487N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
487N/A# If applicable, add the following below this CDDL HEADER, with the
487N/A# fields enclosed by brackets "[]" replaced with your own identifying
487N/A# information: Portions Copyright [yyyy] [name of copyright owner]
487N/A#
487N/A# CDDL HEADER END
487N/A#
3996N/A# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
487N/A#
487N/Ainclude ../../make-rules/shared-macros.mk
487N/A
487N/ACOMPONENT_NAME= gcc
487N/ACOMPONENT_VERSION= 4.5.2
618N/ACOMPONENT_PROJECT_URL= http://gcc.gnu.org/
487N/ACOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
487N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz
844N/ACOMPONENT_ARCHIVE_HASH= \
844N/A sha256:07b880faf29f3f9d9c0953717002ac29f5d061427797d2487a7c9c169e6395b3
487N/ACOMPONENT_ARCHIVE_URL= http://ftp.gnu.org/gnu/gcc/$(COMPONENT_SRC)/$(COMPONENT_ARCHIVE)
1608N/ACOMPONENT_ARCHIVE_1= testsuite-$(COMPONENT_VERSION).tar.gz
1608N/ACOMPONENT_ARCHIVE_URL_1 = \
1608N/A http://ftp.gnu.org/pub/gnu/gcc/$(COMPONENT_SRC)/gcc-$(COMPONENT_ARCHIVE_1)
1608N/ACOMPONENT_ARCHIVE_HASH_1= \
1608N/A sha256:aeb50a52831048da9a6aed118d85a25fc33fa73cae6c80df8f84885712e1b357
1273N/ACOMPONENT_BUGDB= utility/gnu-compiler
487N/A
3661N/ATPNO= 4456
3661N/A
3996N/Ainclude $(WS_MAKE_RULES)/prep.mk
3996N/Ainclude $(WS_MAKE_RULES)/configure.mk
3996N/Ainclude $(WS_MAKE_RULES)/ips.mk
487N/A
523N/APATH=/usr/bin:/usr/gnu/bin:/usr/perl5/bin
523N/A
487N/APARCH = $(MACH:i386=i386-pc)
487N/AGNU_ARCH = $(PARCH:sparc=sparc-sun)-solaris$(SOLARIS_VERSION)
487N/A
487N/APKG_MACROS += GNU_ARCH="$(GNU_ARCH)"
487N/A
487N/A# This product bootstraps itself. The gcc flags are not the same
487N/A# as Studio flags. -O2 means different things for the two compilers
487N/ACFLAGS=-g -O2
487N/ACFLAGS_FOR_BUILD=$(CFLAGS)
487N/A
487N/A# CC_BITS may get in the way
487N/ACC_BITS=
487N/A
487N/ACONFIG_SHELL = /bin/sh
487N/A
487N/ACONFIGURE_PREFIX = /usr/gcc/4.5
487N/A
723N/ACONFIGURE_OPTIONS += --infodir=$(CONFIGURE_PREFIX)/share/info
723N/ACONFIGURE_OPTIONS += --libexecdir=$(CONFIGURE_PREFIX)/lib
723N/ACONFIGURE_OPTIONS += --enable-languages="c,c++,fortran,objc"
723N/ACONFIGURE_OPTIONS += --enable-shared
723N/ACONFIGURE_OPTIONS += --with-gmp-include=/usr/include/gmp
723N/ACONFIGURE_OPTIONS += --with-mpfr-include=/usr/include/mpfr
723N/ACONFIGURE_OPTIONS += --without-gnu-ld --with-ld=/usr/bin/ld
723N/A
1608N/ACOMPONENT_POST_UNPACK_ACTION = \
1608N/A ( cd $(COMPONENT_DIR) ; \
1608N/A tar xvf testsuite-$(COMPONENT_VERSION).tar.gz > /dev/null 2>&1 )
1608N/A
723N/A# sparc and x86 use different assemblers
723N/ACONFIGURE_OPTIONS.sparc += --without-gnu-as --with-as=/usr/bin/as
723N/ACONFIGURE_OPTIONS.i386 += --with-gnu-as --with-as=/usr/gnu/bin/as
723N/ACONFIGURE_OPTIONS += $(CONFIGURE_OPTIONS.$(MACH))
723N/A
723N/ACONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)"
487N/A
1608N/A# Keep ASLR disabled (the default) for gcc 4.5; build often core dumps with ASLR
1608N/A
487N/ACOMPONENT_BUILD_ENV += SHELL=$(CONFIG_SHELL)
487N/A
487N/ACOMPONENT_BUILD_TARGETS=bootstrap
487N/A
487N/Abuild: $(BUILD_32)
487N/A
487N/Ainstall: $(INSTALL_32)
487N/A
1608N/A# To ensure that all tests that are expected to pass actually
1608N/A# pass, we have to increase the stacksize limit to at least
1608N/A# 16384 Kb. Otherwise we'll get spurious failures in the test
1608N/A# harness (gcc.c-torture/compile/limits-exprparen.c and others).
1608N/A# With the soft stacksize limit set to 16384 we get very good
1608N/A# test results.
1608N/Atest:
1608N/A ( cd $(BUILD_DIR_32)/gcc ; \
1608N/A ulimit -Ss 16384 ; \
1608N/A $(GMAKE) check )
487N/A
487N/A
3996N/AREQUIRED_PACKAGES += developer/assembler
3996N/AREQUIRED_PACKAGES += developer/gnu-binutils
3996N/AREQUIRED_PACKAGES += library/gmp
3996N/AREQUIRED_PACKAGES += library/mpc
3996N/AREQUIRED_PACKAGES += library/mpfr
3996N/AREQUIRED_PACKAGES += shell/ksh93
3996N/AREQUIRED_PACKAGES += system/library
3996N/AREQUIRED_PACKAGES += system/library/gcc-45-runtime
3996N/AREQUIRED_PACKAGES += system/library/gcc/gcc-c-runtime
3996N/AREQUIRED_PACKAGES += system/library/math
3996N/AREQUIRED_PACKAGES += system/linker