Skip to contentSkip to conversation

rust-target-config: Add has-thread-local option

PATCH In review Per x Johansson 3 participants 3 messages Aug 25, 2025 – Sep 1, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rust-target-config: Add has-thread-local option

The "has-elf-tls" option was removed by the commit 8e1614a906086fb46c5dd7b7f2dffab91194165c. However is should have been renamed to "has-thread-local", since it was renamed and not removed in rust by this commit.
https://github.com/rust-lang/rust/commit/391332c5d9d5a5e97a0d36e011a87ad43045cfd3

Change-Id Ia1fdf7698ebeef62a88052713645d5b499164353
---
 meta/classes-recipe/rust-target-config.bbclass | 1 +
 1 file changed, 1 insertion(+)
meta/classes-recipe/rust-target-config.bbclass +1 -0
index cac6e90a9e..0df6f0904c 100644
@@ -418,6 +418,7 @@ def rust_gen_target(d, thing, wd, arch):
     tspec['linker-is-gnu'] = True
     tspec['linker-flavor'] = "gcc"
     tspec['has-rpath'] = True
+    tspec['has-thread-local'] = True
     tspec['position-independent-executables'] = True
     tspec['panic-strategy'] = d.getVar("RUST_PANIC_STRATEGY")
 
Signature · 1 line
2.39.5
#1 lore raw

Cc Steve for backport to stable releases?

The introducing commit goes back to langdale so backporting to scarthgap and walnascar would make sense to me? @Per x Johansson/@Steve, what do you think?

Cheers,
Quentin

Quoted 39 lines · Per x Johansson via lists.openembedded.org

[You don't often get email from [email protected]. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]

The "has-elf-tls" option was removed by the commit 8e1614a906086fb46c5dd7b7f2dffab91194165c. However is should have been renamed to "has-thread-local", since it was renamed and not removed in rust by this commit.
https://github.com/rust-lang/rust/commit/391332c5d9d5a5e97a0d36e011a87ad43045cfd3

Change-Id Ia1fdf7698ebeef62a88052713645d5b499164353
---
  meta/classes-recipe/rust-target-config.bbclass | 1 +
  1 file changed, 1 insertion(+)
meta/classes-recipe/rust-target-config.bbclass +1 -1
index cac6e90a9e..0df6f0904c 100644
@@ -418,6 +418,7 @@ def rust_gen_target(d, thing, wd, arch):
      tspec['linker-is-gnu'] = True
      tspec['linker-flavor'] = "gcc"
      tspec['has-rpath'] = True
+    tspec['has-thread-local'] = True
      tspec['position-independent-executables'] = True
      tspec['panic-strategy'] = d.getVar("RUST_PANIC_STRATEGY")
 
--

2.39.5

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#222407): https://lists.openembedded.org/g/openembedded-core/message/222407
Mute This Topic: https://lists.openembedded.org/mt/114881321/6293953
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

#2 lore raw

This started to cause trouble for us after the upgrade to walnascar with Rust 1.84.1 which included this commit https://github.com/rust-lang/rust/commit/d868fdce6b9ddef6abcc8de86b3ba8459def36a2. So I think that it should atlest go into walnascar.

/Per
________________________________
From: Quentin Schulz <[email protected]>
Sent: Monday, September 1, 2025 11:59
To: Per x Johansson <[email protected]>; [email protected] <[email protected]>
Cc: Steve Sakoman <[email protected]>
Subject: Re: [OE-core] [PATCH] rust-target-config: Add has-thread-local option

[You don't often get email from [email protected]. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]

Cc Steve for backport to stable releases?

The introducing commit goes back to langdale so backporting to scarthgap and walnascar would make sense to me? @Per x Johansson/@Steve, what do you think?

Cheers,
Quentin

Quoted 33 lines · Per x Johansson via lists.openembedded.org

[You don't often get email from [email protected]. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]

The "has-elf-tls" option was removed by the commit 8e1614a906086fb46c5dd7b7f2dffab91194165c. However is should have been renamed to "has-thread-local", since it was renamed and not removed in rust by this commit.
https://github.com/rust-lang/rust/commit/391332c5d9d5a5e97a0d36e011a87ad43045cfd3

Change-Id Ia1fdf7698ebeef62a88052713645d5b499164353
---
  meta/classes-recipe/rust-target-config.bbclass | 1 +
  1 file changed, 1 insertion(+)
meta/classes-recipe/rust-target-config.bbclass +1 -1
index cac6e90a9e..0df6f0904c 100644
@@ -418,6 +418,7 @@ def rust_gen_target(d, thing, wd, arch):
      tspec['linker-is-gnu'] = True
      tspec['linker-flavor'] = "gcc"
      tspec['has-rpath'] = True
+    tspec['has-thread-local'] = True
      tspec['position-independent-executables'] = True
      tspec['panic-strategy'] = d.getVar("RUST_PANIC_STRATEGY")
 
--

2.39.5