67 lines
1.4 KiB
Lua
67 lines
1.4 KiB
Lua
project "SHADE_CSharp"
|
|
architecture "x64"
|
|
kind "SharedLib"
|
|
language "C#"
|
|
clr "NetCore"
|
|
dotnetframework "net5.0"
|
|
namespace ("SHADE")
|
|
targetdir (outputdir)
|
|
objdir (interdir)
|
|
systemversion "latest"
|
|
|
|
files
|
|
{
|
|
"%{prj.location}/src/**.cs",
|
|
"%{prj.location}/src/**.tt"
|
|
}
|
|
|
|
flags
|
|
{
|
|
"MultiProcessorCompile"
|
|
}
|
|
|
|
dependson
|
|
{
|
|
"SHADE_Engine"
|
|
}
|
|
|
|
warnings 'Extra'
|
|
|
|
postbuildcommands
|
|
{
|
|
"xcopy /r /y /q \"%{outputdir}\\net5.0\\SHADE_CSharp.xml\" \"%{outputdir}\"",
|
|
"xcopy /r /y /q \"%{outputdir}\\net5.0\\SHADE_CSharp.pdb\" \"%{outputdir}\""
|
|
}
|
|
|
|
filter "configurations:Debug"
|
|
symbols "On"
|
|
defines {"_DEBUG"}
|
|
|
|
filter "configurations:Release"
|
|
optimize "On"
|
|
defines{"_RELEASE"}
|
|
|
|
filter "configurations:Publish"
|
|
optimize "On"
|
|
defines{"_RELEASE"}
|
|
|
|
require "vstudio"
|
|
|
|
function platformsElementCS(cfg)
|
|
_p(2,'<Platforms>x64</Platforms>')
|
|
end
|
|
function configElementCS(cfg)
|
|
_p(2,'<Configurations>Debug;Release;Publish</Configurations>')
|
|
end
|
|
function docsElementCS(cfg)
|
|
_p(2,'<GenerateDocumentationFile>true</GenerateDocumentationFile>')
|
|
end
|
|
function docsLocationElementCS(cfg)
|
|
_p(2,'<DocumentationFile>$(OutDir)</DocumentationFile>')
|
|
end
|
|
|
|
premake.override(premake.vstudio.cs2005.elements, "projectProperties", function (oldfn, cfg)
|
|
return table.join(oldfn(cfg), {
|
|
platformsElementCS, configElementCS, docsElementCS, docsLocationElementCS,
|
|
})
|
|
end) |