1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 autoreconfHook,
6 e2fsprogs,
7 fuse,
8}:
9
10stdenv.mkDerivation (finalAttrs: {
11 pname = "fuse-ext2";
12 version = "0.0.11";
13
14 src = fetchFromGitHub {
15 owner = "alperakcan";
16 repo = "fuse-ext2";
17 rev = "v${finalAttrs.version}";
18 hash = "sha256-VQMftlnd6q1PdwhSIQwjffjnkhupY8MUc8E+p1tgvUM=";
19 };
20
21 patches = [
22 # Remove references to paths outside the nix store
23 ./remove-impure-paths.patch
24 # Don't build macOS desktop installer
25 ./darwin-no-installer.patch
26 ];
27
28 nativeBuildInputs = [
29 autoreconfHook
30 ];
31
32 buildInputs = [
33 e2fsprogs
34 fuse
35 ];
36
37 env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang "-Wno-error=incompatible-function-pointer-types";
38
39 meta = with lib; {
40 description = "FUSE module to mount ext2, ext3 and ext4 with read write support";
41 homepage = "https://github.com/alperakcan/fuse-ext2";
42 license = licenses.gpl2Plus;
43 maintainers = with maintainers; [ emilytrau ];
44 platforms = platforms.unix;
45 mainProgram = "fuse-ext2";
46 };
47})