summaryrefslogtreecommitdiff
path: root/Mk/bsd.port.mk
diff options
context:
space:
mode:
authorSatoshi Asami <asami@FreeBSD.org>1997-01-25 02:45:09 +0000
committerSatoshi Asami <asami@FreeBSD.org>1997-01-25 02:45:09 +0000
commitbd3f2af640293a0c95d6ec2a15eac6dd40ad175b (patch)
tree7e250a00a96f9ddc86bff0f6f37941e93e2fc6c2 /Mk/bsd.port.mk
parentupdate kaffe to 0.7.1. (diff)
(1) Add ${DESTDIR} to ${LOCALBASE} and ${X11BASE}, and remove it from
${PORTSDIR}. This undoes the changes done in rev. 1.38 and 1.59 (part of the bsd.port.mk pre-dawn ages I've never understood). Requested by: jkh (2) Add new variable NO_IGNORE that will override any IGNORE causes. This is just a little hack to allow building of REQUIRES_MOTIF ports and its dependencies only etc., so don't document it. (3) Update +REQUIRED_BY files as necessary. Now you should be able to delete ports that have runtime dependencies without pkg_delete complaining about this file missing.
Notes
Notes: svn path=/head/; revision=5434
Diffstat (limited to 'Mk/bsd.port.mk')
-rw-r--r--Mk/bsd.port.mk20
1 files changed, 15 insertions, 5 deletions
diff --git a/Mk/bsd.port.mk b/Mk/bsd.port.mk
index 72cf27015608..2bbdd4113f24 100644
--- a/Mk/bsd.port.mk
+++ b/Mk/bsd.port.mk
@@ -265,12 +265,12 @@ OPSYS!= uname -s
# tree we are and thus can't go relative. They can, of course, be overridden
# by individual Makefiles or local system make configuration.
.if (${OPSYS} == "NetBSD")
-PORTSDIR?= ${DESTDIR}/usr/opt
+PORTSDIR?= /usr/opt
.else
-PORTSDIR?= ${DESTDIR}/usr/ports
+PORTSDIR?= /usr/ports
.endif
-LOCALBASE?= /usr/local
-X11BASE?= /usr/X11R6
+LOCALBASE?= ${DESTDIR}/usr/local
+X11BASE?= ${DESTDIR}/usr/X11R6
DISTDIR?= ${PORTSDIR}/distfiles
_DISTDIR?= ${DISTDIR}/${DIST_SUBDIR}
PACKAGES?= ${PORTSDIR}/packages
@@ -655,6 +655,7 @@ _MANPAGES:= ${_MANPAGES:S/$/.gz/}
# Don't build a port if it's broken.
################################################################
+.if !defined(NO_IGNORE)
.if (defined(IS_INTERACTIVE) && defined(BATCH))
IGNORE= "is an interactive port"
.elif (!defined(IS_INTERACTIVE) && defined(INTERACTIVE))
@@ -696,6 +697,7 @@ install:
package:
@${IGNORECMD}
.endif
+.endif
.if defined(ALL_HOOK)
all:
@@ -1473,7 +1475,7 @@ misc-depends:
clean-depends:
.if defined(FETCH_DEPENDS) || defined(BUILD_DEPENDS) || defined(LIB_DEPENDS) \
|| defined(RUN_DEPENDS)
- @for dir in `${ECHO} ${FETCH_DEPENDS} ${BUILD_DEPENDS} ${LIB_DEPENDS} ${RUN_DEPENDS} | ${TR} '\040' '\012' | ${SED} -e 's/.*://' | sort | uniq`; do \
+ @for dir in `${ECHO} ${FETCH_DEPENDS} ${BUILD_DEPENDS} ${LIB_DEPENDS} ${RUN_DEPENDS} | ${TR} '\040' '\012' | ${SED} -e 's/.*://' | sort -u`; do \
if [ -d $$dir ] ; then \
(cd $$dir; ${MAKE} NOCLEANDEPENDS=yes clean clean-depends); \
fi \
@@ -1597,6 +1599,14 @@ fake-pkg:
if [ -f ${PKGDIR}/REQ ]; then \
${CP} ${PKGDIR}/REQ ${PKG_DBDIR}/${PKGNAME}/+REQ; \
fi; \
+ for dep in `make package-depends | sort -u`; do \
+ if [ -d ${PKG_DBDIR}/$$dep ]; then \
+ if ! ${GREP} ^${PKGNAME}$$ ${PKG_DBDIR}/$$dep/+REQUIRED_BY \
+ >/dev/null 2>&1; then \
+ ${ECHO} ${PKGNAME} >> ${PKG_DBDIR}/$$dep/+REQUIRED_BY; \
+ fi; \
+ fi; \
+ done; \
else \
${ECHO_MSG} "===> ${PKGNAME} is already installed - perhaps an older version?"; \
${ECHO_MSG} " If so, you may wish to \`\`pkg_delete ${PKGNAME}'' and install"; \