From: PatR Date: Sat, 11 Feb 2023 00:42:01 +0000 (-0800) Subject: Makefile management X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=df18c968409e0f7aa7d1d1125c24b73531dae70c;p=nethack Makefile management Have 'make clean' and 'make spotless' in 3.7 cleanup include/tile.h from 3.6. Otherwise use of 'cc -I../include -I../win/share' in util/Makefile will get 3.6's include/tile.h instead of 3.7's win/share/tile.h; use of FDECL() causes the old header to break when used in various tiles utilities. --- diff --git a/sys/unix/Makefile.utl b/sys/unix/Makefile.utl index 13a2bbe9c..f9a0c5af1 100644 --- a/sys/unix/Makefile.utl +++ b/sys/unix/Makefile.utl @@ -407,7 +407,16 @@ SYSSHARE=../sys/share/ tags: $(UTILSRCS) @ctags -tw $(UTILSRCS) -clean: +# note: 3.6 copied tile.h from win/share/ to include/ and if someone +# switches branches from 3.6 to 3.7 without executing 'make spotless' +# first, the old tile.h sticks around and gets found during compile +# instead of current one; various tile utilities won't build in that +# mis-configuration so allow 'make clean' and 'make spotless' in 3.7 +# to fix things up by deleting the out of date file (if present) +clean-fixup: + -rm -f ../include/tile.h + +clean: clean-fixup -rm -f *.o spotless: clean