satysfi: rewrite with buildDunePackage
This commit is contained in:
parent
c7e15bc394
commit
185ea78a2a
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchFromGitHub, ruby, dune_3, ocamlPackages
|
||||
{ lib, stdenv, fetchFromGitHub, ruby, ocamlPackages
|
||||
, ipaexfont, junicode, lmodern, lmmath
|
||||
}:
|
||||
let
|
||||
@ -34,7 +34,7 @@ let
|
||||
inherit (ocamlPackages.yojson) meta;
|
||||
};
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
ocamlPackages.buildDunePackage rec {
|
||||
pname = "satysfi";
|
||||
version = "0.0.8";
|
||||
src = fetchFromGitHub {
|
||||
@ -51,23 +51,24 @@ in
|
||||
$out/share/satysfi
|
||||
'';
|
||||
|
||||
DUNE_PROFILE = "release";
|
||||
duneVersion = "3";
|
||||
|
||||
nativeBuildInputs = [ ruby dune_3 ];
|
||||
nativeBuildInputs = with ocamlPackages; [ menhir cppo ];
|
||||
|
||||
buildInputs = [ camlpdf otfm yojson-with-position ] ++ (with ocamlPackages; [
|
||||
ocaml findlib menhir menhirLib
|
||||
batteries camlimages core_kernel ppx_deriving uutf omd cppo re
|
||||
menhirLib
|
||||
batteries camlimages core_kernel ppx_deriving uutf omd re
|
||||
]);
|
||||
|
||||
installPhase = ''
|
||||
cp -r ${ipaexfont}/share/fonts/opentype/* lib-satysfi/dist/fonts/
|
||||
cp -r ${junicode}/share/fonts/junicode-ttf/* lib-satysfi/dist/fonts/
|
||||
cp -r ${lmodern}/share/fonts/opentype/public/lm/* lib-satysfi/dist/fonts/
|
||||
cp -r ${lmmath}/share/fonts/opentype/latinmodern-math.otf lib-satysfi/dist/fonts/
|
||||
make install PREFIX=$out LIBDIR=$out/share/satysfi
|
||||
mkdir -p $out/share/satysfi/
|
||||
postInstall = ''
|
||||
mkdir -p $out/share/satysfi/dist/fonts
|
||||
cp -r lib-satysfi/dist/ $out/share/satysfi/
|
||||
cp -r \
|
||||
${ipaexfont}/share/fonts/opentype/* \
|
||||
${junicode}/share/fonts/junicode-ttf/* \
|
||||
${lmodern}/share/fonts/opentype/public/lm/* \
|
||||
${lmmath}/share/fonts/opentype/latinmodern-math.otf \
|
||||
$out/share/satysfi/dist/fonts
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
|
Loading…
Reference in New Issue
Block a user