Skip to content

cycle detected in Darwin->Linux cross GCC #88213

@Gaelan

Description

@Gaelan

Describe the bug
When building a GCC for cross compiling from Darwin to Linux, the build fails with a "cycle detected" error.

To Reproduce

  1. Check out Nixpkgs staging on a Darwin box.
  2. nix-build . --arg crossSystem '(import ./. {}).lib.systems.examples.gnu64' -A stdenv.cc

Expected behavior
GCC compiles successfully, and can be used to produce Linux binaries.

Screenshots

cycle detected in the references of '/nix/store/51hmxfsm1s1089vcl6wxsm1vb6r0kar8-x86_64-unknown-linux-gnu-stage-final-gcc-debug-9.3.0' from '/nix/store/73vjzvxk0430rn4njhv09jnmqrz99h26-x86_64-unknown-linux-gnu-stage-final-gcc-debug-9.3.0-lib'

Additional context
The cycle:

  • 51hmxfsm1s1089vcl6wxsm1vb6r0kar8-x86_64-unknown-linux-gnu-stage-final-gcc-debug-9.3.0/nix-support/propagated-build-inputs includes 73vjzvxk0430rn4njhv09jnmqrz99h26-x86_64-unknown-linux-gnu-stage-final-gcc-debug-9.3.0-lib
  • 73vjzvxk0430rn4njhv09jnmqrz99h26-x86_64-unknown-linux-gnu-stage-final-gcc-debug-9.3.0-lib/x86_64-unknown-linux-gnu/lib/lib{asan,tsan,lsan,ubsan}.so* refer to 51hmxfsm1s1089vcl6wxsm1vb6r0kar8-x86_64-unknown-linux-gnu-stage-final-gcc-debug-9.3.0

Notify maintainers
@Synthetica9

Metadata
Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.

  • system: "x86_64-darwin"
  • host os: Darwin 19.4.0, macOS 10.15.4
  • multi-user?: yes
  • sandbox: no
  • version: nix-env (Nix) 2.3.3
  • channels(root): "darwin, home-manager, nixpkgs-20.09pre221814.10100a97c89"
  • channels(gaelan): "darwin, home-manager, nixpkgs-20.09pre221814.10100a97c89"
  • nixpkgs: /nix/var/nix/profiles/per-user/root/channels/nixpkgs

Channels are irrelevant, I'm using a checkout of staging.

Maintainer information:

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

Metadata

Metadata

Assignees

Labels

0.kind: bugSomething is broken6.topic: cross-compilationBuilding packages on a different platform than they will be used on6.topic: darwinRunning or building packages on Darwin

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions