fangdu64/BDT

Compilation Errors

Opened this issue · 6 comments

Hi, I'm trying to install BDT on Linux. However, when trying to compile bigMat in BDT-0.1.4/build/linux/bigMat, I run into some linking issues. This arises when the following line in the BDT-0.1.4/build/linux/bigMat/Makefile is executed:

else \
                echo "Linux"; \
                $(CXX) $(CXXFLAGS) $(LDFLAGS) -o $@ $(OBJS) -lFreeze -lbdtCore -lbdtUtil -lBamtools -lz -llapack -lrefblas -lgfortran $(LIBS); \
        fi

The error trace is as below:

/users/surag/software/R_packages/BDT/bdt/lib/libbdtCore.a(FeatureDomainDB.o): In function `CFeatureDomainDB::~CFeatureDomainDB()':
FeatureDomainDB.cpp:(.text+0xa64): undefined reference to `Freeze::upCast(Freeze::Connection*)'
/users/surag/software/R_packages/BDT/bdt/lib/libbdtCore.a(FeatureDomainDB.o): In function `CFeatureDomainDB::RqstNewFeatureDomainID(int&)':
FeatureDomainDB.cpp:(.text+0xb42): undefined reference to `Freeze::TransactionHolder::TransactionHolder(IceInternal::Handle<Freeze::Connection> const&)'
FeatureDomainDB.cpp:(.text+0x1178): undefined reference to `Freeze::TransactionHolder::commit()'
FeatureDomainDB.cpp:(.text+0x11ae): undefined reference to `Freeze::TransactionHolder::~TransactionHolder()'
FeatureDomainDB.cpp:(.text+0x1532): undefined reference to `Freeze::TransactionHolder::~TransactionHolder()'
/users/surag/software/R_packages/BDT/bdt/lib/libbdtCore.a(FeatureDomainDB.o): In function `CFeatureDomainDB::Initilize()':
FeatureDomainDB.cpp:(.text+0x1711): undefined reference to `Freeze::IteratorHelper::create(Freeze::MapHelper const&, bool)'
/users/surag/software/R_packages/BDT/bdt/lib/libbdtCore.a(FeatureDomainDB.o): In function `CFeatureDomainDB::CFeatureDomainDB(IceInternal::Handle<Ice::Communicator>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
FeatureDomainDB.cpp:(.text+0x1eac): undefined reference to `Freeze::createConnection(IceInternal::Handle<Ice::Communicator> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
...

Hi, thanks for the info. Looks like the dependent libs have not been built. Did you build the whole BDT by
$ tar xfz v0.1.4.tar.gz
$ cd BDT-v0.1.4
$ make bdt_home={install_path}
This will build all dependencies and then bigMat, bdvd, bigKmeans etc.

Yes that is how I’m building it, but I get the error midway through the make. I’ve been able to narrow it down to this. It successfully builds all third party libraries including Ice.

Can I ask what is your Linux distribution and GCC version?

Ubuntu 16.04.3 LTS
gcc 6.5.0

Can you check if libFreeze is built successfully at
BDT-0.1.4/ThirdParty/Ice/Ice-3.5.1/cpp/lib/
Do you see below files?
libFreeze.so libFreeze.so.3.5.1 libIce.so.35 libIceUtil.so libIceUtil.so.3.5.1 libSlice.so.35
libFreeze.so.35 libIce.so libIce.so.3.5.1 libIceUtil.so.35 libSlice.so libSlice.so.3.5.1

Yes