Fix dolphin start script to work across supported devices.

This commit is contained in:
fewtarius 2022-09-02 20:40:41 -04:00
parent f3b22d5d4d
commit bb7eef0ee8
No known key found for this signature in database
GPG key ID: F4AE55305D1B8C1A
2 changed files with 14 additions and 1 deletions

View file

@ -71,3 +71,16 @@ makeinstall_target() {
cp -rf ${PKG_BUILD}/Data/Sys/* ${INSTALL}/usr/config/dolphin-emu
cp -rf ${PKG_DIR}/config/${DEVICE}/* ${INSTALL}/usr/config/dolphin-emu
}
post_install() {
case ${DEVICE} in
RG503|RG353P)
DOLPHIN_PLATFORM="drm"
;;
*)
DOLPHIN_PLATFORM="x11"
;;
esac
sed -e "s/@DOLPHIN_PLATFORM@/${DOLPHIN_PLATFORM}/g" \
-i ${INSTALL}/usr/bin/start_dolphin.sh
}

View file

@ -18,4 +18,4 @@ rm -rf /storage/.local/share/dolphin-emu
ln -sfv /storage/.config/dolphin-emu /storage/.local/share/dolphin-emu
/usr/bin/dolphin-emu-nogui -p drm -a HLE -e "${1}"
/usr/bin/dolphin-emu-nogui -p @DOLPHIN_PLATFORM@ -a HLE -e "${1}"