gdbstub-xml: avoid a warning from sparse
authorBlue Swirl <blauwirbel@gmail.com>
Sun, 23 Jan 2011 11:43:25 +0000 (11:43 +0000)
committerBlue Swirl <blauwirbel@gmail.com>
Sun, 23 Jan 2011 11:43:25 +0000 (11:43 +0000)
Include a header to get the declaration for xml_builtin. This
avoids a warning from sparse:
  CC    m68k-softmmu/gdbstub-xml.o
gdbstub-xml.c:244:12: warning: symbol 'xml_builtin' was not declared. Should it be static?

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
scripts/feature_to_c.sh

index 0994d9546edeb894c3db9bae09cd5be524de8221..b62da8a0bd76672d237e6c23c32a499d8494dd4b 100644 (file)
@@ -36,6 +36,9 @@ for input; do
   arrayname=xml_feature_`echo $input | sed 's,.*/,,; s/[-.]/_/g'`
 
   ${AWK:-awk} 'BEGIN { n = 0
+      printf "#include \"config.h\"\n"
+      printf "#include \"qemu-common.h\"\n"
+      printf "#include \"gdbstub.h\"\n"
       print "static const char '$arrayname'[] = {"
       for (i = 0; i < 255; i++)
         _ord_[sprintf("%c", i)] = i