depot/third_party/nixpkgs/pkgs/development/python-modules/azure-common/default.nix
Default email bb584b27e9 Project import generated by Copybara.
GitOrigin-RevId: 5181d5945eda382ff6a9ca3e072ed6ea9b547fee
2022-04-15 03:41:22 +02:00

38 lines
896 B
Nix

{ lib
, buildPythonPackage
, fetchPypi
, azure-nspkg
, isPyPy
, setuptools
, python
, isPy3k
}:
buildPythonPackage rec {
version = "1.1.28";
pname = "azure-common";
disabled = isPyPy;
src = fetchPypi {
inherit pname version;
extension = "zip";
sha256 = "sha256-SsDNMhTja2obakQmhnIqXYzESWA6qDPz8PQL2oNnBKM=";
};
propagatedBuildInputs = [
azure-nspkg
] ++ lib.optionals (!isPy3k) [ setuptools ]; # need for namespace lookup
postInstall = if isPy3k then "" else ''
echo "__import__('pkg_resources').declare_namespace(__name__)" >> "$out/lib/${python.libPrefix}"/site-packages/azure/__init__.py
'';
doCheck = false;
meta = with lib; {
description = "This is the Microsoft Azure common code";
homepage = "https://github.com/Azure/azure-sdk-for-python";
license = licenses.mit;
maintainers = with maintainers; [ olcai maxwilson ];
};
}