diff options
author | Michael Schwarz <michi.schwarz@gmail.com> | 2015-09-14 15:04:45 +0200 |
---|---|---|
committer | Michael Schwarz <michi.schwarz@gmail.com> | 2015-09-16 01:50:24 +0200 |
commit | 24a60718eb64da9f5b9e284965e888dd4371a278 (patch) | |
tree | d6ec06a0890df90361e0f4be28ad246052f57213 /Makefile | |
parent | a1f09b7f86c0d20941562f5b1254f9c0a2b9a535 (diff) | |
download | pogojig-24a60718eb64da9f5b9e284965e888dd4371a278.tar.gz pogojig-24a60718eb64da9f5b9e284965e888dd4371a278.tar.bz2 pogojig-24a60718eb64da9f5b9e284965e888dd4371a278.zip |
Implemented Asymptote dependency tracking.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -55,7 +55,7 @@ SVG_ASY_FILES := $(call filter_compiled,.svg,.asy,$(SRC_FILES)) ASY_PDF_FILES := $(call filter_compiled,.asy,.pdf,$(filter-out $(SVG_ASY_FILES),$(SRC_FILES))) # Makefiles which are generated while compiling to record dependencies. -DEPENDENCY_FILES := $(foreach i,.scad,$(call filter_compiled,$i,.d,$(filter-out $(SVG_ASY_FILES),$(SRC_FILES)))) +DEPENDENCY_FILES := $(patsubst %,%.d,$(SCAD_STL_FILES) $(SCAD_DXF_FILES) $(ASY_PDF_FILES)) # Files that may be used from OpenSCAD files and thus must exist before OpenSCAD is called. SCAD_ORDER_DEPS := $(filter %.scad %.dxf,$(SRC_FILES)) $(SVG_DXF_FILES) @@ -95,17 +95,17 @@ $(SVG_ASY_FILES): %.asy: %.svg $(GLOBAL_DEPS) # Rule to compile an OpenSCAD file to a DXF file. $(SCAD_DXF_FILES): %.dxf: %.scad $(GLOBAL_DEPS) | $(SCAD_ORDER_DEPS) echo [openscad] $@ - $(OPENSCAD_CMD) $< $@ $*.d + $(OPENSCAD_CMD) $< $@ # Rule to compile an OpenSCAD file to an STL file. $(SCAD_STL_FILES): %.stl: %.scad $(GLOBAL_DEPS) | $(SCAD_ORDER_DEPS) echo [openscad] $@ - $(OPENSCAD_CMD) $< $@ $*.d + $(OPENSCAD_CMD) $< $@ # Rule to export an SVG file to an Asymptote file. -$(ASY_PDF_FILES): %.pdf: $(ASY_DEPS) $(GLOBAL_DEPS) +$(ASY_PDF_FILES): %.pdf: %.asy $(GLOBAL_DEPS) | $(ASY_DEPS) echo [asymptote] $@ - $(ASYMPTOTE_CMD) $*.asy $@ + $(ASYMPTOTE_CMD) $< $@ # Rule for automaticaly generated OpenSCAD files. $(GENERATED_FILES): generate_sources.sh $(GLOBAL_DEPS) |