9 years, 7 months ago.

How can I compile a library that uses .cc, .pb.h, or other extensions?

I am trying to compile protobuf serialization code made for our serial client. We have all of the code and files, but trying to upload the two class files for the serial client (and the rest of the library), the mbed compiler refuses to accept file extensions other than .cpp and .h (Sorry if this question was answered already) We're wanting to use google's protobuf compiler to build a serial communications interface between our st-micro board and a SASL server for status updates. We currently have the library to interface with the board and the server, but they are in the files that mbed won't accept due to extension naming. Is there a way to ignore extensions? Otherwise, we will need to port the protobuf library to mbed by changing all of the file names and include lines to match.

Question relating to:

1 Answer

-deleted-
9 years, 7 months ago.

Hi Elijah,

The following extensions are supported currently on mbed - .h, .hpp, .c, .cpp, .s, .o.

Unfortunately at this time I cannot provide rough estimate when we could support the .cc, .hh extensions for the build system and exporters due to infrastructure changes. The Online IDE supports these on beta mode, but you won't be able to compile anyway.

Cheers,
Mihail

Accepted Answer

Mihail,

Currently when i try to use the .c extension, the compiler generates a lot of errors related to a number of mbed .h files. Is this an error by me?

posted by David Fletcher 26 Jan 2015