Skip to content

Commit 465162a

Browse files
committed
fix(check_deps): Update support for Ubuntu and Debian versions
* Adjusted version checks for supported distributions. * Added specific error messages for unsupported game titles based on OS version.
1 parent c8bdfe0 commit 465162a

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

lgsm/modules/check_deps.sh

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -361,12 +361,22 @@ if [ -n "${distrosupport}" ]; then
361361
fi
362362
fi
363363

364-
if { [ "${distroid}" == "ubuntu" ] && dpkg --compare-versions "${distroversion}" "gt" "24.04"; } || { [ "${distroidlike}" == "debian" ] && dpkg --compare-versions "${distroversion}" "gt" "12"; }; then
365-
if [ "${shortname}" == "bf1942" ] || [ "${shortname}" == "bfv" ]; then
366-
fn_print_failure_nl "${gamename} is not supported on ${distroname}."
367-
fn_script_log_fail "${gamename} is not supported on ${distroname}."
368-
core_exit.sh
369-
fi
364+
# These titles are only supported up to Ubuntu 22.04 (Jammy) and Debian 12 (Bookworm).
365+
if { [ "${distroid}" == "ubuntu" ] && dpkg --compare-versions "${distroversion}" "gt" "22.04"; } || { [ "${distroidlike}" == "debian" ] && dpkg --compare-versions "${distroversion}" "gt" "12"; }; then
366+
if [ "${shortname}" == "bf1942" ] || [ "${shortname}" == "bfv" ]; then
367+
fn_print_failure_nl "${gamename} is not supported on ${distroname} (requires Ubuntu <= 22.04 or Debian <= 12)."
368+
fn_script_log_fail "${gamename} is not supported on ${distroname}."
369+
core_exit.sh
370+
fi
371+
fi
372+
373+
# These titles are only supported up to Ubuntu 20.04 and Debian 11 (and Debian-like derivatives).
374+
if { [ "${distroid}" == "ubuntu" ] && dpkg --compare-versions "${distroversion}" "gt" "20.04"; } || { [ "${distroidlike}" == "debian" ] && dpkg --compare-versions "${distroversion}" "gt" "11"; }; then
375+
if [ "${shortname}" == "onset" ] || [ "${shortname}" == "btl" ]; then
376+
fn_print_failure_nl "${gamename} is not supported on ${distroname} (requires Ubuntu <= 20.04 or Debian <= 11)."
377+
fn_script_log_fail "${gamename} is not supported on ${distroname}."
378+
core_exit.sh
379+
fi
370380
fi
371381

372382
if [ ! -f "${tmpdir}/dependency-no-check.tmp" ] && [ ! -f "${datadir}/${distroid}-${distroversioncsv}.csv" ]; then

0 commit comments

Comments
 (0)