I have an C application on my raspberry pi running Rasbian that needs to publish to a mqtt broker. Now I found this
I cloned the repository and then ran
make and
sudo make install and the installation seems to have worked. If I include the header in my C file and compile;
#include "MQTTClient.h" it will compile without any problems. Then I added some
sample code and compiled again. This time I get a couple of errors sating undefined reference to various methods that should be located in MQTTClient.C So it seems to me that the linker somehow does find the h file but not the C file. I'm sorry if this is a stupid question, its just that I've been sitting with this for 2 hours now, unable to make it work.