#-*- Makefile -*-
include ../../gnuwin32/MkRules

CFLAGS = -I../../include -I. -O2 -DWIN32

all: libRpcre.a

pcre.o: pcre.c chartables.h
libRpcre.a: get.o maketables.o pcre.o study.o

## this can't be used if cross-building, so ship the file
ifneq ($(strip $(BUILD)),CROSS)
dftables.exe: dftables.o
chartables.h: dftables.exe
	./dftables chartables.h
else
chartables.h: chartables.h.win 
	$(CP) chartables.h.win chartables.h
endif

clean:
	$(RM) *.o *~ libRpcre.a

distclean: clean
	$(RM) chartables.h dftables.exe
