anchor.diff:        substituteInPlace ./tests/osproc/tworkingdir.nim --replace "/usr/bin" "${coreutils}/bin"
         substituteInPlace ./tests/stdlib/ttimes.nim --replace "/usr/share/zoneinfo" "${tzdata}/share/zoneinfo"
   
  -      # disable supposedly broken tests
  -      ${disableTest} ./tests/errmsgs/tproper_stacktrace2.nim
  -      ${disableTest} ./tests/vm/trgba.nim
  -
         # disable tests requiring network access (not available in the build container)
         ${disableTest} ./tests/stdlib/thttpclient.nim
  -      ${disableTest} ./tests/cpp/tasync_cpp.nim
  -      ${disableTest} ./tests/niminaction/Chapter7/Tweeter/src/tweeter.nim
  -
  -      # disable tests requiring un-downloadable dependencies (using nimble, which isn't available in the fetch phase)
  -      ${disableCompile} ./tests/manyloc/keineschweine/keineschweine.nim
  -      ${disableTest} ./tests/manyloc/keineschweine/keineschweine.nim
  -      ${disableCompile} ./tests/manyloc/nake/nakefile.nim
  -      ${disableTest} ./tests/manyloc/nake/nakefile.nim
  -      ${disableCompile} ./tests/manyloc/named_argument_bug/main.nim
  -      ${disableTest} ./tests/manyloc/named_argument_bug/main.nim
       '';
   
     checkPhase = ''
  +    PATH=$PATH:$out/bin
       ./koch tests
     '';
   
  
positive.code:     "-lcrypto"
      "-lpcre"
      "-lreadline"
      "-lsqlite3"
      "-lgc"
    ];
  
  
negative.code: # based on https://github.com/nim-lang/Nim/blob/v0.18.0/.travis.yml
  
  { stdenv, lib, fetchurl, makeWrapper, nodejs-slim-8_x, openssl, pcre, readline, boehmgc, sfml, tzdata, coreutils }:
  
  stdenv.mkDerivation rec {
    name = "nim-${version}";
    version = "0.19.0";
  
    src = fetchurl {
      url = "https://nim-lang.org/download/${name}.tar.xz";
      sha256 = "0biwvw1gividp5lkf0daq1wp9v6ms4xy6dkf5zj0sn9w4m3n76d1";
    };
  
    doCheck = !stdenv.isDarwin;
  