Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 202075 - sys-devel/gcc-4.1.2 compile fails - make[2]: 0: Command not found when FLEX=0 in env
Summary: sys-devel/gcc-4.1.2 compile fails - make[2]: 0: Command not found when FLEX=0...
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
: 202074 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-12-12 19:13 UTC by Trevor Bowen
Modified: 2007-12-31 15:01 UTC (History)
0 users

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


Attachments
for broken system: emerge --verbose --info (emerge_verbose_info.txt,10.93 KB, text/plain)
2007-12-13 19:09 UTC, Trevor Bowen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Trevor Bowen 2007-12-12 19:13:26 UTC
sys-devel/gcc-4.1.2: compile fails on amd64 with bad command:  make[2]: 0: Command not found

Reproducible: Always

Steps to Reproduce:
I have recently installed Gentoo on my AMD Athlon64 X2 box.  (This is my fourth Gentoo install.)  Everything seems to work, except I would like to update the system:

1. emerge -uDN world

Eventually, the update hit gcc, which failed (see error below).

2. emerge gcc

I can consistently produce the same error just by trying to re-emerge gcc.
Actual Results:  
emerge runs for a few minutes, and then bombs with the following:

<truncated snippet>
          gcc.o version.o prefix.o intl.o  ../libcpp/libcpp.a   ../libiberty/libiberty.a
stage1/xgcc -Bstage1/ -B/usr/x86_64-pc-linux-gnu/bin/ -c   -march=athlon64 -O2 -pipe -fprofile-generate -DIN_GCC   -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros -Wold-style-definition -Wmissing-format-attribute     -DHAVE_CONFIG_H -I. -Itreelang -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/../include -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/../libcpp/include     /var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang/tree1.c -o treelang/tree1.o
bison  -v --defines --output=treelang/parse.c /var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang/parse.y
stage1/xgcc -Bstage1/ -B/usr/x86_64-pc-linux-gnu/bin/ -c   -march=athlon64 -O2 -pipe -fprofile-generate -DIN_GCC   -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros -Wold-style-definition -Wmissing-format-attribute     -DHAVE_CONFIG_H -I. -Itreelang -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/../include -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/../libcpp/include     /var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang/treetree.c -o treelang/treetree.o
stage1/xgcc -Bstage1/ -B/usr/x86_64-pc-linux-gnu/bin/ -c   -march=athlon64 -O2 -pipe -fprofile-generate -DIN_GCC   -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros -Wold-style-definition -Wmissing-format-attribute     -DHAVE_CONFIG_H -I. -Itreelang -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/../include -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/../libcpp/include     /var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang/tree-convert.c -o treelang/tree-convert.o
0  -otreelang/lex.c /var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang/lex.l
make[2]: 0: Command not found
make[2]: [treelang/lex.c] Error 127 (ignored)
stage1/xgcc -Bstage1/ -B/usr/x86_64-pc-linux-gnu/bin/ -c   -march=athlon64 -O2 -pipe -fprofile-generate -DIN_GCC   -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros -Wold-style-definition -Wmissing-format-attribute   -Wno-error  -DHAVE_CONFIG_H -I. -Itreelang -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/treelang -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/../include -I/var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/gcc/../libcpp/include     treelang/lex.c -o treelang/lex.o
xgcc: treelang/lex.c: No such file or directory
xgcc: no input files
make[2]: *** [treelang/lex.o] Error 1
make[2]: Leaving directory `/var/tmp/portage/sys-devel/gcc-4.1.2/work/build/gcc'
make[1]: *** [stageprofile_build] Error 2
make[1]: Leaving directory `/var/tmp/portage/sys-devel/gcc-4.1.2/work/build/gcc'
make: *** [profiledbootstrap] Error 2
 *
 * ERROR: sys-devel/gcc-4.1.2 failed.
 * Call stack:
 *          ebuild.sh, line 1701:  Called dyn_compile
 *          ebuild.sh, line 1039:  Called qa_call 'src_compile'
 *          ebuild.sh, line   44:  Called src_compile
 *          ebuild.sh, line 1383:  Called toolchain_src_compile
 *   toolchain.eclass, line   26:  Called gcc_src_compile
 *   toolchain.eclass, line 1548:  Called gcc_do_make
 *   toolchain.eclass, line 1422:  Called die
 * The specific snippet of code:
 *      emake \
 *              LDFLAGS="${LDFLAGS}" \
 *              STAGE1_CFLAGS="${STAGE1_CFLAGS}" \
 *              LIBPATH="${LIBPATH}" \
 *              BOOT_CFLAGS="${BOOT_CFLAGS}" \
 *              ${GCC_MAKE_TARGET} \
 *              || die "emake failed with ${GCC_MAKE_TARGET}"
 *  The die message:
 *   emake failed with profiledbootstrap
 *
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/sys-devel/gcc-4.1.2/temp/build.log'.
 *


Expected Results:  
gcc to emerge successfully without errors.

I may have done this to myself.  :-)  I copied my /etc/make.conf file from an Intel Core2Duo box, on which I recently installed Gentoo.  I initially forgot to change the -march=nocona to -march=athlon64.  ... At some point in the install, I had booted from the 2007.0 LiveCD and tried to do an 'emerge -uDN world' from that environment, which eventually failed.  I don't know if I had the bad march flag at that point - maybe I did, maybe I didn't - I can't recall.  Also, I don't know if it generally hurts doing an emerge to your system from the LiveCD.

...

$ emerge --info
Portage 2.1.3.19 (default-linux/amd64/2007.0, gcc-4.1.1, glibc-2.6.1-r0, 2.6.23-gentoo-r3 x86_64)
=================================================================
System uname: 2.6.23-gentoo-r3 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 3800+
Timestamp of tree: Tue, 11 Dec 2007 05:00:01 +0000
app-shells/bash:     3.2_p17
dev-java/java-config: 1.3.7, 2.0.33-r1
dev-lang/python:     2.4.4-r6
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 1.12.9-r2
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.61-r1
sys-devel/automake:  1.5, 1.6.3, 1.7.9-r1, 1.9.6-r2, 1.10
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.24
virtual/os-headers:  2.6.22-r2
ACCEPT_KEYWORDS="amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=athlon64 -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=athlon64 -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks metadata-transfer sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
MAKEOPTS="-j5"
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 --filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac acl alsa amd64 apache2 apm arts audiofile avi bash-completion berkdb bidi bitmap-fonts bonobo bzip2 cairo cdda cddb cdio cdr clamav cli cracklib crypt ctype cups dri dts dv dvd dvdr emacs encode esd exif expat fam ffmpeg firefox fortran freetype gdbm gif gnome gpm gtk gtk2 hal iconv imlib ipv6 isdnlog java javascript jpeg kde libg++ libwww live lm_sensors mad matroska midi mikmod mmx motif mp3 mpeg mplayer mudflap mysql ncurses nls nptl nptlonly nvidia ofx ogg oggvorbis openal openexr opengl openmp pam pcre pdf pdflib perl php plotutils png posix pppd python qmail-spp qt qt3 qt3support qt4 quicktime rdesktop readline reflection ruby samba scanner sdl session simplexml slang snmp speex spell spl sse sse2 ssl stream svg tcl tcltk tcpd theora tidy tiff tk tokenizer truetype truetype-fonts type1-fonts unicode usb vcd vhosts vim-syntax vlm vorbix wxwindows x264 xcomposite xml xmlrpc xorg xpm xv xvid xvmc zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter 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" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="apm ark chips cirrus cyrix dummy fbdev glint i128 i810 mach64 mga neomagic nv r128 radeon rendition s3 s3virge savage siliconmotion sis sisusb tdfx tga trident tseng v4l vesa vga via vmware voodoo"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-12-12 20:15:32 UTC

*** This bug has been marked as a duplicate of bug 202074 ***
Comment 2 Jakub Moc (RETIRED) gentoo-dev 2007-12-13 17:51:18 UTC
Fix component and re-assign.
Comment 3 SpanKY gentoo-dev 2007-12-13 18:53:28 UTC
*** Bug 202074 has been marked as a duplicate of this bug. ***
Comment 4 SpanKY gentoo-dev 2007-12-13 18:54:09 UTC
post `emerge --verbose --info` output as an attachment
Comment 5 Trevor Bowen 2007-12-13 19:09:32 UTC
Created attachment 138402 [details]
for broken system:  emerge --verbose --info

please let me know what else I can do to help.  :-)
Comment 6 SpanKY gentoo-dev 2007-12-31 04:01:02 UTC
you have:
FLEX="0"

that's no good
Comment 7 Trevor Bowen 2007-12-31 15:01:57 UTC
Wow!  That was the problem.

FWIW, In root's .bashrc, I had a config line from an old environment (used Flex license management) that set FLEX=0.

I am not sure what that variable has to do with gcc, but I commented out that line, unset FLEX in my current shell, emerged gcc, and it compiled with no warnings or errors!

Thanks for the help!!!