[SRILM User List] Compiling srilm
Andreas Stolcke
stolcke at speech.sri.com
Wed Sep 23 09:56:49 PDT 2009
Sylvain Raybaud wrote:
> On Wednesday 23 September 2009 09:52:32 Paul Johnston wrote:
>
>> Hi on my first attempt to build srilm version 1.5.9
>>
>> I get lots of messages like
>>
>>
>>
>> gcc -mtune=pentium3 -Wreturn-type -Wimplicit -Wimplicit-int
>> -D_FILE_OFFSET_BITS=64 -I. -I../../include -c -g -O3 -o
>> ../obj/i686/option.o option.c
>>
>> option.c:1: error: CPU you selected does not support x86-64 instruction
>> set
>>
>>
>>
>> Therefore make World fails, looking into it, the return value of
>> machine-type is
>>
>>
>>> /home/CO/mcasspj/srilm_dir/sbin/machine-type
>>>
>> i686
>>
>>
>>
>> And the actual machine is
>>
>>
>>
>> uname -a
>>
>> Linux servalan.humanities.manchester.ac.uk 2.6.18-128.el5 #1 SMP Wed Dec
>> 17 11:41:38 EST 2008 x86_64 x86_64 x86_64 GNU/Linux
>>
>>
>>
>> More specifically
>>
>>
>>
>> cat /etc/redhat-release
>>
>> Red Hat Enterprise Linux Server release 5.3 (Tikanga)
>>
>>
>>
>> Anyone seen this and have any ideas as to solving the problem?
>>
>> As I intend to build a machine dedicated to this system can anyone
>> recommend a system they use i.e. Solaris, any of the BSDs or a variety
>> of Linux just not Windows or a Mac :-)
>>
>>
>>
>> Many thanks!
>>
>>
>
> Hello
>
> I modified sbin/machine-type and added a common/Makefile.machine.x86_64-gcc4
> so that it compiles for 64 bits. It works on my machine, no guarantee it will
> work anywhere else... You will find them attached. Hope this helps.
>
The idea is that the default even for 64bit i686 machines is 32bit
compilation. That's why machine-type returns i686 by default.
I think the problem you saw can be avoided by adding -m32 in
common/Makefile.machine.i686.
To build 64bit binaries use
make MACHINE_TYPE=i686-m64
Andreas
> regards,
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> SRILM-User site list
> SRILM-User at speech.sri.com
> http://www.speech.sri.com/mailman/listinfo/srilm-user
More information about the SRILM-User
mailing list