source: trunk/make/setup.optional.wlink.mk@ 10366

Last change on this file since 10366 was 9243, checked in by bird, 23 years ago

Improved dependencies on the makefiles.

File size: 2.9 KB
Line 
1# $Id: setup.optional.wlink.mk,v 1.6 2002-09-14 23:31:28 bird Exp $
2
3#
4# Helper file for all the optional stuff which is common for
5# all watcom11xx compilers.
6# Concidering the size of this, it really make sense putting it here.
7#
8MAKE_INCLUDE_LD_OPT = $(PATH_MAKE)\setup.optional.wlink.mk
9
10
11#
12# Linker/defconvert flags.
13#
14_LD_FORMAT = $(BUILD_PLATFORM)
15_LD_SORT = Sort global
16# Option
17_LD_QUIET =
18_LD_DEFAULT_LIBS= ,nodefaultlibs
19_LD_ALIGN =
20_LD_DOSSEG = ,dosseg
21_LD_BASE =
22_LD_PACKCODE =
23_LD_PACKDATA =
24_LD_IGNORECASE = ,caseexact
25_LD_CACHE = ,cache
26
27
28
29!ifdef LD_FORMAT
30! if "$(LD_FORMAT)" == "NE"
31_LD_FORMAT = $(BUILD_PLATFORM)-16
32TOOL_STRIP =
33! else
34! if "$(LD_FORMAT)" == "LX"
35_LD_FORMAT = os2
36! else
37! error error: LD_FORMAT other than NE and LX is not supported by this compiler ($(ENV_NAME)).
38! endif
39! endif
40!endif
41
42!if defined(LD_SORT_GLOBAL)
43_LD_SORT = Sort global
44!endif
45!if defined(LD_SORT_ALPHABETICAL)
46_LD_SORT = Sort alphabetical
47!endif
48!if defined(LD_SORT_BOTH)
49_LD_SORT = Sort global alphabetical
50!endif
51
52# Option
53!if defined(BUILD_QUIET)
54_LD_QUIET = ,quiet
55!endif
56!if defined(LD_ALIGN)
57_LD_ALIGN = ,alignment=$(LD_ALIGN)
58!endif
59!if defined(LD_DEFAULT_LIBS) || defined(ALL_DEFAULT_LIBS)
60_LD_DEFAULT_LIBS =
61!endif
62!if defined(LD_NO_DOSSEG)
63_LD_DOSSEG =
64!endif
65!if defined(LD_DOSSEG)
66_LD_DOSSEG = ,dosseg
67!endif
68!if defined(LD_NO_BASE)
69_LD_BASE =
70!endif
71!if defined(LD_BASE)
72_LD_BASE = offset=$(LD_BASE)
73!endif
74!if defined(LD_NO_PACKCODE)
75_LD_PACKCODE =
76!endif
77!if defined(LD_PACKCODE)
78_LD_PACKCODE = ,packcode=$(LD_PACKCODE)
79!endif
80!if defined(LD_NO_PACKDATA)
81_LD_PACKDATA =
82!endif
83!if defined(LD_PACKDATA)
84_LD_PACKDATA = ,packdata=$(LD_PACKDATA)
85!endif
86!if defined(LD_IGNORECASE) || defined(ALL_IGNORECASE)
87_LD_IGNORECASE = ,nocaseexact
88!endif
89!if defined(LD_NO_IGNORECASE) || defined(ALL_NO_IGNORECASE)
90_LD_IGNORECASE = ,caseexact
91!endif
92!if defined(LD_CACHE)
93_LD_CACHE = ,cache
94!endif
95!if defined(LD_NO_CACHE)
96_LD_CACHE = ,nocache
97!endif
98!if defined(LD_DEF_CACHE)
99_LD_CACHE =
100!endif
101
102
103_LD_OPTIONAL = $(_LD_SORT) Option verbose $(_LD_QUIET) $(_LD_ALIGN) $(_LD_DOSSEG) $(_LD_BASE) $(_LD_PACKCODE) $(_LD_PACKDATA) $(_LD_CACHE) $(_LD_DEFAULT_LIBS)
104
105
106# assert on nonsupported options.
107!if defined(LD_EXTDIC) || defined(LD_NO_EXTDIC)
108! error error: LD_EXTDIC/LD_NO_EXTDIC is not supported by the linker (wlink).
109!endif
110# don't complain!
111#!if defined(LD_OLDCPP) || defined(LD_NO_OLDCPP)
112#! error error: LD_OLDCPP/LD_NO_OLDCPP is not supported by the linker (wlink).
113#!endif
114!if defined(LD_OPTFUNC) || defined(LD_NO_OPTFUNC)
115! error error: LD_DBGPACK/LD_NO_DBGPACK is not supported by the linker (wlink).
116!endif
117
118# assert on obsolete options.
119!if defined(LD_DOSSEG_YES) || defined(LD_DOSSEG_NO)
120! error error: LD_DOSSEG_YES/LD_DOSSEG_NO is obosolete. Use LD_DOSSEG and LD_NO_DOSSEG.
121!endif
122
Note: See TracBrowser for help on using the repository browser.