From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: Re: [PATCH] gnu: bind-utils: Build and install =?utf-8?B?4oCcbnN1?= =?utf-8?B?cGRhdGXigJ0u?= Date: Thu, 21 Jan 2016 11:52:18 +0100 Message-ID: References: <8760yxt2by.fsf@gnu.org> <87lh7stu35.fsf@gmail.com> <87mvs7912x.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48222) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMCqt-0004Ng-UO for guix-devel@gnu.org; Thu, 21 Jan 2016 05:52:33 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aMCqp-0008Et-Su for guix-devel@gnu.org; Thu, 21 Jan 2016 05:52:31 -0500 In-Reply-To: <87mvs7912x.fsf@gnu.org> 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-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Mathieu Lirzin Cc: Guix-devel , Alex Kost --=-=-= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Mathieu Lirzin writes: > Ricardo Wurmus writes: > >> I agree, this looks nicer. Would you like to push this change? There >> isn=E2=80=99t much left of my original patch ;) > > IIUC the main feature of this patch is adding the =E2=80=9Cnsupdate=E2=80= =9D thing > (which should be described in the commit log by the way). So I think > this patch is still yours. :) Okay. Attached are three new patches. I thought I should better split this up into separate commits for clarity. How=E2=80=99s this? --=-=-= Content-Type: text/x-patch; charset="utf-8" Content-Disposition: inline; filename="0001-gnu-bind-utils-Use-modify-phases-syntax.patch" Content-Transfer-Encoding: quoted-printable >From b276ca4c3940663137e4449144b2256f03e47d27 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 21 Jan 2016 11:20:30 +0100 Subject: [PATCH 1/3] gnu: bind-utils: Use "modify-phases" syntax. * gnu/packages/dns.scm (bind-utils): Use "modify-phases" syntax. --- gnu/packages/dns.scm | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/gnu/packages/dns.scm b/gnu/packages/dns.scm index c83d16a..f7d6c88 100644 --- a/gnu/packages/dns.scm +++ b/gnu/packages/dns.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright =C2=A9 2015 Taylan Ulrich Bay=C4=B1rl=C4=B1/Kammer ;;; Copyright =C2=A9 2016 Mark H Weaver +;;; Copyright =C2=A9 2016 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. ;;; @@ -91,19 +92,17 @@ and BOOTP/TFTP for network booting of diskless machin= es.") (string-append "--with-pkcs11=3D" (assoc-ref %build-inputs "p11-kit"))) #:phases - (alist-replace - 'build - (lambda _ - (and (zero? (system* "make" "-C" "lib/dns")) - (zero? (system* "make" "-C" "lib/isc")) - (zero? (system* "make" "-C" "lib/bind9")) - (zero? (system* "make" "-C" "lib/isccfg")) - (zero? (system* "make" "-C" "lib/lwres")) - (zero? (system* "make" "-C" "bin/dig")))) - (alist-replace - 'install - (lambda _ (zero? (system* "make" "-C" "bin/dig" "install"))) - %standard-phases)))) + (modify-phases %standard-phases + (replace 'build + (lambda _ + (and (zero? (system* "make" "-C" "lib/dns")) + (zero? (system* "make" "-C" "lib/isc")) + (zero? (system* "make" "-C" "lib/bind9")) + (zero? (system* "make" "-C" "lib/isccfg")) + (zero? (system* "make" "-C" "lib/lwres")) + (zero? (system* "make" "-C" "bin/dig"))))) + (replace 'install + (lambda _ (zero? (system* "make" "-C" "bin/dig" "install"))))= ))) (home-page "https://www.isc.org/downloads/bind/") (synopsis "Tools for querying nameservers") (description --=20 2.1.0 --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename="0002-gnu-bind-utils-Generalize-build-and-install-phases.patch" >From 4c7f432edbd65abad749170a280d88181f533635 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 21 Jan 2016 11:41:10 +0100 Subject: [PATCH 2/3] gnu: bind-utils: Generalize "build" and "install" phases. * gnu/packages/dns.scm (bind-utils)[arguments]: Generalize "build" and "install" phases. --- gnu/packages/dns.scm | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/gnu/packages/dns.scm b/gnu/packages/dns.scm index f7d6c88..dfdd1df 100644 --- a/gnu/packages/dns.scm +++ b/gnu/packages/dns.scm @@ -91,18 +91,24 @@ and BOOTP/TFTP for network booting of diskless machines.") (assoc-ref %build-inputs "mysql")) (string-append "--with-pkcs11=" (assoc-ref %build-inputs "p11-kit"))) + #:modules ((srfi srfi-1) + (srfi srfi-26) + ,@%gnu-build-system-modules) #:phases - (modify-phases %standard-phases - (replace 'build - (lambda _ - (and (zero? (system* "make" "-C" "lib/dns")) - (zero? (system* "make" "-C" "lib/isc")) - (zero? (system* "make" "-C" "lib/bind9")) - (zero? (system* "make" "-C" "lib/isccfg")) - (zero? (system* "make" "-C" "lib/lwres")) - (zero? (system* "make" "-C" "bin/dig"))))) - (replace 'install - (lambda _ (zero? (system* "make" "-C" "bin/dig" "install"))))))) + (let ((libs '("dns" "isc" "bind9" "isccfg" "lwres")) + (bins '("dig"))) + (modify-phases %standard-phases + (replace 'build + (lambda _ + (every (lambda (dir) + (zero? (system* "make" "-C" dir))) + (append (map (cut string-append "lib/" <>) libs) + (map (cut string-append "bin/" <>) bins))))) + (replace 'install + (lambda _ + (every (lambda (dir) + (zero? (system* "make" "-C" dir "install"))) + (map (cut string-append "bin/" <>) bins)))))))) (home-page "https://www.isc.org/downloads/bind/") (synopsis "Tools for querying nameservers") (description -- 2.1.0 --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename="0003-gnu-bind-utils-Build-and-install-nsupdate.patch" >From 6bd7b2a30ef1f128097c2ff4030e465e3955a34f Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 21 Jan 2016 11:42:17 +0100 Subject: [PATCH 3/3] gnu: bind-utils: Build and install "nsupdate". * gnu/packages/dns.scm (bind-utils)[arguments]: Also build and install "nsupdate" executable. --- gnu/packages/dns.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/dns.scm b/gnu/packages/dns.scm index dfdd1df..ef07f30 100644 --- a/gnu/packages/dns.scm +++ b/gnu/packages/dns.scm @@ -96,7 +96,7 @@ and BOOTP/TFTP for network booting of diskless machines.") ,@%gnu-build-system-modules) #:phases (let ((libs '("dns" "isc" "bind9" "isccfg" "lwres")) - (bins '("dig"))) + (bins '("dig" "nsupdate"))) (modify-phases %standard-phases (replace 'build (lambda _ -- 2.1.0 --=-=-=--