Post
Topic
Board Announcements (Altcoins)
Re: [ANN] Diamond (DMD) Evolution v 2.0 | Hybrid Security | 25% PoS
by
utahjohn
on 24/03/2016, 20:34:42 UTC
Ran into one I cant find an answer for compiling diamond 2.0.5.7 on Ubuntu 16.04 64 bit armv8

ok another new problem: during linking:

build/scrypt_mine.o: In function 'scrypt(void const*, unsigned long, unsigned int*, void*)':
scrypt_mine.cpp: (.text+05c): undefined reference to 'scrypt_core'
collect2: error: ld returned 1 exit status
Makefile:302: recipe for target 'diamond-qt' failed

I give up for tonight, will wait for new wallet source.  diamond.pro or Makefile or src/makefile.unix needs update for armv8 I don't know why I cant figure this out ... tried qmake USE_PNP=1 xARCHCPU=armv7l ...


maybe try this hint from feldenthorn:
You'd need to replace any instances of armv7l with whatever your output from the terminal command "uname -p" is.

(source: https://bit.diamonds/community/index.php/topic,85.msg510.html#msg510 )

Ahh ... uname -p returns aarch64

did a make clean, qmake xARCHCPU=aarch64 USE_UPNP=1 and make USE_UPNP=1 xARCHCPU=aarch64

it's compiling again should take a while ... we shall see ...

src/scrypt_mine.cpp: In function 'void scrypt (const void*, size_t, uint32_t*, void*)':
src/scrypt_mine.cpp:105:21: error: 'scrypt_core' was not declared in the scope

Makefile:2203: recipe for target 'build/scrypt_mine.o' failed

around line 80 of src/scrypt_mine.cpp scrypt_core is defined as:
extern "C" void scrypt_core(uint32_t *X, uint32_t *V);

where is the code for this function i can't find it defined anywhere

Built wallet for x86-64 before and never had this problem ...

in src there is a file scrypt-arm.S, scrypt-X86.S , scrypt-X86_64.S

scrypt_core() appears to be defined in these files ...

perhaps with aarch64 no scrypt-*.S file is being selected? how do I fix this

if I modify diamond.pro and makefile.unix as suggested change armv7l references to aarch64
I get a very similar problem in scrypt_mine.cpp

error: 'SCRYPT_BUFFER_SIZE' not declared
and
error: 'scrypt_core' was not declared

I am quite certain although unable to fix this that the problem is in scrypt-arm.S or scrypt_mine.cpp and that cpu not being selected properly, so scrypt_core() not being generated.
perhaps a scrypt-aarch64.S needs to be added or just some fixes in the #ifdef in scrypt-arm.S, this is beyond me
In any case aarch64 (armv8) fails to compile.

I'd be happy to get it running 32 bit DMD wallet for now but build scrypts fail there too (armv7l) under aarch64.

@danbi
HELP! LOL


Check that scrypt-arm.S is listed under SOURCES in the qt.pro file.
perhaps a scrypt-aarch64.S needs to be added or just some fixes in the #ifdef in scrypt-arm.S, this is beyond me
In any case aarch64 (armv8) fails to compile.

I'd be happy to get it running 32 bit DMD wallet for now but build scrypts fail there too (armv7l) under aarch64.

around line 73 of scrypt_mine.cpp:
insert to the #elif the following
 ||defined(__aarch64__)

this gets past the SCRYPT_BUFFER_SIZE and scrypt_core() errors
but then I get back to this one again:
src/scrypt_mine.cpp: In function 'void scrypt (const void*, size_t, uint32_t*, void*)':
src/scrypt_mine.cpp:105:21: error: 'scrypt_core' was not declared in the scope
Makefile:302: recipe for target 'diamond-qt' failed

Clearly scrypt_core() is not being generated as we are now in linking phase of build ...

There is no qt.pro file just a diamond.pro used by qmake ...
But yes it is listed in diamond.pro

This I just received in email from  pooler@litecoinpool.org
Quote
As documented, there is no Aarch64 implementation in cpuminer.
I do plan to add one in the future, time allowing.
My email:
Quote
Have you updates this for aarch64 (armv8), I am failing to compile
DMDcoin/Diamond.git it fails when I get to the linking stage.]
file: scrypt-arm.S
So diamond team will have to update this for aarch64

somehow force build of scrypt-arm for aarch64 as armv7 Huh

my complete uname -a
Linux odroid64 3.14.29-37 #1 SMP PREEMPT Tue Mar 15 23:57:29 BRT 2016 aarch64 aarch64 aarch64 GNU/Linux

well this sucks, RPi3, Odroid C2, and any other aarch64 CPU out of luck Sad