Premake: Add include guard to make sure dependencies do not include themselves in an infinite chain when two components depend on each other

This commit is contained in:
Jan
2020-02-07 02:46:24 +01:00
parent 55d5746650
commit f73c27a7dc
21 changed files with 245 additions and 125 deletions

View File

@ -108,10 +108,12 @@ function ZoneCode:allWriteFiles()
end
function ZoneCode:include()
includedirs {
path.join(ProjectFolder(), "ZoneCode"),
"%{wks.location}/src/ZoneCode"
}
if References:include("ZoneCode") then
includedirs {
path.join(ProjectFolder(), "ZoneCode"),
"%{wks.location}/src/ZoneCode"
}
end
end
function ZoneCode:link()
@ -123,6 +125,7 @@ function ZoneCode:use()
end
function ZoneCode:project()
References:reset()
local folder = ProjectFolder();
project "ZoneCode"