File: Makefile.sub

package info (click to toggle)
png23d 1.10-3
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 9,020 kB
  • sloc: ansic: 1,951; makefile: 58; sh: 9
file content (53 lines) | stat: -rw-r--r-- 1,577 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#!/usr/bin/make
#
# make fragment for png23d tests

PNG23D=./png23d

BASE_TESTS=square-c c o s spiral cube steps plus plusa plusb calcube-c
LOGO_TESTS=debian-logo.scad debian-logo-s.stl

TESTS=$(LOGO_TESTS) $(addsuffix .stl, $(BASE_TESTS)) $(addsuffix -a.stl, $(BASE_TESTS)) $(addsuffix .scad, $(BASE_TESTS)) $(addsuffix -r.scad, $(BASE_TESTS)) 

TESTF=$(addprefix test/, $(TESTS))

check:$(TESTF)

# convert to binary stl with smooth finish
test/%.stl:test/%.png $(PNG23D)
	$(PNG23D) -l 1 -f smooth -o stl -w 20 -d 10 $< $@

# convert to binary stl with smooth finish
test/%-c.stl:test/%.png $(PNG23D)
	$(PNG23D) -l 1 -f smooth -o stl -w 20 -d 10 $< $@

# convert to ascii stl 
# also has 10 levels for these tests
test/%-a.stl:test/%.png $(PNG23D)
	$(PNG23D) -l 10 -f cube -o astl -w 20 -d 10 $< $@

# convert to ascii stl with cube finish
# also has 10 levels for these tests
test/%-c-a.stl:test/%.png $(PNG23D)
	$(PNG23D) -f cube -l 10 -o astl -w 20 -d 10 $< $@

# convert to binary stl with surface finish
test/%-s.stl:test/%.png $(PNG23D)
	$(PNG23D) -f surface -o stl -w 20 -d 4 $< $@

# convert to smoothed single layer polyhedron scad output
test/%.scad:test/%.png $(PNG23D)
	$(PNG23D) -l 1 -f smooth -o scad -w 50 -d 4 $< $@

# convert to raw finish single layer polyhedron scad output
test/%-c.scad:test/%.png $(PNG23D)
	$(PNG23D) -l 1 -f cube -o scad -w 50 -d 4 $< $@

# convert to single layer rectangular cuboid scad output
test/%-c-r.scad test/%-r.scad:test/%.png $(PNG23D)
	$(PNG23D) -l 1 -o rscad -w 50 -d 4 $< $@

.PHONY: testclean

testclean:
	${RM} $(TESTF)