Changeset 3250 for trunk/kBuild/tools/GXX3.kmk
- Timestamp:
- Dec 28, 2018, 11:43:52 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified trunk/kBuild/tools/GXX3.kmk ¶
r3121 r3250 37 37 TOOL_GXX3_CC ?= gcc$(HOSTSUFF_EXE) 38 38 TOOL_GXX3_CXX ?= g++$(HOSTSUFF_EXE) 39 TOOL_GXX3_PCH ?= $(TOOL_GXX3_CXX) 39 40 TOOL_GXX3_AS ?= gcc$(HOSTSUFF_EXE) 40 41 ifeq ($(KBUILD_TARGET),solaris) … … 73 74 TOOL_GXX3_CC += -fmessage-length=0 74 75 TOOL_GXX3_CXX += -fmessage-length=0 76 TOOL_GXX3_PCH += -fmessage-length=0 75 77 endif 76 78 … … 85 87 86 88 TOOL_GXX3_CXXOBJSUFF ?= .o 87 TOOL_GXX3_CXXOBJSUFF ?= .o88 89 TOOL_GXX3_CXXFLAGS ?= 89 90 TOOL_GXX3_CXXFLAGS.debug ?= -g … … 92 93 TOOL_GXX3_CXXINCS ?= 93 94 TOOL_GXX3_CXXDEFS ?= 95 96 TOOL_GXX3_PCHOBJSUFF ?= .h.gch 97 TOOL_GXX3_PCHFLAGS ?= $(TOOL_GXX3_CXXFLAGS) 98 TOOL_GXX3_PCHFLAGS.debug ?= $(TOOL_GXX3_CXXFLAGS.debug) 99 TOOL_GXX3_PCHFLAGS.profile ?= $(TOOL_GXX3_CXXFLAGS.profile) 100 TOOL_GXX3_PCHFLAGS.release ?= $(TOOL_GXX3_CXXFLAGS.release) 101 TOOL_GXX3_PCHINCS ?= $(TOOL_GXX3_CXXINCS) 102 TOOL_GXX3_PCHDEFS ?= $(TOOL_GXX3_CXXDEFS) 94 103 95 104 TOOL_GXX3_ASFLAGS ?= -x assembler-with-cpp … … 163 172 # @param $(outbase) Output basename (full). Use this for list files and such. 164 173 # @param $(objsuff) Object suffix. 165 TOOL_GXX3_COMPILE_CXX_DEPEND =166 174 TOOL_GXX3_COMPILE_CXX_DEPORD = 167 175 ifdef KBUILD_USE_KOBJCACHE 168 176 TOOL_GXX3_COMPILE_CXX_USES_KOBJCACHE = 1 177 TOOL_GXX3_COMPILE_CXX_DEPEND = 169 178 TOOL_GXX3_COMPILE_CXX_OUTPUT = $(outbase).ii 170 179 define TOOL_GXX3_COMPILE_CXX_CMDS … … 183 192 endef 184 193 else # !KBUILD_USE_KOBJCACHE 194 TOOL_GXX3_COMPILE_CXX_DEPEND = $($(target)_1_GCC_PCH_FILE) 185 195 TOOL_GXX3_COMPILE_CXX_OUTPUT = 186 196 define TOOL_GXX3_COMPILE_CXX_CMDS 187 197 $(QUIET)$(TOOL_GXX3_CXX) -c\ 188 $(flags) $(addprefix -I, $(incs)) $(addprefix -D, $(defs))\ 189 -Wp,-MD,$(dep) -Wp,-MT,$(obj) -Wp,-MP\ 190 -o $(obj)\ 198 $(flags) $(addprefix -I, $($(target)_1_GCC_PCH_DIR) $(incs)) $(addprefix -D, $(defs))\ 199 -Wp,-MD,$(dep) -Wp,-MT,$(obj) -Wp,-MP\ 200 -o $(obj) $(if-expr defined($(target)_PCH_HDR) \ 201 ,-Winvalid-pch -H -include $(basename $($(target)_1_GCC_PCH_FILE)),) \ 191 202 $(abspath $(source)) 192 203 $(QUIET)$(APPEND) -n "$(dep)" "" "$(source):" "" 193 204 endef 194 205 endif # !KBUILD_USE_KOBJCACHE 206 207 208 ## Precompile C++ header. 209 # @param $(target) Normalized main target name. 210 # @param $(source) Source filename (relative). 211 # @param $(obj) Object file name. This shall be (re)created by the compilation. 212 # @param $(dep) Dependcy file. This shall be (re)created by the compilation. 213 # @param $(flags) Flags. 214 # @param $(defs) Definitions. No -D or something. 215 # @param $(incs) Includes. No -I or something. 216 # @param $(dirdep) Directory creation dependency. 217 # @param $(deps) Other dependencies. 218 # @param $(outbase) Output basename (full). Use this for list files and such. 219 # @param $(objsuff) Object suffix. 220 TOOL_GXX3_COMPILE_PCH_DEPORD = $($(target)_1_GCC_PCH_DIR) 221 TOOL_GXX3_COMPILE_PCH_DEPEND = 222 TOOL_GXX3_COMPILE_PCH_OUTPUT = $($(target)_1_GCC_PCH_FILE) 223 define TOOL_GXX3_COMPILE_PCH_CMDS 224 $(QUIET)$(TOOL_GXX3_PCH) -c\ 225 $(flags) $(addprefix -I, $($(target)_1_GCC_PCH_DIR) $(incs)) $(addprefix -D, $(defs))\ 226 -Wp,-MD,$(dep) -Wp,-MT,$(obj) -Wp,-MP\ 227 -o $(obj)\ 228 $(abspath $(source)) 229 $(INSTALL) --hard-link-files-when-possible -m 0644 -- "$(obj)" "$($(target)_1_GCC_PCH_FILE)" 230 $(QUIET)$(APPEND) -n "$(dep)" "" "$(source):" "" 231 endef 195 232 196 233
Note:
See TracChangeset
for help on using the changeset viewer.