spec file -- Matt Domsch Software Architect Dell Linux Solutions linux.dell.com & www.dell.com/linux Linux on Dell mailing lists @ http://lists.us.dell.com --- OpenIPMI.spec.orig 2005-05-19 16:47:03.000000000 -0500 +++ OpenIPMI.spec 2005-05-19 22:53:59.000000000 -0500 @@ -1,13 +1,15 @@ Summary: OpenIPMI (Intelligent Platform Management Interface) library and tools Name: OpenIPMI Version: 1.4.11 -Release: 5 +Release: 6 License: GPL Group: System Environment/Base Source: http://prdownloads.sourceforge.net/openipmi/%{name}-%{version}.tar.gz Patch1: OpenIPMI-1.4.11-gcc4.patch +Patch2: initscripts.patch BuildRoot: /var/tmp/%{name}-%{version}-root BuildPrereq: gdbm-devel swig +Requires: lsb %description The Open IPMI project aims to develop an open code base to allow access to @@ -26,6 +28,7 @@ %prep %setup -q %patch1 -p1 -b .gcc4 +%patch2 -p1 %build %configure @@ -35,9 +38,34 @@ %makeinstall rm -rf $RPM_BUILD_ROOT/%{_libdir}/*.la +# install SYSV init stuff +mkdir -p $RPM_BUILD_ROOT/etc/init.d +install -m755 $RPM_BUILD_DIR/%{name}-%{version}/ipmi.init \ + $RPM_BUILD_ROOT/etc/init.d/ipmi +mkdir -p $RPM_BUILD_ROOT/etc/sysconfig +install -m644 $RPM_BUILD_DIR/%{name}-%{version}/ipmi.sysconf \ + $RPM_BUILD_ROOT/etc/sysconfig/ipmi + + + %clean rm -rf $RPM_BUILD_ROOT +%post +if [ -x /usr/lib/lsb/install_initd ]; then + /usr/lib/lsb/install_initd ipmi +elif [ -x /sbin/chkconfig ]; then + /sbin/chkconfig --add ipmi +fi + +%preun +if [ -x /usr/lib/lsb/remove_initd ]; then + /usr/lib/lsb/remove_initd ipmi +elif [ -x /sbin/chkconfig ]; then + /sbin/chkconfig --del ipmi +fi + + %files %defattr(-,root,root) %{_bindir}/* @@ -47,6 +75,8 @@ %{_libdir}/perl5/site_perl/*/*-linux-thread-multi/OpenIPMI.pm %dir %{_libdir}/perl5/site_perl/*/*-linux-thread-multi/auto/OpenIPMI %{_libdir}/perl5/site_perl/*/*-linux-thread-multi/auto/OpenIPMI/* +%config(noreplace) %{_sysconfdir}/init.d/ipmi +%config(noreplace) %{_sysconfdir}/sysconfig/ipmi %files devel %defattr(-,root,root) @@ -55,6 +85,9 @@ %{_libdir}/*.a %changelog +* Thu May 19 2005 Matt Domsch <Matt_Domsch@xxxxxxxx> 1.4.11-6 +- add initscript and config file + * Wed Mar 30 2005 Phil Knirsch <pknirsch@xxxxxxxxxx> 1.4.11-5 - Correctly put libs in the proper packages -- fedora-devel-list mailing list fedora-devel-list@xxxxxxxxxx http://www.redhat.com/mailman/listinfo/fedora-devel-list