anchor.diff:    outputs = [ "out" ] ++ lib.optional (!enableGUI) "doc";
   
     doCheck = true;
  -  preCheck = ''
  -    # One test in this file fails. That test just tests a part of the pari
  -    # interface that isn't actually used in giac. Of course it would be better
  -    # to only remove that one test, but that would require a patch.
  -    # Removing the whole test set should be good enough for now.
  -    # Upstream report: https://xcas.univ-grenoble-alpes.fr/forum/viewtopic.php?f=4&t=2102#p10326
  -    echo > check/chk_fhan11
  +  preCheck = lib.optionalString (!enableGUI) ''
  +    # even with the nofltk patch, some changes in src/misc.cc (grep
  +    # for HAVE_LIBFLTK) made it so that giac behaves differently
  +    # when fltk is disabled. disable these tests for now.
  +    echo > check/chk_fhan2
  +    echo > check/chk_fhan9
     '';
   
     enableParallelBuilding = true;
  
positive.code:     "--enable-ao" "--enable-ecm" "--enable-glpk"
    ] ++ lib.optionals enableGUI [
      "--enable-gui" "--with-x"
    ];
  
    postInstall = ''
      # example Makefiles contain the full path to some commands
  
negative.code:     lapack blas
    ] ++ lib.optionals enableGUI [
      libGL libGLU fltk xorg.libX11
    ] ++ lib.optional enableMicroPy python3;
  
    /* fixes:
    configure:16211: checking for main in -lntl
  