mersenneforum.org  

Go Back   mersenneforum.org > Great Internet Mersenne Prime Search > Hardware > GPU Computing > GpuOwl

Reply
 
Thread Tools
Old 2021-02-19, 09:37   #1
ZFR
 
ZFR's Avatar
 
Feb 2008
Bray, Ireland

2·79 Posts
Default Compiling GpuOwl on Linux Mint errors

Trying to compile GpuOwl on Linux Mint 19.3. Getting the following error:

Code:
zfr@Daria:~/Desktop/gpuowl-7.2$ make
\echo \"`git describe --tags --long --dirty --always`\" > version.new
/bin/sh: 1: git: not found
diff -q -N version.new version.inc >/dev/null || mv version.new version.inc
echo Version: `cat version.inc`
Version: ""
g++ -MT ProofCache.o -MMD -MP -MF .d/ProofCache.Td -Wall -O2 -std=c++17   -c -o ProofCache.o ProofCache.cpp
g++ -MT Proof.o -MMD -MP -MF .d/Proof.Td -Wall -O2 -std=c++17   -c -o Proof.o Proof.cpp
g++ -MT Pm1Plan.o -MMD -MP -MF .d/Pm1Plan.Td -Wall -O2 -std=c++17   -c -o Pm1Plan.o Pm1Plan.cpp
In file included from /usr/include/c++/8/cassert:44,
                 from Pm1Plan.cpp:5:
Pm1Plan.cpp: In function ‘constexpr u32 {anonymous}::firstMissingFactor(u32)’:
Pm1Plan.cpp:65:3: error: call to non-‘constexpr’ function ‘void __assert_fail(const char*, const char*, unsigned int, const char*)’
   assert(false);
   ^~~~~~
Makefile:33: recipe for target 'Pm1Plan.o' failed
make: *** [Pm1Plan.o] Error 1
I'm using the 7.2 release version by the way, not the latest master code.

Also, I'd rather not use git if I can help it. I just downloaded the 7.2 code from here:
https://github.com/preda/gpuowl/releases

Any help?

Last fiddled with by ZFR on 2021-02-19 at 09:40
ZFR is offline   Reply With Quote
Old 2021-02-19, 10:05   #2
ZFR
 
ZFR's Avatar
 
Feb 2008
Bray, Ireland

2×79 Posts
Default

OK, I figured it out. It seems to be related to this bug, that's been fixed in later gcc version.

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86678

In case anyone else has the same issue, update gcc to gcc-9 and it will solve it.

Now getting another error.

Code:
echo \"`git describe --tags --long --dirty --always`\" > version.new
/bin/sh: 1: git: not found
diff -q -N version.new version.inc >/dev/null || mv version.new version.inc
echo Version: `cat version.inc`
Version: ""
g++ -MT Pm1Plan.o -MMD -MP -MF .d/Pm1Plan.Td -Wall -O2 -std=c++17   -c -o Pm1Plan.o Pm1Plan.cpp
g++ -MT B1Accumulator.o -MMD -MP -MF .d/B1Accumulator.Td -Wall -O2 -std=c++17   -c -o B1Accumulator.o B1Accumulator.cpp
g++ -MT Memlock.o -MMD -MP -MF .d/Memlock.Td -Wall -O2 -std=c++17   -c -o Memlock.o Memlock.cpp
g++ -MT log.o -MMD -MP -MF .d/log.Td -Wall -O2 -std=c++17   -c -o log.o log.cpp
g++ -MT GmpUtil.o -MMD -MP -MF .d/GmpUtil.Td -Wall -O2 -std=c++17   -c -o GmpUtil.o GmpUtil.cpp
g++ -MT Worktodo.o -MMD -MP -MF .d/Worktodo.Td -Wall -O2 -std=c++17   -c -o Worktodo.o Worktodo.cpp
g++ -MT common.o -MMD -MP -MF .d/common.Td -Wall -O2 -std=c++17   -c -o common.o common.cpp
g++ -MT main.o -MMD -MP -MF .d/main.Td -Wall -O2 -std=c++17   -c -o main.o main.cpp
g++ -MT Gpu.o -MMD -MP -MF .d/Gpu.Td -Wall -O2 -std=c++17   -c -o Gpu.o Gpu.cpp
g++ -MT clwrap.o -MMD -MP -MF .d/clwrap.Td -Wall -O2 -std=c++17   -c -o clwrap.o clwrap.cpp
g++ -MT Task.o -MMD -MP -MF .d/Task.Td -Wall -O2 -std=c++17   -c -o Task.o Task.cpp
g++ -MT Saver.o -MMD -MP -MF .d/Saver.Td -Wall -O2 -std=c++17   -c -o Saver.o Saver.cpp
g++ -MT timeutil.o -MMD -MP -MF .d/timeutil.Td -Wall -O2 -std=c++17   -c -o timeutil.o timeutil.cpp
g++ -MT Args.o -MMD -MP -MF .d/Args.Td -Wall -O2 -std=c++17   -c -o Args.o Args.cpp
g++ -MT state.o -MMD -MP -MF .d/state.Td -Wall -O2 -std=c++17   -c -o state.o state.cpp
g++ -MT Signal.o -MMD -MP -MF .d/Signal.Td -Wall -O2 -std=c++17   -c -o Signal.o Signal.cpp
g++ -MT FFTConfig.o -MMD -MP -MF .d/FFTConfig.Td -Wall -O2 -std=c++17   -c -o FFTConfig.o FFTConfig.cpp
g++ -MT AllocTrac.o -MMD -MP -MF .d/AllocTrac.Td -Wall -O2 -std=c++17   -c -o AllocTrac.o AllocTrac.cpp
g++ -MT gpuowl-wrap.o -MMD -MP -MF .d/gpuowl-wrap.Td -Wall -O2 -std=c++17   -c -o gpuowl-wrap.o gpuowl-wrap.cpp
g++ -MT sha3.o -MMD -MP -MF .d/sha3.Td -Wall -O2 -std=c++17   -c -o sha3.o sha3.cpp
g++ -MT md5.o -MMD -MP -MF .d/md5.Td -Wall -O2 -std=c++17   -c -o md5.o md5.cpp
g++ -o gpuowl ProofCache.o Proof.o Pm1Plan.o B1Accumulator.o Memlock.o log.o GmpUtil.o Worktodo.o common.o main.o Gpu.o clwrap.o Task.o Saver.o timeutil.o Args.o state.o Signal.o FFTConfig.o AllocTrac.o gpuowl-wrap.o sha3.o md5.o -lstdc++fs -lOpenCL -lgmp -pthread -L/opt/rocm/opencl/lib -L/opt/rocm-3.3.0/opencl/lib/x86_64 -L/opt/rocm-3.1.0/opencl/lib/x86_64 -L/opt/rocm/opencl/lib/x86_64 -L/opt/amdgpu-pro/lib/x86_64-linux-gnu -L.
/usr/bin/ld: cannot find -lOpenCL
collect2: error: ld returned 1 exit status
Makefile:19: recipe for target 'gpuowl' failed
make: *** [gpuowl] Error 1
Going to google into this myself...
ZFR is offline   Reply With Quote
Old 2021-02-19, 10:13   #3
ZFR
 
ZFR's Avatar
 
Feb 2008
Bray, Ireland

2368 Posts
Default

OK, the above was fixed by linking the OpenCL library files
https://github.com/nginnever/zogminer/issues/54

Code:
sudo ln -s /usr/lib/x86_64-linux-gnu/libOpenCL.so.1 /usr/lib/libOpenCL.so
Now getting this:

Code:
zfr@Daria:~/Desktop/gpuowl-7.2$ make
echo \"`git describe --tags --long --dirty --always`\" > version.new
/bin/sh: 1: git: not found
diff -q -N version.new version.inc >/dev/null || mv version.new version.inc
echo Version: `cat version.inc`
Version: ""
g++ -o gpuowl ProofCache.o Proof.o Pm1Plan.o B1Accumulator.o Memlock.o log.o GmpUtil.o Worktodo.o common.o main.o Gpu.o clwrap.o Task.o Saver.o timeutil.o Args.o state.o Signal.o FFTConfig.o AllocTrac.o gpuowl-wrap.o sha3.o md5.o -lstdc++fs -lOpenCL -lgmp -pthread -L/opt/rocm/opencl/lib -L/opt/rocm-3.3.0/opencl/lib/x86_64 -L/opt/rocm-3.1.0/opencl/lib/x86_64 -L/opt/rocm/opencl/lib/x86_64 -L/opt/amdgpu-pro/lib/x86_64-linux-gnu -L.
ProofCache.o: In function `ProofCache::read(unsigned int) const':
ProofCache.cpp:(.text+0x960): undefined reference to `std::filesystem::__cxx11::filesystem_error::_M_gen_what()'
ProofCache.cpp:(.text+0xa65): undefined reference to `std::filesystem::__cxx11::filesystem_error::_M_gen_what()'
ProofCache.o: In function `ProofCache::write(unsigned int, std::vector<unsigned int, std::allocator<unsigned int> > const&)':
ProofCache.cpp:(.text+0x12d3): undefined reference to `std::filesystem::__cxx11::filesystem_error::_M_gen_what()'
Proof.o: In function `std::filesystem::__cxx11::filesystem_error::filesystem_error(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::filesystem::__cxx11::path const&, std::error_code)':
Proof.cpp:(.text._ZNSt10filesystem7__cxx1116filesystem_errorC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_4pathESt10error_code[_ZNSt10filesystem7__cxx1116filesystem_errorC5ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_4pathESt10error_code]+0x2a0): undefined reference to `std::filesystem::__cxx11::filesystem_error::_M_gen_what()'
collect2: error: ld returned 1 exit status
Makefile:19: recipe for target 'gpuowl' failed
make: *** [gpuowl] Error 1
ZFR is offline   Reply With Quote
Old 2021-02-19, 11:15   #4
ZFR
 
ZFR's Avatar
 
Feb 2008
Bray, Ireland

2×79 Posts
Default

OK, solved. Not sure what I did wrong, but after just deleting everything and starting from scratch it went fine.

So for anyone else having issues on Linux Mint 19:

Update gcc to gcc-9. Note: You have to manually add the repository.
Code:
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt update
sudo apt install gcc-9
Link the OpenCL library files
Code:
sudo ln -s /usr/lib/x86_64-linux-gnu/libOpenCL.so.1 /usr/lib/libOpenCL.so
ZFR is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
GpuOwl 7.x preda GpuOwl 199 2021-03-26 00:00
GpuOwl PRP-Proof changes preda GpuOwl 20 2020-10-17 06:51
gpuOWL for Wagstaff GP2 GpuOwl 22 2020-06-13 16:57
gpuowl tuning M344587487 GpuOwl 14 2018-12-29 08:11
previous compiling errors with LLR TTn Programming 0 2004-09-06 07:16

All times are UTC. The time now is 22:05.


Thu Oct 28 22:05:18 UTC 2021 up 97 days, 16:34, 0 users, load averages: 1.31, 1.22, 1.27

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.