2023-03-24 00:07:29 +00:00
|
|
|
{ pkgs, lib, fetchFromGitHub, buildDunePackage, pkg-config, dune-configurator
|
2020-09-25 04:45:31 +00:00
|
|
|
, bigstring,
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildDunePackage rec {
|
|
|
|
pname = "hidapi";
|
2023-03-24 00:07:29 +00:00
|
|
|
version = "1.1.2";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2023-03-24 00:07:29 +00:00
|
|
|
duneVersion = "3";
|
2021-04-05 15:23:46 +00:00
|
|
|
|
2023-03-24 00:07:29 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "vbmithr";
|
|
|
|
repo = "ocaml-hidapi";
|
|
|
|
rev = version;
|
|
|
|
hash = "sha256-SNQ1/i5wJJgcslIUBe+z5QgHns/waHnILyMUJ46cUwg=";
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
|
2023-03-24 00:07:29 +00:00
|
|
|
minimalOCamlVersion = "4.03";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2022-03-05 16:20:37 +00:00
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
|
|
buildInputs = [ pkgs.hidapi dune-configurator ];
|
2020-09-25 04:45:31 +00:00
|
|
|
propagatedBuildInputs = [ bigstring ];
|
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Bindings to Signal11's hidapi library";
|
2022-05-18 14:49:53 +00:00
|
|
|
homepage = "https://github.com/vbmithr/ocaml-hidapi";
|
2020-09-25 04:45:31 +00:00
|
|
|
license = licenses.isc;
|
|
|
|
maintainers = [ maintainers.alexfmpe ];
|
2022-05-18 14:49:53 +00:00
|
|
|
mainProgram = "ocaml-hid-enumerate";
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
}
|