Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 31 Aug 2014 20:39:27 +0400
From:      Dmitry Sivachenko <demon@FreeBSD.org>
To:        office@FreeBSD.org
Subject:   Need some help with compiling boost-dependent program
Message-ID:  <9AB609D1-F643-4F77-B2F9-AD32F8988DFD@FreeBSD.org>

next in thread | raw e-mail | index | archive | help
Hello Boost maintainers!

I am trying to port mosesdecoder program (http://www.statmt.org/moses/) =
to FreeBSD-10/stable.
It uses Boost heavily and depends on other libraries which are built =
using gcc-4.7.

On some stage it fails to link with reasons unknown to me.

I suspect this may be because Boost is built with clang, I build =
mosesdecoder with clang and other libraries were built using gcc (4.7).  =
May be I am wrong.

The error is the following:

=
moses/bin/clang-linux-3.4.1/release/debug-symbols-on/threading-multi/libmo=
ses.so
: undefined reference to =
`randlm::Vocab::getWordID(std::__1::basic_string<char,
std::__1::char_traits<char>, std::__1::allocator<char> > const&)'
=
moses/bin/clang-linux-3.4.1/release/debug-symbols-on/threading-multi/libmo=
ses.so
: undefined reference to =
`lmContainer::CreateLanguageModel(std::__1::basic_strin
g<char, std::__1::char_traits<char>, std::__1::allocator<char> >, float, =
float)'
=
moses/bin/clang-linux-3.4.1/release/debug-symbols-on/threading-multi/libmo=
ses.so
: undefined reference to =
`randlm::RandLM::initRandLM(std::__1::basic_string<char
, std::__1::char_traits<char>, std::__1::allocator<char> > const&, int, =
int)'
clang++: error: linker command failed with exit code 1 (use -v to see =
invocation
)

though linking command includes -lRandLM explicitly.

You can get tarball for unfinished port so you can easily reproduce this =
here:
http://people.freebsd.org/~demon/mosesdecoder.tar.gz

Any help would be greatly appreciated.
Build log is redirected to ${WRKSRC}/build.log to simplify analysis.

Thanks in advance!




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9AB609D1-F643-4F77-B2F9-AD32F8988DFD>