Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Resource.rc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
// Icon
//

IDI_APPICON ICON DISCARDABLE "APP.ICO"
IDI_APPICON ICON DISCARDABLE "App.ico"

//////////////////////////////////////////////////////////////////////////////
//
Expand Down
6 changes: 6 additions & 0 deletions Win16App.mif
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name = Win16App
rname = Resource
LNK = $(name).lnk
OBJS = AboutDlg.obj MainWnd.obj WinMain.obj
resources = App.ico
lnk_dependencies = makefile Win16App.mif master.mif
13 changes: 13 additions & 0 deletions makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
platform = Win16
CC = wcc
CFLAGS = -zW
res1_flags = -bt=windows -30

!include Win16App.mif
!include master.mif

linkit : .PROCEDURE
@%append $(LNK) system windows

bindit : .PROCEDURE
wrc $(RCINCS) Resource.rc Win16App.exe
75 changes: 75 additions & 0 deletions master.mif
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
#
# this make include file is used to build all the win examples
#
# It assumes that the following make variables are declared by the makefile
# that includes it:
#
# CC the name of the C compiler to use to create
# the .obj files
# CDIR directories other than .. to be searched for
# .c files
# CFLAGS any compiler flags needed to build the
# object files
# name the name of the EXE file to build (without
# any extension)
# LNK the name of the linker command file
# OBJS a list of the .obj files needed to build
# the EXE
# resources a list of all files the .res file is
# dependent upon
# res1_flags flags to be used by the resource compiler's
# first pass
# res2_flags flags to be used by the resource compiler's
# second pass
# lnk_dependencies a list of files the linker command file
# depends upon
# platform Win32 for Win9x/Me/NT/2K/XP, Win16 for 3.x/Win386
#
# In addition the makefile must declare a procedure called linkit that
# that can be used to add commands to the linker command file

!ifeq platform Win32
CFLAGS += -I"$(%WATCOM)/h" -I"$(%WATCOM)/h/nt"
RCINCS += -I"$(%WATCOM)/h/nt"
!else
CFLAGS += -I"$(%WATCOM)/h" -I"$(%WATCOM)/h/win"
RCINCS += -I"$(%WATCOM)/h/win"
!endif

CFLAGS += -zq -oaxt -d2 -w8 -fo=.obj

$(name).exe : $(OBJS) $(rname).rc $(LNK)
wlink @$(LNK)
@%make bindit

$(name).res : $(name).rc $(resources)
wrc -q -r -I.. $(RCINCS) -fo=./$(name).res $(res1_flags) $[@

$(LNK) : $(lnk_dependencies)
%create $(LNK)
@%append $(LNK) debug all
@%append $(LNK) name $(name)
@%append $(LNK) op map, quiet
@%make linkit
@for %i in ($(OBJS)) do @%append $(LNK) file %i


.EXTENSIONS:
.EXTENSIONS: .exe
.EXTENSIONS: .obj
.EXTENSIONS: .c .h .dlg .rc .ico .bmp .cur

.c:..;$(CDIR)
.ico:..
.bmp:..
.cur:..
.rc:..
.dlg:..

.c.obj :
$(CC) $(CFLAGS) $[*

clean: .symbolic
rm -f *.obj *.err *.exe *.lnk *.res *.rex *.lib *.sym *.map
rm -f *.lk1 *.mk1 *.mk