2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
stdenv,
|
|
|
|
fetchFromGitHub,
|
|
|
|
buildPythonPackage,
|
|
|
|
rustPlatform,
|
|
|
|
cargo,
|
|
|
|
pkg-config,
|
|
|
|
rustc,
|
|
|
|
rustfmt,
|
|
|
|
setuptools-rust,
|
|
|
|
openssl,
|
|
|
|
Security,
|
|
|
|
msgpack,
|
2020-12-09 12:39:15 +00:00
|
|
|
}:
|
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
buildPythonPackage rec {
|
2020-12-09 12:39:15 +00:00
|
|
|
pname = "etebase";
|
2023-02-02 18:25:31 +00:00
|
|
|
version = "0.31.6";
|
2020-12-09 12:39:15 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "etesync";
|
|
|
|
repo = "etebase-py";
|
|
|
|
rev = "v${version}";
|
2023-02-02 18:25:31 +00:00
|
|
|
hash = "sha256-T61nPW3wjBRjmJ81w59T1b/Kxrwwqvyj3gILE9OF/5Q=";
|
2020-12-09 12:39:15 +00:00
|
|
|
};
|
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
cargoDeps = rustPlatform.fetchCargoTarball {
|
|
|
|
inherit src;
|
|
|
|
name = "${pname}-${version}";
|
2023-02-02 18:25:31 +00:00
|
|
|
hash = "sha256-wrMNtcaLAsWBVeJbYbYo+Xmobl01lnUbR9NUqqUzUgU=";
|
2021-03-09 03:18:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
format = "pyproject";
|
2020-12-09 12:39:15 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2021-03-09 03:18:52 +00:00
|
|
|
pkg-config
|
2020-12-09 12:39:15 +00:00
|
|
|
rustfmt
|
|
|
|
setuptools-rust
|
2023-05-24 13:37:59 +00:00
|
|
|
rustPlatform.cargoSetupHook
|
|
|
|
cargo
|
|
|
|
rustc
|
|
|
|
];
|
2020-12-09 12:39:15 +00:00
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
buildInputs = [ openssl ] ++ lib.optionals stdenv.isDarwin [ Security ];
|
2020-12-09 12:39:15 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
propagatedBuildInputs = [ msgpack ];
|
2020-12-09 12:39:15 +00:00
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
postPatch = ''
|
|
|
|
# Use system OpenSSL, which gets security updates.
|
|
|
|
substituteInPlace Cargo.toml \
|
|
|
|
--replace ', features = ["vendored"]' ""
|
2020-12-09 12:39:15 +00:00
|
|
|
'';
|
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
pythonImportsCheck = [ "etebase" ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2022-06-16 17:23:12 +00:00
|
|
|
broken = stdenv.isDarwin;
|
2020-12-09 12:39:15 +00:00
|
|
|
homepage = "https://www.etebase.com/";
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Python client library for Etebase";
|
2020-12-09 12:39:15 +00:00
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ _3699n ];
|
|
|
|
};
|
|
|
|
}
|