Reference:
http://zhouyang340.blog.163.com/blog/static/3024095920121187544204/
Http://blog.csdn.net/hongjiujing/archive/2007/09/22/1795941.aspx
Http://blog.csdn.net/truelie/archive/2007/01/31/1499300.aspx
Compile a Linux c system, including lexical and parsing modules, with Bison and Flex on Linux.
YACC is the generator of a grammar analyzer, and Bison is the GNU version of Yacc. Lex and YACC are tools for constructing lexical analyzers and grammar interpreters, and you can easily construct a grammar interpreter using Lex and YACC.
First make
Error 1:
Debian:/home/a/boa-0.94.13/src# make
Yacc-d Boa_grammar.y
Make:yacc:Command not found
Make: * * * [Y.TAB.C] Error 127
Workaround:
debian:/home/a/boa-0.94.13/src# Apt-get Install Bison
Error 2:
Debian:/home/a/boa-0.94.13/src# make
Lex Boa_lexer.l
Make:lex:Command not found
Make: * * * [LEX.YY.C] Error 127
Workaround:
debian:/home/a/boa-0.94.13/src# Apt-get Install Flex
Error 3:
Debian:/home/a/sss/boa-0.94.13/src# make
Gcc-g-o2-pipe-wall-i.-c-o UTIL.O UTIL.C
util.c:100:1: error:pasting "T" and "-" does not give a valid preprocessing token
Make: * * * [UTIL.O] Error 1
Workaround:
Modify Src/compat.h
Found it
#define TIMEZONE_OFFSET (foo) foo##->tm_gmtoff
Modified into
#define TIMEZONE_OFFSET (foo) (foo)->tm_gmtoff
And then
debian:/home/a/sss/boa-0.94.13/src# Make Clean
Debian:/home/a/sss/boa-0.94.13/src# make
Appear:
Debian:/home/a/sss/boa-0.94.13/src# make
Make:nothing to is done for ' all '.
Note that make does not check for anything that needs to be compiled, the library or application has been compiled.
Make primarily checks the timestamp, as long as the target is longer than the dependent file, it does not think it needs to be compiled
Boa Server Make Error