8000 I'm unable to compile it in debian · Issue #1 · r-majere/mjminer · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

I'm unable to compile it in debian #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
enavarrocu opened this issue Oct 8, 2014 · 12 comments
Open

I'm unable to compile it in debian #1

enavarrocu opened this issue Oct 8, 2014 · 12 comments

Comments

@enavarrocu
Copy link

Hello, I have a CPU AMD Sempron 145. When I try to compile in debian I get this.

CFLAGS=-D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -c -o helper.o helper.c
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -o plot plot.c helper.o -lpthread -std=gnu99
/tmp/cckbpc4V.o: In function mnonce': plot.c:(.text+0x3e6): undefined reference tosse4_mshabal_init'
plot.c:(.text+0x420): undefined reference to sse4_mshabal' plot.c:(.text+0x46d): undefined reference tosse4_mshabal_close'
plot.c:(.text+0x4a0): undefined reference to sse4_mshabal_init' plot.c:(.text+0x4bf): undefined reference tosse4_mshabal'
plot.c:(.text+0x50b): undefined reference to sse4_mshabal_close' /tmp/cckbpc4V.o: In functionnonce':
plot.c:(.text+0x78b): undefined reference to shabal_init' plot.c:(.text+0x7bc): undefined reference toshabal'
plot.c:(.text+0x7d5): undefined reference to shabal_close' plot.c:(.text+0x7e8): undefined reference toshabal_init'
plot.c:(.text+0x7ff): undefined reference to shabal' plot.c:(.text+0x812): undefined reference toshabal_close'
collect2: error: ld returned 1 exit status
make: *** [plot] Error 1

@enavarrocu
Copy link
Author

I was able to compile it "manualy" doing this:

CFLAGS=-D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64
gcc -Wall -c -O2 -march=native -o mshabal_sse4.o mshabal_sse4.c
gcc -Wall -c -O2 -march=native -mavx2 -o mshabal256_avx2.o mshabal256_avx2.c
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -o plot plot.c shabal64.o mshabal_sse4.o mshabal256_avx2.o helper.o -lpthread -std=gnu99
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -o optimize optimize.c helper.o
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -DSOLO -o mine mine.c shabal64.o helper.o -lpthread
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -DURAY_POOL -o mine_pool_all mine.c shabal64.o helper.o -lpthread
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -DSHARE_POOL -o mine_pool_share mine.c shabal64.o helper.o -lpthread

@bobloblian
Copy link

For the next guy who follows:

This line needs to replace the top line of the Makefile:

CFLAGS=-D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64

I also need to add the following command:
gcc -Wall -c -O2 -march=native -o shabal64.o shabal64.s

The rest worked:

gcc -Wall -c -O2 -march=native -o mshabal_sse4.o mshabal_sse4.c
gcc -Wall -c -O2 -march=native -mavx2 -o mshabal256_avx2.o mshabal256_avx2.c
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -o plot plot.c shabal64.o mshabal_sse4.o mshabal256_avx2.o helper.o -lpthread -std=gnu99
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -o optimize optimize.c helper.o
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -DSOLO -o mine mine.c shabal64.o helper.o -lpthread
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -DURAY_POOL -o mine_pool_all mine.c shabal64.o helper.o -lpthread
gcc -D LINUX -O2 -Wall -D_FILE_OFFSET_BITS=64 -DSHARE_POOL -o mine_pool_share mine.c shabal64.o helper.o -lpthread

@hheexx
Copy link
hheexx commented Jun 14, 2017

@bobloblian workaround works on ubuntu 16.04. Thanks!

@jxer
Copy link
jxer commented Jun 15, 2017

@bobloblian

does all of this go in the make file? sorry linux noob

"*** missing separator (did you mean TAB instead of 8 spaces?). Stop"

@bobloblian
Copy link

@jxer
The line starting with CFLAGS needs to replace the existing line at the top of the makefile.

The gcc lines are commands that you run from the same directory that the Makefile is in.

@jxer
Copy link
jxer commented Jun 16, 2017

@bobloblian do i still need to run "make" and if so do i run the commands before or after the make commands?

@bobloblian
Copy link

the idea of running make is that it runs the gcc commands for you as per the configuration of the makefile. when you run the gcc commands yourself, you are doing yourself what make would normally do for you...

@jxer
Copy link
jxer commented Jun 16, 2017

@bobloblian bob that makes sense to me but then why are u making changes in the makefile?

i have it running by the way. Ty

@bobloblian
Copy link

gcc will still take some config from the Makefile. try running gcc from outside the directory...

glad you got it going :)

@jxer
Copy link
jxer commented Jun 16, 2017

@bobloblian, ah that makes some sense. first time i ever had to mess with the Makefile

@jxer
Copy link
jxer commented Jun 17, 2017

@bobloblian do you know to resume after stopping, appears this plotter allows resume?

@bobloblian
Copy link

@jxer sorry, don't know. I used it to make a plot all in one shot and it just worked

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants
0