lol
1{ lib
2, stdenv
3, fetchFromGitHub
4, meson
5, ninja
6, glib
7, libkrb5
8, libnl
9, libtool
10, pkg-config
11, withKerberos ? false
12}:
13
14stdenv.mkDerivation rec {
15 pname = "ksmbd-tools";
16 version = "3.5.0";
17
18 src = fetchFromGitHub {
19 owner = "cifsd-team";
20 repo = pname;
21 rev = version;
22 sha256 = "sha256-8mjfKCazigHnuN7Egf11ZuD+nQx7ZTesn0a4LsVvV/M=";
23 };
24
25 buildInputs = [ glib libnl ] ++ lib.optional withKerberos libkrb5;
26
27 nativeBuildInputs = [ meson ninja libtool pkg-config ];
28 patches = [ ./0001-skip-installing-example-configuration.patch ];
29 mesonFlags = [
30 "-Drundir=/run"
31 "--sysconfdir /etc"
32 ];
33
34 meta = with lib; {
35 description = "Userspace utilities for the ksmbd kernel SMB server";
36 homepage = "https://www.kernel.org/doc/html/latest/filesystems/cifs/ksmbd.html";
37 license = licenses.gpl2;
38 platforms = platforms.linux;
39 maintainers = with maintainers; [ elohmeier ];
40 };
41}