Skip to content

Commit a067a95

Browse files
committed
feat(pkgs/warpd): switch to atuan26/warpd fork at v2.2.0
Switch upstream from rvaiya/warpd to atuan26/warpd v2.2.0. Drop the codesign removal patch (fork already uses || true) and the patch file; replace the Makefile install-target override with an installPhase to handle the versioned binary name (warpd-2.2.0).
1 parent 7b6cdb5 commit a067a95

File tree

2 files changed

+15
-55
lines changed

2 files changed

+15
-55
lines changed

pkgs/darwin/warpd/fix-duplicate-symbols.patch

Lines changed: 0 additions & 34 deletions
This file was deleted.

pkgs/darwin/warpd/package.nix

Lines changed: 15 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -5,40 +5,34 @@
55
}:
66
stdenv.mkDerivation rec {
77
pname = "warpd";
8-
version = "1.3.5";
8+
version = "2.2.0";
99

1010
src = fetchFromGitHub {
11-
owner = "rvaiya";
11+
owner = "atuan26";
1212
repo = "warpd";
1313
rev = "v${version}";
14-
hash = "sha256-YHTQ5N4SZSa3S3sy/lNjarKPkANIuB2khwyOW5TW2vo=";
14+
hash = "sha256-ngWQdGKvHxng0C1LlmYHMWjcH4mzgrEFr6DvEa6LdUE=";
1515
};
1616

1717
postPatch = ''
18-
# Fix duplicate symbol error
19-
sed -i 's/^size_t nr_boxes;$/extern size_t nr_boxes;/' src/platform/macos/macos.h
20-
sed -i '/^size_t nr_screens;$/a size_t nr_boxes;' src/platform/macos/screen.m
21-
22-
# Remove codesign step (not available in Nix sandbox)
23-
sed -i '/\.\/codesign\/sign.sh/d' mk/macos.mk
24-
25-
# Replace the entire install target with a simpler Nix-friendly version
26-
cat >> mk/macos.mk << 'EOF'
27-
28-
install:
29-
mkdir -p $(PREFIX)/bin $(PREFIX)/share/man/man1
30-
install -m644 files/warpd.1.gz $(PREFIX)/share/man/man1/
31-
install -m755 bin/warpd $(PREFIX)/bin/
32-
EOF
18+
# Fix duplicate symbol error (global size_t nr_boxes; in macos.h included by multiple TUs)
19+
sed -i 's/^size_t nr_boxes;$/extern size_t nr_boxes;/' src/platform/macos/macos.h
20+
sed -i '/^size_t nr_screens;$/a size_t nr_boxes;' src/platform/macos/screen.m
3321
'';
3422

35-
# Disable X11 and Wayland support on macOS
3623
makeFlags = [
37-
"PREFIX=$(out)"
3824
"DISABLE_X=1"
3925
"DISABLE_WAYLAND=1"
4026
];
4127

28+
installPhase = ''
29+
runHook preInstall
30+
mkdir -p $out/bin $out/share/man/man1
31+
install -m644 files/warpd.1.gz $out/share/man/man1/
32+
install -m755 bin/warpd-${version} $out/bin/warpd
33+
runHook postInstall
34+
'';
35+
4236
meta = {
4337
description = "A modal keyboard-driven virtual pointer for macOS";
4438
longDescription = ''
@@ -48,7 +42,7 @@ stdenv.mkDerivation rec {
4842
- Grid Mode: Navigate using a recursive grid
4943
- Normal Mode: Vim-like hjkl movement for precise cursor control
5044
'';
51-
homepage = "https://github.com/rvaiya/warpd";
45+
homepage = "https://github.com/atuan26/warpd";
5246
license = lib.licenses.mit;
5347
maintainers = with lib.maintainers; [DivitMittal];
5448
platforms = lib.platforms.darwin;

0 commit comments

Comments
 (0)