File mpt-status.spec of Package mpt-status
%define realname mpt-status
%define realver 1.2.0
%define srcext tar.bz2
# Common info
Name: %{realname}
Version: %{realver}
Release: wiz%{?extraver:0.}1
License: GPL
Group: Hardware/Other
URL: http://www.drugphish.ch/~ratz/mpt-status/
Summary: Retrieve configuration and health status from LSI hardware RAID controllers
# Install-time parameters
# Build-time parameters
BuildRoot: %{_tmppath}/%{name}-root
Source0: %{realname}-%{realver}%{?extraver}.%{srcext}
# RHEL does not have package with kernel sources
Source1: drivers.message.fusion.tar.bz2
Patch: linux-compiler.patch
%description
The mpt-status software is a query tool to access the running configuration and
status of LSI SCSI HBAs. This is a completely rewritten version of the original
mpt-status-1.0 tool written by Matt Braithwaite. mpt-status allows you to monitor
the health and status of your RAID setup.
# Preparation step (unpackung and patching if necessary)
%prep
%setup -q -n %{realname}-%{realver}%{?extraver} -a1
%patch -p1
%build
%__cc %{optflags} -I. -Iincl -Wl,--as-needed -Wl,--strip-all mpt-status.c -o mpt-status
%install
%__install -D -m500 mpt-status %{buildroot}%{_sbindir}/mpt-status
%__install -D -m644 man/mpt-status.8 %{buildroot}%{_mandir}/man8/mpt-status.8
%clean
[ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
%files
%defattr(-,root,root)
%doc doc/*
%{_sbindir}/mpt-status
%doc %{_mandir}/man8/mpt-status.8*
%changelog