简体   繁体   中英

Coocox Coide Compiler error : String index out of range: -1

I'm having problems with my project, I'm trying to build it and coocox coide gives me this error.


Building has encountered an error

an internal error occured during building:

An internal error occurred during: "Building". String index out of range: -1


It doesn't say where it happened or what triggered it ...

I looked all over and I can't find an answer for it, at least not for my situation.

Does anyone know how to fix this ? I could realy use help with this :/

I'm using:

CooCox CoIDE

Version: 1.7.7 Build id: 20140628-3328-1557

I also used CubeMx to generate my project, then manually inserted it into Coide.

you can download my project from here if that helps

https://1drv.ms/u/s!Ao4Ba524gyr6eDpD1FP6UonCjVo

Thanks in advance!

I have various built files open. I think it has sometimes problems to erase them. Even with the rebuild button, it (sometimes) gives an error at first (no popup window though)"something like: cannot delete files" and the second time I try it works. Maybe the build files that are erased need some time after they are deleted to be recognized by coide as deleted, and it returns an error if not done fast enough?! Well, also with the build button, sometimes pressing a second time works!

Hmm but it is not reliable... this is a work in progress.

follow up:

  • If there was a compile error, the build button works when building the next time.

  • If there was a link error, the build button doesn't work for the next compilation.

-interesting link with similar problem: http://www.coocox.org/forum/viewtopic.php?f=2&t=4145&start=15 (unfortunatly does not solve my issue)

I faced the same problem when I tried to build with a custom scatter file for the linker.

The link @lode provided solved the issue for me:

I had to remove every occurence of the string rom from the comments inside the .ld file. I replaced the word from with fr_om and voilà, issue resolved.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM