Skip to content

Commit

Permalink
vNext Removal and merge with *.2017.csproj files (dotnet#3231)
Browse files Browse the repository at this point in the history
* Merge vNext\src to 2017 csproj files.
Delete vNext folder.
Update CI build file to build 2017 sln with Current BuildFlavor.
Move NuGet PackageReference Versions to props file.

* Update BenchmarkDotNet version to fix netfx build failure.

* Add TargetFramework to OrleansHost and OrleansManager project.
Add dotnet.exe to Path to see if CI picks it up for building F#.

* Disable F# because of CI server for now.

* Change project factory guids in SLN file to CPS ones.
Remove F# projects from default build configuration.

* Removed legacy files.

* Cleanup csproj files.
Annotate props files with comments.
Add back FSharp support.

* Change dotnet cli to 2.0.0
Fix OrleansBondUtils.csproj by adding condition to package fallback
Include OrleansGCPUtils in solution
Add build script wrapper
Update CI script to always use net462 machine until netstandard 2.0 update.

* Fix FSharp implicit references
Add TestInternalGrainInterfaces to solution

* Add PackageOutputPath for easier build consumption for local builds
Change legacy version to 1.6.0 to match with master
Remove unused parts from props file

* Add BuildFlavor and Configuration to Bootstrap folder structure and based it on RepoRoot variable
Move Bootstrap into root folder
Delete now unneeded targets file in test folder
Rename RepoRoot to SourceRoot

* Move from netstandard 1.5 to 2.0

* Address feedback

* Add #if to AppDomain class usage

* Add DesignTime build check

* Increase build stability.

* Add NuGet.config for CI
Enable parallel builds in Build-Core.cmd

* Revert back to net462 and netstandard15 for this PR. NetStandard 2.0 will be a separate one

* Adding back /m:1 because of CI

* Update test running scripts to honor platform argument
  • Loading branch information
Attila Hajdrik authored and ReubenBond committed Aug 23, 2017
1 parent e7d5ff7 commit 9c32519
Show file tree
Hide file tree
Showing 479 changed files with 2,180 additions and 21,136 deletions.
4 changes: 0 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@

# Tool Runtime Dir
/[Tt]ools/
/vNext/[Tt]ools/
/vNext/src/[Bb]ootstrap/
/vNext/[Bb]ootstrap/
/src/[Tt]ools/
/src/[Bb]ootstrap/

# Orleans code-gen files
Expand Down
20 changes: 11 additions & 9 deletions vNext/Build.cmd → Build-Core.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@ if NOT [%ERRORLEVEL%]==[0] exit /b 1
set _toolRuntime=%~dp0Tools
set _dotnet=%_toolRuntime%\dotnetcli\dotnet.exe

SET PATH=%_toolRuntime%\dotnetcli;%PATH%

SET TOOLS_PACKAGES_PATH=%CMDHOME%\packages

SET SOLUTION=%CMDHOME%\Orleans.vNext.sln
SET SOLUTION=%CMDHOME%\Orleans.sln

:: Set DateTime suffix for debug builds
for /f %%i in ('powershell -NoProfile -ExecutionPolicy ByPass Get-Date -format "{yyyyMMddHHmm}"') do set DATE_SUFFIX=%%i
Expand All @@ -31,31 +33,31 @@ call %_dotnet% restore "%CMDHOME%\Build\Tools.csproj" --packages %TOOLS_PACKAGES

SET CURRENT_CONFIGURATION=Debug

call %_dotnet% restore /p:Configuration=%CURRENT_CONFIGURATION%;IncludeFSharp=false "%SOLUTION%"
call %_dotnet% restore /p:Configuration=%CURRENT_CONFIGURATION% "%SOLUTION%"
@if ERRORLEVEL 1 GOTO :ErrorStop
@echo RESTORE ok for %CURRENT_CONFIGURATION% %SOLUTION%

call %_dotnet% build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION%;IncludeFSharp=false "%SOLUTION%"
call %_dotnet% build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION% "%SOLUTION%"
@if ERRORLEVEL 1 GOTO :ErrorStop
@echo BUILD ok for %CURRENT_CONFIGURATION% %SOLUTION%

call %_dotnet% pack --no-build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION%;IncludeFSharp=false;VersionDateSuffix=%DATE_SUFFIX% "%SOLUTION%"
call %_dotnet% pack --no-build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION%;VersionDateSuffix=%DATE_SUFFIX% "%SOLUTION%"
@if ERRORLEVEL 1 GOTO :ErrorStop
@echo PACKAGE ok for %CURRENT_CONFIGURATION% %SOLUTION%

@echo Build Release ============================

SET CURRENT_CONFIGURATION=Release

call %_dotnet% restore /p:Configuration=%CURRENT_CONFIGURATION%;IncludeFSharp=false "%SOLUTION%"
call %_dotnet% restore /p:Configuration=%CURRENT_CONFIGURATION% "%SOLUTION%"
@if ERRORLEVEL 1 GOTO :ErrorStop
@echo RESTORE ok for %CURRENT_CONFIGURATION% %SOLUTION%

call %_dotnet% build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION%;IncludeFSharp=false "%SOLUTION%"
call %_dotnet% build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION% "%SOLUTION%"
@if ERRORLEVEL 1 GOTO :ErrorStop
@echo BUILD ok for %CURRENT_CONFIGURATION% %SOLUTION%

call %_dotnet% pack --no-build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION%;IncludeFSharp=false "%SOLUTION%"
call %_dotnet% pack --no-build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION% "%SOLUTION%"
@if ERRORLEVEL 1 GOTO :ErrorStop
@echo PACKAGE ok for %CURRENT_CONFIGURATION% %SOLUTION%

Expand All @@ -66,15 +68,15 @@ goto :BuildFinished

SET CURRENT_CONFIGURATION=Debug

call %_dotnet% pack --no-build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION%;IncludeFSharp=false;VersionDateSuffix=%DATE_SUFFIX% "%SOLUTION%"
call %_dotnet% pack --no-build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION%;VersionDateSuffix=%DATE_SUFFIX% "%SOLUTION%"
@if ERRORLEVEL 1 GOTO :ErrorStop
@echo PACKAGE ok for %CURRENT_CONFIGURATION% %SOLUTION%

@echo Package Release ============================

SET CURRENT_CONFIGURATION=Release

call %_dotnet% pack --no-build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION%;IncludeFSharp=false "%SOLUTION%"
call %_dotnet% pack --no-build %BUILD_FLAGS% /p:Configuration=%CURRENT_CONFIGURATION% "%SOLUTION%"
@if ERRORLEVEL 1 GOTO :ErrorStop
@echo PACKAGE ok for %CURRENT_CONFIGURATION% %SOLUTION%

Expand Down
90 changes: 0 additions & 90 deletions Build.2017.cmd

This file was deleted.

29 changes: 18 additions & 11 deletions Build.cmd
Original file line number Diff line number Diff line change
@@ -1,28 +1,35 @@
@if not defined _echo @echo off
setlocal

if [%1]==[] GOTO NETFX
if [%1]==[netfx] GOTO NETFX
if [%1]==[netstandard-win] GOTO VNEXT
if [%1]==[netstandard] GOTO VNEXT
if [%1]==[] GOTO CURRENT
if [%1]==[current] GOTO CURRENT
if [%1]==[netstandard-win] GOTO CURRENT
if [%1]==[netstandard] GOTO CURRENT
if [%1]==[netfx] GOTO LEGACY
if [%1]==[legacy] GOTO LEGACY
if [%1]==[all] GOTO ALL

:NETFX
cmd /c "%~dp0src\Build.cmd"
:CURRENT
set BuildFlavor=
cmd /c "%~dp0Build-Core.cmd"
set exitcode=%errorlevel%
GOTO END

:VNEXT
cmd /c "%~dp0vNext\Build.cmd"
:LEGACY
set BuildFlavor=Legacy
cmd /c "%~dp0Build-Core.cmd"
set exitcode=%errorlevel%
GOTO END

:ALL
cmd /c "%~dp0src\Build.cmd"
set BuildFlavor=
cmd /c "%~dp0Build-Core.cmd"
set exitcode=%errorlevel%
cmd /c "%~dp0vNext\Build.cmd"

set BuildFlavor=Legacy
cmd /c "%~dp0Build-Core.cmd"
set /a exitcode=%errorlevel%+%exitcode%

:END
endlocal&set exitcode=%exitcode%
exit /B %exitcode%
exit /B %exitcode%
143 changes: 123 additions & 20 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
<Project>
<!-- Set the repository root into a variable -->
<PropertyGroup>
<VersionPrefix Condition=" '$(VersionPrefix)'=='' ">1.5.0</VersionPrefix>
<VersionSuffix Condition=" '$(VersionSuffix)'=='' ">beta2</VersionSuffix>
<SourceRoot>$(MSBuildThisFileDirectory)</SourceRoot>
</PropertyGroup>

<PropertyGroup Label="NuGet">
<!-- Set common properties regarding assembly information and nuget packages -->
<PropertyGroup>
<Authors>Microsoft</Authors>
<Product>Microsoft Orleans</Product>
<Copyright>Copyright (c) Microsoft Corporation 2017</Copyright>
Expand All @@ -15,32 +16,134 @@
<PackageReleaseNotes></PackageReleaseNotes>
<RepositoryUrl>https://github.com/dotnet/Orleans</RepositoryUrl>
<RepositoryType>git</RepositoryType>
<IncludeSymbols>true</IncludeSymbols>
<IncludeSource>true</IncludeSource>
</PropertyGroup>

<!-- For Debug builds generated a date/time dependent version suffix -->
<PropertyGroup Condition=" '$(Configuration)'=='Debug' ">
<VersionSuffix Condition=" '$(VersionSuffix)'=='' ">dev</VersionSuffix>
<VersionSuffix Condition=" '$(VersionDateSuffix)'!='' ">$(VersionSuffix)-$(VersionDateSuffix)</VersionSuffix>
<!-- Common compile parameters -->
<PropertyGroup>
<GenerateDocumentationFile Condition="'$(Configuration)'=='Release'">true</GenerateDocumentationFile>
<NoWarn>$(NoWarn);1591</NoWarn>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
</PropertyGroup>

<!-- Until we removing old csproj files we need to exclude assembly attributes from AssemblyInfo.cs files -->
<!-- FSharp SDK overrides -->
<PropertyGroup>
<DefineConstants>$(DefineConstants);EXCLUDE_ASSEMBLYINFO</DefineConstants>
<DisableImplicitSystemValueTupleReference>true</DisableImplicitSystemValueTupleReference>
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
</PropertyGroup>

<!-- Until VS2017 Update 3 released we've to exclude the F# bits from compilation -->
<PropertyGroup Condition="'$(IncludeFSharp)'==''">
<DefineConstants>$(DefineConstants);EXCLUDEFSHARP</DefineConstants>
<!-- BuildFlavor can be Legacy (Orleans 1.x) or Current, default is Current if otherwise not specified -->
<PropertyGroup>
<BuildFlavor Condition=" '$(BuildFlavor)' == '' ">Current</BuildFlavor>
</PropertyGroup>

<PropertyGroup Condition=" '$(BuildFlavor)' == 'Current' ">
<DefineConstants>$(DefineConstants);NETSTANDARD;NETSTANDARD_TODO</DefineConstants>
<TargetFramework>netstandard1.5</TargetFramework>
<TestProjectTargetFramework>net462</TestProjectTargetFramework>
</PropertyGroup>

<PropertyGroup Condition=" '$(BuildFlavor)' == 'Legacy' ">
<TargetFramework>net461</TargetFramework>
<TestProjectTargetFramework>net461</TestProjectTargetFramework>
</PropertyGroup>

<!-- Shared Package Versions -->
<PropertyGroup>
<IncludeSymbols>true</IncludeSymbols>
<IncludeSource>true</IncludeSource>
<GenerateDocumentationFile Condition="'$(Configuration)'=='Release'">true</GenerateDocumentationFile>
<NoWarn>$(NoWarn);1591</NoWarn>
<!-- System packages -->
<SystemRuntimeVersion>4.3.0</SystemRuntimeVersion>
<SystemCollectionsImmutableVersion>1.3.1</SystemCollectionsImmutableVersion>

<!-- Microsoft packages -->
<MicrosoftCodeAnalysisCSharpVersion>2.0.0</MicrosoftCodeAnalysisCSharpVersion>

<MicrosoftExtensionsConfigurationBinderVersion>1.1.2</MicrosoftExtensionsConfigurationBinderVersion>
<MicrosoftExtensionsConfigurationEnvironmentVariablesVersion>1.1.2</MicrosoftExtensionsConfigurationEnvironmentVariablesVersion>
<MicrosoftExtensionsConfigurationJsonVersion>1.1.2</MicrosoftExtensionsConfigurationJsonVersion>
<MicrosoftExtensionsConfigurationVersion>1.1.2</MicrosoftExtensionsConfigurationVersion>
<MicrosoftExtensionsOptionsVersion>1.1.2</MicrosoftExtensionsOptionsVersion>
<MicrosoftExtensionsOptionsConfigurationExtensionsVersion>1.1.2</MicrosoftExtensionsOptionsConfigurationExtensionsVersion>
<MicrosoftExtensionsDependencyInjection>1.1.1</MicrosoftExtensionsDependencyInjection>

<MicrosoftDataSQLiteVersion>1.1.0</MicrosoftDataSQLiteVersion>
<MicrosoftPowerShell5ReferenceAssembliesVersion>1.0.0</MicrosoftPowerShell5ReferenceAssembliesVersion>
<MicrosoftServiceFabricServicesVersion>2.4.145</MicrosoftServiceFabricServicesVersion>

<FSharpCoreVersion>4.2.1</FSharpCoreVersion>

<SystemManagementAutomationdllVersion>10.0.10586</SystemManagementAutomationdllVersion>

<!-- 3rd party packages -->
<MySqlDataVersion>6.9.9</MySqlDataVersion>
<NewtonsoftJsonVersion>10.0.3</NewtonsoftJsonVersion>
<NewRelicAgentApiVersion>5.10.59.0</NewRelicAgentApiVersion>
<NpgsqlVersion>3.1.9</NpgsqlVersion>
<NSubstituteVersion>1.10.0</NSubstituteVersion>
<GoogleCloudPubSubV1Version>1.0.0-beta13</GoogleCloudPubSubV1Version>

<!-- Test related packages -->
<BenchmarkDotNetVersion>0.10.8</BenchmarkDotNetVersion>
<FluentAssertionsVersion>4.19.3</FluentAssertionsVersion>
<XunitSkippableFactVersion>1.3.3</XunitSkippableFactVersion>
<xUnitVersion>2.2.0</xUnitVersion>
</PropertyGroup>

<PropertyGroup Condition=" '$(BuildFlavor)' == 'Current' ">
<!-- System packages -->
<SystemNetHttpVersion>4.3.1</SystemNetHttpVersion>

<!-- Microsoft packages -->
<MicrosoftApplicationInsightsVersion>2.2.0</MicrosoftApplicationInsightsVersion>
<MicrosoftAzureEventHubsVersion>1.0.0</MicrosoftAzureEventHubsVersion>
<WindowsAzureStorageVersion>8.1.1</WindowsAzureStorageVersion>

<!-- 3rd party packages -->
<AWSSDKDynamoDBv2Version>3.3.3</AWSSDKDynamoDBv2Version>
<AWSSDKSQSVersion>3.3.1.7</AWSSDKSQSVersion>
<BondCoreCSharpVersion>5.2.0</BondCoreCSharpVersion>
<ConsulVersion>0.7.2.1</ConsulVersion>
<GoogleProtobufVersion>3.2.0</GoogleProtobufVersion>
<ZooKeeperNetExVersion>3.4.9.2</ZooKeeperNetExVersion>
</PropertyGroup>

<PropertyGroup Condition=" '$(BuildFlavor)' == 'Legacy' ">
<!-- System packages -->
<SystemReflectionMetadataVersion>1.4.2</SystemReflectionMetadataVersion>

<!-- Microsoft packages -->
<MicrosoftApplicationInsightsVersion>1.2.3</MicrosoftApplicationInsightsVersion>
<WindowsAzureServiceBusVersion>4.1.0</WindowsAzureServiceBusVersion>
<WindowsAzureStorageVersion>7.0.0</WindowsAzureStorageVersion>

<!-- 3rd party packages -->
<AWSSDKDynamoDBv2Version>3.1.5.2</AWSSDKDynamoDBv2Version>
<AWSSDKSQSVersion>3.1.0.9</AWSSDKSQSVersion>
<BondCoreCSharpVersion>4.0.1</BondCoreCSharpVersion>
<ConsulVersion>0.7.0.3</ConsulVersion>
<GoogleProtobufVersion>3.0.0</GoogleProtobufVersion>
<ZooKeeperNetExVersion>3.4.8.5</ZooKeeperNetExVersion>
</PropertyGroup>

<ItemGroup>
<ProjectCapability Include="ShowFilesOutsideOfProject" />
</ItemGroup>
</Project>
<!-- Versioning properties -->
<PropertyGroup Condition=" '$(BuildFlavor)' == 'Current' ">
<VersionPrefix Condition=" '$(VersionPrefix)'=='' ">2.0.0</VersionPrefix>
<VersionSuffix Condition=" '$(VersionSuffix)'=='' ">preview3</VersionSuffix>
</PropertyGroup>

<PropertyGroup Condition=" '$(BuildFlavor)' == 'Legacy' ">
<VersionPrefix Condition=" '$(VersionPrefix)'=='' ">1.6.0</VersionPrefix>
<VersionSuffix Condition=" '$(VersionSuffix)'=='' "></VersionSuffix>
</PropertyGroup>

<!-- For Debug builds generated a date/time dependent version suffix -->
<PropertyGroup Condition=" '$(Configuration)'=='Debug' ">
<VersionSuffix Condition=" '$(VersionSuffix)'=='' ">dev</VersionSuffix>
<VersionSuffix Condition=" '$(VersionDateSuffix)'!='' ">$(VersionSuffix)-$(VersionDateSuffix)</VersionSuffix>
</PropertyGroup>

<!-- Set output folder for created NuGet packages -->
<PropertyGroup>
<PackageOutputPath Condition=" '$(PackageOutputPath)'=='' ">$(SourceRoot)/Artifacts/$(BuildFlavor)/$(Configuration)</PackageOutputPath>
</PropertyGroup>
</Project>
10 changes: 10 additions & 0 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<Project>
<!-- Begin Orleans: Without these lines the project won't build properly -->
<!-- Set path to ClientGenerator.exe -->
<PropertyGroup Condition=" '$(OrleansBuildTimeCodeGen)' == 'true' ">
<!--<OrleansReferencesBase>$(ProjectDir)../Bootstrap/$(BuildFlavor)/$(Configuration)</OrleansReferencesBase>-->
<OrleansReferencesBase>$(SourceRoot)/Bootstrap/$(BuildFlavor)/$(Configuration)/</OrleansReferencesBase>
</PropertyGroup>
<Import Project="$(SourceRoot)/src/Orleans.SDK.targets" Condition=" '$(OrleansBuildTimeCodeGen)' == 'true' and Exists('$(SourceRoot)/src/Orleans.SDK.targets') " />
<!--End Orleans -->
</Project>
Loading

0 comments on commit 9c32519

Please sign in to comment.