[Kwintv] Compilation problems with kernel/libc headers

Zsolt Rizsanyi rizsanyi at myrealbox.com
Sat Dec 13 16:01:13 CET 2003


On Wednesday 10 December 2003 12.15, Christian Sangohn wrote:
> > > and it has always become better and better. But :) What happened to the
> > >
> > > Videotext / teletext plugin ?
> >
> > Nothing. It's there and working fine :-) Did you select and correctly
> > configure the vbidecoder? Check the plugins settings dialog page...
>
> I can´t remember finding it but I´ll check again as soon as I managed to
> recompile with KDE-3.1.94
> (3.2-beta2) :(
> I´m having problems compiling yesteday´s (20031209) snapshot. it seems to
> be limited to the v4l part.
>
> sikasso:kvideoio # make
> if /bin/sh ../../libtool --silent --mode=compile --tag=CXX g++
> -DHAVE_CONFIG_H -I. -I. -I../.. -I/opt/
> K-Desktop-Environment-3.1.94/include
> -I/usr/local/lib/qt-x11-free-3.2.1/include -I/usr/X11R6/include
> -DQT_THREAD_SUPPORT  -D_REENTRANT  -Wnon-virtual-dtor -Wno-long-long
> -Wundef -Wall -W
> -Wpointer-arith -Wwrite-strings -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE
> -Wcast-align
> -Wconversion -Wchar-subscripts -fno-builtin -g -O2 -Wformat-security
> -Wmissing-format-attribute
> -fno-exceptions -fno-check-new -fno-common  -MT v4ldev.lo -MD -MP -MF
> ".deps/v4ldev.Tpo" \
>   -c -o v4ldev.lo `test -f 'v4ldev.cpp' || echo './'`v4ldev.cpp; \
> then mv -f ".deps/v4ldev.Tpo" ".deps/v4ldev.Plo"; \
> else rm -f ".deps/v4ldev.Tpo"; exit 1; \
> fi
> In file included from /usr/include/linux/videodev2.h:16,
>                  from /usr/include/linux/videodev.h:8,
>                  from v4ldev.h:40,
>                  from v4ldev.cpp:37:
> /usr/include/linux/time.h:9: error: redefinition of `struct timespec'
> /usr/include/time.h:119: error: previous definition of `struct timespec'
> /usr/include/linux/time.h:15: error: redefinition of `struct timeval'
> /usr/include/bits/time.h:70: error: previous definition of `struct timeval'
>
> /usr/include/linux/time.h:354: error: redefinition of `struct itimerspec'
>
> /usr/include/time.h:160: error: previous definition of `struct itimerspec'
>
> In file included from v4ldev.cpp:42:
> /usr/include/sys/time.h:57: error: redefinition of `struct timezone'
> /usr/include/linux/time.h:20: error: previous definition of `struct
> timezone'
> /usr/include/sys/time.h:94: error: parse error before numeric constant
> /usr/include/sys/time.h:108: error: redefinition of `struct itimerval'
> /usr/include/linux/time.h:359: error: previous definition of `struct
> itimerval'
> make: *** [v4ldev.lo] Error 1
>
> I´m running Debian testing (sarge) with libc 2.3.2-ds10 and
> linux-kernel-headers-2.5.99; this ia surely
> not a typical setup so could it be that some of these kernel and/or libc
> headers don´t work well
> together? I personally don´t think so, so i must have done somthing wrong
> here. How can this problem
> be circumvented?

I have solved this problem by an ugly hack: commenting out the most parts of 
the /usr/include/linux/time.h.
But you can try other approaches suggested in debian bug: #220232.
You can also look at bug #220399.

I have had also some different problems in other part of the qtvision. Which I 
have solved with the next patch:

Index: qtvision/plugins/video/v4l/qtvision_v4l.cpp
===================================================================
RCS file: /home/kde/kdenonbeta/kwintv3/qtvision/plugins/video/v4l/
qtvision_v4l.cpp,v
retrieving revision 1.62
diff -u -p -r1.62 qtvision_v4l.cpp
--- qtvision/plugins/video/v4l/qtvision_v4l.cpp 1 Dec 2003 18:39:58 -0000       
1.62
+++ qtvision/plugins/video/v4l/qtvision_v4l.cpp 13 Dec 2003 14:58:43 -0000
@@ -49,6 +49,7 @@
 #include <stdlib.h>

 #ifdef HAVE_DVBS
+#undef __STRICT_ANSI__
 #include <linux/dvb/frontend.h>
 #include <linux/dvb/dmx.h>
 #endif


If you dont want to bother with it, then I can send you (in private) the .deb 
package I built, and it will maybe work for you...

Regards
Zsolt



More information about the kwintv mailing list