2022-12-22 20:49:10 +01:00
{ stdenv , lib , fetchFromGitLab , buildDunePackage
2022-10-18 11:50:56 +02:00
, gmp , pkg-config , dune-configurator
, zarith , integers
2022-03-01 16:42:22 +01:00
, alcotest , bisect_ppx
} :
2022-10-18 11:50:56 +02:00
2023-04-08 07:27:25 +02:00
buildDunePackage ( rec {
2022-10-18 11:50:56 +02:00
pname = " c l a s s _ g r o u p _ v d f " ;
version = " 0 . 0 . 4 " ;
duneVersion = " 3 " ;
src = fetchFromGitLab {
owner = " n o m a d i c - l a b s / c r y p t o g r a p h y " ;
repo = " o c a m l - c h i a - v d f " ;
rev = " v ${ version } " ;
sha256 = " s h a 2 5 6 - K v p n X 2 D T U y f K A R N W H C 2 l L B G H 2 O u 2 G f R K j w 0 5 l u 4 j b B s = " ;
} ;
minimalOCamlVersion = " 4 . 0 8 " ;
nativeBuildInputs = [
gmp
pkg-config
dune-configurator
] ;
2022-03-01 16:42:22 +01:00
buildInputs = [
dune-configurator
] ;
2022-10-18 11:50:56 +02:00
propagatedBuildInputs = [
zarith
integers
] ;
2022-03-01 16:42:22 +01:00
checkInputs = [
2022-10-18 11:50:56 +02:00
alcotest
bisect_ppx
] ;
doCheck = true ;
meta = {
description = " V e r i f i a b l e D e l a y F u n c t i o n s b i n d i n g s t o C h i a ' s V D F " ;
homepage = " h t t p s : / / g i t l a b . c o m / n o m a d i c - l a b s / t e z o s " ;
license = lib . licenses . mit ;
maintainers = [ lib . maintainers . ulrikstrid ] ;
} ;
}
2023-04-08 07:27:25 +02:00
# Darwin sdk on intel target 10.12 (2016) at the time of writing. It is likely that host will be at least 10.14 (2018). This fix allow it to build and run on 10.14 and build on 10.12 (but don't run).
// lib . optionalAttrs ( lib . versionOlder stdenv . hostPlatform . darwinMinVersion " 1 0 . 1 4 " && stdenv . hostPlatform . isMacOS && stdenv . hostPlatform . isx86_64 ) {
preHook = ''
export MACOSX_DEPLOYMENT_TARGET = 10 .14
'' ;
} )