On Wed, Apr 11, 2018 at 02:20:49 +0100, Alex Bennée wrote: > Emilio G. Cota <c...@braap.org> writes: > So with the attached patch and my proposed cross build we can now get: > > 02:15:54 [alex@zen:~/l/q/qemu.git] softfloat-fixes-for-2.12-v1 ± find . > -iname "fp-test" | xargs file > ./ppc64-linux-user/tests/fp-test: ELF 64-bit LSB executable, 64-bit > PowerPC or cisco 7500, version 1 (GNU/Linux), statically linked, for > GNU/Linux 3.2.0, not stripped (snip) > But it did mean having to hack about a little, mainly to get rid of > glib.
That will let us build fp-test using a cross-compiler. My initial thinking was that since we'd end up testing on a real host (with "-t host" mode), cross-compiling wouldn't be necessary since we could just compile natively on said host. But since we seem to be moving towards supporting cross-compilers, it takes little effort to cross-compile fp-test as well. The main hurdle is to remove the glib dependence as you pointed out. I just wrote a few patches to do this: $ git log --oneline -5 --reverse 48e802b osdep: disable glib-compat.h include with QEMU_NO_GLIB d3c78c7 softfloat: do not include glib headers 744a9c4 tests/tcg/Makefile: define _GNU_SOURCE 661c0e2 tests/fp: fixup e057d45 tests/tcg/Makefile: fp-test build fixup The main difference with your attached patch is that we remove ifdef's from fp-test.c while keeping the osdep.h include. You can fetch the patches from https://github.com/cota/qemu/tree/softfloat-fixes-for-2.12-v1 [BTW the name of the branch is just to keep your original branch name; I'm in now way intending for this to be part of 2.12 :>] Thanks, Emilio