1 # TODO: use man cache owner?
4 %bcond_without tests # "make check" call
6 Summary: Tools for searching and reading man pages
7 Summary(pl.UTF-8): Narzędzia do przeszukiwania i czytania stron podręcznika man
11 # project man-db GPLv2+
13 License: GPL v2+ and GPL v3+
15 Source0: http://download.savannah.gnu.org/releases/man-db/%{name}-%{version}.tar.xz
16 # Source0-md5: 4c8721faa54a4c950c640e5e5c713fb0
17 Source1: %{name}.daily
18 Source2: %{name}.sysconfig
19 # Resolves: #655385 - use old format of nroff output
21 # recent nroff uses times()
22 Patch1: %{name}-sandbox.patch
23 URL: http://www.nongnu.org/man-db/
24 BuildRequires: gdbm-devel
25 BuildRequires: gettext-tools >= 0.18.3
28 BuildRequires: libpipeline-devel >= 1.5.0
29 BuildRequires: libseccomp-devel
30 BuildRequires: pkgconfig
31 BuildRequires: po4a >= 0.41
32 BuildRequires: tar >= 1:1.22
34 BuildRequires: zlib-devel
41 Requires: libpipeline >= 1.5.0
43 Provides: man-pages-reader = %{version}
47 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
49 %define pkgcachedir /var/cache/man
52 The man-db package includes five tools for browsing man-pages: man,
53 whatis, apropos, manpath and lexgrog:
54 - man preformats and displays manual pages.
55 - whatis searches the manual page names.
56 - apropos searches the manual page names and descriptions.
57 - manpath determines search path for manual pages.
58 - lexgrog directly reads header information in manual pages.
60 %description -l pl.UTF-8
61 Pakiet man-db zawiera pięć narzędzi do przeglądania stron podręcznika
62 man (nazywanych man-pages): man, whatis, apropos, manpath i lexgrog:
63 - man wstępnie formatuje i wyświetla strony podręcznika.
64 - whatis przeszukuje nazwy stron podręcznika.
65 - apropos przeszukuje nazwy stron podręcznika oraz opisy.
66 - manpath określa ścieżkę przeszukiwania dla stron podręcznika.
67 - lexgrog bezpośrednio odczytuje informacje z nagłówka stron
77 --disable-cache-owner \
79 --disable-silent-rules \
80 --with-browser=elinks \
81 --with-sections="1 1p 8 2 3 3p 4 5 6 7 9 0p n l p o 1x 2x 3x 4x 5x 6x 7x 8x" \
82 --with-systemdtmpfilesdir=%{systemdtmpfilesdir} \
83 --with-zstd=/usr/bin/zstd
86 CC="%{__cc} %{rpmcflags} %{rpmcppflags}"
88 %{?with_tests:%{__make} check}
91 rm -rf $RPM_BUILD_ROOT
93 INSTALL='install -p' \
95 DESTDIR=$RPM_BUILD_ROOT
97 # move the documentation to relevant place
98 %{__mv} $RPM_BUILD_ROOT%{_docdir}/man-db/* ./
100 # remove libtool archives
101 %{__rm} $RPM_BUILD_ROOT%{_libdir}/man-db/*.la
103 # install cache directory
104 install -d $RPM_BUILD_ROOT%{pkgcachedir}
106 # install cron script for man-db creation/update
107 install -D -p %{SOURCE1} $RPM_BUILD_ROOT/etc/cron.daily/man-db.cron
109 # config for cron script
110 install -D -p %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/man-db
112 cat <<EOF > $RPM_BUILD_ROOT%{systemdtmpfilesdir}/man-db.conf
113 d %{pkgcachedir} 2755 root root 1w
117 %find_lang %{name}-gnulib
118 cat %{name}-gnulib.lang >> %{name}.lang
121 rm -rf $RPM_BUILD_ROOT
123 %files -f %{name}.lang
124 %defattr(644,root,root,755)
125 %doc README man-db-manual.txt man-db-manual.ps docs/COPYING ChangeLog NEWS
126 %config(noreplace) %{_sysconfdir}/man_db.conf
127 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/man-db
128 %attr(750,root,root) /etc/cron.daily/man-db.cron
129 %attr(755,root,root) %{_sbindir}/accessdb
130 %attr(755,root,root) %{_bindir}/apropos
131 %attr(755,root,root) %{_bindir}/catman
132 %attr(755,root,root) %{_bindir}/lexgrog
133 %attr(755,root,root) %{_bindir}/man
134 %attr(755,root,root) %{_bindir}/man-recode
135 %attr(755,root,root) %{_bindir}/mandb
136 %attr(755,root,root) %{_bindir}/manpath
137 %attr(755,root,root) %{_bindir}/whatis
138 %dir %{_libdir}/man-db
139 %attr(755,root,root) %{_libdir}/man-db/*.so
140 %if "%{_libexecdir}" != "%{_libdir}"
141 %dir %{_libexecdir}/man-db
143 %attr(755,root,root) %{_libexecdir}/man-db/zsoelim
144 %{_libexecdir}/man-db/globbing
145 %{_libexecdir}/man-db/manconv
146 %{systemdunitdir}/man-db.service
147 # TODO: as cron.daily replacement
148 #%{systemdunitdir}/man-db.timer
149 %{systemdtmpfilesdir}/man-db.conf
151 # documentation and translation
152 %{_mandir}/man1/apropos.1*
153 %{_mandir}/man1/lexgrog.1*
154 %{_mandir}/man1/man.1*
155 %{_mandir}/man1/man-recode.1*
156 %{_mandir}/man1/manconv.1*
157 %{_mandir}/man1/manpath.1*
158 %{_mandir}/man1/whatis.1*
159 %{_mandir}/man1/zsoelim.1*
160 %{_mandir}/man5/manpath.5*
161 %{_mandir}/man8/accessdb.8*
162 %{_mandir}/man8/catman.8*
163 %{_mandir}/man8/mandb.8*
164 %lang(da) %{_mandir}/da/man*/*
165 %lang(de) %{_mandir}/de/man*/*
166 %lang(es) %{_mandir}/es/man*/*
167 %lang(fr) %{_mandir}/fr/man*/*
168 %lang(id) %{_mandir}/id/man*/*
169 %lang(it) %{_mandir}/it/man*/*
170 %lang(ja) %{_mandir}/ja/man*/*
171 %lang(nl) %{_mandir}/nl/man*/*
172 %lang(pl) %{_mandir}/pl/man*/*
173 %lang(pt) %{_mandir}/pt/man*/*
174 %lang(pt_BR) %{_mandir}/pt_BR/man*/*
175 %lang(ru) %{_mandir}/ru/man*/*
176 %lang(sr) %{_mandir}/sr/man*/*
177 %lang(sv) %{_mandir}/sv/man*/*
178 %lang(tr) %{_mandir}/tr/man*/*
179 %lang(zh_CN) %{_mandir}/zh_CN/man*/*