Skip to content

Unwrapped GCC is propagated to user environments #21751

@abbradar

Description

@abbradar

Issue description

Our CC wrapper doesn't wrap all the binaries that GCC provides -- namely prefixed with architecture x86_64-unknown-gnu-gcc and variations. Because unwrapped GCC is propagated to user environments from the wrapper it ends up in the path (for example in FHS environments). One example of problem that it causes is that OpenWrt picks it up and fails to compile.

wrapCC needs to detect and wrap those.

Steps to reproduce

  1. buildEnv { paths = [ gcc ]; } (you can also add it to environment.systemPackages or buildFHSUserEnv);
  2. Try to compile something with x86_64-unknown-gnu-gcc (prefix may vary).

Technical details

  • Nixpkgs version: (run nix-instantiate --eval '<nixpkgs>' -A lib.nixpkgsVersion) 59dbcef

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.kind: bugSomething is broken2.status: stalehttps://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions