Unverified Commit 0d5e4264 authored by Martin Weinelt's avatar Martin Weinelt
Browse files

python312Packages.python-snap7: convert to pep517 build

parent b075f35a
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -10,7 +10,7 @@
buildPythonPackage rec {
  pname = "python-snap7";
  version = "1.4.1";
  format = "setuptools";
  pyproject = true;

  disabled = pythonOlder "3.6";

@@ -21,14 +21,14 @@ buildPythonPackage rec {
    hash = "sha256-CqLG5/U2k7WdZL5LfcFAnV1Q8HcIU7l36gi51lgB39s=";
  };

  propagatedBuildInputs = [ setuptools ];

  prePatch = ''
    substituteInPlace snap7/common.py \
      --replace "lib_location = None" "lib_location = '${snap7}/lib/libsnap7.so'"
  '';

  # Tests require root privileges to open privilaged ports
  build-system = [ setuptools ];

  # Tests require root privileges to open privileged ports
  doCheck = false;

  pythonImportsCheck = [