Linux核心編譯錯誤: make: *** [.tmp_vmlinux1] Error 1

來源:互聯網
上載者:User

若編譯核心出現如下情況:

WARNING: modpost: Found 1 section mismatch(es).

To see full details build your kernel with:

'make CONFIG_DEBUG_SECTION_MISMATCH=y'

GEN     .version

CHK     include/linux/compile.h

UPD     include/linux/compile.h

CC      init/version.o

LD      init/built-in.o

LD      .tmp_vmlinux1

init/built-in.o: In function `do_one_initcall':

/root/案頭/linux-2.6.30.4/init/main.c:706: undefined reference to `__gnu_mcount_nc'

init/built-in.o: In function `init_post':

/root/案頭/linux-2.6.30.4/init/main.c:804: undefined reference to `__gnu_mcount_nc'

init/built-in.o: In function `name_to_dev_t':

/root/案頭/linux-2.6.30.4/init/do_mounts.c:78: undefined reference to `__gnu_mcount_nc'

init/built-in.o: In function `rest_init':

/root/案頭/linux-2.6.30.4/init/main.c:453: undefined reference to `__gnu_mcount_nc'

init/built-in.o: In function `calibrate_delay':

/root/案頭/linux-2.6.30.4/init/calibrate.c:123: undefined reference to `__gnu_mcount_nc'

arch/arm/kernel/built-in.o:/root/案頭/linux-2.6.30.4/arch/arm/kernel/elf.c:8: more undefined references to `__gnu_mcount_nc' follow

make: *** [.tmp_vmlinux1] 錯誤 1

root@czu:~/案頭/linux-2.6.30.4#

解決方案:

需要補丁__gnu_mcount_nc_patch.patch.gz

下載之後放在linux根目錄下,並解壓得到:__gnu_mcount_nc_patch.patch 檔案。

然後,在終端進入linux根目錄,執行以下語句進行打包:zcat __gnu_mcount_nc_patch.patch | patch p1

(注意:“__”為兩個底線連在一起,“p1”後面的是阿拉伯數字1,還要注意空格)

更多精彩內容:http://www.bianceng.cnhttp://www.bianceng.cn/OS/Linux/

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.