1. 程式人生 > >undefined reference to `__gnu_mcount_nc'的解決 在編譯核心時出現瞭如下錯誤:

undefined reference to `__gnu_mcount_nc'的解決 在編譯核心時出現瞭如下錯誤:

在編譯核心時出現瞭如下錯誤:

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

calibrate.c:(.text+0x14): undefined reference to `__gnu_mcount_nc'

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

calibrate.c:(.text+0x1d4): undefined reference to `__gnu_mcount_nc'

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

calibrate.c:(.text+0x358): undefined reference to `__gnu_mcount_nc'

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

calibrate.c:(.ref.text+0x10): undefined reference to `__gnu_mcount_nc'

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

calibrate.c:(.cpuinit.text+0x10): undefined reference to `__gnu_mcount_nc'

arch/arm/kernel/built-in.o:io.c:(.text+0x10): more undefined references to `__gnu_mcount_nc' follow

make: *** [.tmp_vmlinux1] Error 1

上網參閱以下兩個網頁,

http://forum.ubuntu.org.cn/viewtopic.php?t=333083http://blog.sina.com.cn/s/blog_7d3976fc01012itz.html得出解決方法:

在網上下載一個補丁檔案:地址如下:

方法一,下載到Linux核心目錄下,然後gunzip -dc __gnu_mcount_nc_patch.patch.gz |patch -p1

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

然後,在終端進入linux根目錄,執行以下語句進行打包:

zcat __gnu_mcount_nc_patch.patch | patch p1 或者 

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

再重新編譯就好了

相關推薦

undefined reference to `__gnu_mcount_nc'的解決編譯核心出現如下錯誤

在編譯核心時出現瞭如下錯誤: init/built-in.o: In function `do_one_initcall': calibrate.c:(.text+0x14): undefined reference to `__gnu_mcount_nc' init/built-in.o: In

linux下生產者與消費者問題程式碼,以及編譯c程式碼errorundefined reference to sem_wait 解決方法之一

//本文的詳細講解內容請大家下載word文件:http://download.csdn.net/detail/chenqiai0/4611801 #include <stdio.h> #include <pthread.h>//執行緒 #includ

Linux 編譯報錯 -- undefined reference to 問題解決方法 (具體'pthread_create'和opencv看文章最後兩條)

最近在Linux下程式設計發現一個詭異的現象,就是在連結一個靜態庫的時候總是報錯,類似下面這樣的錯誤: (.text+0x13): undefined reference to `func'     關於undefined reference這樣的問題,大家其實經常會遇到

Linux 編譯報錯 -- undefined reference to 問題解決方法 (具體'pthread_create'和opencv看文章最後兩條)

最近在Linux下程式設計發現一個詭異的現象,就是在連結一個靜態庫的時候總是報錯,類似下面這樣的錯誤: (.text+0x13): undefined reference to `func'     關於undefined reference這樣的問題,大家其實經常會遇

解決編譯核心“ Error: selected processor does not support ARM mode 'smc 0'”相關問題

最近在用arm-2014.05編譯器編譯Linux核心時,出現如下問題:  Error: selected processor does not support ARM mode 'smc 0'   這是我使用的交叉編譯器:   &nbs

"undefined reference to" 問題解決方法

最近在Linux下程式設計發現一個詭異的現象,就是在連結一個靜態庫的時候總是報錯,類似下面這樣的錯誤: (.text+0x13): undefined reference to `func'      關於undefined reference這樣的問題,大家其實經常會遇

undefined reference to 問題解決方法總結

經常遇到這樣的錯誤,最常見的是因為缺少相關目標檔案,但是也有其他情況,網上看到這篇文章,受益匪淺。 在Linux下程式設計在連結一個靜態庫的時候總是報錯,類似下面這樣的錯誤: (.text+0x13): undefined reference to `func'  

ubuntu 12.04 codeblocks undefined reference to ‘pthread_create'解決方法

settings---》compiler and bug settings --》link settings 在左邊新增libpthread.a  ,右邊新增 -lpthread即可。 ubuntu libpthread.a 的路徑為 /usr/lib/x86_64-lin

c/c++中出現undefined reference to”的解決

undefined reference to”的意思是,該函式未定義。 如果使用的是gcc,有以下檢查方案: 如果提示未定義的函式是某個庫的函式。檢查庫時候已經安裝,並在編譯命令中採用-l和-L引數匯入庫。 如果提示未定義的函式是程式中的函式。檢查是否在標頭檔案中宣告

編譯核心出現*** target pattern contains no `%'. Stop.

在編譯核心時,遇到linux-2.6.21.x/usr/Makefile:42: *** target pattern contains no `%'. Stop. 解決這個問題的方法是:刪除linu

編譯核心出現uudecode錯誤

在重新make一下就可以了。 編碼壓縮打包--uudecode 名稱:uudecode 使用許可權:所有使用者 使用方式:uuencode [-hv] [file1 ...] 說明: uudecode 將 uuencode 編碼後的檔案還原, uudecode 只會將 begin 與 end 標記之

解決Wordpress安裝出現“資料庫連線錯誤”的問題

在安裝或者更新(手動離線)wordpress的時候,有可能出現“資料庫連線錯誤”的問題: 一開始看了很多人家修改檔案的教程,發現都不太靠譜,而且麻煩; 這裡推薦一種簡單的方法: 1、登陸本地phpadmin; 2、找到mysql(wordpress建立時使用的資料庫),點選

Android中使用web3j出現記憶體溢位錯誤OutOfMemoryError

在使用Android和web3j開發時出現了記憶體溢位錯誤的異常情況即OutOfMemoryError。 我正在試著在Android應用程式中整合web3j。但是,在載入以太坊錢包檔案時,庫提供了一個記憶體不足的異常: Credentials crede

Jupyter執行出現下面的錯誤Unexpected error while saving file: arma/Untitled.ipynb [Errno 13] Permission denied:

執行環境:Ubuntu16.04+Python2.7執行如下程式碼修改Jupyter的一部分檔案的許可權(執行完之後重新啟動即可): sudo chmod 777 ~/.local/share/jupyter/ cd ~/.local/share/jupyter/ ls s

在Centos上安裝MySQL出現這樣的錯誤Starting MySQL.. ERROR! The server quit without updating PID file (/usr/loca

MySQL的版本是:mysql-5.5.48-linux2.6-x86_64.tar.gzcentos6.6上安裝MySQL時出現的錯誤:[[email protected] mysql]# ./support-files/mysql.server startSta

[ c++] cmake 編譯 undefined reference to `std::cout' 錯誤解決方案

bin cut () cmake fin epo linking com urn cmake .. 和 make 之後,出現如下錯誤 Linking CXX executable ../../../bin/ModuleTest CMakeFiles/Modu

PHP 編譯安裝出現 undefined reference to `libiconv' 錯誤解決方法

原文:http://flyfishes.blog.51cto.com/3527694/819693 手動編譯PHP安裝時遇到如下錯誤 /usr/local/src/php-5.3.10/ext/xmlrpc/libxmlrpc/encodings.c:73: und

解決使用NDK進行編譯出現undefined reference to function的問題

之前在編譯jni時出現了undefined reference to function這個問題,查閱相關資料說是可能連結的庫問題,然後通過各種gcc調整順序解決了這個問題。這個工程是導師的工程,工程在Linux環境下執行無誤,我從Linux環境往Android

linux下開發,解決cocos2d-x中編譯出現的一個小問題, undefined reference to symbol &#39;pthread_create@@GLIBC_2.2.5&#39;

water span x86 code bject data- ace 技術分享 inux 解決cocos2d-x中編譯出現的一個小問題 對於cocos2d-x 2.×中編譯中,若頭文件裏引入了#include "cocos-ext.h",在進行C++編譯的時候會遇到例

minigui:解決gvfb編譯報錯undefined reference to symbol 'XkbGetIndicatorState'

minigui在linux PC平臺建立開發環境時,需要Virtual Frame Buffer 支援(gvfb,qvfb),minigui官網提供了這兩個程式的原始碼,需要自己下載編譯並安裝到自己的PC上。 我用的是gvfb,minigui下載地址:http://www.minig