Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Solved] stk11xx compile problem with 2.6.24 kernel
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
jasn
Guru
Guru


Joined: 05 May 2005
Posts: 439
Location: Maryland, US

PostPosted: Sun Jan 27, 2008 9:37 pm    Post subject: [Solved] stk11xx compile problem with 2.6.24 kernel Reply with quote

I just updated my kernel to gentoo-sources-2.6.24 and am having problems recompiling my stk11xx syntek webcam driver, which was compiling and working fine under 2.6.23-r5. If I use the ebuild in bugzilla, or the svn ebuild, posted in a thread here, I am having the same compile error;
Code:
>>> Emerging (1 of 1) media-video/stk11xx-9999 to /
 * checking ebuild checksums ;-) ...                                                                                          [ ok ]
 * checking auxfile checksums ;-) ...                                                                                         [ ok ]
 * checking miscfile checksums ;-) ...                                                                                        [ ok ]
 * Determining the location of the kernel source code
 * Found kernel source directory:
 *     /usr/src/linux
 * Found kernel object directory:
 *     /lib/modules/2.6.24-gentoo/build
 * Found sources for kernel version:
 *     2.6.24-gentoo
 * Checking for suitable kernel configuration options...                                                                      [ ok ]
>>> Unpacking source...
 * subversion update start -->
 *      repository: https://syntekdriver.svn.sourceforge.net/svnroot/syntekdriver/trunk/driver
At revision 71.
 *    working copy: /usr/portage/distfiles/svn-src/stk11xx/driver

>>> Source unpacked.
>>> Compiling source in /var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999 ...
 * Preparing stk11xx module
make: Entering directory `/usr/src/linux-2.6.24-gentoo'
  LD      /var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/built-in.o
  CC [M]  /var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-usb.o
  CC [M]  /var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-v4l.o
  CC [M]  /var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.o
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-v4l.c: In function 'v4l_stk11xx_register_video_device':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-v4l.c:1659: error: 'struct video_device' has no member named 'hardware'
make[1]: *** [/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-v4l.o] Error 1
make[1]: *** Waiting for unfinished jobs....
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_release':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:63: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_videostatus':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:81: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_informations':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:108: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_fps':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:201: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_brightness':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:219: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'store_brightness':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:240: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_contrast':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:263: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'store_contrast':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:284: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_whitebalance':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:308: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'store_whitebalance':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:329: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_colour':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:353: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'store_colour':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:374: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_hflip':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:398: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'store_hflip':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:416: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'show_vflip':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:441: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'store_vflip':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:459: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'runtest':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:480: warning: initialization from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'stk11xx_create_sysfs_files':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:533: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:534: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:535: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:536: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:537: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:538: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:539: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:540: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:541: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:542: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:543: warning: passing argument 2 of 'video_device_create_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c: In function 'stk11xx_remove_sysfs_files':
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:560: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:561: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:562: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:563: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:564: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:565: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:566: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:567: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:568: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:569: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999/stk11xx-sysfs.c:570: warning: passing argument 2 of 'video_device_remove_file' from incompatible pointer type
make: *** [_module_/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999] Error 2
make: Leaving directory `/usr/src/linux-2.6.24-gentoo'
 *
 * ERROR: media-video/stk11xx-9999 failed.
 * Call stack:
 *               ebuild.sh, line   46:  Called src_compile
 *             environment, line 3109:  Called linux-mod_src_compile
 *             environment, line 2388:  Called die
 * The specific snippet of code:
 *               emake HOSTCC="$(tc-getBUILD_CC)" CC="$(get-KERNEL_CC)" LDFLAGS="$(get_abi_LDFLAGS)" ${BUILD_FIXES} ${BUILD_PARAMS} ${BUILD_TARGETS} || diefunc "$FUNCNAME" "$LINENO" "$?" "Unable to make ${BUILD_FIXES} ${BUILD_PARAMS} ${BUILD_TARGETS}.";
 *  The die message:
 *   Unable to make  -C /usr/src/linux SUBDIRS=/var/tmp/portage/media-video/stk11xx-9999/work/stk11xx-9999  .

Thanks.


Last edited by jasn on Mon Feb 04, 2008 4:03 pm; edited 1 time in total
Back to top
View user's profile Send private message
kfiaciarka
Veteran
Veteran


Joined: 20 May 2005
Posts: 1498
Location: Dobre Miasto, Poland

PostPosted: Thu Jan 31, 2008 11:53 am    Post subject: Reply with quote

same here, even from their svn :/
Back to top
View user's profile Send private message
jasn
Guru
Guru


Joined: 05 May 2005
Posts: 439
Location: Maryland, US

PostPosted: Sat Feb 02, 2008 9:26 pm    Post subject: Reply with quote

OK.. I kind of figured based on this post in a thread over at the sourceforge forum for the syntekdriver, that since the unused .hardware V4L1 field was removed in the v4l core, that it would likely require a simple change in the driver code to compile correctly. This post suggests it's as simple as commenting out line 1659 in stk11xx-v4l.c.

So truly being the noob I am, would someone have a spare moment to walk me through creating a patch to apply in the ebuild process so that the one offending line in the source code file be commented out at ebuild time? I tried doing a simple;
Code:
diff -up stk11xx-1.2.3/stk11xx-v4l.c stk11xx-1.2.3-r2/stk11xx-v4l.c > stk11xx-1.2.3_vid_dev.patch

Which creates a patch file that I edited to the following;
Code:
--- stk11xx-v4l.c       2007-12-07 04:20:29.000000000 -0500
+++ stk11xx-v4l.c       2008-02-02 13:47:53.732226263 -0500
@@ -1656,7 +1656,7 @@ int v4l_stk11xx_register_video_device(st
        dev->vdev->dev = &dev->interface->dev;
        dev->vdev->owner = THIS_MODULE;
        dev->vdev->type = VID_TYPE_CAPTURE;
-       dev->vdev->hardware = VID_HARDWARE_STK11XX;
+//     dev->vdev->hardware = VID_HARDWARE_STK11XX;
        dev->vdev->fops = &v4l_stk11xx_fops;
        dev->vdev->release = video_device_release;
        dev->vdev->minor = -1;

But trying to apply the patch in my ebuild fails with the following output;
Code:
can't find file to patch at input line 3
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|--- stk11xx-v4l.c   2007-12-07 04:20:29.000000000 -0500
|+++ stk11xx-v4l.c   2008-02-02 13:47:53.732226263 -0500
--------------------------
No file to patch.  Skipping patch.
1 out of 1 hunk ignored

If you want to ignore all that silliness that I did, maybe you can just walk me through the simplest way to create a patch to stk11xx-v4l.c, to comment out line 1659, that can be applied during the Gentoo ebuild process, for this driver.

Thanks
Back to top
View user's profile Send private message
hirakendu
Guru
Guru


Joined: 24 Jan 2007
Posts: 386
Location: san diego

PostPosted: Sat Feb 02, 2008 9:59 pm    Post subject: Reply with quote

You can break an emerge into individual steps. Here is an example :
Code:
cd  /usr/portage/sys-boot/elilo/
ebuild /usr/portage/sys-boot/elilo/elilo-3.6_p20060314.ebuild digest
ebuild /usr/portage/sys-boot/elilo/elilo-3.6_p20060314.ebuild unpack
ebuild /usr/portage/sys-boot/elilo/elilo-3.6_p20060314.ebuild compile
ebuild /usr/portage/sys-boot/elilo/elilo-3.6_p20060314.ebuild install
ebuild /usr/portage/sys-boot/elilo/elilo-3.6_p20060314.ebuild qmerge

After the unpack step and before the compile step, you can edit the source code in /var/tmp/portage/ (look for work/ folder).
_________________
Helium Sources || Gentoo Minimal Livecd
Back to top
View user's profile Send private message
jasn
Guru
Guru


Joined: 05 May 2005
Posts: 439
Location: Maryland, US

PostPosted: Mon Feb 04, 2008 4:02 pm    Post subject: Reply with quote

Until someone more knowledgeable than I suggests an ebuild patch mentioned above to comment out the one line of the source code, OR until the Syntekdriver team over at sourceforge update their code to work with 2.6.24, the temporary solution is to simply comment out line 1659 in stk11xx-v4l.c. I got it compile for me by placing 2 slashes in front of the line as follows;

// dev->vdev->hrdware = VID_HARDWARE_STK11XX

You are free to pause the ebuild process as mentioned in hirakendu's post above, patch the source file, and complete the Gentoo compile and install, or to do it all manually. I used the manual ebuild process successfully. I'll mark this issue solved, as it looks like the problem with the compile has been identified, even if no clean Gentoo solution is available right now.
Back to top
View user's profile Send private message
jasn
Guru
Guru


Joined: 05 May 2005
Posts: 439
Location: Maryland, US

PostPosted: Tue Feb 05, 2008 12:45 pm    Post subject: Reply with quote

Much better solution has appeared now that the developers have updated the driver code. No longer necessary to provide a patch for the ebuild process. Using the svn ebuild, if you build from svn sources that are at least revision 72 or later, this problem has been fixed. If you would prefer to use the ebuild from bugzilla, there's one for version 1.3.1 of the driver, which also builds fine in 2.6.24.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum