I followed this guide loosely and successfully compiled OpenSSL, BDB and Boost (compiling for the headless version, so no QT, protoc, libpng or qrencode needed). Then I set the appropriate include and library files in the gcc specs file, so that they could be found and ran autogen.sh and configure. All went well and a makefile was generated in the root directory, which I ran. It compiled all modules successfully and then tried to build bitcoind (I believe), outputting:
Making all in src
make[1]: Entering directory `/i/code/bitcoin_git/bitcoin/src'
make all-recursive
make[2]: Entering directory `/i/code/bitcoin_git/bitcoin/src'
Making all in .
make[3]: Entering directory `/i/code/bitcoin_git/bitcoin/src'
CXXLD bitcoind.exe
This failed however with a host of errors (I included the head only, but I think the problem can be derived from this, as the other errors are very alike):
libbitcoin_server.a(main.o): In function `CLevelDBBatch':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.h:25: undefined reference to `leveldb::WriteBatch::WriteBatch()'
libbitcoin_server.a(main.o): In function `~CLevelDBBatch':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.h:25: undefined reference to `leveldb::WriteBatch::~WriteBatch()'
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.h:25: undefined reference to `leveldb::WriteBatch::~WriteBatch()'
libbitcoin_server.a(leveldbwrapper.o): In function `Z11HandleErrorRKN7leveldb6StatusE':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.cpp:18: undefined reference to `leveldb::Status::ToString() const'
libbitcoin_server.a(leveldbwrapper.o): In function `ZN15CLevelDBWrapperC2ERKN5boost10filesystem4pathEjbb':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.cpp:38: undefined reference to `leveldb::Options::Options()'
libbitcoin_server.a(leveldbwrapper.o): In function `GetOptions':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.cpp:29: undefined reference to `leveldb::Options::Options()'
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.cpp:30: undefined reference to `leveldb::NewLRUCache(unsigned int)'
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.cpp:32: undefined reference to `leveldb::NewBloomFilterPolicy(int)'
libbitcoin_server.a(leveldbwrapper.o): In function `ZN15CLevelDBWrapperC2ERKN5boost10filesystem4pathEjbb':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.cpp:52: undefined reference to `leveldb::DestroyDB(std::string const&, leveldb::Options const&)'
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.cpp:57: undefined reference to `leveldb::DB::Open(leveldb::Options const&, std::string const&, leveldb::DB**)'
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.cpp:47: undefined reference to `leveldb::Env::Default()'
libbitcoin_server.a(txdb.o): In function `CLevelDBBatch':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.h:25: undefined reference to `leveldb::WriteBatch::WriteBatch()'
libbitcoin_server.a(txdb.o): In function `Write':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.h:44: undefined reference to `leveldb::WriteBatch::Put(leveldb::Slice const&, leveldb::Slice const&)'
libbitcoin_server.a(txdb.o): In function `~CLevelDBBatch':
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.h:25: undefined reference to `leveldb::WriteBatch::~WriteBatch()'
i:\code\bitcoin_git\bitcoin\src/leveldbwrapper.h:25: undefined reference to `leveldb::WriteBatch::~WriteBatch()'
...
...
...
I checked if libleveldb.a and libmemenv.a were available, and they were (located at .../src/leveldb).
Could anyone point me in the right direction?
I followed the instructions to the letter and I'm having this same problem when linking bitcoind.exe. Does anyone know what I'm missing here?