diff --git a/man-pages-6.10.tar.xz b/man-pages-6.10.tar.xz new file mode 100644 index 0000000000000000000000000000000000000000..3a82af3ab244256a039f73b9f1658d582db9acd8 Binary files /dev/null and b/man-pages-6.10.tar.xz differ diff --git a/man-pages-6.9.1.tar.gz b/man-pages-6.9.1.tar.gz deleted file mode 100644 index e9ae377c141e6a961314748a10be9982e9d6caae..0000000000000000000000000000000000000000 Binary files a/man-pages-6.9.1.tar.gz and /dev/null differ diff --git a/man-pages.spec b/man-pages.spec index 1fe473f45f111441a975f037ad15420d060e076a..15fd70910c3cd573b7f66b98f20f217ba4a03d60 100644 --- a/man-pages.spec +++ b/man-pages.spec @@ -1,17 +1,19 @@ Name: man-pages -Version: 6.9.1 -Release: 3 +Version: 6.10 +Release: 1 Summary: Linux kernel and user-space C library interfaces documentation License: GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND BSD-2-Clause AND BSD-3-Clause AND BSD-4-Clause-UC AND LGPL-3.0-or-later AND LGPL-3.0-only AND LGPL-3.0-linking-exception AND MIT AND Spencer-94 -URL: http://www.kernel.org/doc/man-pages/ -Source0: https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git/snapshot/%{name}-%{version}.tar.gz -BuildRequires: gcc git make +URL: https://www.kernel.org/doc/man-pages/ +Source0: https://mirrors.edge.kernel.org/pub/linux/docs/man-pages/%{name}-%{version}.tar.xz +BuildRequires: make BuildArch: noarch +Requires(post): %{_sbindir}/update-alternatives +Requires(postun): %{_sbindir}/update-alternatives +Requires(preun): %{_sbindir}/update-alternatives Conflicts: attr < 2.4.47-11 Conflicts: keyutils-libs < 1.5.10 - -Autoreq: no +Obsoletes: %{name}-help < 6.10 %description The Linux man-pages project documents the Linux kernel and C library interface that @@ -19,40 +21,59 @@ are employed by user-space programs.With respect to the C library, the primary f the GNU C library (glibc), although, where known, documentation of variations on other C libraries available for Linux is also included. -%package_help - %prep %autosetup -p1 -sed -i 's/prefix := \/usr\/local/prefix := \/usr/g' ./share/mk/configure/directory_variables/install.mk - -%build %install -make install DESTDIR=%{buildroot} +%make_install prefix=%{_prefix} +rm -f %{buildroot}%{_mandir}/man3/crypt_r.3* +rm -f %{buildroot}%{_mandir}/man3/crypt.3* +rm -f %{buildroot}%{_mandir}/man7/bpf-helpers.7* +rm -f %{buildroot}%{_mandir}/man3/MAX.3* +rm -f %{buildroot}%{_mandir}/man3/MIN.3* -%check +# rename files for alternative usage +mv %{buildroot}%{_mandir}/man7/man.7 %{buildroot}%{_mandir}/man7/man.%{name}.7 +touch %{buildroot}%{_mandir}/man7/man.7 -%pre +%files +%doc README Changes +%{_bindir}/diffman-git +%{_bindir}/mansect +%{_bindir}/pdfman +%{_bindir}/sortman +%ghost %{_mandir}/man7/man.7* +%{_mandir}/man*/* -%preun +%pre +# remove alternativized files if they are not symlinks +[ -L %{_mandir}/man7/man.7.gz ] || rm -f %{_mandir}/man7/man.7.gz >/dev/null 2>&1 || : %post +# set up the alternatives files +%{_sbindir}/update-alternatives --install %{_mandir}/man7/man.7.gz man.7.gz %{_mandir}/man7/man.%{name}.7.gz 300 \ + >/dev/null 2>&1 || : -%postun - -%files -%defattr(-,root,root) -%doc README Changes +%preun +if [ $1 -eq 0 ]; then + %{_sbindir}/update-alternatives --remove man.7.gz %{_mandir}/man7/man.%{name}.7.gz >/dev/null 2>&1 || : +fi -%files help -%{_mandir}/man*/* -%exclude %{_mandir}/man3/crypt_r.3.gz -%exclude %{_mandir}/man3/crypt.3.gz -%exclude %{_mandir}/man7/bpf-helpers.7.gz -%exclude %{_mandir}/man3/MAX.3.gz -%exclude %{_mandir}/man3/MIN.3.gz +%postun +if [ $1 -ge 1 ]; then + if [ "$(readlink %{_sysconfdir}/alternatives/man.7.gz)" == "%{_mandir}/man7/man.%{name}.7.gz" ]; then + %{_sbindir}/update-alternatives --set man.7.gz %{_mandir}/man7/man.%{name}.7.gz >/dev/null 2>&1 || : + fi +fi %changelog +* Thu Jan 23 2025 Funda Wang - 6.10-1 +- update to 6.10 +- no need to separated individual help package, as this package itself + named the content +- convert /usr/share/man7/man.7 into alternatives, because mandoc + also provides this file + * Tue Aug 13 2024 fuanan - 6.9.1-3 - License compliance rectification