distribution/packages/ui/emulationstation/sources/es_settings
fewtarius 06a9cc1b41
* Fixes HDMI output on Powkiddy x55.
* Replaces Powkiddy's function that contantly disables HDMI.
  * Modifies boot args to no longer specify HDMI resolution.
  * Splits SDL2 into SDL2 and SDL2-rotated.
  * Adds environmental options to check for HDMI and if it isn't connected
    preload the rotation patched SDL2.
2023-07-22 18:29:09 +00:00

48 lines
1.2 KiB
Bash
Executable file

#!/bin/bash
# SPDX-License-Identifier: GPL-2.0-or-later
# Copyright (C) 2019-present Shanti Gilbert (https://github.com/shantigilbert)
# Copyright (C) 2020-present Fewtarius
# Source predefined functions and variables
. /etc/profile
set_audio alsa
export SDL_AUDIODRIVER=alsa
TZ=$(get_setting system.timezone)
echo -n "TIMEZONE=${TZ}" > /storage/.cache/timezone
echo -n "${TZ}" >/storage/.cache/system_timezone
systemctl restart tz-data.service
MYLOCALE=$(get_setting system.language)
if [[ -n "${MYLOCALE}" ]]
then
unset I18NPATH LANG LANGUAGE LOCPATH
MYCHARMAP="UTF-8"
MYLANG="${MYLOCALE}.${MYCHARMAP}"
MYLOCPATH="/storage/.config/emulationstation"
if [ ! -e "${MYLOCPATH}/locale/${MYLANG}/LC_NAME" ]; then
performance
I18NPATH="/usr/share/i18n"
localedef -i ${MYLOCALE} \
-c \
-v \
-f ${MYCHARMAP} \
${MYLOCPATH}/locale/${MYLANG} >/var/log/start_es.log 2>&1
${DEVICE_CPU_GOVERNOR}
fi
export LOCPATH="${MYLOCPATH}/locale"
export LANG=${MYLANG}
export LANGUAGE=${MYLANG}
systemctl import-environment LANG
systemctl import-environment LOCPATH
systemctl import-environment I18NPATH
systemctl import-environment LANGUAGE
fi
systemctl import-environment LD_PRELOAD