All of lore.kernel.org
 help / color / mirror / Atom feed
* [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h
@ 2020-06-27 11:34 Max Krummenacher
  2020-06-27 19:31 ` Andrey Zhizhikin
  0 siblings, 1 reply; 7+ messages in thread
From: Max Krummenacher @ 2020-06-27 11:34 UTC (permalink / raw)
  To: openembedded-core; +Cc: Max Krummenacher

Starting with 1.22.8 cogl code unconditionally includes eglmesaext.h.
Change configure.ac so that eglmesaext.h is only included if it actually
exists.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---
 ...figure.ac-don-t-require-eglmesaext.h.patch | 77 +++++++++++++++++++
 meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb |  1 +
 2 files changed, 78 insertions(+)
 create mode 100644 meta/recipes-graphics/cogl/cogl-1.0/0001-configure.ac-don-t-require-eglmesaext.h.patch

diff --git a/meta/recipes-graphics/cogl/cogl-1.0/0001-configure.ac-don-t-require-eglmesaext.h.patch b/meta/recipes-graphics/cogl/cogl-1.0/0001-configure.ac-don-t-require-eglmesaext.h.patch
new file mode 100644
index 0000000000..16ab2d7797
--- /dev/null
+++ b/meta/recipes-graphics/cogl/cogl-1.0/0001-configure.ac-don-t-require-eglmesaext.h.patch
@@ -0,0 +1,77 @@
+From ca94946110f4aaeeb0cbc75e11a619b21f295056 Mon Sep 17 00:00:00 2001
+From: Max Krummenacher <max.krummenacher@toradex.com>
+Date: Thu, 25 Jun 2020 11:27:40 +0000
+Subject: [PATCH] configure.ac: don't require eglmesaext.h
+
+E.g. the Vivante EGL implementation does not provide eglmesaext.h.
+
+The commit moves the check for header file existence outside of the
+check for existence of a egl packageconfig and makes the existence
+of eglmesaext.h optional.
+
+fixes commit fb1acfec ("Fix building against libglvnd-provided EGL headers")
+Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
+
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/cogl/-/merge_requests/28]
+Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
+---
+ configure.ac | 36 +++++++++++++++++-------------------
+ 1 file changed, 17 insertions(+), 19 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 12798e9f..f7fa40e2 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1212,22 +1212,6 @@ AS_IF([test "x$NEED_EGL" = "xyes" && test "x$EGL_CHECKED" != "xyes"],
+         PKG_CHECK_EXISTS([egl],
+           [COGL_PKG_REQUIRES="$COGL_PKG_REQUIRES egl"],
+           [
+-            AC_CHECK_HEADERS(
+-              [EGL/egl.h],
+-              [],
+-              [AC_MSG_ERROR([Unable to locate required EGL headers])])
+-            AC_CHECK_HEADERS(
+-              [EGL/eglext.h],
+-              [],
+-              [AC_MSG_ERROR([Unable to locate required EGL headers])],
+-              [#include <EGL/egl.h>])
+-            AC_CHECK_HEADERS(
+-              [EGL/eglmesaext.h],
+-              [],
+-              [AC_MSG_ERROR([Unable to locate required EGL headers])],
+-              [#include <EGL/egl.h>
+-#include <EGL/eglext.h>])
+-
+             AC_CHECK_LIB(EGL, [eglInitialize],
+               [COGL_EXTRA_LDFLAGS="$COGL_EXTRA_LDFLAGS -lEGL"],
+               [AC_MSG_ERROR([Unable to locate required EGL library])])
+@@ -1236,9 +1220,23 @@ AS_IF([test "x$NEED_EGL" = "xyes" && test "x$EGL_CHECKED" != "xyes"],
+           ]
+           )
+ 
+-        COGL_EGL_INCLUDES="#include <EGL/egl.h>
+-#include <EGL/eglext.h>
+-#include <EGL/eglmesaext.h>"
++        AC_CHECK_HEADERS(
++          [EGL/egl.h],
++          [COGL_EGL_INCLUDES="#include <EGL/egl.h>"],
++          [AC_MSG_ERROR([Unable to locate required EGL headers])])
++        AC_CHECK_HEADERS(
++          [EGL/eglext.h],
++          [COGL_EGL_INCLUDES="$COGL_EGL_INCLUDES
++#include <EGL/eglext.h>"],
++          [AC_MSG_ERROR([Unable to locate required EGL headers])],
++          [$COGL_EGL_INCLUDES])
++        AC_CHECK_HEADERS(
++          [EGL/eglmesaext.h],
++          [COGL_EGL_INCLUDES="$COGL_EGL_INCLUDES
++#include <EGL/eglmesaext.h>"],
++          [],
++          [$COGL_EGL_INCLUDES])
++
+         AC_SUBST([COGL_EGL_INCLUDES])
+       ])
+ 
+-- 
+2.20.1
+
diff --git a/meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb b/meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb
index 78f6b0e7a3..b9446fab38 100644
--- a/meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb
+++ b/meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb
@@ -1,5 +1,6 @@
 require cogl-1.0.inc
 
+SRC_URI += "file://0001-configure.ac-don-t-require-eglmesaext.h.patch"
 SRC_URI[archive.sha256sum] = "a805b2b019184710ff53d0496f9f0ce6dcca420c141a0f4f6fcc02131581d759"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=1b1a508d91d25ca607c83f92f3e31c84"
-- 
2.20.1


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

* Re: [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h
  2020-06-27 11:34 [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h Max Krummenacher
@ 2020-06-27 19:31 ` Andrey Zhizhikin
  2020-06-27 22:51   ` Max Krummenacher
  0 siblings, 1 reply; 7+ messages in thread
From: Andrey Zhizhikin @ 2020-06-27 19:31 UTC (permalink / raw)
  To: Max Krummenacher; +Cc: OE Core mailing list, Max Krummenacher

Hello Max,

On Sat, Jun 27, 2020 at 1:35 PM Max Krummenacher <max.oss.09@gmail.com> wrote:
>
> Starting with 1.22.8 cogl code unconditionally includes eglmesaext.h.
> Change configure.ac so that eglmesaext.h is only included if it actually
> exists.
>
> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> ---
>  ...figure.ac-don-t-require-eglmesaext.h.patch | 77 +++++++++++++++++++
>  meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb |  1 +
>  2 files changed, 78 insertions(+)
>  create mode 100644 meta/recipes-graphics/cogl/cogl-1.0/0001-configure.ac-don-t-require-eglmesaext.h.patch
>
> diff --git a/meta/recipes-graphics/cogl/cogl-1.0/0001-configure.ac-don-t-require-eglmesaext.h.patch b/meta/recipes-graphics/cogl/cogl-1.0/0001-configure.ac-don-t-require-eglmesaext.h.patch
> new file mode 100644
> index 0000000000..16ab2d7797
> --- /dev/null
> +++ b/meta/recipes-graphics/cogl/cogl-1.0/0001-configure.ac-don-t-require-eglmesaext.h.patch
> @@ -0,0 +1,77 @@
> +From ca94946110f4aaeeb0cbc75e11a619b21f295056 Mon Sep 17 00:00:00 2001
> +From: Max Krummenacher <max.krummenacher@toradex.com>
> +Date: Thu, 25 Jun 2020 11:27:40 +0000
> +Subject: [PATCH] configure.ac: don't require eglmesaext.h
> +
> +E.g. the Vivante EGL implementation does not provide eglmesaext.h.
> +
> +The commit moves the check for header file existence outside of the
> +check for existence of a egl packageconfig and makes the existence
> +of eglmesaext.h optional.
> +
> +fixes commit fb1acfec ("Fix building against libglvnd-provided EGL headers")
> +Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> +
> +Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/cogl/-/merge_requests/28]
> +Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> +---
> + configure.ac | 36 +++++++++++++++++-------------------
> + 1 file changed, 17 insertions(+), 19 deletions(-)
> +
> +diff --git a/configure.ac b/configure.ac
> +index 12798e9f..f7fa40e2 100644
> +--- a/configure.ac
> ++++ b/configure.ac
> +@@ -1212,22 +1212,6 @@ AS_IF([test "x$NEED_EGL" = "xyes" && test "x$EGL_CHECKED" != "xyes"],
> +         PKG_CHECK_EXISTS([egl],
> +           [COGL_PKG_REQUIRES="$COGL_PKG_REQUIRES egl"],
> +           [
> +-            AC_CHECK_HEADERS(
> +-              [EGL/egl.h],
> +-              [],
> +-              [AC_MSG_ERROR([Unable to locate required EGL headers])])
> +-            AC_CHECK_HEADERS(
> +-              [EGL/eglext.h],
> +-              [],
> +-              [AC_MSG_ERROR([Unable to locate required EGL headers])],
> +-              [#include <EGL/egl.h>])
> +-            AC_CHECK_HEADERS(
> +-              [EGL/eglmesaext.h],
> +-              [],
> +-              [AC_MSG_ERROR([Unable to locate required EGL headers])],
> +-              [#include <EGL/egl.h>
> +-#include <EGL/eglext.h>])
> +-
> +             AC_CHECK_LIB(EGL, [eglInitialize],
> +               [COGL_EXTRA_LDFLAGS="$COGL_EXTRA_LDFLAGS -lEGL"],
> +               [AC_MSG_ERROR([Unable to locate required EGL library])])
> +@@ -1236,9 +1220,23 @@ AS_IF([test "x$NEED_EGL" = "xyes" && test "x$EGL_CHECKED" != "xyes"],
> +           ]
> +           )
> +
> +-        COGL_EGL_INCLUDES="#include <EGL/egl.h>
> +-#include <EGL/eglext.h>
> +-#include <EGL/eglmesaext.h>"
> ++        AC_CHECK_HEADERS(
> ++          [EGL/egl.h],
> ++          [COGL_EGL_INCLUDES="#include <EGL/egl.h>"],
> ++          [AC_MSG_ERROR([Unable to locate required EGL headers])])
> ++        AC_CHECK_HEADERS(
> ++          [EGL/eglext.h],
> ++          [COGL_EGL_INCLUDES="$COGL_EGL_INCLUDES
> ++#include <EGL/eglext.h>"],
> ++          [AC_MSG_ERROR([Unable to locate required EGL headers])],
> ++          [$COGL_EGL_INCLUDES])
> ++        AC_CHECK_HEADERS(
> ++          [EGL/eglmesaext.h],
> ++          [COGL_EGL_INCLUDES="$COGL_EGL_INCLUDES
> ++#include <EGL/eglmesaext.h>"],
> ++          [],
> ++          [$COGL_EGL_INCLUDES])
> ++
> +         AC_SUBST([COGL_EGL_INCLUDES])
> +       ])
> +
> +--
> +2.20.1
> +
> diff --git a/meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb b/meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb
> index 78f6b0e7a3..b9446fab38 100644
> --- a/meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb
> +++ b/meta/recipes-graphics/cogl/cogl-1.0_1.22.8.bb
> @@ -1,5 +1,6 @@
>  require cogl-1.0.inc
>
> +SRC_URI += "file://0001-configure.ac-don-t-require-eglmesaext.h.patch"
>  SRC_URI[archive.sha256sum] = "a805b2b019184710ff53d0496f9f0ce6dcca420c141a0f4f6fcc02131581d759"
>
>  LIC_FILES_CHKSUM = "file://COPYING;md5=1b1a508d91d25ca607c83f92f3e31c84"
> --
> 2.20.1
>

This patch fails to build with following errors in do_configure:

| checking for wayland-egl >= 1.0.0 wayland-client >= 1.0.0... yes
| checking EGL/egl.h usability... no
| checking EGL/egl.h presence... no
| checking for EGL/egl.h... no
| configure: error: Unable to locate required EGL headers
| WARNING: exit code 1 from a shell command.


> 


-- 
Regards,
Andrey.

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

* Re: [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h
  2020-06-27 19:31 ` Andrey Zhizhikin
@ 2020-06-27 22:51   ` Max Krummenacher
  2020-06-28  9:04     ` Andrey Zhizhikin
  0 siblings, 1 reply; 7+ messages in thread
From: Max Krummenacher @ 2020-06-27 22:51 UTC (permalink / raw)
  To: Andrey Zhizhikin; +Cc: OE Core mailing list, Max Krummenacher

Resent from correct email address. Sorry for the noise.

Hello Andrey


Am Samstag, den 27.06.2020, 21:31 +0200 schrieb Andrey Zhizhikin:
> Hello Max,
> 
> On Sat, Jun 27, 2020 at 1:35 PM Max Krummenacher <max.oss.09@gmail.com> wrote:
> > 
> > Starting with 1.22.8 cogl code unconditionally includes eglmesaext.h.
> > Change configure.ac so that eglmesaext.h is only included if it actually
> > exists.
> > 
> > Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> > 
> 
> This patch fails to build with following errors in do_configure:
> 
> > checking for wayland-egl >= 1.0.0 wayland-client >= 1.0.0... yes
> > checking EGL/egl.h usability... no
> > checking EGL/egl.h presence... no
> > checking for EGL/egl.h... no
> > configure: error: Unable to locate required EGL headers
> > WARNING: exit code 1 from a shell command.

I tested with a (relatively) clean meta-freescale installation, master branch.
I built an i.MX 6 based machine with use-mainline-bsp and an i.MX6 and i.MX8MM based machine with
use-nxp-bsp. 
For me the use-mainline-bsp build unsurprisingly succeeded without and with the patch. The two
builds with use-nxp-bsp failed before the patch in do_compile because eglmesaext.h is missing, but
succeeded with the patch applied.

What was your exact configuration and build target?
Do the headers exist in your build?
  .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/recipe-sysroot/usr/include/
Any hint in the configure log output?
  .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/build/config.log

Max

buildhistroy/images/colibri_imx6/glibc/core-image-weston/build-id.txt

colibri-imx6: core-image-weston configured for fslc-xwayland 3.2-snapshot-20200627

Build Configuration:
BB_VERSION           = "1.47.0"
BUILD_SYS            = "x86_64-linux"
NATIVELSBSTRING      = "universal"
TARGET_SYS           = "arm-fslc-linux-gnueabi"
MACHINE              = "colibri-imx6"
DISTRO               = "fslc-xwayland"
DISTRO_VERSION       = "3.2-snapshot-20200627"
TUNE_FEATURES        = "arm vfp cortexa9 neon thumb callconvention-hard"
TARGET_FPU           = "hard"
meta                 
meta-poky            = "master:3e96efc4dd87f74ba807692feab5d3750e7e9e30"
-> that is my patch on top of poky, master:5951cbcabe29e8520876c7646b578c12d6c20950
meta-oe              
meta-multimedia      
meta-python          = "HEAD:e9e823d1a03eec5874346ed0c87e29c376195476"
meta-freescale       = "master:be4bd4650170a5e9c38875809be440daa65aa0aa"
meta-freescale-3rdparty = "master:13c782bfe40c921034944d6680bd27517a580598"
meta-freescale-distro = "HEAD:eb60ca80e81e07909920889fcdd03649934c4896"

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

* Re: [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h
  2020-06-27 22:51   ` Max Krummenacher
@ 2020-06-28  9:04     ` Andrey Zhizhikin
  2020-06-28 14:57       ` Max Krummenacher
  0 siblings, 1 reply; 7+ messages in thread
From: Andrey Zhizhikin @ 2020-06-28  9:04 UTC (permalink / raw)
  To: Max Krummenacher; +Cc: OE Core mailing list, Max Krummenacher

Hello Max

On Sun, Jun 28, 2020 at 12:51 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
>
> Resent from correct email address. Sorry for the noise.
>
> Hello Andrey
>
>
> Am Samstag, den 27.06.2020, 21:31 +0200 schrieb Andrey Zhizhikin:
> > Hello Max,
> >
> > On Sat, Jun 27, 2020 at 1:35 PM Max Krummenacher <max.oss.09@gmail.com> wrote:
> > >
> > > Starting with 1.22.8 cogl code unconditionally includes eglmesaext.h.
> > > Change configure.ac so that eglmesaext.h is only included if it actually
> > > exists.
> > >
> > > Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> > >
> >
> > This patch fails to build with following errors in do_configure:
> >
> > > checking for wayland-egl >= 1.0.0 wayland-client >= 1.0.0... yes
> > > checking EGL/egl.h usability... no
> > > checking EGL/egl.h presence... no
> > > checking for EGL/egl.h... no
> > > configure: error: Unable to locate required EGL headers
> > > WARNING: exit code 1 from a shell command.
>
> I tested with a (relatively) clean meta-freescale installation, master branch.
> I built an i.MX 6 based machine with use-mainline-bsp and an i.MX6 and i.MX8MM based machine with
> use-nxp-bsp.

Exactly the combination of imx8mmevk and use-nxp-bsp is failing for
me. I tried to perform the clean build with the same failed results...

> For me the use-mainline-bsp build unsurprisingly succeeded without and with the patch. The two
> builds with use-nxp-bsp failed before the patch in do_compile because eglmesaext.h is missing, but
> succeeded with the patch applied.

I've opened the issue regarding this failure in meta-freescale
(https://github.com/Freescale/meta-freescale/issues/438) where I tried
to sum up the details regarding this failure, and looks like the fix
you proposed should've address it. I do not have a `use-mainline-bsp`
build, and imx8mmevk build fails because of the missing non-upstreamed
`mesa` header installation. Current `mesa` configuration in Freescale
layer disables EGL, therefore `EGL/eglmesaext.h` is not installed into
sysroot.

>
> What was your exact configuration and build target?

Build Configuration:
BB_VERSION           = "1.47.0"
BUILD_SYS            = "x86_64-linux"
NATIVELSBSTRING      = "universal"
TARGET_SYS           = "aarch64-fsl-linux"
MACHINE              = "imx8mmevk"
DISTRO               = "krill-wayland"
DISTRO_VERSION       = "2020.04"
TUNE_FEATURES        = "aarch64 cortexa53 crc crypto"
TARGET_FPU           = ""
meta
meta-poky            = "master:70f14da0c558a54439fca245b73e054b8deba75d"
meta-oe
meta-multimedia
meta-python
meta-networking
meta-filesystems     = "master:e9e823d1a03eec5874346ed0c87e29c376195476"
meta-freescale       = "master:be4bd4650170a5e9c38875809be440daa65aa0aa"
meta-freescale-3rdparty = "master:13c782bfe40c921034944d6680bd27517a580598"
meta-freescale-distro = "master:c1da36a693c1d9b50d4d318cb4a960e8daaddbd5"

DISTRO is a pure derivative of fsl-wayland, there are no graphics
amendments inside.


> Do the headers exist in your build?
>   .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/recipe-sysroot/usr/include/

Nope, the header is not installed into recipe-sysroot. Surprisingly
however, it is present in
cogl-1.0/1.22.8-r0/recipe-sysroot-native/usr/include/

> Any hint in the configure log output?
>   .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/build/config.log
>

Other than missing `EGL/egl.h` file, which reports the error:
configure:25431: result: no
configure:25431: checking for EGL/egl.h
configure:25431: result: no
configure:25438: error: Unable to locate required EGL headers

there are some additional errors regarding missing X11 support and
needed optimization warning for _FORTIFY_SOURCE

I've uploaded the config.log to GitHub
(https://gist.github.com/zandrey/65b15322c9561847f499648a2a46f173) so
you can take a look at it.

> Max
>
> buildhistroy/images/colibri_imx6/glibc/core-image-weston/build-id.txt
>
> colibri-imx6: core-image-weston configured for fslc-xwayland 3.2-snapshot-20200627
>
> Build Configuration:
> BB_VERSION           = "1.47.0"
> BUILD_SYS            = "x86_64-linux"
> NATIVELSBSTRING      = "universal"
> TARGET_SYS           = "arm-fslc-linux-gnueabi"
> MACHINE              = "colibri-imx6"
> DISTRO               = "fslc-xwayland"
> DISTRO_VERSION       = "3.2-snapshot-20200627"
> TUNE_FEATURES        = "arm vfp cortexa9 neon thumb callconvention-hard"
> TARGET_FPU           = "hard"
> meta
> meta-poky            = "master:3e96efc4dd87f74ba807692feab5d3750e7e9e30"
> -> that is my patch on top of poky, master:5951cbcabe29e8520876c7646b578c12d6c20950
> meta-oe
> meta-multimedia
> meta-python          = "HEAD:e9e823d1a03eec5874346ed0c87e29c376195476"
> meta-freescale       = "master:be4bd4650170a5e9c38875809be440daa65aa0aa"
> meta-freescale-3rdparty = "master:13c782bfe40c921034944d6680bd27517a580598"
> meta-freescale-distro = "HEAD:eb60ca80e81e07909920889fcdd03649934c4896"



-- 
Regards,
Andrey.

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

* Re: [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h
  2020-06-28  9:04     ` Andrey Zhizhikin
@ 2020-06-28 14:57       ` Max Krummenacher
  2020-06-28 15:06         ` Andrey Zhizhikin
       [not found]         ` <161CBD9446BC6284.11480@lists.openembedded.org>
  0 siblings, 2 replies; 7+ messages in thread
From: Max Krummenacher @ 2020-06-28 14:57 UTC (permalink / raw)
  To: Andrey Zhizhikin; +Cc: OE Core mailing list, Max Krummenacher

Am Sonntag, den 28.06.2020, 11:04 +0200 schrieb Andrey Zhizhikin:
> Hello Max
> 
> On Sun, Jun 28, 2020 at 12:51 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
> > 
> > Resent from correct email address. Sorry for the noise.
> > 
> > Hello Andrey
> > 
> > 
> > Am Samstag, den 27.06.2020, 21:31 +0200 schrieb Andrey Zhizhikin:
> > > Hello Max,
> > > 
> > > On Sat, Jun 27, 2020 at 1:35 PM Max Krummenacher <max.oss.09@gmail.com> wrote:
> > > > 
> > > > Starting with 1.22.8 cogl code unconditionally includes eglmesaext.h.
> > > > Change configure.ac so that eglmesaext.h is only included if it actually
> > > > exists.
> > > > 
> > > > Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> > > > 
> > > 
> > > This patch fails to build with following errors in do_configure:
> > > 
> > > > checking for wayland-egl >= 1.0.0 wayland-client >= 1.0.0... yes
> > > > checking EGL/egl.h usability... no
> > > > checking EGL/egl.h presence... no
> > > > checking for EGL/egl.h... no
> > > > configure: error: Unable to locate required EGL headers
> > > > WARNING: exit code 1 from a shell command.
> > 
> > I tested with a (relatively) clean meta-freescale installation, master branch.
> > I built an i.MX 6 based machine with use-mainline-bsp and an i.MX6 and i.MX8MM based machine
> > with
> > use-nxp-bsp.
> 
> Exactly the combination of imx8mmevk and use-nxp-bsp is failing for
> me. I tried to perform the clean build with the same failed results...
> 
> > For me the use-mainline-bsp build unsurprisingly succeeded without and with the patch. The two
> > builds with use-nxp-bsp failed before the patch in do_compile because eglmesaext.h is missing,
> > but
> > succeeded with the patch applied.
> 
> I've opened the issue regarding this failure in meta-freescale
> (https://github.com/Freescale/meta-freescale/issues/438) where I tried
> to sum up the details regarding this failure, and looks like the fix
> you proposed should've address it. I do not have a `use-mainline-bsp`
> build, and imx8mmevk build fails because of the missing non-upstreamed
> `mesa` header installation. Current `mesa` configuration in Freescale
> layer disables EGL, therefore `EGL/eglmesaext.h` is not installed into
> sysroot.
> 
> > 
> > What was your exact configuration and build target?
> 
> Build Configuration:
> BB_VERSION           = "1.47.0"
> BUILD_SYS            = "x86_64-linux"
> NATIVELSBSTRING      = "universal"
> TARGET_SYS           = "aarch64-fsl-linux"
> MACHINE              = "imx8mmevk"
> DISTRO               = "krill-wayland"
> DISTRO_VERSION       = "2020.04"
> TUNE_FEATURES        = "aarch64 cortexa53 crc crypto"
> TARGET_FPU           = ""
> meta
> meta-poky            = "master:70f14da0c558a54439fca245b73e054b8deba75d"
> meta-oe
> meta-multimedia
> meta-python
> meta-networking
> meta-filesystems     = "master:e9e823d1a03eec5874346ed0c87e29c376195476"
> meta-freescale       = "master:be4bd4650170a5e9c38875809be440daa65aa0aa"
> meta-freescale-3rdparty = "master:13c782bfe40c921034944d6680bd27517a580598"
> meta-freescale-distro = "master:c1da36a693c1d9b50d4d318cb4a960e8daaddbd5"
> 
> DISTRO is a pure derivative of fsl-wayland, there are no graphics
> amendments inside.

Looks like that distro does not have xwayland and thus the X11 headers are
not installed. That now makes the test for egl.h fail as by default X11 headers
are included through eglplatform.h.
That wasn't catched by my tests as I used a distro which builds xwayland.

> 
> 
> > Do the headers exist in your build?
> >   .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/recipe-sysroot/usr/include/
> 
> Nope, the header is not installed into recipe-sysroot. Surprisingly
> however, it is present in
> cogl-1.0/1.22.8-r0/recipe-sysroot-native/usr/include/

Are you sure? Your config.log tells otherwise:

    In file included from ...recipe-sysroot/usr/include/EGL/egl.h:39,
                     from conftest.c:63:
    ...recipe-sysroot/usr/include/EGL/eglplatform.h:144:10: fatal error: X11/Xlib.h: No such file or
directory

Does replacing the initial patch with this one help in your setup?
The test should not only check for existence of the headers themselves.
https://gitlab.gnome.org/GNOME/cogl/-/commit/d9f38c5864e577edb7e9f55c9f1d06248f85429b.patch

Max
> 
> > Any hint in the configure log output?
> >   .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/build/config.log
> > 
> 
> Other than missing `EGL/egl.h` file, which reports the error:
> configure:25431: result: no
> configure:25431: checking for EGL/egl.h
> configure:25431: result: no
> configure:25438: error: Unable to locate required EGL headers
> 
> there are some additional errors regarding missing X11 support and
> needed optimization warning for _FORTIFY_SOURCE
> 
> I've uploaded the config.log to GitHub
> (https://gist.github.com/zandrey/65b15322c9561847f499648a2a46f173) so
> you can take a look at it.




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

* Re: [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h
  2020-06-28 14:57       ` Max Krummenacher
@ 2020-06-28 15:06         ` Andrey Zhizhikin
       [not found]         ` <161CBD9446BC6284.11480@lists.openembedded.org>
  1 sibling, 0 replies; 7+ messages in thread
From: Andrey Zhizhikin @ 2020-06-28 15:06 UTC (permalink / raw)
  To: Max Krummenacher; +Cc: OE Core mailing list, Max Krummenacher

On Sun, Jun 28, 2020 at 4:58 PM Max Krummenacher <max.oss.09@gmail.com> wrote:
>
> Am Sonntag, den 28.06.2020, 11:04 +0200 schrieb Andrey Zhizhikin:
> > Hello Max
> >
> > On Sun, Jun 28, 2020 at 12:51 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
> > >
> > > Resent from correct email address. Sorry for the noise.
> > >
> > > Hello Andrey
> > >
> > >
> > > Am Samstag, den 27.06.2020, 21:31 +0200 schrieb Andrey Zhizhikin:
> > > > Hello Max,
> > > >
> > > > On Sat, Jun 27, 2020 at 1:35 PM Max Krummenacher <max.oss.09@gmail.com> wrote:
> > > > >
> > > > > Starting with 1.22.8 cogl code unconditionally includes eglmesaext.h.
> > > > > Change configure.ac so that eglmesaext.h is only included if it actually
> > > > > exists.
> > > > >
> > > > > Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> > > > >
> > > >
> > > > This patch fails to build with following errors in do_configure:
> > > >
> > > > > checking for wayland-egl >= 1.0.0 wayland-client >= 1.0.0... yes
> > > > > checking EGL/egl.h usability... no
> > > > > checking EGL/egl.h presence... no
> > > > > checking for EGL/egl.h... no
> > > > > configure: error: Unable to locate required EGL headers
> > > > > WARNING: exit code 1 from a shell command.
> > >
> > > I tested with a (relatively) clean meta-freescale installation, master branch.
> > > I built an i.MX 6 based machine with use-mainline-bsp and an i.MX6 and i.MX8MM based machine
> > > with
> > > use-nxp-bsp.
> >
> > Exactly the combination of imx8mmevk and use-nxp-bsp is failing for
> > me. I tried to perform the clean build with the same failed results...
> >
> > > For me the use-mainline-bsp build unsurprisingly succeeded without and with the patch. The two
> > > builds with use-nxp-bsp failed before the patch in do_compile because eglmesaext.h is missing,
> > > but
> > > succeeded with the patch applied.
> >
> > I've opened the issue regarding this failure in meta-freescale
> > (https://github.com/Freescale/meta-freescale/issues/438) where I tried
> > to sum up the details regarding this failure, and looks like the fix
> > you proposed should've address it. I do not have a `use-mainline-bsp`
> > build, and imx8mmevk build fails because of the missing non-upstreamed
> > `mesa` header installation. Current `mesa` configuration in Freescale
> > layer disables EGL, therefore `EGL/eglmesaext.h` is not installed into
> > sysroot.
> >
> > >
> > > What was your exact configuration and build target?
> >
> > Build Configuration:
> > BB_VERSION           = "1.47.0"
> > BUILD_SYS            = "x86_64-linux"
> > NATIVELSBSTRING      = "universal"
> > TARGET_SYS           = "aarch64-fsl-linux"
> > MACHINE              = "imx8mmevk"
> > DISTRO               = "krill-wayland"
> > DISTRO_VERSION       = "2020.04"
> > TUNE_FEATURES        = "aarch64 cortexa53 crc crypto"
> > TARGET_FPU           = ""
> > meta
> > meta-poky            = "master:70f14da0c558a54439fca245b73e054b8deba75d"
> > meta-oe
> > meta-multimedia
> > meta-python
> > meta-networking
> > meta-filesystems     = "master:e9e823d1a03eec5874346ed0c87e29c376195476"
> > meta-freescale       = "master:be4bd4650170a5e9c38875809be440daa65aa0aa"
> > meta-freescale-3rdparty = "master:13c782bfe40c921034944d6680bd27517a580598"
> > meta-freescale-distro = "master:c1da36a693c1d9b50d4d318cb4a960e8daaddbd5"
> >
> > DISTRO is a pure derivative of fsl-wayland, there are no graphics
> > amendments inside.
>
> Looks like that distro does not have xwayland and thus the X11 headers are
> not installed. That now makes the test for egl.h fail as by default X11 headers
> are included through eglplatform.h.
> That wasn't catched by my tests as I used a distro which builds xwayland.

Correct, I'm using Wayland-only distro, no X11 is enabled.

>
> >
> >
> > > Do the headers exist in your build?
> > >   .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/recipe-sysroot/usr/include/
> >
> > Nope, the header is not installed into recipe-sysroot. Surprisingly
> > however, it is present in
> > cogl-1.0/1.22.8-r0/recipe-sysroot-native/usr/include/
>
> Are you sure? Your config.log tells otherwise:
>
>     In file included from ...recipe-sysroot/usr/include/EGL/egl.h:39,
>                      from conftest.c:63:
>     ...recipe-sysroot/usr/include/EGL/eglplatform.h:144:10: fatal error: X11/Xlib.h: No such file or
> directory

I guess my comment was confusing, sorry for that. I do not have Mesa
non-upstreamed headers (eglmesaext.h and eglextchromium.h) installed
in recipe-sysroot, all other headers are present. I thought you've
been asking for those headers only.


>
> Does replacing the initial patch with this one help in your setup?
> The test should not only check for existence of the headers themselves.
> https://gitlab.gnome.org/GNOME/cogl/-/commit/d9f38c5864e577edb7e9f55c9f1d06248f85429b.patch

I'll give it a try now, thanks for pointing it out! ;)

>
> Max
> >
> > > Any hint in the configure log output?
> > >   .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/build/config.log
> > >
> >
> > Other than missing `EGL/egl.h` file, which reports the error:
> > configure:25431: result: no
> > configure:25431: checking for EGL/egl.h
> > configure:25431: result: no
> > configure:25438: error: Unable to locate required EGL headers
> >
> > there are some additional errors regarding missing X11 support and
> > needed optimization warning for _FORTIFY_SOURCE
> >
> > I've uploaded the config.log to GitHub
> > (https://gist.github.com/zandrey/65b15322c9561847f499648a2a46f173) so
> > you can take a look at it.
>
>
>

-- 
Regards,
Andrey.

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

* Re: [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h
       [not found]         ` <161CBD9446BC6284.11480@lists.openembedded.org>
@ 2020-06-28 15:54           ` Andrey Zhizhikin
  0 siblings, 0 replies; 7+ messages in thread
From: Andrey Zhizhikin @ 2020-06-28 15:54 UTC (permalink / raw)
  To: Andrey Zhizhikin; +Cc: Max Krummenacher, OE Core mailing list, Max Krummenacher

On Sun, Jun 28, 2020 at 5:07 PM Andrey Zhizhikin via
lists.openembedded.org <andrey.z=gmail.com@lists.openembedded.org>
wrote:
>
> On Sun, Jun 28, 2020 at 4:58 PM Max Krummenacher <max.oss.09@gmail.com> wrote:
> >
> > Am Sonntag, den 28.06.2020, 11:04 +0200 schrieb Andrey Zhizhikin:
> > > Hello Max
> > >
> > > On Sun, Jun 28, 2020 at 12:51 AM Max Krummenacher <max.oss.09@gmail.com> wrote:
> > > >
> > > > Resent from correct email address. Sorry for the noise.
> > > >
> > > > Hello Andrey
> > > >
> > > >
> > > > Am Samstag, den 27.06.2020, 21:31 +0200 schrieb Andrey Zhizhikin:
> > > > > Hello Max,
> > > > >
> > > > > On Sat, Jun 27, 2020 at 1:35 PM Max Krummenacher <max.oss.09@gmail.com> wrote:
> > > > > >
> > > > > > Starting with 1.22.8 cogl code unconditionally includes eglmesaext.h.
> > > > > > Change configure.ac so that eglmesaext.h is only included if it actually
> > > > > > exists.
> > > > > >
> > > > > > Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> > > > > >
> > > > >
> > > > > This patch fails to build with following errors in do_configure:
> > > > >
> > > > > > checking for wayland-egl >= 1.0.0 wayland-client >= 1.0.0... yes
> > > > > > checking EGL/egl.h usability... no
> > > > > > checking EGL/egl.h presence... no
> > > > > > checking for EGL/egl.h... no
> > > > > > configure: error: Unable to locate required EGL headers
> > > > > > WARNING: exit code 1 from a shell command.
> > > >
> > > > I tested with a (relatively) clean meta-freescale installation, master branch.
> > > > I built an i.MX 6 based machine with use-mainline-bsp and an i.MX6 and i.MX8MM based machine
> > > > with
> > > > use-nxp-bsp.
> > >
> > > Exactly the combination of imx8mmevk and use-nxp-bsp is failing for
> > > me. I tried to perform the clean build with the same failed results...
> > >
> > > > For me the use-mainline-bsp build unsurprisingly succeeded without and with the patch. The two
> > > > builds with use-nxp-bsp failed before the patch in do_compile because eglmesaext.h is missing,
> > > > but
> > > > succeeded with the patch applied.
> > >
> > > I've opened the issue regarding this failure in meta-freescale
> > > (https://github.com/Freescale/meta-freescale/issues/438) where I tried
> > > to sum up the details regarding this failure, and looks like the fix
> > > you proposed should've address it. I do not have a `use-mainline-bsp`
> > > build, and imx8mmevk build fails because of the missing non-upstreamed
> > > `mesa` header installation. Current `mesa` configuration in Freescale
> > > layer disables EGL, therefore `EGL/eglmesaext.h` is not installed into
> > > sysroot.
> > >
> > > >
> > > > What was your exact configuration and build target?
> > >
> > > Build Configuration:
> > > BB_VERSION           = "1.47.0"
> > > BUILD_SYS            = "x86_64-linux"
> > > NATIVELSBSTRING      = "universal"
> > > TARGET_SYS           = "aarch64-fsl-linux"
> > > MACHINE              = "imx8mmevk"
> > > DISTRO               = "krill-wayland"
> > > DISTRO_VERSION       = "2020.04"
> > > TUNE_FEATURES        = "aarch64 cortexa53 crc crypto"
> > > TARGET_FPU           = ""
> > > meta
> > > meta-poky            = "master:70f14da0c558a54439fca245b73e054b8deba75d"
> > > meta-oe
> > > meta-multimedia
> > > meta-python
> > > meta-networking
> > > meta-filesystems     = "master:e9e823d1a03eec5874346ed0c87e29c376195476"
> > > meta-freescale       = "master:be4bd4650170a5e9c38875809be440daa65aa0aa"
> > > meta-freescale-3rdparty = "master:13c782bfe40c921034944d6680bd27517a580598"
> > > meta-freescale-distro = "master:c1da36a693c1d9b50d4d318cb4a960e8daaddbd5"
> > >
> > > DISTRO is a pure derivative of fsl-wayland, there are no graphics
> > > amendments inside.
> >
> > Looks like that distro does not have xwayland and thus the X11 headers are
> > not installed. That now makes the test for egl.h fail as by default X11 headers
> > are included through eglplatform.h.
> > That wasn't catched by my tests as I used a distro which builds xwayland.
>
> Correct, I'm using Wayland-only distro, no X11 is enabled.
>
> >
> > >
> > >
> > > > Do the headers exist in your build?
> > > >   .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/recipe-sysroot/usr/include/
> > >
> > > Nope, the header is not installed into recipe-sysroot. Surprisingly
> > > however, it is present in
> > > cogl-1.0/1.22.8-r0/recipe-sysroot-native/usr/include/
> >
> > Are you sure? Your config.log tells otherwise:
> >
> >     In file included from ...recipe-sysroot/usr/include/EGL/egl.h:39,
> >                      from conftest.c:63:
> >     ...recipe-sysroot/usr/include/EGL/eglplatform.h:144:10: fatal error: X11/Xlib.h: No such file or
> > directory
>
> I guess my comment was confusing, sorry for that. I do not have Mesa
> non-upstreamed headers (eglmesaext.h and eglextchromium.h) installed
> in recipe-sysroot, all other headers are present. I thought you've
> been asking for those headers only.
>
>
> >
> > Does replacing the initial patch with this one help in your setup?
> > The test should not only check for existence of the headers themselves.
> > https://gitlab.gnome.org/GNOME/cogl/-/commit/d9f38c5864e577edb7e9f55c9f1d06248f85429b.patch
>
> I'll give it a try now, thanks for pointing it out! ;)

With this version (also d9f38c5864e577edb7e9f55c9f1d06248f85429b)
Wayland-only build succeeds, so:

Tested-by: Andrey Zhizhikin <andrey.z@gmail.com>

>
> >
> > Max
> > >
> > > > Any hint in the configure log output?
> > > >   .../work/<pkg-arch>/cogl-1.0/1.22.8-r0/build/config.log
> > > >
> > >
> > > Other than missing `EGL/egl.h` file, which reports the error:
> > > configure:25431: result: no
> > > configure:25431: checking for EGL/egl.h
> > > configure:25431: result: no
> > > configure:25438: error: Unable to locate required EGL headers
> > >
> > > there are some additional errors regarding missing X11 support and
> > > needed optimization warning for _FORTIFY_SOURCE
> > >
> > > I've uploaded the config.log to GitHub
> > > (https://gist.github.com/zandrey/65b15322c9561847f499648a2a46f173) so
> > > you can take a look at it.
> >
> >
> >
>
> --
> Regards,
> Andrey.
> 



-- 
Regards,
Andrey.

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

end of thread, other threads:[~2020-06-28 15:54 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-06-27 11:34 [[OE-core][Patch] cogl-1.0: : don't require eglmesaext.h Max Krummenacher
2020-06-27 19:31 ` Andrey Zhizhikin
2020-06-27 22:51   ` Max Krummenacher
2020-06-28  9:04     ` Andrey Zhizhikin
2020-06-28 14:57       ` Max Krummenacher
2020-06-28 15:06         ` Andrey Zhizhikin
     [not found]         ` <161CBD9446BC6284.11480@lists.openembedded.org>
2020-06-28 15:54           ` Andrey Zhizhikin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.