nixpkgs/pkgs/tools/text/mdbook-katex/default.nix
Theodore Ni bf23d0e45b
mdbook-katex: 0.2.10 -> 0.2.17
There is a new co-maintainer who breathed new life into this project,
but as a consequence the Cargo.lock file is no longer present with each
released tag in the GitHub repo, so need to switch to crates.io.
2022-11-27 02:21:29 -08:00

26 lines
765 B
Nix

{ lib, stdenv, fetchCrate, rustPlatform, openssl, CoreServices }:
rustPlatform.buildRustPackage rec {
pname = "mdbook-katex";
version = "0.2.17";
src = fetchCrate {
inherit pname version;
sha256 = "sha256-rJzZVZn8CJOIcSVLCLv6tWox0MRdxNBMUKo1fij1ogc=";
};
cargoHash = "sha256-aSFXTeP5wDshdrrJ+eJCTmLuTlxCuM+5irUr0iW4tAY=";
OPENSSL_DIR = "${lib.getDev openssl}";
OPENSSL_LIB_DIR = "${lib.getLib openssl}/lib";
buildInputs = lib.optionals stdenv.isDarwin [ CoreServices ];
meta = with lib; {
description = "A preprocessor for mdbook, rendering LaTeX equations to HTML at build time.";
homepage = "https://github.com/lzanini/${pname}";
license = [ licenses.mit ];
maintainers = with maintainers; [ lovesegfault ];
};
}