changeset 2448:858a0ef03dff

Only re-generate hcbat.loc if Perl can be found.
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 16 May 2022 11:13:24 +0300
parents 61f4c9018f19
children ee5d264b7e05
files old/Makefile
diffstat 1 files changed, 7 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/old/Makefile	Sat May 14 15:10:34 2022 +0300
+++ b/old/Makefile	Mon May 16 11:13:24 2022 +0300
@@ -39,8 +39,13 @@
 #twomi-batmap.html: twomi-batmap.tmp $(COLORMAP_BIN)
 #	$(COLORMAP_BIN) $(COLORMAP_OPTS) -O $(COLORMAP_HTML) -t "`cat $(patsubst %.tmp,%.desc,$<)`" $< -o $@
 
-hcbat.loc: hcbat.ref $(MAP_PATH)laenor.loc $(MAP_PATH)desolathya.loc $(MAP_PATH)rothikgen.loc $(MAP_PATH)furnachia.loc $(MAP_PATH)lucentium.loc
-	perl -w ./mapref.pl $+ > $@
+hcbat.loc: hcbat.ref mapref.pl $(addprefix $(MAP_PATH),$(addsuffix .loc,$(WORLD_MAPS)))
+	@if command -v perl > /dev/null; then \
+		echo "Generating $@"; \
+		perl -w ./mapref.pl $+ > $@; \
+	else \
+		echo "WARNING: perl not found, not updating $@"; \
+	fi
 
 
 #