On 8/6/2013 1:46 AM, Ville Skyttä wrote:
On 2013-08-06 01:41, Paul Howarth wrote:
What I've been doing is to define a local macro:
# Move to unversioned documentation directories from F-20
# https://fedoraproject.org/wiki/Changes/UnversionedDocdirs
%global our_docdir
%{?_pkgdocdir}%{!?_pkgdocdir:%{_docdir}/%{name}-%{version}}
and then use %{our_docdir} for the documentation path wherever needed.
That's one approach. Another one is to use %{_pkgdocdir} directly and
conditionally redefine it where it's not available, see
https://fedoraproject.org/wiki/Changes/UnversionedDocdirs#Detailed_Description
The benefit of doing it this way in my opinion is that sometime in the
future when the redefinition is no longer needed, it can be removed just
by removing one line without leaving unnecessary things like "%global
our_docdir %{_pkgdocdir}" behind.
This is the approach I wanted to take, except by using the
%{_docdir_fmt} macro instead of the %{_pkgdocdir} macro. In that case,
though, %{_docdir_fmt} evaluates to %{NAME}, not %{name} as I would have
expected. As a result, I ended up with "%{NAME}" being used for the
filepath everywhere instead of the package name.
-Greg
--
packaging mailing list
packaging@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/packaging
--
packaging mailing list
packaging@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/packaging