Skip to content

Commit

Permalink
restore
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinRansom committed Jun 18, 2019
1 parent 7c9bfe5 commit e95cf67
Show file tree
Hide file tree
Showing 32 changed files with 94 additions and 1,609 deletions.
1 change: 0 additions & 1 deletion eng/common/PublishToPackageFeed.proj
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
<TargetStaticFeed Condition="'$(ArtifactsCategory.ToUpper())' == 'WINDOWSDESKTOP'">https://dotnetfeed.blob.core.windows.net/dotnet-windowsdesktop/index.json</TargetStaticFeed>
<TargetStaticFeed Condition="'$(ArtifactsCategory.ToUpper())' == 'NUGETCLIENT'">https://dotnetfeed.blob.core.windows.net/nuget-nugetclient/index.json</TargetStaticFeed>
<TargetStaticFeed Condition="'$(ArtifactsCategory.ToUpper())' == 'ASPNETENTITYFRAMEWORK6'">https://dotnetfeed.blob.core.windows.net/aspnet-entityframework6/index.json</TargetStaticFeed>
<TargetStaticFeed Condition="'$(ArtifactsCategory.ToUpper())' == 'ASPNETBLAZOR'">https://dotnetfeed.blob.core.windows.net/aspnet-blazor/index.json</TargetStaticFeed>
</PropertyGroup>

<Error
Expand Down
7 changes: 2 additions & 5 deletions eng/common/build.ps1
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
[CmdletBinding(PositionalBinding=$false)]
Param(
[string][Alias('c')]$configuration = "Debug",
[string]$platform = $null,
[string] $projects,
[string][Alias('v')]$verbosity = "minimal",
[string] $msbuildEngine = $null,
Expand Down Expand Up @@ -30,7 +29,6 @@ Param(
function Print-Usage() {
Write-Host "Common settings:"
Write-Host " -configuration <value> Build configuration: 'Debug' or 'Release' (short: -c)"
Write-Host " -platform <value> Platform configuration: 'x86', 'x64' or any valid Platform value to pass to msbuild"
Write-Host " -verbosity <value> Msbuild verbosity: q[uiet], m[inimal], n[ormal], d[etailed], and diag[nostic] (short: -v)"
Write-Host " -binaryLog Output binary log (short: -bl)"
Write-Host " -help Print help and exit"
Expand Down Expand Up @@ -79,7 +77,6 @@ function Build {
InitializeCustomToolset

$bl = if ($binaryLog) { "/bl:" + (Join-Path $LogDir "Build.binlog") } else { "" }
$platformArg = if ($platform) { "/p:Platform=$platform" } else { "" }

if ($projects) {
# Re-assign properties to a new variable because PowerShell doesn't let us append properties directly for unclear reasons.
Expand All @@ -91,7 +88,6 @@ function Build {

MSBuild $toolsetBuildProj `
$bl `
$platformArg `
/p:Configuration=$configuration `
/p:RepoRoot=$RepoRoot `
/p:Restore=$restore `
Expand Down Expand Up @@ -133,8 +129,9 @@ try {
Build
}
catch {
Write-Host $_
Write-Host $_.Exception
Write-Host $_.ScriptStackTrace
Write-PipelineTelemetryError -Category "InitializeToolset" -Message $_
ExitWithExitCode 1
}

Expand Down
5 changes: 0 additions & 5 deletions eng/common/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ ci=false
warn_as_error=true
node_reuse=true
binary_log=false
pipelines_log=false

projects=''
configuration='Debug'
Expand All @@ -93,9 +92,6 @@ while [[ $# > 0 ]]; do
-binarylog|-bl)
binary_log=true
;;
-pipelineslog|-pl)
pipelines_log=true
;;
-restore|-r)
restore=true
;;
Expand Down Expand Up @@ -150,7 +146,6 @@ while [[ $# > 0 ]]; do
done

if [[ "$ci" == true ]]; then
pipelines_log=true
binary_log=true
node_reuse=false
fi
Expand Down
6 changes: 3 additions & 3 deletions eng/common/cross/armel/tizen-fetch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -157,15 +157,15 @@ fetch_tizen_pkgs()
Inform "Initialize arm base"
fetch_tizen_pkgs_init standard base
Inform "fetch common packages"
fetch_tizen_pkgs armv7l gcc glibc glibc-devel libicu libicu-devel libatomic
fetch_tizen_pkgs armv7l gcc glibc glibc-devel libicu libicu-devel
fetch_tizen_pkgs noarch linux-glibc-devel
Inform "fetch coreclr packages"
fetch_tizen_pkgs armv7l lldb lldb-devel libgcc libstdc++ libstdc++-devel libunwind libunwind-devel lttng-ust-devel lttng-ust userspace-rcu-devel userspace-rcu
fetch_tizen_pkgs armv7l lldb lldb-devel libgcc libstdc++ libstdc++-devel libunwind libunwind-devel tizen-release lttng-ust-devel lttng-ust userspace-rcu-devel userspace-rcu
Inform "fetch corefx packages"
fetch_tizen_pkgs armv7l libcom_err libcom_err-devel zlib zlib-devel libopenssl libopenssl-devel krb5 krb5-devel libcurl libcurl-devel

Inform "Initialize standard unified"
fetch_tizen_pkgs_init standard unified
Inform "fetch corefx packages"
fetch_tizen_pkgs armv7l gssdp gssdp-devel tizen-release
fetch_tizen_pkgs armv7l gssdp gssdp-devel

2 changes: 1 addition & 1 deletion eng/common/cross/build-rootfs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ if [ -z "$__RootfsDir" ] && [ ! -z "$ROOTFS_DIR" ]; then
fi

if [ -z "$__RootfsDir" ]; then
__RootfsDir="$__CrossDir/../../../.tools/rootfs/$__BuildArch"
__RootfsDir="$__CrossDir/rootfs/$__BuildArch"
fi

if [ -d "$__RootfsDir" ]; then
Expand Down
8 changes: 4 additions & 4 deletions eng/common/darc-init.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,23 @@ function InstallDarcCli ($darcVersion) {

$dotnetRoot = InitializeDotNetCli -install:$true
$dotnet = "$dotnetRoot\dotnet.exe"
$toolList = & "$dotnet" tool list -g
$toolList = Invoke-Expression "& `"$dotnet`" tool list -g"

if ($toolList -like "*$darcCliPackageName*") {
& "$dotnet" tool uninstall $darcCliPackageName -g
Invoke-Expression "& `"$dotnet`" tool uninstall $darcCliPackageName -g"
}

# If the user didn't explicitly specify the darc version,
# query the Maestro API for the correct version of darc to install.
if (-not $darcVersion) {
$darcVersion = $(Invoke-WebRequest -Uri $versionEndpoint -UseBasicParsing).Content
}

$arcadeServicesSource = 'https://dotnetfeed.blob.core.windows.net/dotnet-core/index.json'

Write-Host "Installing Darc CLI version $darcVersion..."
Write-Host "You may need to restart your command window if this is the first dotnet tool you have installed."
& "$dotnet" tool install $darcCliPackageName --version $darcVersion --add-source "$arcadeServicesSource" -v $verbosity -g
Invoke-Expression "& `"$dotnet`" tool install $darcCliPackageName --version $darcVersion --add-source '$arcadeServicesSource' -v $verbosity -g"
}

InstallDarcCli $darcVersion
11 changes: 3 additions & 8 deletions eng/common/dotnet-install.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,9 @@ Param(

. $PSScriptRoot\tools.ps1

$dotnetRoot = Join-Path $RepoRoot ".dotnet"

$installdir = $dotnetRoot
try {
if ($architecture -and $architecture.Trim() -eq "x86") {
$installdir = Join-Path $installdir "x86"
}
InstallDotNet $installdir $version $architecture $runtime $true
$dotnetRoot = Join-Path $RepoRoot ".dotnet"
InstallDotNet $dotnetRoot $version $architecture $runtime $true
}
catch {
Write-Host $_
Expand All @@ -24,4 +19,4 @@ catch {
ExitWithExitCode 1
}

ExitWithExitCode 0
ExitWithExitCode 0
20 changes: 10 additions & 10 deletions eng/common/generate-graph-files.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ function CheckExitCode ([string]$stage)

try {
Push-Location $PSScriptRoot

Write-Host "Installing darc..."
. .\darc-init.ps1 -darcVersion $darcVersion
CheckExitCode "Running darc-init"
Expand All @@ -40,9 +40,9 @@ try {

$darcExe = "$env:USERPROFILE\.dotnet\tools"
$darcExe = Resolve-Path "$darcExe\darc.exe"

Create-Directory $outputFolder

# Generate 3 graph descriptions:
# 1. Flat with coherency information
# 2. Graphviz (dot) file
Expand All @@ -51,26 +51,26 @@ try {
$graphVizImageFilePath = "$outputFolder\graph.png"
$normalGraphFilePath = "$outputFolder\graph-full.txt"
$flatGraphFilePath = "$outputFolder\graph-flat.txt"
$baseOptions = @( "--github-pat", "$gitHubPat", "--azdev-pat", "$azdoPat", "--password", "$barToken" )

$baseOptions = "get-dependency-graph --github-pat $gitHubPat --azdev-pat $azdoPat --password $barToken"
if ($includeToolset) {
Write-Host "Toolsets will be included in the graph..."
$baseOptions += @( "--include-toolset" )
$baseOptions += " --include-toolset"
}

Write-Host "Generating standard dependency graph..."
& "$darcExe" get-dependency-graph @baseOptions --output-file $normalGraphFilePath
Invoke-Expression "& `"$darcExe`" $baseOptions --output-file $normalGraphFilePath"
CheckExitCode "Generating normal dependency graph"

Write-Host "Generating flat dependency graph and graphviz file..."
& "$darcExe" get-dependency-graph @baseOptions --flat --coherency --graphviz $graphVizFilePath --output-file $flatGraphFilePath
Invoke-Expression "& `"$darcExe`" $baseOptions --flat --coherency --graphviz $graphVizFilePath --output-file $flatGraphFilePath"
CheckExitCode "Generating flat and graphviz dependency graph"

Write-Host "Generating graph image $graphVizFilePath"
$dotFilePath = Join-Path $installBin "graphviz\$graphvizVersion\release\bin\dot.exe"
& "$dotFilePath" -Tpng -o"$graphVizImageFilePath" "$graphVizFilePath"
Invoke-Expression "& `"$dotFilePath`" -Tpng -o'$graphVizImageFilePath' `"$graphVizFilePath`""
CheckExitCode "Generating graphviz image"

Write-Host "'$graphVizFilePath', '$flatGraphFilePath', '$normalGraphFilePath' and '$graphVizImageFilePath' created!"
}
catch {
Expand Down
21 changes: 11 additions & 10 deletions eng/common/init-tools-native.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -79,27 +79,28 @@ try {
$NativeTools.PSObject.Properties | ForEach-Object {
$ToolName = $_.Name
$ToolVersion = $_.Value
$LocalInstallerArguments = @{ ToolName = "$ToolName" }
$LocalInstallerArguments += @{ InstallPath = "$InstallBin" }
$LocalInstallerArguments += @{ BaseUri = "$BaseUri" }
$LocalInstallerArguments += @{ CommonLibraryDirectory = "$EngCommonBaseDir" }
$LocalInstallerArguments += @{ Version = "$ToolVersion" }
$LocalInstallerCommand = $InstallerPath
$LocalInstallerCommand += " -ToolName $ToolName"
$LocalInstallerCommand += " -InstallPath $InstallBin"
$LocalInstallerCommand += " -BaseUri $BaseUri"
$LocalInstallerCommand += " -CommonLibraryDirectory $EngCommonBaseDir"
$LocalInstallerCommand += " -Version $ToolVersion"

if ($Verbose) {
$LocalInstallerArguments += @{ Verbose = $True }
$LocalInstallerCommand += " -Verbose"
}
if (Get-Variable 'Force' -ErrorAction 'SilentlyContinue') {
if($Force) {
$LocalInstallerArguments += @{ Force = $True }
$LocalInstallerCommand += " -Force"
}
}
if ($Clean) {
$LocalInstallerArguments += @{ Clean = $True }
$LocalInstallerCommand += " -Clean"
}

Write-Verbose "Installing $ToolName version $ToolVersion"
Write-Verbose "Executing '$InstallerPath $LocalInstallerArguments'"
& $InstallerPath @LocalInstallerArguments
Write-Verbose "Executing '$LocalInstallerCommand'"
Invoke-Expression "$LocalInstallerCommand"
if ($LASTEXITCODE -Ne "0") {
$errMsg = "$ToolName installation failed"
if ((Get-Variable 'DoNotAbortNativeToolsInstallationOnFailure' -ErrorAction 'SilentlyContinue') -and $DoNotAbortNativeToolsInstallationOnFailure) {
Expand Down
2 changes: 1 addition & 1 deletion eng/common/native/CommonLibrary.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ function New-ScriptShim {
Remove-Item (Join-Path $ShimDirectory "$ShimName.exe")
}

& "$ShimDirectory\WinShimmer\winshimmer.exe" $ShimName $ToolFilePath $ShimDirectory
Invoke-Expression "$ShimDirectory\WinShimmer\winshimmer.exe $ShimName $ToolFilePath $ShimDirectory"
return $True
}
catch {
Expand Down
Loading

0 comments on commit e95cf67

Please sign in to comment.