summaryrefslogtreecommitdiffhomepage
path: root/GNUmakefile
diff options
context:
space:
mode:
Diffstat (limited to 'GNUmakefile')
-rw-r--r--GNUmakefile34
1 files changed, 18 insertions, 16 deletions
diff --git a/GNUmakefile b/GNUmakefile
index 6807748..4d2804d 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -3,19 +3,19 @@ MAKEFLAGS := -j$(shell nproc)
# Eurozone coin and -banknote types
eznotes := 5e 10e 20e 50e 100e 200e 500e
ezcoins := 1c 2c 5c 10c 20c 50c 1e 2e
-ezcodes := $(shell \
- grep -Eo '^[A-Z]{2}' data/coins \
- | sort \
- | uniq \
- | tr A-Z a-z \
+ezcodes := $(shell \
+ grep -Eo '^[A-Z]{2}' data/coins \
+ | sort \
+ | uniq \
+ | tr A-Z a-z \
)
# Source files that aren’t dynamically generated
-sources := $(shell find src -type f \( \
- -name 'index.gsp' -or \
- -name '*.css' -or \
- -name '*.svg' -or \
- -name '*.woff2' \
+sources := $(shell find src -type f \( \
+ -name 'index.gsp' -or \
+ -name '*.css' -or \
+ -name '*.svg' -or \
+ -name '*.woff2' \
\))
# Different euro coin and -banknote page types
@@ -45,6 +45,7 @@ eurotndeps := src/euro/index.tnotes.gsp src/euro/nav.dnotes.gsp data/notes
# Macros to get data to pass to m4
altnames = $(shell awk 'BEGIN { FS = "\t" } $$1 == toupper("$1") { print $$4 }' data/country-info)
+name = $(shell awk 'BEGIN { FS = "\t" } $$1 == toupper("$1") { print $$3 }' data/country-info)
demonym = $(shell awk 'BEGIN { FS = "\t" } $$1 == toupper("$1") { print $$2 }' data/country-info)
percentage = $(shell ./scripts/gen-stats $1)
@@ -67,10 +68,11 @@ out/%.html: src/%.gsp $(gspdeps)
m4 -P lib.m4 $< | gsp >$@
$(eurocc): out/euro/%/index.html: $(gspdeps) $(euroccdeps)
- m4 -P -D__coins -D__code=$* \
- -D__demonym="$(call demonym,$*)" \
- -D__altnames="$(call altnames,$*)" \
- -D__percentage="$(call percentage,$*)" \
+ m4 -P -D__coins -D__code=$* \
+ -D__demonym="$(call demonym,$*)" \
+ -D__name="$(call name,$*)" \
+ -D__altnames="$(call altnames,$*)" \
+ -D__percentage="$(call percentage,$*)" \
lib.m4 src/euro/index.ccoins.gsp | gsp >$@
$(eurocd): out/euro/%/index.html: $(eurocddeps) $(gspdeps)
@@ -90,7 +92,7 @@ out/%: src/%
cp $< $@
check:
- LANG=en_US.UTF-8 find src -name '*.gsp' -exec \
+ LANG=en_US.UTF-8 find src -name '*.gsp' -exec \
aspell --home-dir=./ --ignore-case check {} \;
clean:
@@ -99,4 +101,4 @@ clean:
serve:
darkhttpd out --daemon
-.PHONY: all check clean serve
+.PHONY: all check clean serve \ No newline at end of file