aboutsummaryrefslogtreecommitdiff
path: root/src-tauri/src/platform_specific/linux.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src-tauri/src/platform_specific/linux.rs')
-rw-r--r--src-tauri/src/platform_specific/linux.rs21
1 files changed, 21 insertions, 0 deletions
diff --git a/src-tauri/src/platform_specific/linux.rs b/src-tauri/src/platform_specific/linux.rs
index 674f384b..706a4d22 100644
--- a/src-tauri/src/platform_specific/linux.rs
+++ b/src-tauri/src/platform_specific/linux.rs
@@ -3,6 +3,27 @@
use regex::Regex;
use std::process::Command;
+// I intend to add more linux related stuff to check here, so making a func
+// for now tho it only checks `ldd --version`
+// - salmon
+pub fn linux_checks_librs() -> Result<(), String> {
+ // Perform various checks in terms of Linux compatibility
+ // Return early with error message if a check fails
+
+ // check `ldd --version` to see if glibc is up to date for northstar proton
+ let min_required_ldd_version = 2.33;
+ let lddv = check_glibc_v();
+ if lddv < min_required_ldd_version {
+ return Err(format!(
+ "GLIBC is not version {} or greater",
+ min_required_ldd_version
+ ));
+ };
+
+ // All checks passed
+ Ok(())
+}
+
fn get_proton_dir() -> Option<String> {
let steam_dir = steamlocate::SteamDir::locate()?;
let compat_dir = format!("{}/compatibilitytools.d/", steam_dir.path.display());