File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -52,13 +52,15 @@ CheckPrerequisites() {
52
52
if [ $? -ne 0 ]; then
53
53
echo -e " \033[1;31mERROR! wget missing\033[m"
54
54
read -p " Do you want to install wget (root password is needed) " -n 1 -r
55
+ echo
55
56
if [[ $REPLY =~ ^[Yy]$ ]]; then sudo apt-get install wget; fi
56
57
fi
57
58
58
59
which tar > /dev/null
59
60
if [ $? -ne 0 ]; then
60
61
echo -e " \033[1;31mERROR! tar missing\033[m"
61
62
read -p " Do you want to install tar (root password is needed) " -n 1 -r
63
+ echo
62
64
if [[ $REPLY =~ ^[Yy]$ ]]; then sudo apt-get install tar; fi
63
65
fi
64
66
@@ -67,6 +69,7 @@ CheckPrerequisites() {
67
69
if [ $? -ne 0 ]; then
68
70
echo -e " \033[1;31mERROR! cmake missing\033[m"
69
71
read -p " Do you want to install cmake (root password is needed)? " -n 1 -r
72
+ echo
70
73
if [[ $REPLY =~ ^[Yy]$ ]]; then
71
74
cd /usr/src
72
75
sudo wget https://cmake.org/files/v3.9/cmake-3.9.5.tar.gz
@@ -78,6 +81,19 @@ CheckPrerequisites() {
78
81
cd $HOME
79
82
fi
80
83
fi
84
+
85
+ # check if cross-compiler utilities are installed
86
+ which arm-linux-gnueabi-g++ > /dev/null
87
+ if [ $? -ne 0 ]; then
88
+ echo -e " \033[1;31mERROR! cross-compiler utilities missing\033[m"
89
+ read -p " Do you want to install them (root password is needed)? " -n 1 -r
90
+ echo
91
+ if [[ $REPLY =~ ^[Yy]$ ]]; then
92
+ sudo apt-get install -y gcc-multilib g++-multilib
93
+ sudo apt-get install -y libc6-armel-cross libc6-dev-armel-cross binutils-arm-linux-gnueabi
94
+ sudo apt-get install -y libncurses5-dev gcc-arm-linux-gnueabi g++-arm-linux-gnueabi
95
+ fi
96
+ fi
81
97
}
82
98
83
99
# Check command arguments
You can’t perform that action at this time.
0 commit comments