.SUFFIXES: .o .C .c  .cpp


############################################################

include mkflags
include mk.inf

############################################################

C++FLAGS = $(DEBUG) $(ARCH)

.c.o:
	$(CC1) $(ALL_INCLUDES) $(C++FLAGS) -c $(*F).c  -o $*.o

.C.o:
	$(CC) $(ALL_INCLUDES) $(C++FLAGS) -c $(*F).C   -o $*.o

.cpp.o:
	$(CC) $(ALL_INCLUDES) $(C++FLAGS) -c $(*F).cpp -o $*.o


all: $(TARGET)

$(TARGET): $(OBJS)
	$(DLLWRAP) -o $(TARGET) $(OBJS) -mwindows --export-all-symbols $(ALL_LIBS) --output-def $(TARGET).def --driver-name g++
	$(DLLTOOL) --def $(TARGET).def --dllname $(TARGET) --output-lib $(TARGET2)

clean:
	$(RM) -f $(TARGET) $(TARGET2) *.o log.txt


