Here is the coplite output : gcc -DDEFAULT_CHARSET_HOME=\"/usr\" -DDATADIR=\"/var/lib/mysql\" -DSHAREDIR=\"/usr/share/mysql\" -DDONT_USE_RAID -I. -I. -I.. -I./../include -I../include -I./.. -I.. -I.. -O3 -DDBUG_OFF -march=i686 -mcpu=i686 -z combreloc -pipe --force-addr -fomit-frame-pointer -funroll-loops -frerun-cse-after-loop -frerun-loop-opt -falign-functions=4 -O3 -c libmysql.c -MT libmysql.lo -MD -MP -MF .deps/libmysql.TPlo -fPIC -DPIC -o .libs/libmysql.lo libmysql.c: In function `mysql_real_connect': libmysql.c:1349: warning: passing arg 5 of `gethostbyname_r' from incompatible pointer type libmysql.c:1349: too few arguments to function `gethostbyname_r' libmysql.c:1349: warning: assignment makes pointer from integer without a cast make[2]: *** [libmysql.lo] Error 1 make[2]: Leaving directory `/var/tmp/portage/mysql-3.23.55/work/mysql-3.23.55/libmysql_r' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/mysql-3.23.55/work/mysql-3.23.55' make: *** [all] Error 2 !!! ERROR: dev-db/mysql-3.23.55 failed. !!! Function src_compile, Line 101, Exitcode 2 !!! compile problem My system info : Portage 2.0.46-r12 (default-x86-1.4, gcc-3.2.2, glibc-2.2.5-r4,2.3.1-r3) ================================================================= System uname: 2.4.20-ac1 i686 AMD Athlon(tm) XP 1700+ GENTOO_MIRRORS="http://www.ibiblio.org/pub/Linux/distributions/gentoo" CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config /usr/kde/3/share/config /usr/share/config" CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d" PORTDIR="/usr/portage" DISTDIR="/usr/portage/distfiles" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR_OVERLAY="" USE="x86 apm cups quicktime zlib slang tetex aalib guile ruby esd gnome cdr scanner 3dnow alsa arts avi berkdb bonobo crypt dga directfb doc dvd encode evo fbcon flash gb gd gdbm ggi gif gpm gtk gtkhtml innodb imap imlib ipv6 java jpeg lcms libwww libg++ kde mikmod mmx motif mpeg nas ncurses nls nocardbus mozilla mozirc mysql oggvorbis opengl oss pam -pcmcia pda pdflib perl png python qt qtmt readline sdl snmp socks5 spell sse ssl svga tcltk tcpd truetype usb X xml xml2 xmms xv" COMPILER="gcc3" CHOST="i686-pc-linux-gnu" CFLAGS="-march=i686 -mcpu=i686 -O3 -z combreloc -pipe --force-addr -fomit-frame-pointer -funroll-loops -frerun-cse-after-loop -frerun-loop-opt -falign-functions=4" CXXFLAGS="-march=i686 -mcpu=i686 -O3 -z combreloc -pipe --force-addr -fomit-frame-pointer -funroll-loops -frerun-cse-after-loop -frerun-loop-opt -malign-functions=4" ACCEPT_KEYWORDS="x86 ~x86" MAKEOPTS="-j2" AUTOCLEAN="yes" SYNC="rsync://rsync.gentoo.org/gentoo-portage" FEATURES="sandbox ccache" Reproducible: Always Steps to Reproduce: 1. 2. 3.
Resolved with : CFLAGS="" CXXFLAGS="" emerge mysql I've got now an unoptimised but merged mysql As it's just for a dependency when I do an emerge -ub world, it have no importance.
I have the same problem, but in another file: g++ -DMYSQL_SERVER -DDEFAULT_MYSQL_HOME="\"/usr\"" -DDATADIR="\"/var/lib/mysql\"" -DSHAREDIR="\"/usr/share/mysql\"" -DHAVE_CONFIG_H -I. -I. -I.. -I../bdb/build_unix -I./../include -I./../regex -I. -I../include -I.. -I. -O3 -DDBUG_OFF -march=athlon-tbird -pipe -O3 -felide-constructors -fno-exceptions -fno-rtti -fno-implicit-templates -fno-exceptions -fno-rtti -c -o mysqld.o `test -f mysqld.cc || echo './'`mysqld.cc /usr/include/tcpd.h: In function `void* handle_connections_sockets(void*)': /usr/include/tcpd.h:135: too many arguments to function `void sock_host()' mysqld.cc:2513: at this point in file /usr/include/tcpd.h:73: too many arguments to function `int hosts_access()' mysqld.cc:2514: at this point in file /usr/include/tcpd.h:128: too many arguments to function `char* eval_client()' mysqld.cc:2522: at this point in file make[4]: *** [mysqld.o] Error 1 'CFLAGS="" CXXFLAGS="" emerge mysql' did /NOT/ fix this problem. emerge info gives: Portage 2.0.46-r12 (default-x86-1.4, gcc-3.2.2, glibc-2.2.5-r2,2.3.1-r3) ================================================================= System uname: 2.4.19-gentoo-r10 i686 AMD Athlon(tm) Processor GENTOO_MIRRORS="http://gentoo.oregonstate.edu/ http://distro.ibiblio.org/pub/Linux/distributions/gentoo" CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config /usr/kde/3/share/config /usr/X11R6/lib/X11/xkb /usr/share/config" CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d" PORTDIR="/usr/portage" DISTDIR="/usr/portage/distfiles" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR_OVERLAY="/usr/local/portage" USE="x86 oss 3dnow apm avi crypt cups encode gif jpeg gnome libg++ mikmod mmx mpeg ncurses nls pdflib png qtmt quicktime spell truetype xml2 xmms xv zlib alsa gdbm berkdb slang readline svga java mysql X sdl gpm tcpd pam libwww ssl perl python esd imlib oggvorbis gtk qt motif opengl mozilla scanner cdr -kde -arts" COMPILER="gcc3" CHOST="i686-pc-linux-gnu" CFLAGS="-march=athlon-tbird -O3 -pipe" CXXFLAGS="-march=athlon-tbird -O3 -pipe" ACCEPT_KEYWORDS="x86 ~x86" MAKEOPTS="-j2" AUTOCLEAN="yes" SYNC="rsync://rsync.gentoo.org/gentoo-portage" FEATURES="sandbox ccache"
I believe this is an IPv6 issue. If you can accept it, a workaround might be to temporarily USE="-ipv6" until a better fix is found.
Upon further investigation, this problem may be a manifestation of a broken C++ compiler. Please verify that your C++ compiler is working properly. Otherwise, the configure test for the glibc2 gethostbyname_r program fails, and MySQL falls back on an incorrect version at compile time.
well, dunno what else it could be. also, mysql-4 is basically the lastest stable version. might want to try that as well.