Hello,
Starting a new project based on TWR-K64F120, we decided to use KDS (1.3.0) with KSDK (3.0.0) and Processor Expert (PEX). After some try and errors, I understood how it worked and managed to add MQX_STANDARD, a few tasks (OS_Task), the watchdog (fsl_wdog), the Ethernet driver (fsl_enet) and the CRC module (fsl_crc). It started well until I used PEX to add the component fsl_dspi, this caused the following linkage error:
arm-none-eabi-g++: error: ./Generated_Cde/crc16_CCITT.o: No such file or directory
This is related to the CRC module (fsl_crc) which builds correctly. If I disable the fsl_dspi component in PEX, the linkage error goes away so it is not related to fsl_crc. I don't have any clues about the reason why the linker can't find the existing file when adding the fsl_dspi component but it's obviously related to that addition.
For the info, here is the make command (with spaces replaced by EOL to make it more readable):
arm-none-eabi-g++
-mcpu=cortex-m4
-mthumb
-mfloat-abi=hard
-mfpu=fpv4-sp-d16
-O0
-fmessage-length=0
-fsigned-char
-ffunction-sections
-fdata-sections
-Wall
-g3
-T
"C:/Users/nicolas/workspace.kds/EERM-NG/Project_Settings/Linker_Files/ProcessorExpert.ld"
-Xlinker
--gc-sections
-L"C:/Users/nicolas/workspace.kds/EERM-NG/Project_Settings/Linker_Files"
-L"C:\Freescale\KSDK_1.3.0/middleware/tcpip/rtcs/lib/twrk64f120m.kds/debug/rtcs"
-L"C:\Freescale\KSDK_1.3.0\lib\ksdk_platform_lib\kds\K64F12\debug"
-L"C:\Freescale\KSDK_1.3.0\rtos\mqx\lib\twrk64f120m.kds\debug\mqx"
-L"C:\Freescale\KSDK_1.3.0\rtos\mqx\lib\twrk64f120m.kds\debug\mqx_stdlib"
-Wl,-Map,"EERM-NG.map"
-lgcc
-lc
-lsupc++
-lm
-specs=nosys.specs
-nostartfiles
-Xlinker
-z
-Xlinker
muldefs
-Xlinker
-static
-o
"EERM-NG.elf"
./Static_Code/System/PE_low_level_init.o
./Sources/http_srv/eermng_http_srv.o
./Sources/Events.o
./Sources/main.o
./Sources/os_tasks.o
./Sources/rtos_main_task.o
./SDK/rtos/mqx/mqx_stdlib/source/strings/strings.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/buf_prv.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/err.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/fclose.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/fflush.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/fopen.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/fp_prv.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/fread.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/fwrite.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/get.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/pos.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/print.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/print_prv.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/put.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/scan.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/scan_prv.o
./SDK/rtos/mqx/mqx_stdlib/source/stdio/stdio.o
./SDK/rtos/mqx/mqx/source/string/str_utos.o
./SDK/rtos/mqx/mqx/source/string/strnlen.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/core/M4/boot.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/core/M4/dispatch.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/core/M4/support.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/compiler/gcc_arm/comp.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/cortex.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/int_gkis.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/int_kisr.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/int_pvta.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/int_unx.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/int_vtab.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/int_xcpt.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/ipsum.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/mem_copy.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/mem_zero.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/nvic.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_dati.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_gelms.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_hoti.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_iinit.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_mat1.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_mat2.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_mat3.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_miti.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_msti.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_mstiq.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_nsti.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_psti.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_seti.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_supp.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tiad.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tida.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tihr.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_timn.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tims.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tinm.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tins.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tiol.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tipr.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tips.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tise.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tisu.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tius.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_tkti.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/psp_usti.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/sc_irdyq.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/stack_bu.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/stack_de.o
./SDK/rtos/mqx/mqx/source/psp/cortex_m/stack_st.o
./SDK/rtos/mqx/mqx/source/nio/src/errno.o
./SDK/rtos/mqx/mqx/source/nio/src/nio.o
./SDK/rtos/mqx/mqx/source/nio/src/nio_posix.o
./SDK/rtos/mqx/mqx/source/nio/src/nio_std_adpt.o
./SDK/rtos/mqx/mqx/source/nio/fs/fs_supp.o
./SDK/rtos/mqx/mqx/source/nio/drivers/nio_tty/src/nio_tty.o
./SDK/rtos/mqx/mqx/source/nio/drivers/nio_serial/src/nio_serial.o
./SDK/rtos/mqx/mqx/source/nio/drivers/nio_mem/src/nio_mem.o
./SDK/rtos/mqx/mqx/source/nio/drivers/nio_dummy/src/nio_dummy.o
./SDK/rtos/mqx/mqx/source/kernel/event.o
./SDK/rtos/mqx/mqx/source/kernel/idletask.o
./SDK/rtos/mqx/mqx/source/kernel/inittask.o
./SDK/rtos/mqx/mqx/source/kernel/int.o
./SDK/rtos/mqx/mqx/source/kernel/klog.o
./SDK/rtos/mqx/mqx/source/kernel/log.o
./SDK/rtos/mqx/mqx/source/kernel/lwevent.o
./SDK/rtos/mqx/mqx/source/kernel/lwlog.o
./SDK/rtos/mqx/mqx/source/kernel/lwmem.o
./SDK/rtos/mqx/mqx/source/kernel/lwmsgq.o
./SDK/rtos/mqx/mqx/source/kernel/lwsem.o
./SDK/rtos/mqx/mqx/source/kernel/lwtimer.o
./SDK/rtos/mqx/mqx/source/kernel/mem.o
./SDK/rtos/mqx/mqx/source/kernel/mqx.o
./SDK/rtos/mqx/mqx/source/kernel/msg.o
./SDK/rtos/mqx/mqx/source/kernel/msgpool.o
./SDK/rtos/mqx/mqx/source/kernel/msgq.o
./SDK/rtos/mqx/mqx/source/kernel/mutex.o
./SDK/rtos/mqx/mqx/source/kernel/name.o
./SDK/rtos/mqx/mqx/source/kernel/partition.o
./SDK/rtos/mqx/mqx/source/kernel/queue.o
./SDK/rtos/mqx/mqx/source/kernel/sched.o
./SDK/rtos/mqx/mqx/source/kernel/sem.o
./SDK/rtos/mqx/mqx/source/kernel/task.o
./SDK/rtos/mqx/mqx/source/kernel/taskq.o
./SDK/rtos/mqx/mqx/source/kernel/time.o
./SDK/rtos/mqx/mqx/source/kernel/timer.o
./SDK/rtos/mqx/mqx/source/kernel/tlsf.o
./SDK/rtos/mqx/mqx/source/kernel/tlsf_adaptation.o
./SDK/rtos/mqx/mqx/source/kernel/watchdog.o
./SDK/rtos/mqx/mqx/source/bsp/init_bsp.o
./SDK/platform/utilities/src/fsl_debug_console.o
./SDK/platform/utilities/src/fsl_misc_utilities.o
./SDK/platform/utilities/src/print_scan.o
./SDK/platform/system/src/interrupt/fsl_interrupt_manager.o
./SDK/platform/system/src/hwtimer/fsl_hwtimer.o
./SDK/platform/system/src/hwtimer/fsl_hwtimer_systick.o
./SDK/platform/system/src/clock/MK64F12/fsl_clock_MK64F12.o
./SDK/platform/system/src/clock/fsl_clock_manager.o
./SDK/platform/system/src/clock/fsl_clock_manager_common.o
./SDK/platform/osa/src/fsl_os_abstraction_mqx.o
./SDK/platform/hal/src/wdog/fsl_wdog_hal.o
./SDK/platform/hal/src/uart/fsl_uart_hal.o
./SDK/platform/hal/src/sim/MK64F12/fsl_sim_hal_MK64F12.o
./SDK/platform/hal/src/rtc/fsl_rtc_hal.o
./SDK/platform/hal/src/port/fsl_port_hal.o
./SDK/platform/hal/src/osc/fsl_osc_hal.o
./SDK/platform/hal/src/mpu/fsl_mpu_hal.o
./SDK/platform/hal/src/mcg/fsl_mcg_hal.o
./SDK/platform/hal/src/mcg/fsl_mcg_hal_modes.o
./SDK/platform/hal/src/enet/fsl_enet_hal.o
./SDK/platform/hal/src/dspi/fsl_dspi_hal.o
./SDK/platform/hal/src/crc/fsl_crc_hal.o
./SDK/platform/drivers/src/wdog/fsl_wdog_common.o
./SDK/platform/drivers/src/wdog/fsl_wdog_driver.o
./SDK/platform/drivers/src/uart/fsl_uart_common.o
./SDK/platform/drivers/src/uart/fsl_uart_driver.o
./SDK/platform/drivers/src/rtc/fsl_rtc_common.o
./SDK/platform/drivers/src/mpu/fsl_mpu_common.o
./SDK/platform/drivers/src/mpu/fsl_mpu_driver.o
./SDK/platform/drivers/src/enet/fsl_enet_common.o
./SDK/platform/drivers/src/enet/fsl_enet_driver.o
./SDK/platform/drivers/src/dspi/fsl_dspi_common.o
./SDK/platform/drivers/src/dspi/fsl_dspi_master_driver.o
./SDK/platform/drivers/src/dspi/fsl_dspi_shared_function.o
./SDK/platform/drivers/src/dspi/fsl_dspi_slave_driver.o
./SDK/platform/drivers/src/crc/fsl_crc_common.o
./SDK/platform/drivers/src/crc/fsl_crc_driver.o
./SDK/platform/devices/MK64F12/startup/gcc/startup_MK64F12.o
./SDK/platform/devices/MK64F12/startup/system_MK64F12.o
./SDK/platform/devices/startup.o
./Generated_Code/Cpu.o
./Generated_Code/MainTask.o
./Generated_Code/TaskJdB.o
./Generated_Code/TaskMonitoring.o
./Generated_Code/TaskServerHTTP.o
./Generated_Code/clockMan1.o
./Generated_Code/crc16_CCITT.o
./Generated_Code/dspiCom1.o
./Generated_Code/eNet1.o
./Generated_Code/fsl_hwtimer1.o
./Generated_Code/fsl_mpu1.o
./Generated_Code/hardware_init.o
./Generated_Code/mqx_ksdk.o
./Generated_Code/osa1.o
./Generated_Code/pin_init.o
./Generated_Code/uart1.o
./Generated_Code/watchdog1.o
-l_rtcs
Solved! Go to Solution.
I finally found out thanks to another post in the NXP 's community: KDS Static Library Project - Another Bug Report - Need Fix , the given solution links to the following blog post: Solving the 8192 Character Command Line Limit on Windows | MCU on Eclipse which describes the problem as coming from the tools being limited to 8192 characters. In summary: download the most recent tools: GNU ARM Eclipse Windows Build Tools releases and replace echo.exe/make.exe/rm.exe in KDS installation folder.
I'm getting confused: not knowing how to tackle the problem, I started a new project, added some components under Processor Expert (fsl_crc, fsl_dspi, 1 OS_Task and fsl_gpio) and I managed to create a working project. The only thing I can think about is that there were more components on my initial project than there is in this small test project.
I finally found out thanks to another post in the NXP 's community: KDS Static Library Project - Another Bug Report - Need Fix , the given solution links to the following blog post: Solving the 8192 Character Command Line Limit on Windows | MCU on Eclipse which describes the problem as coming from the tools being limited to 8192 characters. In summary: download the most recent tools: GNU ARM Eclipse Windows Build Tools releases and replace echo.exe/make.exe/rm.exe in KDS installation folder.
It seems to be a deeper problem that I originally thought. Today, taking off the fsl_dspi component doesn't allow me to build but generates an error on the watchdog (fsl_wdog).
arm-none-eabi-g++: error: ./Generated_Code/watchdog1o: No such file or directory
The module is built, the object file does exist. The exact same result which happened yesterday with another component, however, today I cannot get the linker to succeed by taking off the fsl_dspi component. I'm lost.