Browse Source

readme: move ubuntu stuff in INSTALL file, no ads

master
Tanguy Pruvot 7 years ago
parent
commit
4d09d856f6
  1. 174
      INSTALL
  2. 28
      README.md

174
INSTALL

@ -1,77 +1,97 @@ @@ -1,77 +1,97 @@
You can use ./build.sh to configure and build with default options.
It is advised to run ./autogen.sh before ./configure (autoconf and automake
need to be installed on your system for autogen.sh to work)
./configure has an option named --with-cuda that allows you to specify
where your CUDA 6.5 toolkit is installed (usually /usr/local/cuda,
but some distros may have a different default location)
** How to compile on Fedora 25 **
Note: You may find an alternative method via rpms :
see https://negativo17.org/nvidia-driver/ and https://negativo17.org/repos/multimedia/
# Step 1: gcc and dependencies
dnf install gcc gcc-c++ autoconf automake
dnf install jansson-devel openssl-devel libcurl-devel zlib-devel
# Step 2: nvidia drivers (Download common linux drivers from nvidia site)
dnf install kernel-devel
dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
dnf check-update
dnf install xorg-x11-drv-nvidia-cuda kmod-nvidia
ln -s libnvidia-ml.so.1 /usr/lib64/libnvidia-ml.so
# Step 3: CUDA SDK (Download from nvidia the generic ".run" archive)
# --override is required to ignore "too recent" gcc 6.3
# --silent is required to install only the toolkit (no kmod)
./cuda_8.0.61_375.26_linux.run --toolkit --silent --override
nvcc --version
# add the nvcc binary path to the system
ln -s /usr/local/cuda-8.0 /usr/local/cuda # (if not already made)
echo 'export PATH=$PATH:/usr/local/cuda/bin' > /etc/profile.d/cuda.sh
# add the cudart library path to the system
echo /usr/local/cuda/lib64 > /etc/ld.so.conf.d/cuda.conf
ldconfig
# Step 4: Fix the toolkit incompatibility with gcc 6
# You need to build yourself an older GCC/G++ version, i recommend the 5.4
# see https://gcc.gnu.org/mirrors.html
# Note: this manual method will override the default gcc, it could be better to use a custom toolchain prefix
wget ftp://ftp.lip6.fr/pub/gcc/releases/gcc-5.4.0/gcc-5.4.0.tar.bz2
dnf install libmpc-devel mpfr-devel gmp-devel
./configure --prefix=/usr/local --enable-languages=c,c++,lto --disable-multilib
make -j 8 && make install
(while this step, you have the time to cook something :p)
# or, for previous fedora versions, edit the file /usr/local/cuda/include/host_config.h
# and comment/delete the line 121 : #error -- unsupported GNU version! gcc versions later than 5 are not supported!
./build.sh
./ccminer -n
** How to compile on macOS **
# Step 1: download and install CUDA Toolkit 8 or more recent
# https://developer.nvidia.com/cuda-toolkit-archive
# Step 2: install Homebrew
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
# Step 3: dependencies
brew install pkg-config autoconf automake curl openssl llvm
./build.sh
./ccminer -n
You can use ./build.sh to configure and build with default options.
It is advised to run ./autogen.sh before ./configure (autoconf and automake
need to be installed on your system for autogen.sh to work)
./configure has an option named --with-cuda that allows you to specify
where your CUDA 6.5 toolkit is installed (usually /usr/local/cuda,
but some distros may have a different default location)
** How to compile on Ubuntu (16.04 LTS)
First, install Cuda toolkit and nVidia Driver, and type `nvidia-smi` to check if your card is detected.
Install dependencies
```sudo apt-get install libcurl4-openssl-dev libssl-dev libjansson-dev automake autotools-dev build-essential```
Ubuntu is now shipped with gcc 6 or 7 so please install gcc/g++ 5 and make it the default (required by the cuda toolkit)
```
sudo apt-get install gcc-5 g++-5
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 1
```
Then use the helper ./build.sh in ccminer source folder, edit configure.sh and the Makefile.am if required.
```
./build.sh
./ccminer --version
```
** How to compile on Fedora 25 **
Note: You may find an alternative method via rpms :
see https://negativo17.org/nvidia-driver/ and https://negativo17.org/repos/multimedia/
# Step 1: gcc and dependencies
dnf install gcc gcc-c++ autoconf automake
dnf install jansson-devel openssl-devel libcurl-devel zlib-devel
# Step 2: nvidia drivers (Download common linux drivers from nvidia site)
dnf install kernel-devel
dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
dnf check-update
dnf install xorg-x11-drv-nvidia-cuda kmod-nvidia
ln -s libnvidia-ml.so.1 /usr/lib64/libnvidia-ml.so
# Step 3: CUDA SDK (Download from nvidia the generic ".run" archive)
# --override is required to ignore "too recent" gcc 6.3
# --silent is required to install only the toolkit (no kmod)
./cuda_8.0.61_375.26_linux.run --toolkit --silent --override
nvcc --version
# add the nvcc binary path to the system
ln -s /usr/local/cuda-8.0 /usr/local/cuda # (if not already made)
echo 'export PATH=$PATH:/usr/local/cuda/bin' > /etc/profile.d/cuda.sh
# add the cudart library path to the system
echo /usr/local/cuda/lib64 > /etc/ld.so.conf.d/cuda.conf
ldconfig
# Step 4: Fix the toolkit incompatibility with gcc 6
# You need to build yourself an older GCC/G++ version, i recommend the 5.4
# see https://gcc.gnu.org/mirrors.html
# Note: this manual method will override the default gcc, it could be better to use a custom toolchain prefix
wget ftp://ftp.lip6.fr/pub/gcc/releases/gcc-5.4.0/gcc-5.4.0.tar.bz2
dnf install libmpc-devel mpfr-devel gmp-devel
./configure --prefix=/usr/local --enable-languages=c,c++,lto --disable-multilib
make -j 8 && make install
(while this step, you have the time to cook something :p)
# or, for previous fedora versions, edit the file /usr/local/cuda/include/host_config.h
# and comment/delete the line 121 : #error -- unsupported GNU version! gcc versions later than 5 are not supported!
./build.sh
./ccminer -n
** How to compile on macOS **
# Step 1: download and install CUDA Toolkit 8 or more recent
# https://developer.nvidia.com/cuda-toolkit-archive
# Step 2: install Homebrew
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
# Step 3: dependencies
brew install pkg-config autoconf automake curl openssl llvm
./build.sh
./ccminer -n

28
README.md

@ -9,7 +9,7 @@ BTC donation address: 1AJdfCpLWPNoAMDfHF1wD5y8VgKSSTHxPo (tpruvot) @@ -9,7 +9,7 @@ BTC donation address: 1AJdfCpLWPNoAMDfHF1wD5y8VgKSSTHxPo (tpruvot)
A part of the recent algos were originally written by [djm34](https://github.com/djm34) and [alexis78](https://github.com/alexis78)
This variant was tested and built on Linux (ubuntu server 14.04, 16.04, Fedora 22 to 25)
It is also built for Windows 7 to 10 with VStudio 2013, to stay compatible with Windows Vista.
It is also built for Windows 7 to 10 with VStudio 2013, to stay compatible with Windows 7 and Vista.
Note that the x86 releases are generally faster than x64 ones on Windows, but that tend to change with the recent drivers.
@ -30,27 +30,7 @@ To rebuild them, you need to clone this repository and its submodules : @@ -30,27 +30,7 @@ To rebuild them, you need to clone this repository and its submodules :
git clone https://github.com/peters/curl-for-windows.git compat/curl-for-windows
# Linux
Compile on Linux
----------------
## Ubuntu
Install dependencies
```sudo apt-get install git libcurl4-openssl-dev nvidia-cuda-toolkit build-essential```
Ubuntu is shipped with Gcc 7 so install Gcc 5 and make it the default
```
sudo apt-get install gcc-5 g++-5
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 1
```
Clone code
```
git clone https://github.com/tpruvot/ccminer.git
cd ccminer
```
Use the helper ./build.sh (edit configure.sh and the Makefile.am if required)
```
./build.sh
./ccminer --version
```
Please see [INSTALL](https://github.com/tpruvot/ccminer/blob/linux/INSTALL) file or [project Wiki](https://github.com/tpruvot/ccminer/wiki/Compatibility)

Loading…
Cancel
Save