2020-07-21 18:23:40 -04:00
|
|
|
$root = $PSScriptRoot
|
|
|
|
|
if (!$root) {
|
2023-08-30 15:52:35 +02:00
|
|
|
$root = "."
|
2020-07-21 18:23:40 -04:00
|
|
|
}
|
|
|
|
|
|
2023-09-06 18:30:01 +02:00
|
|
|
cmake -B $root/build $root | Out-Null
|
|
|
|
|
cmake --build $root/build --config Release -- `
|
|
|
|
|
"-p:UseMultiToolTask=true" `
|
|
|
|
|
"-noLogo" `
|
|
|
|
|
"-p:EnforceProcessCountAcrossBuilds=true" `
|
|
|
|
|
"-clp:ErrorsOnly;Verbosity=minimal"
|
2020-05-20 18:28:49 +01:00
|
|
|
|
|
|
|
|
if (! $?) {
|
|
|
|
|
Write-Error "Build failed"
|
|
|
|
|
exit $LastExitCode
|
|
|
|
|
}
|
|
|
|
|
|
2023-08-30 15:52:35 +02:00
|
|
|
Copy-Item "$root\build\src\Release\mob.exe" "$root\mob.exe"
|
|
|
|
|
Write-Output "run ``.\mob -d prefix/path build`` to start building"
|