-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Use GNU ld on m68k-unknown-linux-gnu #132950
Conversation
These commits modify compiler targets. |
@knickish Can you, in the platform support page, update m68k with the asterisk that says it supports no_std, right now? |
It currently is a question mark, which basically says "lol we're pretty sure this doesn't work", and with this it seems you've finally made it to |
@workingjubilee Building core depends on llvm patches that aren't all backported or merged yet, does that change how you'd like that documentation updated at all? |
Ooh good point, I forgot about that. Hmm... we'll revisit this next PR. :3 @bors r+ rollup |
@@ -12,11 +12,18 @@ pub(crate) fn target() -> Target { | |||
description: Some("Motorola 680x0 Linux".into()), | |||
tier: Some(3), | |||
host_tools: Some(false), | |||
std: None, // ? | |||
std: Some(false), // std cannot be linked for now |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should be a separate commit as it's an unrelated change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done, just removed it for now
mcount: "_mcount".into(), | ||
|
||
// LLD currently does not have support for M68k | ||
linker: Some("m68k-linux-gnu-ld".into()), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Something like link_self_contained: LinkSelfContainedDefault::False
instead may work too. This will also ensure that attempting to enable self-contained linking using lld on the cli gives an error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@knickish Can you try this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup, doing a build right now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This worked, core
and everything besides std
built and linked; the std
link failed with the exact same error as with linker: Some("m68k-linux-gnu-ld".into())
. PR is updated and uses link_self_contained: LinkSelfContainedDefault::False
@bors r- |
f2617ae
to
b6fd461
Compare
Also, the title should be "Use GNU ld on m68k-unknown-linux-gnu" as this just applies to m68k on Linux. |
we don't have any other m68k targets tho' |
b6fd461
to
d3768ea
Compare
On Nov 12, 2024, at 8:31 PM, Jubilee ***@***.***> wrote:
we don't have any other m68k targets tho'
We could easily add m68k-unknown-elf for embedded systems and I am certainly planning that for the future as it’s useful for video game consoles such as the Sega Megadrive.
|
Ah, sure then! @bors r+ rollup |
…iaskrgr Rollup of 7 pull requests Successful merges: - rust-lang#132702 (CFI: Append debug location to CFI blocks) - rust-lang#132851 (Update the doc comment of `ASCII_CASE_MASK`) - rust-lang#132948 (stabilize const_unicode_case_lookup) - rust-lang#132950 (Use GNU ld on m68k-unknown-linux-gnu) - rust-lang#132962 (triagebot: add codegen reviewers) - rust-lang#132966 (stabilize const_option_ext) - rust-lang#132970 (Add tracking issue number to unsigned_nonzero_div_ceil feature) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#132950 - knickish:m68k_gnu_ld, r=workingjubilee Use GNU ld on m68k-unknown-linux-gnu LLD does not really support the M68k architecture yet, specify `m68k-linux-gnu-ld` as the linker for the platform
LLD does not really support the M68k architecture yet, specify
m68k-linux-gnu-ld
as the linker for the platform