Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 78617 - dbus-0.23 fails on dbus-launch.c
Summary: dbus-0.23 fails on dbus-launch.c
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] GNOME (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-01-18 21:18 UTC by Evan Langlois
Modified: 2005-02-09 22:19 UTC (History)
0 users

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


Attachments
ebuild with addition "epatch" line to fix problem (dbus-0.23.ebuild,2.77 KB, text/plain)
2005-01-21 00:38 UTC, Evan Langlois
Details
The little patch to make it work (dbus-0.23-fd_set.patch,293 bytes, patch)
2005-01-21 00:38 UTC, Evan Langlois
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Evan Langlois 2005-01-18 21:18:33 UTC
Can't emerge dbus-0.23 ...

if i586-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I.. -I..  -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -I/usr/X11R6/include -D_XOPEN_SOURCE=500 -DXTHREADS -DXUSE_MTSAFE_API -D_REENTRANT -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/opt/fdo//include -I/usr/X11R6/include -I/usr/include/atk-1.0 -I/usr/include/pango-1.0 -I/usr/include/freetype2 -I/usr/include/freetype2/config -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -DDBUS_LOCALEDIR=\"/usr/@DATADIRNAME@/locale\"  -DDBUS_API_SUBJECT_TO_CHANGE=1   -O2 -march=k6-2 -ffast-math -fstrict-aliasing -DNDEBUG -frename-registers -fomit-frame-pointer -pipe -Wall -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wcast-align -Wfloat-equal -Wsign-compare -MT dbus-cleanup-sockets.o -MD -MP -MF ".deps/dbus-cleanup-sockets.Tpo" -c -o dbus-cleanup-sockets.o dbus-cleanup-sockets.c; \
then mv -f ".deps/dbus-cleanup-sockets.Tpo" ".deps/dbus-cleanup-sockets.Po"; else rm -f ".deps/dbus-cleanup-sockets.Tpo"; exit 1; fi
dbus-launch.c: In function `kill_bus_when_session_ends':
dbus-launch.c:323: error: `fd_set' undeclared (first use in this function)
dbus-launch.c:323: error: (Each undeclared identifier is reported only once
dbus-launch.c:323: error: for each function it appears in.)
dbus-launch.c:323: error: parse error before "read_set"
dbus-launch.c:373: warning: implicit declaration of function `FD_ZERO'
dbus-launch.c:373: warning: nested extern declaration of `FD_ZERO'
dbus-launch.c:373: error: `read_set' undeclared (first use in this function)
dbus-launch.c:374: error: `err_set' undeclared (first use in this function)
dbus-launch.c:378: warning: implicit declaration of function `FD_SET'
dbus-launch.c:378: warning: nested extern declaration of `FD_SET'
dbus-launch.c:384: warning: nested extern declaration of `FD_SET'
dbus-launch.c:388: warning: implicit declaration of function `select'
dbus-launch.c:388: warning: nested extern declaration of `select'
dbus-launch.c:404: warning: implicit declaration of function `FD_ISSET'
dbus-launch.c:404: warning: nested extern declaration of `FD_ISSET'
make[2]: *** [dbus-launch.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory `/usr/tmp/portage/dbus-0.23/work/dbus-0.23/tools'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/tmp/portage/dbus-0.23/work/dbus-0.23'
make: *** [all] Error 2

!!! ERROR: sys-apps/dbus-0.23 failed.
!!! Function src_compile, Line 89, Exitcode 2
!!! (no error message)
!!! If you need support, post the topmost build error, NOT this status message.



Reproducible: Always
Steps to Reproduce:
1. emerge dbus (or anything that depends on it since the USE flag is set)





[ebuild  N    ] sys-apps/dbus-0.23  +X -debug +gtk +mono +python -qt +xml2 0 kB

Portage 2.0.51-r13 (default-linux/x86/2004.3, gcc-3.4.3,
glibc-2.3.4.20041102-r0, 2.6.9-nitro3 i586)
=================================================================
System uname: 2.6.9-nitro3 i586 AMD-K6(tm) 3D processor
Gentoo Base System version 1.6.8
Python:              dev-lang/python-2.3.4 [2.3.4 (#1, Jun 29 2004, 05:54:33)]
distcc 2.17 i586-pc-linux-gnu (protocols 1 and 2) (default port 3632)
[disabled]ccache version 2.3 [enabled]
dev-lang/python:     2.3.4
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.8.5-r2, 1.5, 1.4_p6, 1.6.3, 1.7.9, 1.9.4
sys-devel/binutils:  2.15.92.0.2-r2
sys-devel/libtool:   1.5.10-r2
virtual/os-headers:  2.6.8.1-r2
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=k6-2 -ffast-math -fstrict-aliasing -DNDEBUG
-frename-registers -fomit-frame-pointer -pipe"
CHOST="i586-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.2/share/config /usr/kde/3/share/config /usr/lib/X11/xkb
/usr/share/config /usr/share/texmf/dvipdfm/config/
/usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/
/usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=k6-2 -ffast-math -fstrict-aliasing -DNDEBUG
-frename-registers -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig candy ccache confcache distlocks sandbox sfperms"
GENTOO_MIRRORS="ftp:///ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/
ftp://vlaai.snt.ipv6.utwente.nl/pub/os/linux/gentoo/
http://ftp6.uni-erlangen.de/pub/mirrors/gentoo http://gentoo.binarycompass.org
http://gentoo.seren.com/gentoo ftp://ftp6.uni-erlangen.de/pub/mirrors/gentoo
http://gentoo.mirror.sdv.fr http://gentoo.math.bme.hu
http://chod.cwru.edu/gentoo
http://vlaai.snt.ipv6.utwente.nl/pub/os/linux/gentoo/
http://mirror.datapipe.net/gentoo http://gentoo.tiscali.nl/gentoo/
http://gentoo.llarian.net/ http://cudlug.cudenver.edu/gentoo/
http://ftp.isu.edu.tw/pub/Linux/Gentoo http://ftp.easynet.nl/mirror/gentoo/
ftp://ftp.ipv6.uni-muenster.de/pub/linux/distributions/gentoo
http://mirrors.tds.net/gentoo
http://mirror.clarkson.edu/pub/distributions/gentoo/ http://gentoo.netnitco.net"
LDFLAGS="-Wl,-O1"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="3dnow 3ds X X509 aac aalib acpi adns aim aliaschain alsa amd apache2 apm
artworkextra asterisk async atm audiofile avantgo avi beep bitmap-fonts bonobo
bzip2 bzlib caps cdb cddb cdinstall cdparanoia cdr cgi chroot clamav clearpasswd
cnamefix composite cpdflib crypt cscope ctype cups dba dbx devfs devfs26 devmap
dga diet dillo dio directfb distcache divx4linux djbfft dlloader dmx dnd dnsdb
dri dvb dvd dvdread editor edl eds encode erandom escreen esd ethereal etwin
evms evms2 evo exif exiscan ext-png ext-zlib f77 faac faad fam fastcgi fax fbcon
fbdev ffmpeg fftw flac flash flatfile flood fluidsynth fmod font-server
foomaticdb fortran freetds freetts freetype fs ftp fwdzone gatos gb gcj gd
gd-external gdbm geoip ggi gif gimp gimpprint glade glgd glut gmp gmtsuppl
gmttria gnome gnomedb gnuplot gnutls gphoto2 gpm gps gs gsl gstreamer gtk gtk2
gtkhtml guile hal hbci hdf hdf5 hostap-nopci hostap-noplx icq icu idl ieee1394
image imagemagick imap imlib imlib2 inifile innodb ipalias ipv6 ipv6arpa irda
irmc jabber jack jack-tmpfs java javascript jbig jce jit joystick jp2 jpeg junit
kadu-modules kadu-voice ladcca lcd lcms ldap libcaca libdsk libg++ libgda
libsamplerate libwww lirc live lmtp ltsp lufsusermount lzo lzw lzw-tiff mad
maildir makecheck matroska mbox mcve md5sum mdb memlimit mhash milter ming mixer
mldonkeypango mmap mmx mng monkey mono motif mozilla moznomail mozsvg mpeg mpeg4
mplayer msn mssql multicall multipleip multitarget music mysql mythtv nagios-dns
nagios-ntp nagios-ping nagios-ssh nas native ncurses neXt net netboot netcdf
nethack network neural nntp nocd nosource notlsbeforeauth nowin nptl ntlm nviz
oav objc odbc offensive oggvorbis opengl openssh operanom2 opie oscar oss pam
pcap pcntl pcre pcsc-lite pda pdflib perl php physfs pic plotutils png pnp
portaudio posix postgres ppds psyco pthreads python qemu-fast quicktime quotes
radeon readline remote rogue rtc samba sasl scanner sdk sdl semanticfix session
shared silc silverxp skey slang slp smartcard sndfile snmp sockets socks5
softmmu sox speedo speex spell sqlite ssl stroke svg szip t1lib tcltk tcpd tcsim
tetex tga theora threads tiff timidity tokenizer tools transcode
transparent-proxy truetype truetype-fonts trusted type1 type1-fonts usagi usb
uudeview v4l v4l2 vhosts videos virus-scan wacom wddx wifi wmf wxwin wxwindows
x86 xatrix xchattext xforms xinerama xml xml2 xmms xosd xprint xrandr xsl xv
xvid yahoo yaz yv12 zlib zvbi"
Unset:  PORTDIR_OVERLAY
Comment 1 foser (RETIRED) gentoo-dev 2005-01-19 04:22:36 UTC
What I see is a missing kernel header symbol (which is definitely in the version given), a non-gentoo kernel, a weird include pointing to /opt & an unset PORTDIR_OVERLAY (which considering the kernel is odd & suspicious).

Unless you come with some real good evidence this is really a problem on a clean system, i'm gonna close this as bogus.
Comment 2 Evan Langlois 2005-01-19 23:18:27 UTC
OK - I re-emerged linux26-headers (shouldn't have needed to), and then emerged a new kernel.  Still getting the same results with dbus.  The "weird include pointing to /opt" is the freedesktop.org Xserver, which I keep around since new versions of X sometimes break, and for other reasons.   I re-tested without that include, and it still dies.

fd_set should still not be undeclared!  Any ideas?  As for your comment on "clean system", gentoo has plenty of problems on "clean systems", not to mention that its supposed to continue to work even on upgrades.   Just because you don't know the answer doesn't mean you should blame the user!

if i586-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I.. -I..  -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -I/usr/X11R6/include -D_XOPEN_SOURCE=500 -DXTHREADS -DXUSE_MTSAFE_API -D_REENTRANT -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/X11R6/include -I/usr/include/atk-1.0 -I/usr/include/pango-1.0 -I/usr/include/freetype2 -I/usr/include/freetype2/config -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -DDBUS_LOCALEDIR=\"/usr/@DATADIRNAME@/locale\"  -DDBUS_API_SUBJECT_TO_CHANGE=1   -O2 -march=k6-2 -ffast-math -fstrict-aliasing -DNDEBUG -frename-registers -fomit-frame-pointer -pipe -Wall -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wcast-align -Wfloat-equal -Wsign-compare -MT dbus-launch.o -MD -MP -MF ".deps/dbus-launch.Tpo" -c -o dbus-launch.o dbus-launch.c; \
then mv -f ".deps/dbus-launch.Tpo" ".deps/dbus-launch.Po"; else rm -f ".deps/dbus-launch.Tpo"; exit 1; fi
dbus-launch.c: In function `kill_bus_when_session_ends':
dbus-launch.c:323: error: `fd_set' undeclared (first use in this function)
dbus-launch.c:323: error: (Each undeclared identifier is reported only once
dbus-launch.c:323: error: for each function it appears in.)
dbus-launch.c:323: error: parse error before "read_set"
dbus-launch.c:373: warning: implicit declaration of function `FD_ZERO'
dbus-launch.c:373: warning: nested extern declaration of `FD_ZERO'
dbus-launch.c:373: error: `read_set' undeclared (first use in this function)
dbus-launch.c:374: error: `err_set' undeclared (first use in this function)
dbus-launch.c:378: warning: implicit declaration of function `FD_SET'
dbus-launch.c:378: warning: nested extern declaration of `FD_SET'
dbus-launch.c:384: warning: nested extern declaration of `FD_SET'
dbus-launch.c:388: warning: implicit declaration of function `select'
dbus-launch.c:388: warning: nested extern declaration of `select'
dbus-launch.c:404: warning: implicit declaration of function `FD_ISSET'
dbus-launch.c:404: warning: nested extern declaration of `FD_ISSET'
make: *** [dbus-launch.o] Error 1


Portage 2.0.51-r13 (default-linux/x86/2004.3, gcc-3.4.3, glibc-2.3.4.20041102-r0, 2.6.10-gentoo-r6 i586)
=================================================================
System uname: 2.6.10-gentoo-r6 i586 AMD-K6(tm) 3D processor
Gentoo Base System version 1.6.8
Python:              dev-lang/python-2.3.4 [2.3.4 (#1, Jun 29 2004, 05:54:33)]
distcc 2.17 i586-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]ccache version 2.3 [enabled]
dev-lang/python:     2.3.4
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.8.5-r2, 1.5, 1.4_p6, 1.6.3, 1.7.9, 1.9.4
sys-devel/binutils:  2.15.92.0.2-r2
sys-devel/libtool:   1.5.10-r2
virtual/os-headers:  2.6.8.1-r2
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=k6-2 -ffast-math -fstrict-aliasing -DNDEBUG -frename-registers -fomit-frame-pointer -pipe"
CHOST="i586-pc-linux-gnu"
... rest is unchanged ...
Comment 3 foser (RETIRED) gentoo-dev 2005-01-20 01:40:11 UTC
The simple answer is that on a 'clean' system (and != newly installed) I know what can happen and here I have no such certainty. Also your info is not in sync with the state of your sys (no overlay, several probable overlay artifacts), then you get rather defensive not taking away any of my doubts on the saneness of the sys.

As you say clean systems have problems enough to deal with, to also bother with outside stuff. So thats is why I need to be certain it's not a problem caused by your personal tinkering.

I already helped by indicating what the problem is (yes i put time in it anyway), if you can mess around with your sys, i expect you to also be able to find problems with it. You can reproduce it, I can't, I expect you to do the works.
Comment 4 Evan Langlois 2005-01-20 23:52:59 UTC
The overlay is no longer set because its now in a tarball .. I don't need it anymore unless I need to re-emerge it.  Nothing relies on it, so its a dead issue.

does dbus-launch.c actually compile on your system with the same set of USE flags?

fd_set is in sys/select.h, and adding that #include to the file will make it compile on my system.  How is this being included in your system?  Perhaps this isn't being compiled at all on your system due to different USE flags?  I don't think my C headers are so screwed that a common function like fd_set is just missing.

Now, if you tell me what chain of includes is causing fd_set to be defined, I can see which of my includes are different.  Otherwise, I think a patch should be made so that "#include <sys/select.h>" is in that file.  
Comment 5 Evan Langlois 2005-01-21 00:38:25 UTC
Created attachment 49094 [details]
ebuild with addition "epatch" line to fix problem
Comment 6 Evan Langlois 2005-01-21 00:38:57 UTC
Created attachment 49095 [details, diff]
The little patch to make it work
Comment 7 foser (RETIRED) gentoo-dev 2005-01-21 05:37:06 UTC
you give no reason why this happens, thats what I need to patch.
Comment 8 Evan Langlois 2005-01-21 16:41:10 UTC
Uhmm .. you're the expert.  I gave every reason why this happens.  It doesn't include the header that defines fd_set.  Thats what I've been saying from the very beginning, and you just say that its my fault.  You answered none of my questions and have given no help other than blaming supposed "tweaks" on my system which have nothing to do with the problem.  As far as I know, fd_set is defined in sys/select.h, and that is the file that should be included to get fd_set, and sys/select.h isn't included in the file that fails to compile.

Now, should some other file be included to get this macro instead?  Are my assumptions listed above about fd_set incorrect, even though the fix following those assumptions results in the expected behavior?  The way I see it, the file fails to include a needed header and fails to compile, so including it is the fix.  This should be cut-n-dry.

Could you answer any of my previous questions on what is different between our systems or on which chain of includes from dbus_launch.c ends up defining fd_set?  I can't tell you why yours works because you haven't told me - I don't even know if your system TRIED compiling that file, as I said, it may not use dbus_launch.c with other combinations of USE flags.  

Can the patch just be submitted in the off chance that someone else might have the same problem?  Many people (including myself), just remove USE flags to make something compile instead of reporting the bug to get it fixed - I'm trying to be a good citizen and at least get the issues documented so they can be fixed.
Comment 9 foser (RETIRED) gentoo-dev 2005-02-06 09:13:01 UTC
I'm in no way the expert, thats why I insist on understanding the problem and not just patching away.

But I don't think this patch is incorrect, altough I cannot reproduce the problem at all and apparently there's noone else seeing it.

added the patch to dbus-0.23-r2, thnx for your report.
Comment 10 Evan Langlois 2005-02-09 22:19:59 UTC
I found the problem.  Not sure how it got there, but for future reference, the -D_XOPEN_SOURCE=500 causes the other header files to not include sys/select.h.  This can cause similar problems with gdm as well.  I still think its best for the original authors to include sys/select.h if you are using information from that file, but I removed this define from the gdk-x11 package-config (.pc) file so it won't cause these issues and I'm re-emerging most everything to avoid future problems.  Wish I knew what put that define there, but it's gone now.  I don't know what that define is supposed to be for, but things work fine with it defined if sys/select.h is included like in the patch.