unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Ben Woodcroft <b.woodcroft@uq.edu.au>
To: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
Cc: "guix-devel@gnu.org" <guix-devel@gnu.org>
Subject: Re: Update mafft to 7.245.
Date: Tue, 15 Dec 2015 22:05:04 +1000	[thread overview]
Message-ID: <567001F0.7060206@uq.edu.au> (raw)
In-Reply-To: <idjbn9y8ek6.fsf@bimsb-sys02.mdc-berlin.net>

[-- Attachment #1: Type: text/plain, Size: 1580 bytes --]



On 11/12/15 02:16, Ricardo Wurmus wrote:
> Ben Woodcroft <b.woodcroft@uq.edu.au> writes:
>
>> Two reviews in record time, nice.
>>
>> On 10/11/15 23:12, Efraim Flashner wrote:
>>> On Tue, 10 Nov 2015 22:18:10 +1000
>>> Ben Woodcroft <b.woodcroft@uq.edu.au> wrote:
>>>
>>>> Also had to fix the inputs. Hard not to notice these things in the
>>>> environment container - worked well thanks.
>>> Do they need to be propagated inputs? Did you try them as native-inputs?
>>> Often that's enough to take care of it.
>> The main program 'mafft' is actually a reasonably long shell script,
>> which itself calls awk, grep, perl, etc. collectively many times (>100 I
>> would guess). I think it is intended to be run where these programs are
>> available. I could do as Ricardo suggests and run substitute* but this
>> seems a bit error-prone and not very future-proof to me, especially when
>> the shell script is difficult to exhaustively test. WDYT?
> I looked at the instances of “perl”, “awk”, and “grep” and they seem
> manageable.  I didn’t test this but attached is a different version of
> your patch that does what I suggested.  It might work.  Could you try to
> confirm that it’s okay?
>
> What do you think?
I think you are quite valiant. As I say, I cannot be confident in my 
testing (even those in the readme). The diff looked mostly fine by eye, 
but there was some issues near the end which mangled things somewhat 
(although maybe not the result, not sure). How's the attached? I upped 
version too. OK?

Thanks,
ben

[-- Attachment #2: 0001-PATCH-gnu-mafft-Update-to-7.267.patch --]
[-- Type: text/x-patch, Size: 3166 bytes --]

From e256089eadca19e31fa986d2ce7c13f7fbc3311b Mon Sep 17 00:00:00 2001
From: Ben Woodcroft <donttrustben@gmail.com>
Date: Tue, 15 Dec 2015 20:34:52 +1000
Subject: [PATCH] [PATCH] gnu: mafft: Update to 7.267.

* gnu/packages/bioinformatics.scm (mafft): Update to 7.267.
[arguments]: Don't include mafft-homologs manpage.
[inputs]: Add gawk and grep.
[propagated-inputs]: Add coreutils.
---
 gnu/packages/bioinformatics.scm | 23 ++++++++++++++++++++---
 1 file changed, 20 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 7c573e1..21b85db 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -40,6 +40,7 @@
   #:use-module (gnu packages compression)
   #:use-module (gnu packages cpio)
   #:use-module (gnu packages file)
+  #:use-module (gnu packages gawk)
   #:use-module (gnu packages java)
   #:use-module (gnu packages linux)
   #:use-module (gnu packages machine-learning)
@@ -1690,7 +1691,7 @@ sequencing tag position and orientation.")
 (define-public mafft
   (package
     (name "mafft")
-    (version "7.221")
+    (version "7.267")
     (source (origin
               (method url-fetch)
               (uri (string-append
@@ -1699,7 +1700,7 @@ sequencing tag position and orientation.")
               (file-name (string-append name "-" version ".tgz"))
               (sha256
                (base32
-                "0xi7klbsgi049vsrk6jiwh9wfj3b770gz3c8c7zwij448v0dr73d"))))
+                "1xl6xq1rfxkws0svrlhyqxhhwbv6r77jwblsdpcyiwzsscw6wlk0"))))
     (build-system gnu-build-system)
     (arguments
      `(#:tests? #f ; no automated tests, though there are tests in the read me
@@ -1720,6 +1721,9 @@ sequencing tag position and orientation.")
               ;; remove mafft-homologs.rb from SCRIPTS
               (("^SCRIPTS = mafft mafft-homologs.rb")
                "SCRIPTS = mafft")
+              ;; remove mafft-homologs from MANPAGES
+              (("^MANPAGES = mafft.1 mafft-homologs.1")
+               "MANPAGES = mafft.1")
               ;; remove mafft-distance from PROGS
               (("^PROGS = dvtditr dndfast7 dndblast sextet5 mafft-distance")
                "PROGS = dvtditr dndfast7 dndblast sextet5")
@@ -1732,9 +1736,22 @@ sequencing tag position and orientation.")
               (("^\t\\$\\(INSTALL\\) -m 644 \\$\\(MANPAGES\\) \
 \\$\\(DESTDIR\\)\\$\\(LIBDIR\\)") "#"))
             #t))
+         (add-after 'enter-dir 'patch-paths
+           (lambda* (#:key inputs #:allow-other-keys)
+             (substitute* '("pairash.c"
+                            "mafft.tmpl")
+               (("perl") (which "perl"))
+               (("([\"`| ])awk" _ prefix)
+                (string-append prefix (which "awk")))
+               (("grep") (which "grep")))
+             #t))
          (delete 'configure))))
     (inputs
-     `(("perl" ,perl)))
+     `(("perl" ,perl)
+       ("gawk" ,gawk)
+       ("grep" ,grep)))
+    (propagated-inputs
+     `(("coreutils" ,coreutils)))
     (home-page "http://mafft.cbrc.jp/alignment/software/")
     (synopsis "Multiple sequence alignment program")
     (description
-- 
2.5.0


  reply	other threads:[~2015-12-15 12:05 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-10 12:18 Update mafft to 7.245 Ben Woodcroft
2015-11-10 13:06 ` Ricardo Wurmus
2015-11-10 13:12 ` Efraim Flashner
2015-11-10 22:22   ` Ben Woodcroft
2015-12-10 16:16     ` Ricardo Wurmus
2015-12-15 12:05       ` Ben Woodcroft [this message]
2015-12-17 12:47         ` Ricardo Wurmus
2015-12-17 20:01           ` Ben Woodcroft
2015-12-17 22:29             ` Ricardo Wurmus
2015-12-17 23:27               ` Ben Woodcroft
2015-12-21 14:17                 ` Ricardo Wurmus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=567001F0.7060206@uq.edu.au \
    --to=b.woodcroft@uq.edu.au \
    --cc=guix-devel@gnu.org \
    --cc=ricardo.wurmus@mdc-berlin.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).