chiark / gitweb /
pandemic-counter: Makefiles etc.
[reprap-play.git] / Makefile
index 62a1381d89340e14b7c0e378aa59a1ce7629010d..2c8684410814a3ebcd8e0d3bd6b770f406657a68 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -8,7 +8,7 @@ PLAY ?= $(CWD)
 
 CONFIG=$(PLAY)/slic3r-config.ini
 
-USING_AUTOS ?= filamentspool xeno-drivebay-bracket dungeonquest-cone anke-gps-bracket cable-hole-trunking-cover anglepoise-neck crossbar-computer-led-mount wardrobe-hook
+USING_AUTOS ?= filamentspool xeno-drivebay-bracket dungeonquest-cone anke-gps-bracket cable-hole-trunking-cover anglepoise-neck crossbar-computer-led-mount wardrobe-hook knifeblock pandemic-counter
 AUTO_TOPLEVELS := $(foreach m,$(USING_AUTOS),$(shell $(PLAY)/toplevel-find $m))
 
 AUTO_INCS = funcs.scad
@@ -48,6 +48,8 @@ stls:         $(addsuffix .auto.stl, $(AUTO_TOPLEVELS))
 %:             %.cpp
                cpp -nostdinc -P <$< >$@.tmp && mv -f $@.tmp $@
 
+funcs.scad:
+
 #%.gcode:      %.stl
 #              $(SKEINFORGE) $<
 
@@ -63,13 +65,26 @@ KNIFEBLOCK_TEMPLATE_FILES=\
        $(foreach t,$(KNIFEBLOCK_TEMPLATES), \
        knifeblock-knives-t$k$t.dxf))
 
-knifeblock-knives-templates: $(KNIFEBLOCK_TEMPLATE_FILES)
+knifeblock-knives-templates knifeblock.stl: $(KNIFEBLOCK_TEMPLATE_FILES)
 
 knifeblock-knives-t%.dxf: knifeblock-knives-filter knifeblock-knives-trace.fig
-               ./$< $* <$(filter %.fig, $^) >$@.tmp.fig
+               ./$< $(notdir $*) <$(filter %.fig, $^) >$@.tmp.fig
                fig2dev -D -30 -L eps <$@.tmp.fig >$@.tmp.eps
                pstoedit -dt -f "dxf: -polyaslines -mm" $@.tmp.eps $@
 
+PANDEMICCOUNTER_LETTERS=30 31 32 33 34 35
+PANDEMICCOUNTER_DXFS=$(foreach l,$(PANDEMICCOUNTER_LETTERS), \
+       pandemic-counter-l$l.dxf)
+
+pandemic-counter-letters pandemic-counter.stl: $(PANDEMICCOUNTER_DXFS)
+
+pandemic-counter-l%.eps: pandemic-counter-letters.fig
+               fig2dev -D +$(notdir $*) -L eps <$< >$@.tmp
+               @mv -f $@.tmp $@
+
+%.dxf:         %.eps
+               pstoedit -dt -f "dxf: -polyaslines -mm" $< $@
+
 %:             %.pl
                ./$< >$@.tmp && mv -f $@.tmp $@