Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] micropython: update to 1.14
@ 2021-02-12 18:25 lfdebrux
  2021-02-12 19:00 ` [PR REVIEW] " ericonr
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: lfdebrux @ 2021-02-12 18:25 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1620 bytes --]

There is a new pull request by lfdebrux against master on the void-packages repository

https://github.com/lfdebrux/void-packages ldeb-bump-micropython
https://github.com/void-linux/void-packages/pull/28708

micropython: update to 1.14
<!-- Mark items with [x] where applicable -->

#### General
- [ ] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [x] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [ ] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
-->

#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (x86_64-musl)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [ ] aarch64-musl
  - [ ] armv7l
  - [ ] armv6l-musl
  - [x] armv5tel-musl


A patch file from https://github.com/void-linux/void-packages/pull/28708.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ldeb-bump-micropython-28708.patch --]
[-- Type: text/x-diff, Size: 2408 bytes --]

From 714cdd56c23750cccea4e975aa73b88e182b5828 Mon Sep 17 00:00:00 2001
From: Laurence de Bruxelles <lfdebrux@gmail.com>
Date: Tue, 9 Feb 2021 20:43:54 +0000
Subject: [PATCH 1/2] micropython: use nopie on armv5tel-musl.

On armv5tel-musl micropython crashes with a SEGV in musl's
do_relocs() function. Disabling PIE fixes this.
---
 srcpkgs/micropython/template | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/srcpkgs/micropython/template b/srcpkgs/micropython/template
index 5c88d5e399f..ffb96cf7dc6 100644
--- a/srcpkgs/micropython/template
+++ b/srcpkgs/micropython/template
@@ -1,7 +1,7 @@
 # Template file for 'micropython'
 pkgname=micropython
 version=1.13
-revision=1
+revision=2
 build_wrksrc=ports/unix
 hostmakedepends="pkg-config python3"
 makedepends="libffi-devel"
@@ -13,6 +13,7 @@ distfiles="https://github.com/micropython/micropython/releases/download/v${versi
 checksum=9ab32eb2c19a682f6de7e9b4226de849c42cb92e1ecb4cf56438a75d763bd451
 
 case "$XBPS_TARGET_MACHINE" in
+	armv5tel-musl) nopie=yes ;;
 	ppc*) broken="missing nlr_push" ;;
 esac
 

From e755c66ec3329ea7608d24e3dd68b3aeff7e2864 Mon Sep 17 00:00:00 2001
From: Laurence de Bruxelles <lfdebrux@gmail.com>
Date: Tue, 9 Feb 2021 20:54:33 +0000
Subject: [PATCH 2/2] micropython: update to 1.14.

---
 srcpkgs/micropython/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/micropython/template b/srcpkgs/micropython/template
index ffb96cf7dc6..b82df228d7b 100644
--- a/srcpkgs/micropython/template
+++ b/srcpkgs/micropython/template
@@ -1,7 +1,7 @@
 # Template file for 'micropython'
 pkgname=micropython
-version=1.13
-revision=2
+version=1.14
+revision=1
 build_wrksrc=ports/unix
 hostmakedepends="pkg-config python3"
 makedepends="libffi-devel"
@@ -9,8 +9,8 @@ short_desc="Implementation of Python 3.x for microcontrollers"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="MIT"
 homepage="https://micropython.org/"
-distfiles="https://github.com/micropython/micropython/releases/download/v${version}/micropython-${version}.tar.gz"
-checksum=9ab32eb2c19a682f6de7e9b4226de849c42cb92e1ecb4cf56438a75d763bd451
+distfiles="https://github.com/micropython/micropython/releases/download/v${version}/micropython-${version}.tar.xz"
+checksum=97306156fdeab120a1244626c75a929bb820722afdfc1317dbd5dadef388d94c
 
 case "$XBPS_TARGET_MACHINE" in
 	armv5tel-musl) nopie=yes ;;

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

* Re: [PR REVIEW] micropython: update to 1.14
  2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
@ 2021-02-12 19:00 ` ericonr
  2021-02-13 15:01 ` [PR PATCH] [Updated] " lfdebrux
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: ericonr @ 2021-02-12 19:00 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 271 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/28708#discussion_r575458141

Comment:
This might (almost definitely) be a bug you want to report to musl folks. Can you show a stack trace / disassembly output?


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

* Re: [PR PATCH] [Updated] micropython: update to 1.14
  2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
  2021-02-12 19:00 ` [PR REVIEW] " ericonr
@ 2021-02-13 15:01 ` lfdebrux
  2021-02-13 16:17 ` [PR REVIEW] " ericonr
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: lfdebrux @ 2021-02-13 15:01 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1625 bytes --]

There is an updated pull request by lfdebrux against master on the void-packages repository

https://github.com/lfdebrux/void-packages ldeb-bump-micropython
https://github.com/void-linux/void-packages/pull/28708

micropython: update to 1.14
<!-- Mark items with [x] where applicable -->

#### General
- [ ] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [x] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [ ] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
-->

#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (x86_64-musl)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [ ] aarch64-musl
  - [ ] armv7l
  - [ ] armv6l-musl
  - [x] armv5tel-musl


A patch file from https://github.com/void-linux/void-packages/pull/28708.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ldeb-bump-micropython-28708.patch --]
[-- Type: text/x-diff, Size: 1475 bytes --]

From 466bd90240e82e98ec67590b0f5f2d11c9d4a651 Mon Sep 17 00:00:00 2001
From: Laurence de Bruxelles <lfdebrux@gmail.com>
Date: Tue, 9 Feb 2021 20:43:54 +0000
Subject: [PATCH] micropython: update to 1.14.

Additionally, use nopie on armv5tel-musl: On armv5tel-musl micropython
crashes with a SEGV in musl's do_relocs() function. Disabling PIE fixes
this.
---
 srcpkgs/micropython/template | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/micropython/template b/srcpkgs/micropython/template
index 5c88d5e399f..b82df228d7b 100644
--- a/srcpkgs/micropython/template
+++ b/srcpkgs/micropython/template
@@ -1,6 +1,6 @@
 # Template file for 'micropython'
 pkgname=micropython
-version=1.13
+version=1.14
 revision=1
 build_wrksrc=ports/unix
 hostmakedepends="pkg-config python3"
@@ -9,10 +9,11 @@ short_desc="Implementation of Python 3.x for microcontrollers"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="MIT"
 homepage="https://micropython.org/"
-distfiles="https://github.com/micropython/micropython/releases/download/v${version}/micropython-${version}.tar.gz"
-checksum=9ab32eb2c19a682f6de7e9b4226de849c42cb92e1ecb4cf56438a75d763bd451
+distfiles="https://github.com/micropython/micropython/releases/download/v${version}/micropython-${version}.tar.xz"
+checksum=97306156fdeab120a1244626c75a929bb820722afdfc1317dbd5dadef388d94c
 
 case "$XBPS_TARGET_MACHINE" in
+	armv5tel-musl) nopie=yes ;;
 	ppc*) broken="missing nlr_push" ;;
 esac
 

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

* Re: [PR REVIEW] micropython: update to 1.14
  2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
  2021-02-12 19:00 ` [PR REVIEW] " ericonr
  2021-02-13 15:01 ` [PR PATCH] [Updated] " lfdebrux
@ 2021-02-13 16:17 ` ericonr
  2021-02-13 16:46 ` lfdebrux
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: ericonr @ 2021-02-13 16:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 558 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/28708#discussion_r575683811

Comment:
@lfdebrux can you check if their build system doesn't simply disable PIC? By passing `-fno-PIC` to the compiler, for example. If that's the case, what can happen is that it interacts badly with our PIE by default toolchain, and creates a text relocation in the binary. Musl doesn't support those at all.

You can check for their presence with `readelf -d <binary>` and seeing if TEXTREL appears in the output.

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

* Re: [PR REVIEW] micropython: update to 1.14
  2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
                   ` (2 preceding siblings ...)
  2021-02-13 16:17 ` [PR REVIEW] " ericonr
@ 2021-02-13 16:46 ` lfdebrux
  2021-02-14  3:56 ` ericonr
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: lfdebrux @ 2021-02-13 16:46 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 971 bytes --]

New review comment by lfdebrux on void-packages repository

https://github.com/void-linux/void-packages/pull/28708#discussion_r575686867

Comment:
It doesn't look like they disable PIC; what's weird is that it works fine on x86_64-musl with PIE, but doesn't on armv5tel-musl, which as you say does point towards it being a bug in musl.

Here's a stacktrace from gdb

```
(gdb) start
Temporary breakpoint 1 at 0x90f0: file main.c, line 421.
Starting program: /usr/bin/micropython

Program received signal SIGSEGV, Segmentation fault.
0xb6fb68c0 in do_relocs () from /lib/ld-musl-arm.so.1
(gdb) backtrace
#0  0xb6fb68c0 in do_relocs () from /lib/ld-musl-arm.so.1
#1  0xb6fb6c88 in reloc_all () from /lib/ld-musl-arm.so.1
#2  0xb6fb900c in __dls3 () from /lib/ld-musl-arm.so.1
#3  0xb6fb867c in __dls2 () from /lib/ld-musl-arm.so.1
#4  0xb6fb569c in _dlstart () from /lib/ld-musl-arm.so.1
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
(gdb)
```

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

* Re: [PR REVIEW] micropython: update to 1.14
  2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
                   ` (3 preceding siblings ...)
  2021-02-13 16:46 ` lfdebrux
@ 2021-02-14  3:56 ` ericonr
  2021-02-14 16:12 ` ericonr
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: ericonr @ 2021-02-14  3:56 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 258 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/28708#discussion_r575748724

Comment:
Seems it also segfaults on armv6l :P 

I will try to determine which platforms we have to enable `nopie` for.

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

* Re: [PR REVIEW] micropython: update to 1.14
  2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
                   ` (4 preceding siblings ...)
  2021-02-14  3:56 ` ericonr
@ 2021-02-14 16:12 ` ericonr
  2021-02-14 16:26 ` lfdebrux
  2021-02-14 19:01 ` [PR PATCH] [Closed]: " ericonr
  7 siblings, 0 replies; 9+ messages in thread
From: ericonr @ 2021-02-14 16:12 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 577 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/28708#discussion_r575829876

Comment:
> 0x00000016 (TEXTREL)                    0x0

As suspected :) So not really a bug on musl's side, though it would be nice if an error message were added.

This might be due to their assembly code somewhere, though I couldn't find it. Weirdly, Alpine disables `armv7l` as a target because tests don't pass, and even `armhf` (which is equivalent to our armv6l) because it doesn't build (it might simply be outdated, of course).

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

* Re: [PR REVIEW] micropython: update to 1.14
  2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
                   ` (5 preceding siblings ...)
  2021-02-14 16:12 ` ericonr
@ 2021-02-14 16:26 ` lfdebrux
  2021-02-14 19:01 ` [PR PATCH] [Closed]: " ericonr
  7 siblings, 0 replies; 9+ messages in thread
From: lfdebrux @ 2021-02-14 16:26 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 251 bytes --]

New review comment by lfdebrux on void-packages repository

https://github.com/void-linux/void-packages/pull/28708#discussion_r575831617

Comment:
Oh interesting. With `nopie` that isn't present. Sorry I can't be more helpful, I'm a bit out my depth!

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

* Re: [PR PATCH] [Closed]: micropython: update to 1.14
  2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
                   ` (6 preceding siblings ...)
  2021-02-14 16:26 ` lfdebrux
@ 2021-02-14 19:01 ` ericonr
  7 siblings, 0 replies; 9+ messages in thread
From: ericonr @ 2021-02-14 19:01 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1453 bytes --]

There's a closed pull request on the void-packages repository

micropython: update to 1.14
https://github.com/void-linux/void-packages/pull/28708

Description:
<!-- Mark items with [x] where applicable -->

#### General
- [ ] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [x] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [ ] I generally don't use the affected packages but briefly tested this PR

<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
-->

#### Does it build and run successfully? 
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [x] I built this PR locally for my native architecture, (x86_64-musl)
- [x] I built this PR locally for these architectures (if supported. mark crossbuilds):
  - [ ] aarch64-musl
  - [ ] armv7l
  - [ ] armv6l-musl
  - [x] armv5tel-musl


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

end of thread, other threads:[~2021-02-14 19:01 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-12 18:25 [PR PATCH] micropython: update to 1.14 lfdebrux
2021-02-12 19:00 ` [PR REVIEW] " ericonr
2021-02-13 15:01 ` [PR PATCH] [Updated] " lfdebrux
2021-02-13 16:17 ` [PR REVIEW] " ericonr
2021-02-13 16:46 ` lfdebrux
2021-02-14  3:56 ` ericonr
2021-02-14 16:12 ` ericonr
2021-02-14 16:26 ` lfdebrux
2021-02-14 19:01 ` [PR PATCH] [Closed]: " ericonr

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).