OK I found the solution
you need to set the active build configuration to build for internal flash. Default is for RAM.?
if you are using Code Warrior, right click on the project, then
Build configurations -> set active -> <select the one you wish for>