diff options
author | Jan Tojnar <jtojnar@gmail.com> | 2021-05-01 18:41:50 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-01 18:41:50 +0200 |
commit | 1733bade1a4abe99b5d0dc0d36ee3b5501b9359a (patch) | |
tree | 1a2e66795ed240051e8939fd528729696f19cc80 /pkgs/applications/misc | |
parent | 17af7a98d2e7dfdfdae5292b8dbd7bab28eeaf8d (diff) | |
parent | 31a32eeed3f11fca7475cd5f9746081033856132 (diff) |
Merge pull request #121226 from zhaofengli/librem-take2
phosh: init at 0.10.2
Diffstat (limited to 'pkgs/applications/misc')
-rw-r--r-- | pkgs/applications/misc/feedbackd/default.nix | 5 | ||||
-rw-r--r-- | pkgs/applications/misc/phoc/default.nix | 84 |
2 files changed, 89 insertions, 0 deletions
diff --git a/pkgs/applications/misc/feedbackd/default.nix b/pkgs/applications/misc/feedbackd/default.nix index 34119c2006d44..1cf2fee371044 100644 --- a/pkgs/applications/misc/feedbackd/default.nix +++ b/pkgs/applications/misc/feedbackd/default.nix @@ -41,6 +41,11 @@ stdenv.mkDerivation rec { json-glib ]; + postInstall = '' + mkdir -p $out/lib/udev/rules.d + sed "s|/usr/libexec/|$out/libexec/|" < $src/debian/feedbackd.udev > $out/lib/udev/rules.d/90-feedbackd.rules + ''; + meta = with lib; { description = "A daemon to provide haptic (and later more) feedback on events"; homepage = "https://source.puri.sm/Librem5/feedbackd"; diff --git a/pkgs/applications/misc/phoc/default.nix b/pkgs/applications/misc/phoc/default.nix new file mode 100644 index 0000000000000..6ef88fb07c65f --- /dev/null +++ b/pkgs/applications/misc/phoc/default.nix @@ -0,0 +1,84 @@ +{ lib +, stdenv +, fetchFromGitLab +, fetchpatch +, meson +, ninja +, pkg-config +, python3 +, wrapGAppsHook +, libinput +, gnome3 +, glib +, gtk3 +, wayland +, libdrm +, libxkbcommon +, wlroots +}: + +let + phocWlroots = wlroots.overrideAttrs (old: { + patches = (old.patches or []) ++ [ + # Temporary fix. Upstream report: https://source.puri.sm/Librem5/phosh/-/issues/422 + (fetchpatch { + name = "0001-Revert-layer-shell-error-on-0-dimension-without-anch.patch"; + url = "https://gitlab.alpinelinux.org/alpine/aports/-/raw/78fde4aaf1a74eb13a3f083cb6dfb29f578c3265/community/wlroots/0001-Revert-layer-shell-error-on-0-dimension-without-anch.patch"; + sha256 = "1zjn7mwdj21z0jsc2mz90cnrzk97yqkiq58qqgpjav4h4dgpfb38"; + }) + # To fix missing header `EGL/eglmesaext.h` dropped upstream + (fetchpatch { + name = "0002-stop-including-eglmesaext-h.patch"; + url = "https://github.com/swaywm/wlroots/commit/e18599b05e0f0cbeba11adbd489e801285470eab.patch"; + sha256 = "17ax4dyk0584yhs3lq8ija5bkainjf7psx9c9r50cr4jm9c0i37l"; + }) + ]; + }); +in stdenv.mkDerivation rec { + pname = "phoc"; + version = "0.7.0"; + + src = fetchFromGitLab { + domain = "source.puri.sm"; + owner = "Librem5"; + repo = pname; + rev = "v${version}"; + sha256 = "0afiyr2slg38ksrqn19zygsmjy9k5bpwv6n7zjas3s5djr6hch45"; + }; + + nativeBuildInputs = [ + meson + ninja + pkg-config + python3 + wrapGAppsHook + ]; + + buildInputs = [ + libdrm.dev + libxkbcommon + libinput + glib + gtk3 + gnome3.gnome-desktop + # For keybindings settings schemas + gnome3.mutter + wayland + phocWlroots + ]; + + mesonFlags = ["-Dembed-wlroots=disabled"]; + + postPatch = '' + chmod +x build-aux/post_install.py + patchShebangs build-aux/post_install.py + ''; + + meta = with lib; { + description = "Wayland compositor for mobile phones like the Librem 5"; + homepage = "https://source.puri.sm/Librem5/phoc"; + license = licenses.gpl3Plus; + maintainers = with maintainers; [ archseer masipcat zhaofengli ]; + platforms = platforms.linux; + }; +} |