source: trunk/kBuild/tools/WATCOMC11C-16.kmk@ 2524

Last change on this file since 2524 was 2413, checked in by bird, 15 years ago

copyright year update.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 5.6 KB
Line 
1# $Id: WATCOMC11C-16.kmk 2413 2010-09-11 17:43:04Z bird $
2## @file
3# kBuild Tool Config - Watcom C v11.0c, 16-bit targets.
4#
5# @remarks wrc is untested, so are DLLs, and programs.
6
7#
8# Copyright (c) 2008-2010 knut st. osmundsen <bird-kBuild-spamx@anduin.net>
9#
10# This file is part of kBuild.
11#
12# kBuild is free software; you can redistribute it and/or modify
13# it under the terms of the GNU General Public License as published by
14# the Free Software Foundation; either version 2 of the License, or
15# (at your option) any later version.
16#
17# kBuild is distributed in the hope that it will be useful,
18# but WITHOUT ANY WARRANTY; without even the implied warranty of
19# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20# GNU General Public License for more details.
21#
22# You should have received a copy of the GNU General Public License
23# along with kBuild; if not, write to the Free Software
24# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25#
26#
27# As a special exception you are granted permission to include this file, via
28# the kmk include directive, as you wish without this in itself causing the
29# resulting makefile, program or whatever to be covered by the GPL license.
30# This exception does not however invalidate any other reasons why the makefile,
31# program, whatever should not be covered the GPL.
32#
33#
34
35TOOL_WATCOMC11C-16 = Watcom C/C++ v11.0c - 16-bit targets.
36TOOL_WATCOMC11C-16_EXTENDS = WATCOMC11C
37TOOL_WATCOMC11C-16_ASFLAGS.win ?= -bt=windows
38TOOL_WATCOMC11C-16_CFLAGS.win ?= -bt=windows
39TOOL_WATCOMC11C-16_CXXFLAGS.win ?= -bt=windows
40TOOL_WATCOMC11C-16_RCFLAGS.win ?= -bt=windows
41TOOL_WATCOMC11C-16_LDFLAGS.win ?= -bt=windows
42
43TOOL_WATCOMC11C-16_COMPILE_C_DEPEND =
44TOOL_WATCOMC11C-16_COMPILE_C_DEPORD =
45TOOL_WATCOMC11C-16_COMPILE_C_OUTPUT = $(obj).err
46define TOOL_WATCOMC11C-16_COMPILE_C_CMDS
47 $(QUIET) $(call TOOL_WATCOMC11C_ENV_SETUP) $(TOOL_WATCOMC11C_CC16) \
48 $(flags) \
49 $(addsuffix , $(addprefix -i=, $(subst /,\\,$(incs)))) \
50 $(addprefix -d, $(defs)) \
51 -fo=$(subst /,\\,$(obj)) \
52 -fr=$(subst /,\\,$(obj)).err \
53 $(subst /,\\,$(abspath $(source)))
54 $(QUIET)$(APPEND) -n $(obj).err
55## @todo dependencies
56endef
57
58TOOL_WATCOMC11C-16_COMPILE_CXX_DEPEND =
59TOOL_WATCOMC11C-16_COMPILE_CXX_DEPORD =
60TOOL_WATCOMC11C-16_COMPILE_CXX_OUTPUT = $(obj).err
61define TOOL_WATCOMC11C-16_COMPILE_CXX_CMDS
62 $(QUIET) $(call TOOL_WATCOMC11C_ENV_SETUP) $(TOOL_WATCOMC11C_CXX16) \
63 $(flags) \
64 $(addsuffix , $(addprefix -i=, $(subst /,\\,$(incs)))) \
65 $(addprefix -d, $(defs)) \
66 -fo=$(subst /,\\,$(obj)) \
67 -fr=$(subst /,\\,$(obj)).err \
68 $(subst /,\\,$(abspath $(source)))
69 $(QUIET)$(APPEND) -n $(obj).err
70## @todo dependencies
71endef
72
73TOOL_WATCOMC11C-16_COMPILE_RC_OUTPUT =
74TOOL_WATCOMC11C-16_COMPILE_RC_DEPEND =
75TOOL_WATCOMC11C-16_COMPILE_RC_DEPORD =
76define TOOL_WATCOMC11C-16_COMPILE_RC_CMDS
77 $(QUIET) $(call TOOL_WATCOMC11C_ENV_SETUP) \
78 $(TOOL_WATCOMC11C_RC) -r\
79 $(flags) \
80 $(addprefix -i=, $(subst /,\\,$(incs))) \
81 $(addprefix -d, $(defs))\
82 -fo=$(subst /,\\,$(obj)) \
83 $(subst /,\\,$(abspath $(source)))
84endef
85
86TOOL_WATCOMC11C-16_LINK_LIBRARY_OUTPUT = ## @todo $(outbase).rsp
87TOOL_WATCOMC11C-16_LINK_LIBRARY_DEPEND = $(othersrc)
88TOOL_WATCOMC11C-16_LINK_LIBRARY_DEPORD =
89define TOOL_WATCOMC11C-16_LINK_LIBRARY_CMDS
90 $(QUIET)$(APPEND) -tn $(outbase).rsp $(foreach obj,$(subst /,\,$(objs) $(othersrc)),'+"$(obj)"')
91 $(QUIET)$(TOOL_WATCOMC11C_ENV_SETUP) $(TOOL_WATCOMC11C_AR) $(flags) $(subst /,\\,$(out)) @$(outbase).rsp
92endef
93
94TOOL_WATCOMC11C-16_LINK_PROGRAM_OUTPUT = $(outbase).map
95TOOL_WATCOMC11C-16_LINK_PROGRAM_DEPEND = $(foreach lib,$(libs),$(if $(findstring $(lib),$(subst /,x,$(lib))),, $(lib))) $(othersrc)
96TOOL_WATCOMC11C-16_LINK_PROGRAM_DEPORD =
97define TOOL_WATCOMC11C-16_LINK_PROGRAM_CMDS
98 $(QUIET)$(call TOOL_WATCOMC11C_ENV_SETUP,$(subst $(SP),,$(addsuffix ;,$(libpath)))) \
99 $(TOOL_WATCOMC11C_LD16) \
100 $(flags) \
101 -fe=$(subst /,\\,$(out)) \
102 -fm=$(subst /,\\,$(outbase).map) \
103 $(subst /,\\,$(filter-out %.res,$(objs))) \
104 $(subst /,\\,$(libs)) \
105 $(subst /,\\,$(othersrc))
106 $(if $(filter %.res,$(objs)), $(QUIET)$(call TOOL_WATCOMC11C_ENV_SETUP) \
107 $(TOOL_WATCOMC11C_RC) \
108 $(filter -bt=%,$(flags)) \
109 /fe=$(subst /,\\,$(out)) \
110 $(subst /,\\,$(filter %.res,$(objs))))
111endef
112
113TOOL_WATCOMC11C-16_LINK_DLL_OUTPUT = $(outbase).map
114TOOL_WATCOMC11C-16_LINK_DLL_DEPEND = $(foreach lib,$(libs),$(if $(findstring $(lib),$(subst /,x,$(lib))),, $(lib))) $(othersrc)
115TOOL_WATCOMC11C-16_LINK_DLL_DEPORD =
116define TOOL_WATCOMC11C-16_LINK_DLL_CMDS
117 $(QUIET)$(call TOOL_WATCOMC11C_ENV_SETUP,$(subst $(SP),,$(addsuffix ;,$(libpath)))) \
118 $(TOOL_WATCOMC11C_LD16) \
119 $(flags) \
120 -fe=$(subst /,\\,$(out)) \
121 -fm=$(subst /,\\,$(outbase).map) \
122 $(subst /,\\,$(filter-out %.res,$(objs))) \
123 $(subst /,\\,$(libs)) \
124 $(subst /,\\,$(othersrc))
125 $(if $(filter %.res,$(objs)), $(QUIET)$(call TOOL_WATCOMC11C_ENV_SETUP) \
126 $(TOOL_WATCOMC11C_RC) \
127 $(filter -bt=%,$(flags)) \
128 /fe=$(subst /,\\,$(out)) \
129 $(subst /,\\,$(filter %.res,$(objs))))
130endef
131
132TOOL_WATCOMC11C-16_LINK_SYSMOD_OUTPUT = $(outbase).map
133TOOL_WATCOMC11C-16_LINK_SYSMOD_DEPEND = $(foreach lib,$(libs),$(if $(findstring $(lib),$(subst /,x,$(lib))),, $(lib))) $(othersrc)
134TOOL_WATCOMC11C-16_LINK_SYSMOD_DEPORD =
135define TOOL_WATCOMC11C-16_LINK_SYSMOD_CMDS
136 $(QUIET)$(call TOOL_WATCOMC11C_ENV_SETUP,$(subst $(SP),,$(addsuffix ;,$(libpath)))) \
137 $(TOOL_WATCOMC11C_LD16) \
138 $(flags) \
139 -fe=$(subst /,\\,$(out)) \
140 -fm=$(subst /,\\,$(outbase).map) \
141 $(subst /,\\,$(filter-out %.res,$(objs))) \
142 $(subst /,\\,$(libs)) \
143 $(subst /,\\,$(othersrc))
144 $(if $(filter %.res,$(objs)), $(QUIET)$(call TOOL_WATCOMC11C_ENV_SETUP) \
145 $(TOOL_WATCOMC11C_RC) \
146 $(filter -bt=%,$(flags)) \
147 /fe=$(subst /,\\,$(out)) \
148 $(subst /,\\,$(filter %.res,$(objs))))
149endef
150
Note: See TracBrowser for help on using the repository browser.