how to compile the linux kernel

来源:互联网 发布:知乎 情人节送玫瑰由来 编辑:程序博客网 时间:2024/05/16 15:41



当你下载linux源码以后,有补丁的打补丁,how to use the patch。

cd 源码ing patch -P1 < ../linux_.patch the patch fila is linux_.patch
when you are using the p1, that means you will miss the current folder

the next step will be important for us.
the sequence of compiling the kernel of linux.

the first method
 the linux must provide default config file for compiling. you can find it for example
 make s3c2410_menuconfig.  
 
 the process will generate .config file, which be written into .config file.
 
 configuration written to .config
 
 then make menuconfig

the second method.
 if the vendor must provide itself config file. the next step change the name of vender config to
 .config file.
 then make menuconfig

When you has configured the config file. the next step you perform the make or make uImage, which will
generate the uImage file, that is kernel file of linux. you could use the u-boot file to download the file.

now, the new Iamge has been got.

how to download the uImage using the dnw of linux and com port of windows, which means combine both
the first step:
connect the com port and press the key of downloading uImage

the second step:
connect the dnw line


2. 用linux下的dnw
2.1 把linux下的dnw应用程序放到/bin目录
sudo chmod +x /bin/dnw
sudo chmod +x /bin/dnw

2.2 如果使用VMWAER,让VMWARE位于前台,然后再用USB线连接PC和开发板USB DEVICE接口
用lsusb命令确认VMWARE LINUX已经识别出UBOOT的USB设备
Bus 002 Device 002: ID 5345:1234 Owon PDS6062T Oscilloscope


2.3 在UBOOT界面输入k
    然后在LINUX下执行 dnw uImage
   
2.4 在UBOOT界面输入y
    然后在LINUX下执行 dnw fs_qtopia.yaffs2
 
in practice copy the uImage file to /bin/
 
 











  

0 0
原创粉丝点击