summaryrefslogtreecommitdiffstats
path: root/gnu
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1998-03-20 12:03:53 +0000
committerbde <bde@FreeBSD.org>1998-03-20 12:03:53 +0000
commitc9fc11ea7ec65b0f43509948be736de56da2eb13 (patch)
tree472e28d64685f679cc26bc7db03d07b7d1cbd667 /gnu
parentc917c1de6c42b83a5a8c96df0f6492eff2ffd4f2 (diff)
downloadFreeBSD-src-c9fc11ea7ec65b0f43509948be736de56da2eb13.zip
FreeBSD-src-c9fc11ea7ec65b0f43509948be736de56da2eb13.tar.gz
Don't use beforedepend to complicate and break things. Just put
generated source files in SRCS. Don't use MANDEPEND to complicate things. Just set MAN1 and put generated man pages in CLEANFILES. Added temporary files to CLEANFILES. Partly fixed a potentially fatal bug involving the yacc header. We generate eqn.cc (even if there is a version of it in the source directory older than eqn.y) and a matching eqn.tab.h, but only use the possibly-non-matching eqn.tab.h in the source directory. This works because Cygnus's yacc happened to generate a y.tab.h identical to the current generated one. The correct version will be used when the wrong version is deleted from the source tree. Kludge to get the header generated early enough. Yacc headers are mishandled everywhere they are renamed (and used). Generate neqn at build time, not at install time. Fixed some style bugs.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/usr.bin/groff/eqn/Makefile29
1 files changed, 14 insertions, 15 deletions
diff --git a/gnu/usr.bin/groff/eqn/Makefile b/gnu/usr.bin/groff/eqn/Makefile
index c7773cc..5ea45a1 100644
--- a/gnu/usr.bin/groff/eqn/Makefile
+++ b/gnu/usr.bin/groff/eqn/Makefile
@@ -1,26 +1,25 @@
-# Makefile for eqn
+# $Id$
PROG= eqn
-MAN1= eqn.1 neqn.1
-SRCS= main.cc lex.cc box.cc limit.cc list.cc over.cc text.cc\
+SRCS= eqn.cc eqn.tab.h 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}
+CFLAGS+= -I.
+DPADD= ${LIBGROFF}
+LDADD= ${LIBGROFF}
+MAN1= eqn.1 neqn.1
+CLEANFILES= eqn.cc eqn.tab.h ${MAN1} neqn y.tab.c y.tab.h
-MANDEPEND= neqn.1 eqn.1
-CLEANFILES+= eqn.cc eqn.tab.h neqn ${MANDEPEND}
+all: neqn
-afterinstall: neqn
+beforeinstall: neqn
${INSTALL} ${COPY} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} neqn \
- ${DESTDIR}${BINDIR}
+ ${DESTDIR}${BINDIR}
-beforedepend: eqn.cc
+eqn.tab.h: eqn.cc
.include "../Makefile.cfg"
.include <bsd.prog.mk>
-neqn: ${DIST_DIR}/neqn.sh
- sed -e 's/@g@/${g}/g' ${DIST_DIR}/neqn.sh > neqn
-
+neqn: ${DIST_DIR}/neqn.sh
+ sed -e 's/@g@/${g}/g' ${.ALLSRC} > ${.TARGET}
OpenPOWER on IntegriCloud