diff --git a/eng/testing/linker/project.csproj.template b/eng/testing/linker/project.csproj.template index 6dcd1c5754dd9..ab498732e2ebf 100644 --- a/eng/testing/linker/project.csproj.template +++ b/eng/testing/linker/project.csproj.template @@ -36,13 +36,12 @@ {IlcSdkPath} {IlcFrameworkPath} {IlcFrameworkNativePath} - lld - $(ROOTFS_DIR) + $(ROOTFS_DIR) {CoreCLRBuildIntegrationDir} - + @@ -62,4 +61,25 @@ IsImplicitlyDefined="true" /> + + + clang + + + + + + + + $(_CC_LDFLAGS.SubString(0, $(_CC_LDFLAGS.IndexOf(';')))) + <_LDFLAGS>$(_CC_LDFLAGS.SubString($([MSBuild]::Add($(_CC_LDFLAGS.IndexOf(';')), 1)))) + lld + + + diff --git a/eng/testing/tests.singlefile.targets b/eng/testing/tests.singlefile.targets index 6b869bd02c60a..7ed0a83a76cbc 100644 --- a/eng/testing/tests.singlefile.targets +++ b/eng/testing/tests.singlefile.targets @@ -29,7 +29,6 @@ $(CoreCLRAotSdkDir) $(NetCoreAppCurrentTestHostSharedFrameworkPath) $(NetCoreAppCurrentTestHostSharedFrameworkPath) - lld $(NoWarn);IL1005;IL2105;IL3000;IL3001;IL3002;IL3003 partial true @@ -130,12 +129,18 @@ clang - - + + + + $(_CC_LDFLAGS.SubString(0, $(_CC_LDFLAGS.IndexOf(';')))) + <_LDFLAGS>$(_CC_LDFLAGS.SubString($([MSBuild]::Add($(_CC_LDFLAGS.IndexOf(';')), 1)))) + lld + - clang - - true - - + + + + $(_CC_LDFLAGS.SubString(0, $(_CC_LDFLAGS.IndexOf(';')))) + <_LDFLAGS>$(_CC_LDFLAGS.SubString($([MSBuild]::Add($(_CC_LDFLAGS.IndexOf(';')), 1)))) + + true + diff --git a/src/coreclr/tools/aot/crossgen2/crossgen2.csproj b/src/coreclr/tools/aot/crossgen2/crossgen2.csproj index e19cbbeae9f6e..464aa2bc42907 100644 --- a/src/coreclr/tools/aot/crossgen2/crossgen2.csproj +++ b/src/coreclr/tools/aot/crossgen2/crossgen2.csproj @@ -90,15 +90,20 @@ BeforeTargets="SetupOSSpecificProps"> clang - lld - - + + + + $(_CC_LDFLAGS.SubString(0, $(_CC_LDFLAGS.IndexOf(';')))) + <_LDFLAGS>$(_CC_LDFLAGS.SubString($([MSBuild]::Add($(_CC_LDFLAGS.IndexOf(';')), 1)))) + lld + diff --git a/src/tests/Directory.Build.targets b/src/tests/Directory.Build.targets index 104f53ebda3a8..3c97da76c275f 100644 --- a/src/tests/Directory.Build.targets +++ b/src/tests/Directory.Build.targets @@ -533,7 +533,6 @@ $(MicrosoftNetCoreAppRuntimePackNativeDir) $(OutputRid) - lld $(ROOTFS_DIR) true true @@ -570,4 +569,25 @@ Condition="'$(_WillCLRTestProjectBuild)' == 'true' and '$(CLRTestKind)' == 'BuildAndRun'" DependsOnTargets="ComputeResolvedFilesToPublishList;LinkNative" /> + + + clang + + + + + + + + $(_CC_LDFLAGS.SubString(0, $(_CC_LDFLAGS.IndexOf(';')))) + <_LDFLAGS>$(_CC_LDFLAGS.SubString($([MSBuild]::Add($(_CC_LDFLAGS.IndexOf(';')), 1)))) + lld + + +