2022-07-14 12:49:19 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cmake
|
|
|
|
, libjpeg
|
|
|
|
, mesa
|
|
|
|
, pango
|
2022-10-21 18:38:19 +00:00
|
|
|
, pkg-config
|
2022-07-14 12:49:19 +00:00
|
|
|
, wayland
|
|
|
|
, wayland-protocols
|
|
|
|
, wayland-scanner
|
|
|
|
}:
|
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
2022-07-14 12:49:19 +00:00
|
|
|
pname = "hyprpaper";
|
2022-10-21 18:38:19 +00:00
|
|
|
version = "unstable-2022-09-30";
|
2022-07-14 12:49:19 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "hyprwm";
|
2022-10-21 18:38:19 +00:00
|
|
|
repo = "hyprpaper";
|
|
|
|
rev = "8f4c712950ad6a9bc7c7281c15a63f5fa06ba92b";
|
|
|
|
hash = "sha256-KojBifIOkJ2WmO/lRjQIgPgUnX5Eu10U4VDg+1MB2co=";
|
2022-07-14 12:49:19 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
pkg-config
|
|
|
|
wayland-scanner
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
libjpeg
|
|
|
|
mesa
|
|
|
|
pango
|
|
|
|
wayland
|
|
|
|
wayland-protocols
|
|
|
|
];
|
|
|
|
|
|
|
|
prePatch = ''
|
|
|
|
substituteInPlace src/main.cpp \
|
2022-10-21 18:38:19 +00:00
|
|
|
--replace GIT_COMMIT_HASH '"${finalAttrs.src.rev}"'
|
2022-07-14 12:49:19 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
make protocols
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
2022-10-21 18:38:19 +00:00
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
install -Dm755 ./hyprpaper -t $out/bin
|
|
|
|
|
|
|
|
runHook postInstall
|
2022-07-14 12:49:19 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
2022-10-21 18:38:19 +00:00
|
|
|
inherit (finalAttrs.src.meta) homepage;
|
2022-07-14 12:49:19 +00:00
|
|
|
description = "A blazing fast wayland wallpaper utility";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ wozeparrot ];
|
2022-10-21 18:38:19 +00:00
|
|
|
inherit (wayland.meta) platforms;
|
|
|
|
# ofborg failure: g++ does not recognize '-std=c++23'
|
|
|
|
broken = stdenv.isAarch64;
|
2022-07-14 12:49:19 +00:00
|
|
|
};
|
2022-10-21 18:38:19 +00:00
|
|
|
})
|