From 548654ce32bac6d9c9084e6f2754b8240f21fc19 Mon Sep 17 00:00:00 2001 From: Stig Palmquist Date: Sun, 13 Oct 2024 03:34:51 +0200 Subject: [PATCH 1/2] yaffshiv: init at 0-unstable-2024-08-30 --- pkgs/by-name/ya/yaffshiv/package.nix | 32 ++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 pkgs/by-name/ya/yaffshiv/package.nix diff --git a/pkgs/by-name/ya/yaffshiv/package.nix b/pkgs/by-name/ya/yaffshiv/package.nix new file mode 100644 index 000000000000..2b319ad44d0a --- /dev/null +++ b/pkgs/by-name/ya/yaffshiv/package.nix @@ -0,0 +1,32 @@ +{ + lib, + stdenv, + fetchFromGitHub, + python3, +}: + +stdenv.mkDerivation { + pname = "yaffshiv"; + version = "0-unstable-2024-08-30"; + + src = fetchFromGitHub { + owner = "devttys0"; + repo = "yaffshiv"; + rev = "f6f0ef77bf79ca46aaa77bc34eda06e7b55da8e8"; + sha256 = "sha256-C43UzkaPKheexvVcKi/Krcik+arPXggWAYMSi9RY5eo="; + }; + + buildInputs = [ python3 ]; + + installPhase = '' + install -D -m755 src/yaffshiv $out/bin/yaffshiv + ''; + + meta = { + description = "Simple YAFFS file system parser and extractor"; + homepage = "https://github.com/devttys0/yaffshiv"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ sgo ]; + mainProgram = "yaffshiv"; + }; +} From 681b468aa241143a9d028a89c1b776d1a5b4e50f Mon Sep 17 00:00:00 2001 From: Stig Palmquist Date: Sun, 13 Oct 2024 03:46:32 +0200 Subject: [PATCH 2/2] binwalk: add yaffshiv for YAFFS support --- pkgs/development/python-modules/binwalk/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/development/python-modules/binwalk/default.nix b/pkgs/development/python-modules/binwalk/default.nix index 024bd4d2dea3..e9586af7cb28 100644 --- a/pkgs/development/python-modules/binwalk/default.nix +++ b/pkgs/development/python-modules/binwalk/default.nix @@ -20,6 +20,7 @@ pyqtgraph, pyqt5, pytestCheckHook, + yaffshiv, visualizationSupport ? false, }: @@ -49,6 +50,7 @@ buildPythonPackage rec { squashfsTools xz pycrypto + yaffshiv ] ++ lib.optionals visualizationSupport [ matplotlib