/usr/bin/rst2man is now the Python 3 version

This commit is contained in:
Miro Hrončok 2018-07-27 15:56:04 +02:00
parent 660646924a
commit 51f44321f6
2 changed files with 0 additions and 52 deletions

View File

@ -1,50 +0,0 @@
From d098b1f3ae1d4c69f34cbe4ec792d0521f35503c Mon Sep 17 00:00:00 2001
From: Alexander Bokovoy <ab@samba.org>
Date: Tue, 17 Jul 2018 08:22:23 +0300
Subject: [PATCH] configure.ac: support using both rst2man and rst2man-3
Python3 version of rst2man is called rst2man-3.
Add few more variants to cover Fedora and OpenSUSE.
Signed-off-by: Alexander Bokovoy <ab@samba.org>
---
Makefile.am | 2 +-
configure.ac | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 30658e3..f37c9ae 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -16,7 +16,7 @@ man_MANS=
SUFFIXES = .rst .1 .8
-RST2MAN = rst2man --syntax-highlight=none $< $@
+RST2MAN = $(have_rst2man) --syntax-highlight=none $< $@
.rst.1:
$(RST2MAN)
diff --git a/configure.ac b/configure.ac
index b0bc2b9..8e3d6ce 100644
--- a/configure.ac
+++ b/configure.ac
@@ -252,12 +252,12 @@ fi
# if docs are not disabled, check if rst2man is available
if test $enable_man != "no"; then
- AC_CHECK_PROG(have_rst2man, rst2man, yes, no)
+ AC_CHECK_PROGS(have_rst2man, rst2man-3.6 rst2man-3.4 rst2man-3 rst2man, no)
if test $have_rst2man = "no"; then
if test $enable_man = "yes"; then
- AC_MSG_ERROR([rst2man not found: cannot generate man pages, consider installing perl.])
+ AC_MSG_ERROR([rst2man not found: cannot generate man pages, consider installing python{2,3}-docutils.])
else
- AC_MSG_WARN([rst2man not found: cannot generate man pages, consider installing perl. Disabling man page generation.])
+ AC_MSG_WARN([rst2man not found: cannot generate man pages, consider installing python{2,3}-docutils. Disabling man page generation.])
enable_man="no"
fi
else
--
2.17.1

View File

@ -19,7 +19,6 @@ Requires(post): /usr/sbin/alternatives
Requires(preun): /usr/sbin/alternatives
Source0: https://download.samba.org/pub/linux-cifs/cifs-utils/%{name}-%{version}.tar.bz2
Patch0: cifs-utils-rst2man-3.patch
%description
The SMB/CIFS protocol is a standard file sharing protocol widely deployed
@ -54,7 +53,6 @@ provide these credentials to the kernel automatically at login.
%prep
%setup -q -n %{name}-%{version}%{pre_release}
%patch0 -p1
%build