diff --git a/Directory.Build.props b/Directory.Build.props index f89d2cf48264..9c2dd5c35518 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -54,6 +54,8 @@ $(DotNetRestorePackagesPath) $(ProjectDir)packages/ + $(PackagesDir) + $(PackagesDir) $(ProjectDir)Tools/ $(ToolsDir)ilasm/ilasm $(MSBuildThisFileDirectory)CodeAnalysis.ruleset @@ -149,6 +151,7 @@ <_runtimeOS Condition="'$(_runtimeOS)' == 'tizen.4.0.0'">ubuntu.14.04 <_runtimeOS Condition="'$(PortableBuild)' == 'true'">$(_portableOS) $(_runtimeOS)-x64 + $(ToolRuntimeRID) <_portableOS Condition="'$(OSGroup)' == 'Unix' AND '$(_runtimeOSFamily)' != 'osx' AND '$(_runtimeOSFamily)' != 'FreeBSD'">linux diff --git a/dependencies.props b/dependencies.props index 390db9949782..dffeffb7b160 100644 --- a/dependencies.props +++ b/dependencies.props @@ -34,6 +34,7 @@ preview1-26824-01 3.0.0-preview1-26824-01 3.0.0-preview1-26824-01 + 3.0.0-preview1-26824-01 beta-26823-00 beta-26823-00 1.0.0-beta-26823-00 @@ -136,6 +137,17 @@ MicrosoftNETCoreRuntimeCoreCLRPackageVersion Microsoft.NETCore.Runtime.CoreCLR + + $(MSBuildThisFileFullPath) + MicrosoftNetCoreIlasmPackageVersion + Microsoft.NETCore.ILAsm + + + MSBuildSdk + $(MSBuildThisFileDirectory)global.json + Microsoft.NET.Sdk.IL + Microsoft.NET.Sdk.IL + $(MSBuildThisFileFullPath) NETStandardLibraryPackageVersion @@ -180,11 +192,6 @@ File $(MSBuildThisFileDirectory)BuildToolsVersion.txt Microsoft.DotNet.BuildTools - - - File - $(MSBuildThisFileDirectory)tools-local/ILAsmVersion.txt - Microsoft.NETCore.ILAsm $(MSBuildThisFileFullPath) diff --git a/external/dir.proj b/external/dir.proj index d422e7d5a0d4..bf2f4ee75ed9 100644 --- a/external/dir.proj +++ b/external/dir.proj @@ -12,6 +12,7 @@ + diff --git a/external/tools/Configurations.props b/external/tools/Configurations.props new file mode 100644 index 000000000000..d44d223b56c5 --- /dev/null +++ b/external/tools/Configurations.props @@ -0,0 +1,15 @@ + + + + + netcoreapp-Windows_NT; + netcoreappaot-Windows_NT; + netcoreapp-Unix; + uap10.0.16299; + uap10.0.16299aot; + uap; + uapaot; + mono; + + + diff --git a/external/tools/tools.depproj b/external/tools/tools.depproj new file mode 100644 index 000000000000..78362e848f30 --- /dev/null +++ b/external/tools/tools.depproj @@ -0,0 +1,22 @@ + + + + + + false + $(ToolRuntimeRID) + true + $(NoWarn);NU1603;NU1605 + + + + + $(MicrosoftNetCoreIlasmPackageVersion) + + + $(MicrosoftNetCoreIlasmPackageVersion) + + + + + diff --git a/global.json b/global.json new file mode 100644 index 000000000000..7e73bd74ad22 --- /dev/null +++ b/global.json @@ -0,0 +1,5 @@ +{ + "msbuild-sdks": { + "Microsoft.NET.Sdk.IL": "3.0.0-preview1-26824-01" + } +} diff --git a/init-tools.cmd b/init-tools.cmd index a25fcb128bb8..7c5fbfa1229f 100644 --- a/init-tools.cmd +++ b/init-tools.cmd @@ -72,9 +72,6 @@ if NOT exist "%BUILD_TOOLS_PATH%\init-tools.cmd" ( :afterbuildtoolsrestore -:: Ask init-tools to also restore ILAsm -set /p ILASMCOMPILER_VERSION=< "%~dp0tools-local\ILAsmVersion.txt" - echo Initializing BuildTools... echo Running: "%BUILD_TOOLS_PATH%\init-tools.cmd" "%~dp0" "%DOTNET_CMD%" "%TOOLRUNTIME_DIR%" >> "%INIT_TOOLS_LOG%" call "%BUILD_TOOLS_PATH%\init-tools.cmd" "%~dp0" "%DOTNET_CMD%" "%TOOLRUNTIME_DIR%" "%PACKAGES_DIR%" >> "%INIT_TOOLS_LOG%" diff --git a/init-tools.sh b/init-tools.sh index e02509d99503..85c0709b7b16 100755 --- a/init-tools.sh +++ b/init-tools.sh @@ -10,7 +10,6 @@ if [ -z "${__BUILDTOOLS_SOURCE:-}" ]; then __BUILDTOOLS_SOURCE=https://dotnet.my export __BUILDTOOLS_USE_CSPROJ=true __BUILD_TOOLS_PACKAGE_VERSION=$(cat "$__scriptpath/BuildToolsVersion.txt" | sed 's/\r$//') # remove CR if mounted repo on Windows drive __DOTNET_TOOLS_VERSION=$(cat "$__scriptpath/DotnetCLIVersion.txt" | sed 's/\r$//') # remove CR if mounted repo on Windows drive -__ILASM_VERSION=$(cat "$__scriptpath/tools-local/ILAsmVersion.txt" | sed 's/\r$//') # remove CR if mounted repo on Windows drive __BUILD_TOOLS_PATH="$__PACKAGES_DIR/microsoft.dotnet.buildtools/$__BUILD_TOOLS_PACKAGE_VERSION/lib" __INIT_TOOLS_RESTORE_PROJECT="$__scriptpath/init-tools.msbuild" __BUILD_TOOLS_SEMAPHORE="$__TOOLRUNTIME_DIR/$__BUILD_TOOLS_PACKAGE_VERSION/init-tools.complete" @@ -157,20 +156,6 @@ if [ ! -e "$__BUILD_TOOLS_PATH" ]; then fi fi -if [ -z "${__ILASM_RID-}" ]; then - __ILASM_RID=$__PKG_RID -fi - -echo "Using RID $__ILASM_RID for BuildTools native tools" - -export ILASMCOMPILER_VERSION=$__ILASM_VERSION -export NATIVE_TOOLS_RID=$__ILASM_RID - -if [ -n "${DotNetBootstrapCliTarPath-}" ]; then - # Assume ilasm is not in nuget yet when bootstrapping... - unset ILASMCOMPILER_VERSION -fi - echo "Initializing BuildTools..." echo "Running: $__BUILD_TOOLS_PATH/init-tools.sh $__scriptpath $__DOTNET_CMD $__TOOLRUNTIME_DIR $__PACKAGES_DIR" >> "$__init_tools_log" diff --git a/src/System.Runtime.CompilerServices.Unsafe/Directory.Build.props b/src/System.Runtime.CompilerServices.Unsafe/Directory.Build.props index d6420306f658..981b58b18af5 100644 --- a/src/System.Runtime.CompilerServices.Unsafe/Directory.Build.props +++ b/src/System.Runtime.CompilerServices.Unsafe/Directory.Build.props @@ -5,6 +5,5 @@ 4.0.5.0 MSFT true - $(ToolsDir)\IL.targets - \ No newline at end of file + diff --git a/src/System.Runtime.CompilerServices.Unsafe/src/System.Runtime.CompilerServices.Unsafe.ilproj b/src/System.Runtime.CompilerServices.Unsafe/src/System.Runtime.CompilerServices.Unsafe.ilproj index 4f3f3e32eb71..c662c7065112 100644 --- a/src/System.Runtime.CompilerServices.Unsafe/src/System.Runtime.CompilerServices.Unsafe.ilproj +++ b/src/System.Runtime.CompilerServices.Unsafe/src/System.Runtime.CompilerServices.Unsafe.ilproj @@ -1,4 +1,4 @@ - + $(MSBuildThisFileDirectory)System.Runtime.CompilerServices.Unsafe.xml {04BA3E3C-6979-4792-B19E-C797AD607F42} @@ -8,10 +8,13 @@ netcoreapp-Debug;netcoreapp-Release;netcoreapp2.0-Debug;netcoreapp2.0-Release;netstandard-Debug;netstandard-Release;netstandard1.0-Debug;netstandard1.0-Release + runtime.$(MicrosoftNetCoreIlasmPackageRuntimeId).microsoft.netcore.ildasm + + + + <_IlasmSourceFiles Include="$(NuGetPackageRoot)\$(MicrosoftNetCoreIldasmPackageName)\$(MicrosoftNetCoreIlasmPackageVersion)\runtimes\$(MicrosoftNetCoreIlasmPackageRuntimeId)\native\**\*" /> + <_IlasmSourceFiles Include="$(NuGetPackageRoot)\$(MicrosoftNetCoreRuntimeCoreClrPackageName)\$(MicrosoftNetCoreIlasmPackageVersion)\runtimes\$(MicrosoftNetCoreIlasmPackageRuntimeId)\native\**\*" /> + <_IlasmSourceFiles Include="$(NuGetPackageRoot)\$(MicrosoftNetCoreJitPackageName)\$(MicrosoftNetCoreIlasmPackageVersion)\runtimes\$(MicrosoftNetCoreIlasmPackageRuntimeId)\native\**\*" /> + + + <_IlasmDir>$(ToolsDir)\ilasm + <_IldasmCommand>$(ToolsDir)ilasm/ildasm.exe <_IldasmCommand>$(_IldasmCommand) $(ContractOutputPath)/$(MSBuildProjectName).dll <_IldasmCommand>$(_IldasmCommand) /OUT=$(IntermediateOutputPath)/$(MSBuildProjectName).ref.il @@ -36,6 +47,10 @@ + + + + @@ -52,4 +67,4 @@ $(IntermediateOutputPath)$(MSBuildProjectName).ref.res.obj - \ No newline at end of file + diff --git a/tools-local/ILAsmVersion.txt b/tools-local/ILAsmVersion.txt deleted file mode 100644 index affea3b83888..000000000000 --- a/tools-local/ILAsmVersion.txt +++ /dev/null @@ -1 +0,0 @@ -3.0.0-preview1-26824-01 \ No newline at end of file