diff --git a/packages/ui/emulationstation/package.mk b/packages/ui/emulationstation/package.mk index 33211e643..194e80eea 100644 --- a/packages/ui/emulationstation/package.mk +++ b/packages/ui/emulationstation/package.mk @@ -3,7 +3,7 @@ # Copyright (C) 2020-present Fewtarius PKG_NAME="emulationstation" -PKG_VERSION="7e94d3a" +PKG_VERSION="6c1dcb4" PKG_GIT_CLONE_BRANCH="main" PKG_REV="1" PKG_ARCH="any" diff --git a/packages/ui/emulationstation/sources/start_es.sh b/packages/ui/emulationstation/sources/start_es.sh index e584d30b5..55fce8b2d 100755 --- a/packages/ui/emulationstation/sources/start_es.sh +++ b/packages/ui/emulationstation/sources/start_es.sh @@ -1,4 +1,47 @@ #!/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 -/usr/bin/es_settings + +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 + +# create charmap used for translations +locale=$(get_setting system.language) +if [ $? == "0" ] +then + charmap="UTF-8" + lang="${locale}.${charmap}" + locpath="/storage/.config/emulationstation/locale" + i18npath="$locpath/i18n" + localepath="$locpath/$lang" + + if [ ! -d $localepath ]; then + export I18NPATH=$i18npath + performance + /usr/bin/localedef -f $charmap -i $locale $localepath + ${DEVICE_CPU_GOVERNOR} + fi + + export LOCPATH=$locpath + export LANG=$lang + export LANGUAGE=$lang + systemctl import-environment LANG + systemctl import-environment LOCPATH + systemctl import-environment I18NPATH + systemctl import-environment LANGUAGE +fi + +if [[ ! -f "/storage/.newcfg" ]]; then + touch /storage/.newcfg +fi + emulationstation --log-path /var/log