genesismining / sgminer-gm

A multi-algo GPU miner
GNU General Public License v3.0
340 stars 146 forks source link

Can't compile with jansson 2.11 (with jansson 2.10 it's compiling) #121

Open Zenitur opened 6 years ago

Zenitur commented 6 years ago

I'd test it with Jansson 2.10 (success) 2.11 (fail) and master GIT (fail).

  CCLD     sgminer
submodules/jansson/src/.libs/libjansson.a(value.o): In function `json_sprintf':
/home/user/sgminer-gm-5.5.6/submodules/jansson/src/value.c:806: multiple definition of `json_sprintf'
sgminer-config_parser.o:/home/user/sgminer-gm-5.5.6/config_parser.c:432: first defined here
ku4eto commented 6 years ago

Go into the submodules directory. Delete the old Jansson folder. Its REALLY old branch. Then git clone the Master release of Jansson. This worked for me. Tried to do it in Cygwin. In the end, i got a "working" executable. Although i get now "Error opening terminal: cygwin." and for some reason it requires all of the Cygwin binaries (DLLs)...

Zenitur commented 6 years ago

When I'm downloading Sgminer-gm sources from Github, the "jansson" directory is always empty. I didn't know why. So I'm doing that every time when I compile it. Also I download ADL_SDK

ku4eto commented 6 years ago

The Build instructions are seriously outdated. It took me about 2 hours, of trying non-stop and searching for solution to maybe 5 different issues. I will try to start from a scratch and do it again, to see where it fails and how i managed to fix it. Also, any ideas on the "Error opening terminal: cygwin." ?

pe4enko commented 6 years ago

jansson folder is empty because it is git submodule. You should run commands git submodule init git submodule update

ku4eto commented 6 years ago

Hm, the weird thing is, i got stuck here as well.

Doing the following steps:

submodules/ - git clone jansson ./autogen.sh git submodule init git submodule update AMDAPPSDKROOT= CFLAGS='-O2 -march=native' \ CPPFLAGS=-I/usr/include/ncurses ./configure make -j8

Getting same error as Zenitur.

Tried putting up autoreconf -i and trying various combinations of all the commands above. No luck.

Still no idea, how i managed to create an executable.

NOTE: This is a CYGWIN64 executable. It can run ONLY in Cygwin.

http://s000.tinyupload.com/index.php?file_id=61459293597233757312

pe4enko commented 6 years ago

Not need run command git clone janson only need run at root project folder with empty janson folder git submodule init git submodule update