blob: 734e742390cb037a7aa46586a022974655897f16 (
plain)
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
|
#
# Defines specific to a particular version of the compiler
#
# Inputs:
# ~~~~~~~
# STATIC - if defined means creating a static library or executable
# PASCAL - if defined means link dll against pascal run-time library
# DEBUG - if defined means building with debug information
#
# Outputs:
# ~~~~~~~~
# CC - name of compiler
# LD - name of linker
# AR - name of librarian
# RC - name of resource compiler
# COMMON_CFLAGS - compiler flags for all targets
# COMMON_LFLAGS - linker flags for all targets
# COMMON_LIBS - linker library files for all targets
# DLL_CFLAGS - compiler flags specific to DLL targets
# DLL_LFLAGS - linker flags specific to DLL targets
# DLL_STARTUP_OBJ - start-up object files for DLL targets
# EXE_CFLAGS - compiler flags specific to EXE targets
# EXE_LFLAGS - linker flags specific to EXE targets
# EXE_STARTUP_OBJ - start-up object files for EXE targets
# LIB_CFLAGS - compiler flags specific to static lib targets
# LIB_LFLAGS - flags specific to static lib targets (passed to
# librarian)
#
!include <$(ACE_ROOT)\include\makeinclude\ace_flags.bor>
#
# Build tools
#
CC = bcc32
LD = ilink32
AR = tlib
RC = brcc32
#
# Common flags
#
!ifdef DEBUG
DEBUG_CFLAGS = -v -y -Od -r- -vi- -k -D_DEBUG
DEBUG_LFLAGS = -v
!else
DEBUG_CFLAGS = -O2 -DNDEBUG
DEBUG_LFLAGS =
!endif
!ifdef STATIC
STATIC_CFLAGS =
STATIC_LFLAGS =
!else
STATIC_CFLAGS = -tWR
STATIC_LFLAGS =
!endif
!ifdef CODEGUARD
CODEGUARD_CFLAGS = -vG
!endif
THREAD_CFLAGS = -D_MT -tWM
WARNINGS_CFLAGS = -w-rvl -w-rch -w-par -w-ccc -w-obs -w-aus -w-pia -w-inl
DEFINES_CFLAGS = -DWIN32;_NO_VCL
QUIET_CFLAGS = -q
MISC_CFLAGS = -a8 -b
COMMON_CFLAGS = $(QUIET_CFLAGS) $(DEBUG_CFLAGS) $(THREAD_CFLAGS) \
$(STATIC_CFLAGS) $(WARNINGS_CFLAGS) $(DEFINES_CFLAGS) \
$(MISC_CFLAGS) $(CODEGUARD_CFLAGS)
COMMON_LFLAGS = $(DEBUG_LFLAGS) $(STATIC_LFLAGS) -x -w-dup -Gn
#
# DLL specific flags
#
DLL_CFLAGS = -tWD
DLL_LFLAGS = -Tpd -Gi
!ifdef PASCAL
DLL_STARTUP_OBJ = c0d32.obj sysinit.obj
!else
DLL_STARTUP_OBJ = c0d32.obj
!endif
#
# EXE specific flags
#
EXE_CFLAGS =
EXE_LFLAGS = -Tpe
!ifdef PASCAL
EXE_STARTUP_OBJ = c0x32.obj sysinit.obj
!else
EXE_STARTUP_OBJ = c0x32.obj
!endif
#
# Static lib specific flags
#
LIB_CFLAGS =
!ifdef DEBUG
LIB_LFLAGS = /C /P4096
!else
LIB_LFLAGS = /C /P512
!endif
#
# VCL lib version number
#
!if $(BCBVER) == 5
VCLVER = 50
!else
VCLVER = 40
!endif
#
# Libraries to be linked
#
!ifdef CODEGUARD
CODEGUARD_LIB = cg32.lib
!endif
!ifdef STATIC
!ifdef PASCAL
COMMON_LIBS = $(CODEGUARD_LIB) import32.lib vcl$(VCLVER).lib vcle$(VCLVER).lib cp32mt.lib ws2_32.lib
!else
COMMON_LIBS = $(CODEGUARD_LIB) import32.lib cw32mt.lib ws2_32.lib
!endif
!else
!ifdef PASCAL
COMMON_LIBS = $(CODEGUARD_LIB) import32.lib vcl$(VCLVER).bpi vcle$(VCLVER).lib cp32mti.lib ws2_32.lib
!else
COMMON_LIBS = $(CODEGUARD_LIB) import32.lib cw32mti.lib ws2_32.lib
!endif
!endif
|