mt-st/mt-st.spec

72 lines
1.7 KiB
RPMSpec
Raw Normal View History

2019-12-17 10:46:56 +08:00
Name: mt-st
2023-07-12 16:21:53 +08:00
Version: 1.7
Release: 1
2019-12-17 10:46:56 +08:00
Summary: Tool to manage tape drives
License: GPL+
2023-07-12 16:21:53 +08:00
URL: https://github.com/iustin/mt-st
2019-12-17 10:46:56 +08:00
2023-07-12 16:21:53 +08:00
Source0: https://github.com/iustin/mt-st/releases/download/v%{version}/%{name}-%{version}.tar.gz
2019-12-17 10:46:56 +08:00
Source1: stinit.service
BuildRequires: gcc systemd make bash-completion
2019-12-17 10:46:56 +08:00
Requires(post): systemd
Requires(preun): systemd
Requires(postun): systemd
%description
The mt-st package contains two programs: mt and stinit. Mt is basically a "standard" mt with
additional commands to send the ioctls specific to the Linux SCSI tape driver. Stinit is a program
to initialize the tape drive characteristics.
%package_help
%prep
%autosetup
2019-12-17 10:46:56 +08:00
%build
make CFLAGS="%{build_cflags} %{build_ldflags}"
%install
COMPLETIONDIR=%{buildroot}$(pkg-config --variable=completionsdir bash-completion)
%make_install EXEC_PREFIX=/usr COMPLETIONINSTALLDIR=$COMPLETIONDIR
2019-12-17 10:46:56 +08:00
install -D -p -m 0644 %{SOURCE1} %{buildroot}%{_unitdir}/stinit.service
cd $COMPLETIONDIR
mv mt-st mt
2019-12-17 10:46:56 +08:00
%post
%systemd_post stinit.service
%preun
%systemd_preun stinit.service
%postun
%systemd_postun_with_restart stinit.service
%files
%defattr(-,root,root)
%license COPYING
%{_bindir}/mt
%{_sbindir}/stinit
%{_unitdir}/stinit.service
%{_datadir}/bash-completion/
2019-12-17 10:46:56 +08:00
%files help
%defattr(-,root,root)
%doc README.md stinit.def.examples
2019-12-17 10:46:56 +08:00
%{_mandir}/man[18]/*
%changelog
2023-07-12 16:21:53 +08:00
* Wed Jul 12 2023 chenchen <chen_aka_jan@163.com> - 1.7-1
- Upgrade to version 1.7
* Tue Jan 18 2022 SimpleUpdate Robot <tc@openeuler.org> - 1.4-1
- Upgrade to version 1.4
2019-12-17 10:46:56 +08:00
* Wed Dec 4 2019 openEuler Buildteam <buildteam@openeuler.org> - 1.1-25
- Package init