Skip to content

Commit a8856dd

Browse files
committed
Merge remote-tracking branch 'dotnet/release/2.1.2xx' into merges/release/2.1.2xx-to-release/2.1.3xx
2 parents f87c6e7 + b390c98 commit a8856dd

File tree

12 files changed

+257
-38
lines changed

12 files changed

+257
-38
lines changed

build/DependencyVersions.props

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<MicrosoftAspNetCoreAppPackageVersion>$(MicrosoftAspNetCoreAllPackageVersion)</MicrosoftAspNetCoreAppPackageVersion>
66
<MicrosoftNETCoreAppPackageVersion>2.1.0-rc1-26423-06</MicrosoftNETCoreAppPackageVersion>
77
<MicrosoftNETCoreDotNetHostResolverPackageVersion>$(MicrosoftNETCoreAppPackageVersion)</MicrosoftNETCoreDotNetHostResolverPackageVersion>
8-
<MicrosoftBuildPackageVersion>15.7.0-preview-000169</MicrosoftBuildPackageVersion>
8+
<MicrosoftBuildPackageVersion>15.7.177</MicrosoftBuildPackageVersion>
99
<MicrosoftBuildFrameworkPackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildFrameworkPackageVersion>
1010
<MicrosoftBuildRuntimePackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildRuntimePackageVersion>
1111
<MicrosoftBuildLocalizationPackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildLocalizationPackageVersion>
@@ -15,7 +15,7 @@
1515
<MicrosoftNETCoreCompilersPackageVersion>$(MicrosoftCodeAnalysisCSharpPackageVersion)</MicrosoftNETCoreCompilersPackageVersion>
1616
<MicrosoftCodeAnalysisBuildTasksPackageVersion>$(MicrosoftCodeAnalysisCSharpPackageVersion)</MicrosoftCodeAnalysisBuildTasksPackageVersion>
1717
<MicrosoftNetCompilersNetcorePackageVersion>$(MicrosoftCodeAnalysisCSharpPackageVersion)</MicrosoftNetCompilersNetcorePackageVersion>
18-
<MicrosoftNETSdkPackageVersion>1.0.0-rc1-62827-06</MicrosoftNETSdkPackageVersion>
18+
<MicrosoftNETSdkPackageVersion>2.1.300-rtm-62902-01</MicrosoftNETSdkPackageVersion>
1919
<MicrosoftNETBuildExtensionsPackageVersion>$(MicrosoftNETSdkPackageVersion)</MicrosoftNETBuildExtensionsPackageVersion>
2020
<MicrosoftNETSdkRazorPackageVersion>$(MicrosoftAspNetCoreAppPackageVersion)</MicrosoftNETSdkRazorPackageVersion>
2121
<MicrosoftNETSdkWebPackageVersion>2.1.300-rc1-20180422-1618307</MicrosoftNETSdkWebPackageVersion>
@@ -44,7 +44,7 @@
4444
<NuGetPackagingPackageVersion>$(NuGetBuildTasksPackageVersion)</NuGetPackagingPackageVersion>
4545
<NuGetProjectModelPackageVersion>$(NuGetBuildTasksPackageVersion)</NuGetProjectModelPackageVersion>
4646
<NuGetVersioningPackageVersion>$(NuGetBuildTasksPackageVersion)</NuGetVersioningPackageVersion>
47-
<MicrosoftNETTestSdkPackageVersion>15.7.0-preview-20180221-13</MicrosoftNETTestSdkPackageVersion>
47+
<MicrosoftNETTestSdkPackageVersion>15.7.0</MicrosoftNETTestSdkPackageVersion>
4848
<MicrosoftTestPlatformCLIPackageVersion>$(MicrosoftNETTestSdkPackageVersion)</MicrosoftTestPlatformCLIPackageVersion>
4949
<MicrosoftTestPlatformBuildPackageVersion>$(MicrosoftNETTestSdkPackageVersion)</MicrosoftTestPlatformBuildPackageVersion>
5050
<XliffTasksPackageVersion>0.2.0-beta-000042</XliffTasksPackageVersion>

build/Test.targets

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@
4242
Projects="@(ProjectsToTest)">
4343
</MSBuild>
4444

45+
<Exec Command="$(DotnetInOutputDirectory) exec $(RoslynDirectory)/bincore/VBCSCompiler.dll -shutdown" />
46+
4547
<Message Text="Finished test execution" Importance="High" />
4648
</Target>
4749

netci.groovy

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,35 @@ def project = GithubProject
99
def branch = GithubBranchName
1010
def isPR = true
1111

12-
def platformList = ['Linux:x64:Release', 'Debian8.2:x64:Debug', 'Ubuntu:x64:Release', 'Ubuntu16.04:x64:Debug', 'OSX10.12:x64:Release', 'Windows_NT:x64:Release', 'Windows_NT:x86:Debug', 'Windows_NT_ES:x64:Debug', 'RHEL7.2:x64:Release', 'CentOS7.1:x64:Debug', 'RHEL6:x64:Debug', 'Linux-musl:x64:Debug', 'Linux:arm:Debug', 'Linux:arm64:Debug']
12+
def platformList = [
13+
'CentOS7.1:x64:Debug',
14+
'Debian8.2:x64:Debug',
15+
'fedora.27:x64:Debug',
16+
'Linux:arm:Debug',
17+
'Linux:arm64:Debug',
18+
'Linux-musl:x64:Debug',
19+
'Linux:x64:Release',
20+
'opensuse.43.2:x64:Debug',
21+
'OSX10.12:x64:Release',
22+
'RHEL6:x64:Debug',
23+
'RHEL7.2:x64:Release',
24+
'Ubuntu:x64:Release',
25+
'Ubuntu16.04:x64:Debug',
26+
'ubuntu.18.04:x64:Debug',
27+
'Windows_NT:x64:Release',
28+
'Windows_NT:x86:Debug',
29+
'Windows_NT_ES:x64:Debug'
30+
]
1331

1432
def static getBuildJobName(def configuration, def os, def architecture) {
1533
return configuration.toLowerCase() + '_' + os.toLowerCase() + '_' + architecture.toLowerCase()
1634
}
1735

18-
1936
platformList.each { platform ->
2037
// Calculate names
2138
def (os, architecture, configuration) = platform.tokenize(':')
2239
def osUsedForMachineAffinity = os;
40+
def osVersionUsedForMachineAffinity = 'latest-or-auto';
2341

2442
// Calculate job name
2543
def jobName = getBuildJobName(configuration, os, architecture)
@@ -59,6 +77,11 @@ set DOTNET_CLI_UI_LANGUAGE=es
5977
osUsedForMachineAffinity = 'Ubuntu16.04';
6078
buildCommand = "./build.sh --skip-prereqs --configuration ${configuration} --runtime-id linux-musl-x64 --docker alpine.3.6 --targets Default"
6179
}
80+
else if (os == 'ubuntu.18.04' || os == 'fedora.27' || os == 'opensuse.43.2') {
81+
osUsedForMachineAffinity = 'Ubuntu16.04'
82+
osVersionUsedForMachineAffinity = 'latest-docker'
83+
buildCommand = "./build.sh --linux-portable --skip-prereqs --configuration ${configuration} --docker ${os} --targets Default"
84+
}
6285
else {
6386
// Jenkins non-Ubuntu CI machines don't have docker
6487
buildCommand = "./build.sh --skip-prereqs --configuration ${configuration} --targets Default"
@@ -78,7 +101,7 @@ set DOTNET_CLI_UI_LANGUAGE=es
78101
}
79102
}
80103

81-
Utilities.setMachineAffinity(newJob, osUsedForMachineAffinity, 'latest-or-auto')
104+
Utilities.setMachineAffinity(newJob, osUsedForMachineAffinity, osVersionUsedForMachineAffinity)
82105
Utilities.standardJobSetup(newJob, project, isPR, "*/${branch}")
83106
// ARM CI runs are build only.
84107
if ((architecture != 'arm') && (architecture != 'arm64')) {

run-build.ps1

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,6 @@ if (!(Test-Path $env:DOTNET_INSTALL_DIR))
6767
mkdir $env:DOTNET_INSTALL_DIR | Out-Null
6868
}
6969

70-
71-
7270
# Disable first run since we want to control all package sources
7371
$env:DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
7472

scripts/docker/fedora.27/Dockerfile

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
#
2+
# Copyright (c) .NET Foundation and contributors. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
6+
# Dockerfile that creates a container suitable to build dotnet-cli
7+
FROM microsoft/dotnet-buildtools-prereqs:fedora-27-82a3800-20180326211504
8+
9+
RUN dnf install -y findutils
10+
11+
RUN dnf upgrade -y nss
12+
13+
RUN dnf clean all
14+
15+
# Set a different rid to publish buildtools for, until we update to a version which
16+
# natively supports fedora.24-x64
17+
ENV __PUBLISH_RID=fedora.23-x64
18+
19+
# Setup User to match Host User, and give superuser permissions
20+
ARG USER_ID=0
21+
RUN useradd -m code_executor -u ${USER_ID} -g wheel
22+
RUN echo 'code_executor ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
23+
24+
# With the User Change, we need to change permissions on these directories
25+
RUN chmod -R a+rwx /usr/local
26+
RUN chmod -R a+rwx /home
27+
28+
# Set user to the one we just created
29+
USER ${USER_ID}
30+
31+
# Set working directory
32+
WORKDIR /opt/code
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
#
2+
# Copyright (c) .NET Foundation and contributors. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
6+
FROM microsoft/dotnet-buildtools-prereqs:opensuse-42.3-d46ee12-20180327014902
7+
8+
# Install the base toolchain we need to build anything (clang, cmake, make and the like)
9+
# this does not include libraries that we need to compile different projects, we'd like
10+
# them in a different layer.
11+
RUN zypper -n install binutils \
12+
cmake \
13+
which \
14+
gcc \
15+
llvm-clang \
16+
tar \
17+
ncurses-utils \
18+
curl \
19+
git \
20+
sudo && \
21+
zypper clean -a
22+
23+
# Dependencies of CoreCLR and CoreFX.
24+
25+
RUN zypper -n install --force-resolution \
26+
libunwind \
27+
libicu \
28+
lttng-ust \
29+
libuuid1 \
30+
libopenssl1_0_0 \
31+
libcurl4 \
32+
krb5 && \
33+
zypper clean -a
34+
35+
# Setup User to match Host User, and give superuser permissions
36+
ARG USER_ID=0
37+
RUN useradd -m code_executor -u ${USER_ID} -g wheel
38+
RUN echo 'code_executor ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
39+
40+
# With the User Change, we need to change permissions on these directories
41+
RUN chmod -R a+rwx /usr/local
42+
RUN chmod -R a+rwx /home
43+
RUN chmod -R 755 /usr/lib/sudo
44+
45+
# Set user to the one we just created
46+
USER ${USER_ID}
47+
48+
# Set working directory
49+
WORKDIR /opt/code
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#
2+
# Copyright (c) .NET Foundation and contributors. All rights reserved.
3+
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
4+
#
5+
6+
# Dockerfile that creates a container suitable to build dotnet-cli
7+
FROM microsoft/dotnet-buildtools-prereqs:ubuntu-18.04-f90bc20-20180320154721
8+
9+
RUN apt-get update && \
10+
apt-get -qqy install \
11+
sudo && \
12+
apt-get clean && \
13+
rm -rf /var/lib/apt/lists/*
14+
15+
# Setup User to match Host User, and give superuser permissions
16+
ARG USER_ID=0
17+
RUN useradd -m code_executor -u ${USER_ID} -g sudo
18+
RUN echo 'code_executor ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
19+
20+
# With the User Change, we need to change permissions on these directories
21+
RUN chmod -R a+rwx /usr/local
22+
RUN chmod -R a+rwx /home
23+
RUN chmod -R 755 /usr/lib/sudo
24+
25+
# Set user to the one we just created
26+
USER ${USER_ID}
27+
28+
# Set working directory
29+
WORKDIR /opt/code

src/Microsoft.DotNet.Cli.Utils/Microsoft.DotNet.Cli.Utils.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
<PackageReference Include="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildUtilitiesCorePackageVersion)" />
2626
<PackageReference Include="System.Runtime.InteropServices.RuntimeInformation" Version="4.3.0" />
2727
<PackageReference Include="XliffTasks" Version="$(XliffTasksPackageVersion)" PrivateAssets="All" />
28-
</ItemGroup>
28+
</ItemGroup>
2929

3030
<ItemGroup Condition=" '$(TargetFrameworkIdentifier)' == '.NETStandard' ">
3131
<PackageReference Include="NETStandard.Library" Version="2.0.0" />
Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
// Copyright (c) .NET Foundation and contributors. All rights reserved.
2+
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
3+
4+
using System;
5+
using System.IO;
6+
using Microsoft.DotNet.Tools.Test.Utilities;
7+
using Xunit;
8+
9+
namespace Microsoft.DotNet.Tests.EndToEnd
10+
{
11+
public class GivenDotNetLinuxInstallers
12+
{
13+
[Fact]
14+
public void ItHasExpectedDependencies()
15+
{
16+
var installerFile = Environment.GetEnvironmentVariable("SDK_INSTALLER_FILE");
17+
if (string.IsNullOrEmpty(installerFile))
18+
{
19+
return;
20+
}
21+
22+
var ext = Path.GetExtension(installerFile);
23+
switch (ext)
24+
{
25+
case ".deb":
26+
DebianPackageHasDependencyOnAspNetCoreStoreAndDotnetRuntime(installerFile);
27+
return;
28+
case ".rpm":
29+
RpmPackageHasDependencyOnAspNetCoreStoreAndDotnetRuntime(installerFile);
30+
return;
31+
}
32+
}
33+
34+
private void DebianPackageHasDependencyOnAspNetCoreStoreAndDotnetRuntime(string installerFile)
35+
{
36+
// Example output:
37+
38+
// $ dpkg --info dotnet-sdk-2.1.105-ubuntu-x64.deb
39+
40+
// new debian package, version 2.0.
41+
// size 75660448 bytes: control archive=29107 bytes.
42+
// 717 bytes, 11 lines control
43+
// 123707 bytes, 1004 lines md5sums
44+
// 1710 bytes, 28 lines * postinst #!/usr/bin/env
45+
// Package: dotnet-sdk-2.1.104
46+
// Version: 2.1.104-1
47+
// Architecture: amd64
48+
// Maintainer: Microsoft <[email protected]>
49+
// Installed-Size: 201119
50+
// Depends: dotnet-runtime-2.0.6, aspnetcore-store-2.0.6
51+
// Section: devel
52+
// Priority: standard
53+
// Homepage: https://dotnet.github.io/core
54+
// Description: Microsoft .NET Core SDK - 2.1.104
55+
56+
new TestCommand("dpkg")
57+
.ExecuteWithCapturedOutput($"--info {installerFile}")
58+
.Should().Pass()
59+
.And.HaveStdOutMatching(@"Depends:.*\s?dotnet-runtime-\d+(\.\d+){2}")
60+
.And.HaveStdOutMatching(@"Depends:.*\s?aspnetcore-store-\d+(\.\d+){2}");
61+
}
62+
63+
private void RpmPackageHasDependencyOnAspNetCoreStoreAndDotnetRuntime(string installerFile)
64+
{
65+
// Example output:
66+
67+
// $ rpm -qpR dotnet-sdk-2.1.105-rhel-x64.rpm
68+
69+
// dotnet-runtime-2.0.7 >= 2.0.7
70+
// aspnetcore-store-2.0.7 >= 2.0.7
71+
// /bin/sh
72+
// /bin/sh
73+
// rpmlib(PayloadFilesHavePrefix) <= 4.0-1
74+
// rpmlib(CompressedFileNames) <= 3.0.4-1
75+
76+
new TestCommand("rpm")
77+
.ExecuteWithCapturedOutput($"-qpR {installerFile}")
78+
.Should().Pass()
79+
.And.HaveStdOutMatching(@"dotnet-runtime-\d+(\.\d+){2} >= \d+(\.\d+){2}")
80+
.And.HaveStdOutMatching(@"aspnetcore-store-\d+(\.\d+){2} >= \d+(\.\d+){2}");
81+
}
82+
}
83+
}

test/Microsoft.DotNet.TestFramework/Microsoft.DotNet.TestFramework.csproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,8 @@
1414
<ProjectReference Include="..\..\src\Microsoft.DotNet.Cli.Utils\Microsoft.DotNet.Cli.Utils.csproj" />
1515
</ItemGroup>
1616

17+
<ItemGroup>
18+
<PackageReference Include="NETStandard.Library" Version="2.0.0" />
19+
</ItemGroup>
20+
1721
</Project>

test/Microsoft.DotNet.Tools.Tests.Utilities/ProjectUtils.cs

Lines changed: 0 additions & 27 deletions
This file was deleted.

0 commit comments

Comments
 (0)