如何在Windows下编译Linux内核



步骤:

1、安装Cygwin官方版,然后选择安装一下包:

    安装gcc-core、make、perl、gettext、libelf-devel、libgmp-devel、gettext, libelf-devel, libgmp-devel, libmpc-devel, libmpfr-devel, zlib-devel、libncurses-devel

2、从cygwinports安装交叉编译工具
    linux-i686-binutils(linux-x86_64-binutils)和linux-i686-gcc-core(linux-x86_64-gcc-core)

3. 编译内核 

    配置: make ARCH=x86_64 CROSS_COMPILE=x86_64-pc-linux-gnu- O=_build nconfig

     编译:

4、打包安装:

    API头文件: make headers_install

    内核:make install

    模块: make modules_install


你可能感兴趣的:(如何在Windows下编译Linux内核)