您好,登錄后才能下訂單哦!
本篇內(nèi)容介紹了“CentOS rpm安裝編譯gcc時(shí)的過程”的有關(guān)知識,在實(shí)際案例的操作過程中,不少人都會(huì)遇到這樣的困境,接下來就讓小編帶領(lǐng)大家學(xué)習(xí)一下如何處理這些情況吧!希望大家仔細(xì)閱讀,能夠?qū)W有所成!
CentOS是在linux開發(fā)基礎(chǔ)上的常用系統(tǒng),然后我深入探討了CentOS rpm安裝,在這里對CentOS用戶概括講解下CentOS rpm安裝應(yīng)用,linux下使用CentOS rpm安裝libxml2,gcc,gcc-c++等基本包 我使用了的linux版本是CentOS5.0,進(jìn)行了最小安裝,所以很多包都沒有安裝上。比如gcc (C組件和解釋器),libxml2,gcc-c++等。我現(xiàn)使用安裝光盤安裝這些所需的包。之前我已經(jīng)安裝過gcc了,沒有記下這個(gè)安裝時(shí)的步驟,不過跟其它的安裝是一樣的?,F(xiàn)記下我的安裝時(shí)的日記,以備后忘。希望對網(wǎng)友們也會(huì)有點(diǎn)幫助
CentOS rpm安裝libxml2-devel
CentOSrpm安裝libxml2-devel時(shí)提示其依賴的包還有pkgconfig-0.21-1,zlib-devel-1.2.3-3,所以按其提示缺少什么包就在CentOS rpm安裝光盤上找什么包。一般基本的包在光盤上都會(huì)有放入第2張光盤[root@localhost mnt]# mount /dev/cdrom /mnt/cdrommount: block device /dev/cdrom is write-protected, mounting read-only[root@localhost mnt]# find -iname pkgconfig*./cdrom/CentOS/pkgconfig-0.21-1.fc6.i386.rpm[root@localhost mnt]# rpm -ivh ./cdrom/CentOS/pkgconfig-0.21-1.fc6.i386.rpmwarning: ./cdrom/CentOS/pkgconfig-0.21-1.fc6.i386.rpm: Header V3 DSA signature: NOKEY, key ID e8562897Preparing... [100%]1:pkgconfig [100%]
[root@localhost mnt]# umount /mnt/cdrom
放入第3張光盤[root@localhost mnt]# find -iname zlib*./cdrom/CentOS/zlib-devel-1.2.3-3.i386.rpm[root@localhost mnt]# rpm -ivh ./cdrom/CentOS/zlib-devel-1.2.3-3.i386.rpm[root@localhost mnt]# find -iname libxml*./cdrom/CentOS/libxml2-devel-2.6.26-2.1.2.i386.rpm[root@localhost mnt]# rpm -ivh ./cdrom/CentOS/libxml2-devel-2.6.26-2.1.2.i386.rpm
CentOS rpm安裝gcc-c++
出現(xiàn)錯(cuò)誤configure: error: C++ preprocessor "/lib/cpp" fails sanity checkSee `config.log' for more details.gcc沒有安裝全,缺少c++預(yù)處理程序等還有
./cdrom/CentOS/gcc-c++-4.1.1-52.el5.i386.rpm./cdrom/CentOS/gcc-gfortran-4.1.1-52.el5.i386.rpm fortran預(yù)處理程序./cdrom/CentOS/gcc-java-4.1.1-52.el5.i386.rpm java預(yù)處理程序CentOS rpm安裝./cdrom/CentOS/gcc-c++-4.1.1-52.el5.i386.rpmCentOS rpm安裝gcc-c++包前還缺少其依賴包libstdc++-devel,第三張光盤
[root@localhost mnt]# find -iname libstd*./cdrom/CentOS/libstdc++-devel-4.1.1-52.el5.i386.rpm[root@localhost mnt]# rpm -ivh ./cdrom/CentOS/libstdc++-devel-4.1.1-52.el5.i386.rpmwarning: ./cdrom/CentOS/libstdc++-devel-4.1.1-52.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID e8562897Preparing... [100%]1:libstdc++-devel [100%]
第二張光盤[root@localhost mnt]# find -iname gcc*./cdrom/CentOS/gcc-4.1.1-52.el5.i386.rpm./cdrom/CentOS/gcc-c++-4.1.1-52.el5.i386.rpm./cdrom/CentOS/gcc-gfortran-4.1.1-52.el5.i386.rpm./cdrom/CentOS/gcc-java-4.1.1-52.el5.i386.rpm[root@localhost mnt]# rpm -ivh ./cdrom/CentOS/gcc-c++-4.1.1-52.el5.i386.rpmwarning: ./cdrom/CentOS/gcc-c++-4.1.1-52.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID e8562897Preparing... [100%]1:gcc-c++[100%]
“CentOS rpm安裝編譯gcc時(shí)的過程”的內(nèi)容就介紹到這里了,感謝大家的閱讀。如果想了解更多行業(yè)相關(guān)的知識可以關(guān)注億速云網(wǎng)站,小編將為大家輸出更多高質(zhì)量的實(shí)用文章!
免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場,如果涉及侵權(quán)請聯(lián)系站長郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。