-
Notifications
You must be signed in to change notification settings - Fork 39
/
Copy pathconfig.std
80 lines (66 loc) · 2.21 KB
/
config.std
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
# defaults for DOS; can be overridden in compiler makefiles
DIRSEP = \ #a backslash
ECHOTO = echoto
ECHOTODEP = echoto.bat
LIBLIST = ,
ECHOLIB = echolib
ECHOLIBDEP = echolib.bat
CP = copy
CLO =
SCRIPTS_PATH = ..\scripts
!if $(TOP2LVL)0 == 10
SCRIPTS_PATH = ..\..\scripts
!endif
RMFILES = $(SCRIPTS_PATH)\rmfiles
FIXSTRSOPT = --lib
## Where the pre-compiled SUPPL files are located
## See DOCS\SUPPL.TXT for more information about this library
SUPPL_INC_PATH = ..$(DIRSEP)suppl
SUPPL_LIB_PATH = $(SUPPL_INC_PATH)
## Memory model of FreeCOM
!if $(DEBUG)0 == 10
SHELL_MMODEL=m
DEBUG=-DDEBUG
!else
SHELL_MMODEL=s
DEBUG=-UDEBUG -DNDEBUG
!endif
SHELL_MMODEL_COMP=$(SHELL_MMODEL)
## Compact Memory model used if it requires far data pointers, so uses compact memory model by default
COMPACT_MMODEL=-mc
## Add -DDEBUG=1 below to enable debug support for assembly files
NASMFLAGS = -I$(TOP)/include
!include "$(TOP)/mkfiles/$(COMPILER).mak"
## Which programs to use
NASM = $(XNASM)
## Add -DDEBUG=1 below to enable FreeCOM-debug support for C files
## Add -DNDEBUG=1 below to disable any debug (even assert)
!if $(XMS_SWAP)0 == 10
__XMS_SWAP = -DXMS_SWAP
!endif
!if $(COMPACT_MODEL)0 == 10
MMODEL = $(COMPACT_MMODEL)
!endif
# Default configuration
# added strings.h here because $(CFG) is included everywhere already
## Add -D_NO__DOS_DATE if your compiler does not have no dosdate_t (*)
## Add -D_NO__DOS_TIME if your compiler does not have no dostime_t (*)
## Add -D_NO_FMEMCHR if your compiler does not have no _fmemchr() (*)
## Add -D_NO_FMEMCMP if your compiler does not have no _fmemcmp() (*)
##
## (*) Note: Should be detected by CONFIG.H automatically for Turbo C
## and Borland C compilers.
$(CFG): $(ECHOTODEP) $(CFG_DEPENDENCIES) $(TOP)/config.mak
$(RMFILES) $(CFG)
$(ECHOTO) $(CFG) $(CFLAGS1)
$(ECHOTO) $(CFG) $(CFLAGS2)
$(ECHOTO) $(CFG) $(INCLUDEPATH) -I$(SUPPL_INC_PATH)
$(ECHOTO) $(CFG) -m$(SHELL_MMODEL_COMP) $(MMODEL)
$(ECHOTO) $(CFG) $(DEBUG) $(__XMS_SWAP)
echoto.bat: $(SCRIPTS_PATH)\echoto.bat
$(CP) $(SCRIPTS_PATH)\echoto.bat .
echolib.bat: $(SCRIPTS_PATH)\echolib.bat
$(CP) $(SCRIPTS_PATH)\echolib.bat .
# *Implicit Rules*
.asm.obj:
$(NASM) -f obj $(NASMFLAGS) -DMODEL=$(SHELL_MMODEL) -DCOMPILER=$(COMPILER) $(__XMS_SWAP) $<