Re: Kconfig troubles when using menuconfig - Was: [patch]Re: linux-2.6.22-rc5-gf1518a0 build #300 failed in zc0301_core.c

"Andreas Herrmann" <[email protected]>
Newsgroups gmane.linux.usb.devel,gmane.comp.video.video4linux,gmane.linux.kernel
Message-ID <[email protected]>
On Fri, Jun 22, 2007 at 10:22:46AM -0300, Mauro Carvalho Chehab wrote:
> Hi Roman,
> 
> Several instabilities on Kconfig started to happen after replacing
> Kconfig menus to use menuconfig, as this one, reported by Oliver:
> 
> Em Qui, 2007-06-21 às 13:50 +0200, Oliver Neukum escreveu:
> > Am Donnerstag, 21. Juni 2007 schrieb Toralf Förster:
> > > Right, but IMHO this issue is typical for a problem with the Kconfig definitions of this module.
> > > 
> > > I'll set USB devs as Cc: therefore.
> > 
> > The Kconfig there is incomplete.
> > Mauro, please apply.
> > 
> > 	Regards
> > 		Oliver
> > Signed-off-by: Oliver Neukum <[email protected]>
> >
> > --- a/drivers/media/video/zc0301/Kconfig        2007-06-21 13:44:14.000000000 +0200
> > +++ b/drivers/media/video/zc0301/Kconfig        2007-06-21 13:44:33.000000000 +0200
> > @@ -1,6 +1,6 @@
> >  config USB_ZC0301
> >         tristate "USB ZC0301[P] Image Processor and Control Chip support"
> > -       depends on VIDEO_V4L1
> > +       depends on VIDEO_V4L1 && USB
> >         ---help---
> >           Say Y here if you want support for cameras based on the ZC0301 or
> >           ZC0301P Image Processors and Control Chips.
> > 
> 
> In this specific case, all V4L USB drivers depends on V4L_USB_DRIVERS,
> that depends, in turn, on USB. So, if USB is not selected,
> V4L_USB_DRIVERS should be unselected, unselecting zc0301.
> 
> Unfortunately, the Kernel building system is not properly handling it.
> 
> This is the (snipped) media/video/Kconfig:
> 
> menuconfig V4L_USB_DRIVERS
>         bool "V4L USB devices"
>         depends on USB
>         default y
> 
> if V4L_USB_DRIVERS
> 
> source "drivers/media/video/pvrusb2/Kconfig"
> 
> <snip/>
> 
> source "drivers/media/video/zc0301/Kconfig"
> 
> <snip/>
> 
> endif # V4L_USB_DRIVERS
> 
> -- 
> Cheers,
> Mauro
> 


Hi,

I am not sure whether it is related or not
But if you select USB as module but build your v4l_usb driver
into the kernel you also get compile errors.
Attached is a patch which will prevent this by changing the menuconfig
from bool to tristate.


Regards,

Andreas

--
Correct Kconfig to avoid compile errors like
    
 drivers/built-in.o: In function `sn9c102_usb_disconnect':
 sn9c102_core.c:(.text+0x8d840): undefined reference to `usb_get_dev'
    
Signed-off-by: Andreas Herrmann <[email protected]>

diff --git a/drivers/media/video/Kconfig b/drivers/media/video/Kconfig
index 4cca551..4754d98 100644
--- a/drivers/media/video/Kconfig
+++ b/drivers/media/video/Kconfig
@@ -687,7 +687,7 @@ config VIDEO_CAFE_CCIC
 #
 
 menuconfig V4L_USB_DRIVERS
-	bool "V4L USB devices"
+	tristate "V4L USB devices"
 	depends on USB
 	default y
 




-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.