From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: Re: [PATCH] gnu: Add bowtie. Date: Thu, 18 Dec 2014 17:15:48 +0100 Message-ID: References: <87bnn2huun.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:57229) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y1dkB-0002Tz-RG for guix-devel@gnu.org; Thu, 18 Dec 2014 11:16:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Y1dk6-0005zu-5I for guix-devel@gnu.org; Thu, 18 Dec 2014 11:16:03 -0500 In-Reply-To: <87bnn2huun.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: Ludovic =?utf-8?Q?Court=C3=A8s?= Cc: guix-devel --=-=-= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable >> + 'patch-makefile >> + (lambda _ >> + (substitute* "Makefile" >> + (("^CC =3D .*$") (string-append "CC =3D " (which "gcc"))) >> + (("^CPP =3D .*$") (string-append "CPP =3D " (which "g++")= )) >> + ;; replace BUILD_HOST and BUILD_TIME for deterministic bu= ild >> + (("-DBUILD_HOST=3D.*") "-DBUILD_HOST=3D\"\\\"guix\\\"\"") >> + (("-DBUILD_TIME=3D.*") "-DBUILD_TIME=3D\"\\\"0\\\"\""))) > > Could you make this a =E2=80=98snippet=E2=80=99? It suffices to write = =E2=80=9CCC =3D gcc=E2=80=9D and > =E2=80=9CCPP =3D g++=E2=80=9D. That way, running =E2=80=98guix build -= S bowtie=E2=80=99 will return > source that=E2=80=99s closer to what we=E2=80=99re using. Okay. >> + (license license:gpl3))) > > From a quick glance, this should be =E2=80=98gpl3+=E2=80=99 (source fil= e headers carry > the =E2=80=9Cor any later version=E2=80=9D phrase.) I went by the NEWS and MANUAL files that say "Bowtie 2 is licensed under the GPLv3 license." and "Bowtie 2 is distributed under the [GPLv3 license]" but I have updated the package recipe to use `gpl3+' as the source file headers do indeed carry the phrase "or any later version". > Could you post an updated patch? Please see the attached patch. Thanks for the review! Ricardo PS: This depends on the Perl module "Clone" for which I sent a patch previously. Although you said it was applied I haven't yet seen it in the git repository. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename="0001-gnu-Add-bowtie.patch" >From 96f31057ba6bb17c1801f87d4bbae70dd3539576 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 16 Dec 2014 17:52:44 +0100 Subject: [PATCH] gnu: Add bowtie * gnu/packages/bioinformatics.scm (bowtie): New variable. --- gnu/packages/bioinformatics.scm | 58 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index a2846f1..ff6c337 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -77,6 +77,64 @@ intervals from multiple files in widely-used genomic file formats such as BAM, BED, GFF/GTF, VCF.") (license license:gpl2))) +(define-public bowtie + (package + (name "bowtie") + (version "2.2.4") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/BenLangmead/bowtie2/archive/v" + version ".tar.gz")) + (sha256 + (base32 + "15dnbqippwvhyh9zqjhaxkabk7lm1xbh1nvar1x4b5kwm117zijn")) + (modules '((guix build utils))) + (snippet + '(substitute* "Makefile" + (("^CC = .*$") "CC = gcc") + (("^CPP = .*$") "CPP = g++") + ;; replace BUILD_HOST and BUILD_TIME for deterministic build + (("-DBUILD_HOST=.*") "-DBUILD_HOST=\"\\\"guix\\\"\"") + (("-DBUILD_TIME=.*") "-DBUILD_TIME=\"\\\"0\\\"\""))))) + (build-system gnu-build-system) + (inputs `(("perl" ,perl) + ("perl-clone" ,perl-clone) + ("perl-test-deep" ,perl-test-deep) + ("perl-test-simple" ,perl-test-simple) + ("python" ,python-2))) + (arguments + '(#:make-flags '("allall") + #:phases + (alist-delete + 'configure + (alist-replace + 'install + (lambda* (#:key outputs #:allow-other-keys) + (let ((bin (string-append (assoc-ref outputs "out") "/bin/"))) + (mkdir-p bin) + (for-each (lambda (file) + (copy-file file (string-append bin file))) + (find-files "." "bowtie2.*")))) + (alist-replace + 'check + (lambda* (#:key outputs #:allow-other-keys) + (system* "perl" + "scripts/test/simple_tests.pl" + "--bowtie2=./bowtie2" + "--bowtie2-build=./bowtie2-build")) + %standard-phases))))) + (home-page "http://bowtie-bio.sourceforge.net/bowtie2/index.shtml") + (synopsis "Fast and sensitive nucleotide sequence read aligner") + (description + "Bowtie 2 is a fast and memory-efficient tool for aligning sequencing +reads to long reference sequences. It is particularly good at aligning reads +of about 50 up to 100s or 1,000s of characters, and particularly good at +aligning to relatively long (e.g. mammalian) genomes. Bowtie 2 indexes the +genome with an FM Index to keep its memory footprint small: for the human +genome, its memory footprint is typically around 3.2 GB. Bowtie 2 supports +gapped, local, and paired-end alignment modes.") + (license license:gpl3+))) + (define-public samtools (package (name "samtools") -- 1.9.3 --=-=-=--