Bug 79204 - d4x does not compile
Bug#: 79204 Product:  Gentoo Linux Version: 2004.3 Platform: x86
OS/Version: All Status: RESOLVED Severity: normal Priority: P2
Resolution: FIXED Assigned To: liquidx@gentoo.org Reported By: tom@tomaw.net
Component: Applications
URL: 
Summary: d4x does not compile
Keywords:  
Status Whiteboard: 
Opened: 2005-01-23 06:00 0000
Description:   Opened: 2005-01-23 06:00 0000
d4x fails to compile with the following output:

<command line>:4:1: warning: this is the location of the previous definition
if i686-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I. -I../..   -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -DXTHREADS -D_REENTRANT -DXUSE_MTSAFE_API -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 -include ../../config.h  -march=athlon-mp -O2 -pipe -D_FILE_OFFSET_BITS=64   -MT edit.o -MD -MP -MF ".deps/edit.Tpo" -c -o edit.o edit.cc; \
then mv -f ".deps/edit.Tpo" ".deps/edit.Po"; else rm -f ".deps/edit.Tpo"; exit 1; fi
In file included from <command line>:7:
./../../config.h:464:1: warning: "_REENTRANT" redefined
<command line>:4:1: warning: this is the location of the previous definition
lod.cc:130: error: conflicting declaration 'struct GtkCellRendererProgress'
/usr/include/gtk-2.0/gtk/gtkcellrendererprogress.h:41: error: 'GtkCellRendererProgress' has a previous declaration as `typedef struct _GtkCellRendererProgress GtkCellRendererProgress'
lod.cc:136: error: conflicting declaration 'struct GtkCellRendererProgressClass'
/usr/include/gtk-2.0/gtk/gtkcellrendererprogress.h:42: error: 'GtkCellRendererProgressClass' has a previous declaration as `typedef struct _GtkCellRendererProgressClass GtkCellRendererProgressClass'
lod.cc: In function `void gtk_cell_renderer_progress_set_property(GObject*, guint, const GValue*, GParamSpec*)':
lod.cc:178: error: 'struct _GtkCellRendererProgress' has no member named 'percent'
lod.cc:181: error: 'struct _GtkCellRendererProgress' has no member named 'dwn'
lod.cc: In function `void gtk_cell_renderer_progress_render(GtkCellRenderer*, GdkWindow*, GtkWidget*, GdkRectangle*, GdkRectangle*, GdkRectangle*, GtkCellRendererState)':
lod.cc:198: error: 'struct _GtkCellRendererProgress' has no member named 'percent'
lod.cc:226: error: 'struct _GtkCellRendererProgress' has no member named 'dwn'
make[3]: *** [lod.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory `/var/tmp/portage/d4x-2.5.0/work/d4x-2.5.0final/main/face'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/var/tmp/portage/d4x-2.5.0/work/d4x-2.5.0final/main'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/d4x-2.5.0/work/d4x-2.5.0final'
make: *** [all] Error 2


emerge info:
Portage 2.0.51-r14 (default-linux/x86/2004.3, gcc-3.4.3, glibc-2.3.4.20041102-r0, 2.6.10-gentoo-r6 i686)
=================================================================
System uname: 2.6.10-gentoo-r6 i686 AMD Athlon(tm) MP 2400+
Gentoo Base System version 1.6.8
Python:              dev-lang/python-2.3.4 [2.3.4 (#1, Nov  6 2004, 22:58:27)]
dev-lang/python:     2.3.4
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.8.5-r1, 1.8.5-r2, 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.2-r7
virtual/os-headers:  2.6.8.1-r2
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-march=athlon-mp -O2 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/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/mail/dspam /etc/terminfo /etc/env.d"
CXXFLAGS="-march=athlon-mp -O2 -pipe"
DISTDIR="/usr/portage-distfiles"
FEATURES="autoaddcvs autoconfig candy ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ http://gentoo.tiscali.nl/gentoo/ http://ftp.easynet.nl/mirror/gentoo/ http://gentoo.mirror.sdv.fr ftp://ftp.tiscali.nl/pub/mirror/gentoo http://mir.zyrianes.net/gentoo/ http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ http://www.mirrorservice.org/sites/www.ibiblio.org/gentoo/"
MAKEOPTS="-j3"
PKGDIR="/usr/portage-packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="x86 3dfx 3dnow X aalib alsa apm avi berkdb bitmap-fonts cdr crypt cups dga dvd dvdr eds encode evo f77 fam font-server foomaticdb fortran gdbm gif gnome gpm gstreamer gtk gtk2 guile hal imagemagick imlib ipv6 java jikes jpeg ldap libg++ libwww mad mikmod mmx motif moznocompose moznoirc moznomail mpeg mysql ncurses network nls nntp nptl offensive oggvorbis opengl oss pam pda pdflib perl png python quicktime readline sdl slang smime spell ssl svga tcltk tcpd tetex tiff truetype truetype-fonts type1-fonts unicode xine xml2 xprint xv zlib linguas_en_GB"
Unset:  ASFLAGS, CBUILD, CTARGET, LDFLAGS

I'm using GTK+-2.6.1-r1.

------- Comment #1 From Felix Riemann 2005-01-26 09:14:14 0000 -------
Created an attachment (id=49573) [details]
a quick work-around

This is a naming conflict with gtk+-2.6.
GtkCellRendererProgress didn't exist in gtk+-2.4, but does in 2.6.
This patch simply renames the GtkCellRendererProgress-implementation in d4x to
a safe name.

------- Comment #2 From Peter Volkov 2005-02-02 14:08:25 0000 -------
Strange.
I'm using gtk+2.4 and do not have such bug.

------- Comment #3 From Felix Riemann 2005-02-13 08:29:49 0000 -------
The implementation of GtkCellRendererProgress in d4x conflicts with the
implementation of gtk+-2.6. gtk+-2.4 is not affected, because it doesn't
provide a GtkCellRendererProgress object.

------- Comment #4 From Fyodor Kupchik 2005-03-08 05:00:34 0000 -------
Created an attachment (id=52924) [details]
fixed ebuild with new patch and gtk/glib version correction

------- Comment #5 From pharon@gmail.com 2005-03-08 17:15:49 0000 -------
I tried the proposed patch, and it allowed d4x to be compiled with glib/gtk 2.6

However the program segfaults as soon as it is run. The backtrace from gdb (even with d4x compiled in debug mode ) is :
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 994679120 (LWP 29824)]
0x3b05a8b5 in g_type_check_instance_is_a () from /usr/lib/libgobject-2.0.so.0
(gdb) backtrace
#0  0x3b05a8b5 in g_type_check_instance_is_a ()
   from /usr/lib/libgobject-2.0.so.0


------- Comment #6 From Xavier Neys 2005-03-17 08:12:55 0000 -------
FWIW, sticking the following sed in src_unpack did it for me on ~x86 and
~amd64, both up-to-date at the time of writing.

sed -i 's:GtkCellRendererProgress:d4xGtkCellRendererProgress:g'
main/face/lod.cc

------- Comment #7 From pharon@gmail.com 2005-03-21 07:46:25 0000 -------
The segfault I posted was due to libglade-2.5.0. It was fixed with
libglade-2.5.1.

------- Comment #8 From Akshay Badhe 2005-03-30 02:42:55 0000 -------
i am new here can u please tell me
how to use this work-around. 

------- Comment #9 From Yasha Davidov 2005-04-09 12:30:07 0000 -------
Is this patch going to be in portage?

------- Comment #10 From Thomas Raschbacher 2005-04-21 06:09:27 0000 -------
any news on this? (i like d4x though aria is good too ;))

------- Comment #11 From Vasileios P. Lourdas 2005-04-29 10:59:23 0000 -------
Compiles ok with the proposed patch and ebuild.

------- Comment #12 From Alexander Jenisch 2005-05-11 02:52:12 0000 -------
uhm... i can't find the patch to download though?

------- Comment #13 From Tom Wesley 2005-05-11 03:03:56 0000 -------
From #6 if you put 

sed -i 's:GtkCellRendererProgress:d4xGtkCellRendererProgress:g' main/face/lod.cc

in the src_unpack of the ebuild it works fine for me.

------- Comment #14 From Omer Hasan 2005-05-27 00:48:02 0000 -------
patch from #1 and ebuild from #4 work great here. This should be updated into
portage soon as there isn't a working version in portage. 

------- Comment #15 From Chen Xiangyang 2005-06-04 16:43:24 0000 -------
Verified in current portage.  Please fix it as soon as possible.

------- Comment #16 From Stanislav Nikolov 2005-06-24 05:46:13 0000 -------
Well, this bug has been solved for so long and in many ways. Why hasn't it been
merged with the portage tree yet ?

------- Comment #17 From Alastair Tse (RETIRED) 2005-06-24 07:00:49 0000 -------
its not fixed because i'm lazy ... but i've finally got time for it now. new
ebuild and patch now in portage. 
thanks for all your contributions and patience!

------- Comment #18 From Igor Vagulin 2005-06-26 01:36:56 0000 -------
*** Bug 97034 has been marked as a duplicate of this bug. ***

------- Comment #19 From Jakub Moc (RETIRED) 2005-07-25 09:25:05 0000 -------
*** Bug 100244 has been marked as a duplicate of this bug. ***

------- Comment #20 From Stephen Dranger 2005-07-27 19:20:15 0000 -------
This bug is still showing up in portage for d4x 2.5.0 rc4.

------- Comment #21 From Tom Wesley 2005-07-28 00:30:41 0000 -------
I will do.  This bug was fixed in d4x-2.5.0-r1.  If you're using x86, you will
need the use the ~x86 version of this package.

------- Comment #22 From Jakub Moc (RETIRED) 2005-11-29 23:15:58 0000 -------
*** Bug 113990 has been marked as a duplicate of this bug. ***