How to enable soft-float support in newlib and gcc toolchains for an i386 target

Joel Sherrill joel.sherrill@oarcorp.com
Tue Aug 2 14:51:00 GMT 2011


On 08/02/2011 06:16 AM, Mian M. Hamayun wrote:
> Hello Everyone,
>
> I am newbie to newlib and gcc toolchains, so my question may be a 
> little ambiguous for this forum.
>
> In fact I am trying to build a gcc toolchain with newlib for an i386 
> target which doesn't support hw float/mmx instructions. In fact it is 
> a virtual machine which I am targeting.
> So when I compile my applications with "-msoft-float" flag, I get 
> quite a few unresolved symbols.
>
The support of the soft-float multilibs is dependent on the
target which the compiler was built for.   And the gcc version.
Without that information, it is hard to answer.


> For Example:
> Sources/susan.c:979: undefined reference to `__floatsisf'
> Sources/susan.c:979: undefined reference to `__divsf3'
> Sources/susan.c:1626: undefined reference to `__subdf3'
> Sources/susan.c:1628: undefined reference to `__mulsf3'
> ...
>
These are gcc support methods.  So it is up to how gcc is built.
> So my obvious 'guess' is to rebuild the gcc toolchain and/or newlib 
> using "--with-float=soft" and/or "--enable-soft-float" options. But so 
> far I haven't been able to build a toolchain that solves this issue.
>
> Any help / pointers in this regard will be greatly appreciated.
> Please also point-out if this is not the right forum for this type of 
> question.
>
> Best Regards,
> Hamayun
>


-- 
Joel Sherrill, Ph.D.             Director of Research&  Development
joel.sherrill@OARcorp.com        On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35805
    Support Available             (256) 722-9985




More information about the Newlib mailing list