# -----------------------------------------------------------------
# File name:  MAKEFILE
#
# This file contains the build information necessary to create both
# the application (APPSKEL) and the DLL it calls (DLLSKEL).
#
# This is an NMAKE FILE.
#
# Versions:  Microsoft C 6.00a, Microsoft C/C++ 7.0
#
# Development Team:  Dan Ruder
#
# Written by Microsoft Product Support Services, Windows Developer Support.
#
# Copyright (c) 1991, 1992 Microsoft Corporation.  All rights reserved.
# -----------------------------------------------------------------

all: dllskel.dll appskel.exe

# Defines

# Used for both C 6.0 and C/C++ 7.0
APP_CFLAGS = -c -W3 -AS -G2sw -Zpe -Os /nologo
DLL_CFLAGS = -c -W3 -AMw -G2sw -Zpe -Os /nologo

APP_LINKFLAGS = /NOD/NOE/MAP
DLL_LINKFLAGS = /NOD/NOE/MAP

APP_OBJS = appskel.obj mainwnd.obj init.obj about.obj
DLL_OBJS = dllskel.obj wepcode.obj


# Rules for building DLLSKEL.DLL, the DLL.

dllskel.obj: dllskel.c dllskel.h
    cl $(DLL_CFLAGS) dllskel.c

wepcode.obj: wepcode.c
    cl $(DLL_CFLAGS) -NT WEPSEG wepcode.c

dllskel.dll: $(DLL_OBJS) dllskel.def
    link @<<
    $(DLL_LINKFLAGS) $(DLL_OBJS) libentry.obj
    dllskel.dll
    dllskel.map /map/li
    libw mdllcew
    dllskel.def
<<
    rc dllskel.dll
    mapsym dllskel
    implib dllskel.lib dllskel.def


# Rules for building APPSKEL.EXE, the application that calls the DLL.

appskel.obj: appskel.c appskel.h init.h globals.h
    cl $(APP_CFLAGS) appskel.c

mainwnd.obj: mainwnd.c mainwnd.h about.h globals.h dllskel.h
    cl $(APP_CFLAGS) mainwnd.c

init.obj: init.c init.h mainwnd.h globals.h
    cl $(APP_CFLAGS) init.c

about.obj: about.c about.h
    cl $(APP_CFLAGS) about.c

appskel.res: appskel.rc appskel.h globals.h
    rc -r appskel.rc

appskel.exe: $(APP_OBJS) appskel.def appskel.res
    link @<<
    $(APP_LINKFLAGS) $(APP_OBJS)
    appskel.exe
    appskel /map/li
    libw slibcew dllskel
    appskel.def
<<
    rc appskel.res
    mapsym appskel


# Rules of convenience to remove the extra files in the directory

clean:
    del *.bak
    del *.obj
    del *.res
    del *.map
    del *.sym
    del *.lib

cleaner:
    del *.dll
    del *.exe
    nmake clean
