Moses Support Digest:Moses compilation problem on fedora 11

[Moses-support] Moses compilation problem on fedora 11

Hi guys,
I try to build moses but make returns errors. What to do?
TIA

[b...@bozy-fedora11 mosesdecoder]$ make -j 2
make all-recursive
make[1]: Entering directory `/home/bozy/moses/mosesdecoder’
Making all in moses/src
make[2]: Entering directory `/home/bozy/moses/mosesdecoder/moses/src’
make all-am
make[3]: Entering directory `/home/bozy/moses/mosesdecoder/moses/src’
g++ -DHAVE_CONFIG_H -I. -I../.. -W -Wall -ffor-scope
-D_FILE_OFFSET_BITS=64 -D_LARGE_FILES
-I/home/bozy/moses/irstlm/include -g -O2 -MT AlignmentPhrase.o -MD
-MP -MF .deps/AlignmentPhrase.Tpo -c -o AlignmentPhrase.o
AlignmentPhrase.cpp
g++ -DHAVE_CONFIG_H -I. -I../.. -W -Wall -ffor-scope
-D_FILE_OFFSET_BITS=64 -D_LARGE_FILES
-I/home/bozy/moses/irstlm/include -g -O2 -MT AlignmentPair.o -MD -MP
-MF .deps/AlignmentPair.Tpo -c -o AlignmentPair.o AlignmentPair.cpp
In file included from
/usr/lib/gcc/i586-redhat-linux/4.4.0/../../../../include/c++/4.4.0/cstdlib:69,
from Util.h:35,
from AlignmentPair.h:28,
from AlignmentPair.cpp:22:
/usr/include/stdlib.h:351: error: expected ‘;’ before ‘*’ token
/usr/include/stdlib.h:352: error: expected ‘;’ before ‘*’ token
/usr/include/stdlib.h:353: error: expected ‘;’ before ‘*’ token
/usr/include/stdlib.h:357: error: expected ‘;’ before ‘*’ token
/usr/include/stdlib.h:361: error: ‘int32_t’ has not been declared
make[3]: *** [AlignmentPair.o] Error 1
make[3]: *** Waiting for unfinished jobs….
In file included from
/usr/lib/gcc/i586-redhat-linux/4.4.0/../../../../include/c++/4.4.0/cstdlib:69,
from Util.h:35,
from AlignmentElement.h:27,
from AlignmentPhrase.h:26,
from AlignmentPhrase.cpp:22:
/usr/include/stdlib.h:351: error: expected ‘;’ before ‘*’ token
/usr/include/stdlib.h:352: error: expected ‘;’ before ‘*’ token
/usr/include/stdlib.h:353: error: expected ‘;’ before ‘*’ token
/usr/include/stdlib.h:357: error: expected ‘;’ before ‘*’ token
/usr/include/stdlib.h:361: error: ‘int32_t’ has not been declared
make[3]: *** [AlignmentPhrase.o] Error 1
make[3]: Leaving directory `/home/bozy/moses/mosesdecoder/moses/src’
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/bozy/moses/mosesdecoder/moses/src’
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/bozy/moses/mosesdecoder’
make: *** [all] Error 2


Re:[Moses-support] Moses compilation problem on fedora 11

hi bozydar

the gcc compiler on fedora seems to include the experimental new c++
standard.

to compile moses in gcc 4.4, you have to compile with the switch
-std=c++0x
i’ve tested it on my fedora 11 and it works.

Since moses uses automake, you should add this flag to the 3 Makefile.am files in
moses/src
moses-cmd/src
misc
eg.
AM_CPPFLAGS=….. -std=c++0x

I’m not going to check it in as it breaks compilation on gcc before 4.4. I’ll try & find a way round this soon

NOTICE:This is digested from the Moses-support mailing list, which supports for the moses SMT decoder.

Related posts:

  1. Moses Support Digest:mt3_chart compilation error
  2. Moses Support Digest:Error compiling on Linux
  3. Moses Support Digest:compiling moses 3 chart
  4. Moses Support Digest: moses installation
  5. Moses Support Digest:SRILM installation problem
  6. Moses Support Digest: moses install on 64-bit
  7. Moses Support Digest: cannot find -loolm
  8. Moses Support Digest: experiment management system and Moses scripts
  9. Moses Support Digest:moses threads compilation problem with RandLM
  10. Moses Support Digest:CreateBerkeleyPt and On-Disk Rule Table
This entry was posted in Moses, SMT and tagged , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>