diff options
-rw-r--r-- | phrase-extract/Jamfile | 56 | ||||
-rw-r--r-- | phrase-extract/consolidate-direct-main.cpp (renamed from phrase-extract/consolidate-direct.cpp) | 0 | ||||
-rw-r--r-- | phrase-extract/consolidate-main.cpp (renamed from phrase-extract/consolidate.cpp) | 0 | ||||
-rw-r--r-- | phrase-extract/consolidate-reverse-main.cpp (renamed from phrase-extract/consolidate-reverse.cpp) | 0 | ||||
-rw-r--r-- | phrase-extract/extract-lex-main.cpp (renamed from phrase-extract/extract-lex.cpp) | 0 | ||||
-rw-r--r-- | phrase-extract/extract-main.cpp (renamed from phrase-extract/extract.cpp) | 0 | ||||
-rw-r--r-- | phrase-extract/extract-rules-main.cpp (renamed from phrase-extract/extract-rules.cpp) | 0 | ||||
-rw-r--r-- | phrase-extract/relax-parse-main.cpp (renamed from phrase-extract/relax-parse.cpp) | 0 | ||||
-rw-r--r-- | phrase-extract/score-main.cpp (renamed from phrase-extract/score.cpp) | 0 | ||||
-rw-r--r-- | phrase-extract/statistics-main.cpp (renamed from phrase-extract/statistics.cpp) | 0 |
10 files changed, 17 insertions, 39 deletions
diff --git a/phrase-extract/Jamfile b/phrase-extract/Jamfile index 79382ec78..d5bdf5796 100644 --- a/phrase-extract/Jamfile +++ b/phrase-extract/Jamfile @@ -1,41 +1,19 @@ -obj InputFileStream.o : InputFileStream.cpp : <include>. ; -alias InputFileStream : InputFileStream.o ..//z ; - -obj OutputFileStream.o : OutputFileStream.cpp : <include>. ; -alias OutputFileStream : OutputFileStream.o ..//z ..//boost_iostreams ; - -obj tables-core.o : tables-core.cpp : <include>. ; -obj domain.o : domain.cpp : <include>. <include>.. ; -obj AlignmentPhrase.o : AlignmentPhrase.cpp : <include>. ; -obj PhraseAlignment.o : PhraseAlignment.cpp : <include>. ; -obj ScoreFeature.o : ScoreFeature.cpp : <include>. <include>.. ; -obj SentenceAlignment.o : SentenceAlignment.cpp : <include>. ; -obj SyntaxTree.o : SyntaxTree.cpp : <include>. ; -obj XmlTree.o : XmlTree.cpp : <include>. ; - -alias filestreams : InputFileStream OutputFileStream : : : <include>. ; -alias trees : SyntaxTree.cpp tables-core.o XmlTree.o : : : <include>. ; - -exe extract : tables-core.o SentenceAlignment.o extract.cpp filestreams ../moses/src//ThreadPool ..//boost_iostreams ; - -exe extract-rules : tables-core.o SentenceAlignment.o SyntaxTree.o XmlTree.o SentenceAlignmentWithSyntax.cpp HoleCollection.cpp extract-rules.cpp ExtractedRule.cpp filestreams ..//boost_iostreams ; - -exe extract-lex : extract-lex.cpp filestreams ; - -exe score : tables-core.o domain.o AlignmentPhrase.o score.cpp ScoreFeature.o PhraseAlignment.o filestreams ../util//kenutil ..//boost_iostreams ; - -exe consolidate : consolidate.cpp tables-core.o filestreams ..//boost_iostreams ; - -exe consolidate-direct : consolidate-direct.cpp filestreams ..//boost_iostreams ; - -exe consolidate-reverse : consolidate-reverse.cpp tables-core.o filestreams ; - -exe relax-parse : tables-core.o SyntaxTree.o XmlTree.o relax-parse.cpp filestreams ; - -exe statistics : tables-core.o AlignmentPhrase.o statistics.cpp filestreams ; - -alias programs : extract extract-rules extract-lex score consolidate consolidate-direct consolidate-reverse relax-parse statistics ; +local most-deps = [ glob *.cpp : PhraseAlignment.cpp *Test.cpp *-main.cpp ] ; +#Build .o files with include path setting, reused. +for local d in $(most-deps) { + obj $(d:B).o : $(d) : <include>. <include>.. ; +} +#and stuff them into an alias. +alias deps : $(most-deps:B).o ..//z ..//boost_iostreams ../moses/src//ThreadPool ../util//kenutil : <include>. <include>.. ; + +#PhraseAlignment.cpp requires that main define some global variables. +#Build the mains that do not need these global variables. +for local m in [ glob *-main.cpp : score-main.cpp ] { + exe [ MATCH "(.*)-main.cpp" : $(m) ] : $(m) deps ; +} + +#The side dishes that use PhraseAlignment.cpp +exe score : PhraseAlignment.cpp score-main.cpp deps ; import testing ; -run ScoreFeatureTest.cpp tables-core.o domain.o ScoreFeature.o PhraseAlignment.o filestreams ../util//kenutil ..//boost_unit_test_framework ..//boost_iostreams : : test.domain ; - +run ScoreFeatureTest.cpp PhraseAlignment.cpp deps ..//boost_unit_test_framework ..//boost_iostreams : : test.domain ; diff --git a/phrase-extract/consolidate-direct.cpp b/phrase-extract/consolidate-direct-main.cpp index e7e68e977..e7e68e977 100644 --- a/phrase-extract/consolidate-direct.cpp +++ b/phrase-extract/consolidate-direct-main.cpp diff --git a/phrase-extract/consolidate.cpp b/phrase-extract/consolidate-main.cpp index 43b3f32a1..43b3f32a1 100644 --- a/phrase-extract/consolidate.cpp +++ b/phrase-extract/consolidate-main.cpp diff --git a/phrase-extract/consolidate-reverse.cpp b/phrase-extract/consolidate-reverse-main.cpp index c86d870c8..c86d870c8 100644 --- a/phrase-extract/consolidate-reverse.cpp +++ b/phrase-extract/consolidate-reverse-main.cpp diff --git a/phrase-extract/extract-lex.cpp b/phrase-extract/extract-lex-main.cpp index a59450da8..a59450da8 100644 --- a/phrase-extract/extract-lex.cpp +++ b/phrase-extract/extract-lex-main.cpp diff --git a/phrase-extract/extract.cpp b/phrase-extract/extract-main.cpp index 8749f5059..8749f5059 100644 --- a/phrase-extract/extract.cpp +++ b/phrase-extract/extract-main.cpp diff --git a/phrase-extract/extract-rules.cpp b/phrase-extract/extract-rules-main.cpp index 974e575b9..974e575b9 100644 --- a/phrase-extract/extract-rules.cpp +++ b/phrase-extract/extract-rules-main.cpp diff --git a/phrase-extract/relax-parse.cpp b/phrase-extract/relax-parse-main.cpp index ac06174e8..ac06174e8 100644 --- a/phrase-extract/relax-parse.cpp +++ b/phrase-extract/relax-parse-main.cpp diff --git a/phrase-extract/score.cpp b/phrase-extract/score-main.cpp index 7513b9cc8..7513b9cc8 100644 --- a/phrase-extract/score.cpp +++ b/phrase-extract/score-main.cpp diff --git a/phrase-extract/statistics.cpp b/phrase-extract/statistics-main.cpp index 67373ec93..67373ec93 100644 --- a/phrase-extract/statistics.cpp +++ b/phrase-extract/statistics-main.cpp |