You are not logged in.
Hi
Sorry if this is in the wrong place!
I'm wanting to connect with anyone who might be able to steer me in the right direction to build using the arm-sdk for my rpi 4. I already use the live-sdk.
Thanks
Ozi
Offline
Hi.
For Raspi2, I just use a virtual Devuan ASCII macine for building, am follow the instructions in the arm-sdk Readme (with some initial quirks, that is).
Where are you stuck?
Last edited by b3bgd (2019-08-31 14:53:09)
Offline
I've emailed you.
Offline
Hi again. I'm gonna answer here directly, maybe others will find this useful too.
If you setup up an amd64 machine to build, everything will be OK, because the script will use cross-compiling to the correct arm architecture (armel/armhf/arm64) depending on your board.
Please look closely at the issues and merge requests on Git. For raspi 2 I found out the partitions were not aligned correctly and the kernel modules were not handled properly, resulting in an unusable image (the image posted on Devuan site right now for Raspi2 doesn't even boot). I fixed the problems, and made a merge request. For raspi 4 things seem in order, but there is a merge request for 4G RAM limit. You might want to look at that.
Also, something else to consider:
1. Even if not mentioned in the readme, you will also need the following packages on the build host installed:
quilt bison flex chrpath gawk texinfo libsdl1.2-dev whiptail diffstat cpio libssl-dev
2. On the arm image itself, after booting, you should create the groups for the bus interfaces, because they are not included:
groupadd --system spi
groupadd --system i2c
groupadd --system gpio
3. See net.ifnames in cmdline.txt and adjust as needed for predictable or classic net names - I myself find the old classic way more predictable on raspi, because it only has one interface of each type.
4. On the raspi 2 image at least, locales are kinda missing. Setting the keyboard doesn't work either.
Offline
@b3bgd Thank you for your very useful reply!
Is there anything in the sdk config file that needs to be changed?
And thanks for mentioning the merge request for 4G RAM limit.
Last edited by Ozi (2019-09-02 20:56:00)
Offline
Just trying to install the packages and found gcc-multilib and lib32z1 packages aren't in the debian repo, but they are in the Devuan repo.
Offline
Is there anything in the sdk config file that needs to be changed?
Well... a lot of things are missing: the /opt/vc tools (dtparam/dtoverlay, vcdbg, tvservice etc); installing libgl1-mesa-dri tries to install Radeon and geForce drivers; wpa_supplicant is missing config; groups mentioned above are not created; xrandr is missing; etc. So not sure what to say here, there are lots of things to fix with Devuan for arm. Btw, trying to set the variable to not compress images (forgot which it was) still creates the compressed images (but also leaves the original).
Lots of things to fix.
Offline
I've done the changes to the config.txt and cmdline.txt file to increase ram. And also noticed a line missing in config.txt in the merge request.
## memory shared with the GPU
gpu_mem=128
Where is the variable to set the compress option?
Offline
Where is the variable to set the compress option?
In your raspberry-pi4.sh, near the top, before function definitions, add the lines:
vars+=(nocompressimage)
nocompressimage="true"
Last edited by b3bgd (2019-09-04 04:34:36)
Offline
Ozi wrote:Where is the variable to set the compress option?
In your raspberry-pi4.sh, near the top, before function definitions, add the lines:
vars+=(nocompressimage) nocompressimage="true"
Is raspberry-pi4.sh a file I need to make, or is it init.sh?
I noticed that there are no blends in the arm-sdk repo. Has anyone done a blend for the rpi4? I've done blends for the live-sdk, are they the same?
Offline
Is raspberry-pi4.sh a file I need to make, or is it init.sh?
?
It's in /boards, e.g.:
https://git.devuan.org/b3bgd/arm-sdk/tree/master/boards
Offline
FYI I enabled ccache for compiling cache in my fork:
https://git.devuan.org/b3bgd/arm-sdk
Works like a charm, after the first build I get compiling times about 5x better. I needed this because I made round 50 builds from scratch in the last week or so.
P.S.: in that fork you will also find that I put vc tools for raspi 1 & 2 (because they are 32-bit, and there are no 64-bit executables and I don't know if they will work for 64-bit), and I fixed the raspi 2 image & modules.
Last edited by b3bgd (2019-09-06 12:38:04)
Offline
Would you consider pulling down the vc tools source and compiling, install the 64bit executables?
Offline
I've installed ccache, and I'm running ./init.sh now.
Offline
Now I'm running the build, no blend though.
Seems ok so far, it's just pulling in packages.
Offline
SHould I be running with using sudo?
/bin/sh: 1: bc: not found
Kbuild:42: recipe for target 'include/generated/timeconst.h' failed
make[1]: *** [include/generated/timeconst.h] Error 127
Makefile:1096: recipe for target 'prepare0' failed
make: *** [prepare0] Error 2
make: *** Waiting for unfinished jobs....
HOSTCC scripts/mod/sumversion.o
UPD scripts/mod/devicetable-offsets.h
HOSTCC scripts/mod/file2alias.o
HOSTCC scripts/bin2c
HOSTCC scripts/kallsyms
HOSTLD scripts/mod/modpost
HOSTCC scripts/pnmtologo
HOSTCC scripts/conmakehash
HOSTCC scripts/recordmcount
HOSTCC scripts/sortextable
HOSTCC scripts/asn1_compiler
HOSTCC scripts/extract-cert
[E] error in: clone-git https://github.com/raspberrypi/linux /home/ozi/arm-sdk/tmp/kernels/raspi4/raspi4-linux rpi-4.19.y
[W] called in: formatting root as ext4
[W] called in: grabbing raspi4-linux
[E] error reported, operation aborted.
DEPMOD 4.19.71-v8+
Warning: modules_install: missing 'System.map' file. Skipping depmod.
(*) grabbing raspi4-firmware
Offline
I installed bc which fixed this problem.
Offline
(*) installing qemu-user-static
(*) running debootstrap stage 2
chroot: failed to run command '/debootstrap/debootstrap': Exec format error
[E] error in: qemu_install_user
[W] called in: raspi4 build script loaded
[W] called in: running debootstrap stage 2
[E] error reported, operation aborted.
(*) writing system configuration
(*) running debootstrap stage 3
Offline
Would you consider pulling down the vc tools source and compiling, install the 64bit executables?
I don't have a 64-bit Raspberry at this point to test on... and also this:
Note that this repository does not contain the source for the edidparser and vcdbg binaries due to licensing restrictions.
SHould I be running with using sudo?
Yes of course! See the docs.
chroot: failed to run command '/debootstrap/debootstrap': Exec format error [E] error in: qemu_install_user [W] called in: raspi4 build script loaded [W] called in: running debootstrap stage 2 [E] error reported, operation aborted.
Run as root/with sudo? modprobe binfmt_misc? Do you see other errors above what you posted?
P.S.: I also clear the dist/ and tmp/ folders before each build. Just in case, because I spotted something weird happening a few times.
Last edited by b3bgd (2019-09-08 09:38:22)
Offline
I changed the repo to:
mirror="http://deb.devuan.org/merged"
# mirror="http://pkgmaster.devuan.org/merged"
From the log:
I: Extracting util-linux...
I: Extracting zlib1g...
(*) installing qemu-user-static
(*) running debootstrap stage 2
chroot: failed to run command '/debootstrap/debootstrap': Exec format error
[E] error in: qemu_install_user
[W] called in: raspi4 build script loaded
[W] called in: running debootstrap stage 2
[E] error reported, operation aborted.
(*) writing system configuration
(*) running debootstrap stage 3
. mounted sys
. mounted proc
. mounted dev
. mounted devpts
(*) chrooting to execute dpkgdivert...
chroot: failed to run command '/dpkgdivert': Exec format error
[E] error in: chroot-script dpkgdivert
[W] called in: mounted devpts
[W] called in: chrooting to execute dpkgdivert...
[E] error reported, operation aborted.
mv: cannot stat '/home/ozi/arm-sdk/tmp/devuan-arm64-build/bootstrap/dpkgdivert.log': No such file or directory
(*) chrooting to execute thirdstage...
chroot: failed to run command '/thirdstage': Exec format error
Offline
I have some parts of this missing. I'm going to re-do the clone and run ./init.sh again.
Offline
That didn't help, still getting a number of "Exec format errors"
Is there some config that needs to be done for the sdk or libdevuansdk?
Offline
Another git clone and the build seems to be doing ok. It's doing something with all sorts of drivers. No errors so far.
Offline
This was a much better build, still some errors though.
(*) chrooting to execute dpkgdivert...
chroot: failed to run command '/dpkgdivert': Exec format error
[E] error in: chroot-script dpkgdivert
[W] called in: mounted devpts
[W] called in: chrooting to execute dpkgdivert...
[E] error reported, operation aborted.
mv: cannot stat '/home/ozi/arm-sdk/tmp/devuan-arm64-build/bootstrap/dpkgdivert.log': No such file or directory
(*) chrooting to execute postbuild...
chroot: failed to run command '/postbuild': Exec format error
[E] error in: chroot-script dpkgdivert
[W] called in: mounted devpts
[W] called in: chrooting to execute postbuild...
[E] error reported, operation aborted.
mv: cannot stat '/home/ozi/arm-sdk/tmp/devuan-arm64-build/bootstrap/postbuild.log': No such file or directory
(*) chrooting to execute dpkgdivert...
chroot: failed to run command '/dpkgdivert': Exec format error
[E] error in: chroot-script dpkgdivert
[W] called in: mounted devpts
[W] called in: chrooting to execute dpkgdivert...
[E] error reported, operation aborted.
mv: cannot stat '/home/ozi/arm-sdk/tmp/devuan-arm64-build/bootstrap/dpkgdivert.log': No such file or directory
. umounted devpts
. umounted dev
. umounted proc
. umounted sys
(*) setting up isolinux
. copying kernel and initrd
iso_setup_isolinux:10: no matches found: /home/ozi/arm-sdk/tmp/devuan-arm64-build/bootstrap/boot/vmlinuz*
iso_setup_isolinux:11: no matches found: /home/ozi/arm-sdk/tmp/devuan-arm64-build/bootstrap/boot/initrd*
cp: cannot stat '/home/ozi/arm-sdk/extra/syslinux/isolinux.bin': No such file or directory
[E] error in: iso_setup_isolinux
[W] called in: copying kernel and initrd
[W] called in: setting up isolinux
[E] error reported, operation aborted.
iso_setup_isolinux:15: no matches found: /home/ozi/arm-sdk/extra/syslinux/*.c32
[E] error in: iso_setup_isolinux
[W] called in: copying kernel and initrd
[W] called in: setting up isolinux
[E] error reported, operation aborted.
(*) writing isolinux configuration
(*) creating squashfs out of strapdir
sudo: mksquashfs: command not found
[E] error in: iso_squash_strap
[W] called in: copying kernel and initrd
[W] called in: creating squashfs out of strapdir
[E] error reported, operation aborted.
(*) building iso...
sudo: xorriso: command not found
[E] error in: iso_xorriso_build
[W] called in: copying kernel and initrd
[W] called in: building iso...
[E] error reported, operation aborted.
[E] error in: load devuan raspi4
[W] called in: raspi4 build script loaded
[W] called in: ccache is enabled
Last edited by Ozi (2019-09-10 21:12:45)
Offline
~/arm-sdk/lib/libdevuansdk/config
# mirror="http://pkgmaster.devuan.org/merged"
mirror="http://deb.devuan.org/merged"
Last edited by Ozi (2019-09-10 21:12:29)
Offline