From: Ben Wolsieffer <ben.wolsieffer@hefring.com>
To: Vladimir Murzin <vladimir.murzin@arm.com>
Cc: "Yann E. MORIN" <yann.morin.1998@free.fr>,
Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH 0/2] Add support for FDPIC binaries on ARM
Date: Thu, 11 Aug 2022 17:37:21 -0400 [thread overview]
Message-ID: <YvV2kelJpRw6erhZ@hefring> (raw)
In-Reply-To: <b71a7617-3e26-14ef-6fe6-45e766924270@arm.com>
On Tue, Aug 09, 2022 at 12:26:14PM +0100, Vladimir Murzin wrote:
>
> You might also want to allow uClibc to use NPTL thread library instead
> of old(-sh) LinuxThreads with something like
>
> diff --git a/package/uclibc/Config.in b/package/uclibc/Config.in
> index ba8b5885ec..30a154531a 100644
> --- a/package/uclibc/Config.in
> +++ b/package/uclibc/Config.in
> @@ -76,7 +76,7 @@ choice
>
> config BR2_PTHREADS_NATIVE
> bool "Native POSIX Threading (NPTL)"
> - depends on BR2_USE_MMU
> + depends on BR2_USE_MMU || BR2_BINFMT_FDPIC
> select BR2_TOOLCHAIN_HAS_THREADS
> select BR2_TOOLCHAIN_HAS_THREADS_NPTL
>
You mean I could have just used NPTL and not wasted hours fighting
LinuxThreads...
I'm not sure how I missed this before, since I immediately found the
relevant patches when I searched for them now.
I've been playing around with NPTL and FDPIC and it doesn't quite work
perfectly out of the box. Static libraries (linked into a dynamic
executable) crash when attempting to use TLS. In addition, the reason
static libraries are even being used is because libtool doesn't recognize
the target name and therefore thinks it can't build shared libaries.
There was a patch [1] submitted a few years ago to add the target to
libtool, but it looks like it was ignored. Unfortunately, we can't just
apply it in Buildroot, unless we want to run autoreconf on every
package. I'm working around this locally with a hacky hook to patch
configure scripts, but I'm not sure it is appropriate to upstream.
Although the situation is not ideal, things basically work with
LinuxThreads and the libtool issue, so I'd prefer to get this patch set
finished without expanding the scope.
Thanks, Ben
[1] https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2022-08-11 21:37 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-02 13:30 [Buildroot] [PATCH 0/2] Add support for FDPIC binaries on ARM Ben Wolsieffer
2022-08-02 13:30 ` [Buildroot] [PATCH 1/2] Revert "arch: drop now useless support for FDPIC" Ben Wolsieffer
2022-08-02 13:30 ` [Buildroot] [PATCH 2/2] arch/arm: add support for FDPIC Ben Wolsieffer
2022-08-02 17:28 ` Arnout Vandecappelle
[not found] ` <b71a7617-3e26-14ef-6fe6-45e766924270@arm.com>
2022-08-11 21:37 ` Ben Wolsieffer [this message]
2022-08-14 21:55 ` [Buildroot] [PATCH 0/2] Add support for FDPIC binaries on ARM Arnout Vandecappelle
2022-08-16 20:40 ` Ben Wolsieffer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YvV2kelJpRw6erhZ@hefring \
--to=ben.wolsieffer@hefring.com \
--cc=buildroot@buildroot.org \
--cc=thomas.petazzoni@bootlin.com \
--cc=vladimir.murzin@arm.com \
--cc=yann.morin.1998@free.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.