Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


rebuild finished, went into a container, installed the sdk, sourced the environment-setup, and now `make` isn't there anymore :tizzy:

e:

hobbesmaster posted:

to link against
gently caress i knew it was something obvious, why'm i so drat stupid :bang:

Ciaphas fucked around with this message at 01:13 on Nov 13, 2022

Adbot
ADBOT LOVES YOU

FlapYoJacks
Feb 12, 2009

Poopernickel posted:

Buildroot is a 2007 Kia Sentra, and Yocto is that car that Homer Simpson designed

Buildroot is a 2022 Kia Sentra. :colbert:

Poopernickel
Oct 28, 2005

electricity bad
Fun Shoe
When you build the SDK, it spits out a self-extracting installer. You can give it to other devs who want to write code for your system, but don't want to gently caress around with Yocto.

The SDK gets the compiler, headers/static/dynamic libs that match what goes into your target image, and also anything else you add to TOOLCHAIN_TARGET_TASK.

Phobeste
Apr 9, 2006

never, like, count out Touchdown Tom, man

hobbesmaster posted:

to link against

or to qemu with

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


Poopernickel posted:

When you build the SDK, it spits out a self-extracting installer. You can give it to other devs who want to write code for your system, but don't want to gently caress around with Yocto.

The SDK gets the compiler, headers/static/dynamic libs that match what goes into your target image, and also anything else you add to TOOLCHAIN_TARGET_TASK.

yeah i wasn't getting - somehow - that the toolchains build apps using the target's set of libraries, but those libraries are not* the same set of libraries that lets the toolchains actually run in the first goddamn place

* necessarily

Ciaphas fucked around with this message at 01:20 on Nov 13, 2022

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


go commands work in the sdk now, but when i try and actually build the app this is all for, it can't get & install any of the deps like gomock

code:
▶ installing go tools
go install github.com/golang/mock/mockgen
go: downloading github.com/golang/mock v1.6.0
go: downloading golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4
go: downloading golang.org/x/tools v0.1.12
go: downloading golang.org/x/sys v0.0.0-20220907062415-87db552b00fd
/root/go/pkg/mod/golang.org/x/tools@v0.1.12/internal/imports/imports.go:12:2: package bufio is not in GOROOT (/poky/sysroots/x86_64-pokysdk-linux/usr/lib/go/src/bufio)
/root/go/pkg/mod/github.com/golang/mock@v1.6.0/mockgen/mockgen.go:22:2: package bytes is not in GOROOT (/poky/sysroots/x86_64-pokysdk-linux/usr/lib/go/src/bytes)
/root/go/pkg/mod/golang.org/x/tools@v0.1.12/internal/gocommand/invoke.go:10:2: package context is not in GOROOT (/poky/sysroots/x86_64-pokysdk-linux/usr/lib/go/src/context)
/root/go/pkg/mod/github.com/golang/mock@v1.6.0/mockgen/reflect.go:21:2: package encoding/gob is not in GOROOT (/poky/sysroots/x86_64-pokysdk-linux/usr/lib/go/src/encoding/gob)
/root/go/pkg/mod/github.com/golang/mock@v1.6.0/mockgen/mockgen.go:23:2: package encoding/json is not in GOROOT (/poky/sysroots/x86_64-pokysdk-linux/usr/lib/go/src/encoding/json)
[etc]
:cry:

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


this is all a massive loving waste of time and sanity, isn't it? can't I just not put go in the sdk, and instead install it as part of the dockerfile that builds the container the sdk is installed in?

hobbesmaster
Jan 28, 2008

what exactly are you trying to do? do you think you can “just” use a recipe like this and not bother with the SDK?

https://blog.gopheracademy.com/advent-2015/go-in-a-yocto-project/

or do you need this go environment to be installable? the bitbake class that article is referring to is built in. (look in meta/class)

I remember helping a couple customers set up go for the armv5 routers at my last job but all my language specific yocto memories right now are taken up by the butcher job they did on python

outhole surfer
Mar 18, 2003

nudgenudgetilt posted:

yocto. not even once.

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


let me go over the problem this all started with that we're actually trying to solve, in case someone sees i reached a really stupid conclusion for fixing it:

- we have an app written in Go, with a smattering of C built by CGo, that runs on the target device
- said target device runs some kinda intel processor, at least at this time; no idea if it'll stay that way in the future but i'm guessing it will
- originally we were building our target image & SDK from Yocto 3.something. it didn't include golang, that came from `FROM golang-1.19` at the top of the sdk container's dockerfile. this was apparently working fine
- recently, before i got involved, we started trying to build from Yocto 4.0.4 instead, to get a whole bunch of dependencies updated all at once
- our Go app could still build, but testing no longer worked - generating mocks started breaking down with errors about GLIBC_2.32. i don't have the exact message in front of me rn, but it specifically only happened on those mocks - specifically the ones needing CGo, a coworker thinks
- we tried dicking around in the sdk container with ldconfig, symlinks from /poky, etc. etc - results ranged from "didn't help" to "not even ls runs anymore"
- i thought, maybe trying to use go from a stock docker image to build for our targets only worked by library versions coincidentally lining up before the yocto upgrade, and we couldn't just use the go distribution from the stock docker go-1.19 base image anymore
- and so i started this misadventure with trying to add go to the image recipe's IMAGE_INSTALL. which did install go, but yocto 4.0.4's go is at 1.17, and the team needs 1.19
- finally, figuring out upgrading that is where I came into the thread yesterday

fast forward to today where i'm just plain mad at everything but especially despairing at myself

Ciaphas fucked around with this message at 02:18 on Nov 13, 2022

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:



yes we get it thank you

Phobeste
Apr 9, 2006

never, like, count out Touchdown Tom, man
i'm confused, what's the output artifact of the yocto build? a container image? half a container image? a disk image that gets slapped in a container and loopback mounted?

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


a squashfs for the target machines*, and a sdk .sh for the devs

* there's some Magic i don't understand going on, to do with some kind of initramfs thing, but the end result is the squashfs is essentially mounted to / on the target machine at boot. don't think it's strictly relevant to my problem

Ciaphas fucked around with this message at 03:36 on Nov 13, 2022

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


idk if this'll help even a little but here's the original error from the failing software build that set me off on this whole stupid misadventure

code:
lumos-dev:/workspaces/lumos# make gen
▶ installing go tools
go install github.com/golang/mock/mockgen
[...]
cd lumos/test/mocks && go generate .
/workspaces/lumos/lumos/test/mocks/gomock_reflect_2146178304/prog.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by /workspaces/lumos/lumos/test/mocks/gomock_reflect_2146178304/prog.bin)
/workspaces/lumos/lumos/test/mocks/gomock_reflect_2146178304/prog.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by /workspaces/lumos/lumos/test/mocks/gomock_reflect_2146178304/prog.bin)
/workspaces/lumos/lumos/internal/components/gomock_reflect_84173287/prog.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by /workspaces/lumos/lumos/internal/components/gomock_reflect_84173287/prog.bin)
/workspaces/lumos/lumos/internal/components/gomock_reflect_84173287/prog.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by /workspaces/lumos/lumos/internal/components/gomock_reflect_84173287/prog.bin)
prog.go:14:2: no required module provides package github.com/SpectraLogic/lumos/lumos/internal/components: go.mod file not found in current directory or any parent directory; see 'go help modules'
prog.go:12:2: no required module provides package github.com/golang/mock/mockgen/model: go.mod file not found in current directory or any parent directory; see 'go help modules'
2022/11/09 22:07:09 Loading input failed: exit status 1
generate.go:15: running "mockgen": exit status 1
make: *** [lumos.mk:82: test-gen] Error 1

hobbesmaster
Jan 28, 2008

quote:

/lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32

it’s looking for the host libc, not the target’s

I’m not familiar enough with typical go builds but you’re calling make so I’m guessing there was a configure script run that picked up go in the sysroot but not the cross CC

fins
May 31, 2011

Floss Finder

Ciaphas posted:

idk if this'll help even a little but here's the original error from the failing software build that set me off on this whole stupid misadventure

code:
lumos-dev:/workspaces/lumos# make gen
▶ installing go tools
go install github.com/golang/mock/mockgen
[...]
cd lumos/test/mocks && go generate .
/workspaces/lumos/lumos/test/mocks/gomock_reflect_2146178304/prog.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by /workspaces/lumos/lumos/test/mocks/gomock_reflect_2146178304/prog.bin)
/workspaces/lumos/lumos/test/mocks/gomock_reflect_2146178304/prog.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by /workspaces/lumos/lumos/test/mocks/gomock_reflect_2146178304/prog.bin)
/workspaces/lumos/lumos/internal/components/gomock_reflect_84173287/prog.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (required by /workspaces/lumos/lumos/internal/components/gomock_reflect_84173287/prog.bin)
/workspaces/lumos/lumos/internal/components/gomock_reflect_84173287/prog.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by /workspaces/lumos/lumos/internal/components/gomock_reflect_84173287/prog.bin)
prog.go:14:2: no required module provides package github.com/SpectraLogic/lumos/lumos/internal/components: go.mod file not found in current directory or any parent directory; see 'go help modules'
prog.go:12:2: no required module provides package github.com/golang/mock/mockgen/model: go.mod file not found in current directory or any parent directory; see 'go help modules'
2022/11/09 22:07:09 Loading input failed: exit status 1
generate.go:15: running "mockgen": exit status 1
make: *** [lumos.mk:82: test-gen] Error 1

glibc errors always suck, regardless of build system

this might help?

https://utcc.utoronto.ca/~cks/space/blog/programming/GoAndGlibcVersioning

FlapYoJacks
Feb 12, 2009
Good lord. Everytime I see someone seek help for Yocto I am glad I chose Buildroot as my embedded Linux BSP of choice.

Want an SDK? “make sdk”
want to rebuild a package? “make $pkg_name-reconfigure”

Yeah, it’s not as powerful as Yocto and doesn’t build a distribution (Buildroot is a firmware generator not a distribution builder) but it works quite well and I will never willingly choose Yocto over Buildroot. :v:

Ciaphas
Nov 20, 2005

> BEWARE, COWARD :ovr:


i think the final answer is that the docker image i'm installing the sdk in has to be changed to use a glibc version >= the target image's glibc, without regard for the glibc installed in the SDK's host or target sysroots

this is because - and maybe this was obvious, but it's only now becoming clear to my addled-rear end mind - our go project builds things that run as part of the build; stuff like mockgen, but also the stuff compiled by `go test` because of us needing CGo support. so end result is our build container, on glibc 2.31, builds these intermediaries targeting glibc 2.35 to match the target hardware, then tries to run these programs made for a newer glibc while running off the older glibc - with the results you'd expect

what I'd been misunderstanding is, I thought sourcing the poky environment setup also swapped out the host (the build container)'s active glibc with the one in the poky sysroot - which is evidently not actually the case. idk if that's expected behavior or if we've got something misconfigured somewhere; but frankly now that i understand the real problem, I don't actually care anymore

now i just gotta find a container in docker.io with glibc 2.35 and go 1.19, use that instead of golang:1.19, and the problem's solved. (put that way, the whole problem seems so goddamn obvious in retrospect... :eng99:)

(e) can i shoot the devs for using a mock generator or is that just normal nowadays

Ciaphas fucked around with this message at 10:08 on Nov 15, 2022

hobbesmaster
Jan 28, 2008

can this be thread you bump every time you’re hosed by the sstate-cache? because… yeah

FlapYoJacks
Feb 12, 2009

hobbesmaster posted:

can this be thread you bump every time you’re hosed by the sstate-cache? because… yeah

Absolutely.

MrMoo
Sep 14, 2000

Embedded with a display is surprisingly an incredibly underserved market considering the number of tiny screens out there. I hate all the options.

I want Electron in an embedded image with easy updates. Somehow after many years of existence this still isn’t a thing.

At the Yocto level there is embedded WebKit, which by name is gimped and missing the NodeJS stack. At higher levels, Ubuntu Core doesn’t seem to have any packages that can use the GPU and is all a proprietary soup of Snap packages. Fedora IoT doesn’t seem to have any X11 support, hopefully is better in the upcoming 38 release. Fedora Silverblue has all gimped packages with no GPU support too.

Flatpak on Ubuntu Core can use the GPU, but obviously Ubuntu want to completely fix that by removing support for Flatpak. Apparently third party packages Firefox on Silverblue supports the GPU though.

Embedded platform + immutability + GPU = 💩

It is even worse than normal because you cannot really run in a VM because all the VM vendor GPUs are blacklisted due to a plethora of bugs and bad support.

MrMoo fucked around with this message at 00:08 on Mar 27, 2023

hobbesmaster
Jan 28, 2008

what general type of hardware?

Shaggar
Apr 26, 2006

MrMoo posted:

Embedded with a display is surprisingly an incredibly underserved market considering the number of tiny screens out there. I hate all the options.

I want Electron in an embedded image with easy updates. Somehow after many years of existence this still isn’t a thing.

At the Yocto level there is embedded WebKit, which by name is gimped and missing the NodeJS stack. At higher levels, Ubuntu Core doesn’t seem to have any packages that can use the GPU and is all a proprietary soup of Snap packages. Fedora IoT doesn’t seem to have any X11 support, hopefully is better in the upcoming 38 release. Fedora Silverblue has all gimped packages with no GPU support too.

Flatpak on Ubuntu Core can use the GPU, but obviously Ubuntu want to completely fix that by removing support for Flatpak. Apparently third party packages Firefox on Silverblue supports the GPU though.

Embedded platform + immutability + GPU = 💩

It is even worse than normal because you cannot really run in a VM because all the VM vendor GPUs are blacklisted due to a plethora of bugs and bad support.

the last thing anything embedded needs is javascript

hobbesmaster
Jan 28, 2008

Shaggar posted:

the last thing anything embedded needs is javascript

lol if JavaScript is the worst thing you can think of to ship in 2023

Shaggar
Apr 26, 2006
it litterrally is

Shaggar
Apr 26, 2006
unless you're separating javascript from its underlying tooling/runtimes in which case yes those are worse

Phobeste
Apr 9, 2006

never, like, count out Touchdown Tom, man
I got electron running ok on a yocto build. the key is kind of bypassing yocto for the electron build part (although someone with more time and brains than me could do it). Run electron builder in your recipe for the linux-arm64 arch and it'll pick up the right prebuilds, and it's version controlled up to hash locking via language package control files like yarn.lock or whatever. The pain was getting it to play nicely with appropriate mesa stuff but you can now get it to run on wayland and so on with appropriate flags

hobbesmaster
Jan 28, 2008

Shaggar posted:

it litterrally is

use more imagination

Phobeste
Apr 9, 2006

never, like, count out Touchdown Tom, man
IMO there's in general tension between modern language setups that do their own dependency management and system builders like yocto or buildroot. i think i might have talked about it before in here. like whatever your opinions on the js ecosystem or the python ecosystem, there are language-native tools that your application developers expect to use that do things like separated "what version will i allow automated updates for and expect a minimal level of oversight to tolerate" (roughly the same as whether you'd be comfortable pulling upstream buildroot or some yocto layer) and "in a given build, use exactly these package versions by hash" (what you get in a given buildroot or yocto build). the only solution is for yocto or buildroot to ingest those tools' specification files but I think nobody wants to deal with that because it's still not _that_ common

Shaggar
Apr 26, 2006

this page doesnt even load, but whatever it is its not worse than javascript

Phobeste
Apr 9, 2006

never, like, count out Touchdown Tom, man
ye it is

hobbesmaster
Jan 28, 2008

I choose to believe the page did load and shaggar’s mind is unable to process it

Shaggar
Apr 26, 2006
adobe air is litterrally javascript

Shaggar
Apr 26, 2006
Like adobe air is probably better than electron because its out of date and hasnt caught up to all the latest web "developer" abominations

FlapYoJacks
Feb 12, 2009
Yeah, the generally accepted best practice for UI is QT QML

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face
emuelec seems to be some kind of custom debian

hobbesmaster
Jan 28, 2008

Shaggar posted:

adobe air is litterrally javascript

as well as..

FlapYoJacks
Feb 12, 2009
Also, Buildroot LTS 2023.02 is out with QT6!

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face

Shaggar posted:

this page doesnt even load, but whatever it is its not worse than javascript

lol it does load

it's flash. in 2023

quote:

HARMAN also provide enterprise support for the Adobe Flash Player. Following the 'end of life' of the Adobe deployment at the end of 2020, and the removal of the Flash Player deployments in Windows by Microsoft, HARMAN are still able to provide updated versions of the Flash Player, version 50.0, to enterprse customers under special license terms.

Other than Internet Explorer - and Edge with IE Mode - the browsers have removed support for plug-ins and so HARMAN also have 'packaged browser' solutions to enable web applications to still be viewed. Alternatively, a WebAssembly-based virtualisation layer called CheerpX for Flash is available from a third party company that can host our Flash Player within a modern browser.

Click here for more details of our Flash Player offerings.

cheerpx vm :shepface:

Adbot
ADBOT LOVES YOU

Beeftweeter
Jun 28, 2005

a medium-format picture of beeftweeter staring silently at the camera, a quizzical expression on his face
why did harman kardon take over flash development lol

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply