Date: Sat, 20 Jun 2015 00:13:29 +0000 (UTC) From: Baptiste Daroussin <bapt@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r284619 - head/share/doc/usd/13.viref Message-ID: <201506200013.t5K0DTxn051917@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: bapt Date: Sat Jun 20 00:13:28 2015 New Revision: 284619 URL: https://svnweb.freebsd.org/changeset/base/284619 Log: Readd merge.awk forgotten while importing the old vi documentation directly into the tree. Do not rely on SRCDIR to find the merge.awk script but use .CURDIR Fix a long standing bug making the generated documents never including the index Added: head/share/doc/usd/13.viref/merge.awk (contents, props changed) Modified: head/share/doc/usd/13.viref/Makefile Modified: head/share/doc/usd/13.viref/Makefile ============================================================================== --- head/share/doc/usd/13.viref/Makefile Sat Jun 20 00:02:03 2015 (r284618) +++ head/share/doc/usd/13.viref/Makefile Sat Jun 20 00:13:28 2015 (r284619) @@ -2,7 +2,6 @@ # $FreeBSD$ VOLUME= usd/13.viref -SRCS= vi.ref-patched EXTRA= ex.cmd.roff ref.so set.opt.roff vi.cmd.roff MACROS= -me CLEANFILES= vi.ref-patched index @@ -15,18 +14,22 @@ vi.ref-patched: vi.ref PRINTERDEVICE?= ascii .for _dev in ${PRINTERDEVICE} +SRCS+= vi.ref-${_dev} EXTRA+= index.so.${_dev} -CLEANFILES+= index.so.${_dev} +CLEANFILES+= index.so.${_dev} vi.ref-${_dev} + +vi.ref-${_dev}: index.so.${_dev} + sed -e 's:^\.so index\.so\.\\\*\[\.T\]$$:${_dev}:' vi.ref-patched > ${.TARGET} # Build index.so as a side-effect of building the paper. -index.so.${_dev}: ${SRCS} ${EXTRA:Nindex.so.${_dev}} +index.so.${_dev}: vi.ref-patched ${EXTRA:Nindex.so.${_dev}} sed -e 's:^\.so index\.so\.\\\*\[\.T\]$$::' vi.ref-patched | \ ${ROFF.${_dev}} -U -z sed -e 's/MINUSSIGN/-/' \ -e 's/DOUBLEQUOTE/""/' \ -e "s/SQUOTE/'/" \ -e 's/ /__SPACE/g' < index | \ - sort -u '-t ' -k 1,1 -k 2n | awk -f ${SRCDIR}/merge.awk | \ + sort -u '-t ' -k 1,1 -k 2n | awk -f ${.CURDIR}/merge.awk | \ sed -e 's/__SPACE/ /g' \ -e "s/^\\(['\\.]\\)/\\\\\&\\1/" > ${.TARGET} .endfor Added: head/share/doc/usd/13.viref/merge.awk ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/share/doc/usd/13.viref/merge.awk Sat Jun 20 00:13:28 2015 (r284619) @@ -0,0 +1,17 @@ +# $FreeBSD$ +# @(#)merge.awk 8.3 (Berkeley) 5/25/94 +# +# merge index entries into one line per label +$1 == prev { + printf ", %s", $2; + next; +} +{ + if (NR != 1) + printf "\n"; + printf "%s \t%s", $1, $2; + prev = $1; +} +END { + printf "\n" +}
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201506200013.t5K0DTxn051917>