-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Small fixes #21982
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Small fixes #21982
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -253,9 +253,7 @@ $RunRestore = if ($NoRestore) { $false } | |
# Target selection | ||
$MSBuildArguments += "/p:Restore=$RunRestore" | ||
$MSBuildArguments += "/p:Build=$RunBuild" | ||
if (-not $RunBuild) { | ||
$MSBuildArguments += "/p:NoBuild=true" | ||
} | ||
if (-not $RunBuild) { $MSBuildArguments += "/p:NoBuild=true" } | ||
$MSBuildArguments += "/p:Pack=$Pack" | ||
$MSBuildArguments += "/p:Test=$Test" | ||
$MSBuildArguments += "/p:Sign=$Sign" | ||
|
@@ -364,18 +362,20 @@ Remove-Item variable:global:_MSBuildExe -ea Ignore | |
# Import Arcade | ||
. "$PSScriptRoot/eng/common/tools.ps1" | ||
|
||
# Add default .binlog location if not already on the command line. tools.ps1 does not handle this; it just checks | ||
# $BinaryLog, $CI and $ExcludeCIBinarylog values for an error case. But tools.ps1 provides a nice function to help. | ||
if ($BinaryLog) { | ||
$bl = GetMSBuildBinaryLogCommandLineArgument($MSBuildArguments) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This and the similar |
||
if (-not $bl) { | ||
$MSBuildArguments += "/bl:" + (Join-Path $LogDir "Build.binlog") | ||
} | ||
} | ||
|
||
# Capture MSBuild crash logs | ||
$env:MSBUILDDEBUGPATH = $LogDir | ||
|
||
$local:exit_code = $null | ||
try { | ||
# Import custom tools configuration, if present in the repo. | ||
# Note: Import in global scope so that the script set top-level variables without qualification. | ||
$configureToolsetScript = Join-Path $EngRoot "configure-toolset.ps1" | ||
if (Test-Path $configureToolsetScript) { | ||
. $configureToolsetScript | ||
} | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This was old cruft. Sourcing tools.ps1 sources this file for us already and makes all settings available in this scope. Same for the similar block near the end of build.sh. |
||
# Set this global property so Arcade will always initialize the toolset. The error message you get when you build on a clean machine | ||
# with -norestore is not obvious about what to do to fix it. As initialization takes very little time, we think always initializing | ||
# the toolset is a better default behavior. | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -288,10 +288,6 @@ if [ -z "$configuration" ]; then | |
fi | ||
msbuild_args[${#msbuild_args[*]}]="-p:Configuration=$configuration" | ||
|
||
# Set verbosity | ||
echo "Setting msbuild verbosity to $verbosity" | ||
msbuild_args[${#msbuild_args[*]}]="-verbosity:$verbosity" | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If I didn't remove this, we end up with extra options on the |
||
# Set up additional runtime args | ||
toolset_build_args=() | ||
if [ ! -z "$dotnet_runtime_source_feed$dotnet_runtime_source_feed_key" ]; then | ||
|
@@ -328,15 +324,25 @@ fi | |
# Import Arcade | ||
. "$DIR/eng/common/tools.sh" | ||
|
||
# Add default .binlog location if not already on the command line. tools.sh does not handle this; it just checks | ||
# $binary_log, $ci and $exclude_ci_binary_log values for an error case. | ||
if [[ "$binary_log" == true ]]; then | ||
found=false | ||
for arg in "${msbuild_args[@]}"; do | ||
opt="$(echo "${arg/#--/-}" | awk '{print tolower($0)}')" | ||
if [[ "$opt" == [-/]bl:* || "$opt" == [-/]binarylogger:* ]]; then | ||
found=true | ||
break | ||
fi | ||
done | ||
if [[ "$found" == false ]]; then | ||
msbuild_args[${#msbuild_args[*]}]="/bl:$log_dir/Build.binlog" | ||
fi | ||
fi | ||
|
||
# Capture MSBuild crash logs | ||
export MSBUILDDEBUGPATH="$log_dir" | ||
|
||
# Import custom tools configuration, if present in the repo. | ||
configure_toolset_script="$eng_root/configure-toolset.sh" | ||
if [[ -a "$configure_toolset_script" ]]; then | ||
. "$configure_toolset_script" | ||
fi | ||
|
||
# Set this global property so Arcade will always initialize the toolset. The error message you get when you build on a clean machine | ||
# with -norestore is not obvious about what to do to fix it. As initialization takes very little time, we think always initializing | ||
# the toolset is a better default behavior. | ||
|
Uh oh!
There was an error while loading. Please reload this page.