2022-03-24 07:24:42 +00:00
|
|
|
{ lib, stdenv, fetchCrate, rustPlatform, pkg-config, openssl, CoreServices }:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "mdbook-pdf";
|
2022-10-05 21:37:04 +01:00
|
|
|
version = "0.1.3";
|
2022-03-24 07:24:42 +00:00
|
|
|
|
|
|
|
src = fetchCrate {
|
|
|
|
inherit pname version;
|
2022-10-05 21:37:04 +01:00
|
|
|
sha256 = "sha256-zFeEmIv3DIYKmhVYO9cJwRQbSP8yELaJjVjP7hYegco=";
|
2022-03-24 07:24:42 +00:00
|
|
|
};
|
|
|
|
|
2022-10-05 21:37:04 +01:00
|
|
|
cargoHash = "sha256-pB7NEloeow4TE1Y1EMUZzeCJ/f4DnCS+sQlyN49gqzA=";
|
2022-03-24 07:24:42 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
|
|
|
|
|
|
buildInputs = [ openssl ]
|
|
|
|
++ lib.optionals stdenv.isDarwin [ CoreServices ];
|
|
|
|
|
|
|
|
# No test.
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A backend for mdBook written in Rust for generating PDF";
|
|
|
|
license = licenses.gpl3Plus;
|
|
|
|
maintainers = with maintainers; [ hollowman6 ];
|
|
|
|
homepage = "https://github.com/HollowMan6/mdbook-pdf";
|
|
|
|
};
|
|
|
|
}
|