Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 52314 - mysql-4.0.20 ebuild fails compilation
Summary: mysql-4.0.20 ebuild fails compilation
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High blocker
Assignee: Gentoo Linux MySQL bugs team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-05-28 20:26 UTC by Brian C. Dilley
Modified: 2004-07-22 09:08 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Brian C. Dilley 2004-05-28 20:26:41 UTC
I get an error when i try to emerge mysql-4.0.20, here's the output:

 gcc -DDEFAULT_CHARSET_HOME=\"/usr\" -DDATADIR=\"/var/lib/mysql\" -DSHAREDIR=\"/usr/share/mysql\" -DDONT_USE_RAID -DMYSQL_CLIENT -I. -I. -I.. -I./../include -I../include -I./.. -I.. -I.. -O3 -DDBUG_OFF -march=athlon-xp -mcpu=athlon-xp -O3 -pipe -mfpmath=sse -msse -mmmx -m3dnow -DHAVE_ERRNO_AS_DEFINE=1 -DUSE_OLD_FUNCTIONS -MT my_realloc.lo -MD -MP -MF .deps/my_realloc.Tpo -c my_realloc.c  -fPIC -DPIC -o .libs/my_realloc.o
make[2]: *** [libmysql.lo] Error 1
make[2]: *** Waiting for unfinished jobs....
 gcc -DDEFAULT_CHARSET_HOME=\"/usr\" -DDATADIR=\"/var/lib/mysql\" -DSHAREDIR=\"/usr/share/mysql\" -DDONT_USE_RAID -DMYSQL_CLIENT -I. -I. -I.. -I./../include -I../include -I./.. -I.. -I.. -O3 -DDBUG_OFF -march=athlon-xp -mcpu=athlon-xp -O3 -pipe -mfpmath=sse -msse -mmmx -m3dnow -DHAVE_ERRNO_AS_DEFINE=1 -DUSE_OLD_FUNCTIONS -MT my_realloc.lo -MD -MP -MF .deps/my_realloc.Tpo -c my_realloc.c -o my_realloc.o >/dev/null 2>&1
make[2]: Leaving directory `/var/tmp/portage/mysql-4.0.20/work/mysql-4.0.20/libmysql_r'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/mysql-4.0.20/work/mysql-4.0.20'
make: *** [all] Error 2

!!! ERROR: dev-db/mysql-4.0.20 failed.
!!! Function src_compile, Line 156, Exitcode 2
!!! compile problem


Reproducible: Always
Steps to Reproduce:
1. open console
2. type "emerge mysql"
3. wait for error :D

Actual Results:  
compilation error

Expected Results:  
mysql compiled and installed

emerge info
Portage 2.0.50-r7 (default-x86-1.4, gcc-3.3.3, glibc-2.3.3_pre20040420-r0,
2.6.5-gentoo)
=================================================================
System uname: 2.6.5-gentoo i686 AMD Athlon(tm) XP 1800+
Gentoo Base System version 1.4.11
distcc 2.14 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [enabled]
Autoconf: sys-devel/autoconf-2.59-r3
Automake: sys-devel/automake-1.8.3
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-march=athlon-xp -mcpu=athlon-xp -O3 -pipe -mfpmath=sse -msse -mmmx -m3dnow"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.1/share/config /usr/kde/3.2/share/config /usr/kde/3/share/config
/usr/lib/mozilla/defaults/pref /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=athlon-xp -mcpu=athlon-xp -O3 -pipe -mfpmath=sse -msse -mmmx
-m3dnow"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache distcc sandbox"
GENTOO_MIRRORS="http://gentoo.oregonstate.edu
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 aalib alsa apache apache2 apm arts avi berkdb bonobo cdr crypt cups
emu10k1 encode esd esound foomaticdb gdbm ggi gif gpm gtk gtk2 gtkhtml guile
imlib java jpeg ldap libg++ libwww mad mesa mikmod motif mozilla mpeg mysql nas
ncurses nfs nls oggvorbis opengl oss pam pdflib perl php png postgres python qt
quicktime readline sdl slang spell ssl svga tcltk tcpd truetype x86 xft xinerama
xml xml2 xmms xsl xslt xv zlib"
Comment 1 Brian C. Dilley 2004-05-29 02:50:21 UTC
I had distcc turned on, when i turned it off i no longer experienced this problem.
Comment 2 Stefan Kiesler 2004-07-13 02:06:46 UTC
Reopen please!
Turning distcc off did NOT work for me. Got the same error message (Waiting for unfinished jobs....) until I used MAKEOPTS="-j1". Now I'm getting the following error:

In file included from item.h:476,
                 from mysql_priv.h:311,
                 from thr_malloc.cc:20:
item_cmpfunc.h: In member function `virtual Item::cond_result
   Item_func_ne::eq_cmp_result() const':
item_cmpfunc.h:36608: error: Fehler beim Parsen before `;' token
make[4]: *** [thr_malloc.o] Fehler 1
make[4]: Leaving directory `/var/tmp/portage/mysql-4.0.20/work/mysql-4.0.20/sql'
make[3]: *** [all-recursive] Fehler 1
make[3]: Leaving directory `/var/tmp/portage/mysql-4.0.20/work/mysql-4.0.20/sql'
make[2]: *** [all] Fehler 2
make[2]: Leaving directory `/var/tmp/portage/mysql-4.0.20/work/mysql-4.0.20/sql'
make[1]: *** [all-recursive] Fehler 1
make[1]: Leaving directory `/var/tmp/portage/mysql-4.0.20/work/mysql-4.0.20'
make: *** [all] Fehler 2

The error in line 36608 is quite funny, as item_cmpfunc.h is only 653 lines large.

I'm compiling on an AMD K6/2 400 with 256 MB RAM, 512 MB swap and 4,5 GB HD free. I watched the output of 'top' during my latest attempt and it didn't even swap once at all. So I would assume 256 MB is enough, but why doesn't it compile?

gs-sources-2.4.25_pre7-r8
linux-headers-2.4.19-r1 AND (?) linux-headers-2.4.21-r1
gcc-3.3.3-r6
glibc-2.3.3.20040420


emerge info:

Portage 2.0.50-r9 (default-x86-1.4, gcc-3.3.3, glibc-2.3.3.20040420-r0, 2.4.25_pre7-gss-r8)
=================================================================
System uname: 2.4.25_pre7-gss-r8 i586 AMD-K6(tm) 3D processor
Gentoo Base System version 1.4.16
distcc 2.13 i586-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
Autoconf: sys-devel/autoconf-2.59-r3
Automake: sys-devel/automake-1.8.3
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-march=k6-2 -O2 -pipe"
CHOST="i586-pc-linux-gnu"
COMPILER="gcc3"
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="-march=k6-2 -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache sandbox"
GENTOO_MIRRORS="http://horst.ranzbude.lan/wohnheim/data/gentoo/ ftp://sunsite.informatik.rwth-aachen.de/pub/Linux/gentoo ftp://ftp.wh2.tu-dresden.de/pub/mirrors/gentoo http://gd.tuwien.ac.at/opsys/linux/gentoo/ http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ http://mirrors.sec.informatik.tu-darmstadt.de/gentoo/"
MAKEOPTS="-j1"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://horst.ranzbude.lan/gentoo-portage"
USE="3dnow acl apache2 apm berkdb crypt encode ethereal gdbm gif gpm gtk2 imlib java jpeg libg++ libwww maildir mbox mysql ncurses nls oggvorbis pam pdflib perl png prelude python readline sdl slang snmp socks5 spell ssl svga tcpd x86 xml2 zlib"
Comment 3 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-07-13 10:15:14 UTC
stefan: please give the compiler error message in english!
line 36608 refers to the pre-processed file.
Comment 4 Stefan Kiesler 2004-07-14 06:40:57 UTC
OK, sorry. Well a "Fehler" is an "error" and "Fehler beim Parsen" is a "parse error", thought that was rather obvious. ;-)
As for the parse error, if I'm interpreting gcc's output correctly, it happens on line 143 of file item_cmpfunc.h. I can't see a problem there, as it's very similar to the previous functions in that file, which seem to compile well.

    137 class Item_func_ne :public Item_bool_func2
    138 {
    139 public:
    140   Item_func_ne(Item *a,Item *b) :Item_bool_func2(a,b) { }
    141   longlong val_int();
    142   enum Functype functype() const { return NE_FUNC; }
    143   cond_result eq_cmp_result() const { return COND_FALSE; }
    144   optimize_type select_optimize() const { return OPTIMIZE_NONE; }
    145   const char *func_name() const { return "<>"; }
    146 };

Any ideas? Please...
Comment 5 Stefan Kiesler 2004-07-22 04:03:35 UTC
Success!
All compiled well when I used distcc, but disabled localhost. The 256 MB RAM seemed to be the bottleneck, although it never tried to swap, which I find quite strange.
Comment 6 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-07-22 09:08:34 UTC
i've seen GCC want and instanteous memory usage of 1.2Gb while compiling some of the MySQL source files with certain CFLAGS. It asks for a big whack (more than your RAM+SWAP) and the kernel tells it to go to hell, resulting in your failed build. Reducing CFLAGS or adding memory is the only way around it.
I'm going to mark as invalid since it's your hardware.