File libvorbis-doc.spec of Package libvorbis.7657

# spec file for package libvorbis-doc
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

%if 0%{?suse_version} > 1320
%define build_docs 1
%define build_docs 0

Name:           libvorbis-doc
Version:        1.3.6
Release:        0
Summary:        Documentation of Ogg/Vorbis library
License:        BSD-3-Clause
Group:          Documentation/Other
Patch1:         libvorbis-lib64.dif
Patch2:         libvorbis-m4.dif
Patch12:        vorbis-ocloexec.patch
BuildRequires:  fdupes
BuildRequires:  libogg-devel
BuildRequires:  libtool
BuildRequires:  pkgconfig
BuildRequires:  xz
%if %build_docs
BuildRequires:  doxygen
BuildRequires:  texlive-babel-english
BuildRequires:  texlive-latex
BuildRequires:  texlive-tex4ht
BuildRequires:  tex(a4wide.sty)
BuildRequires:  tex(capt-of.sty)
BuildRequires:  tex(csquotes.sty)
BuildRequires:  tex(enumitem.sty)
BuildRequires:  tex(fancyvrb.sty)
BuildRequires:  tex(grffile.sty)
BuildRequires:  tex(parskip.sty)
BuildRequires:  tex(ulem.sty)
BuildRequires:  tex(underscore.sty)
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch

This package contains documents for Ogg/Vorbis library, including the
API reference.

%setup -q -n libvorbis-%{version}
# %%patch5 -p1
if [ "%{_lib}" == "lib64" ]; then

autoreconf -fiv
%configure \
%if %build_docs
	--enable-docs \
	--disable-examples \
# parallel-build of docs may fail
make -C doc
# we don't build anything but docs

make -C doc DESTDIR=%{buildroot} install
mkdir -p %{buildroot}%{_docdir}
mv %{buildroot}%{_datadir}/doc/libvorbis-* %{buildroot}%{_docdir}/%{name}
# remove unneeded files
find %{buildroot}%{_docdir}/ -empty -delete
%fdupes -s %{buildroot}%{_docdir}

%doc %{_docdir}/%{name}

openSUSE Build Service is sponsored by