Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs/installShellFiles: document how to not break cross-compilation #326016

Closed
wants to merge 1 commit into from

Conversation

Mic92
Copy link
Member

@Mic92 Mic92 commented Jul 10, 2024

Description of changes

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 24.11 Release Notes (or backporting 23.11 and 24.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@github-actions github-actions bot added the 8.has: documentation This PR adds or changes documentation label Jul 10, 2024
@Mic92 Mic92 force-pushed the install-shell-files branch from c3ff62c to cde8053 Compare July 10, 2024 03:46
@ofborg ofborg bot added the 6.topic: cross-compilation Building packages on a different platform than they will be used on label Jul 10, 2024
@Mic92 Mic92 force-pushed the install-shell-files branch from cde8053 to 9d7fcba Compare July 10, 2024 04:02
@Mic92 Mic92 force-pushed the install-shell-files branch from 9d7fcba to a2b9db8 Compare July 10, 2024 04:02
@Mic92 Mic92 requested a review from Ericson2314 July 10, 2024 04:03
@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux labels Jul 10, 2024
@SFrijters
Copy link
Member

PR on the same subject #325591

installShellCompletion --cmd foobar \
--bash <($out/bin/foobar --bash-completion) \
--fish <($out/bin/foobar --fish-completion) \
--zsh <($out/bin/foobar --zsh-completion)
'';
}
```

Copy link
Member

@SFrijters SFrijters Jul 10, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some people have spoken out against this solution before #316749 (comment) and below.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I cannot quite follow the reasoning in this thread though. Qemu is not that bad to have in your build closure. It should be already compiled anyway. But I think it's harder to test, so I personally prefer if contributor at least remove this completion for cross compilation.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have a strong opinion either way, just trying to tie all the discussions in various places together (and hopefully the bikeshedding will converge on something).

Separate question: why is this in preFixup? Is that because it's before wrapping happens?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have a strong opinion here. I let you let write the documentation than.
Just ping me on the review.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Mic92 #325591 was already merged before I got to respond to your comment.

@SFrijters
Copy link
Member

Also linking to discussion in #308283 .

@Mic92 Mic92 closed this Jul 12, 2024
@Mic92 Mic92 deleted the install-shell-files branch January 18, 2025 16:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: cross-compilation Building packages on a different platform than they will be used on 8.has: documentation This PR adds or changes documentation 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants