The file name or extension is too long. (0xCE)

Hello,
can someone help me with the error message from the linker in TI Code Composer Studio?
Image is attached below.

I found this help during my research, but as you can see (drive W mapped as environment) it did nothing either.

GitHub - edgeimpulse/ei-ti-code-composer-examples: Examples and walkthroughs integrating Edge Impulse with TI Code Composer projects

If I then replace the expression @“ccsLinker.opt” in the linker call with the direct commands from the ccs.Linker.opt, an error message appears.
Then it is no longer reported that something is too long, but something does not fit with the libc.a.

Unfortunately, I can’t get any further here and would be grateful for help, as EdgeImpulse is no longer an option for me.

Kind regards
Marcel

Here is the second error message.

This is because as a new user I was not allowed to take two pictures in one post.

Hi @MarcelSch,

This is an unfortunate limitation of Windows, as you are only allowed 255 characters for a filename + path. The Edge Impulse library and sub-libraries (e.g. TFLite for Microcontrollers) have a lot of subdirectories, which can easily surpass this character limit.

Where on your computer are you keeping your project and Edge Impulse SDK library (i.e. what is the full path to main.cpp and full path to edge-impulse-sdk/)? I could not tell from your screenshots.

You can also try enabling “long path names” in Windows to see if that fixes the issue. See this guide for doing that.

Activating long paths has not brought any improvement.
The same error message comes up that the file name or an extension is too long.

The project is located under “C:\ti\KI\Test1”.
EdgeImpulseSDK is located under “C:\ti\KI\Test1\edge-impulse-sdk”.
The path to “main.cpp” is “C:\ti\KI\Test1\main.cpp”.

Hi @MarcelSch,

We’ll add a fix to this limitation in a future release.
Do you need to use Code Composer or command line would work?

I’d recommend using our Docker build as it’s loading a Linux environment to compile the firmware:

Also adding @daschwar to the thread.

Aurelien

When is it planned to fix the limitation issue in a new release?

What exactly do you mean by whether Code Composer is needed or whether command line is sufficient?

I don’t have a CC1352P LaunchPad but a different controller.

Our official target support is for the CC1352P LaunchPad using GCC and the SimpleLink SDK.

The TI Code Composer example is a work in progress (@daschwar may have more information of a new release). If you don’t need the Code Composer IDE, I’d suggest using our Docker build, you’ll need to adapt a few things for your board but you won’t run into the Windows path issue.

Aurelien

Hey experts,

I am also facing a similar issue. I am attaching the screenshot for your reference.


I’m using cc1352P for the project.

I’m currently using the TI-ARM-CLANG compiler as recommended in the Github
I’ve been in touch with @daschwar regarding this issue.
Kindly let me know if there is a fix for this issue.

Is it possible to work on the edge impulse project with the GCC compiler instead of the TI ARM CLANG compiler in Code Composer Studio?

Thanks all! I’ve filed an issue on that repo so we can track it.

Hi @MarcelSch and @Keerthivasan,

Yes, so this is a known issue in the repo readme for windows users. Keerthivasan originally reported & I’ve been chatting with TI on this for support, and thankfully I got some feedback and a workaround.

Basically, ccstudio works by compiling every single .c/cpp file in the project to an object file, and then passing them to the linker. The problem is that depending on what model you’ve output, lots of the tensorflow/cmsis kernel .o files aren’t actually used, but you still end up with a massive linker command (see the ORDERED_OBJS variable in <Project>/Release/makefile) that is >52000 characters. The windows command line has a hard limit at 32768 characters, and long path name support won’t fix this.

The workaround is that we need to modify the makefile generated by ccstudio to provide a .opt file of objects to the linker instead of writing them all inline. It turns out the IDE already generates this in <project>/Release/ccsObjs.opt, but the autogenerated makefile does not use it when invoking the linker.
With that, workaround steps are:

  1. Attempt to build your project normally, such that you have a <project>/Debug or <project>/Release directory. This will autogenerate a makefile for your project.
  2. Open Project->Properties->Build, and uncheck “Generate Makefiles automatically”
  3. Modify the line of <project>/Release/makefile that invokes the linker (for my test project, line 953), replacing $(ORDERED_OBJS) with @"./ccsObjs.opt"

Example of the resulting linker invocation from my resulting makefile:

###@Line 951
# Tool invocations
ei_simple_ble_5_30_CC1352P7_1_tirtos_ticlang.out: $(OBJS) $(CMD_SRCS) $(A_SRCS) $(GEN_CMDS)
	@echo 'Building target: "$@"'
	@echo 'Invoking: Arm Linker'
	"/Applications/ti/ccs1110/ccs/tools/compiler/ti-cgt-armllvm_1.3.0.LTS/bin/tiarmclang" @"/Users/das/ei_ccs_demo_workspace/ei_simple_ble_5_30_CC1352P7_1_tirtos_ticlang/Release/syscfg/ti_ble_app_config.opt" @"/Users/das/ei_ccs_demo_workspace/ei_simple_ble_5_30_CC1352P7_1_tirtos_ticlang/Release/syscfg/ti_build_config.opt" @"/Users/das/ti/simplelink_cc13x2_26x2_sdk_5_20_00_52/source/ti/ble5stack/config/build_components.opt" @"/Users/das/ti/simplelink_cc13x2_26x2_sdk_5_20_00_52/source/ti/ble5stack/config/factory_config.opt"  -mcpu=cortex-m4 -mfloat-abi=hard -mfpu=fpv4-sp-d16 -mlittle-endian -mthumb -Oz -DEI_CLASSIFIER_ALLOCATION_STATIC=1 -DEI_PORTING_TI=1 -DDeviceFamily_CC13X2X7 -DFLASH_ROM_BUILD -DNVOCMP_NWSAMEITEM=1 -gdwarf-3 -march=armv7e-m -Wl,-m"ei_simple_ble_5_30_CC1352P7_1_tirtos_ticlang.map" -Wl,-i"/Users/das/ti/simplelink_cc13x2_26x2_sdk_5_20_00_52/source" -Wl,-i"/Users/das/ti/simplelink_cc13x2_26x2_sdk_5_20_00_52/kernel/tirtos/packages" -Wl,-i"/Users/das/ei_ccs_demo_workspace/ei_simple_ble_5_30_CC1352P7_1_tirtos_ticlang/Release/syscfg" -Wl,-i"/Applications/ti/ccs1110/ccs/tools/compiler/ti-cgt-armllvm_1.3.0.LTS/lib" -Wl,--reread_libs -Wl,--define=FLASH_ROM_BUILD=2 -Wl,--diag_suppress=16002-D -Wl,--diag_suppress=10247-D -Wl,--diag_suppress=10325-D -Wl,--diag_suppress=10229-D -Wl,--diag_suppress=16032-D -Wl,--diag_wrap=off -Wl,--display_error_number -Wl,--warn_sections -Wl,--xml_link_info="ei_simple_ble_5_30_CC1352P7_1_tirtos_ticlang_linkInfo.xml" -Wl,--rom_model -o "ei_simple_ble_5_30_CC1352P7_1_tirtos_ticlang.out" @"./ccsObjs.opt" $(A_SRCS)
	@echo 'Finished building target: "$@"'
	@echo ' '
	@$(MAKE) --no-print-directory post-build

The total linker invocation is now only 1768 characters.

I’m adding this workaround to the repo readme and issue as well. I also think it should be possible to get the ccstudio makefile generation to do this automatically, but I’m still investigating.

Best,
David

2 Likes

if you facing problem with long path issue simply use the LongPathTool and fix easily your long path file problem