[Kwintv] v4l plugin

John Campbell kwintv@mail.kde.org
Tue, 12 Nov 2002 19:08:54 -0800


On Tue, 12 Nov 2002 09:54:18 -0500, you wrote:

>On Tuesday November 12 2002 06:14, John Campbell wrote:
>> I've just installed Mandrake 9.0 after being a loyal RedHat user for
>> years.
>>
>> I'm not sure if my problem is with Mandrake or is simply a coincidence
>> in code-changes/libs between a week or so ago and now.
>>
>> But my problem is that the V4l plugin is failing to compile because
>> the <linux/videodev.h> header doesn't include __c64 (and his friends)
>> if compiled with the "-ansi" flag, which qtvision uses, or at least my
>> configuration does.
>>
>> When I remove the "-ansi" flag from the v4l plugin's Makefile
>> everything compiles and runs fine.  Of course, next time I update it
>> will all be stripped out again as the Makefiles are generated by
>> configure.
>
>   Yes I noticed this last night too.  This is because mandrake has v4l2=
=20
>patched in.  I'm not quite sure what the v4l people want us to do about =
this=20
>in userspace.  As a temporary hack, I added this to kv4lsetup:
>
>#ifdef __STRICT_ANSI__
>#undef __STRICT_ANSI__
>#define FOO__STRICT_ANSI__
>#endif
>#include <asm/types.h>
>#ifdef FOO__STRICT_ANSI__
>#define __STRICT_ANSI__ 1
>#undef FOO__STRICT_ANSI__
>#endif
>
>It's ugly/nasty/etc.  It can't stay there.  I really don't want to add =
this to=20
>all the other files that include v4l include files.  Does anyone know of=
 a=20
>good solution to this other than contacting the v4l authors and asking =
for a=20
>patch to remove the dependency?

Do you mean the v4l plugin for qtvision or the actual v4l module?

The truth is, the STRICT_ANSI blocks in <asm/types.h> header file look
legitimate.  They are blocking out typedefs relating to data sizes,
32bit, 64bit signed and unsigned data.  ANSI doesn't like that.

Qtvision is so tied with hardware issues that I'm wondering why it
runs strict ANSI in the first place.  Wouldn't it be better to just
dump the "-ansi" flag entirely?