From mboxrd@z Thu Jan 1 00:00:00 1970 From: Leo Famulari Subject: Re: [PATCH 1/2] gnu: libtool: Use 'modify-phases'. Date: Wed, 4 Jan 2017 20:09:39 -0500 Message-ID: <20170105010939.GA30755@jasmine> References: <20170101144525.10710-1-ng0@libertad.pw> <20170101152428.27552-1-ng0@libertad.pw> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="5I6of5zJg18YgZEa" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35405) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cOwYz-0004tS-Bt for guix-devel@gnu.org; Wed, 04 Jan 2017 20:09:55 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cOwYw-0005kD-5D for guix-devel@gnu.org; Wed, 04 Jan 2017 20:09:53 -0500 Received: from out2-smtp.messagingengine.com ([66.111.4.26]:46640) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cOwYv-0005jW-Pv for guix-devel@gnu.org; Wed, 04 Jan 2017 20:09:50 -0500 Content-Disposition: inline In-Reply-To: <20170101152428.27552-1-ng0@libertad.pw> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: ng0 Cc: guix-devel@gnu.org --5I6of5zJg18YgZEa Content-Type: multipart/mixed; boundary="DocE+STaALJfprDB" Content-Disposition: inline --DocE+STaALJfprDB Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sun, Jan 01, 2017 at 03:24:27PM +0000, ng0 wrote: > * gnu/packages/autotools.scm (libtool): Use 'modify-phases'. > [arguments]: Use 'modify-phases'. > + ("help2man" ,help2man) ;because we modify ltmain.sh This should go in the other patch, right? I attached a revised patch series with that change, and another bug fix. --DocE+STaALJfprDB Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: attachment; filename="0001-gnu-libtool-Use-modify-phases.patch" Content-Transfer-Encoding: quoted-printable =46rom 7f0fce3f71be7da461de89fb5f6f47289c6498b6 Mon Sep 17 00:00:00 2001 =46rom: ng0 Date: Sun, 1 Jan 2017 15:24:27 +0000 Subject: [PATCH 1/3] gnu: libtool: Use 'modify-phases'. * gnu/packages/autotools.scm (libtool): Use 'modify-phases'. [arguments]: Use 'modify-phases'. Signed-off-by: Leo Famulari --- gnu/packages/autotools.scm | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/gnu/packages/autotools.scm b/gnu/packages/autotools.scm index 72492e70e..64a1e68bf 100644 --- a/gnu/packages/autotools.scm +++ b/gnu/packages/autotools.scm @@ -5,6 +5,7 @@ ;;; Copyright =A9 2014 Manolis Fragkiskos Ragkousis ;;; Copyright =A9 2015 Mark H Weaver ;;; Copyright =A9 2016 David Thompson +;;; Copyright =A9 2017 ng0 ;;; ;;; This file is part of GNU Guix. ;;; @@ -313,21 +314,22 @@ Makefile, simplifying the entire process for the deve= loper.") (or (%current-target-system) (%current-system)))) =20 - #:phases (alist-cons-before - 'check 'pre-check - (lambda* (#:key inputs #:allow-other-keys) - ;; Run the test suite in parallel, if possible. - (setenv "TESTSUITEFLAGS" - (string-append - "-j" - (number->string (parallel-job-count)))) + #:phases + (modify-phases %standard-phases + (add-before 'check 'pre-check + (lambda* (#:key inputs #:allow-other-keys) + ;; Run the test suite in parallel, if possible. + (setenv "TESTSUITEFLAGS" + (string-append + "-j" + (number->string (parallel-job-count)))) + + ;; Path references to /bin/sh. + (let ((bash (assoc-ref inputs "bash"))) + (substitute* "tests/testsuite" + (("/bin/sh") + (string-append bash "/bin/bash"))))))))) =20 - ;; Path references to /bin/sh. - (let ((bash (assoc-ref inputs "bash"))) - (substitute* "tests/testsuite" - (("/bin/sh") - (string-append bash "/bin/bash"))))) - %standard-phases))) (synopsis "Generic shared library support tools") (description "GNU Libtool helps in the creation and use of shared libraries, by --=20 2.11.0 --DocE+STaALJfprDB Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="0002-gnu-libtool-Restore-ltmain.sh-shebang.patch" Content-Transfer-Encoding: quoted-printable =46rom fc60e04d85ab171538333fe5aa47c2e6849b02e3 Mon Sep 17 00:00:00 2001 =46rom: ng0 Date: Sun, 1 Jan 2017 15:24:28 +0000 Subject: [PATCH 2/3] gnu: libtool: Restore ltmain.sh shebang. This fixes * gnu/packages/autotools.scm (libtool)[arguments]: Add new phase 'restore-ltmain-shebang'. [native-inputs]: Add help2man. Signed-off-by: Leo Famulari --- gnu/packages/autotools.scm | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/gnu/packages/autotools.scm b/gnu/packages/autotools.scm index 64a1e68bf..217517ade 100644 --- a/gnu/packages/autotools.scm +++ b/gnu/packages/autotools.scm @@ -27,6 +27,7 @@ #:use-module (gnu packages) #:use-module (gnu packages perl) #:use-module (gnu packages m4) + #:use-module (gnu packages man) #:use-module (gnu packages bash) #:use-module (guix utils) #:use-module (guix packages) @@ -301,6 +302,7 @@ Makefile, simplifying the entire process for the develo= per.") (propagated-inputs `(("m4" ,m4))) (native-inputs `(("m4" ,m4) ("perl" ,perl) + ("help2man" ,help2man) ;because we modify ltmain.sh ("automake" ,automake) ;some tests rely on 'aclo= cal' ("autoconf" ,(autoconf-wrapper)))) ;others on 'autom4= te' =20 @@ -328,7 +330,12 @@ Makefile, simplifying the entire process for the devel= oper.") (let ((bash (assoc-ref inputs "bash"))) (substitute* "tests/testsuite" (("/bin/sh") - (string-append bash "/bin/bash"))))))))) + (string-append bash "/bin/bash")))))) + (add-after 'patch-source-shebangs 'restore-ltmain-shebang + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "build-aux/ltmain.in" + (((string-append (assoc-ref inputs "bash") "/bin/s= h")) + "/bin/sh"))))))) =20 (synopsis "Generic shared library support tools") (description --=20 2.11.0 --DocE+STaALJfprDB Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="0003-gnu-libtool-Don-t-replace-sh-reference-with-bash.patch" Content-Transfer-Encoding: quoted-printable =46rom 809120b991603b8c557be7481be2bbae29bd8a7f Mon Sep 17 00:00:00 2001 =46rom: Leo Famulari Date: Wed, 4 Jan 2017 19:44:27 -0500 Subject: [PATCH 3/3] gnu: libtool: Don't replace 'sh' reference with 'bash'. Bash behaves differently based on how it is invoked (see Invocation in bash= (1)). * gnu/packages/autotools.scm (libtool)[arguments]: Use /bin/sh instead of /bin/bash in 'pre-check' phase. Fix typo in comment. --- gnu/packages/autotools.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/autotools.scm b/gnu/packages/autotools.scm index 217517ade..926767855 100644 --- a/gnu/packages/autotools.scm +++ b/gnu/packages/autotools.scm @@ -326,11 +326,11 @@ Makefile, simplifying the entire process for the deve= loper.") "-j" (number->string (parallel-job-count)))) =20 - ;; Path references to /bin/sh. + ;; Patch references to /bin/sh. (let ((bash (assoc-ref inputs "bash"))) (substitute* "tests/testsuite" (("/bin/sh") - (string-append bash "/bin/bash")))))) + (string-append bash "/bin/sh")))))) (add-after 'patch-source-shebangs 'restore-ltmain-shebang (lambda* (#:key inputs #:allow-other-keys) (substitute* "build-aux/ltmain.in" --=20 2.11.0 --DocE+STaALJfprDB-- --5I6of5zJg18YgZEa Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEsFFZSPHn08G5gDigJkb6MLrKfwgFAlhtnM0ACgkQJkb6MLrK fwhLTg/5AXEZRnyFzJfoe2j+vk22gcG9modZLI3TpfKHuWNEUX+9iWRlWs7BwrYU IXxaPI5F1Xh7zPiMrZbF00JL3/S/08Qe7NaNsRTgheZbxJpv+RY1EemmaSFuAS+h vBTxE8TSeWpB6EVj3h8TrJIMu1XAzOXU+1g5A/s2OcJTg14xQQ4jGTmQAX9xay2m 78is7qweSQU0z3qAiGnb6YEdOCdqoztQ6JBI41am4Vf6MkMY4sJjNWG/mX20sMhR fL+No8wYNeNFSoJKkAW54abs8xcg304lwN2pcpQgMizearjFvD26MlCL+7Fl9S80 RnM33sHrnoJRv7q57M/n6Bx6bX9f63qpB60aEiZ4cnlqjLGMwLcywYonBhClE7sm V/I28yJ1O/L3++AeUMEYFIH8bsUjhGks8vUOyIdsSLuNW7CFaukOrTj+nQ0yb0S4 eDonV7gCqwEw47LNErlPdP4Gtqy7pygEsPx1UDqF0tzeEQbIvcB1ILJnr/JSNO03 wYblvQysk54JXkiZOVI531yO15rGdnn4T3QNNFfPb52mZcpJ7+ZEXXE3STYs5b5b 5QZAHYmTna6dSWc+umkQnGce7BOP/FNTA8lnNTFbmVno+IB5/BCEvB8SaJpS57YM 6/3VqYBxtbSp2NXtUw450o6Pj5okRBF78bmbK+V0xi5dYelpDrc= =9pOD -----END PGP SIGNATURE----- --5I6of5zJg18YgZEa--