seredat / karbowanecwallet

Karbowanec Wallet - wallet for Karbo (Karbovanets) cryptocurrency.
http://karbowanec.com/
MIT License
36 stars 38 forks source link

Cannot build karbowanecwallet due to lpthreds #63

Open younicoin opened 2 years ago

younicoin commented 2 years ago

Hello! I have perfectly working manually built karbowanec: daemon, simplewallet. I also want to build karbowanecwallet from source. I made a link to karbowanec onto cryptonote, created dir build and ran 'cmake ..' but got the error lpthreads

$ cmake ..
..
-- Building on x86_64 for default
-- AES support enabled
CMake Warning (dev) at /usr/lib/x86_64-linux-gnu/cmake/Qt5Core/Qt5CoreMacros.cmake:44 (message):
  qt5_use_modules is not part of the official API, and might be removed in Qt
  6.
Call Stack (most recent call first):
  /usr/lib/x86_64-linux-gnu/cmake/Qt5Core/Qt5CoreMacros.cmake:431 (_qt5_warn_deprecated)
  CMakeLists.txt:527 (qt5_use_modules)
This warning is for project developers.  Use -Wno-dev to suppress it.

**-- Configuring incomplete, errors occurred!**
See also "build/CMakeFiles/CMakeOutput.log".
See also "build/CMakeFiles/CMakeError.log".

$ vim build/CMakeFiles/CMakeError.log
..
  pthread_exit(NULL);

  return 0;
}

Determining if the function pthread_create exists in the pthreads failed with the following output:
Change Dir: build/CMakeFiles/CMakeTmp

Run Build Command(s):/usr/bin/gmake cmTC_3550b/fast && /usr/bin/gmake  -f CMakeFiles/cmTC_3550b.dir/build.make CMakeFiles/cmTC_3550b.dir/build
gmake[1]: Entering directory 'build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_3550b.dir/CheckFunctionExists.c.o
/usr/bin/cc   -DCHECK_FUNCTION_EXISTS=pthread_create -o CMakeFiles/cmTC_3550b.dir/CheckFunctionExists.c.o -c /usr/share/cmake-3.18/Modules/CheckFunctionExists.c
Linking C executable cmTC_3550b
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_3550b.dir/link.txt --verbose=1
/usr/bin/cc  -DCHECK_FUNCTION_EXISTS=pthread_create -rdynamic CMakeFiles/cmTC_3550b.dir/CheckFunctionExists.c.o -o cmTC_3550b  -lpthreads
/usr/bin/ld: cannot find -lpthreads
collect2: error: ld returned 1 exit status
gmake[1]: *** [CMakeFiles/cmTC_3550b.dir/build.make:106: cmTC_3550b] Error 1
gmake[1]: Leaving directory 'build/CMakeFiles/CMakeTmp'
gmake: *** [Makefile:140: cmTC_3550b/fast] Error 2

I have lpthreads library here:

# find /lib -name "*pthread*"
/lib/x86_64-linux-gnu/libpthread-2.31.so
/lib/x86_64-linux-gnu/libpthread.so.0

# uname -a
Linux devuan 5.10.0-11-amd64 #1 SMP Debian 5.10.92-1 (2022-01-18) x86_64 GNU/Linux

# head -1 /etc/os-release 
PRETTY_NAME="Devuan GNU/Linux 4 (chimaera)"

How to build simplewallet?

aivve commented 2 years ago

Hi, so it can't find your pthread lib, why don't you try more common Ubuntu?

younicoin commented 2 years ago

I prefer opensource as more secure and try to have totally opensource system Devuan, instead of Ubuntu full of firmware and blobs.