diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index 8811bdbc220a..bad8e0af5e28 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -12098,6 +12098,11 @@ githubId = 59313755; name = "Maxim Karasev"; }; + mxmlnkn = { + github = "mxmlnkn"; + githubId = 6842824; + name = "Maximilian Knespel"; + }; myaats = { email = "mats@mats.sh"; github = "Myaats"; diff --git a/pkgs/development/python-modules/indexed-bzip2/default.nix b/pkgs/development/python-modules/indexed-bzip2/default.nix new file mode 100644 index 000000000000..d6c82e3aec9a --- /dev/null +++ b/pkgs/development/python-modules/indexed-bzip2/default.nix @@ -0,0 +1,31 @@ +{ lib +, buildPythonPackage +, fetchPypi +, pythonOlder +}: + +buildPythonPackage rec { + pname = "indexed_bzip2"; + version = "1.5.0"; + format = "setuptools"; + + disabled = pythonOlder "3.6"; + + src = fetchPypi { + inherit pname version; + hash = "sha256-tKf9odadfQZQYJz//vWYpeB99Z8VLg+hEPvfEHXgdnM="; + }; + + # has no tests + doCheck = false; + + pythonImportsCheck = [ "indexed_bzip2" ]; + + meta = with lib; { + description = "Python library for parallel decompression and seeking within compressed bzip2 files"; + homepage = "https://github.com/mxmlnkn/indexed_bzip2"; + license = licenses.mit; # dual MIT and asl20, https://internals.rust-lang.org/t/rationale-of-apache-dual-licensing/8952 + maintainers = with lib.maintainers; [ mxmlnkn ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/development/python-modules/indexed-gzip/default.nix b/pkgs/development/python-modules/indexed-gzip/default.nix new file mode 100644 index 000000000000..73ad916f35f8 --- /dev/null +++ b/pkgs/development/python-modules/indexed-gzip/default.nix @@ -0,0 +1,37 @@ +{ lib +, buildPythonPackage +, fetchPypi +, pythonOlder +, cython +, zlib +}: + +buildPythonPackage rec { + pname = "indexed_gzip"; + version = "1.8.5"; + format = "setuptools"; + + disabled = pythonOlder "3.7"; + + src = fetchPypi { + inherit pname version; + hash = "sha256-h9JgYq9KxmknaRuMgq+5YWA8tUaFk+lclkqdNAnr/cI="; + }; + + nativeBuildInputs = [ cython ]; + + buildInputs = [ zlib ]; + + # Too complicated to get to work, not a simple pytest call. + doCheck = false; + + pythonImportsCheck = [ "indexed_gzip" ]; + + meta = with lib; { + description = "Python library to seek within compressed gzip files"; + homepage = "https://github.com/pauldmccarthy/indexed_gzip"; + license = licenses.zlib; + maintainers = with lib.maintainers; [ mxmlnkn ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/development/python-modules/indexed-zstd/default.nix b/pkgs/development/python-modules/indexed-zstd/default.nix new file mode 100644 index 000000000000..f9d643c8ff49 --- /dev/null +++ b/pkgs/development/python-modules/indexed-zstd/default.nix @@ -0,0 +1,37 @@ +{ lib +, buildPythonPackage +, fetchPypi +, pythonOlder +, cython +, zstd +}: + +buildPythonPackage rec { + pname = "indexed_zstd"; + version = "1.6.0"; + format = "setuptools"; + + disabled = pythonOlder "3.6"; + + src = fetchPypi { + inherit pname version; + hash = "sha256-icCerrv6ihBjSTS4Fsw7qhoA5ha8yegfMVRiIOhTvvY="; + }; + + nativeBuildInputs = [ cython ]; + + buildInputs = [ zstd.dev ]; + + # has no tests + doCheck = false; + + pythonImportsCheck = [ "indexed_zstd" ]; + + meta = with lib; { + description = "Python library to seek within compressed zstd files"; + homepage = "https://github.com/martinellimarco/indexed_zstd"; + license = licenses.mit; + maintainers = with lib.maintainers; [ mxmlnkn ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/development/python-modules/python-xz/default.nix b/pkgs/development/python-modules/python-xz/default.nix new file mode 100644 index 000000000000..b5a2ed4e21f9 --- /dev/null +++ b/pkgs/development/python-modules/python-xz/default.nix @@ -0,0 +1,34 @@ +{ lib +, buildPythonPackage +, fetchPypi +, pythonOlder +, setuptools-scm +}: + +buildPythonPackage rec { + pname = "python-xz"; + version = "0.4.0"; + format = "setuptools"; + + disabled = pythonOlder "3.6"; + + src = fetchPypi { + inherit pname version; + hash = "sha256-OYdGWTtwb6n6xZuMmI6rhgPh/iupGVERwLRSJ6OnfbM="; + }; + + nativeBuildInputs = [ setuptools-scm ]; + + # has no tests + doCheck = false; + + pythonImportsCheck = [ "xz" ]; + + meta = with lib; { + description = "Pure Python library for seeking within compressed xz files"; + homepage = "https://github.com/Rogdham/python-xz"; + license = licenses.mit; + maintainers = with lib.maintainers; [ mxmlnkn ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/development/python-modules/rapidgzip/default.nix b/pkgs/development/python-modules/rapidgzip/default.nix new file mode 100644 index 000000000000..ace2bad62016 --- /dev/null +++ b/pkgs/development/python-modules/rapidgzip/default.nix @@ -0,0 +1,34 @@ +{ lib +, buildPythonPackage +, fetchPypi +, pythonOlder +, nasm +}: + +buildPythonPackage rec { + pname = "rapidgzip"; + version = "0.10.3"; + format = "setuptools"; + + disabled = pythonOlder "3.6"; + + src = fetchPypi { + inherit pname version; + hash = "sha256-gtxF9V7OQb34Z0cCuTh/Lbe1ttCbdaY0zpM3KHHGGuw="; + }; + + nativeBuildInputs = [ nasm ]; + + # has no tests + doCheck = false; + + pythonImportsCheck = [ "rapidgzip" ]; + + meta = with lib; { + description = "Python library for parallel decompression and seeking within compressed gzip files"; + homepage = "https://github.com/mxmlnkn/rapidgzip"; + license = licenses.mit; # dual MIT and asl20, https://internals.rust-lang.org/t/rationale-of-apache-dual-licensing/8952 + maintainers = with lib.maintainers; [ mxmlnkn ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/development/python-modules/ratarmount/default.nix b/pkgs/development/python-modules/ratarmount/default.nix new file mode 100644 index 000000000000..1555dfca2197 --- /dev/null +++ b/pkgs/development/python-modules/ratarmount/default.nix @@ -0,0 +1,37 @@ +{ lib +, buildPythonPackage +, fetchPypi +, pythonOlder +, fusepy +, ratarmountcore +}: + +buildPythonPackage rec { + pname = "ratarmount"; + version = "0.14.0"; + + disabled = pythonOlder "3.6"; + + src = fetchPypi { + inherit pname version; + hash = "sha256-P+p0h+KuOsunPsXbRwxzAhr1XcEqMjQxHeHmA29+pDQ="; + }; + + propagatedBuildInputs = [ ratarmountcore fusepy ]; + + checkPhase = '' + runHook preCheck + + python tests/tests.py + + runHook postCheck + ''; + + meta = with lib; { + description = "Mounts archives as read-only file systems by way of indexing"; + homepage = "https://github.com/mxmlnkn/ratarmount"; + license = licenses.mit; + maintainers = with lib.maintainers; [ mxmlnkn ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/development/python-modules/ratarmountcore/default.nix b/pkgs/development/python-modules/ratarmountcore/default.nix new file mode 100644 index 000000000000..49ffdb17cfa5 --- /dev/null +++ b/pkgs/development/python-modules/ratarmountcore/default.nix @@ -0,0 +1,48 @@ +{ lib +, buildPythonPackage +, fetchgit +, pythonOlder +, pytestCheckHook +, indexed-bzip2 +, indexed-gzip +, indexed-zstd +, python-xz +, rapidgzip +, rarfile +, zstandard # Python bindings +, zstd # System tool +}: + +buildPythonPackage rec { + pname = "ratarmountcore"; + version = "0.6.0"; + + disabled = pythonOlder "3.6"; + + src = fetchgit { + url = "https://github.com/mxmlnkn/ratarmount"; + # The revision is hardcoded for now to fix problems with the tests, which are not worthy of a new release + # tag because releases do not officially contain tests. On the next release, use the commented revision, + # which points to a release tag, instead. + #rev = "core-v${version}"; + rev = "ea43572dfbac4770a27ef2169f72ff73ee4a4ae9"; + hash = "sha256-sPApM5OW+UbujFXHSL4ptMaegajz7FNtXz/KftTlw+U="; + fetchSubmodules = true; + }; + + sourceRoot = "${src.name}/core"; + + propagatedBuildInputs = [ indexed-gzip indexed-bzip2 indexed-zstd python-xz rapidgzip rarfile ]; + + pythonImportsCheck = [ "ratarmountcore" ]; + + nativeCheckInputs = [ pytestCheckHook zstandard zstd ]; + + meta = with lib; { + description = "Library for accessing archives by way of indexing"; + homepage = "https://github.com/mxmlnkn/ratarmount/tree/master/core"; + license = licenses.mit; + maintainers = with lib.maintainers; [ mxmlnkn ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 8efa242c7c22..4ef74d116811 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -9372,6 +9372,8 @@ with pkgs; incron = callPackage ../tools/system/incron { }; + indexed-bzip2 = with python3Packages; toPythonApplication indexed-bzip2; + industrializer = callPackage ../applications/audio/industrializer { }; inetutils = callPackage ../tools/networking/inetutils { }; @@ -12546,6 +12548,8 @@ with pkgs; ramfetch = callPackage ../tools/misc/ramfetch { }; + rapidgzip = with python3Packages; toPythonApplication rapidgzip; + rar = callPackage ../tools/archivers/rar { }; rarcrack = callPackage ../tools/security/rarcrack { }; @@ -12554,6 +12558,8 @@ with pkgs; ratman = callPackage ../tools/networking/ratman { }; + ratarmount = with python3Packages; toPythonApplication ratarmount; + ratools = callPackage ../tools/networking/ratools { }; ratt = callPackage ../applications/misc/ratt { }; diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index a0fd063b3e6e..fdf90d36ba3d 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5254,6 +5254,12 @@ self: super: with self; { incremental = callPackage ../development/python-modules/incremental { }; + indexed-bzip2 = callPackage ../development/python-modules/indexed-bzip2 { }; + + indexed-gzip = callPackage ../development/python-modules/indexed-gzip { inherit (pkgs) zlib; }; + + indexed-zstd = callPackage ../development/python-modules/indexed-zstd { inherit (pkgs) zstd; }; + infinity = callPackage ../development/python-modules/infinity { }; inflect = callPackage ../development/python-modules/inflect { }; @@ -10768,6 +10774,8 @@ self: super: with self; { python-xmp-toolkit = callPackage ../development/python-modules/python-xmp-toolkit { }; + python-xz = callPackage ../development/python-modules/python-xz { }; + python-zbar = callPackage ../development/python-modules/python-zbar { }; pythran = callPackage ../development/python-modules/pythran { @@ -11154,6 +11162,8 @@ self: super: with self; { rapidfuzz-capi = callPackage ../development/python-modules/rapidfuzz-capi { }; + rapidgzip = callPackage ../development/python-modules/rapidgzip { inherit (pkgs) nasm; }; + rapt-ble = callPackage ../development/python-modules/rapt-ble { }; rarfile = callPackage ../development/python-modules/rarfile { @@ -11162,6 +11172,10 @@ self: super: with self; { rasterio = callPackage ../development/python-modules/rasterio { }; + ratarmountcore = callPackage ../development/python-modules/ratarmountcore { inherit (pkgs) zstd; }; + + ratarmount = callPackage ../development/python-modules/ratarmount { }; + ratelim = callPackage ../development/python-modules/ratelim { }; ratelimit = callPackage ../development/python-modules/ratelimit { };