Hello,
I have Codewarrior 6.2 and am compiling for a coldfire V1 chip.
I solved this problem:
1. Libraries in project
fp_coldfire_ieee_nodiv.a
C_4i_CF_RegABI_Runtime.a
C_4i_CF_RegABI_MATH_MSL.a
2. Open up MSL_C.CF.v1.mcp project file.
a. Set target to MATH 4i ColdFire RegABI
b. Open ansi_prefix.CF.v1.h
1. add #define __CF_USE_FULL_LIBS__ 1
at the start of file
2. change #define _MSL_HIWARE_COMP 1 to
#define _MSL_HIWARE_COMP 0
3. change #define _MSL_C99 0 to
#define _MSL_C99 1
c. add ansi_fp.c to to project it is in directory
<wherever Codewarrior instaled>\Coldfire_Support\msl\MSL_C\MSL_Common_Embedded\Src
d. build MATH 4i ColdFire RegABI target
If we did everything right it should build fine. And a check mark will appear next to C_4i_CF_RegABI_MATH_MSL.a library in your application project.
Then viola atof will link.
When I did this my binary image grew about 6K
Oh before I did this I had already done the fix for %f format
working FAQ 28628
Don't know if you have to this first to wore out to undo and
see if it matters.. But if you want to print floats you will have
to follow FAQ 28628
Hope this helps
John