Cross-build issues in gdb/gnulib

Paul_Koning@Dell.com Paul_Koning@Dell.com
Mon Aug 24 21:20:00 GMT 2015


I'm running into strange problems cross-building with V7.7.1; it looks like the same configure machinery is present in later versions as well.

The problem is that the configure script in gdb/gnulib tries to run a number of tests, by building and then executing "conftest".  It does so unconditionally, there are no checks for whether this is a cross-build, specifically build = x86_64-linux, host = target = netbsd.

For one of my crossbuilds this "works" because there the host is mips, so attempting to execute conftest fails and the script handles this in a way that produces an acceptable outcome.

But when target is i386-netbsdelf, when the script attempts to execute the (NetBSD) binary for conftest, Linux attempts to do so.  I guess it has some flavor of NetBSD emulation.  But this is bad for two reasons. First, executing that program on the Linux build system obviously produces an irrelevant answer.  Second, and this is what breaks my build, the NetBSD emulation in Linux is defective -- conftest goes into an infinite loop.  So my build never finishes.

What can I do about this?

	paul



More information about the Gdb mailing list