From c4ce52bb45f0dcda8ea924694b48a8e0501d57c0 Mon Sep 17 00:00:00 2001
From: Salmon <99826409+TH3-S4LM0N@users.noreply.github.com>
Date: Tue, 18 Oct 2022 08:26:14 -0500
Subject: Add ldd --version check for Linux (#10)

---
 src-vue/src/views/DeveloperView.vue | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

(limited to 'src-vue/src/views/DeveloperView.vue')

diff --git a/src-vue/src/views/DeveloperView.vue b/src-vue/src/views/DeveloperView.vue
index f08908a6..92364679 100644
--- a/src-vue/src/views/DeveloperView.vue
+++ b/src-vue/src/views/DeveloperView.vue
@@ -8,6 +8,10 @@
             Panic button
         </el-button>
 
+        <el-button type="primary" @click="checkLinuxCompatibility">
+            Check NSProton Compatibility
+        </el-button>
+
         <el-button type="primary" @click="toggleReleaseCandidate">
             Toggle Release Candidate
         </el-button>
@@ -43,6 +47,24 @@ export default defineComponent({
                 position: 'bottom-right'
             });
         },
+        async checkLinuxCompatibility() {
+            let LinuxCompatible = await invoke("linux_checks");
+            if (!LinuxCompatible) {
+                ElNotification({
+                    title: 'Not linux compatible',
+                    message: 'GLIBC is not version 2.33 or greater',
+                    type: 'error',
+                    position: 'bottom-right'
+                });
+            } else {
+                ElNotification({
+                    title: 'Linux compatible',
+                    message: 'No error reported',
+                    type: 'success',
+                    position: 'bottom-right'
+                });
+            }
+        },
         async toggleReleaseCandidate() {
             // Flip between RELEASE and RELEASE_CANDIDATE
             this.$store.state.release_canal = this.$store.state.release_canal === ReleaseCanal.RELEASE
-- 
cgit v1.2.3

