Commit 4dd9e988 authored by Mihai Fufezan's avatar Mihai Fufezan Committed by Jörg Thalheim
Browse files

xdg-desktop-portal-hyprland: 0.5.0 -> unstable-2023-09-10

parent 8f4341b1
Loading
Loading
Loading
Loading
+39 −18
Original line number Diff line number Diff line
{ lib
, stdenv
, fetchFromGitHub
, makeWrapper
, meson
, ninja
, pkg-config
, wayland-scanner
, makeWrapper
, wrapQtAppsHook
, hyprland-protocols
, hyprland-share-picker
, inih
, libdrm
, libuuid
, mesa
, pipewire
, qtbase
, qttools
, qtwayland
, sdbus-cpp
, systemd
, wayland
, wayland-protocols
, wayland-scanner
, hyprland
, slurp
}:
let
  source = import ./source.nix { inherit lib fetchFromGitHub wayland; };
in
stdenv.mkDerivation {
  pname = "xdg-desktop-portal-hyprland";
  inherit (source) src version meta;
  version = "unstable-2023-09-10";

  src = fetchFromGitHub {
    owner = "hyprwm";
    repo = "xdg-desktop-portal-hyprland";
    rev = "aca51609d4c415b30e88b96c6f49f0142cbcdae7";
    hash = "sha256-RF6LXm4J6mBF3B8VcQuABuU4g4tCPHgMYJQSoJ3DW+8=";
  };

  strictDeps = true;
  depsBuildBuild = [ pkg-config ];
  nativeBuildInputs = [
    makeWrapper
    meson
    ninja
    pkg-config
    wayland-scanner
    makeWrapper
    wrapQtAppsHook
  ];

  buildInputs = [
    hyprland-protocols
    inih
    libdrm
    libuuid
    mesa
    pipewire
    qtbase
    qttools
    qtwayland
    sdbus-cpp
    systemd
    wayland
    wayland-protocols
  ];

  mesonFlags = [
    "-Dsd-bus-provider=libsystemd"
  ];
  dontWrapQtApps = true;

  postInstall = ''
    wrapProgram $out/libexec/xdg-desktop-portal-hyprland --prefix PATH ":" ${lib.makeBinPath [hyprland-share-picker]}
    wrapProgramShell $out/bin/hyprland-share-picker \
      "''${qtWrapperArgs[@]}" \
      --prefix PATH ":" ${lib.makeBinPath [slurp hyprland]}

    wrapProgramShell $out/libexec/xdg-desktop-portal-hyprland \
      --prefix PATH ":" ${lib.makeBinPath [(placeholder "out")]}
  '';

  meta = with lib; {
    homepage = "https://github.com/hyprwm/xdg-desktop-portal-hyprland";
    description = "xdg-desktop-portal backend for Hyprland";
    license = licenses.bsd3;
    maintainers = with maintainers; [ fufexan ];
    platforms = platforms.linux;
  };
}
+0 −36
Original line number Diff line number Diff line
{ stdenv
, lib
, fetchFromGitHub
, cmake
, qtbase
, makeShellWrapper
, wrapQtAppsHook
, hyprland
, grim
, slurp
, wayland
}:
let
  source = import ./source.nix { inherit lib fetchFromGitHub wayland; };
in
stdenv.mkDerivation {
  pname = "hyprland-share-picker";
  inherit (source) version;

  src = "${source.src}/hyprland-share-picker";

  nativeBuildInputs = [ cmake wrapQtAppsHook makeShellWrapper ];
  buildInputs = [ qtbase ];

  dontWrapQtApps = true;

  postInstall = ''
    wrapProgramShell $out/bin/hyprland-share-picker \
      "''${qtWrapperArgs[@]}" \
      --prefix PATH ":" ${lib.makeBinPath [grim slurp hyprland]}
  '';

  meta = source.meta // {
    description = "Helper program for xdg-desktp-portal-hyprland";
  };
}
+0 −25
Original line number Diff line number Diff line
{ lib
, fetchFromGitHub
, wayland
}:
let
  version = "0.5.0";
in
{
  inherit version;

  src = fetchFromGitHub {
    owner = "hyprwm";
    repo = "xdg-desktop-portal-hyprland";
    rev = "v${version}";
    hash = "sha256-C5AO0KnyAFJaCkOn+5nJfWm0kyiPn/Awh0lKTjhgr7Y=";
  };

  meta = with lib; {
    description = "xdg-desktop-portal backend for Hyprland";
    homepage = "https://github.com/hyprwm/xdg-desktop-portal-hyprland";
    license = licenses.mit;
    maintainers = with maintainers; [ fufexan ];
    platforms = wayland.meta.platforms;
  };
}
+4 −3
Original line number Diff line number Diff line
@@ -5694,8 +5694,6 @@ with pkgs;
  hyprland-protocols = callPackage ../applications/window-managers/hyprwm/hyprland-protocols { };
  hyprland-share-picker = libsForQt5.callPackage ../applications/window-managers/hyprwm/xdg-desktop-portal-hyprland/hyprland-share-picker.nix { };
  hyprnome = callPackage ../applications/misc/hyprnome { };
  hyprpaper = callPackage ../applications/window-managers/hyprwm/hyprpaper { };
@@ -36884,7 +36882,10 @@ with pkgs;
  xdg-desktop-portal-gtk = callPackage ../development/libraries/xdg-desktop-portal-gtk { };
  xdg-desktop-portal-hyprland = callPackage ../applications/window-managers/hyprwm/xdg-desktop-portal-hyprland { };
  xdg-desktop-portal-hyprland = callPackage ../applications/window-managers/hyprwm/xdg-desktop-portal-hyprland {
    stdenv = gcc13Stdenv;
    inherit (qt6) qtbase qttools qtwayland wrapQtAppsHook;
  };
  xdg-desktop-portal-wlr = callPackage ../development/libraries/xdg-desktop-portal-wlr { };