parent
e2f683d1ca
commit
d2788be5ee
25
mt-st.spec
25
mt-st.spec
@ -1,8 +1,8 @@
|
||||
Summary: Tool for controlling tape drives
|
||||
Name: mt-st
|
||||
Version: 1.1
|
||||
Release: 3%{?dist}
|
||||
License: GPLv2
|
||||
Release: 4%{?dist}
|
||||
License: GPL+
|
||||
Group: Applications/System
|
||||
URL: ftp://ftp.ibiblio.org/pub/linux/system/backup
|
||||
Source0: ftp://metalab.unc.edu/pub/Linux/system/backup/mt-st-%{version}.tar.gz
|
||||
@ -13,8 +13,8 @@ Patch2: mt-st-0.7-config-files.patch
|
||||
Patch3: mt-st-0.9b-manfix.patch
|
||||
Patch4: mt-st-1.1-mtio.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
Requires(post): /sbin/chkconfig
|
||||
Requires(preun): /sbin/chkconfig
|
||||
Requires(post): chkconfig
|
||||
Requires(preun): chkconfig
|
||||
|
||||
%description
|
||||
The mt-st package contains the mt and st tape drive management
|
||||
@ -23,6 +23,7 @@ can control rewinding, ejecting, skipping files and blocks and more.
|
||||
|
||||
Install mt-st if you need a tool to manage tape drives.
|
||||
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1 -b .redhat
|
||||
@ -37,16 +38,20 @@ iconv -f ISO8859-1 -t UTF-8 -o $f.new $f
|
||||
touch -r $f $f.new
|
||||
mv $f.new $f
|
||||
|
||||
|
||||
%build
|
||||
make CFLAGS="$RPM_OPT_FLAGS"
|
||||
|
||||
|
||||
%install
|
||||
rm -rf ${RPM_BUILD_ROOT}
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
make install mandir=%{_mandir}
|
||||
install -D -p -m 0755 %{SOURCE1} $RPM_BUILD_ROOT%{_initddir}/stinit
|
||||
|
||||
|
||||
%clean
|
||||
rm -rf ${RPM_BUILD_ROOT}
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
|
||||
%post
|
||||
/sbin/chkconfig --add stinit
|
||||
@ -56,15 +61,21 @@ if [ $1 -eq 0 ]; then
|
||||
/sbin/chkconfig --del stinit
|
||||
fi
|
||||
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%defattr(-,root,root,-)
|
||||
%doc COPYING README README.stinit mt-st-1.1.lsm stinit.def.examples
|
||||
/bin/mt
|
||||
/sbin/stinit
|
||||
%{_mandir}/man[18]/*
|
||||
%{_initddir}/stinit
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Nov 26 2009 Dan Horák <dan[at]danny.cz> - 1.1-4
|
||||
- stinit initscript updated (#541592)
|
||||
- fixed License
|
||||
|
||||
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
|
||||
|
||||
|
||||
24
stinit.init
24
stinit.init
@ -1,21 +1,35 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# stinit This calls /sbin/stinit if /etc/stinit.def exists
|
||||
# stinit Initialize SCSI tape drives
|
||||
#
|
||||
# chkconfig: 2345 40 99
|
||||
# description: calls stinit if /etc/stinit.def exists
|
||||
# chkconfig: - 90 10
|
||||
# description: Initialize SCSI tape drives with /sbin/stinit
|
||||
# config: /etc/stinit.def
|
||||
|
||||
# BEGIN INIT INFO
|
||||
# Provides: stinit
|
||||
# Default-Start:
|
||||
# Default-Stop: 0 1 2 3 4 5 6
|
||||
# Short-Description: Initialize SCSI tape drives
|
||||
# Description: Initialize SCSI tape drives
|
||||
# END INIT INFO
|
||||
|
||||
. /etc/init.d/functions
|
||||
|
||||
exec=/sbin/stinit
|
||||
config=/etc/stinit.def
|
||||
|
||||
# See how we were called.
|
||||
case "$1" in
|
||||
start)
|
||||
[ -f /etc/stinit.def ] && /sbin/stinit
|
||||
[ -x $exec ] || exit 5
|
||||
[ -f $config ] || exit 6
|
||||
$exec
|
||||
;;
|
||||
stop)
|
||||
;;
|
||||
*)
|
||||
echo $"Usage: $0 {start}"
|
||||
exit 1
|
||||
exit 2
|
||||
esac
|
||||
exit 0
|
||||
|
||||
Loading…
Reference in New Issue
Block a user