ºìÁªLinuxÃÅ»§
Linux°ïÖú

ÔÚ64λ»·¾³Ï±àÒë32λµÄÓ¦ÓóÌÐò

·¢²¼Ê±¼ä:2008-09-23 16:01:21À´Ô´:ºìÁª×÷Õß:Mwany
ÓÃPITAËã·¨×ö°Ð±êÔ¤²âµÄʱºò£¬ÒªÓõ½ViennaRNA°ü×ö½á¹¹µÄÕÛµþ£¬Õâ¸ö°üÊDZ»Ð޸ĹýµÄ£¬Ô­À´µÄ°üÔÚÎÒ»ú×ÓÉÏÊÇ¿ÉÒÔ×°µÄ¡£µ«ÊÇÕâ¸öÐ޸ĹýµÄ°ü±àÒ벻ͨ¹ý¡£ºÜÆæ¹ÖµÄ´íÎ󣬲»ÖªµÀÔõô¸Ä¡£

ºÃÔÚËüÓÐÁ½¸ö°æ±¾£¬64λºÍ32λµÄ¡£ÎÒŪµ½´óÐÍ»úÉÏÈ¥±àÒë32λµÄ£¬Ò²Êdzö´í£¬²»¹ýÊÇÃüÃû¿Õ¼äµÄÎÊÌ⣬ÎÒ¸ÄÁ½¸öÍ·Îļþ¾Í¿ÉÒÔͨ¹ýÁË¡£×î½üÓÖÒªËã¡£ÄǸö´óÐÍ»ú×î½ü±»°á×ßÁË¡£Ö»Äܱ¾»úÉÏ×ö¡£

ËùÒÔÕÛÌÚÁËһϣ¬ÔÚ64λµÄϵͳÀï±àÒë32λµÄ³ÌÐò¡£

CPU: AMD Athlon(tm) 64 X2 Dual Core Processor 3800+
OS: Ubuntu 7.10/Linux 2.6.20-15-server #2 SMP Sun Apr 15 06:22:36 UTC 2007 x86_64 GNU/Linux
GCC: gcc (GCC) 4.1.2 (Ubuntu 4.1.2-0ubuntu4)

Ê×ÏÈÐèÒª°²×°32λµÄ¼æÈÝ¿â

apt-get install ia32-libs libc6-dev-i386 linux32

1.ÓÃlinux32ÃüÁîÔÚconfigureʱ¸ÄÒ»ÏÂCHOST£¬ÉèÖÃһϱàÒë»·¾³

$ linux32 ./configure

#ϵͳÀàÐͽ«±äΪ£ºi686-pc-linux-gnu
#¶ø²»ÊÇx86_64-unknown-linux-gnu

2.É趨GCCµÄ²ÎÊý

export CFLAGS="-m32 -04 -march=i386 -mtune=i386"

#×î¹Ø¼üÊÇ-m32

-m32, -m64
Generate code for a 32-bit or 64-bit environment. The 32-bit environment sets int, long and pointer to 32 bits and generates code that runs on any i386 system. The 64-bit environment sets int to 32 bits and long and pointer to 64 bits and generates code for AMD's x86-64 architecture.

3.±àÒë

make

4.°²×°

sudo make install

×îÖÕÊdzɹ¦µØ°²×°ÁË¡£ÆÆPC»úÓÖµÃÅܺöàÌìÁË¡£
ÎÄÕÂÆÀÂÛ

¹²ÓÐ 0 ÌõÆÀÂÛ