Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 143055 - sys-devel/gcc-3.4.6-r1 fails to compile in a chroot
Summary: sys-devel/gcc-3.4.6-r1 fails to compile in a chroot
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-08-06 23:20 UTC by Aniruddha Shankar
Modified: 2006-08-21 23:21 UTC (History)
0 users

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


Attachments
preprocessed source output, as per compilation failure report (ccXxI9rT.out,126.19 KB, text/plain)
2006-08-06 23:21 UTC, Aniruddha Shankar
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Aniruddha Shankar 2006-08-06 23:20:27 UTC
Am trying to build a build chroot for my VIA C3 machines on my P4-3gHz machine. When trying to emerge gcc, I get this error:


( ` if [ -f ./nm ] ; then echo ./nm ; elif [ -f /var/tmp/portage/gcc-3.4.6-r1/work/build/gcc/../binutils/nm-new ] ; then echo /var/tmp/portage/gcc-3.4.6-r1/work/build/gcc/../binutils/nm-new ; else if [ "i586-pc-linux-gnu" = "i586-pc-linux-gnu" ] ; then echo nm; else t='s,y,y,'; echo nm | sed -e  ; fi; fi` -pg libgcc/./_floatdidf.o | gawk 'NF == 3 && $2 !~ /^[UN]$/ { print "\t.hidden", $3 }'; cat libgcc//stacknote.s ) |  ./xgcc -B./ -B/usr/i586-pc-linux-gnu/bin/ -isystem /usr/i586-pc-linux-gnu/include -isystem /usr/i586-pc-linux-gnu/sys-include -L/var/tmp/portage/gcc-3.4.6-r1/work/build/gcc/../ld -O2  -DIN_GCC    -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fPIC -DHAVE_SYSLOG -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED  -D_LIBC_PROVIDES_SSP_ -fno-stack-protector  -r -nostdinc -nostdlib -o libgcc/./_floatdidf.oS libgcc/./_floatdidf.o -xassembler -
./xgcc -B./ -B/usr/i586-pc-linux-gnu/bin/ -isystem /usr/i586-pc-linux-gnu/include -isystem /usr/i586-pc-linux-gnu/sys-include -L/var/tmp/portage/gcc-3.4.6-r1/work/build/gcc/../ld -O2  -DIN_GCC    -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fPIC -DHAVE_SYSLOG -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED  -D_LIBC_PROVIDES_SSP_ -fno-stack-protector -I. -I. -I/var/tmp/portage/gcc-3.4.6-r1/work/gcc-3.4.6/gcc -I/var/tmp/portage/gcc-3.4.6-r1/work/gcc-3.4.6/gcc/. -I/var/tmp/portage/gcc-3.4.6-r1/work/gcc-3.4.6/gcc/../include   -DL_floatdisf -c /var/tmp/portage/gcc-3.4.6-r1/work/gcc-3.4.6/gcc/libgcc2.c -o libgcc/./_floatdisf.o
/var/tmp/portage/gcc-3.4.6-r1/work/gcc-3.4.6/gcc/libgcc2.c: In function `__floatdisf':
/var/tmp/portage/gcc-3.4.6-r1/work/gcc-3.4.6/gcc/libgcc2.c:1409: internal compiler error: Illegal instruction
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugs.gentoo.org/> for instructions.
Preprocessed source stored into /var/tmp/portage/gcc-3.4.6-r1/temp/ccXxI9rT.out file, please attach this to your bugreport.
make[3]: *** [libgcc/./_floatdisf.o] Error 1
make[3]: Leaving directory `/var/tmp/portage/gcc-3.4.6-r1/work/build/gcc'
make[2]: *** [libgcc.a] Error 2
make[2]: Leaving directory `/var/tmp/portage/gcc-3.4.6-r1/work/build/gcc'
make[1]: *** [stageprofile_build] Error 2
make[1]: Leaving directory `/var/tmp/portage/gcc-3.4.6-r1/work/build/gcc'
make: *** [profiledbootstrap] Error 2

!!! ERROR: sys-devel/gcc-3.4.6-r1 failed.
Call stack:
  ebuild.sh, line 1539:   Called dyn_compile
  ebuild.sh, line 939:   Called src_compile
  ebuild.sh, line 1248:   Called toolchain_src_compile
  toolchain.eclass, line 24:   Called gcc_src_compile
  toolchain.eclass, line 1523:   Called gcc_do_make
  toolchain.eclass, line 1397:   Called die

!!! emake failed with profiledbootstrap
!!! If you need support, post the topmost build error, and the call stack if relevant.


Portage 2.1-r1 (default-linux/x86/2006.0, gcc-3.4.4, glibc-2.3.5-r2, 2.6.17-gentoo-r4 i686)
=================================================================
System uname: 2.6.17-gentoo-r4 i686 Intel(R) Pentium(R) 4 CPU 3.00GHz
Gentoo Base System version 1.6.14
app-admin/eselect-compiler: [Not Present]
dev-lang/python:     2.4.2
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     [Not Present]
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.12
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.12-r6
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i586-pc-linux-gnu"
CFLAGS="-O2 -march=c3 -pipe"
CHOST="i586-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/lib/mozilla/defaults/pref /usr/share/X11/xkb /usr/share/config /var/bind"
CONFIG_PROTECT_MASK="/etc/env.d /etc/gconf /etc/terminfo"
CXXFLAGS="-O2 -march=c3 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks metadata-transfer sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X alsa apache2 apm arts avi berkdb bitmap-fonts cli crypt cups dlloader dri eds emboss encode esd foomaticdb fortran gdbm gif gnome gpm gstreamer gtk gtk2 imlib ipv6 isdnlog jpeg kde libg++ libwww mad mikmod motif mp3 mpeg ncurses nls nptl ogg opengl oss pam pcre pdflib perl png pppd python qt qt3 qt4 quicktime readline reflection sdl session spell spl ssl tcpd truetype truetype-fonts type1-fonts udev vorbis xml xmms xorg xv zlib elibc_glibc input_devices_keyboard input_devices_mouse input_devices_evdev kernel_linux userland_GNU"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, MAKEOPTS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Comment 1 Aniruddha Shankar 2006-08-06 23:21:54 UTC
Created attachment 93636 [details]
preprocessed source output, as per compilation failure report
Comment 2 Jakub Moc (RETIRED) gentoo-dev 2006-08-07 00:25:57 UTC
Please, don't restrict bugs without any reason. Just leave the checkboxes alone.
Comment 3 SpanKY gentoo-dev 2006-08-07 09:26:09 UTC
try with -march=i586

i thought C3's were i686's, so why is your CHOST i586-* ?
Comment 4 Aniruddha Shankar 2006-08-18 03:45:11 UTC
http://gentoo-wiki.com/Safe_Cflags#Eden_C3.2FEzra_.28Via_EPIA.29

gateway ~ # x86info   
x86info v1.17.  Dave Jones 2001-2005
Feedback to <davej@redhat.com>.

Found 1 CPU
--------------------------------------------------------------------------
Family: 6 Model: 7 Stepping: 3
CPU Model : VIA C3 (Samuel 2) [C5B]
Feature flags:
 fpu de tsc msr cx8 mtrr pge mmx
Extended feature flags:

gateway ~ # cat /proc/cpuinfo 
processor       : 0
vendor_id       : CentaurHauls
cpu family      : 6
model           : 7
model name      : VIA Samuel 2
stepping        : 3
cpu MHz         : 796.179
cache size      : 64 KB
fdiv_bug        : no
hlt_bug         : no
f00f_bug        : no
coma_bug        : no
fpu             : yes
fpu_exception   : yes
cpuid level     : 1
wp              : yes
flags           : fpu de tsc msr cx8 mtrr pge mmx 3dnow
bogomips        : 1595.37


Extended x86info output:

gateway ~ # x86info -a    
x86info v1.17.  Dave Jones 2001-2005
Feedback to <davej@redhat.com>.

Found 1 CPU
--------------------------------------------------------------------------
eax in: 0x00000000, eax = 00000001 ebx = 746e6543 ecx = 736c7561 edx = 48727561
eax in: 0x00000001, eax = 00000673 ebx = 00000000 ecx = 00000000 edx = 00803135

eax in: 0x80000000, eax = 80000006 ebx = 00000000 ecx = 00000000 edx = 00000000
eax in: 0x80000001, eax = 00000673 ebx = 00000000 ecx = 00000000 edx = 80803135
eax in: 0x80000002, eax = 20414956 ebx = 756d6153 ecx = 32206c65 edx = 00000000
eax in: 0x80000003, eax = 00000000 ebx = 00000000 ecx = 00000000 edx = 00000000
eax in: 0x80000004, eax = 00000000 ebx = 00000000 ecx = 00000000 edx = 00000000
eax in: 0x80000005, eax = 00000000 ebx = 08800880 ecx = 40040120 edx = 40040120
eax in: 0x80000006, eax = 00000000 ebx = 00000000 ecx = 40040120 edx = 00000000

Family: 6 Model: 7 Stepping: 3
CPU Model : VIA C3 (Samuel 2) [C5B]
Feature flags:
        Onboard FPU
        Debugging Extensions
        Time Stamp Counter
        Model-Specific Registers
        CMPXCHG8 instruction
        Memory Type Range Registers
        Page Global Enable
        MMX support

Extended feature flags:

Instruction TLB: 8-way associative. 128 entries.
Data TLB: 8-way associative. 128 entries.
L1 Data cache:
        Size: 64Kb      4-way associative.
        lines per tag=1 line size=32 bytes.
L1 Instruction cache:
        Size: 64Kb      4-way associative.
        lines per tag=1 line size=32 bytes.
L2 cache size errata detected. Using workaround
L2 (on CPU) cache:
        Size: 64Kb      4-way associative.
        lines per tag=1 line size=32 bytes.
/dev/cpu/0/msr: No such file or directory
FCR: Couldn't read MSR 0x1107
Power management: Longhaul

MTRR registers:
MTRRcap (0xfe): MTRRphysBase0 (0x200): MTRRphysMask0 (0x201): MTRRphysBase1 (0x2                                                    02): MTRRphysMask1 (0x203): MTRRphysBase2 (0x204): MTRRphysMask2 (0x205): MTRRph                                                    ysBase3 (0x206): MTRRphysMask3 (0x207): MTRRphysBase4 (0x208): MTRRphysMask4 (0x                                                    209): MTRRphysBase5 (0x20a): MTRRphysMask5 (0x20b): MTRRphysBase6 (0x20c): MTRRp                                                    hysMask6 (0x20d): MTRRphysBase7 (0x20e): MTRRphysMask7 (0x20f): MTRRfix64K_00000                                                     (0x250): MTRRfix16K_80000 (0x258): MTRRfix16K_A0000 (0x259): MTRRfix4K_C8000 (0                                                    x269): MTRRfix4K_D0000 0x26a: MTRRfix4K_D8000 0x26b: MTRRfix4K_E0000 0x26c: MTRR                                                    fix4K_E8000 0x26d: MTRRfix4K_F0000 0x26e: MTRRfix4K_F8000 0x26f: MTRRdefType (0x                                                    2ff): 

800MHz processor (estimate).

Comment 5 Aniruddha Shankar 2006-08-21 22:17:19 UTC
The following flags worked. I was able to run a complete bootstrap. It seems to me to be a bug with march=c3. Can this bug be reopened and someone confirm ?

CFLAGS="-O2 -march=i586 -pipe"
CHOST="i586-pc-linux-gnu"
Comment 6 SpanKY gentoo-dev 2006-08-21 23:21:07 UTC
no, 3.4.x is dead ... we're moving to gcc-4.1.1 which should handle c3 / i686 just fine