代码拉取完成,页面将自动刷新
%define doc_pdf 1
Name: gi-docgen
Version: 2024.1
Release: 1%{?dist}
Summary: Documentation tool for GObject-based libraries
License: %{shrink:
(Apache-2.0 OR GPL-3.0-or-later) AND
BSD-2-Clause AND
MIT AND
CC0-1.0
}
URL: https://gitlab.gnome.org/GNOME/gi-docgen
Source0: %{url}/-/archive/%{version}/gi-docgen-%{version}.tar.bz2
Patch: gi-docgen-2022.2-no-web-fonts.patch
BuildArch: noarch
BuildRequires: python3-devel
BuildRequires: python3dist(pytest)
%if %{with doc_pdf}
BuildRequires: make
BuildRequires: python3dist(sphinx)
BuildRequires: python3dist(sphinx-rtd-theme)
BuildRequires: python3-sphinx-latex
BuildRequires: latexmk
%endif
BuildRequires: font(redhatdisplay)
BuildRequires: font(redhatdisplayblack)
BuildRequires: font(redhatdisplaymedium)
BuildRequires: font(redhattext)
BuildRequires: font(redhattextmedium)
BuildRequires: font(sourcecodepro)
BuildRequires: font(sourcecodeprosemibold)
Requires: gi-docgen-fonts = %{version}-%{release}
Provides: bundled(js-fzy)
%description
GI-DocGen is a document generator for GObject-based libraries. GObject is the
base type system of the GNOME project. GI-Docgen reuses the introspection data
generated by GObject-based libraries to generate the API reference of these
libraries, as well as other ancillary documentation.
GI-DocGen is not a general purpose documentation tool for C libraries.
While GI-DocGen can be used to generate API references for most GObject/C
libraries that expose introspection data, its main goal is to generate the
reference for GTK and its immediate dependencies. Any and all attempts at
making this tool more generic, or to cover more use cases, will be weighted
heavily against its primary goal.
GI-DocGen is still in development. The recommended use of GI-DocGen is to add
it as a sub-project to your Meson build system, and vendor it when releasing
dist archives.
You should not depend on a system-wide installation until GI-DocGen is declared
stable.
%package fonts
Summary: Metapackage providing fonts for gi-docgen output
License: Apache-2.0 OR GPL-3.0-or-later
Requires: font(redhatdisplay)
Requires: font(redhatdisplayblack)
Requires: font(redhatdisplaymedium)
Requires: font(redhattext)
Requires: font(redhattextmedium)
Requires: font(sourcecodepro)
Requires: font(sourcecodeprosemibold)
%description fonts
Because web fonts from upstream are not bundled in the gi-docgen package,
documentation packages generated with gi-docgen must depend on this metapackage
to ensure the proper system fonts are present.
%package doc
Summary: Documentation for gi-docgen
License: (Apache-2.0 OR GPL-3.0-or-later) AND CC0-1.0
%description doc
Documentation for gi-docgen.
%generate_buildrequires
%pyproject_buildrequires
%prep
%autosetup -p1
find . -type f \( -name '*.woff' -o -name '*.woff2' \) -print -delete
%build
%pyproject_wheel
%if %{with doc_pdf}
sphinx-build -b latex -j%{?_smp_build_ncpus} docs %{_vpath_builddir}/_latex
%make_build -C %{_vpath_builddir}/_latex LATEXMKOPTS='-quiet'
%endif
%install
%pyproject_install
%pyproject_save_files gidocgen
install -t '%{buildroot}%{_pkgdocdir}' -D -m 0644 -p \
CHANGES.md \
CONTRIBUTING.md \
docs/CODEOWNERS
%if %{with doc_pdf}
install -t '%{buildroot}%{_pkgdocdir}' -p -m 0644 \
'%{_vpath_builddir}/_latex/gi-docgen.pdf'
%endif
cp -rp examples '%{buildroot}%{_pkgdocdir}/'
%check
%pytest
%files -f %{pyproject_files}
%license LICENSES/ .reuse/dep5
%{_bindir}/gi-docgen
%{_mandir}/man1/gi-docgen.1*
%{_datadir}/pkgconfig/gi-docgen.pc
%files fonts
%files doc
%license LICENSES/ .reuse/dep5
%doc %{_pkgdocdir}/
%changelog
* Mon Apr 15 2024 OpenCloudOS Release Engineering <releng@opencloudos.tech> - 2024.1-1
- initial build
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。