
Untitled
By: a guest on
Aug 1st, 2012 | syntax:
None | size: 0.92 KB | hits: 10 | expires: Never
GNUmakefile cannot compile bison and flex programs
lex.yy.c: src/dplc/add_inp.flex bison.tab.c src/dplc/bison.tab.h
flex src/dplc/add_inp.flex
bison.tab.c: src/dplc/bison.y
bison -d -t src/dplc/bison.y
a.exe: src/dplc/main.c lex.yy.c bison.tab.c
gcc src/dplc/main.c
clean:
rm src/dplc/bison.tab.c src/dplc/bison.tab.h src/dplc/lex.yy.c src/dplc/a.exe
make: *** No rule to make target `src/dplc/bison.y', needed by `bison.tab.c'. Stop.
make: *** No rule to make target `src/dplc/bison.y', needed by `bison.tab.c'. Stop.
CC=gcc
IDIR =src/dplc/
CFLAGS=-I$(IDIR)
a.exe: src/dplc/main.c lex.yy.c bison.tab.c
$(CC) src/dplc/main.c $(CFLAGS) -I.
bison.tab.c: src/dplc/bison.y
bison -d -t src/dplc/bison.y
lex.yy.c: src/dplc/add_inp.flex bison.tab.c bison.tab.h
flex src/dplc/add_inp.flex
clean:
rm bison.tab.c bison.tab.h lex.yy.c a.exe