packages: ggaoed/ggaoed.spec - init.d script, release 0.2.
pluto
pluto at pld-linux.org
Wed Aug 4 14:31:42 CEST 2010
Author: pluto Date: Wed Aug 4 12:31:42 2010 GMT
Module: packages Tag: HEAD
---- Log message:
- init.d script, release 0.2.
---- Files affected:
packages/ggaoed:
ggaoed.spec (1.1 -> 1.2)
---- Diffs:
================================================================
Index: packages/ggaoed/ggaoed.spec
diff -u packages/ggaoed/ggaoed.spec:1.1 packages/ggaoed/ggaoed.spec:1.2
--- packages/ggaoed/ggaoed.spec:1.1 Wed Aug 4 11:37:49 2010
+++ packages/ggaoed/ggaoed.spec Wed Aug 4 14:31:37 2010
@@ -2,17 +2,21 @@
Summary: ggaoed - ATA over Ethernet target implementation for Linux
Name: ggaoed
Version: 1.1
-Release: 0.1
+Release: 0.2
License: GPL v2
Group: Base/Utilities
Source0: http://ggaoed.googlecode.com/files/%{name}-%{version}.tar.gz
# Source0-md5: 9d46d1b274e96547bb93bc5360a1db54
+Source1: %{name}.init
+Source2: %{name}.sysconfig
Patch0: %{name}-build.patch
URL: http://code.google.com/p/ggaoed/
BuildRequires: docbook2X >= 0.8
BuildRequires: glib2-devel >= 2.12
BuildRequires: libaio-devel >= 0.3.107
BuildRequires: libatomic_ops >= 1.2
+Requires(post,preun): /sbin/chkconfig
+Requires: rc-scripts
Requires: uname(release) >= 2.6.31
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -31,27 +35,45 @@
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_sysconfdir}
+install -d $RPM_BUILD_ROOT%{_sharedstatedir}/ggaoed
%{__make} install \
datarootdir=$RPM_BUILD_ROOT%{_datadir} \
sbindir=$RPM_BUILD_ROOT%{_sbindir} \
mandir=$RPM_BUILD_ROOT%{_mandir}
-install ggaoed.conf.dist $RPM_BUILD_ROOT%{_sysconfdir}/ggaoed.conf
+install -D ggaoed.conf.dist $RPM_BUILD_ROOT%{_sysconfdir}/ggaoed.conf
+install -D %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/ggaoed
+install -D %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/ggaoed
%clean
rm -rf $RPM_BUILD_ROOT
+%post
+/sbin/chkconfig --add ggaoed
+/sbin/chkconfig ggaoed off
+%service ggaoed restart
+
+%preun
+if [ "$1" = "0" ]; then
+ /sbin/chkconfig --del ggaoed
+ %service ggaoed stop
+ # nuke config cache if uninstalling
+ rm -rf %{_sharedstatedir}/ggaoed/*
+fi
+
%files
%defattr(644,root,root,755)
%doc NEWS README
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ggaoed.conf
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ggaoed.conf
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/ggaoed
+%attr(754,root,root) /etc/rc.d/init.d/ggaoed
%attr(755,root,root) %{_sbindir}/ggaoectl
%attr(755,root,root) %{_sbindir}/ggaoed
%{_mandir}/man5/ggaoed.conf.5*
%{_mandir}/man8/ggaoectl.8*
%{_mandir}/man8/ggaoed.8*
+%dir %{_sharedstatedir}/ggaoed
%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
%changelog
@@ -59,5 +81,8 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.2 2010/08/04 12:31:37 pluto
+- init.d script, release 0.2.
+
Revision 1.1 2010/08/04 09:37:49 pluto
- initial spec.
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/ggaoed/ggaoed.spec?r1=1.1&r2=1.2&f=u
More information about the pld-cvs-commit
mailing list