Commit Graph

9 Commits

Author SHA1 Message Date
Artturin
e0464e4788 treewide: replace stdenv.is with stdenv.hostPlatform.is
In preparation for the deprecation of `stdenv.isX`.

These shorthands are not conducive to cross-compilation because they
hide the platforms.

Darwin might get cross-compilation for which the continued usage of `stdenv.isDarwin` will get in the way

One example of why this is bad and especially affects compiler packages
https://www.github.com/NixOS/nixpkgs/pull/343059

There are too many files to go through manually but a treewide should
get users thinking when they see a `hostPlatform.isX` in a place where it
doesn't make sense.

```
fd --type f "\.nix" | xargs sd --fixed-strings "stdenv.is" "stdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "stdenv'.is" "stdenv'.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "clangStdenv.is" "clangStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "gccStdenv.is" "gccStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "stdenvNoCC.is" "stdenvNoCC.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "inherit (stdenv) is" "inherit (stdenv.hostPlatform) is"
fd --type f "\.nix" | xargs sd --fixed-strings "buildStdenv.is" "buildStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "effectiveStdenv.is" "effectiveStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "originalStdenv.is" "originalStdenv.hostPlatform.is"
```
2024-09-25 00:04:37 +03:00
aviac
ffa38763a0
rerun: 0.13.0 -> 0.18.2 2024-09-12 13:41:24 +02:00
Alyssa Ross
b00f262516 Revert "rustc: disable wasm32 if some gcc options are set"
This reverts commits 6d0ba08b97,
723100d83b, and
bf13eca852.

The underlying issue has now been fixed, so we can re-enable
wasm32-unknown-unknown on all platforms.
2024-06-15 08:02:29 +02:00
Alyssa Ross
bf13eca852
rustc: disable wasm32 if some gcc options are set
This is a temporary fix to get rustc building again with these
configurations (which notably include the default aarch64-darwin one)
without causing a stdenv rebuild.  The real fix will be to avoid
passing these options through the Clang wrapper when the target is
overridden.

It could be that there are packages that need wasm32-unknown-unknown
beyond those I've marked as broken here — it's impossible to be sure
without a full rebuild.  But this should be most of them.
2024-06-09 07:20:18 +01:00
Alyssa Ross
07f40e6892 rustc: don't try to use non-existent rust-lld
This removes the need to manually override Rust's default linker for
every package that builds for wasm32-unknown-unknown.
2024-05-29 23:08:09 +02:00
Someone Serge
d6733d933d rerun: nixfmt 2024-04-13 09:47:35 +00:00
Someone Serge
7c74092ad1 rerun: fix the broken test 2024-04-13 09:47:35 +00:00
Someone Serge
ddb73feeda
rerun: fix wayland support, reduce runtime closure 2024-02-22 14:56:36 +00:00
Someone Serge
135fd532b7
rerun: init at 0.13.0 2024-02-17 20:31:48 +00:00