summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwiz <wiz@pkgsrc.org>2000-11-02 03:01:40 +0000
committerwiz <wiz@pkgsrc.org>2000-11-02 03:01:40 +0000
commit7382d63dd07301688aa2f8930122a67425068339 (patch)
tree81e7b3b99fe66cbfe991110111a09fcff389f950
parent545d16621500dd1f2b34a49a3037e3e4fe884193 (diff)
downloadpkgsrc-7382d63dd07301688aa2f8930122a67425068339.tar.gz
Move USE_NCURSES stuff from bsd.pkg.mk to bsd.prefs.mk.
Do executable bit testing in bsd.pkg.mk, REPLACE_NCURSES, slightly different.
-rw-r--r--mk/bsd.pkg.mk30
-rw-r--r--mk/bsd.prefs.mk17
2 files changed, 22 insertions, 25 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk
index 501ea7a5397..bb897f1f8f0 100644
--- a/mk/bsd.pkg.mk
+++ b/mk/bsd.pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.595 2000/11/01 09:06:22 skrll Exp $
+# $NetBSD: bsd.pkg.mk,v 1.596 2000/11/02 03:01:40 wiz Exp $
#
# This file is in the public domain.
#
@@ -192,24 +192,8 @@ MAKE_ENV+= FC="${FC}"
USE_GTEXINFO= yes
.endif
-.if defined(USE_CURSES) && !defined(NEED_NCURSES)
-.if ${OPSYS} == "NetBSD"
-GOOD_CURSES= 1.4[YZ] 1.4Z[A-D] 1.[5-9]*
-NEED_NCURSES= YES
-.for PATTERN in ${GOOD_CURSES}
-.if ${OS_VERSION:M${PATTERN}} != ""
-NEED_NCURSES= NO
-.endif
-.endfor
-.else
-NEED_NCURSES= NO
-.endif
-# do _not_ pass NEED_NCURSES flag down, or we end up with recursive
-# dependency of ncurses on itself on <1.4Y.
-# MAKEFLAGS+= NEED_NCURSES=${NEED_NCURSES}
-.endif
-
-.if defined(NEED_NCURSES) && ${NEED_NCURSES} == "YES"
+.if defined(NEED_NCURSES) && ${NEED_NCURSES} == "YES" && \
+ ${PKGBASE} != "ncurses"
DEPENDS+= ncurses>=5.0:../../devel/ncurses
.endif
@@ -1459,11 +1443,9 @@ do-configure:
${_PKG_SILENT}${_PKG_DEBUG}cd ${WRKSRC}; if [ -f ${f} ]; then \
${SED} -e "s/ncurses/curses/g" ${f} > ${f}.new; \
if [ -x ${f} ]; then \
- ${MV} ${f}.new ${f}; \
- ${CHMOD} a+x ${f}; \
- else \
- ${MV} ${f}.new ${f}; \
- fi \
+ ${CHMOD} a+x ${f}.new; \
+ fi; \
+ ${MV} ${f}.new ${f}; \
fi
.endfor
.endif
diff --git a/mk/bsd.prefs.mk b/mk/bsd.prefs.mk
index 29b13915eac..c33fb8a5464 100644
--- a/mk/bsd.prefs.mk
+++ b/mk/bsd.prefs.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.prefs.mk,v 1.18 2000/10/15 11:31:42 rh Exp $
+# $NetBSD: bsd.prefs.mk,v 1.19 2000/11/02 03:01:40 wiz Exp $
#
# Make file, included to get the site preferences, if any. Should
# only be included by package Makefiles before any .if defined()
@@ -126,4 +126,19 @@ HAVE_BUILTIN_MESA= YES
.undef __BUILTIN_MESA
.endif # CHECK_MESA
+.if defined(USE_CURSES) && !defined(NEED_NCURSES)
+NEED_NCURSES= NO
+.if ${OPSYS} == "NetBSD"
+_INCOMPAT_CURSES= 0.* 1.[0123]* 1.4.* 1.4[A-X]
+.for PATTERN in ${_INCOMPAT_CURSES}
+.if ${OS_VERSION:M${PATTERN}} != ""
+NEED_NCURSES= YES
+.endif
+.endfor
+.endif
+# we can pass the flag down without recursive dependency of ncurses
+# on itself, because it's explicitly tested in bsd.pkg.mk
+MAKEFLAGS+= NEED_NCURSES=${NEED_NCURSES}
+.endif # USE_CURSES
+
.endif # BSD_PKG_MK