jgarzik / cpuminer

CPU miner for bitcoin
Other
952 stars 2.34k forks source link

can't make #8

Closed rikur closed 13 years ago

rikur commented 13 years ago

bitcoin@optimum:~/cpuminer$ CFLAGS="-O3 -Wall -msse2" ./configure 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... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether to enable maintainer-specific portions of Makefiles... no checking for gcc... gcc checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling... no checking for suffix of executables... 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 for style of include used by make... GNU 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 whether gcc needs -traditional... no checking whether gcc and cc understand -c and -o together... yes checking for ranlib... ranlib checking for ANSI C header files... yes checking for json_loads in -ljansson... yes checking for pthread_create in -lpthread... yes checking for yasm... /usr/bin/yasm checking if yasm version is greater than 1.0.1... yes checking for pkg-config... /usr/bin/pkg-config checking pkg-config is at least version 0.9.0... yes checking for gawk... (cached) mawk checking for curl-config... /usr/bin/curl-config checking for the version of libcurl... 7.18.2 checking for libcurl >= version 7.10.1... yes checking whether libcurl is usable... yes checking for curl_free... yes configure: creating ./config.status config.status: creating Makefile config.status: creating compat/Makefile config.status: creating compat/jansson/Makefile config.status: creating x86_64/Makefile config.status: creating cpuminer-config.h config.status: cpuminer-config.h is unchanged config.status: executing depfiles commands bitcoin@optimum:~/cpuminer$ make make all-recursive make[1]: Entering directory /home/bitcoin/cpuminer' Making all in compat make[2]: Entering directory/home/bitcoin/cpuminer/compat' make[3]: Entering directory /home/bitcoin/cpuminer/compat' make[3]: Nothing to be done forall-am'. make[3]: Leaving directory /home/bitcoin/cpuminer/compat' make[2]: Leaving directory/home/bitcoin/cpuminer/compat' make[2]: Entering directory /home/bitcoin/cpuminer' gcc -DHAVE_CONFIG_H -I. -pthread -fno-strict-aliasing -O3 -Wall -msse2 -MT cpu-miner.o -MD -MP -MF .deps/cpu-miner.Tpo -c -o cpu-miner.o cpu-miner.c cpu-miner.c: In function ‘parse_arg’: cpu-miner.c:454: warning: passing argument 2 of ‘json_load_file’ makes integer from pointer without a cast cpu-miner.c:454: error: too few arguments to function ‘json_load_file’ make[2]: *** [cpu-miner.o] Error 1 make[2]: Leaving directory/home/bitcoin/cpuminer' make[1]: * [all-recursive] Error 1 make[1]: Leaving directory `/home/bitcoin/cpuminer' make: * [all] Error 2

jgarzik commented 13 years ago

What version of jansson are you using?

jgarzik commented 13 years ago

closed due to lack of response, and likelihood that this is user/OS jansson problems (nobody else has reported this)

miry commented 13 years ago

I have this bug too. I have used 2.0.1 of jansson.

banane4fun commented 13 years ago

I have this bug too. I have used 2.1 of jansson.

zapnap commented 13 years ago

I've seen the same issue as well. Jansson 2.1 on latest Ubuntu release.

banane4fun commented 13 years ago

I've tried again with the included jansson but unfortunately without success. here the error message.

make[2]: Betrete Verzeichnis '/home/user/Downloads/jgarzik-cpuminer-602e31b' gcc -DHAVE_CONFIG_H -I. -pthread -fno-strict-aliasing -I/usr/local/include -DHAS_YASM -O3 -Wall -msse2 -ljansson compat/jansson/jansson.h -MT minerd-cpu-miner.o -MD -MP -MF .deps/minerd-cpu-miner.Tpo -c -o minerd-cpu-miner.o test -f 'cpu-miner.c' || echo './'cpu-miner.c gcc: cannot specify -o with -c, -S or -E with multiple files make[2]: * [minerd-cpu-miner.o] Fehler 1 make[2]: Verlasse Verzeichnis '/home/user/Downloads/jgarzik-cpuminer-602e31b' make[1]: * [all-recursive] Fehler 1 make[1]: Verlasse Verzeichnis '/home/user/Downloads/jgarzik-cpuminer-602e31b' make: *\ [all] Fehler 2

miry commented 13 years ago

I solved this problem with several ways:

  1. Solution remove from repository libjansson-dev
  2. Fix configure file to use jansson from contrib directory

banane4fun: It is my correct line

 gcc -DHAVE_CONFIG_H -I. -pthread -fno-strict-aliasing -I./compat/jansson    -O3 -Wall -msse2 -MT minerd-cpu-miner.o -MD -MP -MF .deps/minerd-cpu-miner.Tpo -c -o minerd-cpu-miner.o `test -f 'cpu-miner.c' || echo './'`cpu-miner.c