mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-28 15:54:32 +00:00
4f0dadbf38
After final improvements to the official formatter implementation, this commit now performs the first treewide reformat of Nix files using it. This is part of the implementation of RFC 166. Only "inactive" files are reformatted, meaning only files that aren't being touched by any PR with activity in the past 2 months. This is to avoid conflicts for PRs that might soon be merged. Later we can do a full treewide reformat to get the rest, which should not cause as many conflicts. A CI check has already been running for some time to ensure that new and already-formatted files are formatted, so the files being reformatted here should also stay formatted. This commit was automatically created and can be verified using nix-builda08b3a4d19
.tar.gz \ --argstr baseRevb32a094368
result/bin/apply-formatting $NIXPKGS_PATH
80 lines
2.1 KiB
Nix
80 lines
2.1 KiB
Nix
{
|
|
fetchFromGitHub,
|
|
lib,
|
|
stdenv,
|
|
libiconv,
|
|
texliveFull,
|
|
xercesc,
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "blahtexml";
|
|
version = "1.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "gvanas";
|
|
repo = "blahtexml";
|
|
rev = "v${version}";
|
|
hash = "sha256-DL5DyfARHHbwWBVHSa/VwHzNaAx/v7EDdnw1GLOk+y0=";
|
|
};
|
|
|
|
postPatch =
|
|
lib.optionalString stdenv.cc.isClang ''
|
|
substituteInPlace makefile \
|
|
--replace "\$(CXX)" "\$(CXX) -std=c++98"
|
|
''
|
|
+
|
|
# fix the doc build on TeX Live 2023
|
|
''
|
|
substituteInPlace Documentation/manual.tex \
|
|
--replace '\usepackage[utf8x]{inputenc}' '\usepackage[utf8]{inputenc}'
|
|
'';
|
|
|
|
outputs = [
|
|
"out"
|
|
"doc"
|
|
];
|
|
|
|
nativeBuildInputs = [ texliveFull ]; # scheme-full needed for ucs package
|
|
buildInputs = [ xercesc ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ libiconv ];
|
|
|
|
buildFlags =
|
|
[ "doc" ]
|
|
++ (
|
|
if stdenv.hostPlatform.isDarwin then
|
|
[
|
|
"blahtex-mac"
|
|
"blahtexml-mac"
|
|
]
|
|
else
|
|
[
|
|
"blahtex-linux"
|
|
"blahtexml-linux"
|
|
]
|
|
);
|
|
|
|
installPhase = ''
|
|
install -D -t "$out/bin" blahtex blahtexml
|
|
install -m644 -D -t "$doc/share/doc/blahtexml" Documentation/manual.pdf
|
|
'';
|
|
|
|
meta = with lib; {
|
|
homepage = "http://gva.noekeon.org/blahtexml/";
|
|
description = "TeX to MathML converter";
|
|
longDescription = ''
|
|
Blahtex is a program written in C++, which converts an equation given in
|
|
a syntax close to TeX into MathML. It is designed by David Harvey and is
|
|
aimed at supporting equations in MediaWiki.
|
|
|
|
Blahtexml is a simple extension of blahtex, written by Gilles Van Assche.
|
|
In addition to the functionality of blahtex, blahtexml has XML processing
|
|
in mind and is able to process a whole XML document into another XML
|
|
document. Instead of converting only one formula at a time, blahtexml can
|
|
convert all the formulas of the given XML file into MathML.
|
|
'';
|
|
license = licenses.bsd3;
|
|
maintainers = [ maintainers.xworld21 ];
|
|
platforms = platforms.all;
|
|
};
|
|
}
|