Implemented filtering of dependency files, only active if machine have awk or gawk installed (nw)

This commit is contained in:
Miodrag Milanovic 2015-04-04 19:57:12 +02:00
parent ee0fd53c28
commit 9c6fa77b47
2 changed files with 29 additions and 5 deletions

View file

@ -267,10 +267,35 @@ configuration { "Debug", "vs*" }
configuration {}
--postcompiletasks {
-- "gawk -f ../../../../../scripts/depfilter.awk $(@:%.o=%.d) > $(@:%.o=%.dep)",
-- "mv $(@:%.o=%.dep) $(@:%.o=%.d)",
--}
local AWK = ""
if (os.is("windows")) then
AWK_TEST = backtick("awk --version 2> NUL")
if (AWK_TEST~='') then
AWK = "awk"
else
AWK_TEST = backtick("gawk --version 2> NUL")
if (AWK_TEST~='') then
AWK = "gawk"
end
end
else
AWK_TEST = backtick("awk --version 2> /dev/null")
if (AWK_TEST~='') then
AWK = "awk"
else
AWK_TEST = backtick("gawk --version 2> /dev/null")
if (AWK_TEST~='') then
AWK = "gawk"
end
end
end
if (AWK~='') then
postcompiletasks {
AWK .. " -f ../../../../../scripts/depfilter.awk $(@:%.o=%.d) > $(@:%.o=%.dep)",
"mv $(@:%.o=%.dep) $(@:%.o=%.d)",
}
end
msgcompile ("Compiling $(subst ../,,$<)...")

View file

@ -103,7 +103,6 @@ function osdmodulesbuild()
local MOC = ""
if (os.is("windows")) then
print("windows")
MOC = "moc"
else
MOCTST = backtick("which moc-qt4 2>/dev/null")