Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
@ 2017-12-29 13:06 Dagg Stompler
  2017-12-29 13:40 ` Thomas Petazzoni
  2017-12-29 13:55 ` Yann E. MORIN
  0 siblings, 2 replies; 8+ messages in thread
From: Dagg Stompler @ 2017-12-29 13:06 UTC (permalink / raw)
  To: buildroot

BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV is needed for tvheadend inorder
for the program to see usb based DVB cards.

Signed-off-by: Dagg Stompler <daggs@gmx.com>
---
 package/tvheadend/Config.in | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/tvheadend/Config.in b/package/tvheadend/Config.in
index 44a69a27ba..2a497b481d 100644
--- a/package/tvheadend/Config.in
+++ b/package/tvheadend/Config.in
@@ -9,6 +9,7 @@ config BR2_PACKAGE_TVHEADEND
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
 	depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_2
 	depends on BR2_TOOLCHAIN_HAS_SYNC_4
+	depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV
 	select BR2_PACKAGE_DTV_SCAN_TABLES
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	select BR2_PACKAGE_OPENSSL
-- 
2.15.1

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
  2017-12-29 13:06 [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation Dagg Stompler
@ 2017-12-29 13:40 ` Thomas Petazzoni
  2017-12-29 13:57   ` daggs
  2017-12-29 13:55 ` Yann E. MORIN
  1 sibling, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2017-12-29 13:40 UTC (permalink / raw)
  To: buildroot

Hello,

On Fri, 29 Dec 2017 15:06:04 +0200, Dagg Stompler wrote:
> BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV is needed for tvheadend inorder
> for the program to see usb based DVB cards.
> 
> Signed-off-by: Dagg Stompler <daggs@gmx.com>
> ---
>  package/tvheadend/Config.in | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/package/tvheadend/Config.in b/package/tvheadend/Config.in
> index 44a69a27ba..2a497b481d 100644
> --- a/package/tvheadend/Config.in
> +++ b/package/tvheadend/Config.in
> @@ -9,6 +9,7 @@ config BR2_PACKAGE_TVHEADEND
>  	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
>  	depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_2
>  	depends on BR2_TOOLCHAIN_HAS_SYNC_4
> +	depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV

You should use BR2_PACKAGE_HAS_UDEV instead. Indeed udev can be
provided by either eudev or systemd.

This change will also require a change in the Config.in comment. See
package/dt-utils/Config.in for an example.

Also, does tvheadend needs to link with libudev ? If so, it should have
udev in its <pkg>_DEPENDENCIES. If it doesn't link with libudev, then
I'm not sure to see how udev helps for tvheadend to detect USB DVB
cards.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
  2017-12-29 13:06 [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation Dagg Stompler
  2017-12-29 13:40 ` Thomas Petazzoni
@ 2017-12-29 13:55 ` Yann E. MORIN
  2017-12-29 14:02   ` daggs
  1 sibling, 1 reply; 8+ messages in thread
From: Yann E. MORIN @ 2017-12-29 13:55 UTC (permalink / raw)
  To: buildroot

Dagg, All,

On 2017-12-29 15:06 +0200, Dagg Stompler spake thusly:
> BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV is needed for tvheadend inorder
> for the program to see usb based DVB cards.

But is it required for other types of cards, like PCI ones?

And what about systems using mdev instead? I've had a system sithout
udev at all, and tvheadend was working perfectly fine for me.

Basically, I don't think we want to add this dependency at all, because
it is not required in my experience.

Regards,
Yann E. MORIN.

> Signed-off-by: Dagg Stompler <daggs@gmx.com>
> ---
>  package/tvheadend/Config.in | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/package/tvheadend/Config.in b/package/tvheadend/Config.in
> index 44a69a27ba..2a497b481d 100644
> --- a/package/tvheadend/Config.in
> +++ b/package/tvheadend/Config.in
> @@ -9,6 +9,7 @@ config BR2_PACKAGE_TVHEADEND
>  	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
>  	depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_2
>  	depends on BR2_TOOLCHAIN_HAS_SYNC_4
> +	depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV
>  	select BR2_PACKAGE_DTV_SCAN_TABLES
>  	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
>  	select BR2_PACKAGE_OPENSSL
> -- 
> 2.15.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
  2017-12-29 13:40 ` Thomas Petazzoni
@ 2017-12-29 13:57   ` daggs
  2017-12-29 14:03     ` Thomas Petazzoni
  0 siblings, 1 reply; 8+ messages in thread
From: daggs @ 2017-12-29 13:57 UTC (permalink / raw)
  To: buildroot

Greetings Thomas,

> Sent: Friday, December 29, 2017 at 3:40 PM
> From: "Thomas Petazzoni" <thomas.petazzoni@free-electrons.com>
> To: "Dagg Stompler" <daggs@gmx.com>
> Cc: buildroot at buildroot.org
> Subject: Re: [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
>
> Hello,
> 
> On Fri, 29 Dec 2017 15:06:04 +0200, Dagg Stompler wrote:
> > BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV is needed for tvheadend inorder
> > for the program to see usb based DVB cards.
> > 
> > Signed-off-by: Dagg Stompler <daggs@gmx.com>
> > ---
> >  package/tvheadend/Config.in | 1 +
> >  1 file changed, 1 insertion(+)
> > 
> > diff --git a/package/tvheadend/Config.in b/package/tvheadend/Config.in
> > index 44a69a27ba..2a497b481d 100644
> > --- a/package/tvheadend/Config.in
> > +++ b/package/tvheadend/Config.in
> > @@ -9,6 +9,7 @@ config BR2_PACKAGE_TVHEADEND
> >  	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
> >  	depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_2
> >  	depends on BR2_TOOLCHAIN_HAS_SYNC_4
> > +	depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV
> 
> You should use BR2_PACKAGE_HAS_UDEV instead. Indeed udev can be
> provided by either eudev or systemd.
does using BR2_PACKAGE_HAS_UDEV means rootfs dev creation will use udev?

> 
> This change will also require a change in the Config.in comment. See
> package/dt-utils/Config.in for an example.
will look into it.

> 
> Also, does tvheadend needs to link with libudev ? If so, it should have
> udev in its <pkg>_DEPENDENCIES. If it doesn't link with libudev, then
> I'm not sure to see how udev helps for tvheadend to detect USB DVB
> cards.
it doesn't, frankly I don't understand it too, I'm wrestling this for 3 weeks now, without udev, tvheadend didn't listed my adapter in the webui.
on the desktop it did, after some thinking I've decided to try building udev and it worked.
maybe Bernd might have some ideas on the matter. 

Dagg.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
  2017-12-29 13:55 ` Yann E. MORIN
@ 2017-12-29 14:02   ` daggs
  0 siblings, 0 replies; 8+ messages in thread
From: daggs @ 2017-12-29 14:02 UTC (permalink / raw)
  To: buildroot

Greetings Yann.

> Sent: Friday, December 29, 2017 at 3:55 PM
> From: "Yann E. MORIN" <yann.morin.1998@free.fr>
> To: "Dagg Stompler" <daggs@gmx.com>
> Cc: buildroot at buildroot.org
> Subject: Re: [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
>
> Dagg, All,
> 
> On 2017-12-29 15:06 +0200, Dagg Stompler spake thusly:
> > BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV is needed for tvheadend inorder
> > for the program to see usb based DVB cards.
> 
> But is it required for other types of cards, like PCI ones?
I don't know, I have an usb adapter on hand, not pci one.

> 
> And what about systems using mdev instead? I've had a system sithout
> udev at all, and tvheadend was working perfectly fine for me.
tried mdev, didn't worked.

> 
> Basically, I don't think we want to add this dependency at all, because
> it is not required in my experience.
without that feature, I'm unable to use tvheadend, maybe it is needed only for usb adapters.
maybe it is a new feature, also, I won't be surprised if it is needed but not checked if the devs take into account that all distros use some from of udev.
I've asked at the tvheadend irc channel but no answer yet.

Dagg.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
  2017-12-29 13:57   ` daggs
@ 2017-12-29 14:03     ` Thomas Petazzoni
  2017-12-29 14:27       ` daggs
  0 siblings, 1 reply; 8+ messages in thread
From: Thomas Petazzoni @ 2017-12-29 14:03 UTC (permalink / raw)
  To: buildroot

Hello,

On Fri, 29 Dec 2017 14:57:59 +0100, daggs wrote:

> > You should use BR2_PACKAGE_HAS_UDEV instead. Indeed udev can be
> > provided by either eudev or systemd.  
> does using BR2_PACKAGE_HAS_UDEV means rootfs dev creation will use udev?

config BR2_PACKAGE_EUDEV
        bool "eudev"
        depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV
        depends on BR2_USE_MMU # uses fork()
        depends on BR2_USE_WCHAR # needs C99 compiler
        depends on !BR2_STATIC_LIBS # kmod
        select BR2_PACKAGE_HAS_UDEV

So for the eudev case, BR2_PACKAGE_HAS_UDEV is selected when eudev is
enabled, and eudev can only be enabled when
BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV is enabled.

For the systemd case:

menuconfig BR2_PACKAGE_SYSTEMD
        bool "systemd"
        depends on BR2_INIT_SYSTEMD
        depends on !BR2_STATIC_LIBS # kmod
        depends on BR2_TOOLCHAIN_HAS_THREADS # dbus
        depends on BR2_USE_MMU # dbus
        select BR2_PACKAGE_HAS_UDEV

So BR2_PACKAGE_HAS_UDEV is selected when systemd is enabled, which is
only possible when systemd is the init system.

Bottom line: as soon as systemd is the init system *or* eudev is used
at the dev management method, you are guaranteed that
BR2_PACKAGE_HAS_UDEV=y.

> > Also, does tvheadend needs to link with libudev ? If so, it should have
> > udev in its <pkg>_DEPENDENCIES. If it doesn't link with libudev, then
> > I'm not sure to see how udev helps for tvheadend to detect USB DVB
> > cards.  
> it doesn't, frankly I don't understand it too, I'm wrestling this for 3 weeks now, without udev, tvheadend didn't listed my adapter in the webui.
> on the desktop it did, after some thinking I've decided to try building udev and it worked.
> maybe Bernd might have some ideas on the matter. 

This is a somewhat weak understanding of what's happening here. I think
we need a better understanding of what's going on rather than
more-or-less randomly adding a dependency.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
  2017-12-29 14:03     ` Thomas Petazzoni
@ 2017-12-29 14:27       ` daggs
  2017-12-30  6:48         ` daggs
  0 siblings, 1 reply; 8+ messages in thread
From: daggs @ 2017-12-29 14:27 UTC (permalink / raw)
  To: buildroot

Greetings Thomas,

> Sent: Friday, December 29, 2017 at 4:03 PM
> From: "Thomas Petazzoni" <thomas.petazzoni@free-electrons.com>
> To: daggs <daggs@gmx.com>
> Cc: buildroot at buildroot.org, "Bernd Kuhls" <bernd.kuhls@t-online.de>
> Subject: Re: [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
>
> Hello,
> 
> On Fri, 29 Dec 2017 14:57:59 +0100, daggs wrote:
> 
> > > You should use BR2_PACKAGE_HAS_UDEV instead. Indeed udev can be
> > > provided by either eudev or systemd.  
> > does using BR2_PACKAGE_HAS_UDEV means rootfs dev creation will use udev?
> 
> config BR2_PACKAGE_EUDEV
>         bool "eudev"
>         depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV
>         depends on BR2_USE_MMU # uses fork()
>         depends on BR2_USE_WCHAR # needs C99 compiler
>         depends on !BR2_STATIC_LIBS # kmod
>         select BR2_PACKAGE_HAS_UDEV
> 
> So for the eudev case, BR2_PACKAGE_HAS_UDEV is selected when eudev is
> enabled, and eudev can only be enabled when
> BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV is enabled.
> 
> For the systemd case:
> 
> menuconfig BR2_PACKAGE_SYSTEMD
>         bool "systemd"
>         depends on BR2_INIT_SYSTEMD
>         depends on !BR2_STATIC_LIBS # kmod
>         depends on BR2_TOOLCHAIN_HAS_THREADS # dbus
>         depends on BR2_USE_MMU # dbus
>         select BR2_PACKAGE_HAS_UDEV
> 
> So BR2_PACKAGE_HAS_UDEV is selected when systemd is enabled, which is
> only possible when systemd is the init system.
> 
> Bottom line: as soon as systemd is the init system *or* eudev is used
> at the dev management method, you are guaranteed that
> BR2_PACKAGE_HAS_UDEV=y.
ok, I'll look into it.

> 
> > > Also, does tvheadend needs to link with libudev ? If so, it should have
> > > udev in its <pkg>_DEPENDENCIES. If it doesn't link with libudev, then
> > > I'm not sure to see how udev helps for tvheadend to detect USB DVB
> > > cards.  
> > it doesn't, frankly I don't understand it too, I'm wrestling this for 3 weeks now, without udev, tvheadend didn't listed my adapter in the webui.
> > on the desktop it did, after some thinking I've decided to try building udev and it worked.
> > maybe Bernd might have some ideas on the matter. 
> 
> This is a somewhat weak understanding of what's happening here. I think
> we need a better understanding of what's going on rather than
> more-or-less randomly adding a dependency.
for that I need either time to look into the code or an answer from the devs, time I don't have unfortunately, devs aren't responding yet.
I encountered the issue and was able to get it to work, I assume that others might have seen it and didn't had time to look into it.
also as said, maybe Bernd knows what is the issue here and can propose a better fix.

Dagg.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
  2017-12-29 14:27       ` daggs
@ 2017-12-30  6:48         ` daggs
  0 siblings, 0 replies; 8+ messages in thread
From: daggs @ 2017-12-30  6:48 UTC (permalink / raw)
  To: buildroot

Greetings Thomas,

>
> Greetings Thomas,
> 
> > Sent: Friday, December 29, 2017 at 4:03 PM
> > From: "Thomas Petazzoni" <thomas.petazzoni@free-electrons.com>
> > To: daggs <daggs@gmx.com>
> > Cc: buildroot at buildroot.org, "Bernd Kuhls" <bernd.kuhls@t-online.de>
> > Subject: Re: [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation
> >
> > Hello,
> > 
> > On Fri, 29 Dec 2017 14:57:59 +0100, daggs wrote:
> > 
> > > > You should use BR2_PACKAGE_HAS_UDEV instead. Indeed udev can be
> > > > provided by either eudev or systemd.  
> > > does using BR2_PACKAGE_HAS_UDEV means rootfs dev creation will use udev?
> > 
> > config BR2_PACKAGE_EUDEV
> >         bool "eudev"
> >         depends on BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV
> >         depends on BR2_USE_MMU # uses fork()
> >         depends on BR2_USE_WCHAR # needs C99 compiler
> >         depends on !BR2_STATIC_LIBS # kmod
> >         select BR2_PACKAGE_HAS_UDEV
> > 
> > So for the eudev case, BR2_PACKAGE_HAS_UDEV is selected when eudev is
> > enabled, and eudev can only be enabled when
> > BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV is enabled.
> > 
> > For the systemd case:
> > 
> > menuconfig BR2_PACKAGE_SYSTEMD
> >         bool "systemd"
> >         depends on BR2_INIT_SYSTEMD
> >         depends on !BR2_STATIC_LIBS # kmod
> >         depends on BR2_TOOLCHAIN_HAS_THREADS # dbus
> >         depends on BR2_USE_MMU # dbus
> >         select BR2_PACKAGE_HAS_UDEV
> > 
> > So BR2_PACKAGE_HAS_UDEV is selected when systemd is enabled, which is
> > only possible when systemd is the init system.
> > 
> > Bottom line: as soon as systemd is the init system *or* eudev is used
> > at the dev management method, you are guaranteed that
> > BR2_PACKAGE_HAS_UDEV=y.
> ok, I'll look into it.
> 
> > 
> > > > Also, does tvheadend needs to link with libudev ? If so, it should have
> > > > udev in its <pkg>_DEPENDENCIES. If it doesn't link with libudev, then
> > > > I'm not sure to see how udev helps for tvheadend to detect USB DVB
> > > > cards.  
> > > it doesn't, frankly I don't understand it too, I'm wrestling this for 3 weeks now, without udev, tvheadend didn't listed my adapter in the webui.
> > > on the desktop it did, after some thinking I've decided to try building udev and it worked.
> > > maybe Bernd might have some ideas on the matter. 
> > 
> > This is a somewhat weak understanding of what's happening here. I think
> > we need a better understanding of what's going on rather than
> > more-or-less randomly adding a dependency.
> for that I need either time to look into the code or an answer from the devs, time I don't have unfortunately, devs aren't responding yet.
> I encountered the issue and was able to get it to work, I assume that others might have seen it and didn't had time to look into it.
> also as said, maybe Bernd knows what is the issue here and can propose a better fix.
> 
I did a quick search on the tvheadend repo for udev, one hit poped up: https://github.com/tvheadend/tvheadend/blob/master/debian/tvheadend.init
it seems that they do depend on udev when the boot system isn't systemd, am I correct?

Dagg.

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2017-12-30  6:48 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-29 13:06 [Buildroot] [PATCH] tvheadend: add dependency on udev based rootfs creation Dagg Stompler
2017-12-29 13:40 ` Thomas Petazzoni
2017-12-29 13:57   ` daggs
2017-12-29 14:03     ` Thomas Petazzoni
2017-12-29 14:27       ` daggs
2017-12-30  6:48         ` daggs
2017-12-29 13:55 ` Yann E. MORIN
2017-12-29 14:02   ` daggs

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox