NetBSD Problem Report #50243

From www@NetBSD.org  Mon Sep 14 11:22:56 2015
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.netbsd.org", Issuer "Postmaster NetBSD.org" (verified OK))
	by mollari.NetBSD.org (Postfix) with ESMTPS id B632BA6531
	for <gnats-bugs@gnats.NetBSD.org>; Mon, 14 Sep 2015 11:22:56 +0000 (UTC)
Message-Id: <20150914112255.85870A6558@mollari.NetBSD.org>
Date: Mon, 14 Sep 2015 11:22:55 +0000 (UTC)
From: joern.clausen@uni-bielefeld.de
Reply-To: joern.clausen@uni-bielefeld.de
To: gnats-bugs@NetBSD.org
Subject: graphics/libepoxy and option EGL from MesaLib
X-Send-Pr-Version: www-1.0

>Number:         50243
>Category:       pkg
>Synopsis:       graphics/libepoxy and option EGL from MesaLib
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Sep 14 11:25:00 +0000 2015
>Closed-Date:    Wed Sep 16 12:31:39 +0000 2015
>Last-Modified:  Wed Sep 16 12:31:39 +0000 2015
>Originator:     Joern Clausen
>Release:        
>Organization:
University of Bielefeld
>Environment:
>Description:
After making EGL optional in graphics/MesaLib (see pkg/50232), graphics/libepoxy fails, if EGL.h is not present.
>How-To-Repeat:

>Fix:
This fixes the problem for me:

--- Makefile    2015/09/14 11:17:56     1.1
+++ Makefile    2015/09/14 11:18:07
@@ -26,7 +26,7 @@
 .include "../../mk/bsd.prefs.mk"

 PLIST_VARS+=           egl
-.if ${X11_TYPE} == "modular" || exists(${X11BASE}/include/EGL/egl.h)
+.if ${X11_TYPE} == "modular" && exists(${X11BASE}/include/EGL/egl.h)
 PLIST.egl=             yes
 CONFIGURE_ENV+=                PKGSRC_BUILD_EGL=yes
 .else


Maybe the check for modular X11 is now unnecessary?

>Release-Note:

>Audit-Trail:
From: Tobias Nygren <tnn@NetBSD.org>
To: joern.clausen@uni-bielefeld.de
Cc: gnats-bugs@NetBSD.org
Subject: Re: pkg/50243: graphics/libepoxy and option EGL from MesaLib
Date: Mon, 14 Sep 2015 15:10:35 +0200

 On Mon, 14 Sep 2015 11:25:00 +0000 (UTC)
 joern.clausen@uni-bielefeld.de wrote:

 >  PLIST_VARS+=           egl
 > -.if ${X11_TYPE} == "modular" || exists(${X11BASE}/include/EGL/egl.h)
 > +.if  && exists(${X11BASE}/include/EGL/egl.h)
 >  PLIST.egl=             yes
 >  CONFIGURE_ENV+=                PKGSRC_BUILD_EGL=yes
 >  .else
 > 
 > Maybe the check for modular X11 is now unnecessary?

 I'm afraid that is not going to work. In the modular case we cannot
 safely rely on exists() because the dependency package might not be
 installed yet in PREFIX. Maybe something like this will work:

 .include "../../graphics/MesaLib/buildlink3.mk"
 .if ${X11_TYPE} == "modular" && !empty(PKG_BUILD_OPTIONS.MesaLib:Mdri) \
 	|| exists(${X11BASE}/include/EGL/egl.h)

 These packages also use this idiom:
 multimedia/libva/Makefile
 x11/qt5-qtbase/Makefile

From: =?ISO-8859-1?Q?J=F6rn_Clausen?= <joern.clausen@uni-bielefeld.de>
To: Tobias Nygren <tnn@NetBSD.org>
Cc: gnats-bugs@NetBSD.org
Subject: Re: pkg/50243: graphics/libepoxy and option EGL from MesaLib
Date: Mon, 14 Sep 2015 15:24:11 +0200

 > I'm afraid that is not going to work. In the modular case we cannot
 > safely rely on exists() because the dependency package might not be
 > installed yet in PREFIX.

 I thought this

 .include "../../graphics/MesaLib/buildlink3.mk"

 guarantees that MesaLib is installed before libepoxy is even considered 
 to be build???

 -- 
 Jörn Clausen
 Plattformen & Serverdienste
 Hochschulrechenzentrum

 Universität Bielefeld
 Universitätsstraße 25
 33615 Bielefeld
 Telefon: +49 521 106-12601
 E-Mail: joern.clausen@uni-bielefeld.de

 http://www.uni-bielefeld.de/hrz

State-Changed-From-To: open->feedback
State-Changed-By: tnn@NetBSD.org
State-Changed-When: Tue, 15 Sep 2015 16:27:44 +0000
State-Changed-Why:
candidate patch: http://www.netbsd.org/~tnn/pr50243-egl-plist-fix.diff.txt


From: =?ISO-8859-15?Q?J=F6rn_Clausen?= <joern.clausen@uni-bielefeld.de>
To: gnats-bugs@NetBSD.org
Cc: tnn@NetBSD.org, pkg-manager@NetBSD.org, pkgsrc-bugs@NetBSD.org,
 gnats-admin@NetBSD.org
Subject: Re: pkg/50243 (graphics/libepoxy and option EGL from MesaLib)
Date: Wed, 16 Sep 2015 13:26:39 +0200

 Hi!

 > candidate patch: http://www.netbsd.org/~tnn/pr50243-egl-plist-fix.diff.txt

 I have checked the patches against libepoxy and MesaLib and with

 PKG_OPTIONS.MesaLib = -dri -llvm

 on NetBSD 7.0 RC2. Both packages built fine.

 Joern

 -- 
 Jörn Clausen
 Plattformen & Serverdienste
 Hochschulrechenzentrum

 Universität Bielefeld
 Universitätsstraße 25
 33615 Bielefeld
 Telefon: +49 521 106-12601
 E-Mail: joern.clausen@uni-bielefeld.de

 http://www.uni-bielefeld.de/hrz

From: "Tobias Nygren" <tnn@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/50243 CVS commit: pkgsrc
Date: Wed, 16 Sep 2015 12:28:53 +0000

 Module Name:	pkgsrc
 Committed By:	tnn
 Date:		Wed Sep 16 12:28:53 UTC 2015

 Modified Files:
 	pkgsrc/graphics/MesaLib: buildlink3.mk
 	pkgsrc/graphics/libepoxy: Makefile
 	pkgsrc/multimedia/libva: Makefile
 	pkgsrc/x11/qt5-qtbase: Makefile

 Log Message:
 PR pkg/50243: PLIST fix when X11_TYPE=modular and PKG_OPTIONS.MesaLib=-dri
 ok gdt@


 To generate a diff of this commit:
 cvs rdiff -u -r1.52 -r1.53 pkgsrc/graphics/MesaLib/buildlink3.mk
 cvs rdiff -u -r1.9 -r1.10 pkgsrc/graphics/libepoxy/Makefile
 cvs rdiff -u -r1.8 -r1.9 pkgsrc/multimedia/libva/Makefile
 cvs rdiff -u -r1.25 -r1.26 pkgsrc/x11/qt5-qtbase/Makefile

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: feedback->closed
State-Changed-By: tnn@NetBSD.org
State-Changed-When: Wed, 16 Sep 2015 12:31:39 +0000
State-Changed-Why:
fix applied


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.