PelionIoT / simple-mbed-cloud-client

Simple interface for Mbed Cloud Client - deprecated
Apache License 2.0
7 stars 21 forks source link

Short term fix for Windows Path length limit #30

Closed MarceloSalazar closed 4 years ago

MarceloSalazar commented 6 years ago

There are known issues due to the Windows path limit. Even installing the app in the root directory (c:) causes problems when running the tests. Is unclear when exactly this will be fixed.

In the meantime, we need a short-term fix. I can think of a few options (could be combined)

  1. Rename to "simple-mbed-cloud-client" to "spdmc"
  2. Move MCC library out and put it at same level as the SMCC library. The application would integrate the two libs. People could potentially upgrade MCC themselves.
  3. Other? Unknown

@janjongboom @bridadan @screamerbg

Please share your thoughts asap.

janjongboom commented 6 years ago

So this is something that MCC users will also run in to; how are they fixing it?

In example applications we can rename the .lib file to smcc.lib then CLI will extract it to shorter path but this is a (terrible?) workaround.

Terrible idea. MCC and SMCC are tied together and mixing random versions will lead to horror.

MarceloSalazar commented 6 years ago

Both seem to be terrible solutions/workarounds :-( The first one seems to be easier with less impact... Any other thoughts?

MarceloSalazar commented 6 years ago

https://github.com/ARMmbed/simple-mbed-cloud-client-template-restricted/issues/17

andrewc-arm commented 5 years ago

Hi, I wrote following comment below and realized that there is still a Windows command length issue. Please ignore my previous comment.

I had compile error in Windows while Linux worked well. I dug down and found out that auto created include text file such as ".includes_b46ec795e227862d4efaf4d025dcc3ef.txt" had path delimiter wrong. It had Unix delimter of '/' while it should have been '' for Windows. After this, my Windows command got past the issue of arm-none-eabi-g++: error: CreateProcess: No such file or directory I will try to find out where we can change the delimiter for Windows. This is important because for the automated testing, we may use Arm Keil compiler which only runs in Windows.

Regardless of delimiter, the compiler wisely took the ".includes.txt" file and found right include paths. Sorry for causing any confusion. :)

MarceloSalazar commented 5 years ago

See internal discussion: IOTCORE-253

screamerbg commented 5 years ago

This is only a problem when running the tests with GCC_ARM, but it's not when compiling an example program.

Alex-EEE commented 5 years ago

You guys know that on Windows 10 you can fix the path limit with a registry key, right?

MarceloSalazar commented 5 years ago

hi @Alex-EEE thanks for sharing this. Indeed, there is an option in the Windows registry. But doesn't seem enough to run 'mbed test' as we hit ToolException: arm-none-eabi-g++: error: CreateProcess: No such file or directory

Alex-EEE commented 5 years ago

Interesting that I came upon this today, we were actually having the same problem with greentea recently using IAR. It felt like a path size limit, but didn't make sense given the registry key fix. Does anyone know what the limit is with the registry option, or if there's some reason the registry key isn't working? We resorted to the same thing you guys are...refactoring things to shorten paths :-(