2023-06-04 08:12:51 +02:00
|
|
|
# Taken from [here](https://github.com/openstenoproject/plover/pull/1461#issuecomment-1094511201)
|
|
|
|
# Wayland version of plover
|
2023-08-13 04:15:32 +02:00
|
|
|
(final: prev: rec {
|
2023-06-04 08:12:51 +02:00
|
|
|
python3Packages = {
|
2023-08-13 04:15:32 +02:00
|
|
|
plover-stroke = final.python3Packages.buildPythonPackage rec {
|
2023-06-04 08:12:51 +02:00
|
|
|
pname = "plover_stroke";
|
|
|
|
version = "1.0.1";
|
2023-08-13 04:15:32 +02:00
|
|
|
src = prev.python3Packages.fetchPypi {
|
2023-06-04 08:12:51 +02:00
|
|
|
inherit pname version;
|
|
|
|
sha256 = "t+ZM0oDEwitFDC1L4due5IxCWEPzJbF3fi27HDyto8Q=";
|
|
|
|
};
|
|
|
|
};
|
2023-08-13 04:15:32 +02:00
|
|
|
rtf-tokenize = final.python3Packages.buildPythonPackage rec {
|
2023-06-04 08:12:51 +02:00
|
|
|
pname = "rtf_tokenize";
|
|
|
|
version = "1.0.0";
|
2023-08-13 04:15:32 +02:00
|
|
|
src = prev.python3Packages.fetchPypi {
|
2023-06-04 08:12:51 +02:00
|
|
|
inherit pname version;
|
|
|
|
sha256 = "XD3zkNAEeb12N8gjv81v37Id3RuWroFUY95+HtOS1gg=";
|
|
|
|
};
|
|
|
|
};
|
2023-08-13 04:15:32 +02:00
|
|
|
pywayland_0_4_7 = prev.python3Packages.pywayland.overridePythonAttrs
|
2023-06-04 08:12:51 +02:00
|
|
|
(oldAttrs: rec {
|
|
|
|
pname = "pywayland";
|
|
|
|
version = "0.4.7";
|
2023-08-13 04:15:32 +02:00
|
|
|
src = prev.python3Packages.fetchPypi {
|
2023-06-04 08:12:51 +02:00
|
|
|
inherit pname version;
|
|
|
|
sha256 = "0IMNOPTmY22JCHccIVuZxDhVr41cDcKNkx8bp+5h2CU=";
|
|
|
|
};
|
|
|
|
});
|
2023-08-13 04:15:32 +02:00
|
|
|
} // prev.python3Packages;
|
|
|
|
plover.dev = prev.plover.dev.overridePythonAttrs
|
2023-06-04 08:12:51 +02:00
|
|
|
(oldAttrs: {
|
2023-08-13 04:15:32 +02:00
|
|
|
src = final.fetchFromGitHub {
|
2023-06-04 08:12:51 +02:00
|
|
|
owner = "openstenoproject";
|
|
|
|
repo = "plover";
|
|
|
|
rev = "fd5668a3ad9bd091289dd2e5e8e2c1dec063d51f";
|
|
|
|
sha256 = "2xvcNcJ07q4BIloGHgmxivqGq1BuXwZY2XWPLbFrdXg=";
|
|
|
|
};
|
|
|
|
propagatedBuildInputs = oldAttrs.propagatedBuildInputs
|
|
|
|
++ [
|
|
|
|
python3Packages.plover-stroke
|
|
|
|
python3Packages.rtf-tokenize
|
|
|
|
python3Packages.pywayland_0_4_7
|
|
|
|
];
|
|
|
|
nativeBuildInputs = (oldAttrs.nativeBuildInputs or [ ]) ++ [
|
2023-08-13 04:15:32 +02:00
|
|
|
final.pkg-config
|
2023-06-04 08:12:51 +02:00
|
|
|
];
|
|
|
|
doCheck = false; # TODO: get tests working
|
|
|
|
postPatch = ''
|
|
|
|
sed -i /PyQt5/d setup.cfg
|
|
|
|
substituteInPlace plover_build_utils/setup.py \
|
2023-08-13 04:15:32 +02:00
|
|
|
--replace "/usr/share/wayland/wayland.xml" "${final.wayland}/share/wayland/wayland.xml"
|
2023-06-04 08:12:51 +02:00
|
|
|
'';
|
|
|
|
});
|
|
|
|
})
|