<ZorPrime>
hello. Trying to compile the tools and tool chain for arm_cortex-a7_neon. Going by the "Build system usage" wiki page I did make menuconfig and set my target arch and platform. The tools build fails on libelf complaining 'checking whether overlapping arrays are copied correctly... yes
<ZorPrime>
https://pastebin.com/NezqNaki --- not sure what else I'm missing on specifying I'm trying to build for arm and not x64_86
minimal has quit [Quit: Leaving]
<slh>
you need to configure your target (make menuconfig) first, ideally also make a small full build for your target/ device (no need to flash it, just to have the basics built)
<ZorPrime>
slh: yeh I did make menuconfig first, and saved the .config file. I didn't do the full build. Will give that a go
<ZorPrime>
hmmm something funky with the make script somewhere. Turned up verbosity (-j1 V=s) and when it gets to libelf the target has not been changed ----- bash ./configure --target=x86_64-pc-linux-musl --host=x86_64-pc-linux-musl --build=x86_64-pc-linux-musl
Slimey has quit [Server closed connection]
Slimey has joined #openwrt-devel
<Slimey>
ew ID 13b1:003a Linksys AE2500 802.11abgn Wireless Adapter [Broadcom BCM43236]
<ynezz>
and this is a mine field, so before starting fixing those, there should be some unit tests in order to assure same output
<ynezz>
in other words, a lot of work
<mangix>
ynezz: I downloaded it as it seems to be failing on macOS. Running gcc's -fanalyzer is interesting. It mostly found missing malloc/fopen NULL checks
<mangix>
not sure if worth fixing.
<ynezz>
it is always worth fixing
<ynezz>
I've tried gcc's static analyzer as well, but it has produced way more false positives then clang's
<koukoutsi>
hi all, when testing a PR what the best way to have you custom build/config done and then all packages as modules just in case? is is just having two .config files (one with the extra "build all modules etc" settings?)?
<koukoutsi>
or maybe there is a quick way to do it in one go? (buildbot maybe??)
<koukoutsi>
so manage two configs. one for your image and a simple one with just the "build all modules" option eh?
<ynezz>
you can try with one config and run `make CONFIG_BUILDBOT=y`
<koukoutsi>
my personal image has a lot of options build inside
<koukoutsi>
aha!
<koukoutsi>
ynezz: so "make CONFIG_BUILDBOT=y" with build the default "menucofig" options or all the modules too?
user95 has quit [Ping timeout: 480 seconds]
<ynezz>
well, ideally you should've some diffconfig produced by `./scripts/diffconfig > myconfig`; then you should just `cp myconfig .config; printf 'CONFIG_BUILDBOT=y\n' >> .config; make defconfig` to populate it for buildbot check
<koukoutsi>
ok thanks!
user95 has joined #openwrt-devel
<f00b4r0>
wasn't there a copy of the QCA9533 datasheet publicly available somewhere? I'm trying to lookup the gpio multiplexer config
aiyion has quit [Remote host closed the connection]
aiyion has joined #openwrt-devel
<koukoutsi>
is there documentation of the builtroot vs openwrt differences or specific things added ?
<rmilecki>
koukoutsi: no, it's rather messy
<rmilecki>
koukoutsi: I think OpenWrt is based on old Linksys's fork of buildroot
<rmilecki>
and meanwhile we picked some recent upstream buildroot changes
<rmilecki>
and introduced our changes
Misanthropos has quit [Ping timeout: 480 seconds]
<jow>
current openwrt buildroot and buildroot.net only share the name
<jow>
by now OpenWrt buildroot is more or less proprietary
<f00b4r0>
ok, rb mapl-2nd ath79 support done. time to open PR
<koukoutsi>
rmilecki, jow : thank got it! I did check the offical buildroot but looked a lot different so I asked
romany has joined #openwrt-devel
rua has quit [Ping timeout: 480 seconds]
rua has joined #openwrt-devel
<stintel>
can I convince the gh CI to build with CONFIG_DWARVES=y ?
danitool has quit [Quit: Cubum autem in duos cubos, aut quadratoquadratum in duos quadratoquadratos]
srslypascal is now known as Guest784
srslypascal has joined #openwrt-devel
Guest784 has quit [Ping timeout: 480 seconds]
<ZorPrime>
hmmm... would anyone else might happen to know why the libelf automake/autoreconf insists on building for x86_64-pc-linux-musl instead of the target I specified in 'make menuconfig'?
<ZorPrime>
I can only assume I missed something in the directions, but haven't found any other gotchas
<stintel>
that's probably HostBuild ?
<ZorPrime>
this is my first shot at doing cross-compiling so not sure.
<ZorPrime>
wish my CS classes did more embedded stuff :P
<ZorPrime>
stintel: I'm following the directions at the 'Build a single package' wiki page
<stintel>
to be able to build a single package, you still need to build the toolchain and a bunch of other stuff first
<stintel>
and tools etc
<ZorPrime>
yep I get that, doing make tools/install goes swimmingly well until libelf
<stintel>
ok, make tools/install builds tools for the host, not for the target, so if you are building on x86 that's why you are seeing x86_64-pc-linux-musl there
<stintel>
it's probably best you pastebin the full output of your failure
<ZorPrime>
one min please
<stintel>
build with V=sc for verbose output
<stintel>
or BUILD_LOG=1 and get the log from logs/... then
<ynezz>
stintel: just modify that tools.yml and add the commands you need
goliath has quit [Quit: SIGSEGV]
<ZorPrime>
ok yeh so I am building on a laptop loaded with alpine, targeting ipq40xx generic. I'll have that pastebin in another min or so
<stintel>
ynezz: I booted an ubuntu vm to repro what ansuel reported wrt to tools/dwarves
<stintel>
turns out I cannot use HOST_BUILD_DEPENDS PKG_BUILD_DEPENDS in tools/
<stintel>
no idea how to fix this chicken or egg problem - dwarves requires elfutils/host
<stintel>
so the only thing I can think of is move dwarves to package/utils/... but that feels wrong if it's only going to build host stuff / tools
<ynezz>
don't you just need to add proper dependency chain to tools/Makefile?
<stintel>
how
<stintel>
there is nothing in tools/ that has dependencies at all
<ynezz>
line 40 # builddir dependencies
<stintel>
ynezz: from a quick glance these all appear to depend on things within tools/
<ynezz>
then I probably don't follow
<stintel>
so I can just add there $(curdir)/dwarves/compile := package/elfutils/host ?
<stintel>
ZorPrime: which version of OpenWrt are you trying to build?
<ynezz>
stintel: why it needs to go into tools?
<cbeznea>
is there a way to fetch build status from buildbot?
<ZorPrime>
v21.02.2 --- focusing on the cjdns package only, don't care about the rest
<cbeznea>
or to register somewhere in order to be notified about it?
<stintel>
ynezz: where else? it's required at kernel build time when KERNEL_DEBUG_INFO_BTF is enabled - it's not going to be a package for target
<stintel>
ZorPrime: looks like 21.02 might not like building on musl systems :(
cbeznea has quit [Read error: Connection reset by peer]
<ZorPrime>
stintel: bummer... should I use the docker image for dev work then?
<ZorPrime>
I've got docker installed
<stintel>
you could give that a try
cbeznea has joined #openwrt-devel
<stintel>
I don't even recall if we support building on musl hosts
<stintel>
and don't really have time to look into that now
<ZorPrime>
stintel: you've done more than enough thanks... just needed a hint
<stintel>
awesome :)
<ZorPrime>
I've got laptops sitting around I can just throw centos or something and run. Or do docker
<ZorPrime>
I'll look through the wiki further for the "preferred" build env
rua has quit [Ping timeout: 480 seconds]
rua has joined #openwrt-devel
<stintel>
I think most people use debian or ubuntu
Borromini has joined #openwrt-devel
bluetail has joined #openwrt-devel
<bluetail>
@stintel that has a good reason. Debian is capable of secureboot. And that is a nightmare to setup yourself and cost a bit of money. ArchLinux is not by default to name one.
<PaulFertser>
SecureBoot doesn't cost anything if you take the shim verbatim.
<PaulFertser>
And I do not think doing it the way ubuntu or debian does by default is anywhere near complicated. You just put shim to the efi system partition and change efi boot vars to use it.
minimal has joined #openwrt-devel
<bluetail>
@PaulFertser: Both Ubuntu or Debian support SecureBoot by default. You just can go ahead and use Rufus or Balena Etcher. With Arch? You have to sign the Kernel with your own enrolled Key through MOK manager and you are betting for problems
<PaulFertser>
bluetail: /or/ you can just do the same thing Debian does and boot the shim instead of signing anything of your own.
<bluetail>
How would you do that? "Warning: Replacing the platform keys with your own can end up bricking hardware on some machines, including laptops, making it impossible to get into the UEFI/BIOS settings to rectify the situation. This is due to the fact that some device (e.g GPU) firmware (OpROMs), that get executed during boot, are signed using Microsoft's key."
<PaulFertser>
bluetail: the shim is signed my MS keys, and shim boots unsigned grub.
<PaulFertser>
s/my/by/
<bluetail>
Is there a guide to read for using the verbatim shim to boot arch linux on systems with secureboot and uefi enabled?
hanetzer has joined #openwrt-devel
<PaulFertser>
bluetail: not sure about the guide but can you try just copying it and booting instead of grub?
<bluetail>
'it' meaning EFI bootfiles? Which ? I know how to mount the EFI.
<bluetail>
I have been using Ventoy with MokManager to boot some *.iso files that wouldnt boot otherwise. it fails far often as the Kernel isn't loaded. I enrolled a key and then I can boot for instance manjaro. But I cannot proceed for some reason - the installer aborts during installation. My solution? Use debian and create a live usb disk with persistent storage using rufus.
shibboleth has joined #openwrt-devel
<bluetail>
To clarify: installer breaks when partitioning. If I dare to install it though a virtualmachine on my physical disk in uefi mode, it wouldnt boot after, too.
<bluetail>
though/through
<PaulFertser>
bluetail: I have to admit I might be wrong about that regular shim being able to boot unsigned grub.
<bluetail>
I still don't know how - I felt lost in that guide earlier. But trying REFind boot manager and clover - both cant boot the bootloader - if tried, it says that I should load the kernel first.
<bluetail>
I don't have any access to the BIOS for exporting Keys, if that matters.
goliath has joined #openwrt-devel
Misanthropos has joined #openwrt-devel
danitool has joined #openwrt-devel
GNUmoon2 has joined #openwrt-devel
GNUmoon has quit [Read error: Connection reset by peer]
rua has quit [Ping timeout: 480 seconds]
rua has joined #openwrt-devel
GNUmoon2 has quit [Remote host closed the connection]
GNUmoon2 has joined #openwrt-devel
Acinonyx has quit [Quit: Peer reset by connector]
rua has quit [Remote host closed the connection]
rua has joined #openwrt-devel
Luke-Jr has quit [Ping timeout: 480 seconds]
<mangix>
stintel: all tools dependencies must be present within tools. Which means elftools must be under tools and dependency added under tools/Makefile
* stintel
forgets about getting these changes in before the freeze
jordbaer has joined #openwrt-devel
Luke-Jr has joined #openwrt-devel
<ZorPrime>
stintel: Got that docker build env going, got past the point where I was stuck. Host is ubuntu 20.04 based. Thanks again for the once over