2011-05-21 10:05:48 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
for a in $* ; do
|
|
|
|
base=${a%.o}
|
2011-06-20 21:33:42 +00:00
|
|
|
echo "void main_$base(void);"
|
2011-06-13 21:19:18 +00:00
|
|
|
echo "void tick_$base(void);"
|
2011-05-21 10:05:48 +00:00
|
|
|
done
|
|
|
|
|
|
|
|
echo
|
|
|
|
echo "void wrapper(void){"
|
|
|
|
|
|
|
|
for a in $* ; do
|
|
|
|
base=${a%.o}
|
2011-06-20 21:33:42 +00:00
|
|
|
echo "main_$base();"
|
2011-05-21 10:05:48 +00:00
|
|
|
done
|
|
|
|
|
|
|
|
echo "}"
|
2011-06-13 21:19:18 +00:00
|
|
|
|
|
|
|
echo "void tick_wrapper(void){"
|
|
|
|
|
|
|
|
for a in $* ; do
|
|
|
|
base=${a%.o}
|
|
|
|
grep -q \ tick_$base ${base}.c && echo "tick_$base();"
|
|
|
|
done
|
|
|
|
|
|
|
|
echo "}"
|