Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: jawotiy116 on May 22, 2021, 11:11:25 PM



Title: Bitcoind error undefined reference to `GetBlockValue(int, long long const&)'
Post by: jawotiy116 on May 22, 2021, 11:11:25 PM
Hello  :),

I am trying to compile bitcoin in Ubuntu and i am getting the below error

robot@ubuntu:~/Documents/bitcoin-0.10.0$ make
Making all in src
make[1]: Entering directory `/home/robot/Documents/bitcoin-0.10.0/src'
make[2]: Entering directory `/home/robot/Documents/bitcoin-0.10.0/src'
make[3]: Entering directory `/home/robot/Documents/bitcoin-0.10.0/src/secp256k1'
make[3]: Leaving directory `/home/robot/Documents/bitcoin-0.10.0/src/secp256k1'
  CXXLD    bitcoind
libbitcoin_server.a(libbitcoin_server_a-main.o): In function `ConnectBlock(CBlock const&, CValidationState&, CBlockIndex*, CCoinsViewCache&, bool)':
/home/robot/Documents/bitcoin-0.10.0/src/main.cpp:1752: undefined reference to `GetBlockValue(int, long long const&)'
/home/robot/Documents/bitcoin-0.10.0/src/main.cpp:1755: undefined reference to `GetBlockValue(int, long long const&)'
libbitcoin_server.a(libbitcoin_server_a-miner.o): In function `CreateNewBlock(CScript const&)':
/home/robot/Documents/bitcoin-0.10.0/src/miner.cpp:323: undefined reference to `GetBlockValue(int, long long const&)'
collect2: error: ld returned 1 exit status
make[2]: *** [bitcoind] Error 1
make[2]: Leaving directory `/home/robot/Documents/bitcoin-0.10.0/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/robot/Documents/bitcoin-0.10.0/src'
make: *** [all-recursive] Error 1

Could anyone help me please..

Thank you !!


Title: Re: Bitcoind error undefined reference to `GetBlockValue(int, long long const&)'
Post by: gmaxwell on May 22, 2021, 11:23:24 PM
You're compiling an old, unsupported, and broken version.  The current version is 0.21.1 which is available at https://bitcoincore.org/en/download/

There was no GetBlockValue in 0.10.  You're either trying to get help with some altcoin and concealing it to waste Bitcoiner time, or you haven't run make clean first.  But regardless, you shouldn't be using that code.


Title: Re: Bitcoind error undefined reference to `GetBlockValue(int, long long const&)'
Post by: odolvlobo on May 24, 2021, 05:58:12 PM
You're compiling an old, unsupported, and broken version.  The current version is 0.21.1 which is available at https://bitcoincore.org/en/download/

There was no GetBlockValue in 0.10.  You're either trying to get help with some altcoin and concealing it to waste Bitcoiner time, or you haven't run make clean first.  But regardless, you shouldn't be using that code.


Salty, eh?


Title: Re: Bitcoind error undefined reference to `GetBlockValue(int, long long const&)'
Post by: NotATether on May 24, 2021, 06:21:19 PM
In my opinion, people should be required to display their [any] modifications to software they're compiling before they can post build logs and ask for compile help. Speaking from experience.


Title: Re: Bitcoind error undefined reference to `GetBlockValue(int, long long const&)'
Post by: DireWolfM14 on May 24, 2021, 08:57:55 PM
make clean first.

^This.
Last night I was trying to compile Pasta.alla.Ragu and realized that my working directory was fucked.  I was unable to find pot.lid.asy in the default location, I could only find lid.nopot, which would not suffice.  I had noticed in the past that you can get by with pot.nolid, although it's less efficient.   Sometimes it can be found in /home/kitchen/stove/top, but it was missing from that location as well.  I decided to try executing sudo find /home/kitchen -n pot.  

The results were troubling:
/home/kitchen/sink/bottom/fishy_smell/pot.stink

So now the real work began:
sudo roll-up -sleeves
mv /home/kitchen/sink/dirty.dishes /home/kitchen/dishwasher/rinsed.dishes
cd /home/kitchen/dishwasher
make clean
cd /home/kitchen/sink
make clean
sudo ls -la /home/kitchen/sink/drain-trap
sudo touch /home/kitchen/sink/drain-trap/yuck 2> /dev/null


It's a wonder I ever get out of bed!  So yeah, make clean first.