Your makefile does too much work when only cpp2html.c has been changed:
gcc -g -c cpp2html.c
gcc -g cpp2html.o lex.yy.o
gcc -g -DDEBUG cpp2html.o lex.yy.o -o cpp2html
不起作用,我几乎尝试了每一个序列。我的代码如下:
cpp2html: cpp2html.o lex.yy.o
gcc {g cpp2html.o lex.yy.o
gcc -g -DDEBUG cpp2html.o lex.yy.o -o cpp2html
cpp2html.o: cpp2html.c
gcc -g -c cpp2html.c
lex.yy.c: cppscanner.l
flex cppscanner.l
lex.yy.o: lex.yy.c
gcc -g -c lex.yy.c