nixpkgs/pkgs/by-name/am/amoco/package.nix
aleksana 571c71e6f7 treewide: migrate packages to pkgs/by-name, take 1
We are migrating packages that meet below requirements:

1. using `callPackage`
2. called path is a directory
3. overriding set is empty (`{ }`)
4. not containing path expressions other than relative path (to
makenixpkgs-vet happy)
5. not referenced by nix files outside of the directory, other
than`pkgs/top-level/all-packages.nix`
6. not referencing nix files outside of the directory
7. not referencing `default.nix` (since it's changed to `package.nix`)
8. `outPath` doesn't change after migration

The tool is here: https://github.com/Aleksanaa/by-name-migrate.
2024-11-09 20:04:51 +08:00

73 lines
1.2 KiB
Nix

{ lib
, fetchFromGitHub
, python3
}:
python3.pkgs.buildPythonApplication rec {
pname = "amoco";
version = "2.9.8";
format = "setuptools";
src = fetchFromGitHub {
owner = "bdcht";
repo = pname;
rev = "v${version}";
hash = "sha256-3+1ssFyU7SKFJgDYBQY0kVjmTHOD71D2AjnH+4bfLXo=";
};
nativeBuildInputs = with python3.pkgs; [
];
propagatedBuildInputs = with python3.pkgs; [
blessed
click
crysp
grandalf
pyparsing
tqdm
traitlets
];
optional-dependencies = {
app = with python3.pkgs; [
# ccrawl
ipython
prompt-toolkit
pygments
# pyside6
z3-solver
];
};
nativeCheckInputs = with python3.pkgs; [
pytestCheckHook
];
postPatch = ''
substituteInPlace setup.py \
--replace "'pytest-runner'," ""
'';
pythonRelaxDeps = [
"grandalf"
"crysp"
];
pythonImportsCheck = [
"amoco"
];
disabledTests = [
# AttributeError: 'str' object has no attribute '__dict__'
"test_func"
];
meta = with lib; {
description = "Tool for analysing binaries";
mainProgram = "amoco";
homepage = "https://github.com/bdcht/amoco";
license = licenses.gpl2Only;
maintainers = with maintainers; [ fab ];
};
}