gpsd-users
[Top][All Lists]
Advanced

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

Re: Cross compile gpsd-3.20.1~dev for arm with buildroot


From: Florian Kiera
Subject: Re: Cross compile gpsd-3.20.1~dev for arm with buildroot
Date: Wed, 17 Jun 2020 17:38:27 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0

An update to the latest mail:

I found the reason why it doesn't work!

Somehow gpsd tries to install the python directory "gps" to STAGING_DIR/home/user/buildrootpath/output/host/lib/python2.7/site-packages/ instead of just the /home/user/buildrootpath/output/host/lib/python2.7/site-packages/ which causes gpsd to create the directories of user/buildrootpath/... etc and that created directory path is supposed to not be existing. Since it exists an unfortunate test of pkg-generic.mk is failing and causes the compiling to stop.

in pkg-generic.mk there is the following case:

define step_check_build_dir_one
        if [ -d $(2) ]; then \
                printf "%s: installs files in %s\n" $(1) $(2) >&2; \
                exit 1; \
        fi
endef

$(2) is this odd path that looks like it was falsely glued together "home/asterix/buildroot/buildroot-2020.05.2/output/host/arm-buildroot-linux-uclibcgnueabihf/sysroot//home/asterix/buildroot/buildroot-2020.05.2/output/host/lib/python2.7/site-packages/gps" and is supposed to fail. Since gpsd sadly created that path this test is successing and stops the whole buildroot compile. gpsd wasn't as innocent as I thought it would be... Still need to find out why gpsd uses that staging directory as root and not the usual root.

Regards Florian

Am 17.06.20 um 08:56 schrieb Florian Kiera:
Hey Gary!

Am 16.06.20 um 21:34 schrieb Gary E. Miller:
Yo Florian!

On Tue, 16 Jun 2020 17:08:35 +0200
Florian Kiera <florian.kiera@logicway.de> wrote:

Doesn't use LD anymore, so that works now! Thank you for fixing it!
Thank you for your patience.  It was a weird one.

The other issue regarding libtools; I guess it is coming from
python3/python2 conflicts...
Nope.  Your log shows scons built and installed everything fine.

 From your log.  Here is the last file installed:

Install file: "packaging/X11/gpsd-logo.png" as "/home/asterix/buildroot/buildroot-2019.02.8.1/output/host/arm-buildroot-linux-uclibcgnueabihf/sysroot/usr/share/gpsd/icons/gpsd-logo.png"
Here is sconss saying it is done building/installing:

scons: done building targets.
Yes, thats why I guess gpsd is innocent here (as well as it appears on other modules too).
Thsn, dunno where this comes from:

>>> gpsd 3.20.1~dev Fixing libtool files
for la in $(find /home/asterix/buildroot/buildroot-2019.02.8.1/output/host/arm-buildroot-linux-uclibcgnueabihf/sysroot/usr/lib* -name "*.la"); do \
    cp -a "${la}" "${la}.fixed" && \

From a pkg-generic.mk file that is basically used to iterate over the packages. Still its odd that it worked along with python2 but not python3. May its just the way "I update" the python... Cannot help myself differently yet.

It is NOT part of gpsd:

gpsd # fgrep linktool * -r
gpsd #

No libtool anywhere.

It is also NOT part of scons:

gpsd # fgrep libtool /usr/lib64/python3.6/site-packages/SCons/ -R
gpsd #

No libtool anywhere.

I'm still looking at it, may take a while for enlightenment.

I will try to remove python2 entirely
from our buildroot and than just stick to python3.
Does not matter.  scons uses the python that it started with.  Python
slotting works pretty well on all distros.  And your scons worked
seemingly perfectly for you.  You turned off all use of Python except
for scons.
Well using the common python2 didnt made me any trouble at all, so it must be python3 (adding python3 broke it all). I mean its maybe not clever to update python itself and leave the modules of python in the old dust; reason I am updating buildroot as whole at the moment to get a newer version (that should work fine with python3). And yes the libtool part isnt from gpsd but from buildroot. I dont know for sure what libtools purpose is, haven't saw it while compiling before. Might just have overlooked it since it all runs so fast through.

Either way it happens to multiple packages, since I am messing around
with python3, so gpsd might be innocent here...
You see this on packages that are not gpsd?  Looks to me like a bulidroot
problem.  A quick google shows several libtool issues with builtroot, but
I do not understand them.

Also from the build log:

     Applying 0001-SConstruct-do-not-force-O2-by-default.patch using patch:

You turn off -O2 several places, then turn it back on...
Yes. Neither do I yet!
Also the gpsd.mk if you wanna know what exactly is beeing done. (Its
the default one from the buildroot-2020.05 just with an edited
version)
Ugh.  I guess someone loves it somewhere...

gpsd does not support anything earlier than C99, so if this actually worked
if would break things:

     GPSD_CFLAGS += -std=gnu++98
     GPSD_CXXFLAGS += -std=gnu++98
Good to know! Weird it was used on gpsd-3.19. Will remove it for future compilations than.

Fixed port speed is gone:

ifeq ($(BR2_PACKAGE_GPSD_FIXED_PORT_SPEED),y)
GPSD_SCONS_OPTS += fixed_port_speed=$(BR2_PACKAGE_GPSD_FIXED_PORT_SPEED_VALUE)
endif

Other options are also gone.  You should recheck you mk file against
current bulid options.

Is fixed port speed necessary? What I basically wanna do is: run a M8P chip on 2 different boards, while one can be the base, the other one the rover and use PPS.

BR2 vars are set through make menuconfig and safed somewhere in Config.in files in buildroot, can paste that one here as well (there you will see several options are checked). Should've pasted that along with the .mk file here...

After all I know less than you why it isn't working yet, but I hope updating buildroot fixes it since it also uses python3 from the start.

I am wondering now if it is just the way I "updated" python2 to python3... May shouldve done that before compiling everything... Still think it wont fix the path issue.

pkg-generic.mk: If you want to have a look into the file

gpsd-settings.png the make menuconfig settings of what should be build with gpsd.

Regards Florian


reply via email to

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