lol
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

python39Packages.bsddb3: disable on Python 3.10+, remove distutils usage

authored by

kenshin and committed by
Sandro Jäckel
10e9deb7 92fd43bd

+15 -7
+15 -7
pkgs/development/python-modules/bsddb3/default.nix
··· 1 1 { 2 2 lib, 3 3 buildPythonPackage, 4 + pythonAtLeast, 5 + python, 4 6 fetchPypi, 5 7 setuptools, 6 8 pkgs, 7 - python, 8 - pythonOlder, 9 9 }: 10 10 11 11 buildPythonPackage rec { ··· 22 22 23 23 buildInputs = [ pkgs.db ]; 24 24 25 - doCheck = pythonOlder "3.12"; # distutils usage 26 - 27 - checkPhase = '' 28 - ${python.interpreter} test.py 29 - ''; 25 + # See : https://github.com/NixOS/nixpkgs/pull/311198#discussion_r1599257522 26 + # More details here : https://www.jcea.es/programacion/pybsddb.htm 27 + disabled = pythonAtLeast "3.10"; 30 28 31 29 # Path to database need to be set. 32 30 # Somehow the setup.py flag is not propagated. ··· 34 32 # We can also use a variable 35 33 preConfigure = '' 36 34 export BERKELEYDB_DIR=${pkgs.db.dev}; 35 + ''; 36 + 37 + postPatch = '' 38 + substituteInPlace test3.py \ 39 + --replace-fail "from distutils.util import get_platform" "from sysconfig import get_platform" \ 40 + --replace-fail "sys.config[0:3]" "sys.implementation.cache_tag" 41 + ''; 42 + 43 + checkPhase = '' 44 + ${python.interpreter} test.py 37 45 ''; 38 46 39 47 meta = with lib; {