# This file is licensed to you under the license specified in the included file
# `LICENSE'. Look there for further details.

#
# May be you wish to change this
#
CC = cc
#
################################


OBJS = parser.tab.o lex.yy.o gengetopt.o gm.o argsdef.o yywrap.o yyerror.o

all: gengetopt

gengetopt: $(OBJS)
	$(CC) -o gengetopt $(OBJS)

lex.yy.c: scanner.lex parser.tab.h
	flex scanner.lex
parser.tab.c: parser.y
	bison -d parser.y

%.o: %.c
	$(CC) $(CFLAGS) $(CPPFLAGS) -c $<

gengetopt.o: ggos.h
gm.o: ggos.h
lex.yy.o: parser.tab.h argsdef.h
parser.tab.o: argsdef.h
argsdef.o: argsdef.h

clean:
	-rm gengetopt core *.o
maintainer-clean: clean
	-rm lex.yy.c parser.tab.c parser.tab.h

