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

Bug 176541

Summary: app-crypt/heimdal-0.7.2-r3 fails to compile - conflicting types for 'getnameinfo'
Product: Gentoo Linux Reporter: Daniel Black (RETIRED) <dragonheart>
Component: [OLD] UnspecifiedAssignee: Gentoo Kerberos Maintainers <kerberos>
Status: VERIFIED WONTFIX    
Severity: normal CC: david.w.noon
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Daniel Black (RETIRED) gentoo-dev 2007-04-30 08:59:26 UTC
x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../include -I../../include -I../../lib/roken -I../../lib/roken -I/usr/include/et -D_LARGE_FILES= -Wall -Wmissing-prototypes -Wpointer-arith -Wbad-function-cast -Wmissing-declarations -Wnested-externs -O2 -pipe -c strlwr.c -o strlwr.o >/dev/null 2>&1
/bin/sh ../../libtool --mode=compile x86_64-pc-linux-gnu-gcc  -DHAVE_CONFIG_H -I. -I. -I../../include  -I../../include -I../../lib/roken -I../../lib/roken -I/usr/include/et  -D_LARGE_FILES= -Wall -Wmissing-prototypes -Wpointer-arith -Wbad-function-cast -Wmissing-declarations -Wnested-externs -O2 -pipe -c -o getnameinfo.lo getnameinfo.c
 x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../include -I../../include -I../../lib/roken -I../../lib/roken -I/usr/include/et -D_LARGE_FILES= -Wall -Wmissing-prototypes -Wpointer-arith -Wbad-function-cast -Wmissing-declarations -Wnested-externs -O2 -pipe -c strsep_copy.c  -fPIC -DPIC -o .libs/strsep_copy.o
 x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../include -I../../include -I../../lib/roken -I../../lib/roken -I/usr/include/et -D_LARGE_FILES= -Wall -Wmissing-prototypes -Wpointer-arith -Wbad-function-cast -Wmissing-declarations -Wnested-externs -O2 -pipe -c strsep_copy.c -o strsep_copy.o >/dev/null 2>&1
 x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../include -I../../include -I../../lib/roken -I../../lib/roken -I/usr/include/et -D_LARGE_FILES= -Wall -Wmissing-prototypes -Wpointer-arith -Wbad-function-cast -Wmissing-declarations -Wnested-externs -O2 -pipe -c strupr.c  -fPIC -DPIC -o .libs/strupr.o
 x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../include -I../../include -I../../lib/roken -I../../lib/roken -I/usr/include/et -D_LARGE_FILES= -Wall -Wmissing-prototypes -Wpointer-arith -Wbad-function-cast -Wmissing-declarations -Wnested-externs -O2 -pipe -c getnameinfo.c  -fPIC -DPIC -o .libs/getnameinfo.o
/bin/sh ../../libtool --mode=link x86_64-pc-linux-gnu-gcc  -Wall -Wmissing-prototypes -Wpointer-arith -Wbad-function-cast -Wmissing-declarations -Wnested-externs -O2 -pipe   -o libtest.la   libtest_la-strftime.lo libtest_la-strptime.lo libtest_la-snprintf.lo  -lresolv -lpthread
getnameinfo.c:102: error: conflicting types for 'getnameinfo'
/usr/include/gentoo-multilib/amd64/netdb.h:649: error: previous declaration of 'getnameinfo' was here
make[3]: *** [getnameinfo.lo] Error 1
make[3]: *** Waiting for unfinished jobs....
 x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../../include -I../../include -I../../lib/roken -I../../lib/roken -I/usr/include/et -D_LARGE_FILES= -Wall -Wmissing-prototypes -Wpointer-arith -Wbad-function-cast -Wmissing-declarations -Wnested-externs -O2 -pipe -c strupr.c -o strupr.o >/dev/null 2>&1
x86_64-pc-linux-gnu-ar cru .libs/libtest.a .libs/libtest_la-strftime.o .libs/libtest_la-strptime.o .libs/libtest_la-snprintf.o
x86_64-pc-linux-gnu-ranlib .libs/libtest.a
creating libtest.la
(cd .libs && rm -f libtest.la && ln -s ../libtest.la libtest.la)
make[3]: Leaving directory `/var/tmp/portage/app-crypt/heimdal-0.7.2-r3/work/heimdal-0.7.2/lib/roken'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/var/tmp/portage/app-crypt/heimdal-0.7.2-r3/work/heimdal-0.7.2/lib/roken'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/app-crypt/heimdal-0.7.2-r3/work/heimdal-0.7.2/lib'
make: *** [all-recursive] Error 1

!!! ERROR: app-crypt/heimdal-0.7.2-r3 failed.
Call stack:
  ebuild.sh, line 1614:   Called dyn_compile
  ebuild.sh, line 971:   Called qa_call 'src_compile'
  environment, line 3578:   Called src_compile
  heimdal-0.7.2-r3.ebuild, line 62:   Called die

!!! emake failed
!!! 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/app-crypt/heimdal-0.7.2-r3/temp/build.log'.

passivegrunt ~ #
passivegrunt ~ # equery belongs /usr/include/gentoo-multilib/amd64/netdb.h
[ Searching for file(s) /usr/include/gentoo-multilib/amd64/netdb.h in *... ]
sys-libs/glibc-2.5 (/usr/include/gentoo-multilib/amd64/netdb.h)


Portage 2.1.2.2 (default-linux/amd64/2007.0, gcc-4.1.1, glibc-2.5-r0, 2.6.19-gentoo-r5 x86_64)
=================================================================
System uname: 2.6.19-gentoo-r5 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 4200+
Gentoo Base System release 1.12.9
Timestamp of tree: Sun, 29 Apr 2007 19:20:01 +0000
distcc 2.18.3 x86_64-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
dev-lang/python:     2.4.3-r4
dev-python/pycrypto: 2.0.1-r5
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.15-r1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r2
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/gconf /etc/php/apache1-php5/ext-active/ /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/splash /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks metadata-transfer sandbox sfperms strict"
GENTOO_MIRRORS="                http://mirror.internode.on.net/pub/gentoo                 http://ftp.swin.edu.au/gentoo/                 http://mirror.isp.net.au/ftp/pub/gentoo/                 http://mirror.pacific.net.au/linux/Gentoo/                 http://gentoo.osuosl.org                 http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LINGUAS="en_GB"
MAKEOPTS="-j3"
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"
PORTDIR_OVERLAY="/usr/local/portage /usr/local/layman/xeffects"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow 3dnowex X aac acl acpi adns alsa amd64 ares bash-completion berkdb bitmap-fonts bzip2 cairo caps cli cracklib crypt cups curl dbus divx4linux dri drm ecc emerald encode ethereal extensions fastcgi fla flac fortran fpx gd gif gimp gimpprint glitz gmp gnutls gphoto2 graphviz gs gtk hal hardened hpn i8x0 iconv idn ilbc imagemagick imlib ipv6 isdnlog javacomm jbig jpeg jpeg2k kde kdeenablefinal kdehiddenvisibility kerberos l7filter lcms libg++ libgda lzo lzw mad mbox midi mmx mng mp3 mpeg mysql nptl nptlonly ntlm ogg oggvorbis openal openexr opengl operanom2 pam pango pcre perl php png postgres ppds pppd python qt qt3 qt4 readline reflection restrict-javascript samba session sguil slp smime socks5 sox speex spell spl sse sse2 ssl svg svgz tga theora tiff true-type truetype truetype-fonts type1-fonts unicode usb vhosts vorbis wmf x264 xine xinerama xml xml2 xorg xscreensaver zlib zrtp" ALSA_CARDS="hda-intel" 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" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_GB" USERLAND="GNU" VIDEO_CARDS="nv vesa nvidia"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

was attempting to test bug #173219 comment #7
Comment 1 David W Noon 2007-06-02 20:09:17 UTC
I have this also, on a Core2 Duo system (i.e. also AMD64). The code compiles correctly on x86.
Comment 2 Canal Vorfeed 2007-10-20 20:48:35 UTC
There are two problems with the same test for broken getnameinfo:

1. GCC 4.2.2 will issue a warning for test program and it'll be detected as error. Fix is simple:
diff -uNr cf/broken-getaddrinfo.m4 cf/broken-getaddrinfo.m4
--- cf/broken-getaddrinfo.m4    2005-06-16 20:23:03.000000000 +0400
+++ cf/broken-getaddrinfo.m4    2007-10-21 07:50:17.000000000 +0400
@@ -5,6 +5,7 @@
 AC_DEFUN([rk_BROKEN_GETADDRINFO],[
 AC_CACHE_CHECK([if getaddrinfo handles numeric services], ac_cv_func_getaddrinfo_numserv,
 AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdio.h>
+#include <string.h>
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netdb.h>
diff -uNr cf1/broken-getnameinfo.m4 cf/broken-getnameinfo.m4
--- cf/broken-getnameinfo.m4    2004-08-31 19:31:41.000000000 +0400
+++ cf/broken-getnameinfo.m4    2007-10-21 07:50:26.000000000 +0400
@@ -5,6 +5,7 @@
 AC_DEFUN([rk_BROKEN_GETNAMEINFO],[
 AC_CACHE_CHECK([if getnameinfo is broken], ac_cv_func_getnameinfo_broken,
 AC_RUN_IFELSE([AC_LANG_SOURCE([[[#include <stdio.h>
+#include <string.h>
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netinet/in.h>

2. Test will actually can the getnameinfo and your DNS resolution is misconfigured - it'll fail.

After that heimdal will try to use it's own version of getnameinfo and it'll conflict with glibc's one...
Comment 3 Michael Hammer (RETIRED) gentoo-dev 2008-07-14 12:21:09 UTC
We are not going to fix this because we are already working on heimdal-1.2.x - Please use heimdal with our overlay at git://git.overlays.gentoo.org/proj/kerberos.git.

g, mueli