pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/mk Provided a useful error message for the case that X...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/2ceaca358f95
branches:  trunk
changeset: 521663:2ceaca358f95
user:      rillig <rillig%pkgsrc.org@localhost>
date:      Fri Nov 17 09:50:54 2006 +0000

description:
Provided a useful error message for the case that X11_TYPE is set to
something else than { xorg native }. According to the error reports on
pkgsrc-users, many have still X11_TYPE=XFree86.

diffstat:

 mk/x11.buildlink3.mk |  21 +++++++++++++++++----
 1 files changed, 17 insertions(+), 4 deletions(-)

diffs (40 lines):

diff -r a81a904b4935 -r 2ceaca358f95 mk/x11.buildlink3.mk
--- a/mk/x11.buildlink3.mk      Fri Nov 17 09:19:37 2006 +0000
+++ b/mk/x11.buildlink3.mk      Fri Nov 17 09:50:54 2006 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: x11.buildlink3.mk,v 1.5 2006/10/26 17:08:08 rillig Exp $
+# $NetBSD: x11.buildlink3.mk,v 1.6 2006/11/17 09:50:54 rillig Exp $
 #
 # This Makefile fragment is meant to be included by packages that
 # require an X11 distribution.  x11.buildlink3.mk will include the
@@ -7,10 +7,21 @@
 
 X11_BUILDLINK3_MK:=    ${X11_BUILDLINK3_MK}+
 
-.include "../../mk/bsd.prefs.mk"
+.if ${X11_BUILDLINK3_MK} == "+"
+USE_X11=       yes
+
+.  include "../../mk/bsd.prefs.mk"
 
-.if !empty(X11_BUILDLINK3_MK:M+)
-USE_X11=       yes
+#
+# Sanity checks.
+#
+
+.  if ${X11_TYPE} != "native" && ${X11_TYPE} != "xorg"
+_WRONG_X11_TYPE:=      ${X11_TYPE}
+PKG_FAIL_REASON+=      "[x11.version.mk] X11_TYPE must either be \"xorg\" or \"native\", but not \"${_WRONG_X11_TYPE:Q}\"."
+X11_TYPE:=             native
+X11BASE:=              /usr
+.  endif
 
 .  include "../../mk/x11.version.mk"
 
@@ -24,3 +35,5 @@
 .endif # X11_BUILDLINK3_MK
 
 .include "${X11_PKGSRCDIR.${X11_TYPE}}/buildlink3.mk"
+
+X11_BUILDLINK3_MK:=    ${X11_BUILDLINK3_MK:S/+$//}



Home | Main Index | Thread Index | Old Index