about summary refs log tree commit diff
path: root/nixpkgs/pkgs/by-name/ws/wslu/package.nix
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2024-03-22 16:41:59 +0100
committerAlyssa Ross <hi@alyssa.is>2024-03-22 16:41:59 +0100
commit46a88117a05c3469af5d99433af140c3de8ca088 (patch)
treed7f0557756d8f07a3081b3498c05ddc5a8ad429d /nixpkgs/pkgs/by-name/ws/wslu/package.nix
parente97457545cea0b2ca421da257c83d8f1ef451d85 (diff)
parenta343533bccc62400e8a9560423486a3b6c11a23b (diff)
downloadnixlib-46a88117a05c3469af5d99433af140c3de8ca088.tar
nixlib-46a88117a05c3469af5d99433af140c3de8ca088.tar.gz
nixlib-46a88117a05c3469af5d99433af140c3de8ca088.tar.bz2
nixlib-46a88117a05c3469af5d99433af140c3de8ca088.tar.lz
nixlib-46a88117a05c3469af5d99433af140c3de8ca088.tar.xz
nixlib-46a88117a05c3469af5d99433af140c3de8ca088.tar.zst
nixlib-46a88117a05c3469af5d99433af140c3de8ca088.zip
Merge commit 'a343533bccc62400e8a9560423486a3b6c11a23b'
Diffstat (limited to 'nixpkgs/pkgs/by-name/ws/wslu/package.nix')
-rw-r--r--nixpkgs/pkgs/by-name/ws/wslu/package.nix45
1 files changed, 45 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/by-name/ws/wslu/package.nix b/nixpkgs/pkgs/by-name/ws/wslu/package.nix
new file mode 100644
index 000000000000..422b8e76efb6
--- /dev/null
+++ b/nixpkgs/pkgs/by-name/ws/wslu/package.nix
@@ -0,0 +1,45 @@
+{ lib
+, stdenv
+, fetchFromGitHub
+, copyDesktopItems
+}:
+
+stdenv.mkDerivation rec {
+  pname = "wslu";
+  version = "4.1.1";
+
+  src = fetchFromGitHub {
+    owner = "wslutilities";
+    repo = "wslu";
+    rev = "v${version}";
+    hash = "sha256-yhugh836BoSISbTu19ubLOrz5X31Opu5QtCR0DXrbWc=";
+  };
+
+  nativeBuildInputs = [ copyDesktopItems ];
+
+  patches = [
+    ./fallback-conf-nix-store.diff
+    ./fix-desktop-item.patch
+  ];
+
+  postPatch = ''
+    substituteInPlace src/wslu-header \
+      --subst-var out
+  '';
+
+  makeFlags = [
+    "DESTDIR=$(out)"
+    "PREFIX="
+  ];
+
+  desktopItems = [ "src/etc/wslview.desktop" ];
+
+  meta = with lib; {
+    description = "A collection of utilities for Windows Subsystem for Linux";
+    homepage = "https://github.com/wslutilities/wslu";
+    changelog = "https://github.com/wslutilities/wslu/releases/tag/v${version}";
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ jamiemagee ];
+    platforms = platforms.linux;
+  };
+}