Giter Site home page Giter Site logo

Comments (3)

hieuhoang avatar hieuhoang commented on August 22, 2024

Hiya

Thanks for letting us know. Can you please tell me the exact command you
used to compile. If possible, can you please send me the Jamroot file with
the change. I'll check it in

Sent while bumping into things
On 15 Dec 2014 20:32, "Ozan ร‡aฤŸlayan" [email protected] wrote:

Hi,

There are some linking issues with system boost on Fedora Linux 20. Adding:

boost_filesystem

to Jamroot fixes the issue.

โ€”
Reply to this email directly or view it on GitHub
#89.

from mosesdecoder.

ozancaglayan avatar ozancaglayan commented on August 22, 2024

The command used to compile:

./bjam -j8 link=shared debug-symbols=off

Example from the link errors:

gcc.compile.c++ moses/LM/bin/BackwardTest.test/gcc-4.8.3/release/threading-multi/SingleFactor.o
gcc.link mira/bin/gcc-4.8.3/release/threading-multi/mira
gcc.compile.c++ moses/LM/bin/BackwardTest.test/gcc-4.8.3/release/threading-multi/SkeletonLM.o
gcc.link /home/ocaglayan/PhD/mosesdecoder/bin/mira
gcc.compile.c++ moses/bin/gcc-4.8.3/release/threading-multi/FF/SparseHieroReorderingFeatureTest.o
gcc.compile.c++ moses/bin/gcc-4.8.3/release/threading-multi/FeatureVectorTest.o
gcc.compile.c++ moses/bin/gcc-4.8.3/release/threading-multi/ScoreComponentCollectionTest.o
gcc.compile.c++ mert/bin/gcc-4.8.3/release/threading-multi/FeatureDataTest.o
gcc.link mert/bin/gcc-4.8.3/release/threading-multi/feature_data_test
mert/bin/gcc-4.8.3/release/threading-multi/libmert_lib.so: undefined reference to `boost::filesystem::path::stem() const'
mert/bin/gcc-4.8.3/release/threading-multi/libmert_lib.so: undefined reference to `boost::filesystem::detail::dir_itr_close(void*&, void*&)'
mert/bin/gcc-4.8.3/release/threading-multi/libmert_lib.so: undefined reference to `boost::filesystem::path::filename() const'
mert/bin/gcc-4.8.3/release/threading-multi/libmert_lib.so: undefined reference to `boost::filesystem::detail::directory_iterator_construct(boost::filesystem::directory_iterator&, boost::filesystem::path const&, boost::system::error_code*)'
mert/bin/gcc-4.8.3/release/threading-multi/libmert_lib.so: undefined reference to `boost::filesystem::path::compare(boost::filesystem::path const&) const'
mert/bin/gcc-4.8.3/release/threading-multi/libmert_lib.so: undefined reference to `boost::filesystem::detail::directory_iterator_increment(boost::filesystem::directory_iterator&, boost::system::error_code*)'
mert/bin/gcc-4.8.3/release/threading-multi/libmert_lib.so: undefined reference to `boost::filesystem::detail::status(boost::filesystem::path const&, boost::system::error_code*)'
collect2: error: ld returned 1 exit status

    "g++"  -Wl,-R -Wl,"/home/ocaglayan/PhD/mosesdecoder/mert/bin/gcc-4.8.3/release/threading-multi" -Wl,-rpath-link -Wl,"/home/ocaglayan/PhD/mosesdecoder/mert/bin/gcc-4.8.3/release/threading-multi" -o "mert/bin/gcc-4.8.3/release/threading-multi/feature_data_test" -Wl,--start-group "mert/bin/gcc-4.8.3/release/threading-multi/FeatureDataTest.o" "mert/bin/gcc-4.8.3/release/threading-multi/libmert_lib.so"  -Wl,-Bstatic  -Wl,-Bdynamic -lboost_unit_test_framework -ltcmalloc_minimal -ldl -lboost_system -lSegFault -lboost_thread -lrt -Wl,--end-group -pthread

Diff file after changing the Jamroot file:

diff --git a/Jamroot b/Jamroot
index 4514ecb..a7efd84 100644
--- a/Jamroot
+++ b/Jamroot
@@ -166,6 +166,7 @@ requirements += <os>MACOSX:<library>iconv ;
 project : requirements 
   <threading>multi:<define>WITH_THREADS
   <threading>multi:<library>boost_thread
+  <threading>multi:<library>boost_filesystem
   <library>boost_system
   <define>_FILE_OFFSET_BITS=64 <define>_LARGE_FILES
   $(requirements)

from mosesdecoder.

hieuhoang avatar hieuhoang commented on August 22, 2024

I built boost (v1.57) myself and linked moses to it. It works ok
./bjam --with-boost=/home/hieu/workspace/boost_1_57_0 --with-irstlm=/home/hieu/workspace/irstlm-5.80.06/trunk --with-cmph=/home/hieu/workspace/cmph-2.0 -j2
I always recommend building boost yourself as some versions are buggy and the linux distros don't always keep up with the updates. Also, moses (and all other programs that need boost) are sensitive exactly how the library files are named so you need to control it yourself

The instructions to build boost to work with moses is here
http://www.statmt.org/moses/?n=Development.GetStarted

from mosesdecoder.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.