Add support to specify substitutions externally (#88230)
authorMichal Strehovský <MichalStrehovsky@users.noreply.github.com>
Tue, 11 Jul 2023 04:50:09 +0000 (13:50 +0900)
committerGitHub <noreply@github.com>
Tue, 11 Jul 2023 04:50:09 +0000 (13:50 +0900)
commit076f8c58984b009033204ad1dd9f86c691ae42fb
treec1b18f99433bac75e186119398d82eb6af4505c3
parent17a5d436ffe71f33e16b171000edb835c6bd5dc4
Add support to specify substitutions externally (#88230)

ILLinker allows specifying substitutions on the command line, same as descriptors. This can be useful for various workarounds. Add support for this for ILC as well.
15 files changed:
src/coreclr/tools/Common/Compiler/ProcessLinkerXmlBase.cs
src/coreclr/tools/aot/ILCompiler.Compiler.Tests/DependencyGraphTests.cs
src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/BodySubstitution.cs
src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/BodySubstitutionParser.cs
src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/FeatureSwitchManager.cs
src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/ManifestResourceBlockingPolicy.cs
src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/UsageBasedMetadataManager.cs
src/coreclr/tools/aot/ILCompiler/ILCompilerRootCommand.cs
src/coreclr/tools/aot/ILCompiler/Program.cs
src/coreclr/tools/aot/Mono.Linker.Tests/TestCasesRunner/ILCompilerDriver.cs
src/tests/nativeaot/SmokeTests/TrimmingBehaviors/FeatureSwitches.cs
src/tests/nativeaot/SmokeTests/TrimmingBehaviors/ILLink.Substitutions.xml
src/tests/nativeaot/SmokeTests/TrimmingBehaviors/NonEmbedded.ILLink.Substitutions1.xml [new file with mode: 0644]
src/tests/nativeaot/SmokeTests/TrimmingBehaviors/NonEmbedded.ILLink.Substitutions2.xml [new file with mode: 0644]
src/tests/nativeaot/SmokeTests/TrimmingBehaviors/TrimmingBehaviors.csproj