I have a desktop PC at home, it's an x86_64 with 40 cores running Ubuntu Linux.
I've spent the last week or two creating a 'chroot jail' in which I have placed a cross-compiler that builds 32-Bit Big Endian ARM programs.
With the help of "Linux from Scratch" I've built all the libraries I need for my 'Dynamo' program (glib, X11, gtk+2, boost, wxwidgets... and two dozen other dependencies like harfbuzz, freetype, libxml2, etc.).
My chrootjail is very minimal. If a program or library isn't needed then it's out.
In the past half-hour I've finally gotten my Dynamo program built as a 32-Bit Big Endian ARM program. I have QEMU installed, which is a CPU emulator, it allows me to run a 32-Bit Big Endian ARM binary on a 64-Bit x86 computer. I've run Dynamo inside my chrootjail, and the screenshot is below.
As you can see, the letters displayed on the screen are just empty boxes. Anyone know what's likely to cause this? Am I missing some font files or whatever from /usr/share? Because right now there's very little stuff in /usr/share.
(By the way this is related to my thread from 3 weeks ago in which I was exploring other ways of running a Big Endian binary: viewtopic.php?p=210438)
GUI program inside chrootjail (running under QEMU)
Re: GUI program inside chrootjail (running under QEMU)
Hi,
Another other possibility might be the chroot's locale. Try setting it to the default en_US if it isn't already.
Regards,
David
That sounds likely. Have a look in the chroot's /usr/share/fonts/ and compare it with ubuntu.Am I missing some font files or whatever from /usr/share?
Another other possibility might be the chroot's locale. Try setting it to the default en_US if it isn't already.
Regards,
David
Re: GUI program inside chrootjail (running under QEMU)
If any of you are interested in testing your wxWidgets program out on a Big Endian CPU then I'll make my chrootjail available as a tarball when I have it just right. A few more days of tweaking.
For example with testing my own program, I read in the contents of capture files produced by Wireshark -- which can be in either big or little endian format -- and so this is definitely something I want to test on a big endian processor.
Also it can help detect a few other problems, for example:
This snippet will mostly work fine on an x86 CPU because if the input number is less than 65536 then a 'short' and an 'int' will read back the same -- you'll probably get away with the two bytes of stack corruption. On a big Endian CPU though, 'x' will always be zero so you'll spot the error sooner in testing.
For example with testing my own program, I read in the contents of capture files produced by Wireshark -- which can be in either big or little endian format -- and so this is definitely something I want to test on a big endian processor.
Also it can help detect a few other problems, for example:
Code: Select all
short x;
scanf("%i", &x);