Commit Graph

210 Commits

Author SHA1 Message Date
Gunjan Gupta
a747ba2c37 Only install gcc-or1k-bin package when building images with crust-firmware support 2023-06-26 20:54:55 +02:00
Ricardo Pardini
6c232a1303 grub: add hooks, fix GRUB font & wallpaper, introduce grub-with-dtb extension
- introduce hooks `grub_early_config`, `grub_pre_install` and `grub_late_config`
  - what we see here is an extension that itself has hooks, that just works
- introduce extension `grub-with-dtb`, which
  - enables `grub` extension
  - requires `BOOT_FDT_FILE` to be set
  - includes `/etc/armbian-grub-with-dtb` with `BOOT_FDT_FILE=` in the bsp-cli
  - includes `/etc/kernel/postinst.d/armbian-grub-with-dtb` in the bsp-cli
     - which reads the above and creates links for `/boot/armbian-dtb-<version>` when deploying deb's
  - adds implementations of the hooks above to
    - replace the distro's `10_linux` with our own `09_linux_with_dtb`
      - which looks for `/boot/armbian-dtb-<version>`
    - forcibly run  `/etc/kernel/postinst.d/armbian-grub-with-dtb` during image build, since bsp-cli is installed after linux-image
- uefi-arm64: enable GRUB wallpaper by setting `UEFI_GRUB_TERMINAL=gfxterm`
- force GRUB_FONT so Ubuntu is not confused and gfxterm (incl wallpaper) finally works
2023-06-26 13:52:29 +02:00
Ricardo Pardini
017a006acb cleanup-space-final-image: keep qcom and qed firmware (for thinkpad-x13s) 2023-06-26 13:47:00 +02:00
Gunjan Gupta
8278dc5e42 allwinner: Enable crust compilation 2023-06-20 21:36:31 +02:00
Ricardo Pardini
44e547d6a8 armbian-gaming customize launcher for @NicoD-SBC (v2)
- add image suffix `-gaming`
2023-06-12 10:47:15 +02:00
Ricardo Pardini
a9cc0620ec bluetooth-hciattach: new generic extension to facilitate adding hciattach systemd service, given the correct params 2023-05-24 19:22:22 +02:00
Ricardo Pardini
89a7cc971b grub: fixes for wallpaper / gfxmode / submenu /etc
- Debian working
- Ubuntu's grub needs more work
2023-05-21 16:18:20 +02:00
Igor Velkov
9b68c4e42a Add support for nilfs2 fs based image
Signed-off-by: Igor Velkov <iav@iav.lv>
2023-05-16 08:51:05 +02:00
Pander
9ed24a6e86 extension fake-vcgencmd 2023-05-03 15:10:18 +02:00
Ricardo Pardini
ba413c9b25 bcm2711/grub: add busybox (for initrd grep/sed) so initramfs-growroot works again on Debian
- bcm2711: bomb early when `RELEASE` is set and not supported
2023-04-28 21:32:52 +02:00
Ricardo Pardini
5ad3caefee extensions: introduce u-boot-menu extension, for use with extlinux
- this is using the default Debian/Ubuntu package, we probably should replace that with our own scripts
2023-04-28 21:32:52 +02:00
Ricardo Pardini
01c49e0cf1 grub: keep u-boot stuff if UEFI_GRUB=yes 2023-04-28 21:32:52 +02:00
Ricardo Pardini
2b28f29ebe rootfs/image: avoid apt junk leftover by debootstrap; add warnings and debugs over target cache and general rootfs sizes
- rootfs: rootfs-create: show a summary of the 20 biggest dirs, right before tarring the rootfs (for debugging)
- rootfs: rootfs-create: show usage of caches between first and second stages
- rootfs: rootfs-create: cleanup junk left by `debootstrap` after second stage
- rootfs: rootfs-create: _always_ clean apt stuff at the end
- rename `apt_purge_unneeded_packages()` to `apt_purge_unneeded_packages_and_clean_apt_caches()` for clarity
- image: `apt_purge_unneeded_packages_and_clean_apt_caches()`: warn if apt caches not empty; clean them off, always.
- host-utils: `local_apt_deb_cache_prepare()`: also test the target, warn if not empty
- extension: cleanup-space-final-image: do NOT clean apt stuff. done in core now
- the metric shit-ton of debugs added should help the next person who faces this in the future
2023-04-18 16:27:06 +02:00
Ricardo Pardini
a140bf1339 extensions: add v4l2loopback-dkms, very similar to the zfs extension
- Raison d'être: prove `linux-headers` work, at least, minimally
2023-04-15 22:43:33 +02:00
Ricardo Pardini
14286c018c extensions: rkdevflash: switch to using Radxa's fork of rkdeveloptool, which has compile fixes 2023-04-15 22:43:19 +02:00
Ricardo Pardini
f8402a59da extensions: rkdevflash: simplify usage of rkdeveloptool (on Linux only, not Docker) to flash Rockchip images to eMMC 2023-04-15 22:43:19 +02:00
Ricardo Pardini
439882ce7a extensions/grub: use array for pkg list
- also for the media-sbc clone
2023-04-15 22:43:06 +02:00
Ricardo Pardini
f6f621b9a1 extensions: don't export, declare -g 2023-04-15 22:43:06 +02:00
Ricardo Pardini
6f57ba64b6 sunxi-tools: bring in gcc-arm-linux-gnueabi hostdep required for building sunxi's boot stages 2023-04-07 13:00:09 +02:00
Ricardo Pardini
6b965c605c completely remove any traces of KERNEL_ONLY and exit with error if set 2023-03-17 08:32:11 +01:00
Ricardo Pardini
fc8536b700 extension: c-plus-plus-compiler: include g++ package as well as g++-aarch64-linux-gnu 2023-03-10 10:49:45 -03:00
Ricardo Pardini
2f7423d0e4 shellfmt/.editorconfig: enable trim whitespaces, run shellfmt, no actual code changes (#4849)
- shellfmt: bump to 3.6.0 (run with `bash lib/tools/shellfmt.sh`)
- .editorconfig: rationalize, remove duplicated logic
2023-02-23 09:24:41 +01:00
Ricardo Pardini
a2304f28b0 armbian-next: post_build_image: run hook first, then write to CARD_DEVICE, then compress, in that order
- compress *all* present output images, not only .img
- remove 7zip compression & hostdep
- squash a few shortcircuits (yeah, this late in the game...)
2023-02-18 07:46:12 -03:00
Ricardo Pardini
9bffa5e749 armbian-next: artifacts: firmware/rootfs and actual usage of artifacts during image build
- artifacts: introduce `ARTIFACT_IGNORE_CACHE=yes`
- artifacts: introduce `DONT_BUILD_ARTIFACTS`, list of artifacts that if not found cached, fail the build
- kernel_package_source() is no more
- a long dissertation about kernels, families, and the universe
- artifacts: actually use rootfs artifact for image build
- artifacts: detangle via artifact_base_dir
- artifacts: rootfs: use folders in artifact_name; include cache_type
- artifacts: some cleanups / validations
- rootfs artifact; drop old rootfs cli
- artifacts: new CLI shortcuts; remove old firmware CLI
- artifacts: full firmware & usage
- use firmware artifacts in image build and install its debs
- kernel artifact sans legacy; use tmpdir for .deb target for all packages
- legacy artifact versions is no more; pack/unpack now in common obtain;
- artifacts: uboot: cleanup legacy renaming, use artifact version directly
- artifacts: add firmware (small) artifact
- deploy uboot to loop from artifact; allow tty to artifact; todos for cleaning
- fixes, kernel dtb/headers conditional; remove `.git` from Makefile url; use mapfile for finding files to hash
  - completely remove KERNEL_HAS_WORKING_HEADERS_FULL_SOURCE and `kernel_package_callback_linux_headers_full_source()`
  - don't use realpath for artifact_file_relative
  - curb some warnings
  - fix: only install headers & dtbs if such exist
- kernel .config hook modification hash versioning
- OCI_TARGET_BASE vs per-artifact defaults; only deploy to remote from CLI with OTB
- artifact revolver & installing into image
  - add artifact_map_packages and artifact_map_debs dicts
  - revolver accumulates all info
  - REPOSITORY_INSTALL is no more (for uboot/kernel, later others)
  - rename `VER` to `IMAGE_INSTALLED_KERNEL_VERSION`
2023-02-18 07:46:03 -03:00
Ricardo Pardini
388c76c91b armbian-next: shellcheck: squash more shellcheck warnings; some long-lost variables being used; some unset's that are better reset's, etc 2023-02-18 07:45:33 -03:00
Ricardo Pardini
3c5488b002 armbian-next: bump logging archive greet to 14 files 2023-02-18 07:44:59 -03:00
Ricardo Pardini
c75f5c81b3 armbian-next: ext: grub-sbc-media: syncs with original version, fixes, nextify 2023-02-18 07:44:49 -03:00
Ricardo Pardini
9b1687e32b armbian-next: ext: grub-riscv64: syncs with original version, fixes, nextify 2023-02-18 07:44:48 -03:00
Ricardo Pardini
8825a99845 armbian-next: extensions: nomod: for when you really don't care about modules 2023-02-18 07:44:30 -03:00
Ricardo Pardini
36c97b8220 armbian-next: extensions: rename kernel-localmodconfig to just lsmod
- rename `KERNEL_CONFIG_FROM_LSMOD` to just `LSMOD` too
- default `LSMOD` to `${BOARD}`
- and make it "better"
2023-02-18 07:43:20 -03:00
Ricardo Pardini
7879895049 armbian-next: core extensions for xfs / f2fs / brtfs / LUKS/cryptroot hostdeps; enable in main-config 2023-02-18 07:42:46 -03:00
Ricardo Pardini
0ac6a8fc1d armbian-next: add core extension c-plus-plus-compiler which hostdeps on g++-aarch64-linux-gnu and enable it in JetHub family 2023-02-18 07:42:45 -03:00
Ricardo Pardini
53266feff8 armbian-next: kernel: deterministic .config mtime handling; kernel build logging sections reorg
- .config is now compared with previous one byte-wise, diff shown, and mtime preserved directly via `cp -p`
- this does away with the previous mtime-based BS I had written during the fasthash era (and thus remove file-mtime.sh, regen lib)
- split some functions, to better control the interactive piece in the _middle_ of kernel config process
- no more `kernel_config_maybe_interactive()`, now `kernel_config()` that controls its own logging sections
- extract `kernel_determine_toolchain()` out of config into make
- introduce internal hook `armbian_kernel_config()` that runs before custom version (for .config defaults, coming soon)
2023-02-18 07:42:39 -03:00
Ricardo Pardini
cc7972df0d armbian-next: grub: make /usr/share/desktop-base/grub_background.sh executable, otherwise does nothing 2023-02-18 07:41:26 -03:00
Ricardo Pardini
277ce40e6f armbian-next: fix for grub's DISTRO_GENERIC_KERNEL on Debian (not Ubuntu) during update-initramfs
- `initrd`: when kernel not found, list the installed kernels
- armbian-next: small fix for `grub` extension naming
2023-02-18 07:40:34 -03:00
Ricardo Pardini
4a9529dd34 armbian-next: qemu-uboot-arm64 and qemu-uboot-x86 new boards
- sharing most UEFI code, will replace the `virtual` one soon
- x86: patch uboot defconfig to use the `q35` machine type, not `i440fx`
  - separate x86 bootscript, due to non-uInitrd-ness of it
  - hack ramdisk load address both in u-boot source and bootscript
  - use 32-bit u-boot, not 64-bit
- grub: introduce `UEFI_GRUB=skip`, does not deploy GRUB (but does the kernel packages, etc)
- auto-enable qcow2 output for these
- works with both distro's and Armbian's kernels
2023-02-18 07:40:33 -03:00
Ricardo Pardini
27b8ced02e armbian-next: qcow2: introduce QCOW2_KEEP_IMG=no, which deletes the original .img after qcow2'ing it 2023-02-18 07:40:30 -03:00
Ricardo Pardini
55feb9d510 armbian-next: image-output-utm core extension: produces qcow2-based UTM ZIP image
- `UTM`/`OVF`: discard the original .img after conversion
- UTM 3.x, also for arm64 in addition to x86
2023-02-18 07:40:26 -03:00
Ricardo Pardini
b209d8827e armbian-next: vmware-vm core extension: enables image-output-ovf and adds some cli and desktop packages to image list 2023-02-18 07:40:25 -03:00
Ricardo Pardini
dfb0988900 armbian-next: grub: fix/hack for grub deploy inside Docker/chroot when /dev/disk/by-uuid is not present; add sanity checks 2023-02-18 07:40:24 -03:00
Ricardo Pardini
0dba98b6e8 armbian-next: aggregation.py and package-lists.sh usage in core grub-* extensions
- fix grub-riscv64.sh; this needs merging into grub itself later
2023-02-18 07:40:23 -03:00
Ricardo Pardini
c4eaf49f3d armbian-next: cleanup extensions logging, using display_alert new levels extensions (SHOW_EXTENSIONS=yes) and extensionstrace (SHOW_EXTENSIONS_TRACE=yes)
- DEBUG_EXTENSION_CALLS is gone. use SHOW_EXTENSIONS instead.
- LOG_ALL_HOOK_TRACES is gone. use SHOW_EXTENSIONS_TRACE instead
- LOG_ENABLE_EXTENSION is gone. use SHOW_DEBUG=yes instead
2023-02-18 07:39:54 -03:00
Ricardo Pardini
c444040740 armbian-next: grub: call VER="generic" update_initramfs when "${DISTRO_GENERIC_KERNEL}" == "yes" (so ddk builds work again) 2023-02-18 07:39:34 -03:00
Ricardo Pardini
d85bf2a155 armbian-next: many fixes after v29 rebase; mostly involving umount
- remove grub's --verbose, it's really too verbose
- trust in TMPDIR, do not use trap at all in compile_plymouth-theme-armbian - settings traps adhoc is forbidden in armbian-next as well
- be more verbose in umount_chroot(), do not try to unmount tmpfs-mounted dir itself, only xx/tmp
- try to be smarter about /tmp being mounted in rootfs-to-image -- in the end the recursive saves us
- run post_debootstrap_tweaks when the SDCARD is still mounted, not after
- don't try to download anything from any mirrors if SKIP_ARMBIAN_REPO==yes
2023-02-18 07:39:28 -03:00
Ricardo Pardini
d6c43d0cdf armbian-next: kernel-localmodconfig: update kernel_config_mtime after running localmodconfig, otherwise changes not detected 2023-02-18 07:39:06 -03:00
Ricardo Pardini
3c5021b438 armbian-next: allow overriding rkbins repo URL with RKBIN_GIT_URL 2023-02-18 07:38:58 -03:00
Ricardo Pardini
ad21c12c2b armbian-next: extensions changes - MEGASQUASH - squashed changes from c9cf3fc241cfb4c872f4aef7bbc41d5854db7ea3 to 6809de3d6063cb041205a8318e19da6a4dee68c9 ref extensions_08_10_2022_pre_v30 2023-02-18 07:38:45 -03:00
Oleg
20ee08325f move kernel media current 6.1 and edge 6.2 (#4781)
* move kernel media current 6.1 and edge 6.2
add board quartz64b

* fix nanopc-t4
2023-02-01 20:24:20 +01:00
Ash
408bc67619 Add shebangs for shellcheck (#4493)
* Add shebangs for shellcheck

See #AR-1406

* Add shebangs for shellcheck

Also for `extensions` scripts
2022-11-27 21:44:50 +01:00
Ricardo Pardini
0bfad1e7f7 flash-kernel: pass FK_FORCE=yes to flash-kernel so it actually runs in chroot; thanks Ubuntu (#4439) 2022-11-15 20:20:13 +01:00