mirror of
https://github.com/moses-smt/mosesdecoder.git
synced 2024-12-27 22:14:57 +03:00
72 lines
2.2 KiB
Plaintext
72 lines
2.2 KiB
Plaintext
#MOSES BUILD OPTIONS
|
|
#
|
|
#Language models
|
|
#--with-irstlm=/path/to/irstlm
|
|
#--with-srilm=/path/to/srilm
|
|
#--with-randlm=/path/to/randlm
|
|
#KenLM is always compiled.
|
|
#
|
|
#threading=single compiles single-threaded
|
|
#
|
|
#variant=debug for debugging (or just "debug")
|
|
#variant=profile for profiling
|
|
#
|
|
#link=shared for dynamic linking
|
|
#
|
|
#--install=/path/to/install sets the install directory (default dist)
|
|
#--notrace compiles without TRACE macros
|
|
#
|
|
#-j$NCPUS to compile in parallel
|
|
#
|
|
|
|
path-constant TOP : . ;
|
|
|
|
import option ;
|
|
|
|
#If boost static libraries are not installed, use dynamic linking.
|
|
if [ SHELL $(TOP)"/jam-files/test.sh -static -lboost_program_options" ] = 1 {
|
|
force-boost-link = "<link>shared" ;
|
|
}
|
|
#Convenience rule for boost libraries. Defines library boost_$(name).
|
|
#If multi-threaded, links against the -mt version.
|
|
#With shared linkage, defines macro. See tools/build/v2/contrib/boost.jam in a
|
|
#boost tarball for a table of dynamic linking macros.
|
|
rule boost_lib ( name macro ) {
|
|
lib boost_$(name) : : <threading>single <name>boost_$(name) $(force-boost-link) : : <link>shared:<define>BOOST_$(macro) ;
|
|
|
|
lib boost_$(name) : : <threading>multi <name>boost_$(name)-mt $(force-boost-link) : : <link>shared:<define>BOOST_$(macro) ;
|
|
}
|
|
boost_lib thread THREAD_DYN_DLL ;
|
|
boost_lib program_options PROGRAM_OPTIONS_DYN_LINK ;
|
|
boost_lib unit_test_framework TEST_DYN_LINK ;
|
|
|
|
trace = [ option.get "notrace" : : <define>TRACE_ENABLE=1 ] ;
|
|
|
|
project : default-build
|
|
<threading>multi
|
|
<warnings>on
|
|
<variant>release
|
|
<link>static
|
|
;
|
|
|
|
project : requirements
|
|
<threading>multi:<define>WITH_THREADS
|
|
<threading>multi:<library>boost_thread
|
|
<define>_FILE_OFFSET_BITS=64 <define>_LARGE_FILES <define>USE_HYPO_POOL
|
|
$(trace)
|
|
;
|
|
|
|
#Add directories here if you want their incidental targets too (i.e. tests).
|
|
build-project lm ;
|
|
build-project util ;
|
|
|
|
install-location = [ option.get "install" : $(TOP)/dist ] ;
|
|
install dist :
|
|
lm//query
|
|
lm//build_binary
|
|
moses-chart-cmd/src//moses_chart
|
|
moses-cmd/src//programs
|
|
CreateOnDisk/src//CreateOnDisk
|
|
mert//programs
|
|
: <location>$(install-location) <install-type>EXE <install-dependencies>on <link>shared:<dll-path>$(install-location) <link>shared:<install-type>LIB ;
|