Tweak games/retroarch version 1.3.6
[dports.git] / graphics / libdrm / Makefile
1 # Created by: lesi@FreeBSD.org
2 # $FreeBSD$
3
4 PORTNAME=       libdrm
5 PORTVERSION=    2.4.66
6 PORTEPOCH=      1
7 CATEGORIES=     graphics x11
8 MASTER_SITES=   http://dri.freedesktop.org/libdrm/
9
10 MAINTAINER=     x11@FreeBSD.org
11 COMMENT=        Userspace interface to kernel Direct Rendering Module services
12
13 LIB_DEPENDS=    libpciaccess.so:devel/libpciaccess \
14                 libpthread-stubs.so:devel/libpthread-stubs
15
16 USES=           libtool pkgconfig tar:bzip2
17 GNU_CONFIGURE=  yes
18 USE_LDCONFIG=   yes
19 INSTALL_TARGET= install-strip
20
21 OPTIONS_DEFINE= MANPAGES
22
23 .if defined(PACKAGE_BUILDING)
24 OPTIONS_DEFAULT+=       MANPAGES
25 .endif
26
27 USES+=          gmake
28
29 .include <bsd.port.options.mk>
30
31 # KMS support in the kernel is only build on these archs, disable others
32 .if ${ARCH} == "x86_64" || ${ARCH} == "i386"
33 CONFIGURE_ARGS+=--enable-libkms
34 PLIST_SUB+=     KMS="" NOUVEAU=""
35 .else
36 CONFIGURE_ARGS+=--disable-libkms
37 PLIST_SUB+=     KMS="@comment " NOUVEAU="@comment "
38 .endif
39
40 .if ${PORT_OPTIONS:MMANPAGES}
41 BUILD_DEPENDS+= ${LOCALBASE}/share/xsl/docbook/manpages/docbook.xsl:textproc/docbook-xsl
42 USE_GNOME+=     libxslt:build
43 PLIST_SUB+=     MAN=""
44 .else
45 CONFIGURE_ARGS+=--disable-manpages
46 PLIST_SUB+=     MAN="@comment "
47 .endif
48
49 CONFIGURE_ARGS+=--disable-vmwgfx
50
51 .if ${ARCH} == x86_64 || ${ARCH} == i386
52 PLIST_SUB+=     INTEL_DRIVER=""
53 PLIST_SUB+=     RADEON_DRIVERS=""
54 .elif ${ARCH} == ia64 || ${ARCH} == powerpc || ${ARCH} == powerpc64
55 PLIST_SUB+=     INTEL_DRIVER="@comment "
56 PLIST_SUB+=     RADEON_DRIVERS=""
57 .else
58 PLIST_SUB+=     INTEL_DRIVER="@comment "
59 PLIST_SUB+=     RADEON_DRIVERS="@comment "
60 .endif
61
62 # This variable is not for users. So use a non-default name, intended for
63 # people working on DRM kernel module development.
64 .if !defined(LIBDRM_SKIP_RETURN_PATCH)
65 EXTRA_PATCHES+= ${FILESDIR}/extra-xf86drm.c
66 .endif
67
68 pre-patch:
69         @${REINPLACE_CMD} 's|{libdir}/pkgconfig|{prefix}/libdata/pkgconfig|g;' \
70                 ${WRKSRC}/configure
71
72 .include <bsd.port.mk>