2015-09-17 38 views
-1

我剛剛在我的Fedora 22機器上安裝了英特爾引腳,並試圖使用make/source/tools中運行makefile。當我運行它,不過,我得到以下兩個錯誤重複多次:Makefile在Fedora 22上誤解了英特爾引腳的gcc版本

error: #error This kit requires gcc 3.4 or later 
error: #error The C++ ABI of your compiler does not match the ABI of the pin kit. 

然而,我的gcc版本是

gcc version 5.1.1 20150618 (Red Hat 5.1.1-4) (GCC) 

,所以我有點困惑是怎麼回事。我將如何解決這個問題?

+2

我認爲你需要發佈任何配置測試是在該失敗的生成文件,任何人都可以弄清楚 –

回答

0

錯誤:

error: #error The C++ ABI of your compiler does not match the ABI of the pin kit. 

可能是完全正確的,但我猜測,其他的錯誤信息,使一個愚蠢的假設 - 任何ABI不匹配是因爲你的系統有一個ABI 年長比3.4。但是,這是雙向的,現在,你有一個ABI不匹配,因爲當然GCC 5.1是更新

一些背景知識在Fedora的雜誌:GCC 5 in Fedora (What’s an ABI, and what happens when we change it?)

1

註釋掉source/include/pin/compiler_version_check2.H 違規行似乎做的伎倆對我來說:

#if !defined(__GXX_ABI_VERSION) || CC_USED_ABI_VERSION != __GXX_ABI_VERSION 
#error The C++ ABI of your compiler does not match the ABI of the pin kit. 
#endif 

#if CC_USED_ABI_VERSION != __GXX_ABI_VERSION 
#error This kit requires gcc 3.4 or later 
#endif 
1

我碰到一樣的問題。 GCC 5.1引入了一個不再與gcc-3.4 +兼容的新ABI。我建議你下載更新版本的pin,它可以很好地編譯新版本的gcc。

另一種解決方案將宏_GLIBCXX_USE_CXX11_ABI設置爲0,以便您的編譯器將使用較舊的ABI。在PIN目錄下有一些Makefile配置,您可以在其中爲PIN工具設置CXX標誌。

更多關於雙ABI爲GCC:https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_dual_abi.html

較新的PIN的版本可以在這裏找到https://software.intel.com/en-us/articles/pintool-downloads。最新版本,是在2016年3月24日。