#   DJGPP makefile for Jptui Demo

FLAGS = -MMD -Wall -m486 -O3

all : jpdemo.exe

jpdemo.exe : jpdemo.o jptui.dat
	gcc -s -o jpdemo.exe jpdemo.o ../lib/debug/libjptui.a -lgpp
	../exedat/connect.exe jpdemo.exe jptui.dat
	del jptui.dat

jpdemo.o : jpdemo.cpp
	gcc $(FLAGS) -c jpdemo.cpp -o jpdemo.o

jptui.dat : vocab.fre vocab.ger vocab.eng
	copy ..\lib\debug\jptui.dat .
	../exedat/exedat.exe d jptui.dat vocab.fre
	../exedat/exedat.exe d jptui.dat vocab.eng
	../exedat/exedat.exe d jptui.dat vocab.ger
	../exedat/exedat.exe a jptui.dat vocab.fre 1
	../exedat/exedat.exe a jptui.dat vocab.eng 1
	../exedat/exedat.exe a jptui.dat vocab.ger 1

clean :
	del *.o
	del *.d

DEPS := $(wildcard *.d)
ifneq ($(DEPS),)
include $(DEPS)
endif
