Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gf0yG-0006T5-HT for pgsql-hackers@arkaria.postgresql.org; Thu, 03 Jan 2019 11:15:28 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gf0yE-0008Ff-Sd for pgsql-hackers@arkaria.postgresql.org; Thu, 03 Jan 2019 11:15:26 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gf0yE-0008FY-LL for pgsql-hackers@lists.postgresql.org; Thu, 03 Jan 2019 11:15:26 +0000 Received: from ssl.nataraj.su ([195.54.209.170]) by magus.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gf0y8-0000O6-AI for pgsql-hackers@lists.postgresql.org; Thu, 03 Jan 2019 11:15:26 +0000 Received: from x200m.localnet (unknown [91.108.35.130]) by ssl.nataraj.su (Postfix) with ESMTPSA id 639BD511E165; Thu, 3 Jan 2019 14:15:18 +0300 (MSK) From: Nikolay Shaplov To: pgsql-hackers@lists.postgresql.org Cc: Michael Paquier , Tom Lane , Peter Eisentraut Subject: Re: [PATCH] check for ctags utility in make_ctags Date: Thu, 03 Jan 2019 14:15:11 +0300 Message-ID: <2205856.meAnofT0VS@x200m> User-Agent: KMail/5.2.3 (Linux/4.9.0-8-amd64; KDE/5.28.0; x86_64; ; ) In-Reply-To: <20190103010353.GA1442@paquier.xyz> References: <2394207.ccz7JgCJsh@x200m> <4273.1546446946@sss.pgh.pa.us> <20190103010353.GA1442@paquier.xyz> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="nextPart1582210.yV0LUW7Zhe" Content-Transfer-Encoding: 7Bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk This is a multi-part message in MIME format. --nextPart1582210.yV0LUW7Zhe Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" =D0=92 =D0=BF=D0=B8=D1=81=D1=8C=D0=BC=D0=B5 =D0=BE=D1=82 =D1=87=D0=B5=D1=82= =D0=B2=D0=B5=D1=80=D0=B3, 3 =D1=8F=D0=BD=D0=B2=D0=B0=D1=80=D1=8F 2019 =D0= =B3. 10:03:53 MSK =D0=BF=D0=BE=D0=BB=D1=8C=D0=B7=D0=BE=D0=B2=D0=B0=D1=82=D0= =B5=D0=BB=D1=8C Michael=20 Paquier =D0=BD=D0=B0=D0=BF=D0=B8=D1=81=D0=B0=D0=BB: > On Wed, Jan 02, 2019 at 11:35:46AM -0500, Tom Lane wrote: > > In fact, that's demonstrably not so: on my RHEL6 and Fedora boxes, > > /usr/bin/etags isn't owned by any package, because it's a symlink > > managed by the "alternatives" system. It points to /usr/bin/etags.emacs > > which is owned by the emacs-common package. So dropping the advice > > about how to fix the problem seems like a good plan. >=20 > +1, let's keep it simple. I would just use "ctags/etags not found" > as error message. Actually I was trying to say "Please install 'ctags' [utility] to run=20 make_ctags". But if all of you read it as "Please install 'ctags' [package]= to=20 run make_ctags", then it is really better to drop the advice. So I removed it. See the patch. --nextPart1582210.yV0LUW7Zhe Content-Disposition: attachment; filename="check-for-ctags-in-make_ctags_v4.diff" Content-Transfer-Encoding: 7Bit Content-Type: text/x-patch; charset="UTF-8"; name="check-for-ctags-in-make_ctags_v4.diff" diff --git a/src/tools/make_ctags b/src/tools/make_ctags index 1609c07..0834468 100755 --- a/src/tools/make_ctags +++ b/src/tools/make_ctags @@ -2,6 +2,12 @@ # src/tools/make_ctags +if [ ! $(command -v ctags) ] +then + echo "'ctags' utility is not found" 1>&2 + exit 1 +fi + trap "rm -f /tmp/$$" 0 1 2 3 15 rm -f ./tags diff --git a/src/tools/make_etags b/src/tools/make_etags index 3ce96bc..cb44aed 100755 --- a/src/tools/make_etags +++ b/src/tools/make_etags @@ -2,6 +2,12 @@ # src/tools/make_etags +if [ ! $(command -v etags) ] +then + echo "'etags' utility is not found" 1>&2 + exit 1 +fi + rm -f ./TAGS find `pwd`/ -type f -name '*.[chyl]' -print | --nextPart1582210.yV0LUW7Zhe--