Hello,
I am trying to compile the bubbleRobClient example in Eclipse. Same Code, I did no changes.
But I am only getting compiling errors. I included the include-folder and the remoteApi-folder to my project and I also did the preprocessor definitions.
Can you help me what I am missing?
Sneaker
Compiling Errors bubbleRobClient
Re: Compiling Errors bubbleRobClient
Hello Sneaker,
not sure what is wrong. Did you include the remote API via
?
Sometimes you have also to tell the compiler it is compiling C (and not C++) code for the remote API (i.e. by specifying for each remote API C file, that it should be handled as a C-file)
Cheers
not sure what is wrong. Did you include the remote API via
Code: Select all
extern "C" {
#include "extApi.h"
}
Sometimes you have also to tell the compiler it is compiling C (and not C++) code for the remote API (i.e. by specifying for each remote API C file, that it should be handled as a C-file)
Cheers
Re: Compiling Errors bubbleRobClient
There is a lot of config you first have to go to your extApi.h and define which os you're using be it _WIN32 or __LINUX or whatever and then #include "extApi.h" to all your other headers. Make sure you #define MAX_EXT_API_CONNECTIONS and NON_MATLAB_PARSING somewhere and link it to all your other headers too. This should narrow down the errors, then you it'll ask for things like winsock and threads you need to link your project to the library where windows.h is and link your project to where process.h because you use those for socket comm and making threads gl.
Re: Compiling Errors bubbleRobClient
thanks a lot for your answers..
After some hours of testing I figured it out.
The solution for my problem was rather easy and was actually already posted in this thread:
viewtopic.php?f=9&t=924&p=3414&hilit=pthread#p3414
I just had to specifically include the extApi.c and extApiPlatform.c files inside the extern "C" block:
Additionally I had to link the pthread library.
In eclipse:
1. Rightclick on project folder -> Properties
2. Add pthread library
I'm on ubuntu linux.
Sneaker
After some hours of testing I figured it out.
The solution for my problem was rather easy and was actually already posted in this thread:
viewtopic.php?f=9&t=924&p=3414&hilit=pthread#p3414
I just had to specifically include the extApi.c and extApiPlatform.c files inside the extern "C" block:
Code: Select all
extern "C" {
#include "extApi.h"
#include "extApi.c"
#include "extApiPlatform.c"
/* #include "extApiCustom.h" if you wanna use custom remote API functions! */
}
In eclipse:
1. Rightclick on project folder -> Properties
2. Add pthread library
I'm on ubuntu linux.
Sneaker