Skip to content

pkgsMusl.pkgsStatic.stdenv is broken #114510

@r-burns

Description

@r-burns

Describe the bug
The gcc used for pkgsMusl.pkgsStatic.stdenv fails to build on x86_64-linux, due to a faulty bintools setup, as pointed out by Sandro here: #112096 (comment).

I think the reason for this is that the binutils hostPlatform is different from the targetPlatform (host is dynamic musl, target is static) but the configs are both x86_64-unknown-linux-musl. So our package definitions expect the resulting bintools to have a x86_64-unknown-linux-musl targetPrefix, but they do not because the autotools configure script only sees matching host/target configs, so it produces unprefixed ld, as, etc binaries.

To Reproduce
nix-build '<nixpkgs>' -A pkgsMusl.pkgsStatic.stdenv

Notify maintainers
Nixpkgs cross maintainers: @matthewbauer @Ericson2314

Metadata

  • system: "x86_64-linux"
  • host os: Linux 5.4.87, NixOS, 21.03pre268206.536fe36e23a (Okapi)
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.3.10
  • channels(root): "nixos-21.03pre268206.536fe36e23a"
  • nixpkgs: /nix/var/nix/profiles/per-user/root/channels/nixos

Maintainer information:

# a list of nixpkgs attributes affected by the problem
attribute:
  - binutils
  - gcc
# a list of nixos modules affected by the problem
module:

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.kind: bugSomething is broken2.status: stalehttps://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md6.topic: cross-compilationBuilding packages on a different platform than they will be used on6.topic: staticStatic builds (e.g. pkgsStatic)

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions