[Toybox] [PATCH] Fix 32-bit bionic toybox build.

Rob Landley rob at landley.net
Sat Jul 11 12:22:36 PDT 2015


On 07/10/2015 09:25 PM, enh wrote:
> (already submitted as https://android-review.googlesource.com/159035/
> --- i was under pressure because i didn't notice the problem until i'd
> already broken all the 32-bit builds. as usual i tested on 64-bit.
> i've removed the non-standard basename_r and dirname_r from 64-bit

Sigh. There's already a basename_r. Well of course there is.

It sounds like a good idea, personally I'd submit it to posix rather
than remove it. A better fix would be to move basename_r() to
portability.c and rely on libc to provide it if they have it. (I assume
that your basename_r() and the implementation I did aren't too far apart
behavior-wise?)

I need to dig up my AOSP build and try to chip the toolchain out to test
build toybox. (Will static bionic builds run on ubuntu's kernel?)

> bionic, but i can't fix the past. the build failure is because the
> 32-bit bionic basename_r had the signature int basename_r(const char*,
> char*, size_t). looking ahead maybe i should add a _BIONIC_NO_CRUFT so
> non-historic 32-bit code can opt out of this kind of pollution.)

Seriously, I'd just submit this one to the Austin group for the next
posix/susvX spec. What the gnu guys did is a way bigger deviation than
bionic here.

> commit f8b41e81fca2b53410f80c95f111c754d5eff99a
> Author: Elliott Hughes <enh at google.com>
> Date:   Fri Jul 10 19:11:18 2015 -0700

I've applied this, but I'm open to using bionic's basename_r() instead
of mine instead. FYI.

Rob

 1436642556.0


More information about the Toybox mailing list