biome: 1.9.2 -> 1.9.3
[NixPkgs.git] / pkgs / tools / package-management / micromamba / default.nix
blob8707d4099f95c6d4362c28e35b69ae83aeb8ec18
1 { lib
2 , stdenv
3 , fetchFromGitHub
4 , fetchpatch
5 , bzip2
6 , cli11
7 , cmake
8 , curl
9 , ghc_filesystem
10 , libarchive
11 , libsolv
12 , yaml-cpp
13 , nlohmann_json
14 , python3
15 , reproc
16 , spdlog
17 , tl-expected
20 let
21   libsolv' = libsolv.overrideAttrs (oldAttrs: {
22     cmakeFlags = oldAttrs.cmakeFlags ++ [
23       "-DENABLE_CONDA=true"
24     ];
26     patches = [
27       # Apply the same patch as in the "official" boa-forge build:
28       # https://github.com/mamba-org/boa-forge/tree/master/libsolv
29       (fetchpatch {
30         url = "https://raw.githubusercontent.com/mamba-org/boa-forge/20530f80e2e15012078d058803b6e2c75ed54224/libsolv/conda_variant_priorization.patch";
31         sha256 = "1iic0yx7h8s662hi2jqx68w5kpyrab4fr017vxd4wyxb6wyk35dd";
32       })
33     ];
34   });
36 stdenv.mkDerivation rec {
37   pname = "micromamba";
38   version = "1.5.8";
40   src = fetchFromGitHub {
41     owner = "mamba-org";
42     repo = "mamba";
43     rev = "micromamba-" + version;
44     hash = "sha256-sxZDlMFoMLq2EAzwBVO++xvU1C30JoIoZXEX/sqkXS0=";
45   };
47   nativeBuildInputs = [ cmake ];
49   buildInputs = [
50     bzip2
51     cli11
52     nlohmann_json
53     curl
54     libarchive
55     yaml-cpp
56     libsolv'
57     reproc
58     spdlog
59     ghc_filesystem
60     python3
61     tl-expected
62   ];
64   cmakeFlags = [
65     "-DBUILD_LIBMAMBA=ON"
66     "-DBUILD_SHARED=ON"
67     "-DBUILD_MICROMAMBA=ON"
68     # "-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON"
69   ];
71   meta = with lib; {
72     description = "Reimplementation of the conda package manager";
73     homepage = "https://github.com/mamba-org/mamba";
74     license = licenses.bsd3;
75     platforms = platforms.all;
76     maintainers = with maintainers; [ mausch ];
77     mainProgram = "micromamba";
78   };