From patchwork Wed Sep 18 23:33:19 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ben Pfaff X-Patchwork-Id: 1164308 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=openvswitch.org (client-ip=140.211.169.12; helo=mail.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=ovn.org Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 46Yg5f6Q1wz9s7T for ; Thu, 19 Sep 2019 11:59:50 +1000 (AEST) Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 8C407103E; Thu, 19 Sep 2019 01:58:09 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id 425121036 for ; Thu, 19 Sep 2019 01:58:08 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from relay8-d.mail.gandi.net (relay8-d.mail.gandi.net [217.70.183.201]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id A993581A for ; Thu, 19 Sep 2019 01:58:07 +0000 (UTC) X-Originating-IP: 75.54.222.30 Received: from sigfpe.attlocal.net (75-54-222-30.lightspeed.rdcyca.sbcglobal.net [75.54.222.30]) (Authenticated sender: blp@ovn.org) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id 1E81F1BF203; Thu, 19 Sep 2019 01:57:57 +0000 (UTC) From: Ben Pfaff To: dev@openvswitch.org Date: Wed, 18 Sep 2019 16:33:19 -0700 Message-Id: <20190918233322.24305-4-blp@ovn.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190918233322.24305-1-blp@ovn.org> References: <20190918233322.24305-1-blp@ovn.org> MIME-Version: 1.0 X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Cc: Ben Pfaff Subject: [ovs-dev] [PATCH v2 python3 3/6] Documentation: Work with sphinx-build for Python 3 also. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: ovs-dev-bounces@openvswitch.org Errors-To: ovs-dev-bounces@openvswitch.org There's nothing in OVS specific to Sphinx for Python 2, but the compile-time check only looked for a binary named "sphinx-build", which is typically provided only for Python 2. With Python 3, the binary is typically called "sphinx-build-3". With this commit, either name is accepted. Signed-off-by: Ben Pfaff --- Documentation/automake.mk | 1 - m4/openvswitch.m4 | 13 ++++--------- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/Documentation/automake.mk b/Documentation/automake.mk index cd68f3b1571e..e1384851d330 100644 --- a/Documentation/automake.mk +++ b/Documentation/automake.mk @@ -115,7 +115,6 @@ EXTRA_DIST += $(DOC_SOURCE) # You can set these variables from the command line. SPHINXOPTS = -SPHINXBUILD = sphinx-build SPHINXSRCDIR = $(srcdir)/Documentation SPHINXBUILDDIR = $(builddir)/Documentation/_build diff --git a/m4/openvswitch.m4 b/m4/openvswitch.m4 index cd6b51d86c16..4379d16b4203 100644 --- a/m4/openvswitch.m4 +++ b/m4/openvswitch.m4 @@ -474,15 +474,10 @@ AC_DEFUN([OVS_CHECK_FLAKE8], dnl Checks for sphinx. AC_DEFUN([OVS_CHECK_SPHINX], - [AC_CACHE_CHECK( - [for sphinx], - [ovs_cv_sphinx], - [if type sphinx-build >/dev/null 2>&1; then - ovs_cv_sphinx=yes - else - ovs_cv_sphinx=no - fi]) - AM_CONDITIONAL([HAVE_SPHINX], [test "$ovs_cv_sphinx" = yes])]) + [AC_CHECK_PROGS( + [SPHINXBUILD], [sphinx-build-3 sphinx-build-2 sphinx-build], [none]) + AC_ARG_VAR([SPHINXBUILD]) + AM_CONDITIONAL([HAVE_SPHINX], [test "$ac_cv_prog_SPHINXBUILD" != none])]) dnl Checks for dot. AC_DEFUN([OVS_CHECK_DOT],