Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation for this change
BLAST tools are fundamental for bioinformatics. The official package and packages in various distributions are called
ncbi-blast
orncbi-blast+
, so I used this name.This PR in its current state is a response to #33956. (I have made it for myself and did not want to publish until I was certain that it was done right, but that issue prompted me to publish it now.) It builds and works. It allows, but does not implement cross compilation. It is not clear that
substitute-paths
helper should be accepted intoall-packages
, be scoped toncbi-blast
, be implemented in a different language , or if another approach to packaging Blast+ should be used instead.Blast+ build process is powered by a set of hand written Makefiles and shell scripts. They call various coreutils and other tools during the build time, but some of those tools are used during run time. It seemed nontrivial to figure out which occurrences of paths to programs are used during the build, which during the run, and which (if any) at both times, so I went with another approach which is both completely automatic and supports cross compilation. (Cross compilation part is not implemented yet.) The idea is to (1) rewrite absolute paths (e.g.
/bin/sh
,/usr/bin/find
) to the paths of build platform tools before the configure phase, and (2) rewrite paths of build platform tools with paths of host platform tools after the install phase. (Nix approach imposes the unusual burden that build platform paths are different from host platform paths. My solution alleviates it by using one set of paths to programs at a time. It works on the same principle that Nix uses to detect run time dependencies of packages.)Things done
build-use-sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)(
legacy_blast.pl
andupdate_blastdb.pl
are not wrapped with perl yet)