moses-smt / mosesdecoder

Moses, the machine translation system
http://www.statmt.org/moses
GNU Lesser General Public License v2.1
1.58k stars 775 forks source link

compile error in last trunk snapshot #74

Closed ziabary closed 10 years ago

ziabary commented 10 years ago

I've tried to compile snapshot 7e359a8892 but I got compile error.

Compile command: ./bjam --with-xmlrpc-c=$HOME/local/ --with-cmph=$HOME/local/ --with-tcmalloc --install-scripts=$HOME/local/moses --enable-boost-pool -j16 Also I've tried ./bjam witho no other option but unsuccessfull. Error log syas that:

phrase-extract/domain.h:37:21: error: ‘PhraseAlignment’ does not name a type

I've added #include "PhraseAlignment.h" to phrase-extract/domain.h then I get following errors:

phrase-extract/domain.cpp: In member function ‘virtual void MosesTraining::DomainFeature::add(const MosesTraining::ScoreFeatureContext&, std::vector&, std::mapstd::basic_string<char, float>&) const’: phrase-extract/domain.cpp:64:40: error: ‘const class MosesTraining::ExtractionPhrasePair’ has no member named ‘size’ phrase-extract/domain.cpp:65:65: error: no match for ‘operator[]’ in ‘context.MosesTraining::ScoreFeatureContext::phrasePair[i]’ phrase-extract/domain.cpp:67:44: error: no match for ‘operator[]’ in ‘context.MosesTraining::ScoreFeatureContext::phrasePair[i]’ phrase-extract/domain.cpp:69:45: error: no match for ‘operator[]’ in ‘context.MosesTraining::ScoreFeatureContext::phrasePair[i]’ phrase-extract/domain.cpp:72:28: error: ‘const struct MosesTraining::ScoreFeatureContext’ has no member named ‘count’

So I've tried to temporarily supres this error by commenting lines 63-72 in phrase-extract/domain.cpp

now I get several linking errors:

phrase-extract/bin/gcc-4.7/release/debug-symbols-on/link-static/threading-multi/PhraseAlignment.o: In function MosesTraining::PhraseAlignment::create(char*, int, bool)': phrase-extract/PhraseAlignment.cpp:92: undefined reference toMosesTraining::vcbS' phrase-extract/PhraseAlignment.cpp:96: undefined reference to `MosesTraining::vcbT'

hieuhoang commented 10 years ago

i can't reproduce the problem. Try compiling without any bjam arguments and see what you get. Then add 1 argument at a time and see where the problem is.

there is a xmlrpc-c version problem. It appears moses doesn't compile with version xmlrpc-c-1.25.29. I'll double check it in the next few days

On 14/09/14 08:39, S. Mohammad M. Ziabary wrote:

I've tried to compile snapshot 7e359a8 https://github.com/moses-smt/mosesdecoder/commit/7e359a88926cc535630c2c6a2f343eeb842000fe but I got compile error.

Compile command: ./bjam --with-xmlrpc-c=$HOME/local/ --with-cmph=$HOME/local/ --with-tcmalloc --install-scripts=$HOME/local/moses --enable-boost-pool -j16 Also I've tried ./bjam witho no other option but unsuccessfull. Error log syas that:

phrase-extract/domain.h:37:21: error: ‘PhraseAlignment’ does not name a type

I've added #include "PhraseAlignment.h" to phrase-extract/domain.h then I get following errors:

phrase-extract/domain.cpp: In member function ‘virtual void MosesTraining::DomainFeature::add(const MosesTraining::ScoreFeatureContext&, std::vector&, std::mapstd::basic_string<char, float>&) const’: phrase-extract/domain.cpp:64:40: error: ‘const class MosesTraining::ExtractionPhrasePair’ has no member named ‘size’ phrase-extract/domain.cpp:65:65: error: no match for ‘operator[]’ in ‘context.MosesTraining::ScoreFeatureContext::phrasePair[i]’ phrase-extract/domain.cpp:67:44: error: no match for ‘operator[]’ in ‘context.MosesTraining::ScoreFeatureContext::phrasePair[i]’ phrase-extract/domain.cpp:69:45: error: no match for ‘operator[]’ in ‘context.MosesTraining::ScoreFeatureContext::phrasePair[i]’ phrase-extract/domain.cpp:72:28: error: ‘const struct MosesTraining::ScoreFeatureContext’ has no member named ‘count’

So I've tried to temporarily supres this error by commenting lines 63-72 in phrase-extract/domain.cpp

now I get several linking errors:

phrase-extract/bin/gcc-4.7/release/debug-symbols-on/link-static/threading-multi/PhraseAlignment.o: In function |MosesTraining::PhraseAlignment::create(char*, int, bool)': phrase-extract/PhraseAlignment.cpp:92: undefined reference to|MosesTraining::vcbS' phrase-extract/PhraseAlignment.cpp:96: undefined reference to `MosesTraining::vcbT'

— Reply to this email directly or view it on GitHub https://github.com/moses-smt/mosesdecoder/issues/74.

hieuhoang commented 10 years ago

I'm closing this unless you have any more feedback