# This is the Makefile for mkprintf

#   mkprintf:  wraps any text file to a C function that outputs the
#              original text

#   Copyright (C) 1999  Frank Reker <frank@reker.net>

#   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 2 of the License, 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., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA



VERSION = 1.0

FLEX_SRC = scanner.l
FLEX_OUT = mp_scanner.c

BIN = mkprintf

LEX = flex
CC = gcc
RM = rm -f
CFLAGS = -DVERSION=\"$(VERSION)\"
LFLAGS = 
LINK_OBJECTS = 
LEX_OPTIONS = 


all: $(BIN)

$(BIN): $(FLEX_OUT)
	$(CC) $(CFLAGS) $(LFLAGS) $(LINK_OBJECTS) -o $(BIN) $<

$(FLEX_OUT): $(FLEX_SRC)
	$(LEX) $(LEX_OPTIONS) -o$@ $<

clean:
	$(RM) $(BIN) core *.o

distclean: clean
	$(RM) $(FLEX_OUT)

