From: M. R. B. <ma...@uw...> - 2001-02-21 08:35:11
|
On Tue, 20 Feb 2001, Bryan Rittmeyer wrote: > Hmmm... Well, even with the patches I posted previously, I'm having > trouble building the Linux kernel (2.4.1 out of LinuxSH CVS)... the > problem is with our old friends __sdivsi3_i4, __udivsi3_i4, __udivsi3 > and __sdivsi3. They are preventing linkage because they're undefined. > Any idea how to fix this problem? > Heh, those four have caused me many headaches :). Here's what I know (from the gcc sources): Each of those funtions represent integer divide code ... they're all defined in gcc/config/sh/lib1funcs.asm. Each of these routines are conditionally compiled into libgcc based on the cppspecs that define those architecture macros (__SH4__, __SH4_SINGLE__, __SH4_SINGLE_ONLY__) because most of them (except for two which are there for compatibility) are pure floating-point. In your previous post you said you were configuring gcc with --disable-multilib. Well, the sh-linux-gnu Makefile fragment (t-linux) overrides the standard t-sh fragment which allows for a -m4-nofpu version of libgcc (I don't know if this would resolve those references). Is there a reason why you're disabling multilib? The default flags from the specs in linux.h specify compiling for an SH3 (everything defaults to -m3), which would explain why those FP routines aren't pulled into libgcc.a. So, you either want to leave multilib enabled, or change the defaults in linux.h to generate code for the SH4 (my patches do this). I hope I was somewhat coherent bacause it's late where I am and I'm working on a few things at once :) M. R. |