3 # $Id: gen_defs,v 3.0 2002/01/24 12:10:49 roessler Exp $
5 echo '/* Automatically generated by gen_defs. Do not edit! */'
8 for mode in help defs; do
9 if test $mode = help; then
11 echo "#ifndef KEYMAP_DEFS_HELP_C"
12 echo "#define KEYMAP_DEFS_HELP_C"
13 echo "const char *HelpStrings[] = {"
14 expr='s;^[^ ]* *\(.*\); N_(\1),;'
16 echo "#ifndef KEYMAP_DEFS_H"
17 echo "#define KEYMAP_DEFS_H"
19 expr='s;^\([^ ]*\).*; \1,;'
22 sed -e '/^\/\*/d' -e "$expr" < $i
24 if test $mode = help; then
30 if test $mode = help; then
31 echo "#endif /* KEYMAP_DEFS_HELP_C */"
32 echo "#endif /* HELP_C */"
35 echo "#endif /* KEYMAP_DEFS_H */"