Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ WARNING: DO NOT MODIFY this file unless you are knowledgeable about MSBuild and
created a backup copy. Incorrect changes to this file will make it
impossible to load or build your projects from the command-line or the IDE.

Copyright (c) .NET Foundation. All rights reserved.
Copyright (c) .NET Foundation. All rights reserved.
***********************************************************************************************
-->
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
Expand All @@ -30,7 +30,7 @@ Copyright (c) .NET Foundation. All rights reserved.
<MicrosoftNETCoreILAsmVersion Condition="'$(MicrosoftNETCoreILAsmVersion)' == ''">5.0.0</MicrosoftNETCoreILAsmVersion>
<MicrosoftNetCoreIlasmPackageName>runtime.$(MicrosoftNetCoreIlasmPackageRuntimeId).microsoft.netcore.ilasm</MicrosoftNetCoreIlasmPackageName>
<MicrosoftNetCoreIldasmPackageName>runtime.$(MicrosoftNetCoreIlasmPackageRuntimeId).microsoft.netcore.ildasm</MicrosoftNetCoreIldasmPackageName>

<!-- If ILAsmToolPath is specified, it will be used and no packages will be restored
Otherwise packages will be restored and ilasm and ildasm will be referenced from their packages. -->
<_IlasmDir Condition="'$(ILAsmToolPath)' != ''">$([MSBuild]::NormalizeDirectory($(ILAsmToolPath)))</_IlasmDir>
Expand Down Expand Up @@ -68,15 +68,15 @@ Copyright (c) .NET Foundation. All rights reserved.
</Target>

<!-- projects can define an ILResourceReference and we'll decompile it to get native resources -->
<Target Name="DisassembleIlasmResourceFile"
BeforeTargets="CoreCompile"
<Target Name="DisassembleIlasmResourceFile"
BeforeTargets="CoreCompile"
Condition="'$(OS)'=='Windows_NT'"
Inputs="@(ILResourceReference)"
Outputs="$(IntermediateOutputPath)$(MSBuildProjectName).ref.res.obj">
<Error Condition="'@(ILResourceReference->Count())' != '1'" Text="Only one ILResourceReference can be specified" />
<PropertyGroup>
<_ilResourceReference>%(ILResourceReference.FullPath)</_ilResourceReference>
<_IldasmCommand>$(_IldasmDir)ildasm</_IldasmCommand>
<_IldasmCommand>"$(_IldasmDir)ildasm"</_IldasmCommand>
<_IldasmCommand>$(_IldasmCommand) "$(_ilResourceReference)"</_IldasmCommand>
<_IldasmCommand>$(_IldasmCommand) /OUT="$(IntermediateOutputPath)/$(MSBuildProjectName).ref.il"</_IldasmCommand>

Expand Down Expand Up @@ -122,17 +122,17 @@ Copyright (c) .NET Foundation. All rights reserved.

<_KeyFileArgument Condition="'$(KeyOriginatorFile)' != ''">-KEY="$(KeyOriginatorFile)"</_KeyFileArgument>

<_IlasmSwitches>-QUIET -NOLOGO</_IlasmSwitches>
<_IlasmSwitches>-QUIET -NOLOGO</_IlasmSwitches>
<_IlasmSwitches Condition="'$(FoldIdenticalMethods)' == 'True'">$(_IlasmSwitches) -FOLD</_IlasmSwitches>
<_IlasmSwitches Condition="'$(SizeOfStackReserve)' != ''">$(_IlasmSwitches) -STACK=$(SizeOfStackReserve)</_IlasmSwitches>
<_IlasmSwitches Condition="'$(DebugType)' == 'Full'">$(_IlasmSwitches) -DEBUG</_IlasmSwitches>
<_IlasmSwitches Condition="'$(DebugType)' == 'Impl'">$(_IlasmSwitches) -DEBUG=IMPL</_IlasmSwitches>
<_IlasmSwitches Condition="'$(DebugType)' == 'PdbOnly'">$(_IlasmSwitches) -DEBUG=OPT</_IlasmSwitches>
<_IlasmSwitches Condition="'$(Optimize)' == 'True'">$(_IlasmSwitches) -OPTIMIZE</_IlasmSwitches>
<_IlasmSwitches Condition="'$(IlasmResourceFile)' != ''">$(_IlasmSwitches) -RESOURCES=$(IlasmResourceFile)</_IlasmSwitches>
<_IlasmSwitches Condition="'$(IlasmResourceFile)' != ''">$(_IlasmSwitches) -RESOURCES="$(IlasmResourceFile)"</_IlasmSwitches>
</PropertyGroup>

<Exec Command="$(_IlasmDir)ilasm $(_IlasmSwitches) $(_OutputTypeArgument) $(IlasmFlags) -OUTPUT=&quot;@(IntermediateAssembly)&quot; $(_KeyFileArgument) @(Compile, ' ')">
<Exec Command="&quot;$(_IlasmDir)ilasm&quot; $(_IlasmSwitches) $(_OutputTypeArgument) $(IlasmFlags) -OUTPUT=&quot;@(IntermediateAssembly)&quot; $(_KeyFileArgument) @(Compile, ' ')">
<Output TaskParameter="ExitCode" PropertyName="_ILAsmExitCode" />
</Exec>

Expand Down