<div dir="ltr">in O apps (and their children) are in a seccomp sandbox. if you use a system call that bionic doesn't use (such as in this case, the obsolete fork system call), you will run into things like this. the specific case of fork was used enough in apps that the security folks added it to a whitelist, so all O releases later than the first developer preview should allow it.</div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Apr 17, 2017 at 10:47 AM, Rob Landley <span dir="ltr"><<a href="mailto:rob@landley.net" target="_blank">rob@landley.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 04/16/2017 04:36 AM, darken wrote:<br>
> FYI (but I think you CCed yourself on the issue ticket right?)<br>
><br>
> Copying the system toybox into my app makes it work.<br>
> So it seems to be related to how the system toybox is build (NDK<br>
> toolchain?) and my toybox is build (musl libc).<br>
<br>
</span>Eh, that might just be kernel .config. There are a lot of duplicate<br>
system calls that accumulated over the years (blah/blah64, open/openat,<br>
mmap/mmap2...) and you can configure a bunch of them out<br>
<br>
Don't ask me why the 4.11.0-rc7 menuconfig's "General setup" menu has<br>
config options for bpf, madvise/fadvise, userfaultfd, membarrier... Why<br>
are these NOT in the "embedded system" submenu? Enabling a _system_call_<br>
is not enabling lots of infrastructure. It's micromanaging the API. Sigh...<br>
<br>
You can find a static armv5l strace binary (from the dawn of time) at:<br>
<br>
<a href="http://landley.net/aboriginal/downloads/old/binaries/1.4.3/extras/strace-armv5l" rel="noreferrer" target="_blank">http://landley.net/aboriginal/<wbr>downloads/old/binaries/1.4.3/<wbr>extras/strace-armv5l</a><br>
<br>
I've end of lifed aboriginal linux and am working on turning<br>
<a href="https://github.com/landley/mkroot" rel="noreferrer" target="_blank">https://github.com/landley/<wbr>mkroot</a> into a replacement, but it's not there<br>
yet. Still, old binary might work. (Haven't tried it under an android<br>
kernel.)<br>
<br>
I also have a todo item to turn<br>
<a href="https://blog.nelhage.com/2010/08/write-yourself-an-strace-in-70-lines-of-code/" rel="noreferrer" target="_blank">https://blog.nelhage.com/2010/<wbr>08/write-yourself-an-strace-<wbr>in-70-lines-of-code/</a><br>
and some build-time header preprocessing ala<br>
<a href="http://landley.net/notes.html#18-02-2017" rel="noreferrer" target="_blank">http://landley.net/notes.html#<wbr>18-02-2017</a> into a simple strace for toybox.<br>
<br>
It's on the todo list...<br>
<span class="HOEnZb"><font color="#888888"><br>
Rob<br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Elliott Hughes - <a href="http://who/enh" target="_blank">http://who/enh</a> - <a href="http://jessies.org/~enh/" target="_blank">http://jessies.org/~enh/</a><br>Android native code/tools questions? Mail me/drop by/add me as a reviewer.</div>
</div>