galmon icon indicating copy to clipboard operation
galmon copied to clipboard

Build tiny `ubxtool` docker image and a binary depending on just glibc

Open darkk opened this issue 6 years ago • 3 comments

That's useful to avoid native compilation on a Raspberry Pi itself while running a galmon probe.

That may also kinda reduce @akhepcat's pain of slow native compilation on RPi mentioned at #48.

Please, tell me if build-ubxtool should rather be a Makefile target.

darkk avatar Dec 23 '19 20:12 darkk

just building ubxtool is probably fine for most folk for sure - definitely on the rPi, which is probably the majority of install cases. And why spin up a huge vm/docker just for one binary, if you don't have to?

akhepcat avatar Dec 23 '19 20:12 akhepcat

Exactly! I also prefer to copy a bare binary to the rPi, but someone may prefer a tiny* docker image (e.g., if they already have some kind of docker-based services on the pi), and the image comes "for free" as a byproduct of the build process.

*) galmon image with all the deps and build tools is 728 MiB, ubxtool image is ~ 18 MiB, ubxtool.nodeps.x86_64 binary is 12 MiB (not stripped).

darkk avatar Dec 23 '19 20:12 darkk

I've updated the code to produce the binary that works on Raspberry Pi 1 B+ (and Zero) as well. I faced couple of issues while doing that:

clang-8 and recent clang-10 should not be affected.

Maybe I've done something wrong, I have known almost nothing about the difference between CPU/FPU of various Pi boards before yesterday. :-) The binaries produced by the script runs at stations 50, 51 and 52 without noticeable issues. Following links helped me to understand what was going on:

darkk avatar Feb 02 '20 12:02 darkk