Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 15 additions & 7 deletions pkgs/applications/window-managers/cage/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{ lib, stdenv, fetchFromGitHub
, substituteAll
, meson, ninja, pkg-config, wayland-scanner, scdoc, makeWrapper
, wlroots, wayland, wayland-protocols, pixman, libxkbcommon, xcbutilwm
, systemd, libGL, libX11, mesa
Expand All @@ -8,15 +9,24 @@

stdenv.mkDerivation rec {
pname = "cage";
version = "0.1.5";
version = "0.1.5-unstable-2024-07-29";

src = fetchFromGitHub {
owner = "Hjdskes";
owner = "cage-kiosk";
repo = "cage";
rev = "v${version}";
hash = "sha256-Suq14YRw/MReDRvO/TQqjpZvpzAEDnHUyVbQj0BPT4c=";
rev = "d3fb99d6654325ec46277cfdb589f89316bed701";
hash = "sha256-WP0rWO9Wbs/09wTY8IlIUybnVUnwiNdXD9JgsoVG4rM=";
};

patches = [
# TODO: Remove on next stable release.
(substituteAll {
src = ./inject-git-commit.patch;
gitCommit = lib.substring 0 7 src.rev;
gitBranch = "master";
})
];

depsBuildBuild = [
pkg-config
];
Expand All @@ -29,9 +39,7 @@ stdenv.mkDerivation rec {
systemd libGL libX11
];

mesonFlags = [ "-Dxwayland=${lib.boolToString (xwayland != null)}" ];

postFixup = lib.optionalString (xwayland != null) ''
postFixup = lib.optionalString wlroots.enableXWayland ''
wrapProgram $out/bin/cage --prefix PATH : "${xwayland}/bin"
'';

Expand Down
23 changes: 23 additions & 0 deletions pkgs/applications/window-managers/cage/inject-git-commit.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
diff --git a/meson.build b/meson.build
index 4c0cbe280f..d4479741c8 100644
--- a/meson.build
+++ b/meson.build
@@ -68,14 +68,12 @@

version = '@0@'.format(meson.project_version())
git = find_program('git', native: true, required: false)
-if git.found()
- git_commit = run_command([git, 'rev-parse', '--short', 'HEAD'], check: false)
- git_branch = run_command([git, 'rev-parse', '--abbrev-ref', 'HEAD'], check: false)
- if git_commit.returncode() == 0 and git_branch.returncode() == 0
+if true
+ if true
version = '@0@-@1@ (branch \'@2@\')'.format(
meson.project_version(),
- git_commit.stdout().strip(),
- git_branch.stdout().strip(),
+ '@gitCommit@'.strip(),
+ '@gitBranch@'.strip(),
)
endif
endif
13 changes: 0 additions & 13 deletions pkgs/development/libraries/wlroots/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
, mesa
, xorg
, libpng
, ffmpeg_4
, ffmpeg
, hwdata
, seatd
Expand Down Expand Up @@ -113,18 +112,6 @@ let

in
rec {
wlroots_0_16 = generic {
version = "0.16.2";
hash = "sha256-JeDDYinio14BOl6CbzAPnJDOnrk4vgGNMN++rcy2ItQ=";
postPatch = ''
substituteInPlace backend/drm/meson.build \
--replace /usr/share/hwdata/ ${hwdata}/share/hwdata/
'';
extraBuildInputs = [
ffmpeg_4
];
};

wlroots_0_17 = generic {
version = "0.17.4";
hash = "sha256-AzmXf+HMX/6VAr0LpfHwfmDB9dRrrLQHt7l35K98MVo=";
Expand Down
1 change: 1 addition & 0 deletions pkgs/top-level/aliases.nix
Original file line number Diff line number Diff line change
Expand Up @@ -1545,6 +1545,7 @@ mapAliases ({
wkhtmltopdf-bin = wkhtmltopdf; # Added 2024-07-17
wlroots_0_14 = throw "'wlroots_0_14' has been removed in favor of newer versions"; # Added 2023-07-29
wlroots_0_15 = throw "'wlroots_0_15' has been removed in favor of newer versions"; # Added 2024-03-28
wlroots_0_16 = throw "'wlroots_0_16' has been removed in favor of newer versions"; # Added 2024-07-14
wlroots = wlroots_0_18; # wlroots is unstable, we must keep depending on 'wlroots_0_*', convert to package after a stable(1.x) release
wordpress6_1 = throw "'wordpress6_1' has been removed in favor of the latest version"; # Added 2023-10-10
wordpress6_2 = throw "'wordpress6_2' has been removed in favor of the latest version"; # Added 2023-10-10
Expand Down
3 changes: 1 addition & 2 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -29444,7 +29444,7 @@ with pkgs;
cardo = callPackage ../data/fonts/cardo { };

cage = callPackage ../applications/window-managers/cage {
wlroots = wlroots_0_16;
wlroots = wlroots_0_17;
};

calf = callPackage ../applications/audio/calf {
Expand Down Expand Up @@ -31174,7 +31174,6 @@ with pkgs;
super-productivity = callPackage ../applications/office/super-productivity { };

inherit (callPackages ../development/libraries/wlroots {})
wlroots_0_16
wlroots_0_17
wlroots_0_18;

Expand Down