Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 332445 - >=sys-devel/gcc-4.4 fails to build on Solaris/Sparc
Summary: >=sys-devel/gcc-4.4 fails to build on Solaris/Sparc
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: Sparc Solaris
: High normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
: 359405 (view as bug list)
Depends on: 293106
Blocks:
  Show dependency tree
 
Reported: 2010-08-12 15:28 UTC by Eric Meddaugh
Modified: 2011-08-10 14:37 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,790.88 KB, text/plain)
2010-08-12 15:30 UTC, Eric Meddaugh
Details
Extended T namespace patch to make it work on sparc (gcc-4.4.4-T-namespace.patch,5.06 KB, patch)
2010-08-22 19:59 UTC, Maurice van der Pot (RETIRED)
Details | Diff
GCC - File build.log (build.log.gz,44.95 KB, application/octet-stream)
2011-03-18 19:45 UTC, Eugenio Grytsenko
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Meddaugh 2010-08-12 15:28:25 UTC
I was able to get the 4.4.4 on sparc past the T-namespace patch problem (bug 330825).  However it still will not compile:

# Recursively invoke make in the GCC directory to build any
# startfiles (for now).  We must do this just once, passing
# it all the GCC_EXTRA_PARTS as simultaneous goal targets,
# so that rules which cannot execute simultaneously are properly
# serialized.  We indirect through T_TARGET in case any multilib
# directories contain an equals sign, to prevent make from
# interpreting any of the goals as variable assignments.
# We must use cd && make rather than make -C, or else the stage
# number will be embedded in debug information.
_T_=`${PWDCMD-pwd}`/ \
        && cd ../.././gcc \
        && make
GCC_FOR_TARGET="/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.4-r1/work/build/./gcc/xgcc
-B/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.4-r1/work/build/./gcc/
-B/sys_tools/usr/sparc-sun-solaris2.10/bin/
-B/sys_tools/usr/sparc-sun-solaris2.10/lib/ -isystem
/sys_tools/usr/sparc-sun-solaris2.10/include -isystem
/sys_tools/usr/sparc-sun-solaris2.10/sys-include" \
          MULTILIB_CFLAGS="-g -O2 -pipe" \
          _T_=$_T_ \
          T_TARGET="${_T_}crt1.o ${_T_}crtbegin.o ${_T_}crtend.o
${_T_}crtfastmath.o ${_T_}crti.o ${_T_}crtn.o ${_T_}gcrt1.o ${_T_}gmon.o" \
          T_TARGET
make[4]: Entering directory
`/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.4-r1/work/build/gcc'
make[4]: *** No rule to make target
`/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.4-r1/work/build/sparc-sun-solaris2.10/libgcc/crt1.o',
needed by `T_TARGET'.  Stop.
make[4]: Leaving directory
`/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.4-r1/work/build/gcc'
make[3]: *** [gcc-extra-parts] Error 2
make[3]: Leaving directory
`/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.4-r1/work/build/sparc-sun-solaris2.10/libgcc'
make[2]: *** [all-stage1-target-libgcc] Error 2
make[2]: Leaving directory
`/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.4-r1/work/build'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory
`/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.4-r1/work/build'
make: *** [bootstrap-lean] Error 2



Reproducible: Always
Comment 1 Eric Meddaugh 2010-08-12 15:29:43 UTC
# emerge --info
Portage 2.2.01.15417-prefix (prefix/sunos/solaris/5.10/sparc, gcc-4.4.1, unavailable, 5.10 sun4v)
=================================================================
System uname: Solaris-2.10-sun4v-sparc-32bit-ELF
Timestamp of tree: Mon, 02 Aug 2010 11:12:04 +0000
app-shells/bash:     4.1_p5
dev-java/java-config: 2.1.11
dev-lang/python:     2.6.5-r2
dev-util/cmake:      2.8.1-r2
sys-devel/autoconf:  2.65-r1
sys-devel/automake:  1.10.3, 1.11.1
sys-devel/binutils:  2.20.1-r1
sys-devel/gcc:       4.3.2-r4, 4.4.1
sys-devel/gcc-config: 1.4.1-r00.2
sys-devel/libtool:   2.2.10
ACCEPT_KEYWORDS="~sparc-solaris"
ACCEPT_LICENSE="* -@EULA"
CBUILD="sparc-sun-solaris2.10"
CFLAGS="-O2 -pipe"
CHOST="sparc-sun-solaris2.10"
CONFIG_PROTECT="/etc /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/terminfo"
CPPFLAGS="-I/sys_tools/usr/include"
CXXFLAGS="-O2 -pipe"
DISTDIR="/sys_tools/usr/portage/distfiles"
FEATURES="assume-digests collision-protect distlocks fixpackages lafilefixing news nostrip parallel-fetch preserve-libs protect-owned sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-L/sys_tools/usr/lib -R/sys_tools/usr/lib -L/sys_tools/lib -R/sys_tools/lib"
PKGDIR="/sys_tools/usr/portage/packages"
PORTAGE_CONFIGROOT="/sys_tools/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/sys_tools/var/tmp"
PORTDIR="/sys_tools/usr/portage"
PORTDIR_OVERLAY="/sys_tools/usr/local/portage"
SYNC="rsync://rsync.prefix.freens.org/gentoo-portage-prefix"
USE="cracklib cxx kerberos modules ncurses nls prefix readline sparc-solaris ssl unicode zlib" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias proxy proxy_ajp proxy_balancer proxy_connect proxy_ftp proxy_http auth_digest" ELIBC="SunOS" INPUT_DEVICES="keyboard mouse" KERNEL="SunOS" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" RUBY_TARGETS="ruby18" USERLAND="GNU" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, MAKEOPTS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 2 Eric Meddaugh 2010-08-12 15:30:23 UTC
Created attachment 242595 [details]
build.log
Comment 3 Eric Meddaugh 2010-08-12 15:31:40 UTC
This only seems to happen on sparc, not Solaris x86.
Comment 4 Maurice van der Pot (RETIRED) gentoo-dev 2010-08-22 19:59:25 UTC
Created attachment 244085 [details, diff]
Extended T namespace patch to make it work on sparc

The original patch didn't fix the configuration for sparc only for i386.
Comment 5 Fabian Groffen gentoo-dev 2010-08-23 08:52:20 UTC
Hmmm, with Maurice's patch, I just get this:

.4/libgcc/../gcc/mkmap-symver.awk   > tmp-libgcc.map
mv tmp-libgcc.map libgcc.map
make[4]: Entering directory `/var/tmp/portage/portage/sys-devel/gcc-4.4.4-r1/work/build/gcc'
make[4]: *** No rule to make target `/var/tmp/portage/portage/sys-devel/gcc-4.4.4-r1/work/build/sparc-sun-solaris2.10/libgcc/crtbegin.o', needed by `T_TARGET'.  Stop.
make[4]: *** Waiting for unfinished jobs....
Comment 6 Eric Meddaugh 2010-10-26 15:04:10 UTC
Same issue with 4.4.5, and this attached patch does not help to fix it:

# Recursively invoke make in the GCC directory to build any
# startfiles (for now).  We must do this just once, passing
# it all the GCC_EXTRA_PARTS as simultaneous goal targets,
# so that rules which cannot execute simultaneously are properly
# serialized.  We indirect through T_TARGET in case any multilib
# directories contain an equals sign, to prevent make from
# interpreting any of the goals as variable assignments.
# We must use cd && make rather than make -C, or else the stage
# number will be embedded in debug information.
_T_=`${PWDCMD-pwd}`/ \
        && cd ../.././gcc \
        && make GCC_FOR_TARGET="/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/./gcc/xgcc -B/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/./gcc/ -B/sys_tools/usr/sparc-sun-solaris2.10/bin/ -B/sys_tools/usr/sparc-sun-solaris2.10/lib/ -isystem /sys_tools/usr/sparc-sun-solaris2.10/include -isystem /sys_tools/usr/sparc-sun-solaris2.10/sys-include" \
          MULTILIB_CFLAGS="-g -O2 -pipe" \
          _T_=$_T_ \
          T_TARGET="${_T_}crt1.o ${_T_}crtbegin.o ${_T_}crtend.o ${_T_}crtfastmath.o ${_T_}crti.o ${_T_}crtn.o ${_T_}gcrt1.o ${_T_}gmon.o" \
          T_TARGET
make[4]: Entering directory `/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/gcc'
/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/./gcc/xgcc -B/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/./gcc/ -B/sys_tools/usr/sparc-sun-solaris2.10/bin/ -B/sys_tools/usr/sparc-sun-solaris2.10/lib/ -isystem /sys_tools/usr/sparc-sun-solaris2.10/include -isystem /sys_tools/usr/sparc-sun-solaris2.10/sys-include -g -O2 -pipe -c -o /sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/sparc-sun-solaris2.10/libgcc/crt1.o -x assembler-with-cpp /sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/gcc-4.4.5/gcc/config/sparc/sol2-c1.asm
make[4]: *** No rule to make target `/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/sparc-sun-solaris2.10/libgcc/crtbegin.o', needed by `T_TARGET'.  Stop.
make[4]: Leaving directory `/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/gcc'
make[3]: *** [gcc-extra-parts] Error 2
make[3]: Leaving directory `/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build/sparc-sun-solaris2.10/libgcc'
make[2]: *** [all-stage1-target-libgcc] Error 2
make[2]: Leaving directory `/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/sys_tools/var/tmp/portage/sys-devel/gcc-4.4.5/work/build'
make: *** [bootstrap-lean] Error 2
emake failed



Any ideas?
Comment 7 Eugenio Grytsenko 2011-03-18 19:45:02 UTC
Created attachment 266385 [details]
GCC - File build.log

File build.log while trying to do emerge -u gcc.
Comment 8 Eugenio Grytsenko 2011-03-18 19:45:42 UTC
Hello.

I've got the same error or something like that while trying to update my GCC from 4.2.4-r01.2 p1.1 to gcc-4.5.2-r00.1

I've installed Gentoo-prefix in Solaris-10 with SPARC architecture (sun4u) using the following tutorial: http://www.gentoo.org/proj/en/gentoo-alt/prefix/bootstrap-solaris.xml

and I've got these messages:

============= CUT HERE =============
/gentoo/usr/sparcv9-sun-solaris2.10/bin/ranlib libgcov.a
/gentoo/usr/sparcv9-sun-solaris2.10/bin/ranlib libgcc.a
/gentoo/usr/sparcv9-sun-solaris2.10/bin/ranlib libgcc_eh.a
{ /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/./gcc/nm -pg  _muldi3_s.o _negdi2_s.o _lshrdi3_s.o _ashldi3_s.o _ashrdi3_s.o _cmpdi2_s.o _ucmpdi2_s.o _clear_cache_s.o _enable_execute_stack_s.o _trampoline_s.o __main_s.o _absvsi2_s.o _absvdi2_s.o _addvsi3_s.o _addvdi3_s.o _subvsi3_s.o _subvdi3_s.o _mulvsi3_s.o _mulvdi3_s.o _negvsi2_s.o _negvdi2_s.o _ctors_s.o _ffssi2_s.o _ffsdi2_s.o _clz_s.o _clzsi2_s.o _clzdi2_s.o _ctzsi2_s.o _ctzdi2_s.o _popcount_tab_s.o _popcountsi2_s.o _popcountdi2_s.o _paritysi2_s.o _paritydi2_s.o _powisf2_s.o _powidf2_s.o _powixf2_s.o _powitf2_s.o _mulsc3_s.o _muldc3_s.o _mulxc3_s.o _multc3_s.o _divsc3_s.o _divdc3_s.o _divxc3_s.o _divtc3_s.o _bswapsi2_s.o _bswapdi2_s.o _fixunssfsi_s.o _fixunsdfsi_s.o _fixunsxfsi_s.o _fixsfdi_s.o _fixdfdi_s.o _fixxfdi_s.o _fixtfdi_s.o _fixunssfdi_s.o _fixunsdfdi_s.o _fixunsxfdi_s.o _fixunstfdi_s.o _floatdisf_s.o _floatdidf_s.o _floatdixf_s.o _floatditf_s.o _floatundisf_s.o _floatundidf_s.o _floatundixf_s.o _floatunditf_s.o _divdi3_s.o _moddi3_s.o _udivdi3_s.o _umoddi3_s.o _udiv_w_sdiv_s.o _udivmoddi4_s.o  unwind-dw2_s.o unwind-dw2-fde_s.o unwind-sjlj_s.o gthr-gnat_s.o unwind-c_s.o emutls_s.o; echo %%; \
  cat /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/../gcc/libgcc-std.ver  \
    | sed -e '/^[       ]*#/d' \
          -e 's/^%\(if\|else\|elif\|endif\|define\)/#\1/' \
    | /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/./gcc/xgcc -B/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/./gcc/ -B/gentoo/usr/sparcv9-sun-solaris2.10/bin/ -B/gentoo/usr/sparcv9-sun-solaris2.10/lib/ -isystem /gentoo/usr/sparcv9-sun-solaris2.10/include -isystem /gentoo/usr/sparcv9-sun-solaris2.10/sys-include    -g -O2 -pipe -mcpu=ultrasparc -O2  -g -O2 -pipe -mcpu=ultrasparc -DIN_GCC   -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fPIC -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED    -I. -I. -I../.././gcc -I/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc -I/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/. -I/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/../gcc -I/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/../include  -DHAVE_CC_TLS  -E -xassembler-with-cpp -; \
} | gawk -f /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/../gcc/mkmap-symver.awk   > tmp-libgcc.map
mv tmp-libgcc.map libgcc.map
make[6]: Entering directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/gcc'
{ /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/./gcc/nm -pg  _muldi3_s.o _negdi2_s.o _lshrdi3_s.o _ashldi3_s.o _ashrdi3_s.o _cmpdi2_s.o _ucmpdi2_s.o _clear_cache_s.o _enable_execute_stack_s.o _trampoline_s.o __main_s.o _absvsi2_s.o _absvdi2_s.o _addvsi3_s.o _addvdi3_s.o _subvsi3_s.o _subvdi3_s.o _mulvsi3_s.o _mulvdi3_s.o _negvsi2_s.o _negvdi2_s.o _ctors_s.o _ffssi2_s.o _ffsdi2_s.o _clz_s.o _clzsi2_s.o _clzdi2_s.o _ctzsi2_s.o _ctzdi2_s.o _popcount_tab_s.o _popcountsi2_s.o _popcountdi2_s.o _paritysi2_s.o _paritydi2_s.o _powisf2_s.o _powidf2_s.o _powixf2_s.o _powitf2_s.o _mulsc3_s.o _muldc3_s.o _mulxc3_s.o _multc3_s.o _divsc3_s.o _divdc3_s.o _divxc3_s.o _divtc3_s.o _bswapsi2_s.o _bswapdi2_s.o _fixunssfsi_s.o _fixunsdfsi_s.o _fixunsxfsi_s.o _fixsfdi_s.o _fixdfdi_s.o _fixxfdi_s.o _fixtfdi_s.o _fixunssfdi_s.o _fixunsdfdi_s.o _fixunsxfdi_s.o _fixunstfdi_s.o _floatdisf_s.o _floatdidf_s.o _floatdixf_s.o _floatditf_s.o _floatundisf_s.o _floatundidf_s.o _floatundixf_s.o _floatunditf_s.o _divdi3_s.o _moddi3_s.o _udivdi3_s.o _umoddi3_s.o _udiv_w_sdiv_s.o _udivmoddi4_s.o  unwind-dw2_s.o unwind-dw2-fde_s.o unwind-sjlj_s.o gthr-gnat_s.o unwind-c_s.o emutls_s.o; echo %%; \
  cat /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/../gcc/libgcc-std.ver  \
    | sed -e '/^[       ]*#/d' \
          -e 's/^%\(if\|else\|elif\|endif\|define\)/#\1/' \
    | /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/./gcc/xgcc -B/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/./gcc/ -B/gentoo/usr/sparcv9-sun-solaris2.10/bin/ -B/gentoo/usr/sparcv9-sun-solaris2.10/lib/ -isystem /gentoo/usr/sparcv9-sun-solaris2.10/include -isystem /gentoo/usr/sparcv9-sun-solaris2.10/sys-include    -g -O2 -pipe -mcpu=ultrasparc -m32 -O2  -g -O2 -pipe -mcpu=ultrasparc -DIN_GCC   -W -Wall -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fPIC -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED    -I. -I. -I../../.././gcc -I/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc -I/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/. -I/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/../gcc -I/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/../include  -DHAVE_CC_TLS  -E -xassembler-with-cpp -; \
} | gawk -f /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/gcc-4.5.2/libgcc/../gcc/mkmap-symver.awk   > tmp-libgcc.map
make[6]: *** No rule to make target `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/sparcv8plus/libgcc/crtbegin.o', needed by `T_TARGET'.  Stop.
make[6]: *** Waiting for unfinished jobs....
make[6]: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/gcc'
make[5]: *** [gcc-extra-parts] Error 2
make[5]: *** Waiting for unfinished jobs....
make[4]: Entering directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/gcc'
mv tmp-libgcc.map libgcc.map
make[5]: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/sparcv8plus/libgcc'
make[4]: *** [multi-do] Error 1
make[4]: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/libgcc'
make[3]: *** [all-multi] Error 2
make[3]: *** Waiting for unfinished jobs....
make[4]: *** No rule to make target `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/libgcc/crtbegin.o', needed by `T_TARGET'.  Stop.
make[4]: *** Waiting for unfinished jobs....
make[4]: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/gcc'
make[3]: *** [gcc-extra-parts] Error 2
make[3]: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/libgcc'
make[2]: *** [all-stage1-target-libgcc] Error 2
make[2]: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build'
make: *** [bootstrap-lean] Error 2
emake failed
 * ERROR: sys-devel/gcc-4.5.2-r00.1 failed (compile phase):
 *   emake failed with bootstrap-lean
 * 
 * Call stack:
 *     ebuild.sh, line   62:  Called src_compile
 *   environment, line 5161:  Called gcc_src_compile
 *   environment, line 3238:  Called gcc_do_make
 *   environment, line 3009:  Called die
 * The specific snippet of code:
 *       emake LDFLAGS="${LDFLAGS}" STAGE1_CFLAGS="${STAGE1_CFLAGS}" LIBPATH="${EPREFIX}${LIBPATH}" BOOT_CFLAGS="${BOOT_CFLAGS}" ${GCC_MAKE_TARGET} || die "emake failed with ${GCC_MAKE_TARGET}";
 * 
 * If you need support, post the output of 'emerge --info =sys-devel/gcc-4.5.2-r00.1',
 * the complete build log and the output of 'emerge -pqv =sys-devel/gcc-4.5.2-r00.1'.
 * The complete build log is located at '/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/temp/build.log'.
 * The ebuild environment file is located at '/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/temp/environment'.
 * S: '/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build'

>>> Failed to emerge sys-devel/gcc-4.5.2-r00.1, Log file:

>>>  '/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/temp/build.log'

 * Messages for package sys-devel/gcc-4.5.2-r00.1:

 * ERROR: sys-devel/gcc-4.5.2-r00.1 failed (compile phase):
 *   emake failed with bootstrap-lean
 * 
 * Call stack:
 *     ebuild.sh, line   62:  Called src_compile
 *   environment, line 5161:  Called gcc_src_compile
 *   environment, line 3238:  Called gcc_do_make
 *   environment, line 3009:  Called die
 * The specific snippet of code:
 *       emake LDFLAGS="${LDFLAGS}" STAGE1_CFLAGS="${STAGE1_CFLAGS}" LIBPATH="${EPREFIX}${LIBPATH}" BOOT_CFLAGS="${BOOT_CFLAGS}" ${GCC_MAKE_TARGET} || die "emake failed with ${GCC_MAKE_TARGET}";
 * 
 * If you need support, post the output of 'emerge --info =sys-devel/gcc-4.5.2-r00.1',
 * the complete build log and the output of 'emerge -pqv =sys-devel/gcc-4.5.2-r00.1'.
 * The complete build log is located at '/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/temp/build.log'.
 * The ebuild environment file is located at '/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/temp/environment'.
 * S: '/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build'
============= CUT HERE =============


Trying again by hand:

============= CUT HERE =============
shell ~ # EXTRA_ECONF='--with-gmp=/gentoo/usr --with-mpfr=/gentoo/usr --with-mpc=/gentoo/usr' LD_LIBRARY_PATH=/gentoo/usr/lib make -C /gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/sparcv8plus/libgcc/
make: Entering directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/sparcv8plus/libgcc'
# If this is the top-level multilib, build all the other
# multilibs.
# Recursively invoke make in the GCC directory to build any
# startfiles (for now).  We must do this just once, passing
# it all the GCC_EXTRA_PARTS as simultaneous goal targets,
# so that rules which cannot execute simultaneously are properly
# serialized.  We indirect through T_TARGET in case any multilib
# directories contain an equals sign, to prevent make from
# interpreting any of the goals as variable assignments.
# We must use cd && make rather than make -C, or else the stage
# number will be embedded in debug information.
_T_=`${PWDCMD-pwd}`/ \
&& cd ../../.././gcc \
&& make GCC_FOR_TARGET="/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/./gcc/xgcc -B/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/./gcc/ -B/gentoo/usr/sparcv9-sun-solaris2.10/bin/ -B/gentoo/usr/sparcv9-sun-solaris2.10/lib/ -isystem /gentoo/usr/sparcv9-sun-solaris2.10/include -isystem /gentoo/usr/sparcv9-sun-solaris2.10/sys-include  -m32" \
  MULTILIB_CFLAGS="-g -O2 -pipe -mcpu=ultrasparc" \
  _T_=$_T_ \
  T_TARGET="${_T_}crt1.o ${_T_}crtbegin.o ${_T_}crtend.o ${_T_}crtfastmath.o ${_T_}crti.o ${_T_}crtn.o ${_T_}gcrt1.o ${_T_}gmon.o" \
  T_TARGET
make[1]: Entering directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/gcc'
make[1]: *** No rule to make target `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/sparcv8plus/libgcc/crtbegin.o', needed by `T_TARGET'.  Stop.
make[1]: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/gcc'
make: *** [gcc-extra-parts] Error 2
make: Leaving directory `/gentoo/var/tmp/portage/sys-devel/gcc-4.5.2-r00.1/work/build/sparcv9-sun-solaris2.10/sparcv8plus/libgcc'
============= CUT HERE =============


My EPREFIX=/gentoo


My final make.conf after bootstrap:

============= CUT HERE =============
MULTILIB_ABIS="sparc32 sparc64"
CFLAGS_sparc64="-O2 -pipe -mcpu=ultrasparc -m64"
CXXFLAGS_sparc64="$CFLAGS_sparc64"
AUTOCLEAN="yes"
USE="-git nls unicode -nano multilib bash-completion emacs iconv tk cvs kpoll odbc smp static-libs ssl"
CFLAGS="-O2 -pipe -mcpu=ultrasparc"
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j16"
GENTOO_MIRRORS="http://mirror.datapipe.net/gentoo http://distfiles.gentoo.org"
ACCEPT_KEYWORDS="sparc sparc-solaris sparc64-solaris alpha ~sparc ~sparc-solaris ~sparc64-solaris ~alpha"
FEATURES="userpriv assume-digests collision-protect distlocks fixpackages news nostrip parallel-fetch preserve-libs protect-owned sfperms strict unmerge-logs unmerge-orphans userfetch"
============= CUT HERE =============


My emerge --info:

============= CUT HERE =============
shell ~ # emerge --info
Portage 2.2.01.18125-prefix (prefix/sunos/solaris/5.10/sparc64, gcc-4.2.4, unavailable, 5.10 sun4u)
=================================================================
System uname: Solaris-2.10-sun4u-sparc-32bit-ELF
Timestamp of tree: Thu, 17 Mar 2011 22:38:31 +0000
ccache version 3.1.4 [disabled]
app-shells/bash:     4.1_p7
dev-lang/python:     2.6.5-r2
dev-util/ccache:     3.1.4
sys-devel/autoconf:  2.68
sys-devel/automake:  1.11.1
sys-devel/binutils:  2.20.1-r1
sys-devel/gcc:       4.2.4-r01.2
sys-devel/gcc-config: 1.4.1-r00.2
sys-devel/libtool:   2.4
sys-devel/make:      3.82
Repositories: gentoo_prefix
Installed sets: 
ACCEPT_KEYWORDS="alpha sparc sparc-solaris sparc64-solaris ~alpha ~sparc ~sparc-solaris ~sparc64-solaris"
ACCEPT_LICENSE="* -@EULA"
CBUILD="sparcv9-sun-solaris2.10"
CFLAGS="-O2 -pipe -mcpu=ultrasparc"
CHOST="sparcv9-sun-solaris2.10"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/portage /etc/terminfo"
CXXFLAGS="-O2 -pipe -mcpu=ultrasparc"
DISTDIR="/gentoo/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs collision-protect distlocks fixlafiles fixpackages news nostrip parallel-fetch preserve-libs protect-owned sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv"
FFLAGS=""
GENTOO_MIRRORS="http://mirror.datapipe.net/gentoo http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LDFLAGS=""
MAKEOPTS="-j16"
PKGDIR="/gentoo/usr/portage/packages"
PORTAGE_CONFIGROOT="/gentoo/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/gentoo/var/tmp"
PORTDIR="/gentoo/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.prefix.freens.org/gentoo-portage-prefix"
USE="bash-completion cracklib cvs cxx emacs iconv kpoll modules ncurses nls odbc prefix readline smp sparc64-solaris ssl static-libs tk unicode zlib" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="SunOS" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse" KERNEL="SunOS" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby18" USERLAND="GNU" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LINGUAS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
============= CUT HERE =============


My build.log:

============= CUT HERE =============

============= CUT HERE =============



Any ideas?

Thanks!

Regards,
Eugenio.-
Comment 9 Fabian Groffen gentoo-dev 2011-04-06 17:07:53 UTC
*** Bug 359405 has been marked as a duplicate of this bug. ***
Comment 10 Fabian Groffen gentoo-dev 2011-08-10 10:37:26 UTC
I can build 4.5.2 with USE=vanilla, but that doesn't result in a very usable compiler of course, so it must be one of the patches that breaks things.
Comment 11 Fabian Groffen gentoo-dev 2011-08-10 12:46:46 UTC
All Gentoo non-Prefix patches are fine and do not affect building 4.5.2
Comment 12 Fabian Groffen gentoo-dev 2011-08-10 14:37:40 UTC
4.5.2 compiled here.  I hope it does for everyone else now too.