gpsd-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

cross-compiling gpsd with yocto and toolchain


From: Guido Gavilanes
Subject: cross-compiling gpsd with yocto and toolchain
Date: Fri, 3 Apr 2020 19:10:45 +0200

Hello everyone,
I am trying to compile a program (lets call it "myprog") for an embedded platform (arm) using yocto (thud).
myprog uses the function ntp_read present in the library libgpsd.so. I have tested the code in a (quick and dirty) ubuntu on arm (with gpsd and library installed) and it works fine.

but on yocto, when I compile myprog, I find the error:
undefined reference to `ntp_read'. The compilation is linking libgpsd.so, but I see that libgpsd does not have the function ntp_read().
I have compared the libraries of ubuntu-arm and the one generated by yocto and they differ in that the function is not present into yocto library and it is present in the one from ubuntu on arm.
The recipe I am using for gpsd (yocto default) is this:
https://git.congatec.com/yocto/meta-openembedded/tree/sumo/meta-oe/recipes-navigation/gpsd/gpsd-3.17
With this libgpsd.so is also generated into the rootfs.
I used the SCONS parameters to set the ntpshm, ntp and pps to guarantee it is compiled with no errors, but I checked and ntp_read function is not present.
What should I do to make the libgpsd.so compilation to have the ntp_read? is there something I am probably missing to set up?

I have tried also to cross-compile gpsd from source using the yocto generated toolchain, but I found the error:
fatal error: gnu/stubs-soft.h: No such file or directory
and none of the solutions I have found on the Internet has changed this. (stackoverflow question)
I am stalled on this, in the case someone who knows gpsd code in deep might give me an idea of how to solve this, please let me know.
Thank you.


--
Guido


reply via email to

[Prev in Thread] Current Thread [Next in Thread]