summaryrefslogtreecommitdiff
path: root/x11
diff options
context:
space:
mode:
authorwiz <wiz@pkgsrc.org>2005-03-05 18:16:21 +0000
committerwiz <wiz@pkgsrc.org>2005-03-05 18:16:21 +0000
commit8a95eb450573436053fe8a1307dcff3f6bdc786e (patch)
tree27a2e01a3237611b8dd40c17375bcb0442cc37e9 /x11
parent5c8006c83dad253c5ed0a6a7bc636c524cdc4348 (diff)
downloadpkgsrc-8a95eb450573436053fe8a1307dcff3f6bdc786e.tar.gz
Instead of disabling the randrext and Xrandr packages on systems
which have no extutil.h header file, just make them depend on the xextensions package which provides it. Bump PKGREVISION for Xrandr and randrext. Add builtin.mk file for xextensions. jlam says ok.
Diffstat (limited to 'x11')
-rw-r--r--x11/Xrandr-mixedcase/Makefile17
-rw-r--r--x11/randrext/Makefile14
-rw-r--r--x11/randrext/buildlink3.mk4
-rw-r--r--x11/xextensions/builtin.mk46
4 files changed, 57 insertions, 24 deletions
diff --git a/x11/Xrandr-mixedcase/Makefile b/x11/Xrandr-mixedcase/Makefile
index 1548a61d27e..08c8efb0f77 100644
--- a/x11/Xrandr-mixedcase/Makefile
+++ b/x11/Xrandr-mixedcase/Makefile
@@ -1,9 +1,9 @@
-# $NetBSD: Makefile,v 1.9 2004/10/03 00:18:28 tv Exp $
+# $NetBSD: Makefile,v 1.10 2005/03/05 18:16:21 wiz Exp $
#
DISTNAME= libXrandr-1.0.2
PKGNAME= Xrandr-1.0.2
-PKGREVISION= 1
+PKGREVISION= 2
CATEGORIES= x11 devel
MASTER_SITES= http://freedesktop.org/~xlibs/release/
EXTRACT_SUFX= .tar.bz2
@@ -21,17 +21,10 @@ GNU_CONFIGURE= yes
PKGCONFIG_OVERRIDE+= xrandr.pc.in
BUILDLINK_DEPENDS.Xrender+= Xrender>=0.8
+BUILDLINK_DEPENDS.randrext+= randrext>=1.0
-.include "../../mk/bsd.prefs.mk"
-
-# Xrandr won't build without the X Extension library which is only present
-# in XFree86>=4.3.
-.if !exists(${X11BASE}/include/X11/extensions/extutil.h)
-PKG_FAIL_REASON= "${PKGNAME} won't build without the X Extension"
-PKG_FAIL_REASON+= "library which is only present in XFree86>=4.3."
-.endif
-
-.include "../../x11/randrext/buildlink3.mk"
.include "../../x11/Xrender/buildlink3.mk"
+.include "../../x11/randrext/buildlink3.mk"
+.include "../../x11/xextensions/buildlink3.mk"
.include "../../devel/pkgconfig/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/x11/randrext/Makefile b/x11/randrext/Makefile
index 32b0950a6c1..c025ca32eeb 100644
--- a/x11/randrext/Makefile
+++ b/x11/randrext/Makefile
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.8 2004/05/07 01:14:51 xtraeme Exp $
+# $NetBSD: Makefile,v 1.9 2005/03/05 18:16:21 wiz Exp $
DISTNAME= randrext-1.0
+PKGREVISION= 1
CATEGORIES= x11 devel
MASTER_SITES= http://freedesktop.org/~xlibs/release/
EXTRACT_SUFX= .tar.bz2
@@ -16,14 +17,5 @@ GNU_CONFIGURE= yes
PKGCONFIG_OVERRIDE+= randr.pc.in
-.include "../../mk/bsd.prefs.mk"
-
-# Xrandr won't build without the X Extension library which is only present
-# in XFree86>=4.3. For this reason we don't need the header files.
-.if !exists(${X11BASE}/include/X11/extensions/extutil.h)
-PKG_SKIP_REASON= "Xrandr won't build without the X Extension"
-PKG_SKIP_REASON+= "library which is only present in XFree86>=4.3."
-PKG_SKIP_REASON+= "For this reason we don't need the header files."
-.endif
-
+.include "../../x11/xextensions/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/x11/randrext/buildlink3.mk b/x11/randrext/buildlink3.mk
index c5c01ef3591..21a4efa2d03 100644
--- a/x11/randrext/buildlink3.mk
+++ b/x11/randrext/buildlink3.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink3.mk,v 1.3 2004/03/10 17:57:15 jlam Exp $
+# $NetBSD: buildlink3.mk,v 1.4 2005/03/05 18:16:21 wiz Exp $
BUILDLINK_DEPTH:= ${BUILDLINK_DEPTH}+
RANDREXT_BUILDLINK3_MK:= ${RANDREXT_BUILDLINK3_MK}+
@@ -15,6 +15,8 @@ BUILDLINK_DEPENDS.randrext+= randrext>=1.0
BUILDLINK_PKGSRCDIR.randrext?= ../../x11/randrext
BUILDLINK_DEPMETHOD.randrext?= build
+.include "../../x11/xextensions/buildlink3.mk"
+
USE_X11= yes
.endif # RANDREXT_BUILDLINK3_MK
diff --git a/x11/xextensions/builtin.mk b/x11/xextensions/builtin.mk
new file mode 100644
index 00000000000..ab0f16cae1b
--- /dev/null
+++ b/x11/xextensions/builtin.mk
@@ -0,0 +1,46 @@
+# $NetBSD: builtin.mk,v 1.1 2005/03/05 18:16:21 wiz Exp $
+
+_X11_EXTENSIONS_EXTUTIL_H= ${X11BASE}/include/X11/extensions/extutil.h
+
+.if !defined(IS_BUILTIN.xextensions)
+IS_BUILTIN.xextensions= no
+. if exists(${_X11_EXTENSIONS_EXTUTIL_H})
+IS_BUILTIN.xextensions= yes
+# hardcode version for now, since there currently is only one, really
+BUILTIN_PKG.xextensions= xextensions-1.0.1
+BUILDLINK_VARS+= BUILTIN_PKG.xextensions
+. endif
+BUILDLINK_VARS+= IS_BUILTIN.xextensions
+.endif # IS_BUILTIN.xextensions
+
+.if !defined(USE_BUILTIN.xextensions)
+USE_BUILTIN.xextensions?= ${IS_BUILTIN.xextensions}
+
+. if defined(BUILTIN_PKG.xextensions)
+USE_BUILTIN.xextensions= yes
+. for _depend_ in ${BUILDLINK_DEPENDS.xextensions}
+. if !empty(USE_BUILTIN.xextensions:M[yY][eE][sS])
+USE_BUILTIN.xextensions!= \
+ if ${PKG_ADMIN} pmatch '${_depend_}' ${BUILTIN_PKG.xextensions}; then \
+ ${ECHO} "yes"; \
+ else \
+ ${ECHO} "no"; \
+ fi
+. endif
+. endfor
+. endif
+.endif # USE_BUILTIN.xextensions
+
+CHECK_BUILTIN.xextensions?= no
+.if !empty(CHECK_BUILTIN.xextensions:M[nN][oO])
+
+.if !empty(USE_BUILTIN.xextensions:M[nN][oO])
+BUILDLINK_DEPENDS.xextensions+= xextensions>=1.0
+.endif
+
+.if !empty(USE_BUILTIN.xextensions:M[yY][eE][sS])
+BUILDLINK_PREFIX.xextensions= ${X11BASE}
+USE_X11= yes
+.endif
+
+.endif # CHECK_BUILTIN.xextensions