all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#71146] [PATCH] gnu: kallisto: Update to 0.50.1
@ 2024-05-23  9:53 guix--- via Guix-patches via
       [not found] ` <87wmn8kcpa.fsf@elephly.net>
  2024-06-01 19:13 ` Ricardo Wurmus
  0 siblings, 2 replies; 4+ messages in thread
From: guix--- via Guix-patches via @ 2024-05-23  9:53 UTC (permalink / raw)
  To: 71146; +Cc: Ricardo Wurmus

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

Updated kallisto to 0.50.1, it now supports more single-cell technologies (e.g. SPLiT-seq).

I had to modify the 'do-not-use-bundled-htslib snippet to make one regex more selective---in this new version it the previous regex was mistakenly modifying parts of CMakeLists.txt other than the intended one.

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-kallisto-Update-to-0.50.1.patch --]
[-- Type: text/x-patch; name=0001-gnu-kallisto-Update-to-0.50.1.patch, Size: 2511 bytes --]

From 9bec1c5bf14b644ef7147b1bc66acaea6a903830 Mon Sep 17 00:00:00 2001
Message-ID: <9bec1c5bf14b644ef7147b1bc66acaea6a903830.1716457241.git.guix@mawumag.com>
From: Marco Baggio <guix@mawumag.com>
Date: Thu, 23 May 2024 08:52:06 +0200
Subject: [PATCH] gnu: kallisto: Update to 0.50.1

Change-Id: I1b048be328f6d1d5034dfe29688a44f2af0b026a
---
 gnu/packages/bioinformatics.scm | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index b7e8e54de2..8dee300320 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -14820,7 +14820,7 @@ (define-public segemehl
 (define-public kallisto
   (package
     (name "kallisto")
-    (version "0.48.0")
+    (version "0.50.1")
     (source (origin
               (method git-fetch)
               (uri (git-reference
@@ -14829,7 +14829,7 @@ (define-public kallisto
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "0wx1ndmhndsd60952piaa925lk8bjr59d2yr1m2hcsqcb6cdjwpn"))
+                "0zfs79mv75599cf9d7d3c5a3s8idgz9qvl4qfzhvhbd87y3dv7p0"))
               (modules '((guix build utils)))
               (snippet
                '(delete-file-recursively "ext/htslib/"))))
@@ -14841,16 +14841,16 @@ (define-public kallisto
          (add-after 'unpack 'do-not-use-bundled-htslib
            (lambda _
              (substitute* "CMakeLists.txt"
-               (("^ExternalProject_Add" m)
+               (("^ExternalProject_Add\\(htslib[^\\)]*\\)" m)
                 (string-append "if (NEVER)\n" m))
-               (("^\\)")
-                (string-append ")\nendif(NEVER)"))
                (("include_directories\\(\\$\\{htslib_PREFIX.*" m)
                 (string-append "# " m)))
              (substitute* "src/CMakeLists.txt"
                (("target_link_libraries\\(kallisto kallisto_core pthread \
-\\$\\{CMAKE_CURRENT_SOURCE_DIR\\}/../ext/htslib/libhts.a\\)")
-                "target_link_libraries(kallisto kallisto_core pthread hts)")
+\\$\\{CMAKE_CURRENT_SOURCE_DIR\\}/../ext/htslib/libhts.a \
+\\$\\{install_dir\\}/build/src/libbifrost.a\\)")
+                "target_link_libraries(kallisto kallisto_core pthread hts \
+${install_dir}/build/src/libbifrost.a)")
                (("include_directories\\(\\.\\./ext/htslib\\)") "")))))))
     (inputs
      (list hdf5 htslib-1.9 zlib))

base-commit: 3597c736588c45efde3c22d533ea8774c3fdd235
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#71146] [PATCH] gnu: kallisto: Update to 0.50.1
       [not found] ` <87wmn8kcpa.fsf@elephly.net>
@ 2024-06-01 19:13   ` Ricardo Wurmus
  2024-06-04 15:36     ` guix--- via Guix-patches via
  0 siblings, 1 reply; 4+ messages in thread
From: Ricardo Wurmus @ 2024-06-01 19:13 UTC (permalink / raw)
  To: guix; +Cc: 71146

Ricardo Wurmus <rekado@elephly.net> writes:

>> I had to modify the 'do-not-use-bundled-htslib snippet to make one
>> regex more selective---in this new version it the previous regex was
>> mistakenly modifying parts of CMakeLists.txt other than the intended
>> one.
>
> It looks like this might not be working as intended.  I used:
>
>     guix gc -R $(./pre-inst-env guix build kallisto)
>
> and it shows me that the newly built kallisto does not link with our
> htslib.  Perhaps it used the static library?

Turns out it's not actually using htslib at all, because USE_BAM is not
set.  It uses a bundled copy of bifrost instead.  If we want to build
kallisto with bifrost only then we should remove htslib from the inputs,
package bifrost (https://github.com/pmelsted/bifrost) and unbundle it
from kallisto, linking with the shared library.

Does this sound like a good plan or should we use htslib instead?

-- 
Ricardo




^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#71146] [PATCH] gnu: kallisto: Update to 0.50.1
  2024-05-23  9:53 [bug#71146] [PATCH] gnu: kallisto: Update to 0.50.1 guix--- via Guix-patches via
       [not found] ` <87wmn8kcpa.fsf@elephly.net>
@ 2024-06-01 19:13 ` Ricardo Wurmus
  1 sibling, 0 replies; 4+ messages in thread
From: Ricardo Wurmus @ 2024-06-01 19:13 UTC (permalink / raw)
  To: guix; +Cc: 71146

Thank you for the patch!

> I had to modify the 'do-not-use-bundled-htslib snippet to make one
> regex more selective---in this new version it the previous regex was
> mistakenly modifying parts of CMakeLists.txt other than the intended
> one.

It looks like this might not be working as intended.  I used:

    guix gc -R $(./pre-inst-env guix build kallisto)

and it shows me that the newly built kallisto does not link with our
htslib.  Perhaps it used the static library?

-- 
Ricardo




^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#71146] [PATCH] gnu: kallisto: Update to 0.50.1
  2024-06-01 19:13   ` Ricardo Wurmus
@ 2024-06-04 15:36     ` guix--- via Guix-patches via
  0 siblings, 0 replies; 4+ messages in thread
From: guix--- via Guix-patches via @ 2024-06-04 15:36 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: 71146

> Ricardo Wurmus rekado@elephly.net writes:
> 
> Turns out it's not actually using htslib at all, because USE_BAM is not
> set. It uses a bundled copy of bifrost instead. If we want to build
> kallisto with bifrost only then we should remove htslib from the inputs,
> package bifrost (https://github.com/pmelsted/bifrost) and unbundle it
> from kallisto, linking with the shared library.
> 
> Does this sound like a good plan or should we use htslib instead?

My initial attempt was to unbundle bifrost from kallisto, but I had two concerns:

- I was not able to determine the exact version of bifrost that was bundled with kallisto (it is definitely not the latest one, as the relevant ext/bifrost directory in kallisto is older).
This is also a problem with htslib, I am sure whoever packaged kallisto 0.48.0 was careful to choose the correct version, but I would not know how to verify this.
This has the potential to lead to mismatches (or even bugs) between the guix version and the official one compiled from their sources.

- Some header files of bifrost appear to be included in kallisto source code directly, but it was not clear to me how to include bifrost in guix in a way that exports its libraries and headers.

Especially for the first reason, I would actually propose to use the bundled htslib and bifrost for kallisto. Both are bundled as source code and are compiled during the build process, so this should not pose a concern (bifrost is released under BSD 2-Clause License, like kallisto, while htslib is released under expat).

Please let me know what you think.

Cheers,
Marco





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-06-04 18:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-23  9:53 [bug#71146] [PATCH] gnu: kallisto: Update to 0.50.1 guix--- via Guix-patches via
     [not found] ` <87wmn8kcpa.fsf@elephly.net>
2024-06-01 19:13   ` Ricardo Wurmus
2024-06-04 15:36     ` guix--- via Guix-patches via
2024-06-01 19:13 ` Ricardo Wurmus

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.