Commit ba1db967 authored by Vincenzo Mantova's avatar Vincenzo Mantova
Browse files

asymptote: add Qt5 libraries and wrapper for xasy

parent 640d4e20
Loading
Loading
Loading
Loading
+9 −3
Original line number Diff line number Diff line
{ lib, stdenv, fetchFromGitHub, fetchurl, fetchpatch
, autoreconfHook, bison, glm, flex
, autoreconfHook, bison, glm, flex, wrapQtAppsHook
, freeglut, ghostscriptX, imagemagick, fftw
, boehmgc, libGLU, libGL, mesa, ncurses, readline, gsl, libsigsegv
, python3
, python3, qtbase, qtsvg
, zlib, perl, curl
, texLive, texinfo
, darwin
@@ -25,12 +25,13 @@ stdenv.mkDerivation rec {
    flex
    bison
    texinfo
    wrapQtAppsHook
  ];

  buildInputs = [
    ghostscriptX imagemagick fftw
    boehmgc ncurses readline gsl libsigsegv
    zlib perl curl
    zlib perl curl qtbase qtsvg
    texLive
    (python3.withPackages (ps: with ps; [ cson numpy pyqt5 ]))
  ];
@@ -43,6 +44,8 @@ stdenv.mkDerivation rec {
    OpenGL GLUT Cocoa
  ]);

  dontWrapQtApps = true;

  preConfigure = ''
    HOME=$TMP
  '';
@@ -55,6 +58,9 @@ stdenv.mkDerivation rec {
  env.NIX_CFLAGS_COMPILE = "-I${boehmgc.dev}/include/gc";

  postInstall = ''
    rm "$out"/bin/xasy
    makeQtWrapper "$out"/share/asymptote/GUI/xasy.py "$out"/bin/xasy --prefix PATH : "$out"/bin

    mv $out/share/info/asymptote/*.info $out/share/info/
    sed -i -e 's|(asymptote/asymptote)|(asymptote)|' $out/share/info/asymptote.info
    rmdir $out/share/info/asymptote
+1 −1
Original line number Diff line number Diff line
@@ -3014,7 +3014,7 @@ with pkgs;
  astc-encoder = callPackage ../tools/graphics/astc-encoder { };
  asymptote = callPackage ../tools/graphics/asymptote {
  asymptote = libsForQt5.callPackage ../tools/graphics/asymptote {
    texLive = texlive.combine { inherit (texlive) scheme-small epsf cm-super texinfo media9 ocgx2 collection-latexextra; };
  };