From: "Slava Semushin" <slava.semushin@gmail.com> To: "ALT Devel discussion list" <devel@lists.altlinux.org> Subject: Re: [devel] [git update] packages/varnish: heads/master Date: Tue, 3 Jul 2007 15:39:57 +0700 Message-ID: <75e139a00707030139m29ec91b1va1b9f61639402cef@mail.gmail.com> (raw) In-Reply-To: <20070703082249.CD60C1A3402E@ssh.git.local.altlinux.org> 2007/7/3, Sergey Ivanov <seriv / altlinux.org>: [...] > diff --git a/varnish.spec b/varnish.spec > new file mode 100644 > index 0000000..23b16fd > --- /dev/null > +++ b/varnish.spec > @@ -0,0 +1,218 @@ > +Summary: Varnish is a high-performance HTTP accelerator > +Name: varnish > +Version: 1.0.4.3 > +Release: alt2 > +License: BSD-like > +Group: System/Servers > +Packager: Sergey Ivanov <seriv@altlinux.ru> > +Group: System/Servers Тег Group указан два раза. Одного было бы достаточно. [...] > +%prep > +%setup -q s/%setup -q/%setup/ > + > +%build > +%__aclocal > +%__libtoolize --copy --force > +%__autoheader > +%__automake --add-missing --copy --foreign > +%__autoconf Возможно, вместо этих пяти строк будет достаточно вызова макроса %__autoreconf > +# Remove "--disable static" if you want to build static libraries > +# (ie for the devel package) > +%configure --disable-static У нас обычно это делается через %def_{enable,disable} Гляньте, к примеру, как это сделано у меня в libtap.spec [...] > +make install DESTDIR=%{buildroot} INSTALL="install -p" %make_install DESTDIR=%buildroot install [...] > +%clean > +rm -rf %{buildroot} Секция %clean не нужна. > +%files > +%defattr(-,root,root,-) Если не ошибаюсь, то этот %defattr тоже не нужен, так как оно так по умолчанию. [...] > +%{_var}/log/varnish > +%{_mandir}/man1/*.1* > +%{_mandir}/man7/*.7* Можно заменить на макросы %_logdir, %_man1dir и %_man7dir. [...] > +%files libs > +%defattr(-,root,root,-) Опять же я бы убрал этот %defattr [...] > +%post > +/sbin/chkconfig --add varnish > +/sbin/chkconfig --add varnishlog > + > +%preun > +if [ $1 -lt 1 ]; then > + /sbin/service varnish stop > /dev/null 2>/dev/null > + /sbin/service varnishlog stop > /dev/null 2>/dev/null > + /sbin/chkconfig --del varnish > + /sbin/chkconfig --del varnishlog > +fi > + > +%postun > +if [ $1 -ge 1 ]; then > + /sbin/service varnish condrestart > /dev/null 2>/dev/null > + /sbin/service varnishlog condrestart > /dev/null 2>/dev/null > +fi > + > +%post libs -p /sbin/ldconfig > + > +%postun libs -p /sbin/ldconfig [...] Наверняка, есть скрипты и макросы для автоматизации этого процесса. В частности для остановки/запуска демонов есть %post_service, кажется. Советую посмотреть в чужие спеки, как это сделано у других. -- + Slava Semushin | slava.semushin @ gmail.com + ALT Linux Team | php-coder @ altlinux.ru
next parent reply other threads:[~2007-07-03 8:39 UTC|newest] Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2007-07-03 8:39 ` Slava Semushin [this message] 2007-07-03 13:12 ` Igor Zubkov
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=75e139a00707030139m29ec91b1va1b9f61639402cef@mail.gmail.com \ --to=slava.semushin@gmail.com \ --cc=devel@lists.altlinux.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
ALT Linux Team development discussions This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \ devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru public-inbox-index devel Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.devel AGPL code for this site: git clone https://public-inbox.org/public-inbox.git