summaryrefslogtreecommitdiff
path: root/graphics/MesaLib7/buildlink3.mk
blob: 46480e3e7bd8f89abe0d305e1e73291fccac91ef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# $NetBSD: buildlink3.mk,v 1.3 2018/01/07 13:04:12 rillig Exp $

BUILDLINK_TREE+=	MesaLib7

.if !defined(MESALIB7_BUILDLINK3_MK)
MESALIB7_BUILDLINK3_MK:=

BUILDLINK_API_DEPENDS.MesaLib7+=	MesaLib7>=7.11.2
BUILDLINK_PKGSRCDIR.MesaLib7?=		../../graphics/MesaLib7
BUILDLINK_FNAME_TRANSFORM.MesaLib7+=	-e 's|MesaLib7/||'
BUILDLINK_RPATHDIRS+=			MesaLib7/lib

.include "../../mk/bsd.fast.prefs.mk"

# See <http://developer.apple.com/qa/qa2007/qa1567.html>.
.if !empty(MACHINE_PLATFORM:MDarwin-[9].*-*)
BUILDLINK_LDFLAGS.MesaLib7+=	-Wl,-dylib_file,/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib:/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib
.endif

pkgbase:= MesaLib7
.include "../../mk/pkg-build-options.mk"

.if ${X11_TYPE} == "native" && ${OPSYS} != "Cygwin" && exists(${X11BASE}/lib/pkgconfig/dri.pc)
PKG_BUILD_OPTIONS.MesaLib7+=	dri
.endif

.if !empty(PKG_BUILD_OPTIONS.MesaLib7:Mdri)
.  include "../../graphics/MesaLib/dri.mk"
.endif

.if !empty(MACHINE_PLATFORM:MNetBSD-[12].*)
.include "../../devel/pthread-stublib/buildlink3.mk"
.endif

.include "../../x11/libXext/buildlink3.mk"
.endif # MESALIB7_BUILDLINK3_MK

BUILDLINK_TREE+=	-MesaLib7