On 15-02-17 04:34 AM, Christian Grothoff wrote:
Sounds to me like changing the return value is definitively the right
thing, currently that error merely obscures the other errors.
As for the undefined references, you might want to see if you're linking
correctly. Given that you are using a static version of the library,
moving it further back in the link order may help.
Thanks, I think you have pointed me in the right direction. But, now I
have encountered another problem: It seems internal.c in microhttpd.a
cannot find clock_gettime():
arm-linux-gnueabihf-g++ -o "gServer" ./utilities/json.o
./utilities/logger.o ./utilities/settings.o ./service/serv_stub.o
./comm/console.o ./comm/daemon.o ./comm/httpsrv.o ./comm/xhrq.o
./main.o -lpthread -lmicrohttpd
/home/robert/Development/platforms/arm-linux-gnueabihf/bin/../lib/gcc/arm-linux-gnueabihf/4.7.3/../../../../arm-linux-gnueabihf/lib/libmicrohttpd.a(libmicrohttpd_la-internal.o):
In function `MHD_monotonic_time':
/home/linuxium/dev/libmicrohttpd-0.9.39/src/microhttpd/internal.c:188:
undefined reference to `clock_gettime'
collect2: error: ld returned 1 exit status
make: *** [gServer] Error 1
Forgive my GNU ignorance. I have no idea what library contains
clock_gettime(), nor, how or if the linker is told to include this
library. I #included <time.h> ahead of #include <microhttpd.h>, to no avail.