Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
10 years, 1 month ago.
Compiler error -230
I'm developing a CPP library for a LPC1768, that doesn't compile. I get the following message: 'Error: The build system did not finish successfully', with no references.
I could isolate the problem. It starts as soon as I add/uncomment the following, which looks like it fails if I use fread/fwrite:
fread(&this->buffer[this->index++], sizeof(uint8_t), 1, &this->handle);
or
result += fwrite(&start, sizeof(uint32_t), 1, &this->handle); result += fwrite(&frame->flags, sizeof(uint16_t), 1, &this->handle); result += fwrite(&frame->length, sizeof(uint16_t), 1, &this->handle); result += fwrite(&checksumHeader, sizeof(uint8_t), 1, &this->handle);
I tried to move it to another (new) project, without luck. If I introduce a syntax/checker error, it will point at the error as expected. That makes me believe the rest of the code is fine.
Can I find a full build log somewhere?
Edit:
As I tried to make an example with the lines commented, I fixed it due to an error in the example code. Changing my library code from
TinyLink::TinyLink(FILE& _handle, uint8_t* _buffer, size_t _length) : handle(_handle), buffer(_buffer)
into
TinyLink::TinyLink(FILE* _handle, uint8_t* _buffer, size_t _length) : handle(_handle), buffer(_buffer)
solved it all (of course, I updated the rest of the code (e.g. &this->handle into this->handle), but this is the important part). Still I don't know why I got such a vague error message.
Hi Bas, if you publish a simple program that reproduces this error, it'll make it much easier for someone to import, reproduce, fix and share the solution!
posted by Simon Ford 02 Oct 2014Small addition to Simon, or share a code snippet here, where is obvious types of variables used. The only log which is available is in the online IDE. You can always export your program to get full build log.
posted by Martin Kojtal 02 Oct 2014I just found out what caused the problem, when I was creating an example (I updated the question). I still believe mbed could improve on error reporting in this case.
posted by Bas Stottelaar 02 Oct 2014Hi Bas, great you found the problem. Please still consider publishing a test case where you had the problem so it can be reproduced and we can see if there is any way to improve the reporting or information associated with this error.
posted by Simon Ford 02 Oct 2014Hi Simon, I have published my program. The link is http://developer.mbed.org/users/basilfx/code/TinyLinkTest/.
The head revision is the working version, but if you checkout the initial revision, you'll get the broken code.
posted by Bas Stottelaar 02 Oct 2014