Implement a workaround for Bionic Mesa related issues (#1760)

Closing [AR-152]
This commit is contained in:
Igor Pečovnik 2020-01-23 22:40:49 +01:00 committed by GitHub
parent 9be143c2e4
commit 74a2e23f8a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 17 additions and 0 deletions

View File

@ -159,6 +159,18 @@ create_board_package()
fi
EOF
if [[ $RELEASE == bionic ]]; then
cat <<-EOF >> "${destination}"/DEBIAN/postinst
# temporally disable acceleration in Bionic due to broken mesa packages
if [ -n "\$(cat /etc/X11/xorg.conf.d/01-armbian-defaults.conf 2> /dev/null | grep AccelMethod)" ]; then
sed -i '/\Device/,/^\[/ s/AccelMethod".*/AccelMethod"\t "none"/' /etc/X11/xorg.conf.d/01-armbian-defaults.conf
else
sed -i '/\Device/a \\\tOption\t\t\t"AccelMethod" "none"' /etc/X11/xorg.conf.d/01-armbian-defaults.conf
fi
EOF
fi
# install bootscripts if they are not present. Fix upgrades from old images
if [[ $FORCE_BOOTSCRIPT_UPDATE == yes ]]; then
cat <<-EOF >> "${destination}"/DEBIAN/postinst

View File

@ -8,3 +8,8 @@ Section "ServerFlags"
Option "SuspendTime" "0"
Option "OffTime" "0"
EndSection
Section "Device"
Identifier "Default Device"
Driver "modesetting"
Option "AccelMethod" "glamor"
EndSection