New directory tree, with preprocessor/ inside interpretor/.
[Faustine.git] / interpretor / preprocessor / faust-0.9.47mr3 / examples / rewriting / Makefile
diff --git a/interpretor/preprocessor/faust-0.9.47mr3/examples/rewriting/Makefile b/interpretor/preprocessor/faust-0.9.47mr3/examples/rewriting/Makefile
new file mode 100644 (file)
index 0000000..5c8562f
--- /dev/null
@@ -0,0 +1,21 @@
+
+dspsrc  := $(wildcard *.dsp)
+cppsrc  := $(dspsrc:.dsp=.cpp)
+plugins        := $(dspsrc:%.dsp=%~.pd_linux)
+svg    := $(dspsrc:.dsp=-svg)
+xml    := $(dspsrc:.dsp=.dsp.xml)
+pd     := $(dspsrc:.dsp=.pd)
+
+all: $(plugins) $(svg)
+
+clean:
+       rm -Rf *~ $(cppsrc) $(plugins) $(svg) $(xml)
+
+%.cpp %.dsp.xml %-svg: %.dsp
+       faust -xml -svg -sd -a puredata.cpp $< -o $@
+
+%~.pd_linux: %.cpp
+       g++ -shared -fPIC -Dmydsp=$(@:%~.pd_linux=%) -o $@ $<
+
+%.pd: %.dsp.xml
+       faust2pd -s $<