Merge pull request #314811 from markuskowa/add-saunafs

saunasfs: init at 4.2.0
This commit is contained in:
Markus Kowalewski 2024-06-29 13:20:31 +00:00 committed by GitHub
commit 947213464b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 89 additions and 0 deletions

View File

@ -0,0 +1,72 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
asciidoc,
jemalloc,
boost,
fmt,
fuse3,
spdlog,
yaml-cpp,
isa-l,
judy,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "saunafs";
version = "4.2.0";
src = fetchFromGitHub {
owner = "leil-io";
repo = "saunafs";
rev = "v${finalAttrs.version}";
hash = "sha256-rEiiBHB1wRqpnSgFgqVGwA3kOwiDx6MgyTmWyIQHATU=";
};
patches = [
./sfstool.patch
];
outputs = [
"out"
"man"
"dev"
];
nativeBuildInputs = [
cmake
asciidoc
];
buildInputs = [
fmt
spdlog
yaml-cpp
fuse3
boost
jemalloc
isa-l
judy
];
cmakeFlags = [
(lib.cmakeBool "ENABLE_WERROR" false)
(lib.cmakeBool "ENABLE_DOC" false)
(lib.cmakeBool "ENABLE_CLIENT_LIB" true)
(lib.cmakeBool "ENABLE_JEMALLOC" true)
];
postInstall = lib.optionalString (!stdenv.hostPlatform.isStatic) ''
rm $out/lib/*.a
'';
meta = with lib; {
description = "Distributed POSIX file system";
homepage = "https://saunafs.com";
platforms = platforms.linux;
license = licenses.gpl3Only;
maintainers = [ maintainers.markuskowa ];
};
})

View File

@ -0,0 +1,13 @@
diff --git a/src/tools/sfstools.sh b/src/tools/sfstools.sh
index c6c41197..9a59814f 100755
--- a/src/tools/sfstools.sh
+++ b/src/tools/sfstools.sh
@@ -1,5 +1,6 @@
#!/usr/bin/env bash
-tool=$(basename $0)
+tool="$(basename $0)"
+dir="$(dirname $0)"
-${tool/saunafs/saunafs } "$@"
+$dir/saunafs ${tool/sfs/} "$@"

View File

@ -2882,6 +2882,10 @@ with pkgs;
inherit (darwin) autoSignDarwinBinariesHook;
};
saunafs = callPackage ../by-name/sa/saunafs/package.nix {
boost = boost185;
};
mucommander = callPackage ../applications/file-managers/mucommander { };
nnn = callPackage ../applications/file-managers/nnn { };