Unverified Commit 094aae36 authored by Artturin's avatar Artturin Committed by GitHub
Browse files

Merge pull request #309521 from JohnRTitor/hyprlock

hyprlock: 0.3.0 -> 0.3.0-unstable-2024-04-24
parents 43fcad05 66d13063
Loading
Loading
Loading
Loading
+0 −15
Original line number Diff line number Diff line
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 07e2338..720810b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -83,9 +83,4 @@ protocol("unstable/linux-dmabuf/linux-dmabuf-unstable-v1.xml" "linux-dmabuf-unst
 # Installation
 install(TARGETS hyprlock)
 
-install(CODE "
-    if (NOT EXISTS \"${CMAKE_INSTALL_FULL_SYSCONFDIR}/pam.d/hyprlock\")
-        install(FILES \"${CMAKE_SOURCE_DIR}/pam/hyprlock\" DESTINATION \"${CMAKE_INSTALL_FULL_SYSCONFDIR}/pam.d\")
-    endif()
-")
-
+install(FILES "${CMAKE_SOURCE_DIR}/pam/hyprlock" DESTINATION "${CMAKE_INSTALL_FULL_SYSCONFDIR}/pam.d")
+31 −25
Original line number Diff line number Diff line
{ lib
, stdenv
, fetchFromGitHub
, cmake
, pkg-config
, libGL
, libxkbcommon
, hyprlang
, pam
, wayland
, wayland-protocols
, cairo
, pango
, libdrm
, mesa
, nix-update-script
{
  lib,
  stdenv,
  fetchFromGitHub,
  cmake,
  pkg-config,
  libGL,
  libxkbcommon,
  hyprlang,
  pam,
  wayland,
  wayland-protocols,
  cairo,
  file,
  libjpeg,
  libwebp,
  pango,
  libdrm,
  mesa,
  nix-update-script,
}:

stdenv.mkDerivation (finalAttrs: {
  pname = "hyprlock";
  version = "0.3.0";
  version = "0.3.0-unstable-2024-04-24";

  src = fetchFromGitHub {
    owner = "hyprwm";
    repo = "hyprlock";
    rev = "v${finalAttrs.version}";
    hash = "sha256-rbzVe2WNdHynJrnyJsKOOrV8yuuJ7QIuah3ZHWERSnA=";
    # FIXME: Change to a stable release once available
    rev = "415262065fff0a04b229cd00165f346a86a0a73a";
    hash = "sha256-jla5Wo0Qt3NEnD0OjNj85BGw0pR4Zlz5uy8AqHH7tuE=";
  };

  patches = [
    # remove PAM file install check
    ./cmake.patch
  ];

  strictDeps = true;

  nativeBuildInputs = [
@@ -41,9 +41,12 @@ stdenv.mkDerivation (finalAttrs: {

  buildInputs = [
    cairo
    file
    hyprlang
    libdrm
    libGL
    libjpeg
    libwebp
    libxkbcommon
    mesa
    pam
@@ -60,6 +63,9 @@ stdenv.mkDerivation (finalAttrs: {
    license = lib.licenses.bsd3;
    maintainers = with lib.maintainers; [ eclairevoyant ];
    mainProgram = "hyprlock";
    platforms = [ "aarch64-linux" "x86_64-linux" ];
    platforms = [
      "aarch64-linux"
      "x86_64-linux"
    ];
  };
})