diff options
Diffstat (limited to 'cpp/preprocess')
| -rwxr-xr-x | cpp/preprocess | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/cpp/preprocess b/cpp/preprocess new file mode 100755 index 0000000..63af4c6 --- /dev/null +++ b/cpp/preprocess @@ -0,0 +1,21 @@ +#!/bin/sh + +preprocess() { + ruby -r erb -e 'puts ERB.new(ARGF.read).result' $1.erb > $1.tmp + if [ "$?" != 0 ]; then + echo "" + echo "** preprocess failed **" + echo "" + else + mv $1.tmp $1 + fi +} + +preprocess msgpack/type/tuple.hpp +preprocess msgpack/type/define.hpp +preprocess msgpack/zone.hpp +cp -f ../msgpack/pack_define.h msgpack/ +cp -f ../msgpack/pack_template.h msgpack/ +cp -f ../msgpack/unpack_define.h msgpack/ +cp -f ../msgpack/unpack_template.h msgpack/ + |
