The include file is generated elsewhere

svn path=/trunk/; revision=9374
This commit is contained in:
Jörg Mayer 2003-12-21 03:17:54 +00:00
parent 77c6d4e968
commit 9345308925
2 changed files with 2 additions and 27 deletions

View File

@ -9,7 +9,6 @@
.deps
.gdb_history
.libs
FAQTMP*
Makefile
Makefile.in
aclocal.m4

View File

@ -1,14 +1,10 @@
#!/bin/sh
#
# $Id: make-faq,v 1.5 2003/12/21 03:06:49 jmayer Exp $
# $Id: make-faq,v 1.6 2003/12/21 03:16:48 jmayer Exp $
#
# Make-faq - Creates a plain text version of the Ethereal FAQ
# from http://www.ethereal.com/faq
# Split the FAQ every LINECOUNT lines so the strings don't become too long
# for some compilers.
LINECOUNT=400
rm -f FAQ
cat >FAQ <<EOF
@ -25,28 +21,8 @@ EOF
lynx -dump -nolist "http://www.ethereal.com/faq" | sed -e '1,/INDEX/d' >>FAQ
# Create an #include'able version for help/faq.h
rm -f FAQ.include FAQTMP*
split -l $LINECOUNT FAQ FAQTMP
NUM=0
echo "/* THIS FILE IS AUTOMATICALLY GENERATED, DO NOT MODIFY!!! */" >FAQ.include
echo "const char *faq_part[] = {" >>FAQ.include
for i in FAQTMP*; do
if [ $NUM -ne 0 ]; then
echo "," >>FAQ.include
echo >>FAQ.include
fi
sed -e 's/\\/\\\\/g' -e 's/"/\\"/g' -e 's/^/"/' -e 's/$/\\n"/' <$i >>FAQ.include
NUM=`expr $NUM + 1`
done
echo "};" >>FAQ.include
echo "#define FAQ_PARTS $NUM" >>FAQ.include
SIZE=`wc -c FAQ | tr -d ' A-Za-z'`
echo "#define FAQ_SIZE $SIZE" >>FAQ.include
rm -f FAQTMP*
echo
echo "Now move FAQ to help/faq.txt and FAQ.include to help/faq.h"
echo "Now verfiy everything is OK and move FAQ to help/faq.txt"
echo
exit 0