Your Name 7 years ago
parent
commit
96e97cb74b
1 changed files with 8 additions and 7 deletions
  1. 8 7
      setup_nvidia.sh

+ 8 - 7
setup_nvidia.sh

@@ -3,7 +3,7 @@ set -e
 script_version="0.1b"
 script_version="0.1b"
 rdate="10/07/2018"
 rdate="10/07/2018"
 remote_folder="http://wareck.free.fr/openrig"
 remote_folder="http://wareck.free.fr/openrig"
-cuda="9"
+cuda="9.2"
 
 
 #### OPTIONS ####
 #### OPTIONS ####
 ETHMine="YES"
 ETHMine="YES"
@@ -60,9 +60,9 @@ echo -e "\e[97mDone !\e[0m"
 
 
 echo -e "\n\e[95mSystem Update :\e[0m"
 echo -e "\n\e[95mSystem Update :\e[0m"
 sudo apt-get update
 sudo apt-get update
-sudo add-apt-repository -y ppa:ethereum/ethereum -y
-sudo apt-get update
-sudo apt install ethereum git screen htop curl ntp pv git cmake libcryptopp-dev libleveldb-dev libjsoncpp-dev \
+#sudo add-apt-repository -y ppa:ethereum/ethereum -y
+#sudo apt-get update
+sudo apt install git screen htop curl ntp pv git cmake libcryptopp-dev libleveldb-dev libjsoncpp-dev \
 build-essential libcurl4-gnutls-dev libgmp-dev \
 build-essential libcurl4-gnutls-dev libgmp-dev \
 libreadline-dev libmicrohttpd-dev libjansson-dev libgmp-dev libssl-dev unzip python-nfqueue python-scapy -y
 libreadline-dev libmicrohttpd-dev libjansson-dev libgmp-dev libssl-dev unzip python-nfqueue python-scapy -y
 if [ $CCminer = "YES" ]
 if [ $CCminer = "YES" ]
@@ -86,7 +86,7 @@ sudo add-apt-repository ppa:graphics-drivers/ppa -y
 sudo apt-get update
 sudo apt-get update
 sudo apt-get install nvidia-375 -y
 sudo apt-get install nvidia-375 -y
 cd /tmp
 cd /tmp
-if [ $cuda = "9" ]
+if [ $cuda = "9.2" ]
 then
 then
 wget -c http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/cuda-repo-ubuntu1604_9.2.148-1_amd64.deb
 wget -c http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/cuda-repo-ubuntu1604_9.2.148-1_amd64.deb
 sudo dpkg -i cuda-repo-ubuntu1604_9.2.148-1_amd64.deb
 sudo dpkg -i cuda-repo-ubuntu1604_9.2.148-1_amd64.deb
@@ -159,14 +159,15 @@ if [ $XmrRig = "YES" ]
 then
 then
 echo -e "\n\e[95mInstall XMRig :\e[0m"
 echo -e "\n\e[95mInstall XMRig :\e[0m"
 cd ~
 cd ~
-if [ ! -d xmrig ]
+if ! [ -d xmrig ]
 then
 then
 git clone https://github.com/xmrig/xmrig.git
 git clone https://github.com/xmrig/xmrig.git
 else
 else
 cd xmrig
 cd xmrig
 git pull
 git pull
-if [ -d build ];then cd build; else mkdir build && cd build ;fi
+if ! [ -d build ];then mkdir build ;fi
 fi
 fi
+cd build
 cmake ..
 cmake ..
 make
 make
 fi
 fi