Hi

Using ivtv-2836 I've added:

#include <linux/version.h>
#include <linux/utsname.h>

in ivtvctl.c before videodev2.h and it still will not build, there are a huge 
number of errors, so for ease of readability I have attached it as a file

Has anyone managed to build the latest version?  If so, I would be gratefully 
for any guidance.

Trev

On Wednesday 19 Oct 2005 10:34, Mauro Carvalho Chehab wrote:
> Tyler,
>
>       We've separated V4L2 from V4L1. This way, videodev.h have now only V4L1
> stuff. Common stuff for both APIs are at V4L2. This is a first step for
> making V4L1 obsoleted. There are some tests at videodev.h (and now also
> on videodev2.h) to check about kernel version, in CVS. These tests are
> removed by script when we prepare the kernel patchsets. For these tests
> it is need these two include files, before including videodev2.h:
>
> #include <linux/version.h>
> #include <linux/utsname.h>
>
>       On CVS version, this is done by compat.h, where we also handle other
> compat issues.
>
>       To make ivtv compile again, the better way is to include "compat.h"
> before including other V4L CVS headers.
>       If you include version.h on ivtv, it will work, but after migrating it
> to kernel it would produce a bad side efect that the module will be
> recompiled for every minor change on kernel number (for every new -git
> numer, version is touched).
>
cc -I../v4l-kernel/linux/include -I../driver -D_GNU_SOURCE -O2 -Wall   -c -o 
ivtvctl.o ivtvctl.c
In file included from /usr/include/linux/device.h:17,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/list.h:685:2: warning: #warning "don't include kernel 
headers in userspace"
In file included from /usr/include/linux/timex.h:186,
                 from /usr/include/linux/sched.h:10,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/time.h:9: error: redefinition of `struct timespec'
/usr/include/linux/time.h:15: error: redefinition of `struct timeval'
/usr/include/linux/time.h:20: error: redefinition of `struct timezone'
/usr/include/linux/time.h:387: error: redefinition of `struct itimerval'
In file included from /usr/include/linux/sched.h:11,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/jiffies.h:16: error: syntax error before "jiffies_64"
/usr/include/linux/jiffies.h:20: error: syntax error before "get_jiffies_64"
In file included from /usr/include/linux/sched.h:14,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/cpumask.h:80: error: syntax error before "DECLARE_BITMAP"
/usr/include/linux/cpumask.h:81: error: syntax error before 
"_unused_cpumask_arg_"
/usr/include/linux/cpumask.h:84: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpu_set':
/usr/include/linux/cpumask.h:86: error: `cpu' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:86: error: (Each undeclared identifier is reported 
only once
/usr/include/linux/cpumask.h:86: error: for each function it appears in.)
/usr/include/linux/cpumask.h:86: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:90: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpu_clear':
/usr/include/linux/cpumask.h:92: error: `cpu' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:92: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:96: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_setall':
/usr/include/linux/cpumask.h:98: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:98: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:102: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_clear':
/usr/include/linux/cpumask.h:104: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:104: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:111: error: syntax error before "cpumask_t"
/usr/include/linux/cpumask.h: In function `__cpu_test_and_set':
/usr/include/linux/cpumask.h:113: error: `cpu' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:113: error: `addr' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:117: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_and':
/usr/include/linux/cpumask.h:120: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:120: error: `src1p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:120: error: `src2p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:120: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:124: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_or':
/usr/include/linux/cpumask.h:127: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:127: error: `src1p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:127: error: `src2p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:127: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:131: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_xor':
/usr/include/linux/cpumask.h:134: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:134: error: `src1p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:134: error: `src2p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:134: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:139: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_andnot':
/usr/include/linux/cpumask.h:142: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:142: error: `src1p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:142: error: `src2p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:142: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:146: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_complement':
/usr/include/linux/cpumask.h:149: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:149: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:149: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:153: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_equal':
/usr/include/linux/cpumask.h:156: error: `src1p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:156: error: `src2p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:156: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:160: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_intersects':
/usr/include/linux/cpumask.h:163: error: `src1p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:163: error: `src2p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:163: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:167: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_subset':
/usr/include/linux/cpumask.h:170: error: `src1p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:170: error: `src2p' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:170: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:174: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_empty':
/usr/include/linux/cpumask.h:176: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:176: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:180: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_full':
/usr/include/linux/cpumask.h:182: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:182: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:186: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_weight':
/usr/include/linux/cpumask.h:188: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:188: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:193: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_shift_right':
/usr/include/linux/cpumask.h:196: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:196: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:196: error: `n' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:196: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:201: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpus_shift_left':
/usr/include/linux/cpumask.h:204: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:204: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:204: error: `n' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:204: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:208: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__first_cpu':
/usr/include/linux/cpumask.h:210: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:210: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:214: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__next_cpu':
/usr/include/linux/cpumask.h:216: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:216: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:216: error: `n' undeclared (first use in this 
function)
In file included from /usr/include/linux/sched.h:14,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/cpumask.h:233:5: missing binary operator before token "("
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:265: error: syntax error before '*' token
/usr/include/linux/cpumask.h: In function `__cpumask_scnprintf':
/usr/include/linux/cpumask.h:267: error: `buf' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:267: error: `len' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:267: error: `srcp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:267: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:273: error: syntax error before "cpumask_t"
/usr/include/linux/cpumask.h: In function `__cpumask_parse':
/usr/include/linux/cpumask.h:275: error: `buf' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:275: error: `len' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:275: error: `dstp' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:275: error: `nbits' undeclared (first use in this 
function)
/usr/include/linux/cpumask.h:278:5: missing binary operator before token "("
/usr/include/linux/cpumask.h: At top level:
/usr/include/linux/cpumask.h:343: error: syntax error before "cpu_possible_map"
/usr/include/linux/cpumask.h:344: error: syntax error before "cpu_online_map"
/usr/include/linux/cpumask.h:345: error: syntax error before "cpu_present_map"
/usr/include/linux/cpumask.h:347:5: missing binary operator before token "("
In file included from /usr/include/linux/sched.h:20,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/asm/mmu.h:13: error: field `sem' has incomplete type
In file included from /usr/include/linux/signal.h:6,
                 from /usr/include/linux/sched.h:24,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/asm/signal.h:30: error: conflicting types for 'sigset_t'
/usr/include/sys/select.h:38: error: previous declaration of 'sigset_t' was here
In file included from /usr/include/linux/sched.h:26,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/fs_struct.h:9: error: syntax error before "rwlock_t"
/usr/include/linux/fs_struct.h:10: error: 'umask' redeclared as different kind 
of symbol
/usr/include/sys/stat.h:272: error: previous declaration of 'umask' was here
/usr/include/linux/fs_struct.h:10: error: 'umask' redeclared as different kind 
of symbol
/usr/include/sys/stat.h:272: error: previous declaration of 'umask' was here
/usr/include/linux/fs_struct.h:13: error: syntax error before '}' token
In file included from /usr/include/linux/sched.h:28,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/completion.h:15: error: syntax error before 
"wait_queue_head_t"
/usr/include/linux/completion.h: In function `init_completion':
/usr/include/linux/completion.h:26: error: dereferencing pointer to incomplete 
type
/usr/include/linux/completion.h:27: error: dereferencing pointer to incomplete 
type
In file included from /usr/include/linux/sched.h:29,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/pid.h: At top level:
/usr/include/linux/pid.h:18: error: field `task_list' has incomplete type
/usr/include/linux/pid.h:19: error: field `hash_chain' has incomplete type
/usr/include/linux/pid.h:24: error: field `pid_chain' has incomplete type
In file included from /usr/include/linux/sched.h:30,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/percpu.h: In function `__alloc_percpu':
/usr/include/linux/percpu.h:45: error: `GFP_KERNEL' undeclared (first use in 
this function)
In file included from /usr/include/linux/sched.h:101,
                 from /usr/include/linux/module.h:9,
                 from /usr/include/linux/device.h:20,
                 from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/timer.h: At top level:
/usr/include/linux/timer.h:11: error: field `entry' has incomplete type
In file included from ../v4l-kernel/linux/include/linux/videodev2.h:26,
                 from ivtvctl.c:42:
/usr/include/linux/device.h:53: error: field `subsys' has incomplete type
/usr/include/linux/device.h:54: error: field `drivers' has incomplete type
/usr/include/linux/device.h:55: error: field `devices' has incomplete type
/usr/include/linux/device.h:65: error: syntax error before "u32"
/usr/include/linux/device.h:91: error: field `attr' has incomplete type
/usr/include/linux/device.h:106: error: field `unload_sem' has incomplete type
/usr/include/linux/device.h:107: error: field `kobj' has incomplete type
/usr/include/linux/device.h:108: error: field `devices' has incomplete type
/usr/include/linux/device.h:113: error: syntax error before "u32"
/usr/include/linux/device.h:114: error: syntax error before "u32"
/usr/include/linux/device.h:129: error: field `attr' has incomplete type
/usr/include/linux/device.h:147: error: field `subsys' has incomplete type
/usr/include/linux/device.h:148: error: field `children' has incomplete type
/usr/include/linux/device.h:149: error: field `interfaces' has incomplete type
/usr/include/linux/device.h:169: error: field `attr' has incomplete type
/usr/include/linux/device.h:182: error: field `node' has incomplete type
/usr/include/linux/device.h:184: error: field `kobj' has incomplete type
/usr/include/linux/device.h:189: error: `KOBJ_NAME_LEN' undeclared here (not in 
a function)
/usr/include/linux/device.h:217: error: field `attr' has incomplete type
/usr/include/linux/device.h:233: error: field `node' has incomplete type
/usr/include/linux/device.h:254: error: field `node' has incomplete type
/usr/include/linux/device.h:255: error: field `bus_list' has incomplete type
/usr/include/linux/device.h:256: error: field `driver_list' has incomplete type
/usr/include/linux/device.h:257: error: field `children' has incomplete type
/usr/include/linux/device.h:260: error: field `kobj' has incomplete type
/usr/include/linux/device.h:269: error: field `power' has incomplete type
/usr/include/linux/device.h:270: error: syntax error before "u32"
/usr/include/linux/device.h:276: error: syntax error before "detach_state"
/usr/include/linux/device.h:279: error: syntax error before '*' token
/usr/include/linux/device.h:280: error: syntax error before "coherent_dma_mask"
/usr/include/linux/device.h:289: error: syntax error before '}' token
/usr/include/linux/device.h: In function `list_to_dev':
/usr/include/linux/device.h:294: error: syntax error before "struct"
/usr/include/linux/device.h: In function `dev_get_drvdata':
/usr/include/linux/device.h:300: error: dereferencing pointer to incomplete type
/usr/include/linux/device.h: In function `dev_set_drvdata':
/usr/include/linux/device.h:306: error: dereferencing pointer to incomplete type
/usr/include/linux/device.h: At top level:
/usr/include/linux/device.h:332: error: field `attr' has incomplete type
/usr/include/linux/device.h:368: error: syntax error before "u32"
/usr/include/linux/device.h:370: error: syntax error before "num_resources"
/usr/include/linux/device.h:372: error: syntax error before '}' token
In file included from ivtvctl.c:42:
../v4l-kernel/linux/include/linux/videodev2.h:83: error: field `lock' has 
incomplete type
../v4l-kernel/linux/include/linux/videodev2.h:116: warning: "struct file" 
declared inside parameter list
../v4l-kernel/linux/include/linux/videodev2.h:116: warning: "struct inode" 
declared inside parameter list
/usr/include/linux/device.h:286: error: storage size of `dma_pools' isn't known
/usr/include/linux/device.h:369: error: storage size of `dev' isn't known
make[1]: *** [ivtvctl.o] Error 1
make[1]: Leaving directory `/home/mythtv/ivtv-2836/utils'
make: *** [all] Error 2

_______________________________________________
ivtv-devel mailing list
[email protected]
http://ivtvdriver.org/mailman/listinfo/ivtv-devel

Reply via email to