mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-12 03:56:17 +03:00
pythonPackages.binwalk: refactor move to python-modules
This commit is contained in:
parent
9d00ad43f5
commit
b14225b37b
37
pkgs/development/python-modules/binwalk/default.nix
Normal file
37
pkgs/development/python-modules/binwalk/default.nix
Normal file
@ -0,0 +1,37 @@
|
||||
{ stdenv
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, zlib
|
||||
, xz
|
||||
, ncompress
|
||||
, gzip
|
||||
, bzip2
|
||||
, gnutar
|
||||
, p7zip
|
||||
, cabextract
|
||||
, lzma
|
||||
, pycrypto
|
||||
, pyqtgraph ? null }:
|
||||
|
||||
let visualizationSupport = (pyqtgraph != null);
|
||||
in
|
||||
buildPythonPackage rec {
|
||||
name = "binwalk-${version}";
|
||||
version = "2.1.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "devttys0";
|
||||
repo = "binwalk";
|
||||
rev = "291a03595d17f848c73b74cb6ca508da782cd8f7";
|
||||
sha256 = "0grid93yz6i6jb2zggrqncp5awdf7qi88j5y2k7dq0k9r6b8zydw";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [ zlib xz ncompress gzip bzip2 gnutar p7zip cabextract lzma pycrypto ]
|
||||
++ stdenv.lib.optional visualizationSupport pyqtgraph;
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = "http://binwalk.org";
|
||||
description = "A tool for searching a given binary image for embedded files";
|
||||
maintainers = [ maintainers.koral ];
|
||||
};
|
||||
}
|
@ -1035,33 +1035,11 @@ in {
|
||||
|
||||
bibtexparser = callPackage ../development/python-modules/bibtexparser { };
|
||||
|
||||
binwalk_fun = { visualizationSupport ? false, pyqtgraph ? null }:
|
||||
assert visualizationSupport -> pyqtgraph != null;
|
||||
binwalk = callPackage ../development/python-modules/binwalk { };
|
||||
|
||||
buildPythonPackage rec {
|
||||
name = "binwalk-${version}";
|
||||
version = "2.1.1";
|
||||
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "devttys0";
|
||||
repo = "binwalk";
|
||||
rev = "291a03595d17f848c73b74cb6ca508da782cd8f7";
|
||||
sha256 = "0grid93yz6i6jb2zggrqncp5awdf7qi88j5y2k7dq0k9r6b8zydw";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = with stdenv.lib; with pkgs; [ zlib xz ncompress gzip bzip2 gnutar p7zip cabextract lzma self.pycrypto ]
|
||||
++ optional visualizationSupport pyqtgraph;
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = "http://binwalk.org";
|
||||
description = "A tool for searching a given binary image for embedded files";
|
||||
platforms = platforms.all;
|
||||
maintainers = [ maintainers.koral ];
|
||||
};
|
||||
};
|
||||
|
||||
binwalk = self.binwalk_fun { };
|
||||
binwalk-full = self.binwalk_fun { visualizationSupport = true; pyqtgraph = self.pyqtgraph; };
|
||||
binwalk-full = appendToName "full" (self.binwalk.override {
|
||||
pyqtgraph = self.pyqtgraph;
|
||||
});
|
||||
|
||||
bitmath = callPackage ../development/python-modules/bitmath { };
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user