File tree Expand file tree Collapse file tree 5 files changed +143
-12
lines changed
development/python-modules Expand file tree Collapse file tree 5 files changed +143
-12
lines changed Original file line number Diff line number Diff line change 1+ {
2+ lib ,
3+ stdenv ,
4+ fetchFromGitHub ,
5+ fetchpatch ,
6+ meson ,
7+ pkg-config ,
8+ ninja ,
9+ c-stdaux ,
10+ } :
11+
12+ stdenv . mkDerivation rec {
13+ pname = "c-siphash" ;
14+ version = "1.1.0" ;
15+
16+ src = fetchFromGitHub {
17+ owner = "c-util" ;
18+ repo = "c-siphash" ;
19+ tag = "v${ version } " ;
20+ hash = "sha256-S5eAlLR6p0Tpd6aYPGGGOH1sCGOyflVyhICi2pYt/8U=" ;
21+ } ;
22+
23+ nativeBuildInputs = [
24+ meson
25+ pkg-config
26+ ninja
27+ ] ;
28+
29+ propagatedBuildInputs = [ c-stdaux ] ;
30+
31+ doCheck = true ;
32+
33+ meta = {
34+ homepage = "https://github.com/c-util/c-siphash" ;
35+ description = "Streaming-capable SipHash Implementation" ;
36+ changelog = "https://github.com/c-util/c-siphash/releases/tag/${ src . tag } " ;
37+ license = with lib . licenses ; [
38+ asl20
39+ lgpl2Plus
40+ ] ;
41+ maintainers = with lib . maintainers ; [ qbisi ] ;
42+ } ;
43+ }
Original file line number Diff line number Diff line change 1+ {
2+ lib ,
3+ stdenv ,
4+ fetchFromGitHub ,
5+ meson ,
6+ ninja ,
7+ } :
8+
9+ stdenv . mkDerivation rec {
10+ pname = "c-stdaux" ;
11+ version = "1.5.0" ;
12+
13+ src = fetchFromGitHub {
14+ owner = "c-util" ;
15+ repo = "c-stdaux" ;
16+ tag = "v${ version } " ;
17+ hash = "sha256-MsnuEyVCmOIr/q6I1qyPsNXp48jxIEcXoYLHbOAZtW0=" ;
18+ } ;
19+
20+ nativeBuildInputs = [
21+ meson
22+ ninja
23+ ] ;
24+
25+ # Assertion failed: (false && "!__builtin_constant_p(c_align_to(16, non_constant_expr ? 8 : 16))"),
26+ # function test_basic_gnuc, file ../src/test-basic.c, line 548.
27+ doCheck = ! stdenv . hostPlatform . isDarwin ;
28+
29+ meta = {
30+ homepage = "https://github.com/c-util/c-stdaux" ;
31+ description = "Auxiliary macros and functions for the C standard library" ;
32+ changelog = "https://github.com/c-util/c-stdaux/releases/tag/${ src . tag } " ;
33+ license = with lib . licenses ; [
34+ asl20
35+ lgpl2Plus
36+ ] ;
37+ maintainers = with lib . maintainers ; [ qbisi ] ;
38+ } ;
39+ }
Original file line number Diff line number Diff line change 88 pytestCheckHook ,
99 pythonOlder ,
1010 typing-extensions ,
11+ siphash24 ,
1112} :
1213
1314buildPythonPackage rec {
@@ -31,25 +32,19 @@ buildPythonPackage rec {
3132
3233 optional-dependencies = {
3334 numpy = [ numpy ] ;
34- # siphash = [ siphash ];
35+ siphash = [ siphash24 ] ;
3536 } ;
3637
37- nativeCheckInputs = [ pytestCheckHook ] ;
38+ nativeCheckInputs = [
39+ pytestCheckHook
40+ ] ++ optional-dependencies . siphash ;
3841
3942 pythonImportsCheck = [
4043 "pytools"
4144 "pytools.batchjob"
4245 "pytools.lex"
4346 ] ;
4447
45- disabledTests = [
46- # siphash is not available
47- "test_class_hashing"
48- "test_dataclass_hashing"
49- "test_datetime_hashing"
50- "test_hash_function"
51- ] ;
52-
5348 meta = {
5449 description = "Miscellaneous Python lifesavers" ;
5550 homepage = "https://github.com/inducer/pytools/" ;
Original file line number Diff line number Diff line change 1+ {
2+ lib ,
3+ fetchFromGitHub ,
4+ buildPythonPackage ,
5+ meson ,
6+ meson-python ,
7+ cython ,
8+ pkg-config ,
9+ c-siphash ,
10+ pytestCheckHook ,
11+ } :
12+
13+ buildPythonPackage rec {
14+ version = "1.7" ;
15+ pname = "siphash24" ;
16+ pyproject = true ;
17+
18+ src = fetchFromGitHub {
19+ owner = "dnicolodi" ;
20+ repo = "python-siphash24" ;
21+ tag = "v${ version } " ;
22+ hash = "sha256-/7XrRD4e7jLTUY/8mBbJ4dSo5P6pj8GRpSreIOZpKp0=" ;
23+ } ;
24+
25+ nativeBuildInputs = [ pkg-config ] ;
26+
27+ build-system = [
28+ meson
29+ meson-python
30+ cython
31+ ] ;
32+
33+ buildInputs = [
34+ c-siphash
35+ ] ;
36+
37+ pythonImportsCheck = [
38+ "siphash24"
39+ ] ;
40+
41+ pytestFlagsArray = [ "test.py" ] ;
42+
43+ nativeCheckInputs = [ pytestCheckHook ] ;
44+
45+ meta = {
46+ homepage = "https://github.com/dnicolodi/python-siphash24" ;
47+ description = "Streaming-capable SipHash Implementation" ;
48+ changelog = "https://github.com/dnicolodi/python-siphash24/releases/tag/${ src . tag } " ;
49+ license = lib . licenses . lgpl2Plus ;
50+ maintainers = with lib . maintainers ; [ qbisi ] ;
51+ } ;
52+ }
Original file line number Diff line number Diff line change @@ -15265,10 +15265,12 @@ self: super: with self; {
1526515265
1526615266 sip = callPackage ../development/python-modules/sip { };
1526715267
15268- siphashc = callPackage ../development/python-modules/siphashc { };
15269-
1527015268 sip4 = callPackage ../development/python-modules/sip/4.x.nix { };
1527115269
15270+ siphash24 = callPackage ../development/python-modules/siphash24 { };
15271+
15272+ siphashc = callPackage ../development/python-modules/siphashc { };
15273+
1527215274 sipyco = callPackage ../development/python-modules/sipyco { };
1527315275
1527415276 sirius = toPythonModule (pkgs.sirius.override {
You can’t perform that action at this time.
0 commit comments