I ran the example of using makefile project in D:\NXP\S32DS_Power_v1.2\S32DS\S32_SDK_MPC5748G_EAR_0.8.0\examples\MPC5748G\demo_apps\hello_world-mkf\GCC-MKF, met an error as following, how can I slove this problem.
I using S32DS_Power_v1.2.
Hi Steven,
Thanks for this report.
I suspect there is an issue in the example makefile which does not work well with the latest GCC compiler (S32DS Power v1.2)
Could you possibly try to remove the linker options below from the Makefile (line 124, 127):
-nostartfiles -nostdlib
<S32DS_Power_v1.2>\S32DS\S32_SDK_MPC5748G_EAR_0.8.0\examples\MPC5748G\demo_apps\hello_world-mkf\GCC-MKF\Makefile
## Linker flags
LDFLAGS_RAM:=-Wl,-Map=$(MAP_RAM)
LDFLAGS_RAM+= -nodefaultlibs -T "$(BASEDIR)\platform\devices\MPC5748G\linker\gcc\MPC5748G_ram.ld" --entry=Reset_Handler -Wl,-gc-sections
LDFLAGS_RAM+=-lgcc -lm -lc
LDFLAGS_FLASH:=-Wl,-Map=$(MAP_FLASH)
LDFLAGS_FLASH+= -nodefaultlibs -T "$(BASEDIR)\platform\devices\MPC5748G\linker\gcc\MPC5748G_flash.ld" --entry=Reset_Handler -Wl,-gc-sections
LDFLAGS_FLASH+=-lgcc -lm -lc
And re-build the project.
Hope it helps.
Stan
Hi Stanislav,
Yes. It worked, I can build it correctly by using gcc,very thans.