From 384850e0638ce3d47ecf9279861dd7676d425b30 Mon Sep 17 00:00:00 2001 From: Bryan Drewery Date: Tue, 14 Jun 2016 16:20:05 +0000 Subject: [PATCH] WITH_META_MODE: Fix rebuilding maketab outside of build-tools. The bsd.dep.mk yacc targets rely on only the .c file getting a .meta file. However the previous code here relying on only the .h file meant that it would be generated with a .meta file. r301285 made it so that the .h file is never expected to get a .meta file. To keep this restriction in place add in an extra dependency on the .c file so that it is generated at this time. It's a hack but the best for the patterns we have at the moment for handling build-tools and side-effect-generated files. Reported by: Mark Millard Approved by: re (implicit) Sponsored by: EMC / Isilon Storage Division --- usr.bin/awk/Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/usr.bin/awk/Makefile b/usr.bin/awk/Makefile index 168b22eea632..f6c1baac7e42 100644 --- a/usr.bin/awk/Makefile +++ b/usr.bin/awk/Makefile @@ -17,8 +17,10 @@ MLINKS= awk.1 nawk.1 CLEANFILES= maketab proctab.c ytab.h -ytab.h: awkgram.h .NOMETA - ln -sf ${.ALLSRC} ${.TARGET} +# XXX: awkgram.c isn't really needed here but it is added to keep +# awkgram.h: .NOMETA respected. +ytab.h: awkgram.c awkgram.h .NOMETA + ln -sf ${.ALLSRC:M*.h} ${.TARGET} proctab.c: maketab ${BTOOLSPATH:U.}/maketab > proctab.c