Upstream `gcc-13` merged `mcfgthreads` support with a caveat: it's
headers interface is not compatible with the patch `nixpkgs` was
carrying in `gcc-12` and before.
To keep both new (`gcc13`) and old (`_pre_gcc13`) version I held back
previous `windows.mcfgthreads` attribute as
`windows.mcfgthreads_pre_gcc_13`. It is used for `gcc` before 13.
The change fixes the build of `pkgsCross.mingwW64.stdenv` itself and
example program:
$ nix build --impure --expr 'with import ./. {}; pkgsCross.mingwW64.re2c.override { stdenv = pkgsCross.mingwW64.gcc11Stdenv; }'
This is in preparation for native builds of DXVK, but it also allows
users to choose to use an older version if that is more compatible with
their hardware.
Upstream will remove the `setup_dxvk.sh` in DXVK 2.1. To avoid breaking
users of the current derivation, vendor `setup_dxvk.sh`. This script is
based on the upstream script with some modifications:
- Update command-line parsing; and
- Reorganized action processing logic.
While it’s unlikely, it’s possible that different MoltenVK versions
could require their own compatability patches. Support that by making
the `moltenvk` derivation provide the patch via `passthru`. There is no
package with the patch applied because the patch should never be used by
anything other than DXVK.
- Move the synchronization primitive changes to their own patch, so it
can be applied conditionally on Darwin. Also, document why this change
is needed; and
- Refactor how `src` is handled to support allowing Darwin and Linux to
diverge in case the Darwin patches do not apply to the latest version.
This should address some post-merger concerns that were raised about
Darwin’s blocking updates for Linux.