19 x86_64-linux = fetchurl {
20 url = "https://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/${version}/ncbi-blast-${version}+-x64-linux.tar.gz";
21 hash = "sha256-OO8MNOk6k0J9FlAGyCOhP+hirEIT6lL+rIInB8dQWEU=";
23 aarch64-linux = fetchurl {
24 url = "https://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/${version}/ncbi-blast-${version}+-aarch64-linux.tar.gz";
25 hash = "sha256-JlOyoxZQBbvUcHIMv5muTuGQgrh2uom3rzDurhHQ+FM=";
27 x86_64-darwin = fetchurl {
28 url = "https://ftp.ncbi.nlm.nih.gov/blast/executables/blast+/${version}/ncbi-blast-${version}+-x64-macosx.tar.gz";
29 hash = "sha256-eMfuwMCD6VlDgeshLslDhYBBp0YOpL+6q/zSchR0bAs=";
31 aarch64-darwin = x86_64-darwin;
33 src = srcs.${stdenv.hostPlatform.system};
36 inherit pname version src;
38 nativeBuildInputs = lib.optionals stdenv.hostPlatform.isLinux [ autoPatchelfHook ];
40 buildInputs = [ python3 perl ] ++ lib.optionals stdenv.hostPlatform.isLinux [ zlib bzip2 glib libxml2 ];
45 install -Dm755 bin/* -t $out/bin
51 substituteInPlace $out/bin/get_species_taxids.sh \
52 --replace /bin/rm ${coreutils}/bin/rm
56 inherit (blast.meta) description homepage license;
57 platforms = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ];
58 sourceProvenance = with sourceTypes; [ binaryNativeCode ];
59 maintainers = with maintainers; [ natsukium ];