[1/1] package/gstreamer1/gst1-plugins-bad: fix opengl dependency
diff mbox series

Message ID 20190807215804.100437-1-james.hilliard1@gmail.com
State New
Headers show
Series
  • [1/1] package/gstreamer1/gst1-plugins-bad: fix opengl dependency
Related show

Commit Message

James Hilliard Aug. 7, 2019, 9:58 p.m. UTC
Fixes:
WPEThreadedView.h:24:10: fatal error: gst/gl/gl.h: No such file or directory
 #include <gst/gl/gl.h>
          ^~~~~~~~~~~~~

Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
---
 package/gstreamer1/gst1-plugins-bad/Config.in | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Adrian Perez de Castro Aug. 7, 2019, 10:24 p.m. UTC | #1
Hi,

On Wed,  7 Aug 2019 15:58:04 -0600, James Hilliard <james.hilliard1@gmail.com> wrote:
> Fixes:
> WPEThreadedView.h:24:10: fatal error: gst/gl/gl.h: No such file or directory
>  #include <gst/gl/gl.h>
>           ^~~~~~~~~~~~~
> 
> Signed-off-by: James Hilliard <james.hilliard1@gmail.com>

Reviewed-by: Adrian Perez de Castro <aperez@igalia.com>

Thanks for the patch :)
—Adrián

> ---
>  package/gstreamer1/gst1-plugins-bad/Config.in | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/package/gstreamer1/gst1-plugins-bad/Config.in b/package/gstreamer1/gst1-plugins-bad/Config.in
> index f00f3edb7c..79acd83a63 100644
> --- a/package/gstreamer1/gst1-plugins-bad/Config.in
> +++ b/package/gstreamer1/gst1-plugins-bad/Config.in
> @@ -595,11 +595,11 @@ config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WPE
>  	bool "wpe"
>  	default y
>  	depends on BR2_PACKAGE_WPEWEBKIT
> -	depends on BR2_PACKAGE_GST1_PLUGINS_BASE_HAS_LIB_OPENGL
> +	depends on BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_OPENGL
>  
>  comment "wpe needs the gst1-plugins-base opengl library and wpewebkit"
>  	depends on !BR2_PACKAGE_WPEWEBKIT \
> -		|| !BR2_PACKAGE_GST1_PLUGINS_BASE_HAS_LIB_OPENGL
> +		|| !BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_OPENGL
>  
>  config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_X265
>  	bool "x265"
> -- 
> 2.20.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
Thomas Petazzoni Aug. 15, 2019, 10:02 p.m. UTC | #2
James, Adrian, Adam,

On Wed,  7 Aug 2019 15:58:04 -0600
James Hilliard <james.hilliard1@gmail.com> wrote:

> Fixes:
> WPEThreadedView.h:24:10: fatal error: gst/gl/gl.h: No such file or directory
>  #include <gst/gl/gl.h>
>           ^~~~~~~~~~~~~
> 
> Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
> ---
>  package/gstreamer1/gst1-plugins-bad/Config.in | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

I must say I'm a bit confused by the GStreamer OpenGL options, and this
particular patch. See below.

> diff --git a/package/gstreamer1/gst1-plugins-bad/Config.in b/package/gstreamer1/gst1-plugins-bad/Config.in
> index f00f3edb7c..79acd83a63 100644
> --- a/package/gstreamer1/gst1-plugins-bad/Config.in
> +++ b/package/gstreamer1/gst1-plugins-bad/Config.in
> @@ -595,11 +595,11 @@ config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WPE
>  	bool "wpe"
>  	default y
>  	depends on BR2_PACKAGE_WPEWEBKIT
> -	depends on BR2_PACKAGE_GST1_PLUGINS_BASE_HAS_LIB_OPENGL
> +	depends on BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_OPENGL

So with this patch in place, it is no longer possible to select the wpe
plugin if you have OpenGL ES, you really need full OpenGL, making the
WPE plugin unselectable on most embedded platforms, that often only
provide OpenGL ES, and not full OpenGL ? Is that really the case ?

Also, I'm confused by the semantic of
BR2_PACKAGE_GST1_PLUGINS_BASE_HAS_LIB_OPENGL. With this patch +
http://patchwork.ozlabs.org/patch/1143636/, it's essentially going to
be used in only one remaining place:
BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_GL. And it is exactly equal to
BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_HAS_WINDOW &&
BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL.

The naming is very confusing, and there are not many comments to
explain what's going on. Can we try to clarify all of this ?

Thanks,

Thomas
James Hilliard Aug. 15, 2019, 10:54 p.m. UTC | #3
On Thu, Aug 15, 2019 at 4:02 PM Thomas Petazzoni
<thomas.petazzoni@bootlin.com> wrote:
>
> James, Adrian, Adam,
>
> On Wed,  7 Aug 2019 15:58:04 -0600
> James Hilliard <james.hilliard1@gmail.com> wrote:
>
> > Fixes:
> > WPEThreadedView.h:24:10: fatal error: gst/gl/gl.h: No such file or directory
> >  #include <gst/gl/gl.h>
> >           ^~~~~~~~~~~~~
> >
> > Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
> > ---
> >  package/gstreamer1/gst1-plugins-bad/Config.in | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
>
> I must say I'm a bit confused by the GStreamer OpenGL options, and this
> particular patch. See below.
>
> > diff --git a/package/gstreamer1/gst1-plugins-bad/Config.in b/package/gstreamer1/gst1-plugins-bad/Config.in
> > index f00f3edb7c..79acd83a63 100644
> > --- a/package/gstreamer1/gst1-plugins-bad/Config.in
> > +++ b/package/gstreamer1/gst1-plugins-bad/Config.in
> > @@ -595,11 +595,11 @@ config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WPE
> >       bool "wpe"
> >       default y
> >       depends on BR2_PACKAGE_WPEWEBKIT
> > -     depends on BR2_PACKAGE_GST1_PLUGINS_BASE_HAS_LIB_OPENGL
> > +     depends on BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_OPENGL
>
> So with this patch in place, it is no longer possible to select the wpe
> plugin if you have OpenGL ES, you really need full OpenGL, making the
> WPE plugin unselectable on most embedded platforms, that often only
> provide OpenGL ES, and not full OpenGL ? Is that really the case ?
From my testing it was required, maybe there's some additional config options I
missed however.
>
> Also, I'm confused by the semantic of
> BR2_PACKAGE_GST1_PLUGINS_BASE_HAS_LIB_OPENGL. With this patch +
> http://patchwork.ozlabs.org/patch/1143636/, it's essentially going to
> be used in only one remaining place:
> BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_GL. And it is exactly equal to
> BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_HAS_WINDOW &&
> BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL.
>
> The naming is very confusing, and there are not many comments to
> explain what's going on. Can we try to clarify all of this ?
Yeah, I agree this is very confusing, this patch took me quite a bit
of testing to get
something that appears to be correct.
Not really sure myself what's up with the naming but a lot of stuff
got moved around here:
https://github.com/buildroot/buildroot/commit/3f2aef56127fbe71378e6a2d55192a0835d962ab
>
> Thanks,
>
> Thomas
> --
> Thomas Petazzoni, CTO, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com
Thomas Petazzoni Aug. 16, 2019, 12:31 p.m. UTC | #4
Hello James,

+Peter Seiderer

On Thu, 15 Aug 2019 16:54:56 -0600
James Hilliard <james.hilliard1@gmail.com> wrote:

> On Thu, Aug 15, 2019 at 4:02 PM Thomas Petazzoni
> <thomas.petazzoni@bootlin.com> wrote:
> >
> > James, Adrian, Adam,
> >
> > On Wed,  7 Aug 2019 15:58:04 -0600
> > James Hilliard <james.hilliard1@gmail.com> wrote:
> >  
> > > Fixes:
> > > WPEThreadedView.h:24:10: fatal error: gst/gl/gl.h: No such file or directory
> > >  #include <gst/gl/gl.h>

So, I just did a test with the following defconfig, which only has
OpenGL ES (provided by rpi-userland) and not the full OpenGL:

BR2_arm=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_CUSTOM=y
BR2_TOOLCHAIN_EXTERNAL_DOWNLOAD=y
BR2_TOOLCHAIN_EXTERNAL_URL="http://autobuild.buildroot.org/toolchains/tarballs/br-arm-full-2019.05.1.tar.bz2"
BR2_TOOLCHAIN_EXTERNAL_GCC_4_9=y
BR2_TOOLCHAIN_EXTERNAL_HEADERS_4_14=y
BR2_TOOLCHAIN_EXTERNAL_LOCALE=y
# BR2_TOOLCHAIN_EXTERNAL_HAS_THREADS_DEBUG is not set
BR2_TOOLCHAIN_EXTERNAL_CXX=y
BR2_INIT_NONE=y
BR2_SYSTEM_BIN_SH_NONE=y
# BR2_PACKAGE_BUSYBOX is not set
BR2_PACKAGE_GSTREAMER1=y
BR2_PACKAGE_GST1_PLUGINS_BASE=y
# BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_AUDIOCONVERT is not set
# BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_AUDIORESAMPLE is not set
# BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_VOLUME is not set
BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL=y
BR2_PACKAGE_RPI_USERLAND=y
# BR2_TARGET_ROOTFS_TAR is not set

And it does provide gst/gl/gl.h:

$ find . -name 'gl.h'
./output/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/include/GLES/gl.h

So, gst/gl/gl.h is provided when OpenGL ES is used, which means your
patch is most likely incorrect, and we should allow enabling the wpe
plugin when OpenGL ES is available.

Best regards,

Thomas
James Hilliard Aug. 16, 2019, 11:09 p.m. UTC | #5
On Fri, Aug 16, 2019 at 6:31 AM Thomas Petazzoni
<thomas.petazzoni@bootlin.com> wrote:
>
> Hello James,
>
> +Peter Seiderer
>
> On Thu, 15 Aug 2019 16:54:56 -0600
> James Hilliard <james.hilliard1@gmail.com> wrote:
>
> > On Thu, Aug 15, 2019 at 4:02 PM Thomas Petazzoni
> > <thomas.petazzoni@bootlin.com> wrote:
> > >
> > > James, Adrian, Adam,
> > >
> > > On Wed,  7 Aug 2019 15:58:04 -0600
> > > James Hilliard <james.hilliard1@gmail.com> wrote:
> > >
> > > > Fixes:
> > > > WPEThreadedView.h:24:10: fatal error: gst/gl/gl.h: No such file or directory
> > > >  #include <gst/gl/gl.h>
>
> So, I just did a test with the following defconfig, which only has
> OpenGL ES (provided by rpi-userland) and not the full OpenGL:
>
> BR2_arm=y
> BR2_TOOLCHAIN_EXTERNAL=y
> BR2_TOOLCHAIN_EXTERNAL_CUSTOM=y
> BR2_TOOLCHAIN_EXTERNAL_DOWNLOAD=y
> BR2_TOOLCHAIN_EXTERNAL_URL="http://autobuild.buildroot.org/toolchains/tarballs/br-arm-full-2019.05.1.tar.bz2"
> BR2_TOOLCHAIN_EXTERNAL_GCC_4_9=y
> BR2_TOOLCHAIN_EXTERNAL_HEADERS_4_14=y
> BR2_TOOLCHAIN_EXTERNAL_LOCALE=y
> # BR2_TOOLCHAIN_EXTERNAL_HAS_THREADS_DEBUG is not set
> BR2_TOOLCHAIN_EXTERNAL_CXX=y
> BR2_INIT_NONE=y
> BR2_SYSTEM_BIN_SH_NONE=y
> # BR2_PACKAGE_BUSYBOX is not set
> BR2_PACKAGE_GSTREAMER1=y
> BR2_PACKAGE_GST1_PLUGINS_BASE=y
> # BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_AUDIOCONVERT is not set
> # BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_AUDIORESAMPLE is not set
> # BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_VOLUME is not set
> BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL=y
> BR2_PACKAGE_RPI_USERLAND=y
> # BR2_TARGET_ROOTFS_TAR is not set
>
> And it does provide gst/gl/gl.h:
>
> $ find . -name 'gl.h'
> ./output/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/include/GLES/gl.h
That's different from this right?:
https://github.com/GStreamer/gst-plugins-base/blob/1.16.0/gst-libs/gst/gl/gl.h
>
> So, gst/gl/gl.h is provided when OpenGL ES is used, which means your
> patch is most likely incorrect, and we should allow enabling the wpe
> plugin when OpenGL ES is available.
I thought gst/gl/gl.h was provided by gst1-plugins-base not OpenGL ES right?
That should get built based on this and not OpenGL ES AFAICT:
BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_OPENGL
>
> Best regards,
>
> Thomas
> --
> Thomas Petazzoni, CTO, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com

Patch
diff mbox series

diff --git a/package/gstreamer1/gst1-plugins-bad/Config.in b/package/gstreamer1/gst1-plugins-bad/Config.in
index f00f3edb7c..79acd83a63 100644
--- a/package/gstreamer1/gst1-plugins-bad/Config.in
+++ b/package/gstreamer1/gst1-plugins-bad/Config.in
@@ -595,11 +595,11 @@  config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_WPE
 	bool "wpe"
 	default y
 	depends on BR2_PACKAGE_WPEWEBKIT
-	depends on BR2_PACKAGE_GST1_PLUGINS_BASE_HAS_LIB_OPENGL
+	depends on BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_OPENGL
 
 comment "wpe needs the gst1-plugins-base opengl library and wpewebkit"
 	depends on !BR2_PACKAGE_WPEWEBKIT \
-		|| !BR2_PACKAGE_GST1_PLUGINS_BASE_HAS_LIB_OPENGL
+		|| !BR2_PACKAGE_GST1_PLUGINS_BASE_LIB_OPENGL_OPENGL
 
 config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_X265
 	bool "x265"