Mailinglist Archive: opensuse-packaging (250 mails)

< Previous Next >
Re: [opensuse-packaging] need help with .spec file
  • From: Cristian Rodríguez <crrodriguez@xxxxxxxxxxxx>
  • Date: Wed, 19 Aug 2009 09:44:37 -0400
  • Message-id: <4A8C01C5.6020307@xxxxxxxxxxxx>
On 19/08/09 09:02, doiggl@xxxxxxxxxxxxxxxxxx wrote:
Hello,
Thanks Dominique and Adrian for the info, your correct about the errors.

So far I've added to the specfile the following:-

BuildRequires: pwdutils , apache2-devel

%define apache apache2
%define apache_libexecdir %(%{apxs} -q LIBEXECDIR)
%define apache_sysconfdir %(%{apxs} -q SYSCONFDIR)
%define apache_includedir %(%{apxs} -q INCLUDEDIR)
%define apache_serverroot %(%{apxs} -q PREFIX)
%define apache_localstatedir %(%{apxs} -q LOCALSTATEDIR)
%define apache_mmn %(MMN=$(%{apxs} -q LIBEXECDIR)_MMN; test -x $MMN &&
$MMN)


Requires: apache2 %{apache_mmn}

%pre
id cricket >/dev/null 2>&1
if [ $? -ne 0 ]; then
/usr/sbin/useradd -r -d %{_libdir}/%{name} -c "cricket id" cricket
/usr/sbin/groupadd apache
fi

%postun
if [ $1 -eq 0 ]; then
/usr/sbin/userdel cricket
/usr/sbin/groupdel apache
fi

no, do not mess with the apache group...


cricket: "/var/cricket" is not allowed anymore in FHS 2.2.

use /var/lib/%{name} instead.


--
To unsubscribe, e-mail: opensuse-packaging+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-packaging+help@xxxxxxxxxxxx

< Previous Next >