Merge pull request #305361 from Aleksanaa/gtklock

gtklock: 2.1.0 -> 3.0.0; gtk-session-lock: init at 0.2.0
This commit is contained in:
Aleksana 2024-04-27 15:00:08 +08:00 committed by GitHub
commit 590959643e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 73 additions and 18 deletions

View File

@ -0,0 +1,57 @@
{ lib
, stdenv
, fetchFromGitHub
, meson
, ninja
, pkg-config
, gobject-introspection
, vala
, gtk3
, wayland-scanner
, wayland
}:
stdenv.mkDerivation (finalAttrs: {
pname = "gtk-session-lock";
version = "0.2.0";
src = fetchFromGitHub {
owner = "Cu3PO42";
repo = "gtk-session-lock";
rev = "v${finalAttrs.version}";
hash = "sha256-SHKAYmdev08oRB/V6UpfSFqYwplF59IaNSOoWcACPig=";
};
outputs = [ "out" "dev" ];
nativeBuildInputs = [
meson
ninja
pkg-config
gobject-introspection
vala
wayland-scanner
];
buildInputs = [
gtk3
wayland
];
# Tests are not fully prepared, but may be enabled in later versions
doCheck = false;
strictDeps = true;
meta = {
description = "A library to use GTK 3 to build screen lockers using ext-session-lock-v1 protocol";
homepage = "https://github.com/Cu3PO42/gtk-session-lock";
# The author stated "GTK Session Lock is licensed under the GNU General
# Public License version 3.0 or any later version approved by me (Cu3PO42)."
# Since we don't know if the author will approve later versions, we mark gpl3Only
license = with lib.licenses; [ gpl3Only ];
maintainers = with lib.maintainers; [ aleksana ];
platforms = lib.platforms.unix;
badPlatforms = lib.platforms.darwin;
};
})

View File

@ -1,45 +1,43 @@
{ lib
, stdenv
, fetchFromGitHub
, wrapGAppsHook
, pam
, meson
, ninja
, scdoc
, gtk3
, pkg-config
, gtk-layer-shell
, glib
, librsvg
, wayland
, wayland-scanner
, wrapGAppsHook
, gtk3
, pam
, gtk-session-lock
}:
stdenv.mkDerivation rec {
pname = "gtklock";
version = "2.1.0";
version = "3.0.0";
src = fetchFromGitHub {
owner = "jovanlanik";
repo = pname;
repo = "gtklock";
rev = "v${version}";
sha256 = "sha256-Jh+BmtKGaLgAcTXc44ydV83dp/W4wzByehUWyeyBoFI=";
hash = "sha256-B6pySjiwPBRFb4avE9NHsS1KkWMPW81DAqYro/wtrmQ=";
};
nativeBuildInputs = [
meson
ninja
scdoc
pkg-config
wayland-scanner
glib
wrapGAppsHook
];
buildInputs = [
wayland
gtk3
pam
gtk-layer-shell
librsvg
gtk-session-lock
];
strictDeps = true;
installFlags = [
"DESTDIR=$(out)"
"PREFIX="
@ -51,8 +49,8 @@ stdenv.mkDerivation rec {
Important note: for gtklock to work you need to set "security.pam.services.gtklock = {};" manually.
''; # Following nixpkgs/pkgs/applications/window-managers/sway/lock.nix
homepage = "https://github.com/jovanlanik/gtklock";
license = licenses.gpl3;
maintainers = with maintainers; [ dit7ya ];
license = licenses.gpl3Only;
maintainers = with maintainers; [ dit7ya aleksana ];
platforms = platforms.linux;
mainProgram = "gtklock";
};