Skip to content

Commit

Permalink
v8.3
Browse files Browse the repository at this point in the history
- DietPi-Software | Chromium: Resolved an issue on Raspberry Pi Bullseye systems where pages did not load but a "Page Unresponsive" error prompt was shown after a while instead, if KMS/DRM was not used. Many thanks to @pastaholic for reporting this issue: #5342
  • Loading branch information
MichaIng committed Apr 2, 2022
1 parent 74e58b1 commit 0d2791c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 14 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ Fixes:
- DietPi-Software | rTorrent: Resolved an issue where the web interface didn't work with Nginx because the PHP handler wasn't set. Many thanks to @vinhtq115 for providing the solution: https://github.com/MichaIng/DietPi/pull/5375
- DietPi-Software | Webmin: Worked around an issue where the install failed. Many thanks to @omavoss for reporting this issue: https://github.com/MichaIng/DietPi/issues/5386
- DietPi-Software | WireGuard: Resolved an issue where the WireGuard module shipped with the kernel was not detected if it is shipped xz-compressed. Many thanks to @Carbonara for reporting this issue: https://dietpi.com/phpbb/viewtopic.php?t=10173
- DietPi-Software | Chromium: Resolved an issue on Raspberry Pi Bullseye systems where pages did not load but a "Page Unresponsive" error prompt was shown after a while instead, if KMS/DRM was not used. Many thanks to @pastaholic for reporting this issue: https://github.com/MichaIng/DietPi/issues/5342

As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/XXXX

Expand Down
23 changes: 9 additions & 14 deletions dietpi/dietpi-software
Original file line number Diff line number Diff line change
Expand Up @@ -9410,39 +9410,34 @@ _EOF_
if (( $G_HW_MODEL > 9 ))
then
G_AGI chromium libpam-systemd
Create_Desktop_Shortcut chromium

# RPi: Use RPi repo package including non-free FFmpeg codecs integration
else
G_AGI chromium-browser chromium-codecs-ffmpeg-extra libpam-systemd
Create_Desktop_Shortcut chromium-browser

# Enable KMS
grep -Eq '^[[:blank:]]*dtoverlay=vc4-f?kms-v3d' /boot/config.txt || /boot/dietpi/func/dietpi-set_hardware rpi-opengl vc4-kms-v3d

# Bullseye: Enable hardware codecs
(( $G_DISTRO < 6 )) || /boot/dietpi/func/dietpi-set_hardware rpi-codec 1
fi

# Flags: Allow root (disable sandbox) and minimise CPU usage: https://peter.sh/experiments/chromium-command-line-switches/
local flags="export CHROMIUM_FLAGS=\"\$CHROMIUM_FLAGS --no-sandbox --test-type --disable-smooth-scrolling --disable-low-res-tiling --enable-low-end-device-mode --num-raster-threads=$G_HW_CPU_CORES --disable-composited-antialiasing"
# - RPi: Leave OpenGL choice to user, as it also depends on RPi model
# - x86_64: OpenGL
# - Else: GLES
(( $G_HW_MODEL < 10 || $G_HW_ARCH == 10 )) && flags+='"' || flags+=' --use-gl=egl"'
# - x86_64: OpenGL, else GLES
(( $G_HW_ARCH == 10 )) && flags+='"' || flags+=' --use-gl=egl"'
# - RPi Buster: Uses /etc/chromium-browser/customizations, else /etc/chromium.d: https://github.com/RPi-Distro/chromium-browser/commit/f4a599d
local path='chromium.d'
(( $G_DISTRO > 5 || $G_HW_MODEL > 9 )) || path='chromium-browser/customizations'
echo "$flags" > "/etc/$path/dietpi"

# Desktop shortcut: chromium-browser.desktop on RPi
if (( $G_HW_MODEL > 9 ))
then
Create_Desktop_Shortcut chromium
else
Create_Desktop_Shortcut chromium-browser
fi

# Autostart run script for kiosk mode, based on @AYapejian: https://github.com/MichaIng/DietPi/issues/1737#issue-318697621
# Autostart script for kiosk mode, based on @AYapejian: https://github.com/MichaIng/DietPi/issues/1737#issue-318697621
[[ -d '/var/lib/dietpi/dietpi-software/installed' ]] || G_EXEC mkdir -p /var/lib/dietpi/dietpi-software/installed
cat << '_EOF_' > /var/lib/dietpi/dietpi-software/installed/chromium-autostart.sh
#!/bin/dash
# Autostart run script for kiosk mode, based on @AYapejian: https://github.com/MichaIng/DietPi/issues/1737#issue-318697621
# Autostart script for kiosk mode, based on @AYapejian: https://github.com/MichaIng/DietPi/issues/1737#issue-318697621

# Resolution to use for kiosk mode, should ideally match current system resolution
RES_X=$(sed -n '/^[[:blank:]]*SOFTWARE_CHROMIUM_RES_X=/{s/^[^=]*=//p;q}' /boot/dietpi.txt)
Expand Down

0 comments on commit 0d2791c

Please sign in to comment.