Merge pull request #15 from catseye/build-on-msvc
Build on MSVC
Chris Pressey authored 3 years ago
GitHub committed 3 years ago
|
0 |
# NMAKE Makefile for bef.
|
|
1 |
|
|
2 |
PROGS=bin\bef.exe bin\befprof.exe bin\bef2c.exe
|
|
3 |
CC=cl
|
|
4 |
O=.obj
|
|
5 |
RM_F=del
|
|
6 |
|
|
7 |
WARNS= -Wall -wd4820 -wd4131 -wd4459 -wd4242 -wd4244 -wd4996 \
|
|
8 |
-wd4668 -wd4255 -wd4710 -wd4706 -wd4702 -wd4711 -wd4456 -wd5045
|
|
9 |
|
|
10 |
CFLAGS=$(CFLAGS) -Ox -nologo
|
|
11 |
CFLAGS=$(CFLAGS) $(WARNS) $(EXTRA_CFLAGS)
|
|
12 |
|
|
13 |
!ifdef DEBUG
|
|
14 |
CFLAGS=$(CFLAGS) -Zi
|
|
15 |
!endif
|
|
16 |
|
|
17 |
all: $(PROGS)
|
|
18 |
|
|
19 |
bin\bef.exe: src\bef.c
|
|
20 |
$(CC) $(CFLAGS) src\bef.c -Fe:bin\bef
|
|
21 |
|
|
22 |
bin\befprof.exe: src\befprof.c
|
|
23 |
$(CC) $(CFLAGS) src\befprof.c -Fe:bin\befprof
|
|
24 |
|
|
25 |
bin\bef2c.exe: src\bef2c.c
|
|
26 |
$(CC) $(CFLAGS) src\bef2c.c -Fe:bin\bef2c
|
|
27 |
|
|
28 |
clean:
|
|
29 |
$(RM_F) *$(O) src\*$(O)
|
|
30 |
|
|
31 |
distclean:
|
|
32 |
$(RM_F) $(PROGS)
|
62 | 62 |
DICE C 3.15 (AmigaDOS 1.3)
|
63 | 63 |
DJGPP 2.05 gcc 8.1.0 (32-bit Protected-Mode, FreeDOS 1.1)
|
64 | 64 |
Borland C++ v3.1 (16-bit, FreeDOS 1.1)
|
|
65 |
Microsoft Visual C++ 14.15 (see NMakefile)
|
65 | 66 |
|
66 | 67 |
Has, in the Past, been Known to Compile Under:
|
67 | 68 |
|
|
76 | 77 |
-1 onto the stack instead of an undefined value;
|
77 | 78 |
added -u option to retain old behaviour in this case
|
78 | 79 |
(thanks to James Holderness for noticing and suggesting)
|
|
80 |
support for compiling with MSVC (also by James Holderness)
|
79 | 81 |
|
80 | 82 |
v2.23: Aug 2012, Chris Pressey
|
81 | 83 |
delay given with -y now actually happens when compiled
|
|
176 | 178 |
# include <console.h>
|
177 | 179 |
# define CONSOLE 1
|
178 | 180 |
#endif /* __MWERKS__ */
|
|
181 |
#ifdef _MSC_VER
|
|
182 |
# define sleep(s) _sleep(1000 * s)
|
|
183 |
#endif /* _MSC_VER */
|
179 | 184 |
|
180 | 185 |
/********************************************************** #DEFINE'S */
|
181 | 186 |
|
49 | 49 |
gcc 4.5.3 (NetBSD 6.1.5)
|
50 | 50 |
DJGPP 2.05 gcc 8.1.0 (32-bit Protected-Mode, FreeDOS 1.1)
|
51 | 51 |
Borland C++ v3.1 (16-bit, FreeDOS 1.1)
|
|
52 |
Microsoft Visual C++ 14.15 (see NMakefile)
|
52 | 53 |
|
53 | 54 |
Has, in the Past, been Known to Compile Under:
|
54 | 55 |
|
61 | 61 |
DJGPP 2.05 gcc 8.1.0 (32-bit Protected-Mode, FreeDOS 1.1)
|
62 | 62 |
Borland C++ v3.1 (16-bit, FreeDOS 1.1)
|
63 | 63 |
(NOTE: use "compact" or "large" memory model!)
|
|
64 |
Microsoft Visual C++ 14.15 (see NMakefile)
|
64 | 65 |
|
65 | 66 |
Has, in the Past, been Known to Compile Under:
|
66 | 67 |
|