Commit 33e65120 authored by Anthony ROUSSEL's avatar Anthony ROUSSEL
Browse files

httpdirfs: 1.2.5 -> 1.2.6

Changelog: https://github.com/fangfufu/httpdirfs/compare/1.2.5...1.2.6

Unfortunately, MacOS support has been removed intentionally upstream with this release:

> I don't have the resources to test out compilation for Linux distributions
> other than Debian. I also do not have the resources to test out compilation for
> FreeBSD or macOS. Thereforce I have removed the instruction on how to compile
> for these operating systems in the README for now. Please feel free to send me a
> pull request to add them back in.

See https://github.com/fangfufu/httpdirfs?tab=readme-ov-file#other-operating-systems
parent 8195804e
Loading
Loading
Loading
Loading
+13 −22
Original line number Diff line number Diff line
@@ -2,11 +2,13 @@
  curl,
  expat,
  fetchFromGitHub,
  fuse,
  fuse3,
  gumbo,
  help2man,
  lib,
  libuuid,
  meson,
  ninja,
  nix-update-script,
  pkg-config,
  stdenv,
@@ -15,46 +17,35 @@

stdenv.mkDerivation (finalAttrs: {
  pname = "httpdirfs";
  version = "1.2.5";
  version = "1.2.6";

  src = fetchFromGitHub {
    owner = "fangfufu";
    repo = "httpdirfs";
    rev = "refs/tags/${finalAttrs.version}";
    hash = "sha256-PUYsT0VDEzerPqwrLJrET4kSsWsQhtnfmLepeaqtA+I=";
    hash = "sha256-4Tp9DTYWUHElO0YNeINgzmbI0tpXxmKfZ1Jhz5UYn5M=";
  };

  postPatch = lib.optional stdenv.hostPlatform.isDarwin ''
    substituteInPlace Makefile --replace-fail '-fanalyzer' '-Xanalyzer'
  '';

  nativeBuildInputs = [
    help2man
    meson
    ninja
    pkg-config
  ];

  buildInputs = [
    curl
    expat
    fuse
    fuse3
    gumbo
    libuuid
  ];

  makeFlags = [ "prefix=${placeholder "out"}" ];

  postBuild = ''
    make man
  '';

  passthru = {
    # Disabled for Darwin because requires macFUSE installed outside NixOS
    tests.version = lib.optionalAttrs stdenv.hostPlatform.isLinux (
      testers.testVersion {
    tests.version = testers.testVersion {
      command = "${lib.getExe finalAttrs.finalPackage} --version";
      package = finalAttrs.finalPackage;
      }
    );
    };
    updateScript = nix-update-script { };
  };

@@ -65,6 +56,6 @@ stdenv.mkDerivation (finalAttrs: {
    license = lib.licenses.gpl3Only;
    mainProgram = "httpdirfs";
    maintainers = with lib.maintainers; [ sbruder schnusch anthonyroussel ];
    platforms = lib.platforms.unix;
    platforms = lib.platforms.linux;
  };
})