2008-01-16 09:02:25 +01:00
|
|
|
#!/bin/sh
|
2008-01-25 11:49:14 +01:00
|
|
|
top_srcdir="${1-.}"
|
2008-01-16 09:02:25 +01:00
|
|
|
echo "/* This file is autogenerated by" $(basename $0) "*/"
|
|
|
|
echo
|
|
|
|
echo "const name_func_link_t LayoutList[] ="
|
|
|
|
echo "{"
|
2008-01-25 11:49:14 +01:00
|
|
|
for file in ${top_srcdir}/layouts/*.h
|
2008-01-16 09:02:25 +01:00
|
|
|
do
|
|
|
|
echo " /* $file */"
|
2008-05-23 13:33:57 +02:00
|
|
|
grep '^layout_t layout_' $file | cut -d' ' -f2 | cut -d\; -f1 | while read layout
|
2008-01-16 09:02:25 +01:00
|
|
|
do
|
|
|
|
shortname=$(echo $layout | cut -d _ -f2-)
|
|
|
|
echo " {\"$shortname\", $layout},"
|
|
|
|
done
|
|
|
|
done
|
|
|
|
|
|
|
|
echo " {NULL, NULL}"
|
|
|
|
echo "};"
|