-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Make dependency on lld optional #85667
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 4 commits
a8e0a1c
da82152
e8a297b
a0f4d40
f13fa80
d425a7a
3eb227a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -533,7 +533,6 @@ | |
| <IlcFrameworkNativePath>$(MicrosoftNetCoreAppRuntimePackNativeDir)</IlcFrameworkNativePath> | ||
| <RuntimeIdentifier>$(OutputRid)</RuntimeIdentifier> | ||
|
|
||
| <LinkerFlavor Condition="'$(TargetOS)' == 'linux'">lld</LinkerFlavor> | ||
| <SysRoot Condition="'$(CrossBuild)' == 'true' and '$(HostOS)' != 'windows'">$(ROOTFS_DIR)</SysRoot> | ||
| <BuildNativeAotFrameworkObjects Condition="'$(IlcMultiModule)' == 'true'">true</BuildNativeAotFrameworkObjects> | ||
| <DisableFrameworkLibGeneration Condition="'$(BuildNativeAotFrameworkObjects)' == 'true'">true</DisableFrameworkLibGeneration> | ||
|
|
@@ -570,4 +569,28 @@ | |
| Condition="'$(_WillCLRTestProjectBuild)' == 'true' and '$(CLRTestKind)' == 'BuildAndRun'" | ||
| DependsOnTargets="ComputeResolvedFilesToPublishList;LinkNative" /> | ||
|
|
||
| <Target Name="LocateNativeCompiler" | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There seems to be a lot of duplication of this logic. Would it be possible to have this logic in a shared file under
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah - I've been meaning to share this and other logic that is already duplicated. There are some subtle differences, so I wanted to see if I could get it working first.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd like to work on the sharing in a follow-up if that sounds ok to you. This fix will unblock some other things I can work on in parallel. |
||
| Condition="'$(TestBuildMode)' == 'nativeaot' and '$(HostOS)' != 'windows'" | ||
| BeforeTargets="SetupOSSpecificProps"> | ||
| <PropertyGroup> | ||
| <CppCompilerAndLinker Condition="'$(CppCompilerAndLinker)' == ''">clang</CppCompilerAndLinker> | ||
| </PropertyGroup> | ||
|
|
||
| <Exec Command="sh -c 'build_arch="$(TargetArchitecture)" compiler="$(CppCompilerAndLinker)" . "$(RepositoryEngineeringDir)/common/native/init-compiler.sh" && echo $CC' 2>/dev/null" | ||
| EchoOff="true" | ||
| ConsoleToMsBuild="true" | ||
| StandardOutputImportance="Low"> | ||
| <Output TaskParameter="ConsoleOutput" PropertyName="CppLinker" /> | ||
| </Exec> | ||
|
|
||
| <Exec Command=""$(CppLinker)" -fuse-ld=lld -Wl,--version" Condition="$(CppCompilerAndLinker.Contains('clang'))" | ||
| IgnoreExitCode="true" IgnoreStandardErrorWarningFormat="true" StandardOutputImportance="Low" StandardErrorImportance="Low" ConsoleToMSBuild="true"> | ||
| <Output TaskParameter="ExitCode" PropertyName="_LLDCheckExitCode" /> | ||
| </Exec> | ||
|
|
||
| <PropertyGroup Condition="'$(_LLDCheckExitCode)' == '0'"> | ||
| <LinkerFlavor>lld</LinkerFlavor> | ||
| </PropertyGroup> | ||
| </Target> | ||
|
|
||
| </Project> | ||
Uh oh!
There was an error while loading. Please reload this page.