## Makefile for miktex.lib (Win32 version)		-*- Makefile -*-
## Time-stamp: "97/08/02 14:26:24 mik"

!include ..\miktex.inc

srcdir = .

OBJECTS = c4plib.obj c4pstart.obj getopt.obj getopt1.obj miktex.obj fnamedb.obj

all: miktex.dll miktex.lib findfile.exe

.c.obj:
	$(CC) -c -I$(srcdir) -DMIKTEX_DLL -DIN_MIKTEX_DLL -DSTRICT \
		$(release_info) -MD -O2 $(cflags) $(CFLAGS) $<

findfile.exe: findfile.c miktex.lib
	$(CC) -DMIKTEX_DLL $(release_info) $(cflags) $(CFLAGS) -MD \
		findfile.c /link $(ldflags) miktex.lib

miktex.dll miktex.lib: $(OBJECTS) miktex.res
	link $(ldflags) $(LDFLAGS) -dll -out:miktex.dll \
		-implib:miktex.lib $(OBJECTS) miktex.res advapi32.lib

miktex.res: miktex.version miktex.rc
	rc miktex.rc

install: miktex.lib miktex.dll
	$(INSTALL_PROGRAM) miktex.dll $(bindir)\miktex.dll

uninstall:

mostlyclean:
	-del *.obj
	-del *.res
	-del *.exp

clean: mostlyclean
	-del miktex.lib
	-del miktex.dll
	-del findfile.exe
	-del *.ilk
	-del *.pdb

distclean: clean
	-del *.opt
	-del makefile.win32.bak

realclean: distclean

depend: c4plib.c c4pstart.c getopt.c getopt1.c miktex.c fnamedb.c
	makedepend -f makefile.win32 -I. $**

# DO NOT DELETE

c4plib.obj: c4plib.h miktex.h
c4pstart.obj: c4plib.h
getopt.obj: getopt.h
getopt1.obj: getopt.h
miktex.obj: c4plib.h miktex.h fnamedb.h miktex.rc miktex.version version.h
fnamedb.obj: miktex.h c4plib.h miktex.rc miktex.version version.h
