rpmrebuild.spec
Pawel "shogun" Serej
shogun w pstryk.net
Pią, 20 Maj 2005, 20:02:37 CEST
W załączniku jest spec.
Nie znalazłem nigdzie paczki tar.gz, zamiast tego była spakowana w src.rpm.
Wrzuciłem na swoje konto źródła, ale to tylko chwilowe rozwiązanie. Co więcej
wersja to 2.0.3-1 ale nie mogłem dodać '-1' do Version, więc dodałem na
sztywno w Source0, ale mam nadzieję, że to też ktoś poprawi.
--
Pozdrawiam Shogun
#GG: 1664795
#JID: shogun (at) jabberpl.org
-------------- następna część ---------
# $Revision: 1.46 $, $Date: 2005/04/09 16:03:51 $
#
# Conditional build:
#
Summary: A tool to build rpm file from rpm database
Summary(pl): Narzędzie do przebudowywania pakietów rpm
Name: rpmrebuild
Version: 2.0.3
Release: 0.1
License: GPL
Group: Applications
Source0: http://shogun.pstryk.net/%{name}-%{version}-1.tar.gz
# Source0-md5: ee8242f5bcf8d9639a03658a2175547b
URL: http://rpmrebuild.sourceforge.net/
BuildRequires: automake
BuildRequires: autoconf
BuildRequires: bash
BuildRequires: cpio
BuildRequires: grep
BuildRequires: sed
BuildRequires: rpm >= 4.0
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
you have an installed package on a computer, want to install on other
one, and do not find the rpm file anymore.
Or you want to distribute your customization in an rpm format
this tool is for you
%description -l pl
rpmrebuild to narzędzie służące ponownemu przebudowywaniu dawnych pakietów, jeśli
np. nie możesz znaleźć ich źródła.
%prep
%setup -q -c %{name}-%{version}
%build
%{__make}
%install
rm -rf $RPM_BUILD_ROOT
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
%clean
rm -rf $RPM_BUILD_ROOT
%postun
#echo "%postun $1"
[ $1 -ne 0 ] && exit 0 || :
########################################
# This code should remove all lines from
# the line contains 'RPMREBUILD START'
# till (include) line 'RPMREBUILD END'
# in the file /etc/popt
########################################
rm -f /etc/popt.tmp || exit
if [ -f /etc/popt ]; then
(
need_copy=1
while :; do
if ! read -r line; then
[ "x$line" = "x" ] && break
fi
case "x$line" in
x*RPMREBUILD*START*) need_copy="" ; continue;;
x*RPMREBUILD*END*) need_copy="1"; continue;;
esac
[ "$need_copy" ] && { echo "$line" || exit; } || :
done
) < /etc/popt > /etc/popt.tmp || exit
if [ -s /etc/popt.tmp ]; then
mv -f /etc/popt.tmp /etc/popt || exit
else
rm -f /etc/popt.tmp /etc/popt || exit
fi
else
:
fi
%triggerin -- rpm < 4.0.3
#echo "%triggerin -- rpm < 4.0.3 ('$1' '$2')"
########################################
# This code should remove all lines from
# the line contains 'RPMREBUILD START'
# till (include) line 'RPMREBUILD END'
# in the file /etc/popt
########################################
rm -f /etc/popt.tmp || exit
if [ -f /etc/popt ]; then
(
need_copy=1
while :; do
if ! read -r line; then
[ "x$line" = "x" ] && break
fi
case "x$line" in
x*RPMREBUILD*START*) need_copy="" ; continue;;
x*RPMREBUILD*END*) need_copy="1"; continue;;
esac
[ "$need_copy" ] && { echo "$line" || exit; } || :
done
) < /etc/popt > /etc/popt.tmp || exit
if [ -s /etc/popt.tmp ]; then
mv -f /etc/popt.tmp /etc/popt || exit
else
rm -f /etc/popt.tmp /etc/popt || exit
fi
else
:
fi
cat /usr/lib/rpmrebuild/popt-without-POPTdesc >> /etc/popt || exit
%triggerin -- rpm >= 4.0.3
#echo "%triggerin -- rpm >= 4.0.3 ('$1' '$2')"
########################################
# This code should remove all lines from
# the line contains 'RPMREBUILD START'
# till (include) line 'RPMREBUILD END'
# in the file /etc/popt
########################################
rm -f /etc/popt.tmp || exit
if [ -f /etc/popt ]; then
(
need_copy=1
while :; do
if ! read -r line; then
[ "x$line" = "x" ] && break
fi
case "x$line" in
x*RPMREBUILD*START*) need_copy="" ; continue;;
x*RPMREBUILD*END*) need_copy="1"; continue;;
esac
[ "$need_copy" ] && { echo "$line" || exit; } || :
done
) < /etc/popt > /etc/popt.tmp || exit
if [ -s /etc/popt.tmp ]; then
mv -f /etc/popt.tmp /etc/popt || exit
else
rm -f /etc/popt.tmp /etc/popt || exit
fi
else
:
fi
cat /usr/lib/rpmrebuild/popt-with-POPTdesc >> /etc/popt || exit
%files
%defattr(0644,root,root,0755)
%attr(755,root,root) /usr/lib/*
%attr(755,root,root) /usr/bin/rpmrebuild
/usr/share/man/man1/demo.plug.1rrp.gz
/usr/share/man/man1/file2pacDep.plug.1rrp.gz
/usr/share/man/man1/nodoc.plug.1rrp.gz
/usr/share/man/man1/rpmrebuild.1.gz
/usr/share/man/man1/rpmrebuild_plugins.1.gz
/usr/share/man/man1/uniq.plug.1rrp.gz
%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
%changelog
* %{date} PLD Team <feedback w pld-linux.org>
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log: rpmrebuild.spec,v $
Więcej informacji o liście dyskusyjnej pld-devel-pl