Skip to content
Snippets Groups Projects
Commit 5200203b authored by Jean-Paul Calderone's avatar Jean-Paul Calderone
Browse files

Upstream nixpkgs has upgraded these packages

So we don't have to override them to get a new version anymore.  Also,
upstream has done a better job of integrating them into the overall system
than we have (with respect to other upstream changes).
parent 4a127665
No related branches found
No related tags found
1 merge request!57Remove unnecessary overrides
{ lib, buildPythonPackage, fetchFromGitHub, isPy3k,
six, txaio, twisted, zope_interface, cffi, trollius, futures, cryptography,
mock, pytest,
supportAsyncio ? false
}:
buildPythonPackage rec {
pname = "autobahn";
version = "19.7.1";
src = fetchFromGitHub {
owner = "crossbario";
repo = "autobahn-python";
rev = "v${version}";
sha256 = "1gl2m18s77hlpiglh44plv3k6b965n66ylnxbzgvzcdl9jf3l3q3";
};
propagatedBuildInputs = [ six txaio twisted zope_interface cffi cryptography ] ++
(lib.optionals (!isPy3k) [ futures ]) ++
(lib.optionals (supportAsyncio && !isPy3k) [ trollius ])
;
checkInputs = [ mock pytest ];
checkPhase = ''
runHook preCheck
USE_TWISTED=true py.test $out
runHook postCheck
'';
# XXX Fails for some reason I don't understand.
doCheck = false;
meta = with lib; {
description = "WebSocket and WAMP in Python for Twisted and asyncio.";
homepage = "https://crossbar.io/autobahn";
license = licenses.mit;
maintainers = with maintainers; [ nand0p ];
};
}
{ stdenv
, buildPythonPackage
, fetchFromGitHub
, openssl
, cryptography_vectors
, darwin
, asn1crypto
, packaging
, six
, pythonOlder
, enum34
, ipaddress
, isPyPy
, cffi
, pytest
, pretend
, iso8601
, pytz
, hypothesis
}:
buildPythonPackage rec {
pname = "cryptography";
version = "2.7"; # Also update the hash in vectors.nix
src = fetchFromGitHub {
owner = "pyca";
repo = "cryptography";
rev = "2.7";
sha256 = "145byri5c3b8m6dbhwb6yxrv9jrr652l3z1w16mz205z8dz38qja";
};
outputs = [ "out" "dev" ];
buildInputs = [ openssl ]
++ stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.Security;
propagatedBuildInputs = [
asn1crypto
packaging
six
] ++ stdenv.lib.optional (pythonOlder "3.4") enum34
++ stdenv.lib.optional (pythonOlder "3.3") ipaddress
++ stdenv.lib.optional (!isPyPy) cffi;
checkInputs = [
cryptography_vectors
hypothesis
iso8601
pretend
pytest
pytz
];
checkPhase = ''
py.test --disable-pytest-warnings tests
'';
# IOKit's dependencies are inconsistent between OSX versions, so this is the best we
# can do until nix 1.11's release
__impureHostDeps = [ "/usr/lib" ];
meta = with stdenv.lib; {
description = "A package which provides cryptographic recipes and primitives";
longDescription = ''
Cryptography includes both high level recipes and low level interfaces to
common cryptographic algorithms such as symmetric ciphers, message
digests, and key derivation functions.
Our goal is for it to be your "cryptographic standard library". It
supports Python 2.7, Python 3.4+, and PyPy 5.3+.
'';
homepage = https://github.com/pyca/cryptography;
license = with licenses; [ asl20 bsd3 psfl ];
maintainers = with maintainers; [ primeos ];
};
}
{ buildPythonPackage, fetchPypi, lib, cryptography }:
buildPythonPackage rec {
pname = "cryptography_vectors";
# The test vectors must have the same version as the cryptography package:
version = cryptography.version;
src = fetchPypi {
inherit pname version;
sha256 = "1g38zw90510azyfrj6mxbslx2gp9yrnv5dac0w2819k9ssdznbgi";
};
# No tests included
doCheck = false;
meta = with lib; {
description = "Test vectors for the cryptography package";
homepage = https://cryptography.io/en/latest/development/test-vectors/;
# Source: https://github.com/pyca/cryptography/tree/master/vectors;
license = with licenses; [ asl20 bsd3 ];
maintainers = with maintainers; [ primeos ];
};
}
......@@ -17,13 +17,6 @@ self: super: {
# new tahoe-lafs dependency
eliot = python-super.callPackage ./eliot.nix { };
# new autobahn requires a newer cryptography
cryptography = python-super.callPackage ./cryptography.nix { };
# new cryptography requires a newer cryptography_vectors
cryptography_vectors = python-super.callPackage ./cryptography_vectors.nix { };
# new tahoe-lafs depends on a very recent autobahn for better
# websocket testing features.
autobahn = python-super.callPackage ./autobahn.nix { };
# tahoe-lafs in nixpkgs is packaged as an application! so we have to
# re-package it ourselves as a library.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment