guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 3/3] gnu: Add khmer.


From: Leo Famulari
Subject: Re: [PATCH 3/3] gnu: Add khmer.
Date: Fri, 17 Jun 2016 03:23:58 -0400
User-agent: Mutt/1.6.0 (2016-04-01)

On Fri, Jun 17, 2016 at 11:23:21AM +1000, Ben Woodcroft wrote:
> +    (build-system python-build-system)
> +    (arguments
> +     `(#:phases
> +       (modify-phases %standard-phases
> +         (add-after 'unpack 'set-paths

This phase deletes bundled libraries and then copies one of the
libraries back in from another package (murmur-hash).

Can khmer refer to murmur-hash without it being bundled at all?

> +           (lambda* (#:key inputs outputs #:allow-other-keys)
> +             ;; Delete bundled libraries.
> +             (delete-file-recursively "third-party/zlib")
> +             (delete-file-recursively "third-party/bzip2")
> +             ;; Replace bundled seqan.
> +             (let* ((seqan-all "third-party/seqan")
> +                    (seqan-include (string-append
> +                                    seqan-all "/core/include/seqan")))
> +               (delete-file-recursively seqan-all)
> +               (mkdir-p seqan-include)
> +               (rmdir seqan-include)

Here it makes the directory seqan-include and then removes it. Should it
be reversed? Would it be simpler to delete the directory and then use
copy-recursively, which I don't think requires mkdir-p?

> +               (copy-file (string-append (assoc-ref inputs "seqan")
> +                                         "/include/seqan")
> +                          seqan-include))
> +             ;; Replace bundled MurmurHash.

> +             (let ((smhasher "third-party/smhasher/"))
> +               (delete-file-recursively smhasher)
> +               (mkdir smhasher)
> +               (for-each
> +                (lambda (file)
> +                  (copy-file
> +                   (string-append
> +                    (assoc-ref inputs "murmur-hash") "/include/" file)
> +                   (string-append smhasher file)))
> +                (list "MurmurHash3.cpp" "MurmurHash3.h"))
> +               (rename-file
> +                (string-append smhasher "MurmurHash3.cpp")
> +                (string-append smhasher "MurmurHash3.cc")))
> +             (setenv "CC" "gcc")

I think this variable setting should be in its own phase.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]