<div dir="auto"><div><div class="gmail_extra"><div class="gmail_quote">On Mar 13, 2017 9:19 PM, "Aleix Pol" <<a href="mailto:aleixpol@kde.org">aleixpol@kde.org</a>> wrote:<br type="attribution"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="elided-text">On Mon, Mar 13, 2017 at 4:55 PM, Dan Nicholson <<a href="mailto:nicholson@endlessm.com">nicholson@endlessm.com</a>> wrote:<br>
> On Mon, Mar 13, 2017 at 10:08 AM, Aleix Pol <<a href="mailto:aleixpol@kde.org">aleixpol@kde.org</a>> wrote:<br>
>> On Tue, Mar 7, 2017 at 1:08 PM, Dan Nicholson <<a href="mailto:nicholson@endlessm.com">nicholson@endlessm.com</a>> wrote:<br>
>>> On Tue, Mar 7, 2017 at 4:58 AM, Bastien Nocera <<a href="mailto:hadess@hadess.net">hadess@hadess.net</a>> wrote:<br>
>>>> On Tue, 2017-03-07 at 03:05 +0100, Aleix Pol wrote:<br>
>>>>> Dear Flatpak'ers,<br>
>>>>> As some of you already know, I've been poking around trying to find<br>
>>>>> some kind of system where we can build the KDE runtime and<br>
>>>>> applications for ARM.<br>
>>>><br>
>>>> For the applications, the fix is a package install on the build system,<br>
>>>> and a flatpak-builder option away. See this post as well as the<br>
>>>> original one:<br>
>>>> <a href="http://www.hadess.net/2016/10/flatpak-cross-compilation-support.html" rel="noreferrer" target="_blank">http://www.hadess.net/2016/10/<wbr>flatpak-cross-compilation-<wbr>support.html</a><br>
>>><br>
>>> We use this QEMU setup at Endless for our ARM apps. It's slow but<br>
>>> works fine for apps. I think building a whole runtime would be<br>
>>> painful, but you could give it a shot.<br>
>>><br>
>>> The details in Bastien's post is that if you have qemu-user-static<br>
>>> installed with the appropriate binfmts (usually provided in distro<br>
>>> packaging), then you can run binaries emulated for any architecture<br>
>>> QEMU supports. On linux-4.8+, the interpreter associated with the<br>
>>> binfmt is opened immediately by the kernel and kept open so it doesn't<br>
>>> need to live in the mount namespace setup by flatpak. Pass the<br>
>>> appropriate arch to flatpak-builder and it magically works.<br>
>>><br>
>>> On older kernels you can still do it, but you have to somehow get the<br>
>>> interpreter path used in the binfmt definition included in the<br>
>>> sandbox. One way would be to include qemu-user-static in the SDK at<br>
>>> the same path as the host (e.g., /usr/bin/qemu-arm-static). What I did<br>
>>> at Endless was hack the binfmt definition to use /run/qemu-arm-static<br>
>>> and then add a bind mount from the host into the sandbox at that<br>
>>> location.<br>
>><br>
>> Hi,<br>
>> So since nothing was really working and the cosmos doesn't seem to be<br>
>> keen on offering proper ARM systems, I decided to give it a go.<br>
>><br>
>> Yet, I'm getting an error message at the first thing ever executed:<br>
>> execvp ./configure: No such file or directory<br>
>><br>
>> Any idea what can be wrong?<br>
>><br>
>> Aleix<br>
>><br>
>> PS: I'm testing this on ubuntu yakkety (kernel 4.8.0) and the flatpak ppa<br>
><br>
> That indicates that you don't have the binfmt support enabled because<br>
> that essentially means that it can't run the ARM /bin/sh (I'm pretty<br>
> sure). Do you have /proc/sys/fs/binfmt_misc/qemu-<wbr>arm? Does<br>
> /proc/sys/fs/binfmt_misc/<wbr>status say "enabled"? Can you do something<br>
> simple like "flatpak build $build_dir bash"?<br>
<br>
</div>Sounds like something is wrong in my system?<br>
Maybe a permissions issue?<br>
<br>
Aleix<br>
<br>
$ flatpak build sdk bash<br>
execvp bash: No such file or directory<br>
$ cat /proc/sys/fs/binfmt_misc/<wbr>status<br>
enabled<br>
$ ls -l /proc/sys/fs/binfmt_misc/qemu-<wbr>arm<br>
-rw-r--r-- 1 root root 0 mar 13 14:19 /proc/sys/fs/binfmt_misc/qemu-<wbr>arm<br></blockquote></div></div></div><div dir="auto"><br></div><div dir="auto">Can you show the contents of that qemu-arm file?</div><div dir="auto"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
</blockquote></div><br></div></div></div>