Skip to content

Commit

Permalink
Add Makefile to build stl files from scad files
Browse files Browse the repository at this point in the history
  • Loading branch information
qtux committed Apr 9, 2018
1 parent 8b00320 commit c251d7f
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.stl
19 changes: 19 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# disable implicit rules
.SUFFIXES:

SCAD_FILES = $(wildcard */*.scad)
STL_FILES = $(patsubst %.scad, %.stl, $(SCAD_FILES))

# create all stl files
.PHONY: all
all: $(STL_FILES)

# remove all stl files
.PHONY: clean
clean:
rm $(STL_FILES)

# build stl files
%.stl: %.scad
openscad $< -o $@

0 comments on commit c251d7f

Please sign in to comment.