79 lines
2.4 KiB
Lua
79 lines
2.4 KiB
Lua
local function auStartSolution(sln)
|
|
|
|
workspace(sln.name)
|
|
|
|
auRequire("Core/Target").startSolution()
|
|
|
|
location(Aurora.Settings.sAbsCompilerWd)
|
|
|
|
-- Required for core Aurora assumptions. External build chains may mess with these -- not my problem.
|
|
symbols "On" -- even ship binaries are initially built with symbols for unix targets to strip them with objcopy
|
|
visibility "Hidden" -- posix devs are stupid. default vis is stupid. we're beyond the 70's C OS aka version 7 UNIX
|
|
stringpooling "true" -- i've seen hashmaps explode too many times to care about the few ms this saves
|
|
floatingpoint "strict" -- x87 sucks so lets be mean. it's a nice to have when working with js runtimes
|
|
justmycode "Off" -- some premake warning bug
|
|
|
|
if (Aurora.Settings.bStaticRuntime) then
|
|
staticruntime "On"
|
|
else
|
|
staticruntime "Off"
|
|
end
|
|
|
|
if (Aurora.Settings.bEditAndCont) then
|
|
editandcontinue "On"
|
|
else
|
|
editandcontinue "Off"
|
|
end
|
|
|
|
flags
|
|
{
|
|
"NoPCH"
|
|
}
|
|
|
|
if (Aurora.Settings.bMultithreadBuild) then
|
|
flags
|
|
{
|
|
"MultiProcessorCompile"
|
|
}
|
|
end
|
|
|
|
if (Aurora.Settings.bLTO) then
|
|
flags "LinkTimeOptimization"
|
|
end
|
|
|
|
auFilterForPlatforms(function(platform)
|
|
if (platform == "win32") then
|
|
if (not Aurora.Settings.bForceClangWin32) then
|
|
toolset "msc"
|
|
else
|
|
toolset "clang"
|
|
end
|
|
else
|
|
if (not Aurora.Settings.bForceClangOnUnix) then
|
|
toolset "gcc"
|
|
else
|
|
toolset "clang"
|
|
end
|
|
end
|
|
end)
|
|
|
|
if (Aurora.Settings.bForceLLVMStl) then
|
|
auFilter {"files:**.cpp or files:**.cc or files:**.cxx", "toolset:clang"}
|
|
buildoptions {"-stdlib=libc++"}
|
|
auFilter{}
|
|
|
|
auFilter { "toolset:clang"}
|
|
linkoptions {"-nodefaultlibs"}
|
|
links {"c++",
|
|
"c++abi",
|
|
"m",
|
|
"c",
|
|
"gcc_s",
|
|
"gcc"}
|
|
auFilter {}
|
|
end
|
|
end
|
|
|
|
return {
|
|
start = auStartSolution
|
|
} |