Hi Marcus: > * Implicitly pass default endianness as -mbig-endian / -mlittle-endian > to gas, since older binutils targeting little endian will not understand > -mlittle-endian. Instead assume gas has the same default as gcc. > If -mbig-endian or -mlittle-endian is explicitly given, it is passed > on to gas since this use is under the discretion of the user. > (This means that DRIVER_SELF_SPECS can not be used to set the default.)
You can add a check in configure.ac and config.in to detect whether binutils is supported or not. here is example, search HAVE_AS_MISA_SPEC in this patch: https://github.com/gcc-mirror/gcc/commit/4b81528241ca682025d92558ff6aeec91dafdca8 > * Configure multilib for big/little endian, since that would require > newest binutils when building for a little endian target, due to the > requirement to build libgcc et al as big endian. I think it's fine at this moment, multi-lib stuff can be done later.