11 buildPythonPackage rec {
16 disabled = pythonOlder "3.7";
18 src = fetchFromGitHub {
22 hash = "sha256-kX89fMXqrEvhMAAjqKHzHmrYizKBt1uCWMOJtFNNhy4=";
25 build-system = [ setuptools ];
27 doCheck = stdenv.hostPlatform.system == "x86_64-linux" && stdenv.hostPlatform.isGnu;
30 patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" test/external_tools/readelf
31 ${python.interpreter} test/run_all_unittests.py
32 ${python.interpreter} test/run_examples_test.py
33 ${python.interpreter} test/run_readelf_tests.py --parallel
36 pythonImportsCheck = [ "elftools" ];
39 description = "Python library for analyzing ELF files and DWARF debugging information";
40 homepage = "https://github.com/eliben/pyelftools";
41 changelog = "https://github.com/eliben/pyelftools/blob/v${version}/CHANGES";
42 license = with lib.licenses; [
43 # Public domain with Unlicense waiver.
45 # pyelftools bundles construct library that is licensed under MIT license.
46 # See elftools/construct/{LICENSE,README} in the source code.
49 maintainers = with lib.maintainers; [
53 mainProgram = "readelf.py";