From 11ed3c91a52299e16e7fe6db6344f761784e1156 Mon Sep 17 00:00:00 2001 From: LukeeGD Date: Mon, 9 Mar 2020 08:24:35 +0800 Subject: [PATCH] Fix 18.04 dependency install (fixes #8 ) --- restore.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/restore.sh b/restore.sh index adb31d6..415b80f 100755 --- a/restore.sh +++ b/restore.sh @@ -410,10 +410,12 @@ function Ubuntu { } function Ubuntu1804 { - if [ $(uname -m) == 'x86_64' ]; then + mname=$(uname -m) + if [ $mname == 'x86_64' ]; then mtype='amd64' else mtype='i386' + mname=$mtype fi sudo apt -y install binutils mkdir tmp @@ -421,8 +423,8 @@ function Ubuntu1804 { apt download -o=dir::cache=. libcurl3 ar x libcurl3* data.tar.xz tar xf data.tar.xz - sudo cp usr/lib/${mtype}-linux-gnu/libcurl.so.4.* /usr/lib/libcurl.so.3 - curl -L http://mirrors.edge.kernel.org/ubuntu/pool/main/libp/libpng/libpng12-0_1.2.54-1ubuntu1.1_${mtype}.deb -o libpng12.deb + sudo cp usr/lib/${mname}-linux-gnu/libcurl.so.4.* /usr/lib/libcurl.so.3 + curl -L http://mirrors.edge.kernel.org/ubuntu/pool/main/libp/libpng/libpng12-0_1.2.54-1ubuntu1.1_${mname}.deb -o libpng12.deb sudo dpkg -i libpng12.deb cd .. Clean