VPATH = . ..\..\common\midi ..\..\common\uart
CPP  = g++.exe
CC   = gcc.exe
OBJ  = 16550.o midimax.o midi_win.o
LIBS = -lwinmm
CFLAGS = $(INCS) -DBUILDING_DLL=1 -I..\..\..\src -I..\..\common\midi  -I..\..\common\uart -O3

all: midimax.dll

clean:
	rm *.o
	rm *.dll

DEFFILE=libmidimax.def
STATICLIB=libmidimax.a

midimax.dll: $(OBJ)
	$(CC) -o midimax.dll -s -shared $(OBJ) $(LIBS) -Wl,--subsystem,windows

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