Skip to content

Instantly share code, notes, and snippets.

@marcinwol
Created August 16, 2015 01:19
Show Gist options
  • Star 17 You must be signed in to star a gist
  • Fork 7 You must be signed in to fork a gist
  • Save marcinwol/073f7cff475b33e9c7bc to your computer and use it in GitHub Desktop.
Save marcinwol/073f7cff475b33e9c7bc to your computer and use it in GitHub Desktop.
Ubuntu 14:04: compile CPUMiner/minerd (forked by LucasJones & Wolf) for Monero mining
# get git to install it
sudo apt-get install git
# dependencies
sudo apt-get install build-essential autotools-dev autoconf libcurl3 libcurl4-gnutls-dev
# download latest version
git clone https://github.com/wolf9466/cpuminer-multi
cd cpuminer-multi/
# compile
./autogen.sh
CFLAGS="-march=native" ./configure
make
#install
sudo make install
@obelich
Copy link

obelich commented Aug 30, 2017

Hiyas i have compiled it using you tutorial and i try to mine in eobot and i get this
minerd -o stratum+tcp://scrypt.eobot.com:4444 --userpass eobot.903012:x

[2017-08-29 17:30:40] Starting Stratum on stratum+tcp://scrypt.eobot.com:4444
[2017-08-29 17:30:40] 7 miner threads started, using 'cryptonight' algorithm.
[2017-08-29 17:31:03] Stratum authentication failed
[2017-08-29 17:31:03] ...retry after 10 seconds

@Skeyelab
Copy link

Skeyelab commented Nov 9, 2017

@obelich - it compiled, you have a pool issue.

@omater1
Copy link

omater1 commented Nov 27, 2017

I need help to compile in architecture s390x (Big Edians) IBM Z/linux Machine:

cpuminer-multi# CFLAGS="-march=native" ./configure
checking build system type... s390x-ibm-linux-gnu
checking host system type... s390x-ibm-linux-gnu
checking target system type... s390x-ibm-linux-gnu
checking for a BSD-compatible install... /usr/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 whether to enable maintainer-specific portions of Makefiles... no
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... no
configure: error: in /home/xxx/Donwload/cpuminer-multi': configure: error: C compiler cannot create executables See config.log' for more details

@omater1
Copy link

omater1 commented Nov 27, 2017

This is log:
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by cpuminer configure 2.3.3, which was
generated by GNU Autoconf 2.69. Invocation command line was

$ ./configure

---------

Platform.

---------

hostname = sirdevapvseg01
uname -m = s390x
uname -r = 3.16.0-4-s390x
uname -s = Linux
uname -v = #1 SMP Debian 3.16.36-1+deb8u2 (2016-10-19)

/usr/bin/uname -p = unknown
/bin/uname -X = unknown

/bin/arch = unknown
/usr/bin/arch -k = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo = unknown
/bin/machine = unknown
/usr/bin/oslevel = unknown
/bin/universe = unknown

PATH: /usr/local/sbin
PATH: /usr/local/bin
PATH: /usr/sbin
PATH: /usr/bin
PATH: /sbin
PATH: /bin

-----------

Core tests.

-----------

configure:2340: checking build system type
configure:2354: result: s390x-ibm-linux-gnu
configure:2374: checking host system type
configure:2387: result: s390x-ibm-linux-gnu
configure:2407: checking target system type
configure:2420: result: s390x-ibm-linux-gnu
configure:2463: checking for a BSD-compatible install
configure:2531: result: /usr/bin/install -c
configure:2542: checking whether build environment is sane
configure:2597: result: yes
configure:2748: checking for a thread-safe mkdir -p
configure:2787: result: /bin/mkdir -p
configure:2794: checking for gawk
configure:2810: found /usr/bin/gawk
configure:2821: result: gawk
configure:2832: checking whether make sets $(MAKE)
configure:2854: result: yes
configure:2883: checking whether make supports nested variables
configure:2900: result: yes
configure:3030: checking whether to enable maintainer-specific portions of Makefiles
configure:3039: result: no
configure:3067: checking for style of include used by make
configure:3095: result: GNU
configure:3166: checking for gcc
configure:3182: found /usr/bin/gcc
configure:3193: result: gcc
configure:3422: checking for C compiler version
configure:3431: gcc --version >&5
gcc (Debian 4.9.2-10) 4.9.2
Copyright (C) 2014 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:3442: $? = 0
configure:3431: gcc -v >&5
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/s390x-linux-gnu/4.9/lto-wrapper
Target: s390x-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 4.9.2-10' --with-bugurl=file:///usr/share/doc/gcc-4.9/README.Bugs --enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.9 --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.9 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libitm --disable-libsanitizer --disable-libquadmath --enable-plugin --with-system-zlib --disable-browser-plugin --enable-java-awt=gtk --enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.9-s390x/jre --enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.9-s390x --with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.9-s390x --with-arch-directory=s390x --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --enable-objc-gc --enable-multiarch --with-long-double-128 --enable-multilib --enable-checking=release --build=s390x-linux-gnu --host=s390x-linux-gnu --target=s390x-linux-gnu
Thread model: posix
gcc version 4.9.2 (Debian 4.9.2-10)
configure:3442: $? = 0
configure:3431: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:3442: $? = 4
configure:3431: gcc -qversion >&5
gcc: error: unrecognized command line option '-qversion'
gcc: fatal error: no input files
compilation terminated.
configure:3442: $? = 4
configure:3462: checking whether the C compiler works
configure:3484: gcc -march=native conftest.c >&5
gcc: error: unrecognized argument in option '-march=native'
gcc: note: valid arguments to '-march=' are: g5 g6 z10 z196 z9-109 z9-ec z900 z990 zEC12
configure:3488: $? = 1
configure:3526: result: no
configure: failed program was:
| /* confdefs.h /
| #define PACKAGE_NAME "cpuminer"
| #define PACKAGE_TARNAME "cpuminer"
| #define PACKAGE_VERSION "2.3.3"
| #define PACKAGE_STRING "cpuminer 2.3.3"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define PACKAGE "cpuminer"
| #define VERSION "2.3.3"
| /
end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:3531: error: in /home/alfil/Donwload/cpuminer-multi': configure:3533: error: C compiler cannot create executables See config.log' for more details

----------------

Cache variables.

----------------

ac_cv_build=s390x-ibm-linux-gnu
ac_cv_env_CCASFLAGS_set=
ac_cv_env_CCASFLAGS_value=
ac_cv_env_CCAS_set=
ac_cv_env_CCAS_value=
ac_cv_env_CC_set=
ac_cv_env_CC_value=
ac_cv_env_CFLAGS_set=set
ac_cv_env_CFLAGS_value=-march=native
ac_cv_env_CPPFLAGS_set=
ac_cv_env_CPPFLAGS_value=
ac_cv_env_CPP_set=
ac_cv_env_CPP_value=
ac_cv_env_LDFLAGS_set=
ac_cv_env_LDFLAGS_value=
ac_cv_env_LIBS_set=
ac_cv_env_LIBS_value=
ac_cv_env_build_alias_set=
ac_cv_env_build_alias_value=
ac_cv_env_host_alias_set=
ac_cv_env_host_alias_value=
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_host=s390x-ibm-linux-gnu
ac_cv_path_install='/usr/bin/install -c'
ac_cv_path_mkdir=/bin/mkdir
ac_cv_prog_AWK=gawk
ac_cv_prog_ac_ct_CC=gcc
ac_cv_prog_make_make_set=yes
ac_cv_target=s390x-ibm-linux-gnu
am_cv_make_support_nested_variables=yes

-----------------

Output variables.

-----------------

ACLOCAL='${SHELL} /home/alfil/Donwload/cpuminer-multi/missing aclocal-1.14'
ALLOCA=''
AMDEPBACKSLASH=''
AMDEP_FALSE='#'
AMDEP_TRUE=''
AMTAR='$${TAR-tar}'
AM_BACKSLASH=''
AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
AM_DEFAULT_VERBOSITY='1'
AM_V='$(V)'
ARCH_ARM_FALSE=''
ARCH_ARM_TRUE=''
ARCH_x86_64_FALSE=''
ARCH_x86_64_TRUE=''
ARCH_x86_FALSE=''
ARCH_x86_TRUE=''
AUTOCONF='${SHELL} /home/alfil/Donwload/cpuminer-multi/missing autoconf'
AUTOHEADER='${SHELL} /home/alfil/Donwload/cpuminer-multi/missing autoheader'
AUTOMAKE='${SHELL} /home/alfil/Donwload/cpuminer-multi/missing automake-1.14'
AWK='gawk'
CC='gcc'
CCAS=''
CCASDEPMODE=''
CCASFLAGS=''
CCDEPMODE=''
CFLAGS='-march=native'
CPP=''
CPPFLAGS=''
CYGPATH_W='echo'
DEFS=''
DEPDIR='.deps'
DISABLE_LINUX_HUGEPAGES_FALSE=''
DISABLE_LINUX_HUGEPAGES_TRUE=''
ECHO_C=''
ECHO_N='-n'
ECHO_T=''
EGREP=''
EXEEXT=''
GREP=''
HAVE_WINDOWS_FALSE=''
HAVE_WINDOWS_TRUE=''
INSTALL_DATA='${INSTALL} -m 644'
INSTALL_PROGRAM='${INSTALL}'
INSTALL_SCRIPT='${INSTALL}'
INSTALL_STRIP_PROGRAM='$(install_sh) -c -s'
JANSSON_LIBS=''
LDFLAGS=''
LIBCURL=''
LIBCURL_CPPFLAGS=''
LIBOBJS=''
LIBS=''
LTLIBOBJS=''
MAINT='#'
MAINTAINER_MODE_FALSE=''
MAINTAINER_MODE_TRUE='#'
MAKEINFO='${SHELL} /home/alfil/Donwload/cpuminer-multi/missing makeinfo'
MKDIR_P='/bin/mkdir -p'
OBJEXT=''
PACKAGE='cpuminer'
PACKAGE_BUGREPORT=''
PACKAGE_NAME='cpuminer'
PACKAGE_STRING='cpuminer 2.3.3'
PACKAGE_TARNAME='cpuminer'
PACKAGE_URL=''
PACKAGE_VERSION='2.3.3'
PATH_SEPARATOR=':'
PTHREAD_FLAGS=''
PTHREAD_LIBS=''
RANLIB=''
SET_MAKE=''
SHELL='/bin/bash'
STRIP=''
USE_LOBOTOMIZED_AES_FALSE=''
USE_LOBOTOMIZED_AES_TRUE=''
VERSION='2.3.3'
WANT_JANSSON_FALSE=''
WANT_JANSSON_TRUE=''
WS2_LIBS=''
_libcurl_config=''
ac_ct_CC='gcc'
am__EXEEXT_FALSE=''
am__EXEEXT_TRUE=''
am__fastdepCCAS_FALSE=''
am__fastdepCCAS_TRUE=''
am__fastdepCC_FALSE=''
am__fastdepCC_TRUE=''
am__include='include'
am__isrc=''
am__leading_dot='.'
am__nodep='_no'
am__quote=''
am__tar='$${TAR-tar} chof - "$$tardir"'
am__untar='$${TAR-tar} xf -'
bindir='${exec_prefix}/bin'
build='s390x-ibm-linux-gnu'
build_alias=''
build_cpu='s390x'
build_os='linux-gnu'
build_vendor='ibm'
datadir='${datarootdir}'
datarootdir='${prefix}/share'
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
dvidir='${docdir}'
exec_prefix='NONE'
host='s390x-ibm-linux-gnu'
host_alias=''
host_cpu='s390x'
host_os='linux-gnu'
host_vendor='ibm'
htmldir='${docdir}'
includedir='${prefix}/include'
infodir='${datarootdir}/info'
install_sh='${SHELL} /home/alfil/Donwload/cpuminer-multi/install-sh'
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
localedir='${datarootdir}/locale'
localstatedir='${prefix}/var'
mandir='${datarootdir}/man'
mkdir_p='$(MKDIR_P)'
oldincludedir='/usr/include'
pdfdir='${docdir}'
prefix='NONE'
program_transform_name='s,x,x,'
psdir='${docdir}'
sbindir='${exec_prefix}/sbin'
sharedstatedir='${prefix}/com'
sysconfdir='${prefix}/etc'
target='s390x-ibm-linux-gnu'
target_alias=''
target_cpu='s390x'
target_os='linux-gnu'
target_vendor='ibm'

-----------

confdefs.h.

-----------

/* confdefs.h */
#define PACKAGE_NAME "cpuminer"
#define PACKAGE_TARNAME "cpuminer"
#define PACKAGE_VERSION "2.3.3"
#define PACKAGE_STRING "cpuminer 2.3.3"
#define PACKAGE_BUGREPORT ""
#define PACKAGE_URL ""
#define PACKAGE "cpuminer"
#define VERSION "2.3.3"

configure: exit 77

@Litas-dev
Copy link

died

@KoryKor
Copy link

KoryKor commented Feb 20, 2018

Ребят, выручайте, нужно точно такой же Майнер, чтоб можно было вклеить его сюда sudo apt-get update
sudo apt-get -y install git make
automake gcc screen libcurl4-openssl-dev libmysqlclient-dev
sudo apt-get -y install git && sudo apt-get -y install build-essential autotools-dev autoconf libcurl3 libcurl4-gnutls-dev && git clone https://github.com/wolf9466/cpuminer-multi/ && cd cpuminer-multi/ && ./autogen.sh && CFLAGS="-march=native" && ./configure && sudo make install && nohup ./minerd -a cryptonight -o stratum+tcp://xmr.pool.minergate.com:45560 -u Email -p x

@esemi
Copy link

esemi commented Mar 14, 2018

А ты прикольный =)

@JoseAlmela
Copy link

JoseAlmela commented Mar 20, 2018

Hello everybody,
I get an unexpected compiling error:

In file included from cryptonight_aesni.c:2:0:
cryptonight.h:65:6: note: expected ‘uint64_t *’ but argument is of type ‘union hash_state *’
cryptonight_aesni.c:166:4: error: impossible register constraint in ‘asm’
cryptonight_aesni.c:222:1: error: impossible register constraint in ‘asm’
cryptonight_aesni.c:222:1: error: impossible register constraint in ‘asm’
cryptonight_aesni.c:166:4: error: impossible register constraint in ‘asm’
cryptonight_aesni.c:222:1: error: impossible register constraint in ‘asm’
cryptonight_aesni.c:222:1: error: impossible register constraint in ‘asm’
make[1]: *** [minerd-cryptonight_aesni.o] Error 1
make[1]: se sale del directorio `/home/pepe/cpuminer-multi'
make: *** [install-recursive] Error 1

All the previous steps went web (autogen, configure...).
Thank you very much.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment