anchor.diff:      export NIX_LDFLAGS+=" -rpath $out/lib/ghc-${version}"
     '' + lib.optionalString stdenv.isDarwin ''
       export NIX_LDFLAGS+=" -no_dtrace_dof"
  +
  +    # GHC tries the host xattr /usr/bin/xattr by default which fails since it expects python to be 2.7
  +    export XATTR=${lib.getBin xattr}/bin/xattr
     '' + lib.optionalString targetPlatform.useAndroidPrebuilt ''
       sed -i -e '5i ,("armv7a-unknown-linux-androideabi", ("e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64", "cortex-a8", ""))' llvm-targets
     '' + lib.optionalString targetPlatform.isMusl ''
  
positive.code:     ghc bootPkgs.alex bootPkgs.happy bootPkgs.hscolour
    ] ++ lib.optionals enableDocs [
      sphinx
    ] ++ lib.optionals stdenv.isDarwin [
      # TODO(@sternenseemann): use XATTR env var once we have
      # https://gitlab.haskell.org/ghc/ghc/-/merge_requests/6447
      xattr
    ];
  
    # For building runtime libs
  
negative.code: 
    src = fetchgit {
      url = "https://gitlab.haskell.org/ghc/ghc.git/";
      rev = "64923cf295ea914db458547432237a5ed1eff571";
      sha256 = "1s9sm4gf4r71lk0s7h9v217rxfwjf435q1jji90hlxz23wvmhr6d";
    };
  
    enableParallelBuilding = true;
  