# $Header: /cvs/src/jbofihe/dfasyn/Makefile,v 1.1 2001/07/12 21:15:35 richard Exp $
#
# Makefile for NFA->DFA conversion utility
#
# Copyright (C) Richard P. Curnow  2000-2001
# 
# This program is free software; you can redistribute it and/or modify
# it under the terms of version 2 of the GNU General Public License as
# published by the Free Software Foundation.
# 
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# General Public License for more details.
# 
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
# 
#

CC=gcc
#CFLAGS=-g
#CFLAGS=-O2 -pg
CFLAGS=-O2
OBJ = parse.o scan.o n2d.o expr.o tabcompr.o compdfa.o

all : dfasyn

dfasyn : $(OBJ)
	$(CC) $(CFLAGS) -o dfasyn $(OBJ)

parse.c parse.h : parse.y
	bison -v -d parse.y
	mv parse.tab.c parse.c
	mv parse.tab.h parse.h

parse.o : parse.c n2d.h

scan.c : scan.l
	flex -t -s scan.l > scan.c

scan.o : scan.c parse.h n2d.h

clean:
	rm dfasyn *.o scan.c parse.c parse.h parse.output

