Minor fixes needed to compile with MSVC++ 2005
[nasm/autotest.git] / Mkfiles / Makefile.lcc
blob38d63ffa4ac40b1f663c46b3c67d83d613aef368
1 # host: windows nt/95
2 # target: windows nt/95
3 # Makefile for the Netwide Assembler
5 # The Netwide Assembler is copyright (C) 1996 Simon Tatham and
6 # Julian Hall. All rights reserved. The software is
7 # redistributable under the licence given in the file "Licence"
8 # distributed in the NASM archive.
10 # makefile designed for lcc-win32
11 # lcc-win32 is lcc (c compiler coded by guys from princeton uni)
12 # ported to win32 by jacob navia
13 # available at http://www.remcomp.com/lcc-win32/
15 CFLAGS = -c -O -g2
16 CC = lcc.exe $(CFLAGS)
17 LFLAGS = -subsystem console -s
18 LD = lcclnk.exe $(LFLAGS)
19 OBJ = obj
21 .c.${OBJ}:
22         $(CC) -o $@ $*.c
24 NASM = nasm.${OBJ} nasmlib.${OBJ} float.${OBJ} insnsa.${OBJ} assemble.${OBJ} labels.${OBJ} \
25        parser.${OBJ} outform.${OBJ} output/outbin.${OBJ} output/outaout.${OBJ} output/outcoff.${OBJ} \
26        output/outelf32.${OBJ} output/outelf64.${OBJ} \
27        output/outobj.${OBJ} output/outas86.${OBJ} output/outrdf.${OBJ} output/outdbg.${OBJ} output/outrdf2.${OBJ} \
28        output/outieee.${OBJ} preproc.${OBJ} listing.${OBJ} eval.${OBJ}
30 NDISASM = ndisasm.${OBJ} disasm.${OBJ} sync.${OBJ} nasmlib.${OBJ} insnsd.${OBJ}
32 all: nasm ndisasm
34 # linker response files
35 # that may take long, too much spawning command.com :)
36 NASM.LNK: makefile.lcc
37         echo nasm.$(OBJ) > NASM.LNK
38         echo nasmlib.$(OBJ) >> NASM.LNK
39         echo eval.$(OBJ) >> NASM.LNK
40         echo float.$(OBJ) >> NASM.LNK
41         echo insnsa.$(OBJ) >> NASM.LNK
42         echo assemble.$(OBJ) >> NASM.LNK
43         echo labels.$(OBJ) >> NASM.LNK
44         echo listing.$(OBJ) >> NASM.LNK
45         echo parser.$(OBJ) >> NASM.LNK
46         echo preproc.$(OBJ) >> NASM.LNK
47         echo outform.$(OBJ) >> NASM.LNK
48         echo output/outbin.$(OBJ) >> NASM.LNK
49         echo output/outaout.$(OBJ) >> NASM.LNK
50         echo output/outcoff.$(OBJ) >> NASM.LNK
51         echo output/outelf32.$(OBJ) >> NASM.LNK
52         echo output/outelf64.$(OBJ) >> NASM.LNK
53         echo output/outobj.$(OBJ) >> NASM.LNK
54         echo output/outas86.$(OBJ) >> NASM.LNK
55         echo output/outrdf.$(OBJ) >> NASM.LNK
56         echo output/outrdf2.$(OBJ) >> NASM.LNK
57         echo output/outieee.$(OBJ) >> NASM.LNK
58         echo output/outdbg.$(OBJ) >> NASM.LNK
60 NDISASM.LNK: makefile.lcc
61         echo ndisasm.$(OBJ) > NDISASM.LNK
62         echo disasm.$(OBJ) >> NDISASM.LNK
63         echo sync.$(OBJ) >> NDISASM.LNK
64         echo nasmlib.$(OBJ) >> NDISASM.LNK
65         echo insnsd.$(OBJ) >> NDISASM.LNK
67 nasm: $(NASM) nasm.lnk
68         $(LD) -o nasm.exe @nasm.lnk
70 ndisasm: $(NDISASM) ndisasm.lnk
71         $(LD) -o ndisasm.exe @ndisasm.lnk
73 # These source files are automagically generated from a single
74 # instruction-table file by a Perl script. They're distributed,
75 # though, so it isn't necessary to have Perl just to recompile NASM
76 # from the distribution.
78 insnsa.c insnsd.c insnsi.h insnsn.c: insns.dat insns.pl
79         perl insns.pl insns.dat
81 # These files contains all the standard macros that are derived from
82 # the version number.
83 version.h: version version.pl
84         perl version.pl h < version > version.h
86 version.mac: version version.pl
87         perl version.pl mac < version > version.mac
89 # This source file is generated from the standard macros file
90 # `standard.mac' by another Perl script. Again, it's part of the
91 # standard distribution.
93 macros.c: standard.mac macros.pl version.mac
94         perl macros.pl standard.mac version.mac
96 # These source files are generated from regs.dat by yet another
97 # perl script.
98 regs.c: regs.dat regs.pl
99         perl regs.pl c regs.dat > regs.c
100 regflags.c: regs.dat regs.pl
101         perl regs.pl fc regs.dat > regflags.c
102 regdis.c: regs.dat regs.pl
103         perl regs.pl dc regs.dat > regdis.c
104 regvals.c: regs.dat regs.pl
105         perl regs.pl vc regs.dat > regvals.c
106 regs.h: regs.dat regs.pl
107         perl regs.pl h regs.dat > regs.h
109 clean:
110         rm -f *.${OBJ} nasm.exe ndisasm.exe
112 #-- Magic hints to mkdep.pl --#
113 # @object-ending: ".${OBJ}"
114 # @path-separator: "/"
115 #-- Everything below is generated by mkdep.pl - do not edit --#
116 assemble.${OBJ}: assemble.c preproc.h insns.h pptok.h regs.h regflags.c \
117  config.h version.h nasmlib.h nasm.h regvals.c assemble.h insnsi.h
118 crc64.${OBJ}: crc64.c
119 disasm.${OBJ}: disasm.c insns.h sync.h regdis.c regs.h config.h regs.c \
120  version.h nasm.h insnsn.c names.c insnsi.h disasm.h
121 eval.${OBJ}: eval.c labels.h eval.h regs.h config.h version.h nasmlib.h \
122  nasm.h insnsi.h
123 float.${OBJ}: float.c regs.h config.h version.h nasm.h insnsi.h
124 hashtbl.${OBJ}: hashtbl.c regs.h config.h version.h nasmlib.h hashtbl.h \
125  nasm.h insnsi.h
126 insnsa.${OBJ}: insnsa.c insns.h regs.h config.h version.h nasm.h insnsi.h
127 insnsd.${OBJ}: insnsd.c insns.h regs.h config.h version.h nasm.h insnsi.h
128 insnsn.${OBJ}: insnsn.c
129 labels.${OBJ}: labels.c regs.h config.h version.h hashtbl.h nasmlib.h nasm.h \
130  insnsi.h
131 listing.${OBJ}: listing.c regs.h config.h version.h nasmlib.h nasm.h \
132  insnsi.h listing.h
133 macros.${OBJ}: macros.c
134 names.${OBJ}: names.c regs.c insnsn.c
135 nasm.${OBJ}: nasm.c labels.h preproc.h insns.h parser.h eval.h pptok.h \
136  regs.h outform.h config.h version.h nasmlib.h nasm.h stdscan.h assemble.h \
137  insnsi.h listing.h
138 nasmlib.${OBJ}: nasmlib.c insns.h regs.h config.h version.h nasmlib.h nasm.h \
139  insnsi.h
140 ndisasm.${OBJ}: ndisasm.c insns.h sync.h regs.h config.h version.h nasmlib.h \
141  nasm.h insnsi.h disasm.h
142 outform.${OBJ}: outform.c regs.h config.h outform.h version.h nasm.h \
143  insnsi.h
144 output/outaout.${OBJ}: output/outaout.c regs.h outform.h config.h version.h \
145  nasmlib.h nasm.h stdscan.h insnsi.h
146 output/outas86.${OBJ}: output/outas86.c regs.h outform.h config.h version.h \
147  nasmlib.h nasm.h insnsi.h
148 output/outbin.${OBJ}: output/outbin.c labels.h eval.h regs.h outform.h \
149  config.h version.h nasmlib.h nasm.h stdscan.h insnsi.h
150 output/outcoff.${OBJ}: output/outcoff.c regs.h outform.h config.h version.h \
151  nasmlib.h nasm.h insnsi.h
152 output/outdbg.${OBJ}: output/outdbg.c regs.h outform.h config.h version.h \
153  nasmlib.h nasm.h insnsi.h
154 output/outelf32.${OBJ}: output/outelf32.c regs.h outform.h config.h \
155  version.h nasmlib.h nasm.h stdscan.h insnsi.h
156 output/outelf64.${OBJ}: output/outelf64.c regs.h outform.h config.h \
157  version.h nasmlib.h nasm.h stdscan.h insnsi.h
158 output/outieee.${OBJ}: output/outieee.c regs.h outform.h config.h version.h \
159  nasmlib.h nasm.h insnsi.h
160 output/outmacho.${OBJ}: output/outmacho.c compiler.h regs.h outform.h \
161  config.h version.h nasmlib.h nasm.h insnsi.h
162 output/outobj.${OBJ}: output/outobj.c regs.h outform.h config.h version.h \
163  nasmlib.h nasm.h stdscan.h insnsi.h
164 output/outrdf.${OBJ}: output/outrdf.c regs.h outform.h config.h version.h \
165  nasmlib.h nasm.h insnsi.h
166 output/outrdf2.${OBJ}: output/outrdf2.c rdoff/rdoff.h regs.h outform.h \
167  config.h version.h nasmlib.h nasm.h insnsi.h
168 parser.${OBJ}: parser.c insns.h parser.h float.h regs.h regflags.c config.h \
169  version.h nasmlib.h nasm.h stdscan.h insnsi.h
170 pptok.${OBJ}: pptok.c preproc.h pptok.h nasmlib.h
171 preproc.${OBJ}: preproc.c preproc.h macros.c pptok.h regs.h config.h \
172  version.h hashtbl.h nasmlib.h nasm.h insnsi.h
173 regdis.${OBJ}: regdis.c
174 regflags.${OBJ}: regflags.c
175 regs.${OBJ}: regs.c
176 regvals.${OBJ}: regvals.c
177 stdscan.${OBJ}: stdscan.c insns.h regs.h config.h version.h nasmlib.h nasm.h \
178  stdscan.h insnsi.h
179 sync.${OBJ}: sync.c sync.h
180 tokhash.${OBJ}: tokhash.c insns.h regs.h config.h version.h nasm.h insnsi.h