Index: graphics/MesaLib/buildlink3.mk =================================================================== RCS file: /cvsroot/pkgsrc/graphics/MesaLib/buildlink3.mk,v retrieving revision 1.52 diff -u -r1.52 buildlink3.mk --- graphics/MesaLib/buildlink3.mk 25 Apr 2015 11:19:18 -0000 1.52 +++ graphics/MesaLib/buildlink3.mk 16 Sep 2015 00:56:20 -0000 @@ -35,6 +35,13 @@ . include "../../graphics/MesaLib/dri.mk" .endif +.if ${X11_TYPE} == "modular" && !empty(PKG_BUILD_OPTIONS.MesaLib:Mdri) || \ + ${X11_TYPE} == "native" && exists(${X11BASE}/include/EGL/egl.h) +MESALIB_SUPPORTS_EGL= yes +.else +MESALIB_SUPPORTS_EGL= no +.endif + .if !empty(MACHINE_PLATFORM:MNetBSD-[12].*) .include "../../devel/pthread-stublib/buildlink3.mk" .endif Index: multimedia/libva/Makefile =================================================================== RCS file: /cvsroot/pkgsrc/multimedia/libva/Makefile,v retrieving revision 1.8 diff -u -r1.8 Makefile --- multimedia/libva/Makefile 28 Apr 2015 06:56:18 -0000 1.8 +++ multimedia/libva/Makefile 16 Sep 2015 00:56:20 -0000 @@ -34,14 +34,14 @@ PKGCONFIG_OVERRIDE+= libva.pc.in PLIST_VARS+= egl -.if ${X11_TYPE} == "modular" || exists(${X11BASE}/include/EGL/egl.h) -PLIST.egl= yes -.endif pre-configure: cd ${WRKSRC} && autoreconf -i .include "../../graphics/MesaLib/buildlink3.mk" +.if !empty(MESALIB_SUPPORTS_EGL:Myes) +PLIST.egl= yes +.endif .include "../../x11/libXfixes/buildlink3.mk" .include "../../x11/libXext/buildlink3.mk" .include "../../x11/libX11/buildlink3.mk" Index: graphics/libepoxy/Makefile =================================================================== RCS file: /cvsroot/pkgsrc/graphics/libepoxy/Makefile,v retrieving revision 1.9 diff -u -r1.9 Makefile --- graphics/libepoxy/Makefile 14 Sep 2015 18:20:12 -0000 1.9 +++ graphics/libepoxy/Makefile 16 Sep 2015 00:56:20 -0000 @@ -26,12 +26,7 @@ .include "../../mk/bsd.prefs.mk" PLIST_VARS+= egl -.if ${X11_TYPE} == "modular" || exists(${X11BASE}/include/EGL/egl.h) -PLIST.egl= yes -CONFIGURE_ENV+= PKGSRC_BUILD_EGL=yes -.else -CONFIGURE_ENV+= PKGSRC_BUILD_EGL=no -.endif +CONFIGURE_ENV+= PKGSRC_BUILD_EGL=${MESALIB_SUPPORTS_EGL} # This could be garbage collected, but it seems likely that there will # be more glx issues, so it seems easier to leave it. @@ -46,5 +41,8 @@ .include "../../lang/python/tool.mk" .include "../../devel/xorg-util-macros/buildlink3.mk" .include "../../graphics/MesaLib/buildlink3.mk" +.if !empty(MESALIB_SUPPORTS_EGL:Myes) +PLIST.egl= yes +.endif .include "../../x11/libX11/buildlink3.mk" .include "../../mk/bsd.pkg.mk" Index: x11/qt5-qtbase/Makefile =================================================================== RCS file: /cvsroot/pkgsrc/x11/qt5-qtbase/Makefile,v retrieving revision 1.25 diff -u -r1.25 Makefile --- x11/qt5-qtbase/Makefile 4 Jul 2015 16:18:42 -0000 1.25 +++ x11/qt5-qtbase/Makefile 16 Sep 2015 00:56:20 -0000 @@ -52,9 +52,6 @@ .endif PLIST_VARS+= egl -.if ${X11_TYPE} == "modular" || exists(${X11BASE}/include/EGL/egl.h) -PLIST.egl= yes -.endif .include "../../mk/compiler.mk" @@ -186,6 +183,9 @@ .include "../../textproc/icu/buildlink3.mk" .if ${OPSYS} != "Darwin" .include "../../graphics/glu/buildlink3.mk" +.if !empty(MESALIB_SUPPORTS_EGL:Myes) +PLIST.egl= yes +.endif .include "../../x11/libxcb/buildlink3.mk" .include "../../x11/xcb-util/buildlink3.mk" .include "../../x11/xcb-util-image/buildlink3.mk"