nixpkgs/pkgs/tools/filesystems/dwarfs/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

102 lines
1.8 KiB
Nix
Raw Permalink Normal View History

{ lib
, fetchFromGitHub
, stdenv
, substituteAll
, bison
, boost
, cmake
, double-conversion
2023-07-23 19:11:29 +02:00
, fmt
, fuse3
, glog
, gtest
, jemalloc
, libarchive
, libevent
, libunwind
, lz4
, openssl
, pkg-config
, ronn
, xxHash
2023-07-23 19:11:29 +02:00
, utf8cpp
, zstd
}:
stdenv.mkDerivation rec {
pname = "dwarfs";
2024-01-19 17:31:29 +01:00
version = "0.7.5";
src = fetchFromGitHub {
owner = "mhx";
repo = "dwarfs";
rev = "v${version}";
fetchSubmodules = true;
2024-01-19 17:31:29 +01:00
hash = "sha256-Zzm2SaFR31TBBMDfgJulVbqsJBh1He2wBFzHRC/c5vg=";
};
2023-07-23 19:11:29 +02:00
patches = [
(with lib.versions; substituteAll {
src = ./version_info.patch;
2023-07-23 19:11:29 +02:00
versionFull = version; # displayed as version number (with v prepended)
versionMajor = major version;
versionMinor = minor version;
versionPatch = patch version;
})
];
cmakeFlags = [
"-DPREFER_SYSTEM_ZSTD=ON"
"-DPREFER_SYSTEM_XXHASH=ON"
"-DPREFER_SYSTEM_GTEST=ON"
2023-07-23 19:11:29 +02:00
"-DPREFER_SYSTEM_LIBFMT=ON"
# may be added under an option in the future
# "-DWITH_LEGACY_FUSE=ON"
"-DWITH_TESTS=ON"
];
nativeBuildInputs = [
bison
cmake
pkg-config
ronn
];
buildInputs = [
# dwarfs
boost
2023-07-23 19:11:29 +02:00
fmt
fuse3
jemalloc
libarchive
lz4
xxHash
2023-07-23 19:11:29 +02:00
utf8cpp
zstd
# folly
double-conversion
glog
libevent
libunwind
openssl
];
doCheck = true;
nativeCheckInputs = [ gtest ];
2023-07-23 19:11:29 +02:00
# these fail inside of the sandbox due to missing access
# to the FUSE device
2023-07-23 19:11:29 +02:00
GTEST_FILTER = "-dwarfs/tools_test.end_to_end/*:dwarfs/tools_test.mutating_ops/*";
meta = with lib; {
description = "A fast high compression read-only file system";
homepage = "https://github.com/mhx/dwarfs";
license = licenses.gpl3Plus;
2024-04-27 05:22:56 +02:00
maintainers = with maintainers; [ ];
platforms = platforms.linux;
};
}