Fix custom build when new files are in new/missing directory
This commit is contained in:
parent
db19fa5acc
commit
660e4e2589
@ -401,7 +401,7 @@
|
||||
buildmessage = "\t@{ECHO} " .. p.quote(config.buildmessage) .. "\n"
|
||||
end
|
||||
local commands = table.implode(config.buildcommands,"\t","\n","")
|
||||
table.insert(makefilerules, os.translateCommandsAndPaths(outputs .. ": " .. filename .. inputs .. "\n" .. buildmessage .. commands, cfg.project.basedir, cfg.project.location))
|
||||
table.insert(makefilerules, os.translateCommandsAndPaths(outputs .. ": " .. filename .. inputs .. "\n" .. buildmessage .. "\t@$(MakeDirCommand) $(@D)\n" .. commands, cfg.project.basedir, cfg.project.location))
|
||||
table.insertflat(dependencies, outputs)
|
||||
return true
|
||||
end
|
||||
|
@ -112,10 +112,12 @@
|
||||
<CustomPreBuild>test.obj test2.obj
|
||||
test.obj: test.rule
|
||||
@echo "Rule-ing test.rule"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
dorule -p "test.rule"
|
||||
|
||||
test2.obj: test2.rule
|
||||
@echo "Rule-ing test2.rule"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
dorule -p -p2 "test2.rule"
|
||||
</CustomPreBuild>
|
||||
</AdditionalRules>
|
||||
@ -157,18 +159,22 @@ test2.obj: test2.rule
|
||||
<CustomPreBuild>test.obj test2.obj test3.obj test4.obj
|
||||
test.obj: test.rule
|
||||
@echo "Rule-ing test.rule"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
dorule testValue1 testValue2 "test.rule"
|
||||
|
||||
test2.obj: test2.rule
|
||||
@echo "Rule-ing test2.rule"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
dorule -StestValue1 -StestValue2 "test2.rule"
|
||||
|
||||
test3.obj: test3.rule
|
||||
@echo "Rule-ing test3.rule"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
dorule testValue1,testValue2 "test3.rule"
|
||||
|
||||
test4.obj: test4.rule
|
||||
@echo "Rule-ing test4.rule"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
dorule -OtestValue1,testValue2 "test4.rule"
|
||||
</CustomPreBuild>
|
||||
</AdditionalRules>
|
||||
@ -198,10 +204,12 @@ test4.obj: test4.rule
|
||||
<CustomPreBuild>test.obj test2.obj
|
||||
test.obj: test.rule
|
||||
@echo "Rule-ing test.rule"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
dorule S0 "test.rule"
|
||||
|
||||
test2.obj: test2.rule
|
||||
@echo "Rule-ing test2.rule"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
dorule S1 "test2.rule"
|
||||
</CustomPreBuild>
|
||||
</AdditionalRules>
|
||||
@ -222,6 +230,7 @@ test2.obj: test2.rule
|
||||
<CustomPreBuild>toto.c
|
||||
toto.c: toto.txt extra_dependency
|
||||
@echo "Some message"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
test
|
||||
test toto.c
|
||||
</CustomPreBuild>
|
||||
@ -242,6 +251,7 @@ toto.c: toto.txt extra_dependency
|
||||
<CustomPreBuild>toto.c
|
||||
toto.c: toto.txt extra_dependency
|
||||
@echo "\"Some message\""
|
||||
@$(MakeDirCommand) $(@D)
|
||||
test
|
||||
test toto.c
|
||||
</CustomPreBuild>
|
||||
@ -263,11 +273,13 @@ toto.c: toto.txt extra_dependency
|
||||
<CustomPreBuild>bar.c foo.c
|
||||
bar.c: bar.txt bar.h extra_dependency
|
||||
@echo "Some message"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
test
|
||||
test bar
|
||||
|
||||
foo.c: foo.txt foo.h extra_dependency
|
||||
@echo "Some message"
|
||||
@$(MakeDirCommand) $(@D)
|
||||
test
|
||||
test foo
|
||||
</CustomPreBuild>
|
||||
|
Loading…
Reference in New Issue
Block a user