> Le 18 oct. 2019 à 19:47, Johannes Mario Ringheim <j...@ringheimsauto.org> a > écrit : > > Den 09.10.2019 16:07, skreiv James Mckernon: >> I too am relatively new to Faust but I will try to shed some light on this. >> Whatever executable you are running to compile faust code to a pd >> binary will be generating C++ code as an intermediate step. If this is >> what you want to get your hands on, it should be possible. The various >> faust2... executables are mostly just bash scripts, so it's not too >> difficult to modify their behaviour. If you are on a unix-y system, >> you can find out the path of the script in question by running 'which >> faust2puredata' (or whichever script it is you are interested in). I >> would suggest making a copy of script in your local directory, opening >> it in your text editor, and removing the step at the end which deleted >> the temporary interim files (in faust2puredata, that's the couple of >> lines which start rm -rf... near the end of the file). You might also >> want to just adjust it to output to the current directory, or one of >> your choice, instead of to a temporary directory as it appears to now. >> And if you make a copy of the script, remember to make the copy >> executable with chmod u+x. >> I'm not 100% sure I have understood your question correctly, but if I >> have, I hope the above will give you enough to get started. > > Thank you for your suggestion. I took a look at faust2puredata, and it seems > to me that it compiles straight from the interim c++ code to a binary PD > external. > > To be clear: I want the c source code of the PD external, not the binary PD > external. > > So to ask a different question: Is it possible to compile/transpile from > Faust code to c source code instead of c++? >
C++ compilation is used to generate the PD external with faust2puredata. If you want to see the C++ file before the binary PD external is produced, you can simply do the following, using -a to give the wanted architecture file : faust -a puredata.cpp foo.dsp -o foo.cpp or: faust -a puredata.cpp foo.dsp -i -o foo.cpp (adding -i to have all Faust related architecture files be inlined in the resulting foo.cpp file) You can also use « -lang c » to generate a pure C from a DSP source : faust -lang c -o foo.c Stéphane _______________________________________________ Faudiostream-users mailing list Faudiostream-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/faudiostream-users