Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #declaring variables. accessed with $ sign in later use.
- #CC will be the compiler I am using. CFLAGS are compiler flags.
- #YACCFLAGS are yacc flags.
- CC = g++
- CFLAGS = -c -Wall
- PARGEN = bison
- LEXPARGENFLAGS = -d
- LEXER = flex
- .PHONY : clean
- clean:
- rm lex.yy.o y.tab.o lex.yy.c y.tab.c y.tab.h a.out
- .PHONY : build run
- build:
- $(PARGEN) $(PARGENFLAGS) pl0yacc.ypp
- $(LEXER) pl0Lex.l
- $(CC) $(CFLAGS) -lfl lex.yy.c pl0yacc.tab.cpp
- $(CC) lex.yy.o pl0yacc.tab.o -o a.out
- run: build
- ./a.out<testInput
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement