Bitcoin Forum
November 18, 2024, 02:44:13 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Need help building cgminer from git on Fedora17[update]  (Read 6400 times)
Jive Turkey (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
October 02, 2012, 06:57:45 PM
Last edit: October 05, 2012, 06:55:48 AM by Jive Turkey
 #1

Initially autogen/configure was unable to find libcurl but I found that that was a permissions issue by running it as root strangely, its hit or miss and more consistently miss for detecting libcurl or libcurl version. I have AMDAPP-SDK installed and working, I know this because the precompiled binary works. Still, autogen is not finding OpenCL.

This is what I get running autogen:
Code:
 ./autogen.sh 
Running autoreconf -if...
Configuring...
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for a BSD-compatible install... /bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking dependency style of gcc... (cached) gcc3
checking for ranlib... ranlib
checking whether gcc needs -traditional... no
checking whether gcc and cc understand -c and -o together... yes
checking for ranlib... (cached) ranlib
checking sys/mman.h usability... yes
checking sys/mman.h presence... yes
checking for sys/mman.h... yes
checking wchar.h usability... yes
checking wchar.h presence... yes
checking for wchar.h... yes
checking for stdint.h... (cached) yes
checking for mprotect... yes
checking for sigaction... yes
checking for sigaltstack... yes
checking for siginterrupt... yes
checking for mmap... yes
checking for MAP_ANONYMOUS... yes
checking whether memchr works... yes
checking whether memmem is declared... yes
checking for memmem... yes
checking whether memmem works... yes
checking for C/C++ restrict keyword... __restrict
checking for uid_t in sys/types.h... yes
checking for inline... inline
checking whether the preprocessor supports include_next... yes
checking whether system header files limit the line length... no
checking for wchar_t... yes
checking for unsigned long long int... yes
checking for long long int... yes
checking whether stdint.h conforms to C99... yes
checking whether memmem is declared without a macro... yes
checking whether mempcpy is declared without a macro... yes
checking whether memrchr is declared without a macro... yes
checking whether rawmemchr is declared without a macro... yes
checking whether stpcpy is declared without a macro... yes
checking whether stpncpy is declared without a macro... yes
checking whether strchrnul is declared without a macro... yes
checking whether strdup is declared without a macro... yes
checking whether strncat is declared without a macro... yes
checking whether strndup is declared without a macro... yes
checking whether strnlen is declared without a macro... yes
checking whether strpbrk is declared without a macro... yes
checking whether strsep is declared without a macro... yes
checking whether strcasestr is declared without a macro... yes
checking whether strtok_r is declared without a macro... yes
checking whether strerror_r is declared without a macro... yes
checking whether strsignal is declared without a macro... yes
checking whether strverscmp is declared without a macro... yes
checking whether memmem works in linear time... yes
checking for memmem... (cached) yes
checking whether memmem works... (cached) yes
checking for struct sigaction.sa_sigaction... yes
checking for volatile sig_atomic_t... yes
checking for sighandler_t... yes
checking whether sigaction is declared without a macro... yes
checking whether sigaddset is declared without a macro... yes
checking whether sigdelset is declared without a macro... yes
checking whether sigemptyset is declared without a macro... yes
checking whether sigfillset is declared without a macro... yes
checking whether sigismember is declared without a macro... yes
checking whether sigpending is declared without a macro... yes
checking whether sigprocmask is declared without a macro... yes
checking for sigprocmask... yes
checking whether NULL can be used in arbitrary expressions... yes
checking for ANSI C header files... (cached) yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking for size_t... yes
checking for working alloca.h... yes
checking for alloca... yes
[b]checking for OpenCL... yes[/b]
checking for pthread_create in -lpthread... yes
checking for json_loads in -ljansson... no
checking for ADL_SDK/adl_sdk.h... yes ./autogen.sh
Running autoreconf -if...
Configuring...
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for a BSD-compatible install... /bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking dependency style of gcc... (cached) gcc3
checking for ranlib... ranlib
checking whether gcc needs -traditional... no
checking whether gcc and cc understand -c and -o together... yes
checking for ranlib... (cached) ranlib
checking sys/mman.h usability... yes
checking sys/mman.h presence... yes
checking for sys/mman.h... yes
checking wchar.h usability... yes
checking wchar.h presence... yes
checking for wchar.h... yes
checking for stdint.h... (cached) yes
checking for mprotect... yes
checking for sigaction... yes
checking for sigaltstack... yes
checking for siginterrupt... yes
checking for mmap... yes
checking for MAP_ANONYMOUS... yes
checking whether memchr works... yes
checking whether memmem is declared... yes
checking for memmem... yes
checking whether memmem works... yes
checking for C/C++ restrict keyword... __restrict
checking for uid_t in sys/types.h... yes
checking for inline... inline
checking whether the preprocessor supports include_next... yes
checking whether system header files limit the line length... no
checking for wchar_t... yes
checking for unsigned long long int... yes
checking for long long int... yes
checking whether stdint.h conforms to C99... yes
checking whether memmem is declared without a macro... yes
checking whether mempcpy is declared without a macro... yes
checking whether memrchr is declared without a macro... yes
checking whether rawmemchr is declared without a macro... yes
checking whether stpcpy is declared without a macro... yes
checking whether stpncpy is declared without a macro... yes
checking whether strchrnul is declared without a macro... yes
checking whether strdup is declared without a macro... yes
checking whether strncat is declared without a macro... yes
checking whether strndup is declared without a macro... yes
checking whether strnlen is declared without a macro... yes
checking whether strpbrk is declared without a macro... yes
checking whether strsep is declared without a macro... yes
checking whether strcasestr is declared without a macro... yes
checking whether strtok_r is declared without a macro... yes
checking whether strerror_r is declared without a macro... yes
checking whether strsignal is declared without a macro... yes
checking whether strverscmp is declared without a macro... yes
checking whether memmem works in linear time... yes
checking for memmem... (cached) yes
checking whether memmem works... (cached) yes
checking for struct sigaction.sa_sigaction... yes
checking for volatile sig_atomic_t... yes
checking for sighandler_t... yes
checking whether sigaction is declared without a macro... yes
checking whether sigaddset is declared without a macro... yes
checking whether sigdelset is declared without a macro... yes
checking whether sigemptyset is declared without a macro... yes
checking whether sigfillset is declared without a macro... yes
checking whether sigismember is declared without a macro... yes
checking whether sigpending is declared without a macro... yes
checking whether sigprocmask is declared without a macro... yes
checking for sigprocmask... yes
checking whether NULL can be used in arbitrary expressions... yes
checking for ANSI C header files... (cached) yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking for size_t... yes
checking for working alloca.h... yes
checking for alloca... yes
checking for OpenCL... yes
checking for pthread_create in -lpthread... yes
checking for json_loads in -ljansson... no
checking for ADL_SDK/adl_sdk.h... yes
checking for library containing addstr... -lncurses
checking for yasm... /bin/yasm
checking if yasm version is greater than 1.0.1... yes
checking for pkg-config... /usr/local/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for LIBCURL... no
checking for LIBCURL... no
configure: error: Missing required libcurl dev >= 7.10.1

I'm also asking for help on the Fedora forums and this is what I have posted over there:
The code I'm trying to compile is cgminer, here's a link to the README on github. https://github.com/ckolivas/cgminer/blob/master/README
More info here: https://bitcointalk.org/index.php?topic=28402.0

It seems to have been developed on Ubuntu and the dependencies listed in the README are here:
Quote
Dependencies:
   curl dev library    http://curl.haxx.se/libcurl/
   (libcurl4-openssl-dev)

   curses dev library
   (libncurses5-dev or libpdcurses on WIN32)

   pkg-config      http://www.freedesktop.org/wiki/Software/pkg-config
   libtool         http://www.gnu.org/software/libtool/

   jansson         http://www.digip.org/jansson/
   (jansson is included in-tree and not necessary)

   yasm 1.0.1+ http://yasm.tortall.net/
   (yasm is optional, gives assembly routines for CPU mining)

   AMD APP SDK      http://developer.amd.com/sdks/AMDAPPSDK
   (This sdk is mandatory for GPU mining)

   AMD ADL SDK      http://developer.amd.com/sdks/ADLSDK
   (This sdk is mandatory for ATI GPU monitoring & clocking)

   libudev headers
   (This is only required for FPGA auto-detection and is linux only)

   libusb headers
   (This is only required for ZTEX support)
There is a pre-built binary available that will run and do the GPU overclocking and fan control and submit shares before crashing. The only error message it offers is
Quote
./cgminer: /lib64/libcurl.so.4: no version information available (required by ./cgminer)

My guess is that the code is pretty platform specific to Ubuntu/Debian. Specifically some differences between how Debian and Fedora handle environmental variables and version info. I'm not quite experienced enough to figure it out on my own yet.  I've had it running for weeks at a time on an Ubuntu box. As a test I just ran a git build on the Ubuntu box and it works.

I'm on Fedora 17 x86_64
the output of the suggested query:
Code:
# rpm -aq | grep curl |sort 
curl-7.24.0-5.fc17.x86_64
libcurl-7.24.0-5.fc17.x86_64
libcurl-devel-7.24.0-5.fc17.x86_64
python-pycurl-7.19.0-10.fc17.x86_64
adding:
Code:
# rpm -ql libcurl-devel
/usr/bin/curl-config
/usr/include/curl
/usr/include/curl/curl.h
/usr/include/curl/curlbuild-64.h
/usr/include/curl/curlbuild.h
/usr/include/curl/curlrules.h
/usr/include/curl/curlver.h
/usr/include/curl/easy.h
/usr/include/curl/mprintf.h
/usr/include/curl/multi.h
/usr/include/curl/stdcheaders.h
/usr/include/curl/typecheck-gcc.h
/usr/lib64/libcurl.so
/usr/lib64/pkgconfig/libcurl.pc
/usr/share/aclocal/libcurl.m4
*Omitting /usr/share/doc and /usr/share/man

Similar info from a working Ubuntu build:
Code:
[COLOR="Sienna"]$ dpkg --get-selections | grep curl|sort
curl install
libcurl3-gnutls install
libcurl3 install
libcurl3-nss install
libcurl4-openssl-dev install
python-pycurl install[/color]
and
Code:
[COLOR="Sienna"]$ dpkg -L libcurl4-openssl-dev 
/usr/lib/x86_64-linux-gnu/libcurl.a
/usr/lib/x86_64-linux-gnu/libcurl.la
/usr/lib/x86_64-linux-gnu/pkgconfig/libcurl.pc
/usr/include/curl/curl.h
/usr/include/curl/curlver.h
/usr/include/curl/easy.h
/usr/include/curl/mprintf.h
/usr/include/curl/stdcheaders.h
/usr/include/curl/multi.h
/usr/include/curl/typecheck-gcc.h
/usr/include/curl/curlbuild.h
/usr/include/curl/curlrules.h
/usr/share/aclocal/libcurl.m4
/usr/lib/x86_64-linux-gnu/libcurl.so[/COLOR]
*Also ommitting /usr/share/[doc||man]

These are also some potentially interesting differences:
Fedora 17:
Code:
# curl --version
curl 7.24.0 (x86_64-redhat-linux-gnu) libcurl/7.24.0 NSS/3.13.5.0 zlib/1.2.5 libidn/1.24 libssh2/1.4.1
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtsp scp sftp smtp smtps telnet tftp
Features: AsynchDNS GSS-Negotiate IDN IPv6 Largefile NTLM NTLM_WB SSL libz
Ubuntu 12.04:
Code:
[COLOR="sienna"]$ curl --version
curl 7.22.0 (x86_64-pc-linux-gnu) libcurl/7.22.0 OpenSSL/1.0.1 zlib/1.2.3.4 libidn/1.23 librtmp/2.3
Protocols: dict file ftp ftps gopher http https imap imaps ldap pop3 pop3s rtmp rtsp smtp smtps telnet tftp
Features: GSS-Negotiate IDN IPv6 Largefile NTLM NTLM_WB SSL libz TLS-SRP [/COLOR]

My ultimate goal is to be able to offer the developer a diff patch making the code more platform independent, or possibly just a note in the readme to help F17 users get the right dependencies.

Thanks for reading this epic post:thumb:
kano
Legendary
*
Offline Offline

Activity: 4620
Merit: 1851


Linux since 1997 RedHat 4


View Profile
October 05, 2012, 09:02:28 AM
 #2

My 11.04 build in my git downloads (e.g. 2.7.6a) works on Fedora 17 - I know coz I run it on Fedora 17 also Smiley
https://github.com/kanoi/cgminer/downloads

... of course I don't have an ATI card in this machine (my desktop) but I have an nVidia using the fusion build of the original nVidia drivers and that also works GPU mining
i.e. I've tried BFL, Icarus, nVidia GPU - all 3 work on Fedora 17 with that binary in my downloads

Edit: I actually run Xubuntu 11.04 in a VirtualBox on Fedora 17 to build the cgminer binaries Smiley

Pool: https://kano.is - low 0.5% fee PPLNS 3 Days - Most reliable Solo with ONLY 0.5% fee   Bitcointalk thread: Forum
Discord support invite at https://kano.is/ Majority developer of the ckpool code - k for kano
The ONLY active original developer of cgminer. Original master git: https://github.com/kanoi/cgminer
Jive Turkey (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
October 05, 2012, 09:59:01 AM
 #3

My 11.04 build in my git downloads (e.g. 2.7.6a) works on Fedora 17 - I know coz I run it on Fedora 17 also Smiley
https://github.com/kanoi/cgminer/downloads

... of course I don't have an ATI card in this machine (my desktop) but I have an nVidia using the fusion build of the original nVidia drivers and that also works GPU mining
i.e. I've tried BFL, Icarus, nVidia GPU - all 3 work on Fedora 17 with that binary in my downloads

Edit: I actually run Xubuntu 11.04 in a VirtualBox on Fedora 17 to build the cgminer binaries Smiley
I saw those and I can confirm 2.7.6a does work on F17 with the ATI HD6870 w/ the current latest driver+SDK+ADL. I'm currently running the one I built on my Ubuntu 12.04 server box. I tend to obsess about these little problems. I'm thinking the Fedora libcurl is the problem, is that why you resorted to building on Ubuntu?

I just find it a little sad that we can build this on Windows and Ubuntu but not Fedora (and maybe not on CentOS or RHEL either), I really want to understand why and try to fix it.
kano
Legendary
*
Offline Offline

Activity: 4620
Merit: 1851


Linux since 1997 RedHat 4


View Profile
October 05, 2012, 12:17:11 PM
 #4

...
I saw those and I can confirm 2.7.6a does work on F17 with the ATI HD6870 w/ the current latest driver+SDK+ADL. I'm currently running the one I built on my Ubuntu 12.04 server box. I tend to obsess about these little problems. I'm thinking the Fedora libcurl is the problem, is that why you resorted to building on Ubuntu?

I just find it a little sad that we can build this on Windows and Ubuntu but not Fedora (and maybe not on CentOS or RHEL either), I really want to understand why and try to fix it.
I build that 2.N.Na coz I'm the 2nd main cgminer dev and coz I GPU mine on a mining only rig - which is xubuntu 11.04 - and since other people use 11.04, and since my sig points to the linux install for xubuntu 11.04 for GPU mining Smiley

Aside: I build bitcoind on Fedora 16/17 without any major trouble

Pool: https://kano.is - low 0.5% fee PPLNS 3 Days - Most reliable Solo with ONLY 0.5% fee   Bitcointalk thread: Forum
Discord support invite at https://kano.is/ Majority developer of the ckpool code - k for kano
The ONLY active original developer of cgminer. Original master git: https://github.com/kanoi/cgminer
dbabo
Newbie
*
Offline Offline

Activity: 41
Merit: 0


View Profile
April 30, 2013, 02:32:31 PM
 #5

...
I saw those and I can confirm 2.7.6a does work on F17 with the ATI HD6870 w/ the current latest driver+SDK+ADL. I'm currently running the one I built on my Ubuntu 12.04 server box. I tend to obsess about these little problems. I'm thinking the Fedora libcurl is the problem, is that why you resorted to building on Ubuntu?

I just find it a little sad that we can build this on Windows and Ubuntu but not Fedora (and maybe not on CentOS or RHEL either), I really want to understand why and try to fix it.
I build that 2.N.Na coz I'm the 2nd main cgminer dev and coz I GPU mine on a mining only rig - which is xubuntu 11.04 - and since other people use 11.04, and since my sig points to the linux install for xubuntu 11.04 for GPU mining Smiley

Aside: I build bitcoind on Fedora 16/17 without any major trouble

I'm trying to run pre-built  binary (3.1.0) on the RHEL 6.4 86 and getting the same error:
Code:
./cgminer
./cgminer: /usr/lib64/libcurl.so.4: no version information available (required by ./cgminer)
./cgminer: /lib64/libc.so.6: version `GLIBC_2.15' not found (required by ./cgminer)
./cgminer: /lib64/libc.so.6: version `GLIBC_2.14' not found (required by ./cgminer)

[az@azlnx cgminer-x86_64-built]$ uname -a
Linux azlnx.XXX 2.6.32-358.2.1.el6.x86_64 #1 SMP Tue Mar 12 14:18:09 CDT 2013 x86_64 x86_64 x86_64 GNU/Linux

rpm -qa | grep curl
libcurl-devel-7.19.7-36.el6_4.x86_64
libcurl-7.19.7-36.el6_4.x86_64
python-pycurl-7.19.0-8.el6.x86_64
curl-7.19.7-36.el6_4.x86_64

ls -l /lib64/libc.so.6 -> libc-2.12.so
/lib64/libc.so.6 -> libc-2.12.so


Please advise.
kano
Legendary
*
Offline Offline

Activity: 4620
Merit: 1851


Linux since 1997 RedHat 4


View Profile
April 30, 2013, 03:44:30 PM
 #6

GLIBC errors means that the OS version doesn't match the binary.
It means the binary can't run on your linux.

In my binaries git I now have 2 Fedora versions:
1) the previous one built on 11.04 that worked on F16 and F17
2) another one (added this week) built on F18 (for F18)

To build the F18 one my versions are:
ncurses-5.9-7.20121017.fc18.x86_64
ncurses-base-5.9-7.20121017.fc18.x86_64
ncurses-devel-5.9-7.20121017.fc18.x86_64
ncurses-libs-5.9-7.20121017.fc18.x86_64
curl-7.27.0-8.fc18.x86_64
libcurl-7.27.0-8.fc18.x86_64
libcurl-devel-7.27.0-8.fc18.x86_64
glibc-common-2.16-30.fc18.x86_64
glibc-headers-2.16-30.fc18.x86_64
glibc-devel-2.16-30.fc18.x86_64
glibc-2.16-30.fc18.x86_64

When the 11.04 version ran on F17 I had this on F17:
ncurses-libs-5.9-4.20120204.fc17.x86_64
ncurses-base-5.9-4.20120204.fc17.x86_64
ncurses-devel-5.9-4.20120204.fc17.x86_64
ncurses-5.9-4.20120204.fc17.x86_64
curl-7.24.0-6.fc17.x86_64
libcurl-7.24.0-6.fc17.x86_64
libcurl-devel-7.24.0-6.fc17.x86_64
glibc-devel-2.15-58.fc17.x86_64
glibc-common-2.15-58.fc17.x86_64
glibc-headers-2.15-58.fc17.x86_64
glibc-2.15-58.fc17.x86_64

You can see the GLIBC versions there are 2.16 and 2.15

Your GLIBC version appears to be 2.12 - so pretty much no chance of something that old working with the binaries.

Also (but not the problem) your curl versions are very old

What it all probably means is that you will need to build it yourself.

Pool: https://kano.is - low 0.5% fee PPLNS 3 Days - Most reliable Solo with ONLY 0.5% fee   Bitcointalk thread: Forum
Discord support invite at https://kano.is/ Majority developer of the ckpool code - k for kano
The ONLY active original developer of cgminer. Original master git: https://github.com/kanoi/cgminer
dbabo
Newbie
*
Offline Offline

Activity: 41
Merit: 0


View Profile
April 30, 2013, 05:06:50 PM
Last edit: April 30, 2013, 06:12:26 PM by dbabo
 #7

GLIBC errors means that the OS version doesn't match the binary.
....
Also (but not the problem) your curl versions are very old

What it all probably means is that you will need to build it yourself.

realized that after i posted. Upgraded from 6.3 to 6.4 ( RHEL). But still rather old libraries.
I'll be building from git .
Thank you for you the help!

P.S. got it compiled.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!