mesa: double check for eglplatform.h
Even if 'egl' is in PACKAGECONFIG, mesa egl support can be disabled explicitly (using a .bbappend, for example). This patch adds another check for the existence
of eglplatform.h before 'sed' can alter it.
--- meta/recipes-graphics/mesa/mesa_9.1.6.bb | 4 +++- meta/recipes-graphics/mesa/mesa_git.bb | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-)
meta/recipes-graphics/mesa/mesa_9.1.6.bb +3 -1
@@ -19,6 +19,8 @@ S = "${WORKDIR}/Mesa-${PV}" #make eglplatform.h independent of MESA_EGL_NO_X11_HEADER do_install_append() { if ${@base_contains('PACKAGECONFIG', 'egl', 'true', 'false', d)}; then - sed -i -e 's/^#ifdef MESA_EGL_NO_X11_HEADERS/#if ${@base_contains('DISTRO_FEATURES', 'x11', '0', '1', d)}/' ${D}${includedir}/EGL/eglplatform.h + if [ -e "${D}${includedir}/EGL/eglplatform.h" ]; then + sed -i -e 's/^#ifdef MESA_EGL_NO_X11_HEADERS/#if ${@base_contains('DISTRO_FEATURES', 'x11', '0', '1', d)}/' ${D}${includedir}/EGL/eglplatform.h + fi fi }
meta/recipes-graphics/mesa/mesa_git.bb +3 -1
@@ -23,6 +23,8 @@ S = "${WORKDIR}/git" #make eglplatform.h independent of MESA_EGL_NO_X11_HEADER do_install_append() { if ${@base_contains('PACKAGECONFIG', 'egl', 'true', 'false', d)}; then - sed -i -e 's/^#ifdef MESA_EGL_NO_X11_HEADERS/#if ${@base_contains('DISTRO_FEATURES', 'x11', '0', '1', d)}/' ${D}${includedir}/EGL/eglplatform.h + if [ -e "${D}${includedir}/EGL/eglplatform.h" ]; then + sed -i -e 's/^#ifdef MESA_EGL_NO_X11_HEADERS/#if ${@base_contains('DISTRO_FEATURES', 'x11', '0', '1', d)}/' ${D}${includedir}/EGL/eglplatform.h + fi fi }
Signature · 1 line
1.8.3.2
Hi Valentin,
Quoted 6 lines · On Monday 14 April 2014 16:58:14 Valentin Popa wrote:
Even if 'egl' is in PACKAGECONFIG, mesa egl support can be disabled explicitly (using a .bbappend, for example). This patch adds another check for the existence
ofeglplatform.hbefore 'sed' can alter it.Signed-off-by Valentin Popa <[email protected]>
If this is dora-only, you need to mention why master isn't affected in the commit message. If it affects master the patch needs to go into master first and then dora.
Cheers,
Paul
Signature · 2 lines
Paul Eggleton Intel Open Source Technology Centre
Quoted 8 lines · Paul Eggleton
Hi Valentin,
Quoted 5 lines · On Monday 14 April 2014 16:58:14 Valentin Popa wrote:
Even if 'egl' is in PACKAGECONFIG, mesa egl support can be disabled explicitly (using a .bbappend, for example). This patch adds another check for the existence
ofeglplatform.hbefore 'sed' can alter it.
Quoted 8 lines
Quoted 1 line
Signed-off-by Valentin Popa <[email protected]>If this is dora-only, you need to mention why master isn't affected in the commit message. If it affects master the patch needs to go into master first and then dora.
Cheers,
Paul
It doesn't affect the master. It's just for dora. I'll submit a V3 with the explanations.