rpms/flumotion/devel flumotion.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Michael Schwendt bugs.michael at gmx.net
Mon Apr 25 14:40:31 UTC 2005


On Thu, 21 Apr 2005 19:00:32 +0200, Ralf Corsepius wrote:

> On Thu, 2005-04-21 at 12:40 -0400, Thomas Vander Stichele wrote:
> 
> > Requires(post):	openssl
> 
> > %post
> > /sbin/chkconfig --add flumotion
> > # generate a default .pem certificate ?
> > PEM_FILE="%{_sysconfdir}/flumotion/default.pem"
> > if ! test -e ${PEM_FILE}
> > then
> >   sh %{_datadir}/ssl/certs/make-dummy-cert ${PEM_FILE}
> 
> This is not quite correct.
> 
> %{_datadir} is a property of this package, this scriptlet however is
> expecting /usr/share/ssl/certs/make-dummy-cert (A property currently
> being provided by openssl)
> 
> 
> Therefore I'd recommend you to change
> 
> Requires(post): openssl
> into
> Requires(post): /usr/share/ssl/certs/make-dummy-cert
> 
> and to use
> /usr/share/ssl/certs/make-dummy-cert instead of 
> %{_datadir}/ssl/certs/make-dummy-cert
> 
> This might seem negligible to you, but it makes a substantial difference
> should the location of make-dummy-cert change, or openssl be replaced by
> another package.

Skimming over the FC-3 openssl.spec, it installs the file as

  %{_datadir}/ssl/certs/make-dummy-cert

and includes it in the %files section as:

  %{_datadir}/ssl/certs

Hence "Requires: %{_datadir}/ssl/certs/make-dummy-cert" looks correct.
If both packages are rebuilt with a different %_datadir, they would
still work.

That's how package dependencies work in a given context. You don't just
depend on the expanded path /usr/share/ssl/certs/make-dummy-cert, because
the openssl package doesn't hardcode that path. It uses %_datadir, and as long
as it does that, staying in sync with it is added value.




More information about the fedora-extras-commits mailing list