summaryrefslogtreecommitdiffstats
path: root/case/Makefile
blob: 07a92fe3432b7af3e2f909c97f033c5c6a1bf6b9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
SCAD_MODELS	= top-keyboard.scad
SCAD_INCLUDE	= params.scad

STL_MODELS	= top-keyboard.stl
STL_MODEL_PARAM	= top-keyboard.json

OPENSCAD	= /usr/bin/openscad

all: scad
scad: $(SCAD_MODELS)
stl: $(STL_MODELS)

top-keyboard.scad: SCAD_INPUT = top.scad
top-keyboard.scad: top.scad

$(SCAD_MODELS): $(SCAD_INPUT) $(SCAD_INCLUDE)
	cat $(SCAD_INCLUDE) $(SCAD_INPUT) > $@

$(STL_MODELS): %.stl: %.scad
	$(OPENSCAD) $< -o $@

clean:
	$(RM) $(SCAD_MODELS) $(STL_MODELS)