2022-06-26 17:44:15 +00:00
|
|
|
{ lib, fetchurl, buildDunePackage, io-page, mirage-block }:
|
2020-12-26 18:35:40 +00:00
|
|
|
|
|
|
|
buildDunePackage rec {
|
|
|
|
pname = "mirage-block-ramdisk";
|
|
|
|
version = "0.5";
|
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url =
|
|
|
|
"https://github.com/mirage/mirage-block-ramdisk/releases/download/${version}/mirage-block-ramdisk-${version}.tbz";
|
|
|
|
sha256 = "cc0e814fd54efe7a5b7a8c5eb1c04e2dece751b7d8dee2d95908a0768896e8af";
|
|
|
|
};
|
|
|
|
|
2022-10-11 06:50:54 +00:00
|
|
|
# Make compatible with cstruct 6.1.0
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace src/ramdisk.ml --replace 'Cstruct.len' 'Cstruct.length'
|
|
|
|
'';
|
|
|
|
|
2022-06-26 17:44:15 +00:00
|
|
|
minimalOCamlVersion = "4.06";
|
2023-03-25 10:18:11 +00:00
|
|
|
duneVersion = "3";
|
2020-12-26 18:35:40 +00:00
|
|
|
|
|
|
|
propagatedBuildInputs = [ io-page mirage-block ];
|
|
|
|
|
2022-06-26 17:44:15 +00:00
|
|
|
doCheck = false;
|
2020-12-26 18:35:40 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "In-memory BLOCK device for MirageOS";
|
|
|
|
homepage = "https://github.com/mirage/mirage-block-ramdisk";
|
|
|
|
license = licenses.isc;
|
|
|
|
maintainers = with maintainers; [ ehmry ];
|
|
|
|
};
|
|
|
|
}
|