All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/pkg-cargo.mk: fix building cargo packages on 32bit arm
@ 2022-02-17 23:06 Moritz Bitsch via buildroot
  2022-03-07 21:23 ` Arnout Vandecappelle
  2022-07-24 16:08 ` Yann E. MORIN
  0 siblings, 2 replies; 4+ messages in thread
From: Moritz Bitsch via buildroot @ 2022-02-17 23:06 UTC (permalink / raw)
  To: buildroot; +Cc: Moritz Bitsch

From: Moritz Bitsch <moritz@h6t.eu>

there are duplicated symbols between rustc and gcc. Specifying
--allow-multiple-definition to the linker as workaround until
rustc is fixed.

rust-lang issue: https://github.com/rust-lang/compiler-builtins/issues/420

Fixes: http://autobuild.buildroot.net/results/53f/53f5598b8e520caaa135fb4923c09da382dab329
Signed-off-by: Moritz Bitsch <moritz@h6t.eu>
---
 package/pkg-cargo.mk | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/package/pkg-cargo.mk b/package/pkg-cargo.mk
index e74a8358bc..71d695d926 100644
--- a/package/pkg-cargo.mk
+++ b/package/pkg-cargo.mk
@@ -46,6 +46,14 @@ PKG_CARGO_ENV = \
 	CARGO_BUILD_TARGET="$(RUSTC_TARGET_NAME)" \
 	CARGO_TARGET_$(call UPPERCASE,$(RUSTC_TARGET_NAME))_LINKER=$(notdir $(TARGET_CROSS))gcc
 
+#
+# This is a workaround for https://github.com/rust-lang/compiler-builtins/issues/420
+# and should be removed when fixed upstream
+#
+ifeq ($(NORMALIZED_ARCH),arm)
+	PKG_CARGO_ENV += RUSTFLAGS="-Clink-arg=-Wl,--allow-multiple-definition"
+endif
+
 HOST_PKG_CARGO_ENV = \
 	$(PKG_COMMON_CARGO_ENV)
 
-- 
2.35.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/pkg-cargo.mk: fix building cargo packages on 32bit arm
  2022-02-17 23:06 [Buildroot] [PATCH 1/1] package/pkg-cargo.mk: fix building cargo packages on 32bit arm Moritz Bitsch via buildroot
@ 2022-03-07 21:23 ` Arnout Vandecappelle
  2022-07-24 16:08 ` Yann E. MORIN
  1 sibling, 0 replies; 4+ messages in thread
From: Arnout Vandecappelle @ 2022-03-07 21:23 UTC (permalink / raw)
  To: moritz, buildroot



On 18/02/2022 00:06, Moritz Bitsch via buildroot wrote:
> From: Moritz Bitsch <moritz@h6t.eu>
> 
> there are duplicated symbols between rustc and gcc. Specifying
> --allow-multiple-definition to the linker as workaround until
> rustc is fixed.
> 
> rust-lang issue: https://github.com/rust-lang/compiler-builtins/issues/420
> 
> Fixes: http://autobuild.buildroot.net/results/53f/53f5598b8e520caaa135fb4923c09da382dab329
> Signed-off-by: Moritz Bitsch <moritz@h6t.eu>

  Applied to master, thanks.

  Regards,
  Arnout

> ---
>   package/pkg-cargo.mk | 8 ++++++++
>   1 file changed, 8 insertions(+)
> 
> diff --git a/package/pkg-cargo.mk b/package/pkg-cargo.mk
> index e74a8358bc..71d695d926 100644
> --- a/package/pkg-cargo.mk
> +++ b/package/pkg-cargo.mk
> @@ -46,6 +46,14 @@ PKG_CARGO_ENV = \
>   	CARGO_BUILD_TARGET="$(RUSTC_TARGET_NAME)" \
>   	CARGO_TARGET_$(call UPPERCASE,$(RUSTC_TARGET_NAME))_LINKER=$(notdir $(TARGET_CROSS))gcc
>   
> +#
> +# This is a workaround for https://github.com/rust-lang/compiler-builtins/issues/420
> +# and should be removed when fixed upstream
> +#
> +ifeq ($(NORMALIZED_ARCH),arm)
> +	PKG_CARGO_ENV += RUSTFLAGS="-Clink-arg=-Wl,--allow-multiple-definition"
> +endif
> +
>   HOST_PKG_CARGO_ENV = \
>   	$(PKG_COMMON_CARGO_ENV)
>   
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/pkg-cargo.mk: fix building cargo packages on 32bit arm
  2022-02-17 23:06 [Buildroot] [PATCH 1/1] package/pkg-cargo.mk: fix building cargo packages on 32bit arm Moritz Bitsch via buildroot
  2022-03-07 21:23 ` Arnout Vandecappelle
@ 2022-07-24 16:08 ` Yann E. MORIN
  2022-07-25  9:20   ` Moritz Bitsch via buildroot
  1 sibling, 1 reply; 4+ messages in thread
From: Yann E. MORIN @ 2022-07-24 16:08 UTC (permalink / raw)
  To: moritz; +Cc: buildroot

Moritz, All,

On 2022-02-18 00:06 +0100, Moritz Bitsch via buildroot spake thusly:
> From: Moritz Bitsch <moritz@h6t.eu>
> 
> there are duplicated symbols between rustc and gcc. Specifying
> --allow-multiple-definition to the linker as workaround until
> rustc is fixed.
> 
> rust-lang issue: https://github.com/rust-lang/compiler-builtins/issues/420

This is supposedly fixed upstream:
    https://github.com/rust-lang/compiler-builtins/issues/420

which leads to:
    https://github.com/rust-lang/compiler-builtins/issues/412

which leads to:
    https://github.com/rust-lang/compiler-builtins/pull/452

and:
    https://github.com/rust-lang/rust/pull/93696

which is now merged.

We recently bumped to using rust 1.62.0.

Do you think that this workaround can now be dropped?

Regards,
Yann E. MORIN.

> Fixes: http://autobuild.buildroot.net/results/53f/53f5598b8e520caaa135fb4923c09da382dab329
> Signed-off-by: Moritz Bitsch <moritz@h6t.eu>
> ---
>  package/pkg-cargo.mk | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/package/pkg-cargo.mk b/package/pkg-cargo.mk
> index e74a8358bc..71d695d926 100644
> --- a/package/pkg-cargo.mk
> +++ b/package/pkg-cargo.mk
> @@ -46,6 +46,14 @@ PKG_CARGO_ENV = \
>  	CARGO_BUILD_TARGET="$(RUSTC_TARGET_NAME)" \
>  	CARGO_TARGET_$(call UPPERCASE,$(RUSTC_TARGET_NAME))_LINKER=$(notdir $(TARGET_CROSS))gcc
>  
> +#
> +# This is a workaround for https://github.com/rust-lang/compiler-builtins/issues/420
> +# and should be removed when fixed upstream
> +#
> +ifeq ($(NORMALIZED_ARCH),arm)
> +	PKG_CARGO_ENV += RUSTFLAGS="-Clink-arg=-Wl,--allow-multiple-definition"
> +endif
> +
>  HOST_PKG_CARGO_ENV = \
>  	$(PKG_COMMON_CARGO_ENV)
>  
> -- 
> 2.35.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/pkg-cargo.mk: fix building cargo packages on 32bit arm
  2022-07-24 16:08 ` Yann E. MORIN
@ 2022-07-25  9:20   ` Moritz Bitsch via buildroot
  0 siblings, 0 replies; 4+ messages in thread
From: Moritz Bitsch via buildroot @ 2022-07-25  9:20 UTC (permalink / raw)
  To: Yann E. MORIN; +Cc: buildroot

Hello Yann, All,


it seems that the original autobuild error still requires the workaround 
with rust 1.62.0. I think we should keep the workaround in place.

If I get some time Ill have a look at what is going on, as the mentioned 
github issues are fixed.


Regards,

Moritz Bitsch

Am 24.07.22 um 18:08 schrieb Yann E. MORIN:
> Moritz, All,
>
> On 2022-02-18 00:06 +0100, Moritz Bitsch via buildroot spake thusly:
>> From: Moritz Bitsch <moritz@h6t.eu>
>>
>> there are duplicated symbols between rustc and gcc. Specifying
>> --allow-multiple-definition to the linker as workaround until
>> rustc is fixed.
>>
>> rust-lang issue: https://github.com/rust-lang/compiler-builtins/issues/420
> This is supposedly fixed upstream:
>      https://github.com/rust-lang/compiler-builtins/issues/420
>
> which leads to:
>      https://github.com/rust-lang/compiler-builtins/issues/412
>
> which leads to:
>      https://github.com/rust-lang/compiler-builtins/pull/452
>
> and:
>      https://github.com/rust-lang/rust/pull/93696
>
> which is now merged.
>
> We recently bumped to using rust 1.62.0.
>
> Do you think that this workaround can now be dropped?
>
> Regards,
> Yann E. MORIN.
>
>> Fixes: http://autobuild.buildroot.net/results/53f/53f5598b8e520caaa135fb4923c09da382dab329
>> Signed-off-by: Moritz Bitsch <moritz@h6t.eu>
>> ---
>>   package/pkg-cargo.mk | 8 ++++++++
>>   1 file changed, 8 insertions(+)
>>
>> diff --git a/package/pkg-cargo.mk b/package/pkg-cargo.mk
>> index e74a8358bc..71d695d926 100644
>> --- a/package/pkg-cargo.mk
>> +++ b/package/pkg-cargo.mk
>> @@ -46,6 +46,14 @@ PKG_CARGO_ENV = \
>>   	CARGO_BUILD_TARGET="$(RUSTC_TARGET_NAME)" \
>>   	CARGO_TARGET_$(call UPPERCASE,$(RUSTC_TARGET_NAME))_LINKER=$(notdir $(TARGET_CROSS))gcc
>>   
>> +#
>> +# This is a workaround for https://github.com/rust-lang/compiler-builtins/issues/420
>> +# and should be removed when fixed upstream
>> +#
>> +ifeq ($(NORMALIZED_ARCH),arm)
>> +	PKG_CARGO_ENV += RUSTFLAGS="-Clink-arg=-Wl,--allow-multiple-definition"
>> +endif
>> +
>>   HOST_PKG_CARGO_ENV = \
>>   	$(PKG_COMMON_CARGO_ENV)
>>   
>> -- 
>> 2.35.1
>>
>> _______________________________________________
>> buildroot mailing list
>> buildroot@buildroot.org
>> https://lists.buildroot.org/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-07-25  9:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-17 23:06 [Buildroot] [PATCH 1/1] package/pkg-cargo.mk: fix building cargo packages on 32bit arm Moritz Bitsch via buildroot
2022-03-07 21:23 ` Arnout Vandecappelle
2022-07-24 16:08 ` Yann E. MORIN
2022-07-25  9:20   ` Moritz Bitsch via buildroot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.