歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
您现在的位置: Linux教程網 >> UnixLinux >  >> Linux編程 >> Linux編程

Linux 制作交叉編譯器ARM920T

[Linuxidc@localhost dl]$ ll
total 157692
-rwxrwxrwx. 1 root root 18997755 May 15 09:12 binutils-2.21.1.tar.bz2
-rwxrwxrwx. 1 root root    19233 May 19 06:59 buildroot-2011.11-config_arm1176jzf-s
-rwxrwxrwx. 1 root root    19217 May 19 07:04 buildroot-2011.11-config_arm920t
-rwxrwxrwx. 1 root root    20234 May 19 07:04 buildroot-2011.11-config_arm926t
-rwxrwxrwx. 1 root root  1749001 Nov 30 18:27 buildroot-2011.11.tar.bz2
-rwxrwxrwx. 1 root root  261391 May 15 09:07 ccache-3.1.4.tar.bz2
-rwxrwxrwx. 1 root root 59756702 May 15 09:17 gcc-4.3.6.tar.bz2
-rwxrwxrwx. 1 root root  2024576 May 15 09:07 gmp-5.0.2.tar.bz2
-rwxrwxrwx. 1 root root 73577826 May 15 09:12 linux-2.6.37.tar.bz2
-rwxrwxrwx. 1 root root  583045 May 15 09:07 lzo-2.06.tar.gz
-rwxrwxrwx. 1 root root  1154306 May 15 09:11 mpfr-3.0.1.tar.bz2
-rwxrwxrwx. 1 root root  2796416 Jun  8  2011 uClibc-0.9.32.tar.bz2
-rwxrwxrwx. 1 root root  486374 May 15 09:11 zlib-1.2.5.tar.bz2
[Linuxidc@localhost dl]$
[Linuxidc@localhost dl]$ tar -jxf dl/buildroot-2011.11.tar.bz2
[Linuxidc@localhost dl]$ mv dl/ buildroot-2011.11/
[Linuxidc@localhost dl]$ cd buildroot-2011.11/
[Linuxidc@localhost dl]$ cp dl/buildroot-2011.11-config_arm920t .config

 

注:buildroot-2011.11-config_arm920t 在sourcecode裡面,路徑如下:

/home/Linuxidc/source/embededproject-code/doc/buildroot/config/buildroot-2011.11-config_arm920t

 

[Linuxidc@localhost dl]$ export TERM=vt100
[Linuxidc@localhost dl]$ make menuconfig
[Linuxidc@localhost dl]$ make

 

注:在make的時候,我們可能出現一種情況就是:系統提示我們的makeinfo沒有安裝,這是因為我們的系統缺少一個texinfo的軟件包,我們可以把這個軟件包下載安裝,然後再make,就不會出現這樣的問題。

下載地址如下:http://ftp.gnu.org/gnu/texinfo/

[Linuxidc@localhost dl]$ tar -zxf 解壓縮軟件包

[Linuxidc@localhost dl]$ ./configure 配置

[Linuxidc@localhost dl]$ make  編譯

[Linuxidc@localhost dl]$ make install 安裝

 

繼續之前的工作:make的時候,看每個人的PC的配置,配置越高,make的時間就會短一點,一般在半小時之內能搞好。

[Linuxidc@localhost dl]$    make
[Linuxidc@localhost ~]$ /opt/buildroot-2011.11/arm920t/usr/bin/arm-linux-gcc
-v
Using built-in specs.
Target: arm-unknown-linux-uclibcgnueabi
Configured with: /opt/buildroot-2011.11/output/toolchain/gcc-4.3.6/configure
--prefix=/opt/buildroot-2011.11/arm920t/usr --build=i686-pc-linux-gnu
--host=i686-pc-linux-gnu --target=arm-unknown-linux-uclibcgnueabi
--enable-languages=c,c++
--with-sysroot=/opt/buildroot-2011.11/arm920t/usr/arm-unknown-linux-uclibcgnueabi/sysroot
--with-build-time-tools=/opt/buildroot-2011.11/arm920t/usr/arm-unknown-linux-uclibcgnueabi/bin
--disable-__cxa_atexit --enable-target-optspace --disable-libgomp
--with-gnu-ld --disable-libssp --disable-multilib --disable-tls
--disable-shared --with-gmp=/opt/buildroot-2011.11/arm920t/usr
--with-mpfr=/opt/buildroot-2011.11/arm920t/usr --enable-threads
--disable-decimal-float --with-float=soft --with-abi=aapcs-linux
--with-arch=armv4t --with-tune=arm920t --with-pkgversion='Buildroot 2011.11'
--with-bugurl=http://bugs.buildroot.net/
Thread model: posix
gcc version 4.3.6 (Buildroot 2011.11)

Copyright © Linux教程網 All Rights Reserved