...long live groff

This commit is contained in:
Paul Traina 1996-09-08 01:27:58 +00:00
parent e72c5689b0
commit f7c160386a
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=18140
38 changed files with 833 additions and 0 deletions

View file

@ -0,0 +1,16 @@
# Makefile for groff
#
# $Id$
SUBDIR= libgroff libdriver libbib \
addftinfo eqn \
grodvi groff grolj4 grops grotty \
indxbib lkbib lookbib man mm nroff \
pfbtops pic psbb refer tbl tfmtodit tmac troff \
devX100 devX100-12 devX75 devX75-12 devascii devdvi \
devlatin1 devkoi8-r devlj4 devps
# BSD already provides soelim and we don't want xditview compiled be default
MISC= soelim afmtodit doc grog hpftodit xditview
.include <bsd.subdir.mk>

View file

@ -0,0 +1,132 @@
# $Id: Makefile.cfg,v 1.10 1996/06/24 04:22:58 jkh Exp $
BINDIR?= /usr/bin
SHELL= /bin/sh
# Define `page' to be letter if your PostScript printer uses 8.5x11
# paper (USA) and define it to be A4, if it uses A4 paper (rest of the
# world).
PAGE=letter
# Normally the Postscript driver, grops, produces output that conforms
# to version 3.0 of the Adobe Document Structuring Conventions.
# Unfortunately some spoolers and previewers can't handle such output.
# The BROKEN_SPOOLER_FLAGS variable tells grops what it should do to
# make its output acceptable to such programs. This variable controls
# only the default behaviour of grops; the behaviour can be changed at
# runtime by the grops -b option (and so by groff -P-b).
# Use a value of 0 if your spoolers and previewers are able to handle
# conforming PostScript correctly.
# Add 1 if no %%{Begin,End}DocumentSetup comments should be generated;
# this is needed for early versions of TranScript that get confused by
# anything between the %%EndProlog line and the first %%Page: comment.
# Add 2 if lines in included files beginning with %! should be
# stripped out; this is needed for the OpenWindows 2.0 pageview previewer.
# Add 4 if %%Page, %%Trailer and %%EndProlog comments should be
# stripped out of included files; this is needed for spoolers that
# don't understand the %%{Begin,End}Document comments. I suspect this
# includes early versions of TranScript.
# Add 8 if the first line of the PostScript output should be %!PS-Adobe-2.0
# rather than %!PS-Adobe-3.0; this is needed when using Sun's Newsprint
# with a printer that requires page reversal.
BROKEN_SPOOLER_FLAGS=7
# PSPRINT is the command to use for printing a PostScript file,
# for example `lpr'.
PSPRINT=lpr
# DVIPRINT is the command to use for printing a TeX dvi file,
# for example `lpr -d'.
DVIPRINT=lpr -d
########################################################################
# Don't touch...
g=
tmac_s=s
tmac_m=m
device=ps
fontdir=/usr/share/groff_font
fontpath=$(fontdir)
tmacdir=/usr/share/tmac
tmacpath=$(tmacdir)
indexext=.i
common_words_file=/usr/share/dict/eign
indexdir=/usr/share/dict/papers
indexname=Ind
########################################################################
# Libraries
# Bad assumption, if one exists they all exist
.if exists(${.OBJDIR}/../libgroff)
LIBGROFF= $(.OBJDIR)/../libgroff/libgroff.a
LIBDRIVER= $(.OBJDIR)/../libdriver/libdriver.a
LIBBIB= $(.OBJDIR)/../libbib/libbib.a
.else
LIBGROFF= $(.CURDIR)/../libgroff/libgroff.a
LIBDRIVER= $(.CURDIR)/../libdriver/libdriver.a
LIBBIB= $(.CURDIR)/../libbib/libbib.a
.endif
DEFINES= -DHAVE_UNISTD_H=1\
-DHAVE_DIRENT_H=1\
-DHAVE_LIMITS_H=1\
-DHAVE_SYS_DIR_H=1\
-DHAVE_STDLIB_H=1\
-DSTDLIB_H_DECLARES_GETOPT=1\
-DSTDLIB_H_DECLARES_PUTENV=1\
-DSTDIO_H_DECLARES_POPEN=1\
-DSTDIO_H_DECLARE_PCLOSE=1\
-DHAVE_CC_OSFCN_H=1\
-DHAVE_CC_LIMITS_H=1\
-DRETSIGTYPE=void\
-DHAVE_STRUCT_EXCEPTION=1\
-DHAVE_RENAME=1\
-DHAVE_MKSTEMP=1\
-DSYS_SIGLIST_DECLARED=1
INCLUDES= -I$(GROFF_DIST)/include -I$(.CURDIR)/include
CFLAGS+=$(DEFINES) $(INCLUDES)
.y.o:
$(YACC) $(YFLAGS) $(.IMPSRC)
mv -f y.tab.c $(.PREFIX).cc
mv -f y.tab.h $(.PREFIX).tab.h
${CXX} ${CXXFLAGS} -c $(.PREFIX).cc -o ${.TARGET}
.y.cc:
$(YACC) $(YFLAGS) $(.IMPSRC)
mv -f y.tab.c $(.PREFIX).cc
mv -f y.tab.h $(.PREFIX).tab.h
.SUFFIXES: .man .1 .2 .3 .4 .5 .6 .7 .8
#.8.man .7.man .6.man .5.man .4.man .3.man .2.man .1.man:
.man.8 .man.7 .man.6 .man.5 .man.4 .man.3 .man.2 .man.1:
@${ECHO} Making $@ from $<
@-rm -f $@
@sed -e "s;@FONTDIR@;$(fontdir);g" \
-e "s;@FONTPATH@;$(fontpath);g" \
-e "s;@MACRODIR@;$(tmacdir);g" \
-e "s;@MACROPATH@;$(tmacpath);g" \
-e "s;@DEVICE@;$(device);g" \
-e "s;@DEFAULT_INDEX@;$(indexdir)/$(indexname);g" \
-e "s;@DEFAULT_INDEX_NAME@;$(indexname);g" \
-e "s;@INDEX_SUFFIX@;$(indexext);g" \
-e "s;@COMMON_WORDS_FILE@;$(common_words_file);g" \
-e "s;@MAN1EXT@;1;g" \
-e "s;@MAN5EXT@;5;g" \
-e "s;@MAN7EXT@;7;g" \
-e "s;@TMAC_S@;$(tmac_s);g" \
-e "s;@TMAC_M@;$(tmac_m);g" \
-e "s;@TMAC_MDIR@;$(tmacdir)/mm;g" \
-e "s;@BROKEN_SPOOLER_FLAGS@;$(BROKEN_SPOOLER_FLAGS);g" \
-e "s;@VERSION@;`cat ${GROFF_DIST}/VERSION`;g" \
-e "s;@MDATE@;`$(SHELL) ${GROFF_DIST}/mdate.sh $<`;g" \
-e "s;@g@;$(g);g" \
-e "s;@G@;`echo $(g) | tr [a-z] [A-Z]`;g" \
$< >$@
MANSRC=${.OBJDIR}

View file

@ -0,0 +1,33 @@
# @(#)Makefile.dev 6.2 (Berkeley) 3/16/91
# Client Makefiles define DEV and DEVFILES and provide rules for
# individual font files
#
# $Id$
.include "../Makefile.cfg"
FONTDIR?= /usr/share/groff_font
DEVICEDIR?= $(FONTDIR)/dev$(DEV)
FONTOWN?= bin
FONTGRP?= bin
FONTMODE?= 444
all: $(DEVFILES)
.for f in $(DEVFILES)
.if exists(${.OBJDIR}/$f)
beforeinstall:: ${.OBJDIR}/$f
$(INSTALL) -c -o $(FONTOWN) -g $(FONTGRP) -m $(FONTMODE) \
${.OBJDIR}/$f $(DESTDIR)$(DEVICEDIR)
.elif exists(${.CURDIR}/$f)
beforeinstall:: ${.CURDIR}/$f
$(INSTALL) -c -o $(FONTOWN) -g $(FONTGRP) -m $(FONTMODE) \
${.CURDIR}/$f $(DESTDIR)$(DEVICEDIR)
.else
beforeinstall:: $(DISTDIR)/$f
$(INSTALL) -c -o $(FONTOWN) -g $(FONTGRP) -m $(FONTMODE) \
$(DISTDIR)/$f $(DESTDIR)$(DEVICEDIR)
.endif
.endfor
.include <bsd.prog.mk>

View file

@ -0,0 +1,55 @@
# @(#)Makefile.tty 6.1 (Berkeley) 3/3/91
#
# Modified for Berkeley Unix by Donn Seeley, donn@okeeffe.berkeley.edu
#
#Copyright (C) 1989, 1990 Free Software Foundation, Inc.
# Written by James Clark (jjc@jclark.uucp)
#
#This file is part of groff.
#
#groff is free software; you can redistribute it and/or modify it under
#the terms of the GNU General Public License as published by the Free
#Software Foundation; either version 1, or (at your option) any later
#version.
#
#groff is distributed in the hope that it will be useful, but WITHOUT ANY
#WARRANTY; without even the implied warranty of MERCHANTABILITY or
#FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
#for more details.
#
#You should have received a copy of the GNU General Public License along
#with groff; see the file LICENSE. If not, write to the Free Software
#Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
.MAIN: all
RES=240
CPI=10
LPI=6
FONTS=R I B BI S L
DEVFILES=$(FONTS) DESC
CLEANFILES=$(DEVFILES)
$(FONTS): R.proto
@${ECHO} Making $@
@(charwidth=`echo $(RES) / $(CPI) | bc` ; \
sed -e "s/^name [A-Z]*$$/name $@/" \
-e "s/^\\([^ ]*\\) [0-9]+ /\\1 $$charwidth /" \
-e "s/^spacewidth [0-9]+$$/spacewidth $$charwidth/" \
-e "s/^internalname .*$$/internalname $@/" \
-e "/^internalname/s/BI/3/" \
-e "/^internalname/s/B/2/" \
-e "/^internalname/s/I/1/" \
-e "/^internalname .*[^ 0-9]/d" \
${DISTDIR}/R.proto >$@)
DESC: DESC.proto
@${ECHO} Making $@
@sed -e "s/^res .*$$/res $(RES)/" \
-e "s/^hor .*$$/hor `echo $(RES) / $(CPI) | bc`/" \
-e "s/^vert .*$$/vert `echo $(RES) / $(LPI) | bc`/" \
-e "s/^fonts .*$$/fonts `set $(FONTS); echo $$#` $(FONTS)/" \
${DISTDIR}/DESC.proto >$@
beforeinstall:: ${DEVFILES}

View file

@ -0,0 +1,13 @@
# Makefile for addftinfo
PROG= addftinfo
SRCS= addftinfo.cc guess.cc
#CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBGROFF}
DPADD+= ${LIBGROFF}
MANDEPEND= addftinfo.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,7 @@
# $Id$
#
# Generic groff font makefile
#
.include "${.CURDIR}/../Makefile.inc"
.include "${DISTDIR}/Makefile.sub"
.include "${.CURDIR}/../Makefile.dev"

View file

@ -0,0 +1,7 @@
# $Id$
#
# Generic groff font makefile
#
.include "${.CURDIR}/../Makefile.inc"
.include "${DISTDIR}/Makefile.sub"
.include "${.CURDIR}/../Makefile.dev"

View file

@ -0,0 +1,7 @@
# $Id$
#
# Generic groff font makefile
#
.include "${.CURDIR}/../Makefile.inc"
.include "${DISTDIR}/Makefile.sub"
.include "${.CURDIR}/../Makefile.dev"

View file

@ -0,0 +1,7 @@
# $Id$
#
# Generic groff font makefile
#
.include "${.CURDIR}/../Makefile.inc"
.include "${DISTDIR}/Makefile.sub"
.include "${.CURDIR}/../Makefile.dev"

View file

@ -0,0 +1,7 @@
# Makefile for devascii
DEV= ascii
.include "../Makefile.inc"
.include "../Makefile.tty"
.include "../Makefile.dev"

View file

@ -0,0 +1,18 @@
DEV= dvi
FONTFILES= R I B BI CW MI S EX H HI HB SA SB DESC $(DEVGENFILES)
DEVGENFILES= generate/CompileFonts generate/Makefile generate/msam.map\
generate/msbm.map generate/texb.map generate/texex.map \
generate/texi.map generate/texmi.map generate/texr.map \
generate/texsy.map generate/textt.map generate/cork.map
CLEANFILES+= DESC
DEVFILES= $(FONTFILES)
.include "../Makefile.inc"
DESC: DESC.in
cat ${DISTDIR}/DESC.in >DESC
test -z '${DVIPRINT}' || echo print '${DVIPRINT}' >>DESC
.include "../Makefile.dev"

View file

@ -0,0 +1,6 @@
# Makefile for devkoi8-r
DEV= koi8-r
.include "../Makefile.tty"
.include "../Makefile.dev"

View file

@ -0,0 +1,6 @@
# Makefile for devlatin1
DEV= latin1
.include "../Makefile.tty"
.include "../Makefile.dev"

View file

@ -0,0 +1,40 @@
DEV= ps
FONTS= S ZD ZDR SS AB ABI AI AR BMB BMBI BMI BMR \
CB CBI CI CR HB HBI HI HR HNB HNBI HNI HNR \
NB NBI NI NR PB PBI PI PR TB TBI TI TR ZCMI
SUPPORT= download prologue symbolsl.pfa text.enc zapfdr.pfa
DEVGENFILES= generate/Makefile generate/afmname generate/dingbatsmap \
generate/dingbatsrmap generate/lgreekmap generate/symbol.sed \
generate/symbolchars generate/symbolsl.afm generate/textmap
PSFILES= prologue symbolsl.pfa zapfdr.pfa
FONTFILES= $(FONTS) $(SUPPORT) $(DEVGENFILES) DESC
DEVFILES= $(FONTFILES)
CLEANFILES+= DESC ${PSFILES}
.include "../Makefile.inc"
DESC: DESC.in
-rm -f DESC
cat ${DISTDIR}/DESC.in >DESC
echo broken ${BROKEN_SPOOLER_FLAGS} >>DESC
if test "${PAGE}" = A4; then \
echo "paperlength 841890" >>DESC; \
else \
echo "paperlength 792000" >>DESC; \
fi
test -z '${PSPRINT}' || echo print '${PSPRINT}' >>DESC
${PSFILES}:
-rm -f $@
sed -f ${DISTDIR}/psstrip.sed $? >$@
fonts: DESC
${MAKE} -f ${DISTDIR}/generate/Makefile \
srcdir=${DISTDIR}/generate DESC=${DISTDIR}/DESC.in
prologue: ${DISTDIR}/prologue.ps
zapfdr.pfa: ${DISTDIR}/zapfdr.ps
symbolsl.pfa: ${DISTDIR}/symbolsl.ps
.include "../Makefile.dev"

View file

@ -0,0 +1,24 @@
# Makefile for eqn
PROG= eqn
SRCS= main.cc lex.cc box.cc limit.cc list.cc over.cc text.cc\
script.cc mark.cc other.cc delim.cc sqrt.cc pile.cc special.cc
OBJS= eqn.o
#CFLAGS+= -I. -I${.CURDIR}/../include
LDADD+= ${LIBGROFF}
DPADD+= ${LIBGROFF}
MANDEPEND= eqn.1
CLEANFILES+= eqn.cc eqn.tab.h neqn ${MANDEPEND}
neqn:
sed -e 's/@g@/${g}/g' ${DISTDIR}/neqn.sh > neqn
afterinstall: neqn
${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} neqn \
${DESTDIR}${BINDIR}
beforedepend: eqn.cc
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,33 @@
# @(#)Makefile.dev 6.2 (Berkeley) 3/16/91
# Client Makefiles define DEV and DEVFILES and provide rules for
# individual font files
#
# $Id$
.include "../Makefile.cfg"
FONTDIR?= /usr/share/groff_font
DEVICEDIR?= $(FONTDIR)/dev$(DEV)
FONTOWN?= bin
FONTGRP?= bin
FONTMODE?= 444
all: $(DEVFILES)
.for f in $(DEVFILES)
.if exists(${.OBJDIR}/$f)
beforeinstall:: ${.OBJDIR}/$f
$(INSTALL) -c -o $(FONTOWN) -g $(FONTGRP) -m $(FONTMODE) \
${.OBJDIR}/$f $(DESTDIR)$(DEVICEDIR)
.elif exists(${.CURDIR}/$f)
beforeinstall:: ${.CURDIR}/$f
$(INSTALL) -c -o $(FONTOWN) -g $(FONTGRP) -m $(FONTMODE) \
${.CURDIR}/$f $(DESTDIR)$(DEVICEDIR)
.else
beforeinstall:: $(DISTDIR)/$f
$(INSTALL) -c -o $(FONTOWN) -g $(FONTGRP) -m $(FONTMODE) \
$(DISTDIR)/$f $(DESTDIR)$(DEVICEDIR)
.endif
.endfor
.include <bsd.prog.mk>

View file

@ -0,0 +1,55 @@
# @(#)Makefile.tty 6.1 (Berkeley) 3/3/91
#
# Modified for Berkeley Unix by Donn Seeley, donn@okeeffe.berkeley.edu
#
#Copyright (C) 1989, 1990 Free Software Foundation, Inc.
# Written by James Clark (jjc@jclark.uucp)
#
#This file is part of groff.
#
#groff is free software; you can redistribute it and/or modify it under
#the terms of the GNU General Public License as published by the Free
#Software Foundation; either version 1, or (at your option) any later
#version.
#
#groff is distributed in the hope that it will be useful, but WITHOUT ANY
#WARRANTY; without even the implied warranty of MERCHANTABILITY or
#FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
#for more details.
#
#You should have received a copy of the GNU General Public License along
#with groff; see the file LICENSE. If not, write to the Free Software
#Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
.MAIN: all
RES=240
CPI=10
LPI=6
FONTS=R I B BI S L
DEVFILES=$(FONTS) DESC
CLEANFILES=$(DEVFILES)
$(FONTS): R.proto
@${ECHO} Making $@
@(charwidth=`echo $(RES) / $(CPI) | bc` ; \
sed -e "s/^name [A-Z]*$$/name $@/" \
-e "s/^\\([^ ]*\\) [0-9]+ /\\1 $$charwidth /" \
-e "s/^spacewidth [0-9]+$$/spacewidth $$charwidth/" \
-e "s/^internalname .*$$/internalname $@/" \
-e "/^internalname/s/BI/3/" \
-e "/^internalname/s/B/2/" \
-e "/^internalname/s/I/1/" \
-e "/^internalname .*[^ 0-9]/d" \
${DISTDIR}/R.proto >$@)
DESC: DESC.proto
@${ECHO} Making $@
@sed -e "s/^res .*$$/res $(RES)/" \
-e "s/^hor .*$$/hor `echo $(RES) / $(CPI) | bc`/" \
-e "s/^vert .*$$/vert `echo $(RES) / $(LPI) | bc`/" \
-e "s/^fonts .*$$/fonts `set $(FONTS); echo $$#` $(FONTS)/" \
${DISTDIR}/DESC.proto >$@
beforeinstall:: ${DEVFILES}

View file

@ -0,0 +1,13 @@
# Makefile for grodvi
PROG= grodvi
SRCS= dvi.cc
#CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBDRIVER} ${LIBGROFF} -lm
DPADD+= ${LIBDRIVER} ${LIBGROFF} ${LIBM}
MANDEPEND= grodvi.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,13 @@
# Makefile for groff
PROG= groff
SRCS= groff.cc pipeline.c
CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBGROFF} -lm
DPADD+= ${LIBGROFF} ${LIBM}
MANDEPEND= groff.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,13 @@
# Makefile for grops
PROG= grops
SRCS= ps.cc psrm.cc
#CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBDRIVER} ${LIBGROFF} -lm
DPADD+= ${LIBDRIVER} ${LIBGROFF} ${LIBM}
MANDEPEND= grops.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,13 @@
# Makefile for grotty
PROG= grotty
SRCS= tty.cc
#CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBDRIVER} ${LIBGROFF} -lm
DPADD+= ${LIBDRIVER} ${LIBGROFF} ${LIBM}
MANDEPEND= grotty.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,21 @@
# Makefile for indxbib
PROG= indxbib
SRCS= indxbib.cc dirnamemax.c signal.c
CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBBIB} ${LIBGROFF} -lm
DPADD+= ${LIBBIB} ${LIBGROFF} ${LIBM}
MANDEPEND= indxbib.1
CLEANFILES+= ${MANDEPEND}
# Ugh - I can't grab /usr/share from ../../../share/Makefile.inc
# since I've already grabbed a BINDIR file for installing indxbib.
# Sigh... Hardcode it. - jkh
#
afterinstall:
${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \
${DISTDIR}/eign ${DESTDIR}${SHAREDIR}/dict
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,13 @@
# Makefile for libbib
LIB= bib
SRCS= common.cc index.cc linear.cc search.cc map.c
CFLAGS+= -I$(.CURDIR)/../include
NOMAN= noman
NOPROFILE= noprofile
install:
.include "../Makefile.cfg"
.include <bsd.lib.mk>

View file

@ -0,0 +1,13 @@
# Makefile for libdriver
LIB= driver
SRCS= input.cc printer.cc
CFLAGS+= -I$(DISTDIR)/../include
NOMAN= noman
NOPROFILE= noprofile
install:
.include "../Makefile.cfg"
.include <bsd.lib.mk>

View file

@ -0,0 +1,28 @@
# Makefile for libgroff
#
# $Id$
#
.include "../Makefile.inc"
LIB= groff
SRCS= assert.cc change_lf.cc cmap.cc cset.cc device.cc errarg.cc\
error.cc fatal.cc filename.cc font.cc fontfile.cc lf.cc\
lineno.cc macropath.cc nametoindex.cc new.cc prime.cc\
progname.cc ptable.cc searchpath.cc string.cc strsave.cc\
tmpfile.cc illegal.cc version.cc
SRCS+= iftoa.c itoa.c matherr.c
CFLAGS+= -I$(.CURDIR)/../include
NOMAN= noman
NOPROFILE= noprofile
CLEANFILES+= version.cc
version.cc: $(GROFF_DIST)/VERSION
@${ECHO} Making version.cc
@echo const char \*version_string = \"`cat $(GROFF_DIST)/VERSION`\"\; >$@
install:
.include "../Makefile.cfg"
.include <bsd.lib.mk>

View file

@ -0,0 +1,13 @@
# Makefile for lkbib
PROG= lkbib
SRCS= lkbib.cc
CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBBIB} ${LIBGROFF} -lm
DPADD+= ${LIBBIB} ${LIBGROFF} ${LIBM}
MANDEPEND= lkbib.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,13 @@
# Makefile for lookbib
PROG= lookbib
SRCS= lookbib.cc
CFLAGS+= -I$(.CURDIR)/../include
LDADD+= $(LIBBIB) $(LIBGROFF) -lm
DPADD+= $(LIBBIB) $(LIBGROFF) $(LIBM)
MANDEPEND= lookbib.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,10 @@
# Makefile for manpages
MAN5= groff_font.5 groff_out.5
MAN7= groff_char.7
MANDEPEND= ${MAN5} ${MAN7}
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,37 @@
TMACOWN?= bin
TMACGRP?= bin
TMACMODE?= 444
TMACDIR?= /usr/share/tmac
FILES= 0.MT 5.MT 4.MT ms.cov se_ms.cov
LOCALE= locale se_locale
MAN7= groff_mm.7 groff_mmse.7
MLINKS= groff_mm.7 mm.7 groff_mmse.7 mmse.7
MANDEPEND= ${MAN7}
CLEANFILES+= ${MANDEPEND}
afterinstall:
${INSTALL} -c -o $(TMACOWN) -g $(TMACGRP) -m $(TMACMODE) \
${DISTDIR}/tmac.m $(DESTDIR)$(TMACDIR)/tmac.m
${INSTALL} -c -o $(TMACOWN) -g $(TMACGRP) -m $(TMACMODE) \
${DISTDIR}/tmac.m $(DESTDIR)$(TMACDIR)/tmac.mse
test -d $(DESTDIR)$(TMACDIR)/mm || mkdir $(DESTDIR)$(TMACDIR)/mm
chown $(TMACOWN).$(TMACGRP) $(DESTDIR)$(TMACDIR)/mm
chmod 755 $(DESTDIR)$(TMACDIR)/mm
for f in $(FILES); do \
$(INSTALL) -c -o $(TMACOWN) -g $(TMACGRP) -m $(TMACMODE) \
${DISTDIR}/mm/$$f $(DESTDIR)$(TMACDIR)/mm/$$f; \
done
for f in $(LOCALE); do \
test -f $(DESTDIR)$(TMACDIR)/mm/$$f || \
touch $(DESTDIR)$(TMACDIR)/mm/$$f; \
chown $(TMACOWN).$(TMACGRP) $(DESTDIR)$(TMACDIR)/mm/$$f; \
chmod $(TMACMODE) $(DESTDIR)$(TMACDIR)/mm/$$f; \
done
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,13 @@
MAN1= nroff.1
MANDEPEND= nroff.1
CLEANFILES+= ${MANDEPEND}
afterinstall:
${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
$(DISTDIR)/nroff.sh $(DESTDIR)$(BINDIR)/nroff
${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
$(DISTDIR)/psroff.sh $(DESTDIR)$(BINDIR)/psroff
.include <../Makefile.cfg>
.include <bsd.prog.mk>

View file

@ -0,0 +1,12 @@
# Makefile for pfbtops
PROG= pfbtops
SRCS= pfbtops.c
LDADD+= ${LIBGROFF}
DPADD+= ${LIBGROFF}
MANDEPEND= pfbtops.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,16 @@
# Makefile for pic
PROG= pic
SRCS= lex.cc main.cc object.cc common.cc troff.cc tex.cc
OBJS= pic.o
CFLAGS+= -I. -I${.CURDIR}/../include
LDADD+= ${LIBGROFF} -lm
DPADD+= ${LIBGROFF} ${LIBM}
MANDEPEND= pic.1
CLEANFILES+= pic.cc pic.tab.h ${MANDEPEND}
beforedepend: pic.cc
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,10 @@
# Makefile for psbb
PROG= psbb
SRCS= psbb.c
MANDEPEND= psbb.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,14 @@
# Makefile for refer
PROG= refer
SRCS= command.cc ref.cc refer.cc token.cc
OBJS= label.o
CFLAGS+= -I. -I${.CURDIR}/../include
LDADD+= ${LIBBIB} ${LIBGROFF} -lm
DPADD+= ${LIBBIB} ${LIBGROFF} ${LIBM}
MANDEPEND= refer.1
CLEANFILES+= label.cc label.tab.h ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,13 @@
# Makefile for tbl
PROG= tbl
SRCS= main.cc table.cc
CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBGROFF} -lm
DPADD+= ${LIBGROFF} ${LIBM}
MANDEPEND= tbl.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,13 @@
# Makefile for tfmtodit
PROG= tfmtodit
SRCS= tfmtodit.cc
CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBGROFF} -lm
DPADD+= ${LIBGROFF} ${LIBM}
MANDEPEND= tfmtodit.1
CLEANFILES+= ${MANDEPEND}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,48 @@
# Makefile for groff macros
TMACOWN?= bin
TMACGRP?= bin
TMACMODE?= 444
TMACDIR?= /usr/share/tmac
MDOCDIR?= ${TMACDIR}/mdoc
MAN7= groff_ms.7 me.7
MLINKS= groff_ms.7 ms.7 me.7 groff_me.7
LINKS= ${TMACDIR}/tmac.andoc ${TMACDIR}/tmac.an
MANDEPEND= ${MAN7}
CLEANFILES+= temp ${MANDEPEND} tmac.groff_an
FILES= tmac.andoc tmac.pic tmac.ps tmac.psnew tmac.psold\
tmac.pspic tmac.psatk tmac.dvi tmac.tty tmac.tty-char tmac.X\
tmac.Xps tmac.latin1 eqnrc troffrc
STRIPFILES= tmac.e tmac.s tmac.doc
MDOCFILES= doc-common doc-ditroff doc-nroff doc-syms
beforeinstall:
for f in ${FILES}; do \
${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \
${DISTDIR}/$$f ${DESTDIR}${TMACDIR}; \
done
sed -f ${DISTDIR}/strip.sed ${DISTDIR}/tmac.an >tmac.groff_an
${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \
tmac.groff_an ${DESTDIR}${TMACDIR}
for f in ${STRIPFILES}; do \
rm -f temp; \
sed -f ${DISTDIR}/strip.sed ${DISTDIR}/$$f >temp; \
${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \
temp ${DESTDIR}${TMACDIR}/$$f; \
done
for f in ${MDOCFILES}; do \
rm -f temp; \
sed -f ${DISTDIR}/strip.sed ${DISTDIR}/$$f >temp; \
${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \
temp ${DESTDIR}${MDOCDIR}/$$f; \
done
test -f ${DESTDIR}${TMACDIR}/man.local || \
${INSTALL} -c -o ${TMACOWN} -g ${TMACGRP} -m ${TMACMODE} \
${DISTDIR}/man.local ${DESTDIR}${TMACDIR}
.include "../Makefile.cfg"
.include <bsd.prog.mk>

View file

@ -0,0 +1,28 @@
PROG= troff
SRCS= env.cc node.cc input.cc div.cc symbol.cc dictionary.cc reg.cc \
number.cc majorminor.cc
CFLAGS+= -I${.CURDIR}/../include
LDADD+= ${LIBGROFF} -lm
DPADD+= ${LIBGROFF} ${LIBM}
MANDEPEND= troff.1
CLEANFILES+= majorminor.cc ${MANDEPEND}
.include "../Makefile.inc"
majorminor.cc: ${GROFF_DIST}/VERSION
@${ECHO} Making $@
@-rm -f $@
@echo const char \*major_version = \
\"`sed -e 's/^\([^.]*\)\..*$$/\1/' ${GROFF_DIST}/VERSION`\"\; >$@
@echo const char \*minor_version = \
\"`sed -e 's/^[^.]*\.\([0-9]*\).*$$/\1/' ${GROFF_DIST}/VERSION`\"\; >>$@
afterinstall:
${INSTALL} -c -o bin -g bin -m 444 ${DISTDIR}/hyphen.us \
${DESTDIR}${tmacdir}/hyphen.us
${INSTALL} -c -o bin -g bin -m 444 ${DISTDIR}/hyphen.us-ru \
${DESTDIR}${tmacdir}/hyphen.us-ru
.include "../Makefile.cfg"
.include <bsd.prog.mk>