wrights-deck/Makefile

21 lines
861 B
Makefile
Raw Normal View History

suits := blades puppets chairs bread cards wheels
2022-07-27 03:23:26 -04:00
values := 1 2 3 4 5 6 traveler knight wizard noble
nobles := count-of-cards queen-of-puppets earl-of-bread scion-of-blades prince-of-wheels regent-of-chairs
2022-07-27 03:23:26 -04:00
cards := $(foreach suit,$(suits),$(foreach value,$(values),$(value)-$(suit)))
svgcards := $(foreach card,$(cards),build/$(card).svg)
pngcards := $(foreach card,$(cards),build/$(card).png)
2022-07-27 03:23:26 -04:00
svgdeck: $(svgcards)
2022-07-27 03:23:26 -04:00
pngdeck: $(pngcards)
2022-07-27 03:23:26 -04:00
build/%.svg: deck.asy cards.asy numerals.asy suits.asy nobles.asy $(foreach suit,$(suits),$(suit).asy) $(foreach noble,$(nobles),$(noble).asy)
2022-07-27 03:23:26 -04:00
mkdir -p build
sh -c "buf_size=5000000 asy -globalwrite deck.asy"
build/sample.png: $(svgcards)
montage -density 100 -background transparent $(svgcards) -tile 10x6 -geometry +0+0 build/sample.png
2022-07-28 17:26:09 -04:00
2022-07-27 03:23:26 -04:00
build/%.png: build/%.svg
convert -density 512 -background transparent $< $@