FYI
I added the following to Jamroot and then called bjam with --with-pic
if [ option.get "with-pic" : : "yes" ] {
requirements += <cxxflags>-fPIC ;
}
Hints to compile the dependencies with PIC as well:
cmph: ./configure --with-pic
boost: ./b2 cxxflags=-fPIC
Gesendet: Dienstag, 15. Dezember 2015 um 18:26 Uhr
Von: "Hieu Hoang" <[email protected]>
An: "Miriam Käshammer" <[email protected]>, [email protected]
Betreff: Re: [Moses-support] Compiling Moses with -fPIC
Von: "Hieu Hoang" <[email protected]>
An: "Miriam Käshammer" <[email protected]>, [email protected]
Betreff: Re: [Moses-support] Compiling Moses with -fPIC
you may have to compile boost, cmph and irstlm with the -fPIC too.
On 14/12/15 16:06, "Miriam Käshammer" wrote:
Dear Moses community,My goal is to link Moses (the decoder) as a static library into some other shared library. As far as I understand the compiler/linker output of this other library, I need to compile the Moses library with parameter -fPIC (position independent code). Could you help me in achieving this?I already tried to add "cxxflags=-fPIC" to the bjam command like this:./bjam -j8 -d2 -a --with-boost="${PREFIX}" --with-xmlrpc-c="${PREFIX}" --with-cmph="${PREFIX}" --with-irstlm="${PREFIX}" --install-scripts="${PREFIX}"/scripts link=static cxxflags=-fPICHowever, the build process just seems to get stuck before it actually starts, see attached log.Any help/comment is appreciated.Thanks!Miriam_______________________________________________ Moses-support mailing list [email protected] http://mailman.mit.edu/mailman/listinfo/moses-support
-- Hieu Hoang http://www.hoang.co.uk/hieu
_______________________________________________ Moses-support mailing list [email protected] http://mailman.mit.edu/mailman/listinfo/moses-support
