Changeset 184 for trunk/kBuild
- Timestamp:
- Dec 4, 2004, 3:26:54 AM (21 years ago)
- Location:
- trunk/kBuild
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kBuild/footer.kmk
r183 r184 577 577 $(eval obj := $(outbase)$(objsuff)) 578 578 $(eval dep := $(outbase)$(SUFF_DEP)) 579 580 #$ (warning dbg: target=$(target) source=$(source) tool=$(tool) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff)) 579 $(eval deps := \ 580 $($(target)_$(source)_DEPS)\ 581 $($(target)_$(source)_DEPS.$(BUILD_TYPE))\ 582 $($(target)_$(source)_DEPS.$(BUILD_TARGET))\ 583 $($(target)_$(source)_DEPS.$(BUILD_TARGET_ARCH))\ 584 $($(target)_$(source)_DEPS.$(BUILD_TARGET_CPU))\ 585 $($(source)_DEPS)\ 586 $($(source)_DEPS.$(BUILD_TYPE))\ 587 $($(source)_DEPS.$(BUILD_TARGET))\ 588 $($(target)_DEPS)\ 589 $($(target)_DEPS.$(BUILD_TARGET_ARCH))\ 590 $($(target)_DEPS.$(BUILD_TARGET_CPU))) 591 592 593 #$ (warning dbg: target=$(target) source=$(source) tool=$(tool) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) deps=$(deps)) 581 594 ifndef TOOL_$(tool)_COMPILE_$(type) 582 595 $$(warning kBuild: TOOL_$(tool)_COMPILE_$(type) is not defined. source=$(source) target=$(target) ) … … 667 680 $(eval dirdep := $(dir $(lib)).dir_created) 668 681 ## @todo fix dependencies on makefiles an such 669 $(eval deps := )682 $(eval deps := $($(target)_DEPS)) 670 683 671 684 $(eval $(TOOL_$(tool)_LINK_LIBRARY)) … … 798 811 $(eval dirdep := $(dir $(exe)).dir_created) 799 812 ## @todo fix dependencies 800 $(eval deps := )813 $(eval deps := $($(target)_DEPS)) 801 814 # 802 815 $(eval custom_pre := $(strip $(firstword … … 950 963 $(eval dirdep := $(dir $(dll)).dir_created) 951 964 ## @todo fix dependencies 952 $(eval deps := )965 $(eval deps := $($(target)_DEPS)) 953 966 # 954 967 $(eval custom_pre := $(strip $(firstword … … 1116 1129 $(eval dirdep := $(dir $(sys)).dir_created) 1117 1130 ## @todo fix dependencies 1118 $(eval deps := )1131 $(eval deps := $($(target)_DEPS)) 1119 1132 # 1120 1133 $(eval custom_pre := $(strip $(firstword -
trunk/kBuild/tools/GCC.kmk
r181 r184 75 75 # @param $(incs) Includes. No -I or something. 76 76 # @param $(dirdep) Directory creation dependency. 77 # @param $(deps) Other dependencies. 77 78 # 78 79 # @param $(outbase) Output basename (full). Use this for list files and such. 79 80 # @param $(objsuff) Object suffix. 80 81 define TOOL_GCC_COMPILE_C 81 #$ (warning dbg: TOOL_GCC_COMPILE_C: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) )82 $(obj): $(dirdep) $(PATH_CURRENT)/$(source) 82 #$ (warning dbg: TOOL_GCC_COMPILE_C: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) deps=$(deps)) 83 $(obj): $(dirdep) $(PATH_CURRENT)/$(source) $(deps) 83 84 $(call MSG_L2,Compiling $$@ using GCC) 84 85 $(TOOL_GCC_CC) -c\ … … 87 88 -o $$@\ 88 89 $(call ABSPATH,$(source)) 89 90 90 91 endef 91 92 … … 100 101 # @param $(incs) Includes. No -I or something. 101 102 # @param $(dirdep) Directory creation dependency. 103 # @param $(deps) Other dependencies. 102 104 # 103 105 # @param $(outbase) Output basename (full). Use this for list files and such. 104 106 # @param $(objsuff) Object suffix. 105 107 define TOOL_GCC_COMPILE_CXX 106 #$ (warning dbg: TOOL_GCC_COMPILE_CXX: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) )107 $(obj): $(dirdep) $(source) 108 #$ (warning dbg: TOOL_GCC_COMPILE_CXX: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) deps=$(deps)) 109 $(obj): $(dirdep) $(source) $(deps) 108 110 $(call MSG_L2,Compiling $$@ using GCC) 109 111 $(TOOL_GCC_CXX) -c\ … … 112 114 -o $$@\ 113 115 $(call ABSPATH,$(source)) 114 116 115 117 endef 116 118 … … 131 133 $(RM) -f $$@ 132 134 $(TOOL_GCC_AR) $(flags) $$@ $(objs) 133 135 134 136 endef 135 137 … … 155 157 ifneq ($(custom_pre),) 156 158 $(eval $(custom_pre)) 157 endif 159 endif 158 160 $(TOOL_GCC_LD) $(flags) -o $$@ $(objs) \ 159 161 $(foreach lib,$(libs), $(if $(findstring $(lib),$(subst /,x,$(lib))), -l$(patsubst lib%,%,$(basename $(lib))), $(lib))) 160 162 ifneq ($(custom_post),) 161 163 $(eval $(custom_post)) 162 endif 163 164 endif 165 164 166 endef 165 167 … … 185 187 ifneq ($(custom_pre),) 186 188 $(eval $(custom_pre)) 187 endif 189 endif 188 190 $(TOOL_GCC_LD) $(TOOL_GCC_LDFLAGS.dll) $(flags) -o $$@ $(objs) \ 189 191 $(foreach lib,$(libs), $(if $(findstring $(lib),$(subst /,x,$(lib))), -l$(patsubst lib%,%,$(basename $(lib))), $(lib))) 190 192 ifneq ($(custom_post),) 191 193 $(eval $(custom_post)) 192 endif 193 194 endif 195 194 196 endef 195 197 -
trunk/kBuild/tools/GCC3.kmk
r181 r184 80 80 # @param $(incs) Includes. No -I or something. 81 81 # @param $(dirdep) Directory creation dependency. 82 # @param $(deps) Other dependencies. 82 83 # 83 84 # @param $(outbase) Output basename (full). Use this for list files and such. … … 85 86 define TOOL_GCC3_COMPILE_C 86 87 #$ (warning dbg: TOOL_GCC3_COMPILE_C: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff)) 87 $(obj): $(dirdep) $(source) 88 $(obj): $(dirdep) $(source) $(deps) 88 89 $(call MSG_L2,Compiling $$@ using GCC3) 89 90 $(TOOL_GCC3_CC) -c\ … … 92 93 -o $$@\ 93 94 $(call ABSPATH,$(source)) 94 95 95 96 endef 96 97 … … 105 106 # @param $(incs) Includes. No -I or something. 106 107 # @param $(dirdep) Directory creation dependency. 108 # @param $(deps) Other dependencies. 107 109 # 108 110 # @param $(outbase) Output basename (full). Use this for list files and such. … … 110 112 define TOOL_GCC3_COMPILE_CXX 111 113 #$ (warning dbg: TOOL_GCC3_COMPILE_CXX: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff)) 112 $(obj): $(dirdep) $(source) 114 $(obj): $(dirdep) $(source) $(deps) 113 115 $(call MSG_L2,Compiling $$@ using GCC3) 114 116 $(TOOL_GCC3_CXX) -c\ … … 117 119 -o $$@\ 118 120 $(call ABSPATH,$(source)) 119 121 120 122 endef 121 123 … … 136 138 $(RM) -f $$@ 137 139 $(TOOL_GCC3_AR) $(flags) $$@ $(objs) 138 140 139 141 endef 140 142 … … 160 162 ifneq ($(custom_pre),) 161 163 $(eval $(custom_pre)) 162 endif 164 endif 163 165 $(TOOL_GCC3_LD) $(flags) -o $$@ $(objs) \ 164 166 $(foreach p,$(libpath), -L$(p)) \ … … 166 168 ifneq ($(custom_post),) 167 169 $(eval $(custom_post)) 168 endif 169 170 endif 171 170 172 endef 171 173 … … 191 193 ifneq ($(custom_pre),) 192 194 $(eval $(custom_pre)) 193 endif 195 endif 194 196 $(TOOL_GCC3_LD) $(TOOL_GCC3_LDFLAGS.dll) $(flags) -o $$@ $(objs) \ 195 197 $(foreach p,$(libpath), -L$(p)) \ … … 197 199 ifneq ($(custom_post),) 198 200 $(eval $(custom_post)) 199 endif 200 201 endif 202 201 203 endef 202 204 … … 221 223 ifneq ($(custom_pre),) 222 224 $(eval $(custom_pre)) 223 endif 225 endif 224 226 $(TOOL_GCC3_LD_SYSMOD) $(TOOL_GCC3_LDFLAGS.sysmod) $(flags) -o $$@ $(objs) \ 225 227 $(foreach p,$(libpath), -L$(p)) \ … … 227 229 ifneq ($(custom_post),) 228 230 $(eval $(custom_post)) 229 endif 230 231 endef 232 231 endif 232 233 endef 234 -
trunk/kBuild/tools/GCC3OMF.kmk
r182 r184 80 80 # @param $(incs) Includes. No -I or something. 81 81 # @param $(dirdep) Directory creation dependency. 82 # @param $(deps) Other dependencies. 82 83 # 83 84 # @param $(outbase) Output basename (full). Use this for list files and such. 84 85 # @param $(objsuff) Object suffix. 85 86 define TOOL_GCC3OMF_COMPILE_C 86 #$ (warning dbg: TOOL_GCC3OMF_COMPILE_C: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) )87 $(obj): $(dirdep) $(source) 87 #$ (warning dbg: TOOL_GCC3OMF_COMPILE_C: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) deps=$(deps)) 88 $(obj): $(dirdep) $(source) $(deps) 88 89 $(call MSG_L2,Compiling $$@ using GCC3) 89 90 $(TOOL_GCC3OMF_CC) -c\ … … 92 93 -o $$@\ 93 94 $(call ABSPATH,$(source)) 94 95 95 96 endef 96 97 … … 105 106 # @param $(incs) Includes. No -I or something. 106 107 # @param $(dirdep) Directory creation dependency. 108 # @param $(deps) Other dependencies. 107 109 # 108 110 # @param $(outbase) Output basename (full). Use this for list files and such. 109 111 # @param $(objsuff) Object suffix. 110 112 define TOOL_GCC3OMF_COMPILE_CXX 111 #$ (warning dbg: TOOL_GCC3OMF_COMPILE_CXX: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) )112 $(obj): $(dirdep) $(source) 113 #$ (warning dbg: TOOL_GCC3OMF_COMPILE_CXX: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) deps=$(deps)) 114 $(obj): $(dirdep) $(source) $(deps) 113 115 $(call MSG_L2,Compiling $$@ using GCC3) 114 116 $(TOOL_GCC3OMF_CXX) -c\ … … 117 119 -o $$@\ 118 120 $(call ABSPATH,$(source)) 119 121 120 122 endef 121 123 … … 136 138 $(RM) -f $$@ 137 139 $(TOOL_GCC3OMF_AR) $(flags) $$@ $(objs) 138 140 139 141 endef 140 142 … … 160 162 ifneq ($(custom_pre),) 161 163 $(eval $(custom_pre)) 162 endif 164 endif 163 165 $(TOOL_GCC3OMF_LD) $(flags) -o $$@ $(objs) \ 164 166 $(foreach p,$(libpath), -L$(p)) \ … … 166 168 ifneq ($(custom_post),) 167 169 $(eval $(custom_post)) 168 endif 169 170 endif 171 170 172 endef 171 173 … … 191 193 ifneq ($(custom_pre),) 192 194 $(eval $(custom_pre)) 193 endif 195 endif 194 196 $(TOOL_GCC3OMF_LD) $(TOOL_GCC3OMF_LDFLAGS.dll) $(flags) -o $$@ $(objs) \ 195 197 $(foreach p,$(libpath), -L$(p)) \ … … 197 199 ifneq ($(custom_post),) 198 200 $(eval $(custom_post)) 199 endif 200 201 endif 202 201 203 endef 202 204 … … 221 223 ifneq ($(custom_pre),) 222 224 $(eval $(custom_pre)) 223 endif 225 endif 224 226 $(TOOL_GCC3OMF_LD_SYSMOD) $(TOOL_GCC3OMF_LDFLAGS.sysmod) $(flags) -o $$@ $(objs) \ 225 227 $(foreach p,$(libpath), -L$(p)) \ … … 227 229 ifneq ($(custom_post),) 228 230 $(eval $(custom_post)) 229 endif 230 231 endef 232 231 endif 232 233 endef 234 -
trunk/kBuild/tools/MINGW32.kmk
r181 r184 28 28 29 29 # find latest installed version 30 ifndef PATH_TOOL_MINGW32 30 ifndef PATH_TOOL_MINGW32 31 31 PATH_TOOL_MINGW32 := $(sort $(wildcard $(PATH_DEV)/$(BUILD_PLATFORM_ARCH).$(BUILD_PLATFORM)/mingw32/v*.*)) 32 32 ifeq ($(PATH_TOOL_MINGW32),) … … 55 55 endif 56 56 endif 57 57 58 58 TOOL_MINGW32_CC := $(_TOOL_MINGW32_PREFIX)gcc$(_TOOL_MINGW32_SUFF_EXE) 59 59 TOOL_MINGW32_COBJSUFF := .o … … 105 105 # @param $(incs) Includes. No -I or something. 106 106 # @param $(dirdep) Directory creation dependency. 107 # @param $(deps) Other dependencies. 107 108 # 108 109 # @param $(outbase) Output basename (full). Use this for list files and such. 109 110 # @param $(objsuff) Object suffix. 110 111 define TOOL_MINGW32_COMPILE_C 111 #$ (warning dbg: TOOL_MINGW32_COMPILE_C: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) )112 $(obj): $(dirdep) $(source) 112 #$ (warning dbg: TOOL_MINGW32_COMPILE_C: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) deps=$(deps)) 113 $(obj): $(dirdep) $(source) $(deps) 113 114 $(call MSG_L2,Compiling $$@ using MINGW32) 114 115 $(TOOL_MINGW32_CC) -c\ … … 117 118 -o $$@\ 118 119 $(call ABSPATH,$(source)) 119 120 120 121 endef 121 122 … … 130 131 # @param $(incs) Includes. No -I or something. 131 132 # @param $(dirdep) Directory creation dependency. 133 # @param $(deps) Other dependencies. 132 134 # 133 135 # @param $(outbase) Output basename (full). Use this for list files and such. 134 136 # @param $(objsuff) Object suffix. 135 137 define TOOL_MINGW32_COMPILE_CXX 136 #$ (warning dbg: TOOL_MINGW32_COMPILE_CXX: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) )137 $(obj): $(dirdep) $(source) 138 #$ (warning dbg: TOOL_MINGW32_COMPILE_CXX: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) deps=$(deps)) 139 $(obj): $(dirdep) $(source) $(deps) 138 140 $(call MSG_L2,Compiling $$@ using MINGW32) 139 141 $(TOOL_MINGW32_CXX) -c\ … … 142 144 -o $$@\ 143 145 $(call ABSPATH,$(source)) 144 146 145 147 endef 146 148 … … 161 163 $(RM) -f $$@ 162 164 $(TOOL_MINGW32_AR) $(flags) $$@ $(objs) 163 165 164 166 endef 165 167 … … 185 187 ifneq ($(custom_pre),) 186 188 $(eval $(custom_pre)) 187 endif 189 endif 188 190 $(TOOL_MINGW32_LD) $(flags) -o $$@ $(objs) \ 189 191 $(foreach p,$(libpath), -L$(p)) \ … … 191 193 ifneq ($(custom_post),) 192 194 $(eval $(custom_post)) 193 endif 194 195 endif 196 195 197 endef 196 198 … … 216 218 ifneq ($(custom_pre),) 217 219 $(eval $(custom_pre)) 218 endif 220 endif 219 221 $(TOOL_MINGW32_DLLWRAP) $(flags) \ 220 222 --dllname=$(dll) \ … … 231 233 ifneq ($(custom_post),) 232 234 $(eval $(custom_post)) 233 endif 235 endif 234 236 _OUT_FILES += $(outbase).map $(outbase).a $(outbase).exp 235 237 -
trunk/kBuild/tools/NASM.kmk
r129 r184 33 33 endif 34 34 endif 35 35 36 36 ifneq ($(PATH_TOOL_NASM),) 37 37 TOOL_NASM_AS := $(PATH_TOOL_NASM)/nasm$(HOSTSUFF_EXE) … … 51 51 # @param $(incs) Includes. No -I or something. 52 52 # @param $(dirdep) Directory creation dependency. 53 # @param $(deps) Other dependencies. 53 54 # 54 55 # @param $(outbase) Output basename (full). Use this for list files and such. 55 56 # @param $(objsuff) Object suffix. 56 57 define TOOL_NASM_COMPILE_AS 57 #$ (warning dbg: TOOL_NASM_COMPILE_AS: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) )58 $(obj): $(dirdep) $(source) 58 #$ (warning dbg: TOOL_NASM_COMPILE_AS: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff) deps=$(deps)) 59 $(obj): $(dirdep) $(source) $(deps) 59 60 $(call MSG_L2,Compiling $$@ using NASM) 60 61 $(TOOL_NASM_AS) \ … … 64 65 $(call ABSPATH,$(source)) 65 66 _OUT_FILES += $(outbase).lst 66 67 67 68 endef 68 69 -
trunk/kBuild/tools/VCC70.kmk
r181 r184 70 70 # @param $(incs) Includes. No -I or something. 71 71 # @param $(dirdep) Directory creation dependency. 72 # @param $(deps) Other dependencies. 72 73 # 73 74 # @param $(outbase) Output basename (full). Use this for list files and such. … … 75 76 define TOOL_VCC70_COMPILE_C 76 77 #$ (warning dbg: TOOL_VCC70_COMPILE_C: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff)) 77 $(obj): $(dirdep) $(source) 78 $(obj): $(dirdep) $(source) $(deps) 78 79 $(call MSG_L2,Compiling $$@ using VCC70) 79 80 $(TOOL_VCC70_CC) -c\ … … 101 102 # @param $(incs) Includes. No -I or something. 102 103 # @param $(dirdep) Directory creation dependency. 104 # @param $(deps) Other dependencies. 103 105 # 104 106 # @param $(outbase) Output basename (full). Use this for list files and such. … … 106 108 define TOOL_VCC70_COMPILE_CXX 107 109 #$ (warning dbg: TOOL_VCC70_COMPILE_CXX: target=$(target) source=$(source) obj=$(obj) dep=$(dep) flags=$(flags) defs=$(defs) incs=$(incs) dirdep=$(dirdep) outbase=$(outbase) objsuff=$(objsuff)) 108 $(obj): $(dirdep) $(source) 110 $(obj): $(dirdep) $(source) $(deps) 109 111 $(call MSG_L2,Compiling $$@ using VCC70) 110 112 $(TOOL_VCC70_CXX) -c\ … … 118 120 -D__DATE__=\"0000.00.00\" -D__FILE__=\"filename.c\" -D__LINE__=42 -D__TIME__=\"00.00.00\" -D__TIMESTAMP__=\"lotsofnumbers\" \ 119 121 $(addprefix -D, $(defs)) $(addprefix -I, $(incs)) \ 120 $(call ABSPATH,$(source)) 122 $(call ABSPATH,$(source)) 121 123 _OUT_FILES += $(outbase).pdb 122 124 … … 252 254 $(foreach p,$(libpath), /LIBPATH:$(p)) \ 253 255 $(subst /,\\,$(objs)) \ 254 $(subst /,\\,$(libs)) 256 $(subst /,\\,$(libs)) 255 257 ifeq ($(filter %.exp .def,$(othersrc)),) 256 258 if test -f $(outbase).exp; then $(CP) $(outbase).exp $(PATH_LIB)/; fi
Note:
See TracChangeset
for help on using the changeset viewer.