0
我建立一個rpm,請讓我知道我錯了,如何解決沒有這樣的文件或目錄錯誤:建立RPM時(%prep)的退出狀態不良?
我的規格文件rpms.spec並且其內容是:
Summary: GNU indent
Name: rpms
Version: 1
Release: 1
Source0: %{name}-%{version}.tar.gz
License: GPL
Group: Development/Tools
%description
The GNU indent program reformats C code to any of a variety of
formatting standards, or you can define your own.
%prep
%setup -q
%build
./configure
make
%install
make install
%files
%defattr(-,root,root)
/usr/local/bin/indent
%doc /usr/local/info/indent.info
%doc %attr(0444,root,root) /usr/local/man/man1/indent.1
%doc COPYING AUTHORS README NEWS
我抄tar文件到/ usr/SRC /紅帽/來源/也 ,然後當我做的rpmbuild -ba rpms.spec我收到以下錯誤
rpmbuild -ba rpms.spec Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.87218
+ umask 022
+ cd /usr/src/redhat/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ cd /usr/src/redhat/BUILD
+ rm -rf rpms-1
+ /bin/gzip -dc /usr/src/redhat/SOURCES/rpms-1.tar.gz
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd rpms-1 /var/tmp/rpm-tmp.87218: line 35: cd: rpms-1: No such file or directory error: Bad exit status from /var/tmp/rpm-tmp.87218 (%prep)
RPM生成錯誤:從/var/tmp/rpm-tmp.87218 壞退出狀態(%準備)
沒有目錄作爲rpms-1.我試圖在BUILd目錄中創建目錄,它沒有工作。
這裏面應該在serverfault上。 – 2009-12-04 13:51:06