@@ -1,6 +1,6 @@
11name: entropy
22
3−version: 0.4.1.7
3+version: 0.4.1.8
44description: A mostly platform independent method to obtain cryptographically strong entropy
55 (RDRAND, urandom, CryptAPI, and patches welcome)
66 Users looking for cryptographically strong (number-theoretically
@@ -24,6 +24,12 @@ tested-with: GHC == 8.2.2
2424-- data-files:
2525extra-source-files: ./cbits/getrandom.c ./cbits/random_initialized.c ./cbits/rdrand.c, ./cbits/rdrand.h, README.md
2626
27+Flag DoNotGetEntropy
28+ Description: Avoid use of the getentropy() *nix function. By default getentropy will be used
29+ if detected during compilation (this plays poorly with cross compilation).
30+ Default: False
31+ Manual: True
32+
2733custom-setup
2834 setup-depends: Cabal >= 1.10 && < 3.7
2935 , base < 5
@@ -72,6 +78,9 @@ library
7278 Build-Depends: unix
7379 c-sources: cbits/getrandom.c cbits/random_initialized.c
7480 }
81+ if flag(DoNotGetEntropy) {
82+ cc-options: -DDO_NOT_USE_GET_ENTROPY
83+ }
7584
7685
7786source-repository head