| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | # $NetBSD: Makefile,v 1.12 2010/04/19 18:46:15 tnn Exp $ | | 1 | # $NetBSD: Makefile,v 1.13 2010/04/19 18:49:30 tnn Exp $ |
2 | # | | 2 | # |
3 | | | 3 | |
4 | DISTNAME= libdrm-2.4.20 | | 4 | DISTNAME= libdrm-2.4.20 |
5 | CATEGORIES= x11 graphics | | 5 | CATEGORIES= x11 graphics |
6 | MASTER_SITES= http://dri.freedesktop.org/libdrm/ | | 6 | MASTER_SITES= http://dri.freedesktop.org/libdrm/ |
7 | EXTRACT_SUFX= .tar.bz2 | | 7 | EXTRACT_SUFX= .tar.bz2 |
8 | | | 8 | |
9 | MAINTAINER= joerg@NetBSD.org | | 9 | MAINTAINER= joerg@NetBSD.org |
10 | HOMEPAGE= http://dri.freedesktop.org/wiki/DRM | | 10 | HOMEPAGE= http://dri.freedesktop.org/wiki/DRM |
11 | COMMENT= Userspace interface to kernel DRM services | | 11 | COMMENT= Userspace interface to kernel DRM services |
12 | | | 12 | |
13 | PKG_DESTDIR_SUPPORT= user-destdir | | 13 | PKG_DESTDIR_SUPPORT= user-destdir |
14 | | | 14 | |
| @@ -16,25 +16,27 @@ USE_PKGLOCALEDIR= yes | | | @@ -16,25 +16,27 @@ USE_PKGLOCALEDIR= yes |
16 | USE_TOOLS+= pkg-config | | 16 | USE_TOOLS+= pkg-config |
17 | USE_LIBTOOL= yes | | 17 | USE_LIBTOOL= yes |
18 | PKGCONFIG_OVERRIDE+= libdrm.pc.in | | 18 | PKGCONFIG_OVERRIDE+= libdrm.pc.in |
19 | GNU_CONFIGURE= yes | | 19 | GNU_CONFIGURE= yes |
20 | | | 20 | |
21 | .include "../../mk/bsd.prefs.mk" | | 21 | .include "../../mk/bsd.prefs.mk" |
22 | | | 22 | |
23 | SUBST_CLASSES+= atomic | | 23 | SUBST_CLASSES+= atomic |
24 | SUBST_FILES.atomic= xf86drm.h | | 24 | SUBST_FILES.atomic= xf86drm.h |
25 | SUBST_MESSAGE.atomic= Configuring xf86drm.h's atomic operations. | | 25 | SUBST_MESSAGE.atomic= Configuring xf86drm.h's atomic operations. |
26 | SUBST_STAGE.atomic= pre-configure | | 26 | SUBST_STAGE.atomic= pre-configure |
27 | SUBST_VARS.atomic= ATOMIC_OPS_CHECK | | 27 | SUBST_VARS.atomic= ATOMIC_OPS_CHECK |
28 | | | 28 | |
29 | .if ${OPSYS} == "NetBSD" && exists(/usr/include/sys/atomic.h) | | | |
30 | ATOMIC_OPS_CHECK= 1 | | | |
31 | .else | | | |
32 | ATOMIC_OPS_CHECK= 0 | | 29 | ATOMIC_OPS_CHECK= 0 |
33 | .include "../../devel/libatomic_ops/buildlink3.mk" | | 30 | .if ${OPSYS} == "NetBSD" |
| | | 31 | . if exists(/usr/include/sys/atomic.h) |
| | | 32 | ATOMIC_OPS_CHECK= 1 |
| | | 33 | . else |
| | | 34 | . include "../../devel/libatomic_ops/buildlink3.mk" |
34 | CONFIGURE_ENV+= drm_cv_atomic_primitives=libatomic-ops | | 35 | CONFIGURE_ENV+= drm_cv_atomic_primitives=libatomic-ops |
| | | 36 | . endif |
35 | .endif | | 37 | .endif |
36 | | | 38 | |
37 | CONFIGURE_ARGS+= PTHREADSTUBS_CFLAGS=-I${PREFIX}/include \ | | 39 | CONFIGURE_ARGS+= PTHREADSTUBS_CFLAGS=-I${PREFIX}/include \ |
38 | PTHREADSTUBS_LIBS=-L${PREFIX}/lib | | 40 | PTHREADSTUBS_LIBS=-L${PREFIX}/lib |
39 | | | 41 | |
40 | .include "../../mk/bsd.pkg.mk" | | 42 | .include "../../mk/bsd.pkg.mk" |