X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=default.nix;h=80aeb43314821924503d8a287892550224c96268;hb=HEAD;hp=f19ff1076ca200cb660cdadc83cd946d481d6799;hpb=e76352087b8fef64155d44a3c34e8ab7516f2a4a;p=bcachefs-tools-debian diff --git a/default.nix b/default.nix index f19ff10..80aeb43 100644 --- a/default.nix +++ b/default.nix @@ -1,32 +1,6 @@ -{ nixpkgs ? (import ./nix/nixpkgs.nix) -}: - -with nixpkgs; - -stdenv.mkDerivation rec { - name = "bcachefs-tools-${version}"; - version = "git"; - - src = lib.cleanSource ./.; # NOTE: ignore .git, otherwise things get weird! - - nativeBuildInputs = [ git pkgconfig ]; - buildInputs = - [ liburcu libuuid libaio zlib attr keyutils - libsodium libscrypt - ]; - - enableParallelBuilding = true; - makeFlags = - [ "PREFIX=$(out)" - ]; - - meta = with stdenv.lib; { - description = "Userspace tools for bcachefs"; - homepage = http://bcachefs.org; - license = licenses.gpl2; - platforms = platforms.linux; - maintainers = - [ "Kent Overstreet " - ]; - }; -} +(import (let lock = builtins.fromJSON (builtins.readFile ./flake.lock); +in fetchTarball { + url = + "https://github.com/edolstra/flake-compat/archive/${lock.nodes.flake-compat.locked.rev}.tar.gz"; + sha256 = lock.nodes.flake-compat.locked.narHash; +}) { src = ./.; }).defaultNix