Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 76199

Summary: Bootstrap fails compiling m4 with message "cru: Command not found".
Product: Gentoo Linux Reporter: Matt Toso <takaitra>
Component: [OLD] Core systemAssignee: Gentoo Linux bug wranglers <bug-wranglers>
Status: RESOLVED DUPLICATE    
Severity: blocker    
Priority: High    
Version: 2004.3   
Hardware: x86   
OS: Linux   
URL: http://forums.gentoo.org/viewtopic.php?p=1928638
Whiteboard:
Package list:
Runtime testing required: ---

Description Matt Toso 2004-12-30 19:54:18 UTC
I am running the bootstrap.sh script during the Stage 1 install and have received the following error:

make[1]: cru: Command not found
make[1]: *** [libm4.a] Error 127
make[1]: Leaving directory '/var/tmp/portage/m4-1.4.1/work/m4-1.4.1/lib'
make: *** [all] Error 1

!!! ERROR: sys-devel/m4-1.4.1 failed
!!! Function src_compile, Line 26, Exitcode 2
!!! (no error message) 

Reproducible: Always
Steps to Reproduce:
1. Follow the Gentoo Handbook to install Gentoo 2004.3 on an x86.
2. Start the bootstrap script.

Actual Results:  
Bootstrap fails while attempting to compile m4.

Expected Results:  
Finished bootstrapping and brought me to a stage2 install.

Gentoo Base System version 1.4.16
Portage 2.0.51-r3 (default-linux/x86/2004.3, gcc-3.3.4, glibc-2.3.4.20040808-r1,
2.6.9-gentoo-r1 i686)
=================================================================
System uname: 2.6.9-gentoo-r1 i686 Intel(R) Pentium(R) M processor 1.60GHz
Autoconf: 
Automake: 
Binutils: sys-devel/binutils-2.15.90.0.1.1-r3
Headers:  sys-kernel/linux-headers-2.4.21-r1
Libtools: 
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O3 -march=pentium3 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O3 -march=pentium3 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="http://gentoo.osuosl.org
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X acl acpi alsa apm avi berkdb bitmap-fonts cdr crypt cups divx4linux dvd
dvdr encode ethereal exif f77 fbcon flac foomaticdb fortran gdbm gif gnome gpm
gtk gtk2 icc imap imlib ipv6 jpeg libg++ libwww mad mikmod mmx motif mpeg
ncurses nls oggvorbis opengl pam pcmcia pdflib perl png python qt quicktime
readline samba sdl spell sse ssl svga tcpd truetype usb x86 xinerama xml2 xmms
xv xvid zlib"
Comment 1 Anton Koinov 2004-12-30 20:20:43 UTC
I am getting the same error on ppc:
make[1]: Entering directory `/var/tmp/portage/m4-1.4.1/work/m4-1.4.1/lib'
gcc -c -DHAVE_CONFIG_H -I.. -I.  -O2 -pipe -mcpu=7400 -maltivec -mabi=altivec regex.c
gcc -c -DHAVE_CONFIG_H -I.. -I.  -O2 -pipe -mcpu=7400 -maltivec -mabi=altivec getopt.c
gcc -c -DHAVE_CONFIG_H -I.. -I.  -O2 -pipe -mcpu=7400 -maltivec -mabi=altivec getopt1.c
gcc -c -DHAVE_CONFIG_H -I.. -I.  -O2 -pipe -mcpu=7400 -maltivec -mabi=altivec error.c
gcc -c -DHAVE_CONFIG_H -I.. -I.  -O2 -pipe -mcpu=7400 -maltivec -mabi=altivec obstack.c
gcc -c -DHAVE_CONFIG_H -I.. -I.  -O2 -pipe -mcpu=7400 -maltivec -mabi=altivec xmalloc.c
gcc -c -DHAVE_CONFIG_H -I.. -I.  -O2 -pipe -mcpu=7400 -maltivec -mabi=altivec xstrdup.c
In file included from regex.c:4062:
regex.c: In function `re_match_2_internal':
regex.c:4890: warning: passing arg 1 of `bcmp_translate' discards qualifiers from pointer target type
regex.c:4890: warning: passing arg 2 of `bcmp_translate' discards qualifiers from pointer target type
rm -f libm4.a
cru libm4.a regex.o getopt.o getopt1.o error.o obstack.o xmalloc.o xstrdup.o
make[1]: cru: Command not found
make[1]: *** [libm4.a] Error 127
make[1]: Leaving directory `/var/tmp/portage/m4-1.4.1/work/m4-1.4.1/lib'
make: *** [all] Error 1

!!! ERROR: sys-devel/m4-1.4.1 failed.
!!! Function src_compile, Line 26, Exitcode 2
!!! (no error message)
Comment 2 Matt Toso 2004-12-30 21:55:20 UTC
This could help narrow things down. Oddly, the AR=ar variable is being ignored in /var/tmp/portage/m4-1.4.1/work/m4-1.4.1/lib/Makefile. This causes the script to look for the "cru" command when actually it should be executing "ar cru...". Exporting the environment variable AR=ar seems to work and I've suggested this temporary fix for people with this problem.
Comment 3 Daniel Black (RETIRED) gentoo-dev 2004-12-30 21:59:06 UTC

*** This bug has been marked as a duplicate of 76195 ***