Skip to content

Commit

Permalink
Beta v9.8.0 (#7235)
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaIng authored Oct 17, 2024
2 parents 2c429ef + 31dabca commit ce76b23
Show file tree
Hide file tree
Showing 24 changed files with 494 additions and 212 deletions.
20 changes: 11 additions & 9 deletions .build/images/dietpi-build
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ case $HW_MODEL in
0) iname='RPi' HW_ARCH=${HW_ARCH:-1} boot_size=128 root_size=895;;
1) iname='RPi1' HW_ARCH=1 boot_size=128 root_size=895;;
2) iname='RPi2' HW_ARCH=2 boot_size=128 root_size=895;;
4) iname='RPi234' HW_ARCH=3 boot_size=128 root_size=895;;
5) iname='RPi5' HW_ARCH=3 boot_size=128 root_size=895;;
4) iname='RPi234' HW_ARCH=3 boot_size=128 root_size=1000;;
5) iname='RPi5' HW_ARCH=3 boot_size=128 root_size=1000;;
10) iname='OdroidC1' HW_ARCH=2 partition_start=4 boot_size=128 root_size=700 boot_fstype='fat16';;
11) iname='OdroidXU4' HW_ARCH=2 partition_start=4 root_size=800;;
12) iname='OdroidC2' HW_ARCH=3 partition_start=4 root_size=1148;;
Expand Down Expand Up @@ -139,24 +139,26 @@ case $HW_MODEL in
73) iname='ROCKPiS' HW_ARCH=3 partition_start=16 root_size=1100;;
74) iname='RadxaZero' HW_ARCH=3 partition_start=4 root_size=1148;;
75) iname='Container' HW_ARCH=${HW_ARCH:-10} root_size=575;;
'76.1') iname='NanoPiR5S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;;
'76.2') iname='NanoPiR5C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;;
77) iname='ROCK3A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;;
'76.1') iname='NanoPiR5S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
'76.2') iname='NanoPiR5C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
77) iname='ROCK3A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
78) iname='ROCK5B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
'79.1') iname='NanoPiR6S' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
'79.2') iname='NanoPiR6C' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
'79.3') iname='NanoPCT6' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;;
80) iname='OrangePi5' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
81) iname='VisionFive2' HW_ARCH=11 root_size=639;;
82) iname='OrangePi5Plus' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
83) iname='OrangePiZero3' HW_ARCH=3 partition_start=4 root_size=1148;;
84) iname='Star64' HW_ARCH=11 root_size=639;;
85) iname='ROCK5A' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
86) iname='ASUSTB2' HW_ARCH=3 partition_start=16 root_size=1100;;
87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;;
87) iname='OrangePi3B' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
88) iname='OrangePiZero2W' HW_ARCH=3 partition_start=4 root_size=1148;;
89) iname='OrangePi3LTS' HW_ARCH=3 partition_start=4 root_size=1000;;
90) iname='RadxaZERO3' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1136;;
90) iname='RadxaZERO3' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
91) iname='OrangePi5Max' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
92) iname='NanoPiM6' HW_ARCH=3 PTTYPE='gpt' partition_start=16 root_size=1100;;
*) G_DIETPI-NOTIFY 1 "Invalid hardware model \"$HW_MODEL\" passed, aborting..."; exit 1;;
esac

Expand Down Expand Up @@ -614,7 +616,7 @@ _EOF_

# Force ARMv6 arch on Raspbian
# shellcheck disable=SC2015
(( $HW_ARCH > 1 )) || { echo -e '#/bin/dash\n[ "$*" = -m ] && echo armv6l || /usr/bin/uname "$@"' > rootfs/usr/local/bin/uname && G_EXEC chmod +x rootfs/usr/local/bin/uname; } || Error_Exit 'Failed to generate /usr/local/bin/uname for ARMv6'
(( $HW_ARCH > 1 )) || { echo -e '#/bin/dash\n[ "$*" = -m ] && echo armv6l || /bin/uname "$@"' > rootfs/usr/local/bin/uname && G_EXEC chmod +x rootfs/usr/local/bin/uname; } || Error_Exit 'Failed to generate /usr/local/bin/uname for ARMv6'

# Skip filesystem expansion
G_EXEC rm rootfs/etc/systemd/system/local-fs.target.wants/dietpi-fs_partition_resize.service
Expand Down
5 changes: 1 addition & 4 deletions .build/images/dietpi-imager
Original file line number Diff line number Diff line change
Expand Up @@ -761,11 +761,8 @@ _EOF_
(( $SKIP_ARCHIVE )) && exit 0

# Generate xz archive
# NB: LZMA2 ultra compression requires much memory per thread. 1 GiB is not sufficient for >2 threads, hence use "-T2" to limit used CPU threads to "2" on 1 GiB devices with more than two cores.
local threads=0
(( $(free -m | mawk '/Mem:/{print $2}') < 1750 && $(nproc) > 2 )) && threads=2
[[ -f $OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz ]] && G_EXEC rm "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz"
G_EXEC_DESC='Creating final xz archive' G_EXEC xz -9e -k "-T$threads" "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT"
G_EXEC_DESC='Creating final xz archive' G_EXEC xz -9e -T0 -M75% -k "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT"
G_EXEC_DESC='Generating SHA256 hash' G_EXEC eval "sha256sum '$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz' > '$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz.sha256'"
local signature=() sig_text=''
[[ $SIGN_PASS ]] && { G_DIETPI-NOTIFY 2 'Signing archive ...'; gpg --batch --pinentry-mode loopback --passphrase "$SIGN_PASS" -b --armor "$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz" || exit 1; signature=("$OUTPUT_IMG_NAME.$OUTPUT_IMG_EXT.xz.asc") sig_text="\nSignature: $PWD/${signature[*]}"; }
Expand Down
24 changes: 16 additions & 8 deletions .build/images/dietpi-installer
Original file line number Diff line number Diff line change
Expand Up @@ -416,6 +416,7 @@ _EOF_
'79.1' ': NanoPi R6S'
'79.2' ': NanoPi R6C'
'79.3' ': NanoPC T6'
'92' ': NanoPi M6'
'72.1' ': ROCK 4 (all other variants)'
'72.2' ': ROCK 4 SE'
'72.3' ': ROCK 4C Plus'
Expand All @@ -429,6 +430,7 @@ _EOF_
'89' ': Orange Pi 3 LTS'
'80' ': Orange Pi 5'
'82' ': Orange Pi 5 Plus'
'91' ': Orange Pi 5 Max'
'83' ': Orange Pi Zero 3'
'88' ': Orange Pi Zero 2W'
'86' ': ASUS Tinker Board 2'
Expand Down Expand Up @@ -628,7 +630,7 @@ _EOF_
G_EXEC mv "$dir/.build/images/U-Boot/99-dietpi-uboot" /etc/initramfs/post-update.d/99-dietpi-uboot
G_EXEC sed --follow-symlinks -i 's/arm64/arm/' /etc/initramfs/post-update.d/99-dietpi-uboot

elif [[ $G_HW_MODEL =~ ^(12|15|16|40|42|43|44|45|46|47|48|52|54|55|56|57|58|59|60|62|63|64|65|66|67|68|72|73|74|76|77|78|79|80|82|83|85|86|87|88|89|90)$ ]]
elif [[ $G_HW_MODEL =~ ^(12|15|16|40|42|43|44|45|46|47|48|52|54|55|56|57|58|59|60|62|63|64|65|66|67|68|72|73|74|76|77|78|79|80|82|83|85|86|87|88|89|90|91|92)$ ]]
then
armbian_packages=1
G_EXEC mv "$dir/.build/images/U-Boot/boot.cmd" /boot/boot.cmd
Expand Down Expand Up @@ -669,7 +671,7 @@ setenv rootuuid "true"' /boot/boot.cmd
(( $G_HW_MODEL == 15 )) && G_EXEC eval 'echo '\''meson_rng'\'' > /etc/modules-load.d/dietpi-hwrng.conf'

# Rockchip 64-bit (configs work with Amlogic OOTB)
elif [[ $G_HW_MODEL =~ ^(42|43|46|47|55|56|58|68|72|73|76|77|78|79|80|82|85|86|87|90)$ ]]
elif [[ $G_HW_MODEL =~ ^(42|43|46|47|55|56|58|68|72|73|76|77|78|79|80|82|85|86|87|90|91|92)$ ]]
then
G_EXEC sed --follow-symlinks -Ei '/^setenv (kernel|fdt)_addr_r/d' /boot/boot.cmd
G_CONFIG_INJECT 'setenv scriptaddr ' 'setenv scriptaddr "0x9000000"' /boot/boot.cmd
Expand Down Expand Up @@ -697,20 +699,19 @@ setenv rootuuid "true"' /boot/boot.cmd
esac
;;
85) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3588s-rock-5a.dtb' /boot/dietpiEnv.txt;;
87) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=rockchip/rk3566-orangepi-3b.dtb' /boot/dietpiEnv.txt;;
*) :;;
esac
# Overlay prefix
case $G_HW_MODEL in
73) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rk3308' /boot/dietpiEnv.txt;;
78|79|80|82|85) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rk3588' /boot/dietpiEnv.txt;; # ToDo: There are multiple other prefixes used in the kernel package, "rock-5b", "rock-5ab", "rockchip" (for fixup), so the boot.cmd need heavy adjustments (eliminate the prefix entirely) to work with all overlays.
78|79|80|82|85|91|92) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rk3588' /boot/dietpiEnv.txt;; # ToDo: There are multiple other prefixes used in the kernel package, "rock-5b", "rock-5ab", "rockchip" (for fixup), so the boot.cmd need heavy adjustments (eliminate the prefix entirely) to work with all overlays.
*) G_CONFIG_INJECT 'overlay_prefix=' 'overlay_prefix=rockchip' /boot/dietpiEnv.txt;;
esac
# Console args
case $G_HW_MODEL in
73) G_CONFIG_INJECT 'consoleargs=' 'consoleargs=console=ttyS0,1500000' /boot/dietpiEnv.txt;; # headless
47|55|56) G_CONFIG_INJECT 'consoleargs=' 'consoleargs=console=ttyS2,1500000' /boot/dietpiEnv.txt;; # headless
78|79|80|82|85) G_EXEC sed --follow-symlinks -i 's/ttyAML0,115200/ttyFIQ0,1500000/' /boot/dietpiEnv.txt;; # RK3588
78|79|80|82|85|91|92) G_EXEC sed --follow-symlinks -i 's/ttyAML0,115200/ttyFIQ0,1500000/' /boot/dietpiEnv.txt;; # RK3588
*) G_EXEC sed --follow-symlinks -i 's/ttyAML0,115200/ttyS2,1500000/' /boot/dietpiEnv.txt;;
esac

Expand Down Expand Up @@ -791,6 +792,11 @@ setenv rootuuid "true"' /boot/boot.cmd
G_EXEC mv "$dir/.build/images/NanoPiM3/boot.cmd" /boot/boot.cmd
G_EXEC sed --follow-symlinks -i '/overlay/d' /boot/dietpiEnv.txt
G_EXEC sed --follow-symlinks -i 's/ttyAML0/ttySAC0/' /boot/dietpiEnv.txt
# Device tree
case $HW_VARIANT in
2) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=s5p6818-nanopi-fire3.dtb' /boot/dietpiEnv.txt;;
*) G_CONFIG_INJECT 'fdtfile=' 'fdtfile=s5p6818-nanopi-m3.dtb' /boot/dietpiEnv.txt;;
esac
fi
fi

Expand Down Expand Up @@ -1136,6 +1142,8 @@ _EOF_
88) model='orangepizero2w' kernel='sunxi64';;
89) model='orangepi3-lts' kernel='sunxi64';;
90) model='radxa-zero3' kernel='rk35xx' branch='legacy';;
91) model='orangepi5-max' kernel='rk35xx' branch='vendor';;
92) model='nanopi-m6' kernel='rk35xx' branch='vendor';;
*) :;;
esac

Expand Down Expand Up @@ -1272,7 +1280,7 @@ _EOF_
# tiny-initramfs to satisfy dependency: https://github.com/RPi-Distro/repo/issues/358
G_AGI raspi-firmware
G_CONFIG_INJECT 'SKIP_INITRAMFS_GEN=' 'SKIP_INITRAMFS_GEN=yes' /etc/default/raspi-firmware
G_AGI "${kernel[@]}" raspi-utils raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" tiny-initramfs
G_AGI "${kernel[@]}" raspi-utils-core raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" tiny-initramfs
G_EXEC apt-mark auto tiny-initramfs
G_EXEC rm -f /boot/initrd.img-* /boot/firmware/initramfs*
else
Expand Down Expand Up @@ -1957,8 +1965,8 @@ _EOF_'
then
/boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyS1

# Rockchip vendor: ROCK 5B, NanoPi 6, Orange Pi 5, Orange Pi 5 Plus, ROCK 5A, Radxa ZERO 3
elif [[ $G_HW_MODEL =~ ^(78|79|80|82|85|90)$ ]]
# Rockchip vendor/legacy: ROCK 5B, NanoPi 6, Orange Pi 5, Orange Pi 5 Plus, ROCK 5A, Radxa ZERO 3
elif [[ $G_HW_MODEL =~ ^(78|79|80|82|85|90|91|92)$ ]]
then
/boot/dietpi/func/dietpi-set_hardware serialconsole enable ttyFIQ0

Expand Down
2 changes: 1 addition & 1 deletion .build/software/Amiberry/container_build.bash
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ G_EXEC mount "${FP_LOOP}p1" rootfs

# Enforce ARMv6 arch on Raspbian
# shellcheck disable=SC2015
(( $arch > 1 )) || { echo -e '#/bin/dash\n[ "$*" = -m ] && echo armv6l || /usr/bin/uname "$@"' > rootfs/usr/local/bin/uname && G_EXEC chmod +x rootfs/usr/local/bin/uname; } || Error_Exit 'Failed to generate /usr/local/bin/uname for ARMv6'
(( $arch > 1 )) || { echo -e '#/bin/dash\n[ "$*" = -m ] && echo armv6l || /bin/uname "$@"' > rootfs/usr/local/bin/uname && G_EXEC chmod +x rootfs/usr/local/bin/uname; } || Error_Exit 'Failed to generate /usr/local/bin/uname for ARMv6'

# Enable automated setup
G_CONFIG_INJECT 'AUTO_SETUP_AUTOMATED=' 'AUTO_SETUP_AUTOMATED=1' rootfs/boot/dietpi.txt
Expand Down
2 changes: 1 addition & 1 deletion .build/software/dietpi-software-build.bash
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ G_EXEC mount "${FP_LOOP}p1" rootfs

# Enforce ARMv6 arch on Raspbian
# shellcheck disable=SC2015
(( $arch > 1 )) || { echo -e '#/bin/dash\n[ "$*" = -m ] && echo armv6l || /usr/bin/uname "$@"' > rootfs/usr/local/bin/uname && G_EXEC chmod +x rootfs/usr/local/bin/uname; } || Error_Exit 'Failed to generate /usr/local/bin/uname for ARMv6'
(( $arch > 1 )) || { echo -e '#/bin/dash\n[ "$*" = -m ] && echo armv6l || /bin/uname "$@"' > rootfs/usr/local/bin/uname && G_EXEC chmod +x rootfs/usr/local/bin/uname; } || Error_Exit 'Failed to generate /usr/local/bin/uname for ARMv6'

# Enable automated setup
G_CONFIG_INJECT 'AUTO_SETUP_AUTOMATED=' 'AUTO_SETUP_AUTOMATED=1' rootfs/boot/dietpi.txt
Expand Down
94 changes: 94 additions & 0 deletions .build/software/sprd-bluetooth/build.bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
#!/bin/bash
{
if [[ -f '/boot/dietpi/func/dietpi-globals' ]]
then
. /boot/dietpi/func/dietpi-globals || exit 1
else
curl -sSf "https://raw.githubusercontent.com/${G_GITOWNER:-MichaIng}/DietPi/${G_GITBRANCH:-master}/dietpi/func/dietpi-globals" -o /tmp/dietpi-globals || exit 1
# shellcheck disable=SC1091
. /tmp/dietpi-globals || exit 1
G_EXEC_NOHALT=1 G_EXEC rm /tmp/dietpi-globals
fi

G_EXEC mkdir -p sprd-bluetooth/{DEBIAN,usr/bin,lib/systemd/system}

G_EXEC curl -fo sprd-bluetooth/usr/bin/hciattach_opi 'https://raw.githubusercontent.com/orangepi-xunlong/orangepi-build/next/external/packages/blobs/bt/hciattach/hciattach_opi_arm64'
G_EXEC chmod +x sprd-bluetooth/usr/bin/hciattach_opi
cat << '_EOF_' > sprd-bluetooth/lib/systemd/system/sprd-bluetooth.service
[Unit]
Description=Spreadtrum (sprd) Bluetooth support
After=bluetooth.service
[Service]
RemainAfterExit=yes
ExecStart=/usr/bin/hciattach_opi -n -s 1500000 /dev/ttyBT0 sprd
[Install]
WantedBy=multi-user.target
_EOF_

# Control files
# - postinst
cat << '_EOF_' > sprd-bluetooth/DEBIAN/postinst
#!/bin/sh
if [ -d '/run/systemd/system' ]
then
echo 'Configuring sprd-bluetooth systemd service ...'
systemctl unmask sprd-bluetooth
systemctl enable --now sprd-bluetooth
fi
_EOF_

# - prerm
cat << '_EOF_' > sprd-bluetooth/DEBIAN/prerm
#!/bin/sh
if [ "$1" = 'remove' ] && [ -d '/run/systemd/system' ]
then
if [ -f '/lib/systemd/system/sprd-bluetooth.service' ]
then
echo 'Deconfiguring sprd-bluetooth systemd service ...'
systemctl unmask sprd-bluetooth
systemctl disable --now sprd-bluetooth
fi
fi
_EOF_

# - postrm
cat << '_EOF_' > sprd-bluetooth/DEBIAN/postrm
#!/bin/sh
if [ "$1" = 'purge' ]
then
if [ -d '/etc/systemd/system/sprd-bluetooth.service.d' ]
then
echo 'Removing sprd-bluetooth systemd service overrides ...'
rm -Rv /etc/systemd/system/sprd-bluetooth.service.d
fi
fi
_EOF_

G_EXEC chmod +x sprd-bluetooth/DEBIAN/{postinst,prerm,postrm}

# - md5sums
find sprd-bluetooth ! \( -path sprd-bluetooth/DEBIAN -prune \) -type f -exec md5sum {} + | sed 's|sprd-bluetooth/||' > sprd-bluetooth/DEBIAN/md5sums

# - control
cat << _EOF_ > sprd-bluetooth/DEBIAN/control
Package: sprd-bluetooth
Version: 0.0.1
Architecture: arm64
Maintainer: MichaIng <[email protected]>
Date: $(date -uR)
Installed-Size: $(du -sk sprd-bluetooth | mawk '{print $1}')
Section: admin
Priority: optional
Homepage: https://github.com/orangepi-xunlong/orangepi-build/tree/next/external/packages/blobs/bt/hciattach
Description: Spreadtrum (sprd) Bluetooth support
_EOF_
G_CONFIG_INJECT 'Installed-Size: ' "Installed-Size: $(du -sk sprd-bluetooth | mawk '{print $1}')" sprd-bluetooth/DEBIAN/control

# Build DEB package
G_EXEC_OUTPUT=1 G_EXEC dpkg-deb -b -Zxz -z9 sprd-bluetooth

# Cleanup
G_EXEC rm -R sprd-bluetooth
}
6 changes: 3 additions & 3 deletions .conf/dps_39/minidlna.conf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# WARNING: After changing this option, you need to restart the service
# via: "systemctl restart minidlna"
# Note: After changing this option, you need to restart the service
# via: "systemctl restart minidlna"

# Media paths
media_dir=A,/mnt/dietpi_userdata/Music
Expand All @@ -11,7 +11,7 @@ db_dir=/mnt/dietpi_userdata/.MiniDLNA_Cache

# Must be one of "off", "fatal", "error", "warn", "info" or "debug".
# "off" turns of logging entirely, "fatal" is the highest level of importance.
# Access logs via: "journalctl -u minidlna", on Bullseye in /var/log/minidlna.
# Access logs via: "journalctl -u minidlna" and /var/log/minidlna.
log_level=warn

# Use a different container as the root of the directory tree presented to
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/dietpi-software.bash
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ Process_Software()
164) aSERVICES[i]='nukkit' aUDP[i]='19132'; (( $arch == 10 )) || aDELAY[i]=60;;
165) aSERVICES[i]='gitea' aTCP[i]='3000'; (( $arch < 10 )) && aDELAY[i]=30;;
#166) aSERVICES[i]='pi-spc';; Service cannot reasonably start in container as WirinPi's gpio command fails reading /proc/cpuinfo
167) aSERVICES[i]='raspotify';;
167) (( $arch < 3 )) || aSERVICES[i]='raspotify';; # 32-bit ARM fails with: "arm-binfmt-P: /usr/bin/librespot: Unable to find a guest_base to satisfy all guest address mapping requirements"
#169) aSERVICES[i]='voice-recognizer';; "RuntimeError: This module can only be run on a Raspberry Pi!"
170) aCOMMANDS[i]='unrar -V';;
#171) aSERVICES[i]='frps frpc' aTCP[i]='7000 7400 7500';; Interactive install with service and ports depending on server/client/both choice
Expand Down Expand Up @@ -320,7 +320,7 @@ G_EXEC mount "${FP_LOOP}p1" rootfs

# Force ARMv6 arch on Raspbian
# shellcheck disable=SC2015
(( $arch > 1 )) || { echo -e '#/bin/dash\n[ "$*" = -m ] && echo armv6l || /usr/bin/uname "$@"' > rootfs/usr/local/bin/uname && G_EXEC chmod +x rootfs/usr/local/bin/uname; } || Error_Exit 'Failed to generate /usr/local/bin/uname for ARMv6'
(( $arch > 1 )) || { echo -e '#/bin/dash\n[ "$*" = -m ] && echo armv6l || /bin/uname "$@"' > rootfs/usr/local/bin/uname && G_EXEC chmod +x rootfs/usr/local/bin/uname; } || Error_Exit 'Failed to generate /usr/local/bin/uname for ARMv6'

# Force RPi on ARM systems if requested
if [[ $RPI == 'true' ]] && (( $arch < 10 ))
Expand Down
25 changes: 25 additions & 0 deletions .github/workflows/sprd-bluetooth.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: sprd-bluetooth
on: workflow_dispatch
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true
permissions: {}
jobs:
build:
# https://github.com/actions/runner-images
runs-on: ubuntu-24.04
steps:
- name: Build
run: sudo bash -c "$(curl -sSf "https://raw.githubusercontent.com/$GITHUB_REPOSITORY_OWNER/DietPi/$GITHUB_REF_NAME/.build/software/sprd-bluetooth/build.bash")"
- name: Upload
run: |
# SSH server and client keys
mkdir ~/.ssh
umask 377
echo '${{ secrets.KNOWN_HOSTS }}' > ~/.ssh/known_hosts
echo '${{ secrets.SSH_KEY }}' > ~/.ssh/id_ed25519
# Upload
curl -T sprd-bluetooth.deb --key ~/.ssh/id_ed25519 '${{ secrets.UPLOAD_URL }}all/'
curl 'https://api.cloudflare.com/client/v4/zones/${{ secrets.CF_ZONE }}/purge_cache' -H 'Authorization: Bearer ${{ secrets.CF_TOKEN }}' -H 'Content-Type: application/json' \
--data '{"files":["https://dietpi.com/downloads/binaries/testing/","https://dietpi.com/downloads/binaries/testing/sprd-bluetooth.deb"]}'
Loading

0 comments on commit ce76b23

Please sign in to comment.