diff options
Diffstat (limited to 'mech/mech.mk')
-rw-r--r-- | mech/mech.mk | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/mech/mech.mk b/mech/mech.mk new file mode 100644 index 0000000..6807c03 --- /dev/null +++ b/mech/mech.mk @@ -0,0 +1,19 @@ +MECH_BUILD_DIR := $(BUILD_DIR)/mech +PARTS := bottom top back front +STL := $(PARTS:%=$(MECH_BUILD_DIR)/%.stl) +GCODE := $(PARTS:%=$(MECH_BUILD_DIR)/%.gcode) + +.PHONY: mech +mech: $(GCODE) + +$(BUILD_DIR)/%.gcode: $(BUILD_DIR)/%.stl + mkdir -p $(dir $@) + prusa-slicer --output $@ --export-gcode $< + +$(BUILD_DIR)/%.stl: %.scad + mkdir -p $(dir $@) + openscad --export-format binstl -o $@ $< + +.PHONY: clean +clean: + rm -rf $(BUILD_DIR) |