#*
#*  sudo version 1.1 allows users to execute commands as root
#*  Copyright (C) 1991  The Root Group, Inc.
#*
#*  This program is free software; you can redistribute it and/or modify
#*  it under the terms of the GNU General Public License as published by
#*  the Free Software Foundation; either version 1, or (at your option)
#*  any later version.
#*
#*  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., 675 Mass Ave, Cambridge, MA 02139, USA.
#*
#*  If you make modifications to the source, we would be happy to have
#*  them to include in future releases.  Feel free to send them to:
#*      Jeff Nieusma                       nieusma@rootgroup.com
#*      3959 Arbol CT                      (303) 447-8093
#*      Boulder, CO 80301-1752             
#*
#
#   This is the makefile for visudo
#
#
     CC=gcc
#     CC=cc
    LEX=flex
#    LEX=lex
   YACC=bison -y
#   YACC=yacc
CCFLAGS=-I.. -m486 -fomit-frame-pointer -O2
LDFLAGS=-s -N
   LIBS=-lfl
#   LIBS=-ll -ly

visudo		:	lex.yy.o y.tab.o visudo.o
	$(CC) $(CCFLAGS) -o $@ *.o ${LIBS}

y.tab.o y.tab.h :       visudo.yacc ../sudo.h
	$(YACC) -d visudo.yacc
	$(CC) $(CCFLAGS) -c y.tab.c

lex.yy.o        :       visudo.lex y.tab.h ../sudo.h
	$(LEX) visudo.lex
	$(CC) $(CCFLAGS) -c lex.yy.c

visudo.o	:	visudo.c ../sudo.h
	$(CC) $(CCFLAGS) -c visudo.c

clean		:
	-rm -f lex.yy.* y.tab.* *.o visudo
