2009-04-10 07:31:57 +00:00
|
|
|
Name: fcoe-utils
|
|
|
|
Version: 1.0.7
|
2009-06-09 08:49:52 +00:00
|
|
|
Release: 7%{?dist}
|
2009-04-10 07:31:57 +00:00
|
|
|
Summary: Fibre Channel over Ethernet utilities
|
|
|
|
|
|
|
|
Group: Applications/System
|
|
|
|
License: GPLv2
|
|
|
|
URL: http://www.open-fcoe.org
|
|
|
|
Source0: http://www.open-fcoe.org/openfc/downloads/%{name}-%{version}.tar.gz
|
2009-06-09 08:49:52 +00:00
|
|
|
Source1: quickstart.txt
|
2009-04-10 07:31:57 +00:00
|
|
|
Patch0: fcoe-utils-1.0.7-init.patch
|
2009-05-04 11:52:53 +00:00
|
|
|
Patch1: fcoe-utils-1.0.7-free.patch
|
2009-05-14 14:17:13 +00:00
|
|
|
Patch2: fcoe-utils-1.0.7-init-condrestart.patch
|
|
|
|
Patch3: fcoe-utils-1.0.7-longOpts.patch
|
2009-04-10 07:31:57 +00:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
|
|
|
|
|
|
BuildRequires: libhbaapi-devel dcbd-devel
|
2009-04-27 11:24:53 +00:00
|
|
|
Requires: dcbd libhbalinux
|
2009-04-10 07:31:57 +00:00
|
|
|
Requires(post): chkconfig
|
|
|
|
Requires(preun): chkconfig initscripts
|
|
|
|
Requires(postun): initscripts
|
|
|
|
|
|
|
|
%description
|
|
|
|
Fibre Channel over Ethernet utilities
|
|
|
|
fcoeadm - command line tool for configuring FCoE interfaces
|
|
|
|
fcoemon - service to configure DCB Ethernet QOS filters, works with dcbd
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q
|
|
|
|
%patch0 -p1 -b .initPatch
|
2009-05-04 11:52:53 +00:00
|
|
|
%patch1 -p1 -b .freePatch
|
2009-05-14 14:17:13 +00:00
|
|
|
%patch2 -p1 -b .condrestartPatch
|
|
|
|
%patch3 -p1 -b .longOpts
|
2009-04-10 07:31:57 +00:00
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
%configure
|
|
|
|
make %{?_smp_mflags}
|
|
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
make install DESTDIR=$RPM_BUILD_ROOT
|
2009-04-27 11:24:53 +00:00
|
|
|
mkdir -p $RPM_BUILD_ROOT%{_initrddir}
|
2009-05-14 14:17:13 +00:00
|
|
|
mv $RPM_BUILD_ROOT/etc/init.d/fcoe $RPM_BUILD_ROOT%{_initrddir}/fcoe
|
2009-04-10 07:31:57 +00:00
|
|
|
rm -rf $RPM_BUILD_ROOT/etc/init.d
|
2009-06-09 08:49:52 +00:00
|
|
|
install -m 644 %SOURCE1 quickstart.txt
|
2009-04-10 07:31:57 +00:00
|
|
|
|
|
|
|
|
|
|
|
%clean
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
|
|
|
|
|
|
%post
|
2009-05-14 14:17:13 +00:00
|
|
|
/sbin/chkconfig --add fcoe
|
|
|
|
|
|
|
|
%triggerun -- fcoe-utils <= 1.0.7-5
|
|
|
|
if [ -x %{_initrddir}/fcoe-utils ]; then
|
|
|
|
/sbin/service fcoe-utils stop > /dev/null 2>&1
|
|
|
|
/sbin/chkconfig fcoe-utils off
|
|
|
|
# now copy an updated file, which we need to do proper condrestart
|
|
|
|
sed 's/\/var\/lock\/subsys\/fcoe/\/var\/lock\/subsys\/fcoe-utils/' %{_initrddir}/fcoe > %{_initrddir}/fcoe-utils
|
|
|
|
fi
|
|
|
|
|
|
|
|
%triggerpostun -- fcoe-utils <= 1.0.7-5
|
|
|
|
if [ -x %{_initrddir}/fcoe-utils ]; then
|
|
|
|
rm -f %{_initrddir}/fcoe-utils # this file should be already deleted, but just in case ...
|
|
|
|
fi
|
2009-04-10 07:31:57 +00:00
|
|
|
|
|
|
|
%preun
|
|
|
|
if [ $1 = 0 ]; then
|
2009-05-14 14:17:13 +00:00
|
|
|
/sbin/service fcoe stop > /dev/null 2>&1
|
|
|
|
/sbin/chkconfig --del fcoe
|
2009-04-10 07:31:57 +00:00
|
|
|
fi
|
|
|
|
|
|
|
|
%postun
|
|
|
|
if [ "$1" -ge "1" ]; then
|
2009-05-14 14:17:13 +00:00
|
|
|
/sbin/service fcoe condrestart > /dev/null 2>&1 || :
|
2009-04-10 07:31:57 +00:00
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root,-)
|
2009-06-09 08:49:52 +00:00
|
|
|
%doc README COPYING quickstart.txt
|
2009-04-10 07:31:57 +00:00
|
|
|
%{_sbindir}/*
|
|
|
|
%{_mandir}/man8/*
|
|
|
|
%{_sysconfdir}/fcoe/scripts/fcoeplumb
|
|
|
|
%dir %{_sysconfdir}/fcoe/
|
|
|
|
%dir %{_sysconfdir}/fcoe/scripts/
|
|
|
|
%config(noreplace) %{_sysconfdir}/fcoe/config
|
|
|
|
%config(noreplace) %{_sysconfdir}/fcoe/cfg-ethx
|
2009-05-14 14:17:13 +00:00
|
|
|
%{_initrddir}/fcoe
|
2009-04-10 07:31:57 +00:00
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
2009-06-09 08:49:52 +00:00
|
|
|
* Tue Jun 9 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-7
|
|
|
|
- added quickstart file to %doc (#500759)
|
|
|
|
|
2009-05-14 14:17:13 +00:00
|
|
|
* Thu May 14 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-6
|
|
|
|
- renamed init script to fcoe, changed lock filename to fcoe
|
|
|
|
(#497604)
|
|
|
|
- init script modified to do condrestart properly
|
|
|
|
- some modifications in spec file to apply previous change
|
|
|
|
to older versions od init script during update
|
|
|
|
- fixed issue with accepting long options (#498551)
|
|
|
|
|
|
|
|
* Mon May 4 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-5
|
2009-05-04 11:52:53 +00:00
|
|
|
- fixed SIGSEGV when fcoe module isn't loaded (#498550)
|
|
|
|
|
2009-04-27 11:24:53 +00:00
|
|
|
* Wed Apr 27 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-4
|
|
|
|
- added libhbalinux to Requires (#497605)
|
|
|
|
- correction of spec file (_initddir -> _initrddir)
|
|
|
|
|
2009-04-10 07:31:57 +00:00
|
|
|
* Wed Apr 8 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-3
|
|
|
|
- more minor corrections in spec file
|
|
|
|
|
|
|
|
* Thu Apr 2 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-2
|
|
|
|
- minor corrections in spec file
|
|
|
|
- moved init script to correct location
|
|
|
|
- correction in the init script (chkconfig directives)
|
|
|
|
|
|
|
|
* Mon Mar 2 2009 Chris Leech <christopher.leech@intel.com> - 1.0.7-1
|
|
|
|
- initial rpm build of fcoe tools
|
|
|
|
|