红联首页 凝聚Linux人的力量
菜鸟过关 | 精华文档 | 同城人(交友) | 我与Linux的故事 | Linux新闻 | Linux视频 | Linux人才 | 软件下载 | 大学校园 | English
发新话题
打印

With buildroot build its own Linux Toolchain

With buildroot build its own Linux Toolchain

For quite a long time, building a cross toolchain from the scratch seems like a nightmare to most embedded software engineers. This used to require hanlding a lot of interdependent source packages as well as their patches carefully.

With the assist of buildroot, which is made available along with well-known uclibc, things used to be a mess can be well handled by just a few simple commands.

Below is my attempt to build an arm toolchain:

1) Download the latest buildroot snapshot from uclibc.org. Like all other packages offered by uclibc, it has a fantastic DAILY snapshot.

2) Unpack the buildroot snapshot package like this:
# tar -jxvf buildroot-200xxxxxx.tar.bz2

3) Configure the buildroot. This looks quite alike with configuring linux kernel features. For me, I just need an arm toolchain integrated with the lightweight uclibc instead of the heavy glibc. So, I just made some simple changes within the toolchain menu. Probably, buildroot can be used to build other embedded components like linux kernel, busybox, even tinyx.

# make menuconfig  

4) Execute the build command. This supposes to take quite a long while to do a batch of traffic jobs like downloading different source packages, applying patches, compling the source code and etc. Please find youself a favorite computer game to kill the time..

# make

5) Finally, if everything is all right, you will have your toolchain in the build_arm sub-folder. To make the toolchain work, probably you have to add the path that contains the executable files like arm-linux-gcc, arm-linux-g++ into your $PATH environment.

Enjoy it.

TOP

发新话题