git.iko.soy/typeable/nixpkgs
on master help sign in
python3Packages.awscrt: add pythonImportsCheck
commitb74e0ecf6d4b2b18afc8c919f45470210a411afa authorFabian Affolter <mail@fabian-affolter.ch> dateSat 12 Feb 2022, 10:31 (5 years ago) parent1630b52
1 file changed+38−12
pkgs/development/python-modules/awscrt/default.nix+38−12
pkgs/development/python-modules/awscrt/default.nix+38−12
@@ -1,30 +1,56 @@
1−{ lib, buildPythonPackage, fetchPypi, cmake, perl, stdenv, gcc10, CoreFoundation, Security }:
1+{ lib
2+, buildPythonPackage
3+, fetchPypi
4+, cmake
5+, perl
6+, stdenv
7+, gcc10
8+, CoreFoundation
9+, Security
10+, pythonOlder
11+}:
212
313buildPythonPackage rec {
414 pname = "awscrt";
515 version = "0.13.3";
16+ format = "setuptools";
617
7− buildInputs = lib.optionals stdenv.isDarwin [ CoreFoundation Security ];
18+ disabled = pythonOlder "3.6";
19+
20+ src = fetchPypi {
21+ inherit pname version;
22+ hash = "sha256-1GaKDpOGX/YbM4rByTw0nYgwHYFvOLHZ0GRvanX3vAU=";
23+ };
24+
25+ buildInputs = lib.optionals stdenv.isDarwin [
26+ CoreFoundation
27+ Security
28+ ];
829
930 # Required to suppress -Werror
1031 # https://github.com/NixOS/nixpkgs/issues/39687
11− hardeningDisable = lib.optional stdenv.cc.isClang "strictoverflow";
12−
13− nativeBuildInputs = [ cmake ] ++
14− # gcc <10 is not supported, LLVM on darwin is just fine
15− lib.optionals (!stdenv.isDarwin && stdenv.isAarch64) [ gcc10 perl ];
32+ hardeningDisable = lib.optionals stdenv.cc.isClang [
33+ "strictoverflow"
34+ ];
35+
36+ # gcc <10 is not supported, LLVM on darwin is just fine
37+ nativeBuildInputs = [
38+ cmake
39+ ] ++ lib.optionals (!stdenv.isDarwin && stdenv.isAarch64) [
40+ gcc10
41+ perl
42+ ];
1643
1744 dontUseCmakeConfigure = true;
1845
46+ pythonImportsCheck = [
47+ "awscrt"
48+ ];
49+
1950 # Unable to import test module
2051 # https://github.com/awslabs/aws-crt-python/issues/281
2152 doCheck = false;
2253
23− src = fetchPypi {
24− inherit pname version;
25− sha256 = "sha256-1GaKDpOGX/YbM4rByTw0nYgwHYFvOLHZ0GRvanX3vAU=";
26− };
27−
2854 meta = with lib; {
2955 homepage = "https://github.com/awslabs/aws-crt-python";
3056 description = "Python bindings for the AWS Common Runtime";