wayland-bongocat: packaging fixes (#452723)
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
bash,
|
||||
fetchFromGitHub,
|
||||
gitUpdater,
|
||||
pkg-config,
|
||||
wayland,
|
||||
wayland-protocols,
|
||||
@@ -25,17 +27,21 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
wayland-scanner
|
||||
];
|
||||
buildInputs = [
|
||||
bash
|
||||
wayland
|
||||
wayland-protocols
|
||||
];
|
||||
|
||||
# Build phases
|
||||
# Ensure that the Makefile has the correct directory with the Wayland protocols
|
||||
preBuild = ''
|
||||
export WAYLAND_PROTOCOLS_DIR="${wayland-protocols}/share/wayland-protocols"
|
||||
makeFlags = [
|
||||
"WAYLAND_PROTOCOLS_DIR=${wayland-protocols}/share/wayland-protocols"
|
||||
"release"
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace Makefile \
|
||||
--replace-fail 'CC = gcc' 'CC ?= gcc'
|
||||
'';
|
||||
|
||||
makeFlags = [ "release" ];
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
@@ -49,7 +55,18 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
doInstallCheck = true;
|
||||
nativeInstallCheckInputs = [ versionCheckHook ];
|
||||
|
||||
# Package information
|
||||
installCheckPhase = ''
|
||||
runHook preInstallCheck
|
||||
|
||||
$out/bin/bongocat-find-devices --help
|
||||
|
||||
runHook postInstallCheck
|
||||
'';
|
||||
|
||||
passthru.updateScript = gitUpdater {
|
||||
rev-prefix = "v";
|
||||
};
|
||||
|
||||
meta = {
|
||||
description = "Delightful Wayland overlay that displays an animated bongo cat reacting to keyboard input";
|
||||
homepage = "https://github.com/saatvik333/wayland-bongocat";
|
||||
|
||||
Reference in New Issue
Block a user