python3: fix build for powerpc-linux.musl and powerpc64-linux-musl
PATCH 1/1 python3: fix build for powerpc-linux.musl and powerpc64-linux-musl
Add the missing triplets (not considering uclibc) for do_configure.
--- .../python3/powerpc-musl-triplets.patch | 43 +++++++++++++++++++ meta/recipes-devtools/python/python3_3.5.6.bb | 1 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-devtools/python/python3/powerpc-musl-triplets.patch
meta/recipes-devtools/python/python3/powerpc-musl-triplets.patch new file +43 -0
@@ -0,0 +1,43 @@ +Using musl libc the task do_configure fails on powerpc*. + + checking build system type... x86_64-pc-linux-gnu + checking host system type... powerpc-oe-linux-musl + checking for python3.5... python3.5 + ... + checking for the platform triplet based on compiler characteristics... + powerpc-linux-gnu + configure: error: internal configure error for the platform triplet + +Fix this by adding the musl triplets. +Note: uclibc is purposedly not considered (unsupported in oe-core). + +Upstream-Status: Pending +Signed-off-by: Andrea Adami <[email protected]> + +--- a/configure.ac 2018-12-13 14:44:55.414309610 +0100 ++++ b/configure.ac 2018-12-13 13:22:37.546497547 +0100 +@@ -831,14 +831,22 @@ + or1k-linux-gnu + # elif defined(__powerpc__) && defined(__SPE__) + powerpc-linux-gnuspe ++# elif defined(__powerpc__) && !defined(__GLIBC__) ++ powerpc-linux-musl ++# elif defined(__powerpc__) ++ powerpc-linux-gnu ++# elif defined(__powerpc64__) && !defined(__GLIBC__) ++# if defined(__LITTLE_ENDIAN__) ++ powerpc64le-linux-musl ++# else ++ powerpc64-linux-musl ++# endif + # elif defined(__powerpc64__) + # if defined(__LITTLE_ENDIAN__) + powerpc64le-linux-gnu + # else + powerpc64-linux-gnu + # endif +-# elif defined(__powerpc__) +- powerpc-linux-gnu + # elif defined(__s390x__) + s390x-linux-gnu + # elif defined(__s390__)
meta/recipes-devtools/python/python3_3.5.6.bb +1 -0
@@ -44,6 +44,7 @@ SRC_URI += "\ file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch \ file://run-ptest \ " +SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch" inherit multilib_header python3native update-alternatives qemu ptest
Signature · 1 line
2.17.1
Quoted 1 line · Andrea Adami
+SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch"
Whilst this is musl specific it doesn't break glibc, so apply it universally.
Also seems that assuming !glibc == musl isn't safe, is there a better define?
Ross
Also, why does this appear to be powerpc-specific?
Ross
Quoted 9 lines · Ross
Quoted 1 line · Andrea Adami
+SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch"
Whilst this is musl specific it doesn't break glibc, so apply it universally.
Also seems that assuming !glibc == musl isn't safe, is there a better define?
Ross
Quoted 71 lines · Andrea Adami
Add the missing triplets (not considering uclibc) for
do_configure.Signed-off-by Andrea Adami <[email protected]>--- .../python3/powerpc-musl-triplets.patch | 43 +++++++++++++++++++ meta/recipes-devtools/python/python3_3.5.6.bb | 1 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-devtools/python/python3/powerpc-musl-triplets.patch
(quoted diff) +0
-0triplets.patch b/meta/recipes-devtools/python/python3/powerpc-musl- triplets.patch
new file mode 100644
index 0000000000..477d049858meta/recipes-devtools/python/python3/powerpc-musl- new file +0
-0triplets.patch
meta/recipes-devtools/python/python3/powerpc-musl- new file +7
-0@@ -0,0 +1,43 @@ +Using musl libc the task do_configure fails on powerpc*. + + checking build system type... x86_64-pc-linux-gnu + checking host system type... powerpc-oe-linux-musl + checking for python3.5... python3.5 + ... + checking for the platform triplet based on compilercharacteristics...
meta/recipes-devtools/python/python3/powerpc-musl- new file +2
-0+ powerpc-linux-gnu + configure: error: internal configure error for the platformtriplet
meta/recipes-devtools/python/python3/powerpc-musl- new file +34
-0+ +Fix this by adding the musl triplets. +Note: uclibc is purposedly not considered (unsupported in oe-core). + +Upstream-Status: Pending +Signed-off-by: Andrea Adami <[email protected]> + +--- a/configure.ac 2018-12-13 14:44:55.414309610 +0100 ++++ b/configure.ac 2018-12-13 13:22:37.546497547 +0100 +@@ -831,14 +831,22 @@ + or1k-linux-gnu + # elif defined(__powerpc__) && defined(__SPE__) + powerpc-linux-gnuspe ++# elif defined(__powerpc__) && !defined(__GLIBC__) ++ powerpc-linux-musl ++# elif defined(__powerpc__) ++ powerpc-linux-gnu ++# elif defined(__powerpc64__) && !defined(__GLIBC__) ++# if defined(__LITTLE_ENDIAN__) ++ powerpc64le-linux-musl ++# else ++ powerpc64-linux-musl ++# endif + # elif defined(__powerpc64__) + # if defined(__LITTLE_ENDIAN__) + powerpc64le-linux-gnu + # else + powerpc64-linux-gnu + # endif +-# elif defined(__powerpc__) +- powerpc-linux-gnu + # elif defined(__s390x__) + s390x-linux-gnu + # elif defined(__s390__)meta/recipes-devtools/python/python3_3.5.6.bb +0
-0
meta/recipes-devtools/python/python3_3.5.6.bb SRC_URI += "\ · line 50
Quoted 7 lines
meta/recipes-devtools/python/python3_3.5.6.bb +1
-0@@ -44,6 +44,7 @@ SRC_URI += "\ file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f- 2305.patch \ file://run-ptest \ " +SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch" inherit multilib_header python3native update-alternatives qemu ptest
Do we need to make the patch application musl only? This tends to make it more painful for recipe upgrading and we should only do that if the patch would have an adverse affect on non-musl. Would also be good to get tweaks like this submitted upstream...
Cheers,
Richard
Quoted 86 lines · Richard Purdie
Quoted 71 lines · Andrea Adami
Add the missing triplets (not considering uclibc) for
do_configure.Signed-off-by Andrea Adami <[email protected]>--- .../python3/powerpc-musl-triplets.patch | 43 +++++++++++++++++++ meta/recipes-devtools/python/python3_3.5.6.bb | 1 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-devtools/python/python3/powerpc-musl-triplets.patch
(quoted diff) +0
-0triplets.patch b/meta/recipes-devtools/python/python3/powerpc-musl- triplets.patch
new file mode 100644
index 0000000000..477d049858meta/recipes-devtools/python/python3/powerpc-musl- new file +0
-0triplets.patch
meta/recipes-devtools/python/python3/powerpc-musl- new file +7
-0@@ -0,0 +1,43 @@ +Using musl libc the task do_configure fails on powerpc*. + + checking build system type... x86_64-pc-linux-gnu + checking host system type... powerpc-oe-linux-musl + checking for python3.5... python3.5 + ... + checking for the platform triplet based on compilercharacteristics...
meta/recipes-devtools/python/python3/powerpc-musl- new file +2
-0+ powerpc-linux-gnu + configure: error: internal configure error for the platformtriplet
meta/recipes-devtools/python/python3/powerpc-musl- new file +34
-0+ +Fix this by adding the musl triplets. +Note: uclibc is purposedly not considered (unsupported in oe-core). + +Upstream-Status: Pending +Signed-off-by: Andrea Adami <[email protected]> + +--- a/configure.ac 2018-12-13 14:44:55.414309610 +0100 ++++ b/configure.ac 2018-12-13 13:22:37.546497547 +0100 +@@ -831,14 +831,22 @@ + or1k-linux-gnu + # elif defined(__powerpc__) && defined(__SPE__) + powerpc-linux-gnuspe ++# elif defined(__powerpc__) && !defined(__GLIBC__) ++ powerpc-linux-musl ++# elif defined(__powerpc__) ++ powerpc-linux-gnu ++# elif defined(__powerpc64__) && !defined(__GLIBC__) ++# if defined(__LITTLE_ENDIAN__) ++ powerpc64le-linux-musl ++# else ++ powerpc64-linux-musl ++# endif + # elif defined(__powerpc64__) + # if defined(__LITTLE_ENDIAN__) + powerpc64le-linux-gnu + # else + powerpc64-linux-gnu + # endif +-# elif defined(__powerpc__) +- powerpc-linux-gnu + # elif defined(__s390x__) + s390x-linux-gnu + # elif defined(__s390__)meta/recipes-devtools/python/python3_3.5.6.bb +0
-0meta/recipes-devtools/python/python3_3.5.6.bb SRC_URI += "\ · line 50
Quoted 7 lines
meta/recipes-devtools/python/python3_3.5.6.bb +1
-0@@ -44,6 +44,7 @@ SRC_URI += "\ file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f- 2305.patch \ file://run-ptest \ " +SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch" inherit multilib_header python3native update-alternatives qemu ptestDo we need to make the patch application musl only? This tends to make it more painful for recipe upgrading and we should only do that if the patch would have an adverse affect on non-musl. Would also be good to get tweaks like this submitted upstream...
Quoted 4 lines
Cheers,
Richard
If you prefert I add it unconditionally.
This error with musl is not seen for other archs, I could not test the ppc64 but imagined it would suffer as well.
Does your autobuilder succeed?
Cheers
Andrea
Quoted 88 lines · Andrea Adami
Quoted 86 lines · Richard Purdie
Quoted 71 lines · Andrea Adami
Add the missing triplets (not considering uclibc) for
do_configure.Signed-off-by Andrea Adami <[email protected]>--- .../python3/powerpc-musl-triplets.patch | 43 +++++++++++++++++++ meta/recipes-devtools/python/python3_3.5.6.bb | 1 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-devtools/python/python3/powerpc-musl-triplets.patch
(quoted diff) +0
-0triplets.patch b/meta/recipes-devtools/python/python3/powerpc-musl- triplets.patch
new file mode 100644
index 0000000000..477d049858meta/recipes-devtools/python/python3/powerpc-musl- new file +0
-0triplets.patch
meta/recipes-devtools/python/python3/powerpc-musl- new file +7
-0@@ -0,0 +1,43 @@ +Using musl libc the task do_configure fails on powerpc*. + + checking build system type... x86_64-pc-linux-gnu + checking host system type... powerpc-oe-linux-musl + checking for python3.5... python3.5 + ... + checking for the platform triplet based on compilercharacteristics...
meta/recipes-devtools/python/python3/powerpc-musl- new file +2
-0+ powerpc-linux-gnu + configure: error: internal configure error for the platformtriplet
meta/recipes-devtools/python/python3/powerpc-musl- new file +34
-0+ +Fix this by adding the musl triplets. +Note: uclibc is purposedly not considered (unsupported in oe-core). + +Upstream-Status: Pending +Signed-off-by: Andrea Adami <[email protected]> + +--- a/configure.ac 2018-12-13 14:44:55.414309610 +0100 ++++ b/configure.ac 2018-12-13 13:22:37.546497547 +0100 +@@ -831,14 +831,22 @@ + or1k-linux-gnu + # elif defined(__powerpc__) && defined(__SPE__) + powerpc-linux-gnuspe ++# elif defined(__powerpc__) && !defined(__GLIBC__) ++ powerpc-linux-musl ++# elif defined(__powerpc__) ++ powerpc-linux-gnu ++# elif defined(__powerpc64__) && !defined(__GLIBC__) ++# if defined(__LITTLE_ENDIAN__) ++ powerpc64le-linux-musl ++# else ++ powerpc64-linux-musl ++# endif + # elif defined(__powerpc64__) + # if defined(__LITTLE_ENDIAN__) + powerpc64le-linux-gnu + # else + powerpc64-linux-gnu + # endif +-# elif defined(__powerpc__) +- powerpc-linux-gnu + # elif defined(__s390x__) + s390x-linux-gnu + # elif defined(__s390__)meta/recipes-devtools/python/python3_3.5.6.bb +0
-0meta/recipes-devtools/python/python3_3.5.6.bb SRC_URI += "\ · line 50
Quoted 7 lines
meta/recipes-devtools/python/python3_3.5.6.bb +1
-0@@ -44,6 +44,7 @@ SRC_URI += "\ file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f- 2305.patch \ file://run-ptest \ " +SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch" inherit multilib_header python3native update-alternatives qemu ptestDo we need to make the patch application musl only? This tends to make it more painful for recipe upgrading and we should only do that if the patch would have an adverse affect on non-musl. Would also be good to get tweaks like this submitted upstream...
Quoted 8 lines
Quoted 4 lines
Cheers,
Richard
If you prefert I add it unconditionally.
This error with musl is not seen for other archs, I could not test the ppc64 but imagined it would suffer as well.
I have tested on ppc64 fix based on commit cda0ef61d373 ("python3: fix do_configure check platform triplet error") and it works.
BTW on ppc64 we have much more problems with musl. Starting from ELFv2 ABI only support in musl and ending with broken LDSO pathes in final image.
Quoted 6 lines
Does your autobuilder succeed?
Cheers
Andrea
Quoted 64 lines · Andrea Adami
Add the missing triplets (not considering uclibc) for
do_configure.Signed-off-by Andrea Adami <[email protected]>--- .../python3/powerpc-musl-triplets.patch | 43 +++++++++++++++++++ meta/recipes-devtools/python/python3_3.5.6.bb | 1 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-devtools/python/python3/powerpc-musl-triplets.patchmeta/recipes-devtools/python/python3/powerpc-musl-triplets.patch new file +43
-0@@ -0,0 +1,43 @@ +Using musl libc the task do_configure fails on powerpc*. + + checking build system type... x86_64-pc-linux-gnu + checking host system type... powerpc-oe-linux-musl + checking for python3.5... python3.5 + ... + checking for the platform triplet based on compiler characteristics... + powerpc-linux-gnu + configure: error: internal configure error for the platform triplet + +Fix this by adding the musl triplets. +Note: uclibc is purposedly not considered (unsupported in oe-core). + +Upstream-Status: Pending +Signed-off-by: Andrea Adami <[email protected]> + +--- a/configure.ac 2018-12-13 14:44:55.414309610 +0100 ++++ b/configure.ac 2018-12-13 13:22:37.546497547 +0100 +@@ -831,14 +831,22 @@ + or1k-linux-gnu + # elif defined(__powerpc__) && defined(__SPE__) + powerpc-linux-gnuspe ++# elif defined(__powerpc__) && !defined(__GLIBC__) ++ powerpc-linux-musl ++# elif defined(__powerpc__) ++ powerpc-linux-gnu ++# elif defined(__powerpc64__) && !defined(__GLIBC__) ++# if defined(__LITTLE_ENDIAN__) ++ powerpc64le-linux-musl ++# else ++ powerpc64-linux-musl ++# endif + # elif defined(__powerpc64__) + # if defined(__LITTLE_ENDIAN__) + powerpc64le-linux-gnu + # else + powerpc64-linux-gnu + # endif +-# elif defined(__powerpc__) +- powerpc-linux-gnu + # elif defined(__s390x__) + s390x-linux-gnu + # elif defined(__s390__)meta/recipes-devtools/python/python3_3.5.6.bb +0
-0
meta/recipes-devtools/python/python3_3.5.6.bb SRC_URI += "\ · line 50
Quoted 7 lines
meta/recipes-devtools/python/python3_3.5.6.bb +1
-0@@ -44,6 +44,7 @@ SRC_URI += "\ file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch \ file://run-ptest \ " +SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch" inherit multilib_header python3native update-alternatives qemu ptest
Have you looked at approach implemented in commit cda0ef61d373 ("python3: fix do_configure check platform triplet error")?
Maybe we should add same tweak for musl?
Hi Andrea
Sigh, while I dont like what configury is doing here, we can probably instead surgically check for
$CC --print-multiarch on ppc/musl
and then update the tweak-MULTIARCH-for-powerpc-linux-gnuspe.patch patch to consider musl multiarch triplets. Maybe do it for ppc64 while here but I will not hold you accountable for that.
Quoted 79 lines · Andrea Adami
Add the missing triplets (not considering uclibc) for
do_configure.Signed-off-by Andrea Adami <[email protected]>--- .../python3/powerpc-musl-triplets.patch | 43 +++++++++++++++++++ meta/recipes-devtools/python/python3_3.5.6.bb | 1 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-devtools/python/python3/powerpc-musl-triplets.patchmeta/recipes-devtools/python/python3/powerpc-musl-triplets.patch new file +43
-0@@ -0,0 +1,43 @@ +Using musl libc the task do_configure fails on powerpc*. + + checking build system type... x86_64-pc-linux-gnu + checking host system type... powerpc-oe-linux-musl + checking for python3.5... python3.5 + ... + checking for the platform triplet based on compiler characteristics... + powerpc-linux-gnu + configure: error: internal configure error for the platform triplet + +Fix this by adding the musl triplets. +Note: uclibc is purposedly not considered (unsupported in oe-core). + +Upstream-Status: Pending +Signed-off-by: Andrea Adami <[email protected]> + +--- a/configure.ac 2018-12-13 14:44:55.414309610 +0100 ++++ b/configure.ac 2018-12-13 13:22:37.546497547 +0100 +@@ -831,14 +831,22 @@ + or1k-linux-gnu + # elif defined(__powerpc__) && defined(__SPE__) + powerpc-linux-gnuspe ++# elif defined(__powerpc__) && !defined(__GLIBC__) ++ powerpc-linux-musl ++# elif defined(__powerpc__) ++ powerpc-linux-gnu ++# elif defined(__powerpc64__) && !defined(__GLIBC__) ++# if defined(__LITTLE_ENDIAN__) ++ powerpc64le-linux-musl ++# else ++ powerpc64-linux-musl ++# endif + # elif defined(__powerpc64__) + # if defined(__LITTLE_ENDIAN__) + powerpc64le-linux-gnu + # else + powerpc64-linux-gnu + # endif +-# elif defined(__powerpc__) +- powerpc-linux-gnu + # elif defined(__s390x__) + s390x-linux-gnu + # elif defined(__s390__)meta/recipes-devtools/python/python3_3.5.6.bb +1
-1@@ -44,6 +44,7 @@ SRC_URI += "\ file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch \ file://run-ptest \ " +SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch" inherit multilib_header python3native update-alternatives qemu ptest --2.17.1
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
Hi,
the patch is now superseeded.
Serhey sent a new patch-serie containing the fix for powerpc/musl, please review that.
Thanks!
Regards
Andrea
Quoted 91 lines · Khem Raj
Hi Andrea
Sigh, while I dont like what configury is doing here, we can probably instead surgically check for
$CC --print-multiarch on ppc/musl
and then update the tweak-MULTIARCH-for-powerpc-linux-gnuspe.patch patch to consider musl multiarch triplets. Maybe do it for ppc64 while here but I will not hold you accountable for that.
Quoted 79 lines · Andrea Adami
Add the missing triplets (not considering uclibc) for
do_configure.Signed-off-by Andrea Adami <[email protected]>--- .../python3/powerpc-musl-triplets.patch | 43 +++++++++++++++++++ meta/recipes-devtools/python/python3_3.5.6.bb | 1 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-devtools/python/python3/powerpc-musl-triplets.patchmeta/recipes-devtools/python/python3/powerpc-musl-triplets.patch new file +43
-0@@ -0,0 +1,43 @@ +Using musl libc the task do_configure fails on powerpc*. + + checking build system type... x86_64-pc-linux-gnu + checking host system type... powerpc-oe-linux-musl + checking for python3.5... python3.5 + ... + checking for the platform triplet based on compiler characteristics... + powerpc-linux-gnu + configure: error: internal configure error for the platform triplet + +Fix this by adding the musl triplets. +Note: uclibc is purposedly not considered (unsupported in oe-core). + +Upstream-Status: Pending +Signed-off-by: Andrea Adami <[email protected]> + +--- a/configure.ac 2018-12-13 14:44:55.414309610 +0100 ++++ b/configure.ac 2018-12-13 13:22:37.546497547 +0100 +@@ -831,14 +831,22 @@ + or1k-linux-gnu + # elif defined(__powerpc__) && defined(__SPE__) + powerpc-linux-gnuspe ++# elif defined(__powerpc__) && !defined(__GLIBC__) ++ powerpc-linux-musl ++# elif defined(__powerpc__) ++ powerpc-linux-gnu ++# elif defined(__powerpc64__) && !defined(__GLIBC__) ++# if defined(__LITTLE_ENDIAN__) ++ powerpc64le-linux-musl ++# else ++ powerpc64-linux-musl ++# endif + # elif defined(__powerpc64__) + # if defined(__LITTLE_ENDIAN__) + powerpc64le-linux-gnu + # else + powerpc64-linux-gnu + # endif +-# elif defined(__powerpc__) +- powerpc-linux-gnu + # elif defined(__s390x__) + s390x-linux-gnu + # elif defined(__s390__)meta/recipes-devtools/python/python3_3.5.6.bb +1
-1@@ -44,6 +44,7 @@ SRC_URI += "\ file://0005-bpo-30714-ALPN-changes-for-OpenSSL-1.1.0f-2305.patch \ file://run-ptest \ " +SRC_URI_append_libc-musl = " file://powerpc-musl-triplets.patch" inherit multilib_header python3native update-alternatives qemu ptest --2.17.1
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core