I built a new machine with Ubuntu 12.04 Server. I learned the default
setup installs bjam. (all my previous installs were on systems without
bjam installs). 

~$ bjam --version
Boost.Build V2 (Milestone
12)
Boost.Jam 03.1.19 

I'm using the last 20 July commit of Moses. My
bjam command line is: 

src/mosesdecoder$ sudo ./bjam -j4 -a
--debug-configuration --with-xmlrpc-c
--prefix="/usr/local/lib/mosesdecoder"
--install-scripts="/usr/local/lib/mosesdecoder/scripts"
--with-irstlm=/usr/local --with-randlm=/usr/local
--with-srilm=/usr/local 

The system hung with no stderr or stdout
output. Top showed a single instance of cc1plus (not four per -j4) and
it hung for about 30 minutes before I hit Ctrl-C. I traced the problem
to the moses bjam shell script. If I remove the two lines "${bjam}"
--help & --version, the compile completes fine. 

if
 bjam="$(which bjam
2>/dev/null)" && #exists
 [ ${#bjam} != 0 ] && #paranoia about which
printing nothing then returning true
 ! grep UFIHGUFIHBDJKNCFZXAEVA
"${bjam}" /dev/null #bjam in path isn't this script
then
 #Delegate to
system bjam
 exec "${bjam}" "$@"
fi 

In my case, "${bjam}" resolves to
/usr/bin/bjam. More troubleshooting found: 

1) the "/usr/bin/bjam
--help" command ignores the --help argument and tries to process the
Jamfiles in the default folder. When issuing the "/usr/bin/bjam --help"
command from a default folder without any Jamfiles, the command
terminates and reports "error: error: no Jamfile in current directory
found, and no target references specified." From the Moses folder and
with the Bash script redirecting both stderr and stdout to /dev/null,
started processing without the command line scripts and system hung.


2) The --version output is a different format than the "grep" search
expects and the bjam Bash script skips the system bjam installation and
moves on to the bjam distributedwith Moses. 

For my purposes, I will
remove the two lines. For the main trunk, the --help command should be
removed at a minimum. The grep line would have to be re-designed to
handle the new report format if you really need to identify the Boost
version. 

Tom
_______________________________________________
Moses-support mailing list
[email protected]
http://mailman.mit.edu/mailman/listinfo/moses-support

Reply via email to