如何重新编译内核

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

如何重新编译内核

Jump to solution
1,185 Views
jingyangxie
Contributor V

最近我在使用yocto工程,下载了内核镜像,但是我需要修改内核的部分内容,请问如何修改并重新编译内核?

Labels (3)
0 Kudos
1 Solution
802 Views
jian_jiang
NXP Employee
NXP Employee

Hi jingyang xie,

After modifying the code, you need to locate the linux kernel directory(.../linux-imx/.../git/) in the terminal, and use the command "make".

All the best

Jian Jiang

View solution in original post

0 Kudos
6 Replies
802 Views
jingyangxie
Contributor V

Thanks for all,I have got it!

0 Kudos
802 Views
jian_jiang
NXP Employee
NXP Employee

Hi jingyang xie,

You may need the command below to set the cross compile and architecture before execute the command "make"

export CROSS_COMPILE=~/<your path>/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-

export ARCH=arm

All the best

Jian Jiang

0 Kudos
803 Views
jian_jiang
NXP Employee
NXP Employee

Hi jingyang xie,

After modifying the code, you need to locate the linux kernel directory(.../linux-imx/.../git/) in the terminal, and use the command "make".

All the best

Jian Jiang

0 Kudos
802 Views
qinghuazhu
Contributor III

Hi jingyang xie,

Chek this :Custom driver not building with the package

Best regards.

0 Kudos
802 Views
Rita_Wang
NXP TechSupport
NXP TechSupport

Hi jingyang xie,

You need to download the source code first, and then  modify the kernel code. Then build the source code. Here could you tell me which board and which version BSP are you using?
Have a great day,
Dan

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Mark Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
802 Views
jingyangxie
Contributor V

Hi DanWang,

    the BSP is 4.15.1.2.0,the custom board is based on i.mx 6 solo x sabresd

0 Kudos