no better way to spend a friday night than fighting with grub. =P with the maketest FEATURE enabled, grub will fail the test phase at size_test. the following versions of grub fail with the indicated message: grub-0.95.20040823 (gcc 3.4.3): ffs_stage1_5 is too big (9440 > 7168). grub-0.95.20040823 (gcc 3.3.4): ffs_stage1_5 is too big (9408 > 7168). grub-0.94-r2 (gcc 3.4.3): ffs_stage1_5 is too big (9248 > 7168). grub-0.94-r1 (gcc 3.4.3): ffs_stage1_5 is too big (9248 > 7168). grub-0.94-r1 (gcc 3.3.4): ffs_stage1_5 is too big (9216 > 7168). each version also throws a god-load of warnings, some of which i'll post below. grub-0.93.20030118 will pass testing and install with gcc-3.3.4, but not with 3.4.3 which isn't too surprising. Reproducible: Always Steps to Reproduce: 1. emerge one of the grub ebuilds above with 'maketest' in FEATURES Actual Results: >>> Test phase [check]: sys-boot/grub-0.95.20040823 Making check in netboot make[1]: Entering directory `/var/tmp/portage/grub-0.95.20040823/work/grub-0.95.20040823/netboot' make[1]: Nothing to be done for `check'. make[1]: Leaving directory `/var/tmp/portage/grub-0.95.20040823/work/grub-0.95.20040823/netboot' Making check in stage2 make[1]: Entering directory `/var/tmp/portage/grub-0.95.20040823/work/grub-0.95.20040823/stage2' make check-am make[2]: Entering directory `/var/tmp/portage/grub-0.95.20040823/work/grub-0.95.20040823/stage2' make check-TESTS make[3]: Entering directory `/var/tmp/portage/grub-0.95.20040823/work/grub-0.95.20040823/stage2' ffs_stage1_5 is too big (9408 > 7168). FAIL: size_test ================================= 1 of 1 tests failed Please report to bug-grub@gnu.org ================================= make[3]: *** [check-TESTS] Error 1 make[3]: Leaving directory `/var/tmp/portage/grub-0.95.20040823/work/grub-0.95.20040823/stage2' make[2]: *** [check-am] Error 2 make[2]: Leaving directory `/var/tmp/portage/grub-0.95.20040823/work/grub-0.95.20040823/stage2' make[1]: *** [check] Error 2 make[1]: Leaving directory `/var/tmp/portage/grub-0.95.20040823/work/grub-0.95.20040823/stage2' make: *** [check-recursive] Error 1 !!! ERROR: sys-boot/grub-0.95.20040823 failed. !!! Function src_test, Line 520, Exitcode 0 !!! Make check failed. See above for details. ===================================\ emerge info ===================================/ Portage 2.0.51-r3 (default-linux/x86/2004.3, gcc-3.4.3, glibc-2.3.4.20040808-r1, 2.6.9-ck3 i686) ================================================================= System uname: 2.6.9-ck3 i686 Pentium III (Katmai) Gentoo Base System version 1.4.16 ccache version 2.3 [enabled] Autoconf: sys-devel/autoconf-2.59-r5 Automake: sys-devel/automake-1.8.5-r1 Binutils: sys-devel/binutils-2.14.90.0.8-r1 Headers: sys-kernel/linux26-headers-2.6.8.1 Libtools: sys-devel/libtool-1.5.2-r5 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-O2 -march=pentium3 -fomit-frame-pointer -pipe -ffast-math -ftracer -momit-leaf-frame-pointer" CHOST="i686-pc-linux-gnu" COMPILER="" CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /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="-O2 -march=pentium3 -fomit-frame-pointer -pipe -ffast-math -ftracer -momit-leaf-frame-pointer" DISTDIR="/usr/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks maketest nodoc sandbox sfperms" GENTOO_MIRRORS="ftp://sunsite.ualberta.ca/pub/unix/Linux/gentoo/ ftp://gentoo.agsn.ca/ http://gentoo.mirrored.ca/" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="x86 X alsa avi bash-completion berkdb cdr crypt fbcon fortran gdbm gif gpm imlib java javascript jpeg mmx mozilla mpeg ncurses nptl odbc oggvorbis opengl pam perl pic png python readline ruby sdl sse ssl tcpd unicode userlocales xml xml2 zlib" ===================================\ Please note that I also tested each version with CFLAGS="-march=pentium3 -pipe" to check sanity. These are examples of the most common warnings that cropped up: ===================================/ timer.h:53: warning: no previous prototype for 'timer2_running' timer.h:58: warning: no previous prototype for 'waiton_timer2' 3c509.c:63: warning: declaration of 'nic' shadows a global declaration etherboot.h:539: warning: shadowed declaration is here (this one appears literally thousands of times) davicom.c:491: warning: unused variable `addr_low' davicom.c:491: warning: unused variable `addr_high' tulip.c:974: warning: declaration of 'addr_high' shadows a previous local tulip.c:946: warning: shadowed declaration is here tulip.c:984: warning: declaration of 'addr_low' shadows a previous local tulip.c:946: warning: shadowed declaration is here eepro.c:440:5: warning: "DEBUG" is not defined epic100.c:58: warning: 'read_eeprom' declared `static' but never defined tulip.c:783: warning: pointer of type `void *' used in arithmetic ====================================\ etc. grepping a single log for 'warning' gave me a 142k file.
Unfortunately, the very nature of the beast means that things like this are an absolute git to fix. I think the reason for this particular problem is the fact that some of the flags deprecated in 3.3 are now ignored entirely in 3.4, and this means that things meant to reduce the size of the stage1_5 files don't actually do anything. Fixing this has been on my todo list for a while, and unfortunately unless someone can provide a patch it might stay there for a while too.
well, i have nothing but time these days so i'll poke it with a stick for a bit. i probably don't know enough to figure it out, but can't hurt and i need the experience ;] in the meantime, would it be a good idea (or possible) to disable the tests? someone installing gentoo (or linux even) for the first time isn't going to feel very comfortable when a critical piece of their system can't pass its own inspection. (ie. so it don't spook the noobs.)
I'm working on removing the tests for FFS and UFS2 from the build. As yet I haven't managed it, although I'm assured it's possible.
It is not only a problem of gcc-3.4. I got the same error with gcc-3.3.4 but my ffs_stage1_5 is a little bit smaller. here is what i got: ... make check-TESTS make[3]: Entering directory `/var/tmp/portage/grub-0.94-r1/work/grub-0.94/stage2' ffs_stage1_5 is too big (9216 > 7168). FAIL: size_test ================================= 1 of 1 tests failed Please report to bug-grub@gnu.org ================================= make[3]: *** [check-TESTS] Error 1 make[3]: Leaving directory `/var/tmp/portage/grub-0.94-r1/work/grub-0.94/stage2' make[2]: *** [check-am] Error 2 make[2]: Leaving directory `/var/tmp/portage/grub-0.94-r1/work/grub-0.94/stage2' make[1]: *** [check] Error 2 make[1]: Leaving directory `/var/tmp/portage/grub-0.94-r1/work/grub-0.94/stage2' make: *** [check-recursive] Error 1 !!! ERROR: sys-boot/grub-0.94-r1 failed. !!! Function src_test, Line 520, Exitcode 0 !!! Make check failed. See above for details. !!! If you need support, post the topmost build error, NOT this status message. my emerge info: Portage 2.0.51-r3 (default-linux/x86/2004.3, gcc-3.3.4, glibc-2.3.4.20040808-r1, 2.4.26-gentoo-r13 i686) ================================================================= System uname: 2.4.26-gentoo-r13 i686 Pentium II (Deschutes) Gentoo Base System version 1.4.16 distcc 2.16 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled] ccache version 2.3 [enabled] Autoconf: sys-devel/autoconf-2.59-r5 Automake: sys-devel/automake-1.8.5-r1 Binutils: sys-devel/binutils-2.15.90.0.1.1-r3 Headers: sys-kernel/linux-headers-2.4.21-r1 Libtools: sys-devel/libtool-1.5.2-r7 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-O2 -mcpu=pentium2 -fomit-frame-pointer -pipe" CHOST="i686-pc-linux-gnu" COMPILER="" CONFIG_PROTECT="/etc /etc/tomcat5 /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/bind /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-O2 -mcpu=pentium2 -fomit-frame-pointer -pipe" DISTDIR="/mnt/space/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache collision-protect distlocks maketest sandbox sfperms strict userpriv usersandbox" 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="/var/portage/tree" PORTDIR_OVERLAY="" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="apache2 apm avi berkdb bitmap-fonts chroot crypt curl encode f77 foomaticdb gd gdbm gif gtk2 imap imlib innodb javascript jpeg libwww lzw-tiff mad maildir mikmod motif mpeg ncurses oggvorbis opengl pam pdflib pic png quicktime readline samba sasl spell ssl tcpd tiff x86 xml xml2 xmms xv zlib"
Hmmm, I better read all your lines; you already checked it with gcc-3.3.4 and your file has the same size ;-)
these disable the size_tests for ffs and ufs2 with grub-0.94 and 0.95.
Created attachment 48740 [details, diff] grub-0.94-sizetest.patch
Created attachment 48741 [details, diff] grub-0.95.20040823-sizetest.patch disable ffs and ufs2 size_test for grub-0.95
Comment on attachment 48740 [details, diff] grub-0.94-sizetest.patch disable ffs size_test for grub-0.94
still a bug with 0.96 ?
yep.
0.96-r1 removes the test