[Buildroot] [PATCH v2] package/uclibc: Enable compile in thumb mode configuration option

Paul Enman paul.enman at gmail.com
Thu Dec 31 19:44:13 UTC 2015


Hi Waldemar,

On Sat, Dec 19, 2015 at 3:13 AM, Waldemar Brodkorb <wbx at openadk.org> wrote:

> Hi Arnout,
> Arnout Vandecappelle wrote,
>
> > On 16-12-15 08:10, Waldemar Brodkorb wrote:
> > > Hi,
> > > Thomas Petazzoni wrote,
> > >> Paul,
> > >>
> > >>> + $(call KCONFIG_DISABLE_OPT,UCLIBC_HAS_CONTEXT_FUNCS,$(@D)/.config)
> > >>
> > >> What is the relation between this and Thumb ?
> > >
> > > The user context manipulation functions in uClibc are using
> > > non-thumb instructions and result in a compile failure.
> >
> >  Some packages need context functions, that's why they are enabled in our
> > default uClibc config. Cfr. d01aaa7 (by you, Waldemar).
>
> Yeah. But the context functions are deprecated and POSIX suggests
> not to use them. Unfortunately they are only implemented for
> arm/mips/x86/x86_64 in uClibc. Someone could port the implementation
> for other architectures from GNU libc. But then still all noMMU
> architectures would be missing. Furthermore the GNU libc
> implementation does not work for THUMB only builds.
>
> >  So if you do this, you'll need to make some packages depend on !THUMB.
> While
> > they actually did work before this commit.
>
> They did work before for people trying to run thumb code on a ARM
> core which allows both modes. (arm and thumb)
> But without this patch people can not use it to do a thumb2-only
> build, which is a requirement to support ARM noMMU processors like
> Cortex-M3 and Cortex-M4.
>
> >  Can't uClibc be fixed to enable interworking for the context functions
> so they
> > will work even if the rest of the library is compiled in thumb mode?
>
> I think the intention of this patch is to support thumb2 only
> builds. There is no interworking support for Cortex-M3/Cortex-M4.
>


> Best regards
>  Waldemar
>

Thanks for your insight, if I understand this correctly, context functions
are presently supported by toolchains using (e)glibc, musl and uClibc only
for architectures arm(with interworking)/mips/x86/x86_64 instructions (and
not thumb, thumb2, ARC, Xtensa, others)?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20151231/57e320c3/attachment-0002.html>


More information about the buildroot mailing list