aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorBryan Drewery <bdrewery@FreeBSD.org>2013-10-27 14:22:02 +0000
committerBryan Drewery <bdrewery@FreeBSD.org>2013-10-27 14:22:02 +0000
commit529249e0bbf7a521e0ac132782858dd032870aea (patch)
tree311afefe38aaf8e81c6a4000e4b622ddb019c8f1 /Makefile
parent793d69268d433f45045491136aa00c90a8dec8ce (diff)
downloadports-529249e0bbf7a521e0ac132782858dd032870aea.tar.gz
ports-529249e0bbf7a521e0ac132782858dd032870aea.zip
Notes
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile11
1 files changed, 6 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index 4ae3d399850f..82a6cb9b37da 100644
--- a/Makefile
+++ b/Makefile
@@ -105,11 +105,11 @@ INDEX_SHELL= /bin/sh
INDEX_PORTS=.
.endif
-#.if exists(/usr/libexec/make_index)
-#MAKE_INDEX= /usr/libexec/make_index /dev/stdin
-#.else
+.if exists(/usr/libexec/make_index)
+MAKE_INDEX= /usr/libexec/make_index /dev/stdin
+.else
MAKE_INDEX= perl ${.CURDIR}/Tools/make_index
-#.endif
+.endif
${INDEXDIR}/${INDEXFILE}:
@${INDEX_ECHO_1ST} "Generating ${INDEXFILE} - please wait.."; \
@@ -144,7 +144,8 @@ ${INDEXDIR}/${INDEXFILE}:
cat $${tmpdir}/${INDEXFILE}.desc.* | (cd ${.CURDIR} ; ${MAKE_INDEX}) | \
sed -e 's/ */ /g' -e 's/| */|/g' -e 's/ *|/|/g' -e 's./..g' | \
sort -t '|' +1 -2 | \
- sed -e 's../.g' > ${INDEXDIR}/${INDEXFILE}.tmp; \
+ sed -Ee 's../.g' -e ':a' -e 's|/[^/]+/\.\.||; ta' \
+ -e 's|${.CURDIR}|/usr/ports|g' > ${INDEXDIR}/${INDEXFILE}.tmp; \
if [ "${INDEX_PRISTINE}" != "" ]; then \
sed -e "s,$${LOCALBASE},/usr/local," ${INDEXDIR}/${INDEXFILE}.tmp > ${INDEXDIR}/${INDEXFILE}; \
else \