Browse Source

Get the architecture if it isn't specified

Bob Mottram 8 years ago
parent
commit
68de1b3964
1 changed files with 11 additions and 0 deletions
  1. 11
    0
      src/freedombone-app-gogs

+ 11
- 0
src/freedombone-app-gogs View File

@@ -54,6 +54,17 @@ function gogs_parameters {
54 54
         CURR_ARCH=arm
55 55
     fi
56 56
     if [ ! $CURR_ARCH ]; then
57
+        echo $'No architecture specified'
58
+        ARCHITECTURE=$(uname -m)
59
+        if [[ $ARCHITECTURE == "arm"* ]]; then
60
+            CURR_ARCH=arm
61
+        fi
62
+        if [[ $ARCHITECTURE == "amd"* ]]; then
63
+            CURR_ARCH=amd64
64
+        fi
65
+        if [[ $ARCHITECTURE == *"386" || $ARCHITECTURE == *"686" ]]; then
66
+            CURR_ARCH=386
67
+        fi
57 68
         return
58 69
     fi
59 70