summaryrefslogtreecommitdiff
path: root/share/mk/bsd.man.mk
diff options
context:
space:
mode:
authorMichael Shalayeff <mickey@cvs.openbsd.org>2001-07-20 19:48:27 +0000
committerMichael Shalayeff <mickey@cvs.openbsd.org>2001-07-20 19:48:27 +0000
commitf306a2b49207a3896d25e5fbcbe3cbe3313d08a1 (patch)
treee92f16d9ddafd643641fdac10e94164303abb15e /share/mk/bsd.man.mk
parent53a62aec27bf2b212ce013e43261d03e569d10fb (diff)
undo broken changes, i dunno a fix for these; how many times you gonna repeat the same mistake espie@ and millert@ ?
Diffstat (limited to 'share/mk/bsd.man.mk')
-rw-r--r--share/mk/bsd.man.mk24
1 files changed, 16 insertions, 8 deletions
diff --git a/share/mk/bsd.man.mk b/share/mk/bsd.man.mk
index 24b78b22e63..5ec9adb58ae 100644
--- a/share/mk/bsd.man.mk
+++ b/share/mk/bsd.man.mk
@@ -1,4 +1,4 @@
-# $OpenBSD: bsd.man.mk,v 1.21 2001/07/19 23:16:17 espie Exp $
+# $OpenBSD: bsd.man.mk,v 1.22 2001/07/20 19:48:26 mickey Exp $
# $NetBSD: bsd.man.mk,v 1.23 1996/02/10 07:49:33 jtc Exp $
# @(#)bsd.man.mk 5.2 (Berkeley) 5/11/90
@@ -116,13 +116,21 @@ maninstall:
done
.endif
.if defined(MLINKS) && !empty(MLINKS)
-. for sub in ${MANSUBDIR}
-. for lnk file in ${MLINKS}
- @l=${DESTDIR}${MANDIR}${lnk:E}${sub}/${lnk:R}.0${MCOMPRESSSUFFIX}; \
- t=${DESTDIR}${MANDIR}${file:E}${sub}/${file:R}.0${MCOMPRESSSUFFIX}; \
- echo $$t -\> $$l; \
- rm -f $$t; ln $$l $$t;
-. endfor
+. for _subdir in ${MANSUBDIR}
+ @set ${MLINKS}; \
+ while test $$# -ge 2; do \
+ name=$$1; \
+ shift; \
+ dir=${DESTDIR}${MANDIR}$${name##*.}; \
+ l=$${dir}${_subdir}/$${name%.*}.0${MCOMPRESSSUFFIX}; \
+ name=$$1; \
+ shift; \
+ dir=${DESTDIR}${MANDIR}$${name##*.}; \
+ t=$${dir}${_subdir}/$${name%.*}.0${MCOMPRESSSUFFIX}; \
+ echo $$t -\> $$l; \
+ rm -f $$t; \
+ ln $$l $$t; \
+ done
. endfor
.endif