Use _pkgdocdir and add backward-compatibility

Create HTML directory for cases (like EL6) where groff is not UTF-8 capable
so we don't build the docs anyway.
f38
David Woodhouse 9 years ago
parent 9dcb7d4f0d
commit d5fd5f3199

@ -19,6 +19,8 @@
%define use_tokens 1 %define use_tokens 1
%endif %endif
%{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}}
Name: openconnect Name: openconnect
Version: 7.07 Version: 7.07
Release: 1%{?relsuffix}%{?dist} Release: 1%{?relsuffix}%{?dist}
@ -88,13 +90,14 @@ gpgv2 --keyring %{SOURCE2} %{SOURCE1} %{SOURCE0}
%if !%{use_gnutls} %if !%{use_gnutls}
--with-openssl --without-openssl-version-check \ --with-openssl --without-openssl-version-check \
%endif %endif
--htmldir=%{_docdir}/%{name} --htmldir=%{_pkgdocdir}
make %{?_smp_mflags} V=1 make %{?_smp_mflags} V=1
%install %install
rm -rf $RPM_BUILD_ROOT rm -rf $RPM_BUILD_ROOT
%make_install %make_install
mkdir -p $RPM_BUILD_ROOT/%{_pkgdocdir}
rm -f $RPM_BUILD_ROOT/%{_libdir}/libopenconnect.la rm -f $RPM_BUILD_ROOT/%{_libdir}/libopenconnect.la
%find_lang %{name} %find_lang %{name}
@ -114,7 +117,7 @@ rm -rf $RPM_BUILD_ROOT
%{_sbindir}/openconnect %{_sbindir}/openconnect
%{_mandir}/man8/* %{_mandir}/man8/*
%doc TODO COPYING.LGPL %doc TODO COPYING.LGPL
%doc %{_docdir}/%{name} %doc %{_pkgdocdir}
%files devel %files devel
%defattr(-,root,root,-) %defattr(-,root,root,-)

Loading…
Cancel
Save