summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorhubertf <hubertf@pkgsrc.org>1999-08-22 01:30:15 +0000
committerhubertf <hubertf@pkgsrc.org>1999-08-22 01:30:15 +0000
commitdc3aa46cc2cafda06c36af06303ac7763fe77ed2 (patch)
treef4434c10b9cc33d0ae79ca1c0474ce9dcc6930e9 /Makefile
parent58dd80e8d7fa515262b0eb9f8f647d983e6b6f2a (diff)
downloadpkgsrc-dc3aa46cc2cafda06c36af06303ac7763fe77ed2.tar.gz
Collect information from pkgsrc/*/README.html into one long list
(README-all.html), and reference this file.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile39
1 files changed, 38 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index d3b562f6df0..6b48f7d792a 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.24 1999/06/06 19:33:17 frueauf Exp $
+# $NetBSD: Makefile,v 1.25 1999/08/22 01:30:15 hubertf Exp $
# FreeBSD Id: Makefile,v 1.35 1997/08/19 07:10:01 fenner Exp
#
@@ -78,3 +78,40 @@ search: ${.CURDIR}/INDEX
@grep ${key} ${.CURDIR}/INDEX | awk -F\| '{ printf("Port:\t%s\nPath:\t%s\nInfo:\t%s\nMaint:\t%s\nIndex:\t%s\nB-deps:\t%s\nR-deps:\t%s\nArch:\t%s\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9, $$10); }'
.endif
+
+#
+# Generate list of all packages by extracting information from
+# the category/README.html pages
+#
+readme-all:
+ @mv README-all.html README-all.html.BAK
+ @${MAKE} README-all.html
+ @if cmp -s README-all.html README-all.html.BAK ; then \
+ mv README-all.html.BAK README-all.html ; \
+ else \
+ rm -f README-all.html.BAK ; \
+ fi
+
+README-all.html:
+ @rm -f $@.new
+ @rm -f $@.newsorted
+ @echo -n "Processing categories for $@:"
+.for category in ${SUBDIR}
+ @if [ -f ${category}/README.html ]; then \
+ echo -n ' ${category}' ; \
+ grep '^<TR>' ${category}/README.html \
+ | sed -e 's|"|"${category}/|' \
+ -e 's| <TD>| <TD>(<A HREF="${category}/README.html">${category}</A>) <TD>|' \
+ -e 's|<TR>|<TR VALIGN=TOP>|' \
+ >> $@.new ; \
+ fi
+.endfor
+ @echo "."
+ @sort -t '">' +2 <$@.new >$@.newsorted
+ @cat templates/README.all \
+ | ${SED} \
+ -e '/%%PKGS%%/r$@.newsorted' \
+ -e '/%%PKGS%%/d' \
+ > $@
+ @rm -f $@.new
+ @rm -f $@.newsorted