# This is a part of the Microsoft Foundation Classes C++ library.
# Copyright (C) 1994-1996 Watcom International Corporation
# All rights reserved.
#
# This source code is only intended as a supplement to the
# Microsoft Foundation Classes Reference and Microsoft
# QuickHelp and/or WinHelp documentation provided with the library.
# See these sources for detailed information regarding the
# Microsoft Foundation Classes product.

!ifdef afxdll
!  ifneq afxdll 1
!    error DLLHUSK may only be built with afxdll=1
!  endif
!else
afxdll = 1
!endif

!ifdef debug
!  ifneq debug 1
!    error DLLHUSK may only be built with debug=1
!  endif
!else
debug = 1
!endif

exe = dllhusk.exe
objs = dllhusk.obj mainfrm.obj
res = dllhusk.res
extralib = testdll1.lib testdll2.lib

goal: testdll1.lib testdll2.lib dllhusk.exe .symbolic
    @%null

!include ..\master.mif

.dll.lib:
    wlib -b -c -n $^&.lib +$^&.dll

.obj.dll:
    wlink.exe $(lflags) f $[@ @dll.lnk @$^&.def
    wrc.exe $(rflags) $^*.res $^@

testdll1.lib : testdll1.dll
testdll2.lib : testdll2.dll

testdll1.dll : testdll1.obj dll.lnk testdll1.res testdll1.def
testdll2.dll : testdll2.obj dll.lnk testdll2.res testdll2.def

dll.lnk : $(__MAKEFILES__)
    %create $^@
    @%append $^@ system windows_dll initinstance memory
    @%append $^@ option map
    @%append $^@ reference __clib_WEP_
    @%append $^@ library mfw250$(dbgsuffix).lib
    @%append $^@ library mfwo250$(dbgsuffix).lib
    @%append $^@ library mfwd250$(dbgsuffix).lib
    @%append $^@ library commdlg.lib
    @%append $^@ library shell.lib
    @%append $^@ library mfcoleui.lib
    @%append $^@ library compobj.lib
    @%append $^@ library storage.lib
    @%append $^@ library ole2.lib
    @%append $^@ library ole2disp.lib

testdll1.obj : testdll1.cpp
    wpp.exe $[@ -bd-zu $(cflags) $(dbgflags) -d_WINDLL

testdll2.obj : testdll2.cpp
    wpp.exe $[@ -bd-zu $(cflags) $(dbgflags) -d_WINDLL

