Skip to content

Commit

Permalink
Merge pull request dotnet#14683 from weshaggard/MergeDevRelease200
Browse files Browse the repository at this point in the history
Merge changes from dev/release/2.0.0
  • Loading branch information
weshaggard authored Oct 30, 2017
2 parents 868692d + 80a6421 commit 9e186c8
Show file tree
Hide file tree
Showing 24 changed files with 258 additions and 233 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -607,7 +607,7 @@ endif (CLR_CMAKE_PLATFORM_UNIX)

# Microsoft.Dotnet.BuildTools.Coreclr version
set(BuildToolsVersion "1.0.4-prerelease")
set(BuildToolsDir "${CLR_DIR}/packages/Microsoft.DotNet.BuildTools.CoreCLR/${BuildToolsVersion}")
set(BuildToolsDir "${CLR_CMAKE_PACKAGES_DIR}/Microsoft.DotNet.BuildTools.CoreCLR/${BuildToolsVersion}")

#------------------------------
# Add Product Directory
Expand Down
2 changes: 1 addition & 1 deletion build-packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ initHostDistroRid()
if [ "$__HostOS" == "Linux" ]; then
if [ -e /etc/os-release ]; then
source /etc/os-release
if [[ $ID == "alpine" ]]; then
if [[ $ID == "alpine" || $ID == "rhel" ]]; then
# remove the last version digit
VERSION_ID=${VERSION_ID%.*}
fi
Expand Down
3 changes: 2 additions & 1 deletion build.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,8 @@ set "__ProjectDir=%~dp0"
if %__ProjectDir:~-1%==\ set "__ProjectDir=%__ProjectDir:~0,-1%"
set "__ProjectFilesDir=%__ProjectDir%"
set "__SourceDir=%__ProjectDir%\src"
set "__PackagesDir=%__ProjectDir%\packages"
set "__PackagesDir=%DotNetRestorePackagesPath%"
if [%__PackagesDir%]==[] set "__PackagesDir=%__ProjectDir%\packages"
set "__RootBinDir=%__ProjectDir%\bin"
set "__LogsDir=%__RootBinDir%\Logs"
set "__PgoOptDataVersion="
Expand Down
9 changes: 7 additions & 2 deletions build.proj
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,13 @@
</Target>

<Target Name="RestoreOptData">
<Exec Command="$(DotnetRestoreCommand) $(SourceDir).nuget/optdata/optdata.csproj"
StandardOutputImportance="Low" />
<PropertyGroup>
<OptDataRestoreCommand>"$(DotnetToolCommand)"</OptDataRestoreCommand>
<OptDataRestoreCommand>$(OptDataRestoreCommand) restore</OptDataRestoreCommand>
<OptDataRestoreCommand>$(OptDataRestoreCommand) --packages "$(PackagesDir.TrimEnd('/').TrimEnd('\'))"</OptDataRestoreCommand>
</PropertyGroup>
<Exec Command="$(OptDataRestoreCommand) $(SourceDir).nuget/optdata/optdata.csproj"
StandardOutputImportance="Low" />
</Target>

<!--
Expand Down
8 changes: 4 additions & 4 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ initHostDistroRid()
if [ "$__HostOS" == "Linux" ]; then
if [ -e /etc/os-release ]; then
source /etc/os-release
if [[ $ID == "alpine" ]]; then
if [[ $ID == "alpine" || $ID == "rhel" ]]; then
# remove the last version digit
VERSION_ID=${VERSION_ID%.*}
fi
Expand Down Expand Up @@ -175,7 +175,7 @@ restore_optdata()
# Parse the optdata package versions out of msbuild so that we can pass them on to CMake
local DotNetCli="$__ProjectRoot/Tools/dotnetcli/dotnet"
if [ ! -f $DotNetCli ]; then
"$__ProjectRoot/init-tools.sh"
source "$__ProjectRoot/init-tools.sh"
if [ $? != 0 ]; then
echo "Failed to restore buildtools."
exit 1
Expand Down Expand Up @@ -334,7 +334,7 @@ build_native()
echo "Failed to generate $message build project!"
exit 1
fi

# Build
if [ $__ConfigureOnly == 1 ]; then
echo "Finish configuration & skipping $message build."
Expand Down Expand Up @@ -621,7 +621,7 @@ __IgnoreWarnings=0
# Set the various build properties here so that CMake and MSBuild can pick them up
__ProjectDir="$__ProjectRoot"
__SourceDir="$__ProjectDir/src"
__PackagesDir="$__ProjectDir/packages"
__PackagesDir="${DotNetRestorePackagesPath:-${__ProjectDir}/packages}"
__RootBinDir="$__ProjectDir/bin"
__UnprocessedBuildArgs=
__RunArgs=
Expand Down
47 changes: 29 additions & 18 deletions dependencies.props
Original file line number Diff line number Diff line change
@@ -1,16 +1,26 @@
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

<!-- NuGet package restore sources. -->
<PropertyGroup>
<RestoreSources Condition="'$(DotNetBuildOffline)' != 'true'">
https://dotnetfeed.blob.core.windows.net/dotnet-core/packages/index.json;
https://dotnet.myget.org/F/dotnet-core/api/v3/index.json;
https://api.nuget.org/v3/index.json;
$(RestoreSources)
</RestoreSources>
</PropertyGroup>

<PropertyGroup>
<!-- Central place to set the versions of all nuget packages produced in the repo -->
<PackageVersion Condition="'$(PackageVersion)' == ''">2.1.0</PackageVersion>

<!-- Set the boolean below to true to generate packages with stabilized versions -->
<StabilizePackageVersion Condition="'$(StabilizePackageVersion)' == ''">false</StabilizePackageVersion>
<StableVersion Condition="'$(StabilizePackageVersion)' == 'true' and '$(StableVersion)' == ''">$(PackageVersion)</StableVersion>

<PreReleaseLabel>preview1</PreReleaseLabel>
</PropertyGroup>

<!-- Source of truth for dependency tooling: the commit hash of the dotnet/versions master branch as of the last auto-upgrade. -->
<PropertyGroup>
<CoreFxCurrentRef>5b662e16887cd01cada59eb678ab0c1dd64438c4</CoreFxCurrentRef>
Expand All @@ -19,20 +29,16 @@
<PgoDataCurrentRef>5b662e16887cd01cada59eb678ab0c1dd64438c4</PgoDataCurrentRef>
</PropertyGroup>

<!-- Auto-upgraded properties for each build info dependency. -->
<!-- Tests/infrastructure dependency versions. -->
<PropertyGroup>
<CoreFxPackageVersion>4.5.0-preview1-25830-02</CoreFxPackageVersion>
<PlatformPackageVersion>2.1.0-preview1-25830-02</PlatformPackageVersion>
<MicrosoftPrivateCoreFxNETCoreAppPackageVersion>4.5.0-preview1-25830-02</MicrosoftPrivateCoreFxNETCoreAppPackageVersion>
<MicrosoftNETCorePlatformsPackageVersion>2.1.0-preview1-25830-02</MicrosoftNETCorePlatformsPackageVersion>
<PgoDataPackageVersion>99.99.99-master-20171030-0047</PgoDataPackageVersion>
</PropertyGroup>

<!-- Full package version strings that are used in other parts of the build. -->
<PropertyGroup>
<CoreClrPackageVersion>2.1.0-preview1-25829-02</CoreClrPackageVersion>
<MicrosoftNETCoreRuntimeCoreCLRPackageVersion>2.1.0-preview1-25829-02</MicrosoftNETCoreRuntimeCoreCLRPackageVersion>
<XunitPackageVersion>2.2.0-beta2-build3300</XunitPackageVersion>
<XUnitConsoleNetCoreVersion>1.0.2-prerelease-00177</XUnitConsoleNetCoreVersion>
<XUnitPerformanceApiVersion>1.0.0-beta-build0007</XUnitPerformanceApiVersion>
<MicrosoftDiagnosticsTracingLibraryVersion>1.0.3-alpha-experimental</MicrosoftDiagnosticsTracingLibraryVersion>
<XunitConsoleNetcorePackageVersion>1.0.2-prerelease-00177</XunitConsoleNetcorePackageVersion>
<XunitPerformanceApiPackageVersion>1.0.0-beta-build0007</XunitPerformanceApiPackageVersion>
<MicrosoftDiagnosticsTracingTraceEventPackageVersion>1.0.3-alpha-experimental</MicrosoftDiagnosticsTracingTraceEventPackageVersion>
<VCRuntimeVersion>1.2.0</VCRuntimeVersion>
</PropertyGroup>

Expand Down Expand Up @@ -73,17 +79,17 @@

<XmlUpdateStep Include="CoreFx">
<Path>$(MSBuildThisFileFullPath)</Path>
<ElementName>CoreFxPackageVersion</ElementName>
<ElementName>MicrosoftPrivateCoreFxNETCoreAppPackageVersion</ElementName>
<PackageId>Microsoft.Private.CoreFx.NETCoreApp</PackageId>
</XmlUpdateStep>
<XmlUpdateStep Include="CoreFx">
<Path>$(MSBuildThisFileFullPath)</Path>
<ElementName>PlatformPackageVersion</ElementName>
<ElementName>MicrosoftNETCorePlatformsPackageVersion</ElementName>
<PackageId>Microsoft.NETCore.Platforms</PackageId>
</XmlUpdateStep>
<XmlUpdateStep Include="CoreClr">
<Path>$(MSBuildThisFileFullPath)</Path>
<ElementName>CoreClrPackageVersion</ElementName>
<ElementName>MicrosoftNETCoreRuntimeCoreCLRPackageVersion</ElementName>
<PackageId>Microsoft.NETCore.Runtime.CoreCLR</PackageId>
</XmlUpdateStep>
<UpdateStep Include="BuildTools">
Expand Down Expand Up @@ -131,16 +137,21 @@
<XUnitPerformanceApiDependency Include="xunit.performance.execution" />
<XUnitPerformanceApiDependency Include="xunit.performance.metrics" />
<StaticDependency Include="@(XUnitPerformanceApiDependency)">
<Version>$(XUnitPerformanceApiVersion)</Version>
<Version>$(XunitPerformanceApiPackageVersion)</Version>
</StaticDependency>

<StaticDependency Include="xunit.console.netcore">
<Version>$(XUnitConsoleNetCoreVersion)</Version>
<Version>$(XunitConsoleNetcorePackageVersion)</Version>
</StaticDependency>

<DependencyBuildInfo Include="@(StaticDependency)">
<PackageId>%(Identity)</PackageId>
<UpdateStableVersions>true</UpdateStableVersions>
</DependencyBuildInfo>
</ItemGroup>

<!-- Override isolated build dependency versions with versions from Repo API. -->
<Import Project="$(DotNetPackageVersionPropsPath)"
Condition="'$(DotNetPackageVersionPropsPath)' != ''" />

</Project>
9 changes: 5 additions & 4 deletions dir.props
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,9 @@
<!-- This name is used to create a GIT repository URL https://github.com/dotnet/$(GitHubRepositoryName) used to find source code for debugging -->
<GitHubRepositoryName Condition="'$(GitHubRepositoryName)' == ''">coreclr</GitHubRepositoryName>

<PackagesDir>$(__PackagesDir)\</PackagesDir>
<PackagesDir Condition="'$(__PackagesDir)'==''">$(ProjectDir)packages\</PackagesDir>
<PackagesDir>$(DotNetRestorePackagesPath)</PackagesDir>
<PackagesDir Condition="'$(PackagesDir)'=='' and '$(__PackagesDir)'!=''">$(__PackagesDir)\</PackagesDir>
<PackagesDir Condition="'$(PackagesDir)'==''">$(ProjectDir)packages\</PackagesDir>

<RootBinDir>$(__RootBinDir)\</RootBinDir>
<RootBinDir Condition="'$(__RootBinDir)'==''">$(ProjectDir)bin\</RootBinDir>
Expand Down Expand Up @@ -165,8 +166,8 @@
<CrossTargetComponentFolder Condition="'$(PackagePlatform)' == 'arm64'">x64</CrossTargetComponentFolder>
<CrossTargetComponentFolder Condition="'$(PackagePlatform)' == 'arm'">x86</CrossTargetComponentFolder>

<PackageOutputPath>$(PackagesBinDir)/pkg/</PackageOutputPath>
<SymbolPackageOutputPath>$(PackagesBinDir)/symbolpkg/</SymbolPackageOutputPath>
<PackageOutputPath Condition="'$(PackageOutputPath)' == ''">$(PackagesBinDir)/pkg/</PackageOutputPath>
<SymbolPackageOutputPath Condition="'$(SymbolPackageOutputPath)' == ''">$(PackagesBinDir)/symbolpkg/</SymbolPackageOutputPath>
<PackageIndexFile>$(MSBuildThisFileDirectory)/src/.nuget/packageIndex.json</PackageIndexFile>

<!-- coreclr doesn't currently use the index so don't force it to be in sync -->
Expand Down
18 changes: 13 additions & 5 deletions init-tools.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,18 @@ if exist "%BUILD_TOOLS_SEMAPHORE%" (

if exist "%TOOLRUNTIME_DIR%" rmdir /S /Q "%TOOLRUNTIME_DIR%"

:: Download Nuget.exe
if NOT exist "%PACKAGES_DIR%NuGet.exe" (
if NOT exist "%PACKAGES_DIR%" mkdir "%PACKAGES_DIR%"
powershell -NoProfile -ExecutionPolicy unrestricted -Command "(New-Object Net.WebClient).DownloadFile('https://www.nuget.org/nuget.exe', '%PACKAGES_DIR%NuGet.exe')
if exist "%DotNetBuildToolsDir%" (
echo Using tools from '%DotNetBuildToolsDir%'.
mklink /j "%TOOLRUNTIME_DIR%" "%DotNetBuildToolsDir%"

if not exist "%DOTNET_CMD%" (
echo ERROR: Ensure that '%DotNetBuildToolsDir%' contains the .NET Core SDK at '%DOTNET_PATH%'
exit /b 1
)

echo Done initializing tools.
echo Using tools from '%DotNetBuildToolsDir%'. > "%BUILD_TOOLS_SEMAPHORE%"
exit /b 0
)

echo Running %0 > "%INIT_TOOLS_LOG%"
Expand All @@ -41,7 +49,7 @@ if exist "%DOTNET_CMD%" goto :afterdotnetrestore
echo %__MsgPrefix%Installing dotnet cli...
if NOT exist "%DOTNET_PATH%" mkdir "%DOTNET_PATH%"
set DOTNET_ZIP_NAME=dotnet-sdk-%DOTNET_VERSION%-win-x64.zip
set DOTNET_REMOTE_PATH=https://dotnetcli.blob.core.windows.net/dotnet/Sdk/%DOTNET_VERSION%/%DOTNET_ZIP_NAME%
set DOTNET_REMOTE_PATH=https://dotnetcli.azureedge.net/dotnet/Sdk/%DOTNET_VERSION%/%DOTNET_ZIP_NAME%
set DOTNET_LOCAL_PATH=%DOTNET_PATH%%DOTNET_ZIP_NAME%
echo %__MsgPrefix%Installing '%DOTNET_REMOTE_PATH%' to '%DOTNET_LOCAL_PATH%' >> "%INIT_TOOLS_LOG%"
powershell -NoProfile -ExecutionPolicy unrestricted -Command "$retryCount = 0; $success = $false; do { try { (New-Object Net.WebClient).DownloadFile('%DOTNET_REMOTE_PATH%', '%DOTNET_LOCAL_PATH%'); $success = $true; } catch { if ($retryCount -ge 6) { throw; } else { $retryCount++; Start-Sleep -Seconds (5 * $retryCount); } } } while ($success -eq $false); Add-Type -Assembly 'System.IO.Compression.FileSystem' -ErrorVariable AddTypeErrors; if ($AddTypeErrors.Count -eq 0) { [System.IO.Compression.ZipFile]::ExtractToDirectory('%DOTNET_LOCAL_PATH%', '%DOTNET_PATH%') } else { (New-Object -com shell.application).namespace('%DOTNET_PATH%').CopyHere((new-object -com shell.application).namespace('%DOTNET_LOCAL_PATH%').Items(),16) }" >> "%INIT_TOOLS_LOG%"
Expand Down
Loading

0 comments on commit 9e186c8

Please sign in to comment.