Browse Source

Add options to disable tests and examples from the build.

pull/1275/head
Joao Matos 5 years ago
parent
commit
8278efd338
  1. 10
      build/Helpers.lua
  2. 4
      build/premake5.lua

10
build/Helpers.lua

@ -15,6 +15,16 @@ newoption { @@ -15,6 +15,16 @@ newoption {
description = "disable C++-11 ABI on GCC 4.9+"
}
newoption {
trigger = "disable-tests",
description = "disable tests from being included"
}
newoption {
trigger = "disable-examples",
description = "disable examples from being included"
}
explicit_target_architecture = _OPTIONS["arch"]
function is_64_bits_mono_runtime()

4
build/premake5.lua

@ -39,14 +39,18 @@ workspace "CppSharp" @@ -39,14 +39,18 @@ workspace "CppSharp"
include (srcdir .. "/Generator.Tests")
include (srcdir .. "/Runtime")
if not _OPTIONS["disable-tests"] then
dofile "Tests.lua"
group "Tests"
IncludeTests()
end
if not _OPTIONS["disable-tests"] then
if string.starts(action, "vs") then
group "Examples"
IncludeExamples()
end
end

Loading…
Cancel
Save