Linux 安裝*src.rpm的時候出現:
warning: user mandrake does not exist - using root
warning: group mandrake does not exist - using root
錯誤 。
症狀:
[root@localhost System_Sources]# rpm -Uvh libmpfr-2.2.1-3mdv2007.1.src.rpm warning: libmpfr-2.2.1-3mdv2007.1.src.rpm: V3 DSA signature: NOKEY, key ID 26752624 1:libmpfr warning: user mandrake does not exist - using root warning: group mandrake does not exist - using root warning: user mandrake does not exist - using root warning: group mandrake does not exist - using root ########################################### [100%] [root@localhost Desktop]# rpm -Uvh yum-3.2.20-4.fc10.src.rpm warning: yum-3.2.20-4.fc10.src.rpm: V3 DSA signature: NOKEY, key ID 0b86274e 1:yum warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root warning: user mockbuild does not exist - using root warning: group mockbuild does not exist - using root ########################################### [100%]
原因:
方法:
[root@localhost beinan]# ls unrar* unrar-3.5.2-1.2.fc4.src.rpm unrar.spec
unrar-3.5.2-1.2.fc4.src.rpm unrar.spec
[root@localhost beinan]# rpm -ivh unrar-3.5.2-1.2.fc4.src.rpm
[root@localhost beinan]# ls /usr/src/redhat/SOURCES/unrar unrar.1 unrarsrc-3.5.2.tar.gz
# rpmbuild --ba unrar.spec
編譯完成:
[root@localhost beinan]# ls /usr/src/redhat/RPMS/i386/ unrar-3.5.2-1.i386.rpm unrar-debuginfo-3.5.2-1.i386.rpm
[root@localhost beinan]# rpm -ivh /usr/src/redhat/RPMS/i386/unrar-3.5.2-1.i386.rpm Preparing... ########################################### [100%] 1:unrar ########################################### [100%]
[root@localhost beinan]# unrar x mydoc.rar
例 2:
1.執行rpm -i your-package.src.rpm 2. cd /usr/src/redhat/SPECS 3. rpmbuild -bp your-package.specs 一個和你的軟件包同名的specs文件 4. cd /usr/src/redhat/BUILD/your-package/ 一個和你的軟件包同名的目錄 5. ./configure 這一步和編譯普通的源碼軟件一樣,可以加上參數 6. make 7. make install
1.執行rpm -i you-package.src.rpm 2. cd /usr/src/redhat/SPECS 前兩步和方法一相同 3. rpmbuild -bb your-package.specs 一個和你的軟件包同名的specs文件 這時,在/usr/src/redhat/RPM/i386/ (根據具體包的不同,也可能是i686,noarch等等) 在這個目錄下,有一個新的rpm包,這個是編譯好的二進制文件。 執行rpm -i new-package.rpm即可安裝完成。
本文出自 “黃寶的博客” 博客,請務必保留此出處http://huangbao.blog.51cto.com/725279/152656