When compiling for a cross compiler to mips64-linux-gnu, we need to build a minimal compiler which does not have any libc headers including stdio.h. So when we go to link n32 (or n64) glibc, it fails saying undefined symbols for the TF functions. The reason why it fails is because libgcc's configure did not figure out the size of long double. The reason why that test fails is because there is an include for stdio.h. The default AC_CHECK_SIZEOF uses the default include requirements which include stdio.h unconditionally. Add to configure.ac and regenerate. # The libgcc should not depend on any header files AC_DEFUN([_AC_INCLUDES_DEFAULT_REQUIREMENTS], [m4_divert_text([DEFAULTS], [ac_includes_default='/* none */'])]) --- CUT --- I will submit this patch after I finish testing it but I wanted to file this as a bug so it does not get lost.
Mine.
Author: pinskia Date: Mon May 21 18:56:35 2012 New Revision: 187732 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=187732 Log: 2012-05-21 Andrew Pinski <apinski@cavium.com> PR bootstrap/53183 * configure.ac: Define the default includes to being none. * configure: Regenerate. Modified: trunk/libgcc/ChangeLog trunk/libgcc/configure trunk/libgcc/configure.ac
Author: pinskia Date: Mon May 21 19:02:11 2012 New Revision: 187733 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=187733 Log: 2012-05-21 Andrew Pinski <apinski@cavium.com> PR bootstrap/53183 * configure.ac: Define the default includes to being none. * configure: Regenerate. Modified: branches/gcc-4_7-branch/libgcc/ (props changed) branches/gcc-4_7-branch/libgcc/ChangeLog branches/gcc-4_7-branch/libgcc/configure branches/gcc-4_7-branch/libgcc/configure.ac Propchange: branches/gcc-4_7-branch/libgcc/ ('svn:mergeinfo' added)
Fixed.