2021-01-25 08:26:54 +00:00
|
|
|
{ lib
|
2018-10-15 17:28:32 +01:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, pkgs
|
2018-11-03 11:40:03 +00:00
|
|
|
, python
|
2018-10-15 17:28:32 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "bsddb3";
|
2020-11-29 10:14:41 +00:00
|
|
|
version = "6.2.9";
|
2018-10-15 17:28:32 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-11-29 10:14:41 +00:00
|
|
|
sha256 = "70d05ec8dc568f42e70fc919a442e0daadc2a905a1cfb7ca77f549d49d6e7801";
|
2018-10-15 17:28:32 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ pkgs.db ];
|
|
|
|
|
2018-11-03 11:40:03 +00:00
|
|
|
checkPhase = ''
|
|
|
|
${python.interpreter} test.py
|
|
|
|
'';
|
2018-10-15 17:28:32 +01:00
|
|
|
|
|
|
|
# Path to database need to be set.
|
|
|
|
# Somehow the setup.py flag is not propagated.
|
|
|
|
#setupPyBuildFlags = [ "--berkeley-db=${pkgs.db}" ];
|
|
|
|
# We can also use a variable
|
|
|
|
preConfigure = ''
|
|
|
|
export BERKELEYDB_DIR=${pkgs.db.dev};
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2018-10-15 17:28:32 +01:00
|
|
|
description = "Python bindings for Oracle Berkeley DB";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://www.jcea.es/programacion/pybsddb.htm";
|
2018-10-15 17:28:32 +01:00
|
|
|
license = with licenses; [ agpl3 ]; # License changed from bsd3 to agpl3 since 6.x
|
|
|
|
maintainers = [ maintainers.costrouc ];
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|