summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorjaseg <git@jaseg.net>2019-09-26 19:45:54 +0200
committerjaseg <git@jaseg.net>2019-09-26 19:45:54 +0200
commitb2eb56076d47af08a11e10fa53446a00b849a13c (patch)
tree4537c06e2e9bc5b78a731231e6c049c8cd5f376c /Makefile
parent82b88f920a85487372cc6e0b46633e4aa328eb69 (diff)
downloadpogojig-b2eb56076d47af08a11e10fa53446a00b849a13c.tar.gz
pogojig-b2eb56076d47af08a11e10fa53446a00b849a13c.tar.bz2
pogojig-b2eb56076d47af08a11e10fa53446a00b849a13c.zip
Pogojig mostly done: KiCAD export works
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile41
1 files changed, 14 insertions, 27 deletions
diff --git a/Makefile b/Makefile
index 26672df..4b66b0d 100644
--- a/Makefile
+++ b/Makefile
@@ -1,40 +1,27 @@
-# Installation-dependent settings. You can overwrite these in a file called config.mk in the same directory as this makefile. See readme.creole.
-INKSCAPE := inkscape
-OPENSCAD := openscad
-PYTHON := python2
-ASYMPTOTE := asy
+# Environment variables:
+# INKSCAPE_DXF_FLATNESS controls inkscape SVG->DXF export curve flatness (default: 0.1)
+# INKSCAPE, OPENSCAD: Commands to use for inkscape and openscad
-# Settings affecting the compiled results. You can overwrite these in a file called settings.mk in the same directory as this makefile. See readme.creole.
-DXF_FLATNESS := 0.1
-
-# Non-file goals.
-.PHONY: all clean generated dxf stl asy pdf
-
-# Include the configuration files.
--include config.mk settings.mk
-
-# Command to run the Python scripts.
-PYTHON_CMD := PYTHONPATH="support" $(PYTHON)
-INKSCAPE_CMD := INKSCAPE=$(INKSCAPE) DXF_FLATNESS=$(DXF_FLATNESS) $(PYTHON_CMD) -m inkscape
-OPENSCAD_CMD := OPENSCAD=$(OPENSCAD) $(PYTHON_CMD) -m openscad
+OPENSCAD ?= openscad
all: src/jig.stl src/pcb_shape.dxf
-clean:
- rm -f src/input.preprocessed.dxf
- rm -f src/input.preprocessed.svg
- rm -f src/jig.stl
- rm -f src/pcb_shape.dxf
-
src/input.preprocessed.dxf: src/input.preprocessed.svg
- $(INKSCAPE_CMD) $< $@
+ support/inkscape_exporter.py $< $@
src/pcb_shape.dxf: src/pcb_shape.scad src/input.preprocessed.dxf
- $(OPENSCAD_CMD) $< $@
+ $(OPENSCAD) -o $@ $<
src/jig.stl: src/jig.scad src/input.preprocessed.dxf
- $(OPENSCAD_CMD) $< $@
+ $(OPENSCAD) -o $@ $<
src/input.preprocessed.svg: input.svg
support/inkscape_svg_filter_layers.py $< $@ --only --name "Test Points" "Mounting Holes" "Grip Slots" "Outline"
+.PHONY: clean
+clean:
+ rm -f src/input.preprocessed.dxf
+ rm -f src/input.preprocessed.svg
+ rm -f src/jig.stl
+ rm -f src/pcb_shape.dxf
+