From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: [PATCH] packages: Add zip archive support to 'patch-and-repack'. Date: Tue, 24 Mar 2015 21:50:19 +0100 Message-ID: <87iodq15o4.fsf@gnu.org> References: <1427212612-24293-1-git-send-email-bavier@member.fsf.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37129) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YaVmQ-0001Qm-7f for guix-devel@gnu.org; Tue, 24 Mar 2015 16:50:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YaVmN-0007lq-0p for guix-devel@gnu.org; Tue, 24 Mar 2015 16:50:30 -0400 In-Reply-To: <1427212612-24293-1-git-send-email-bavier@member.fsf.org> (Eric Bavier's message of "Tue, 24 Mar 2015 10:56:52 -0500") 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: Eric Bavier Cc: guix-devel@gnu.org Eric Bavier skribis: > * guix/packages.scm (%standard-patch-inputs): Add "unzip". > (patch-and-repack)[decompression-type]: Detect zip archive. > [build]: Invoke "unzip" when appropriate. Please add =E2=80=9CFixes .=E2=80=9D right above= , and email 19830-close@debbugs.gnu.org with the commit id afterwards. > - (zero? (system* (string-append #$tar "/bin/tar") > - "xvf" #$source))) > + #$@(if (string=3D? decompression-type "unzip") > + #~((zero? (system* "unzip" #$source))) > + #~((zero? (system* (string-append #$tar "/bin/= tar") > + "xvf" #$source))))) Simply: #$(if (string=3D? decompression-type "unzip") #~(zero? (system* "unzip" #$source)) #~(zero? (system* (string-append #$tar "/bin/tar") ...))) OK to push with these changes! Thank you, Ludo=E2=80=99.