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

Last change on this file since 145 was 142, checked in by ktk, 25 years ago

Import

  • 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"
37#CFLAGS = -dDEBUG -bt=os2v2 -e60 -hc -d2 -5r -i$(INC) -omlinear -s -w4 -xd -ze -zdp -zl -zq -nt=CODE32 -zff -zgf -zu -zp1 -mc
38CFLAGS = -dDEBUG -bt=os2v2 -e60 -hc -d2 -5r -i$(INC) -omlinear -s -w4 -xd -ze -zdp -zl -zq -nt=CODE32 -zff -zgf -zp1 -mf -DKEE
39!else
40#CFLAGS = -bt=os2v2 -e60 -5r -i$(INC) -omlinear -s -w4 -xd -ze -zdp -zl -zq -nt=CODE32 -zff -zgf -zu -zp1 -mc
41CFLAGS = -bt=os2v2 -e60 -5r -i$(INC) -omlinear -s -w4 -xd -ze -zdp -zl -zq -nt=CODE32 -zff -zgf -zp1 -mf -DKEE
42!endif
43
44CC = WPP386 $(CFLAGS) $(IWC)
45CCSMALL = WPP386 $(CFLAGS_SMALL) $(IWC)
46
47!if "$(DEBUG)" == "1"
48ASFLAGS = -Mb -Li -Sv:M510 -D:KEE
49!else
50ASFLAGS = -Mb -Li -Sv:M510 -D:KEE
51!endif
52ASM = alp $(ASFLAGS) $(INCA)
53
54DFLAGS = -l -s
55DIS = WDISASM $(DFLAGS)
56
57!if "$(DEBUG)" == "1"
58LFLAGS = system os2v2 physdevice option int, dosseg, map, eliminate, mang, tog sort global d codeview
59!else
60LFLAGS = system os2v2 physdevice option int, dosseg, map, eliminate, mang, tog sort global
61!endif
62QFLAGS = system os2 option quiet, map, align=512
63LINK = WLINK $(LFLAGS)
64
65BFLAGS = -s -t -c -b -q -n
66LIB = WLIB $(BFLAGS)
67
68IFLAGS = /nologo
69IMPLIB = IMPLIB $(IFLAGS)
70
71.obj.lst:
72 $(DIS) $*
73
74.c.obj: .AUTODEPEND
75 $(CC) $*.c
76
77.cpp.obj: .AUTODEPEND
78 $(CC) $*.cpp
79
80.asm.obj: .AUTODEPEND
81 $(ASM) $*.asm -Fl:$*.lst
82
83.def.lib:
84 $(IMPLIB) $*.lib $*.def
85
86#===================================================================
87#
88# List of source files
89#
90#===================================================================
91FILEFIRST= startup.obj
92FILE2 = strategy.obj
93FILE3 = init.obj
94FILE4 = devhlp.obj
95FILE5 = idc.obj dispatch.obj
96FILE6 = impdos.lib
97FILE7 = impkee.lib
98FILE8 = ..\sblive\sblive32.lib ..\lib32\linuxlib.lib
99FILELAST = end.obj
100FILES = $(FILEFIRST) $(FILE0) $(FILE1) $(FILE2) $(FILE3) $(FILE4) $(FILE5) $(FILE6) $(FILE7) $(FILE8) $(FILE9) $(FILELAST)
101TARGET = sblive32
102WMAPNAME = sblive32.wmap
103
104
105
106#===================================================================
107#
108# Specific dependencies
109#
110#===================================================================
111all: $(TARGET).sys
112
113$(TARGET).lnk: makefile.os2 ..\include\version.mak
114 @%write $^@ name $(TARGET).sys
115 @%write $^@ option alignment=16
116 @%write $^@ option description '@$#$(_VENDOR):$(_VERSION)$#@'
117 @%write $^@ option map=$(WMAPNAME)
118 @%write $^@ import DOSIODELAYCNT DOSCALLS.427
119 @for %f in ($(FILES)) do @%append $^@ file %f
120 @%write $^@ library $(%WATCOM)\lib386\os2\clib3r.lib
121
122$(TARGET).sys: $(TARGET).lnk $(FILES)
123 $(LINK) @$(TARGET).lnk
124 ..\drv16\wat2map $(WMAPNAME) $(TARGET).MAP
125 mapsym $(TARGET).MAP
126 copy $(TARGET).sys ..\bin
127 copy $(TARGET).sym ..\bin
128
129clean:
130 del *.obj *.err *.lnk *.sys *.sym *.lst *.map *.wmap
131
Note: See TracBrowser for help on using the repository browser.