From e84326b6b7b9b85c269fb622f8bddff82f42c421 Mon Sep 17 00:00:00 2001 From: natsukium Date: Sat, 2 Nov 2024 20:31:03 +0900 Subject: [PATCH 1/2] python312Packages.yaramod: 4.0.0 -> 4.0.1 Diff: https://github.com/avast/yaramod/compare/refs/tags/v4.0.0...v4.0.1 Changelog: https://github.com/avast/yaramod/blob/v4.0.1/CHANGELOG.md --- pkgs/development/python-modules/yaramod/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/yaramod/default.nix b/pkgs/development/python-modules/yaramod/default.nix index 3bf6ba1b7546..f65b34047596 100644 --- a/pkgs/development/python-modules/yaramod/default.nix +++ b/pkgs/development/python-modules/yaramod/default.nix @@ -21,7 +21,7 @@ let in buildPythonPackage rec { pname = "yaramod"; - version = "4.0.0"; + version = "4.0.1"; format = "setuptools"; disabled = pythonOlder "3.7"; @@ -30,7 +30,7 @@ buildPythonPackage rec { owner = "avast"; repo = pname; rev = "refs/tags/v${version}"; - hash = "sha256-YbsNFtDk5u5UyTsS1aGKUv/HWYxEwERinZ3G84/mC9o="; + hash = "sha256-EkGG3J84mTFnor1YX9B1TyjvW6mCCF/AH904DaVX+VU="; }; postPatch = '' From ff8466cb40c40e2b430340326c83a623b2e9cd02 Mon Sep 17 00:00:00 2001 From: natsukium Date: Sat, 2 Nov 2024 22:53:43 +0900 Subject: [PATCH 2/2] python312Packages.yaramod: refactor --- .../python-modules/yaramod/default.nix | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/yaramod/default.nix b/pkgs/development/python-modules/yaramod/default.nix index f65b34047596..87cd9ffcee7f 100644 --- a/pkgs/development/python-modules/yaramod/default.nix +++ b/pkgs/development/python-modules/yaramod/default.nix @@ -5,10 +5,10 @@ fetchFromGitHub, pytestCheckHook, libxcrypt, - pythonOlder, gtest, pybind11, nlohmann_json, + setuptools, }: let @@ -22,13 +22,11 @@ in buildPythonPackage rec { pname = "yaramod"; version = "4.0.1"; - format = "setuptools"; - - disabled = pythonOlder "3.7"; + pyproject = true; src = fetchFromGitHub { owner = "avast"; - repo = pname; + repo = "yaramod"; rev = "refs/tags/v${version}"; hash = "sha256-EkGG3J84mTFnor1YX9B1TyjvW6mCCF/AH904DaVX+VU="; }; @@ -48,12 +46,16 @@ buildPythonPackage rec { nativeBuildInputs = [ cmake pog - gtest ]; - setupPyBuildFlags = [ "--with-unit-tests" ]; + build-system = [ setuptools ]; - checkInputs = [ pytestCheckHook ]; + env.ENV_YARAMOD_BUILD_WITH_UNIT_TESTS = true; + + nativeCheckInputs = [ + gtest + pytestCheckHook + ]; pytestFlagsArray = [ "tests/" ];