версии gcc позже, чем 5 не поддерживаются при компиляции ethminer

Важный материал:

Привет пользователи Ubuntu. Недавно я решил ступить в Ethereum, добывающий мир и компиляцию ethminer самостоятельно. После установки cuda однако, я столкнулся с небольшой проблемой. При выполнении sudo cmake --build . после cmake .. -DETHASHCUDA=ON -DETHASHCL=OFF, консоль произвела это:

[  0%] Built target BuildInfo.h
[ 29%] Built target devcore
[ 41%] Built target ethash
[ 45%] Building NVCC (Device) object libethash-cuda/CMakeFiles/ethash-cuda.dir/ethash-cuda_generated_ethash_cuda_miner_kernel.cu.o
In file included from /usr/local/cuda/include/cuda_runtime.h:78:0,
                 from <command-line>:0:
/usr/local/cuda/include/host_config.h:119:2: error: #error -- unsupported GNU version! gcc versions later than 5 are not supported!
 #error -- unsupported GNU version! gcc versions later than 5 are not supported!
  ^~~~~
CMake Error at ethash-cuda_generated_ethash_cuda_miner_kernel.cu.o.Release.cmake:222 (message):
  Error generating
  /home/diamond/ethminer/build/libethash-cuda/CMakeFiles/ethash-cuda.dir//./ethash-cuda_generated_ethash_cuda_miner_kernel.cu.o


libethash-cuda/CMakeFiles/ethash-cuda.dir/build.make:63: recipe for target 'libethash-cuda/CMakeFiles/ethash-cuda.dir/ethash-cuda_generated_ethash_cuda_miner_kernel.cu.o' failed
make[2]: *** [libethash-cuda/CMakeFiles/ethash-cuda.dir/ethash-cuda_generated_ethash_cuda_miner_kernel.cu.o] Error 1
CMakeFiles/Makefile2:232: recipe for target 'libethash-cuda/CMakeFiles/ethash-cuda.dir/all' failed
make[1]: *** [libethash-cuda/CMakeFiles/ethash-cuda.dir/all] Error 2
Makefile:149: recipe for target 'all' failed
make: *** [all] Error 2

Дополнительная информация:

Я установил использование CUDA sudo apt install cuda. Это установило nvidia-275 и cuda самостоятельно (наряду со много другого материала)

2
задан 19 July 2017 в 15:05

1 ответ

Это решило мою проблему:

sudo rm /usr/local/cuda/bin/gcc
sudo rm /usr/local/cuda/bin/g++
sudo apt install gcc-5 g++-5
sudo ln -s /usr/bin/gcc-5 /usr/local/cuda/bin/gcc
sudo ln -s /usr/bin/g++-5 /usr/local/cuda/bin/g++
0
ответ дан 2 December 2019 в 08:47

Другие вопросы по тегам:

Похожие вопросы: