aboutsummaryrefslogtreecommitdiffstats
path: root/jaucpp/scripts/setup-machine-arch.sh
diff options
context:
space:
mode:
Diffstat (limited to 'jaucpp/scripts/setup-machine-arch.sh')
-rw-r--r--jaucpp/scripts/setup-machine-arch.sh41
1 files changed, 41 insertions, 0 deletions
diff --git a/jaucpp/scripts/setup-machine-arch.sh b/jaucpp/scripts/setup-machine-arch.sh
new file mode 100644
index 00000000..df6c6444
--- /dev/null
+++ b/jaucpp/scripts/setup-machine-arch.sh
@@ -0,0 +1,41 @@
+#!/bin/sh
+
+machine=`uname -m`
+
+case "$machine" in
+ "arm")
+ cpu="arm"
+ cpufamily="arm"
+ archabi="armhf"
+ syslibdir="arm-linux-gnueabihf"
+ ;;
+ "armv7l")
+ cpu="armv7l"
+ cpufamily="arm"
+ archabi="armhf"
+ syslibdir="arm-linux-gnueabihf"
+ ;;
+ "aarch64")
+ cpu="aarch64"
+ cpufamily="arm"
+ archabi="arm64"
+ syslibdir="aarch64-linux-gnu"
+ ;;
+ "x86_64")
+ cpu="x86_64"
+ cpufamily="x86"
+ archabi="amd64"
+ syslibdir="x86_64-linux-gnu"
+ ;;
+ *)
+ echo "Unsupported machine $machine"
+ exit 1
+ ;;
+esac
+
+echo machine $machine
+echo cpu $cpu
+echo cpufamily $cpufamily
+echo archabi $archabi
+echo syslibdir $syslibdir
+