source: sbliveos2/trunk/drv32/makefile.os2@ 172

Last change on this file since 172 was 152, checked in by sandervl, 25 years ago

misc updates

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 4.1 KB
Line 
1#******************************************************************************
2# Makefile for 32 bits OS/2 SB Live driver
3#
4# Copyright 2000 Sander van Leeuwen (sandervl@xs4all.nl)
5#
6# This program is free software; you can redistribute it and/or
7# modify it under the terms of the GNU General Public License as
8# published by the Free Software Foundation; either version 2 of
9# the License, or (at your option) any later version.
10#
11# This program is distributed in the hope that it will be useful,
12# but WITHOUT ANY WARRANTY; without even the implied warranty of
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14# GNU General Public License for more details.
15#
16# You should have received a copy of the GNU General Public
17# License along with this program; if not, write to the Free
18# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139,
19# USA.
20#
21#******************************************************************************
22!include ..\include\version.mak
23
24INC = .;$(%WATCOM)\H;..\runtime;..\include;$(%DDK)\base\h
25INCA = -I:$(%DDK)\BASE\INC
26
27#===================================================================
28#
29# Auto-dependency information
30#
31#===================================================================
32.ERASE
33.SUFFIXES:
34.SUFFIXES: .lst .obj .lib .cpp .c .asm .def
35
36!if "$(DEBUG)" == "1"
37CFLAGS = -dDEBUG -bt=os2v2 -e60 -hc -d2 -5r -i$(INC) -omlinear -s -w4 -xd -ze -zdp -zl -zq -nt=CODE32 -zff -zgf -zp1
38ASFLAGS = -Mb -Li -Sv:M510
39!else
40CFLAGS = -bt=os2v2 -e60 -5r -i$(INC) -omlinear -s -w4 -xd -ze -zdp -zl -zq -nt=CODE32 -zff -zgf -zp1
41ASFLAGS = -Mb -Li -Sv:M510
42!endif
43
44!if "$(KEE)" == "1"
45CFLAGS = $(CFLAGS) -mf -DKEE
46ASFLAGS = $(ASFLAGS) -D:KEE
47LNKFILE = sblivekee.lnk
48!else
49CFLAGS = $(CFLAGS) -mc -zu
50LNKFILE = sblive.lnk
51!endif
52
53CC = WPP386 $(CFLAGS) $(IWC)
54ASM = alp $(ASFLAGS) $(INCA)
55
56DFLAGS = -l -s
57DIS = WDISASM $(DFLAGS)
58
59!if "$(DEBUG)" == "1"
60LFLAGS = system os2v2 physdevice option int, dosseg, map, eliminate, mang, tog sort global d codeview
61!else
62LFLAGS = system os2v2 physdevice option int, dosseg, map, eliminate, mang, tog sort global
63!endif
64QFLAGS = system os2 option quiet, map, align=512
65LINK = WLINK $(LFLAGS)
66
67BFLAGS = -s -t -c -b -q -n
68LIB = WLIB $(BFLAGS)
69
70IFLAGS = /nologo
71IMPLIB = IMPLIB $(IFLAGS)
72
73.obj.lst:
74 $(DIS) $*
75
76.c.obj: .AUTODEPEND
77 $(CC) $*.c
78
79.cpp.obj: .AUTODEPEND
80 $(CC) $*.cpp
81
82.asm.obj: .AUTODEPEND
83 $(ASM) $*.asm -Fl:$*.lst
84
85.def.lib:
86 $(IMPLIB) $*.lib $*.def
87
88#===================================================================
89#
90# List of source files
91#
92#===================================================================
93FILEFIRST= startup.obj
94FILE2 = strategy.obj
95FILE3 = init.obj
96FILE4 = impmvdm.lib devhlp.obj
97FILE5 = idc.obj dispatch.obj
98FILE6 = impdos.lib
99!if "$(KEE)" == "1"
100FILE7 = impkee.lib
101!endif
102FILE8 = ..\sblive\sblive32.lib ..\lib32\linuxlib.lib
103FILELAST = end.obj
104FILES = $(FILEFIRST) $(FILE0) $(FILE1) $(FILE2) $(FILE3) $(FILE4) $(FILE5) $(FILE6) $(FILE7) $(FILE8) $(FILE9) $(FILELAST)
105TARGET = sblive32
106WMAPNAME = sblive32.wmap
107
108
109
110#===================================================================
111#
112# Specific dependencies
113#
114#===================================================================
115all: $(TARGET).sys
116
117$(LNKFILE): makefile.os2 ..\include\version.mak
118 @%write $^@ name $(TARGET).sys
119 @%write $^@ option alignment=16
120 @%write $^@ option description '@$#$(_VENDOR):$(_VERSION)$#@'
121 @%write $^@ option map=$(WMAPNAME)
122 @for %f in ($(FILES)) do @%append $^@ file %f
123#!if "$(KEE)" == "1"
124 @%write $^@ import DOSIODELAYCNT DOSCALLS.427
125#!endif
126 @%write $^@ library $(%WATCOM)\lib386\os2\clib3r.lib
127
128$(TARGET).sys: $(LNKFILE) $(FILES)
129 $(LINK) @$(LNKFILE)
130 ..\drv16\wat2map $(WMAPNAME) $(TARGET).MAP
131 mapsym $(TARGET).MAP
132 copy $(TARGET).sys ..\bin
133!ifdef KEE
134 copy $(TARGET).sys ..\bin\$(TARGET)kee.sys
135!else
136 copy $(TARGET).sys ..\bin\$(TARGET)w4.sys
137!endif
138 copy $(TARGET).sym ..\bin
139
140clean:
141 del *.obj *.err *.lnk *.sys *.sym *.lst *.map *.wmap *.lib
142
Note: See TracBrowser for help on using the repository browser.