aboutsummaryrefslogtreecommitdiff
path: root/generate.sh
diff options
context:
space:
mode:
authorHans-Christoph Steiner <eighthave@users.sourceforge.net>2006-05-27 10:51:20 +0000
committerHans-Christoph Steiner <eighthave@users.sourceforge.net>2006-05-27 10:51:20 +0000
commit110ba15500772e524daa6b2c6c97487886e12136 (patch)
tree3bb11d987d8bd928d558b376cb6f3bb68feaf781 /generate.sh
wrote script to generate files to build internal Pd objects as separate libs; next, I'll write a patch which removes these from being compiled into the core, so then we'll really have 'pure pd'svn2git-root
svn path=/trunk/externals/corelibs/; revision=5140
Diffstat (limited to 'generate.sh')
-rwxr-xr-xgenerate.sh23
1 files changed, 23 insertions, 0 deletions
diff --git a/generate.sh b/generate.sh
new file mode 100755
index 0000000..4b69e71
--- /dev/null
+++ b/generate.sh
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+# put these at the top of the file
+touch lib_d_fft.c
+echo '#include "../../pd/src/d_fftroutine.c"' >> lib_d_fft.c
+echo '#include "../../pd/src/d_mayer_fft.c"' >> lib_d_fft.c
+
+for file in ../../pd/src/[dx]_*.c; do
+ newfile=`echo $file | sed 's|.*/src/\([dx]_\)|lib_\1|'`
+ touch $newfile
+ echo -n '#include "' >> $newfile
+ echo -n $file >> $newfile
+ echo '"' >> $newfile
+ echo "void "`echo $newfile|sed 's|\(.*\)\.c|\1|'`"_setup(void)" >> $newfile
+ echo "{" >> $newfile
+ echo $file | sed 's|.*src/\(.*\)\.c| \1_setup();|' >> $newfile
+ echo "}" >> $newfile
+done
+
+# these files hold code for other classes, but no classes
+rm lib_d_fftroutine.c lib_d_mayer_fft.c lib_d_resample.c
+
+