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

shadow: add runtime-shell.patch for cross-compilation #87437

Merged
1 commit merged into from Apr 11, 2021

Conversation

matthewbauer
Copy link
Member

@matthewbauer matthewbauer commented May 9, 2020

This gets the right shell in the closure.

By default, shadow wants to pull in the bash we are building it with,
while we would prefer it used the runtime bash.

Motivation for this change
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@matthewbauer matthewbauer changed the base branch from master to staging May 9, 2020 22:11
@FRidh FRidh changed the base branch from staging to staging-next May 11, 2020 20:19
@FRidh FRidh changed the base branch from staging-next to staging May 11, 2020 20:19
@FRidh FRidh added this to WIP in Staging via automation May 11, 2020
@FRidh FRidh moved this from WIP to Needs review in Staging May 11, 2020
Copy link
Contributor

@lopsided98 lopsided98 left a comment

Choose a reason for hiding this comment

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

LGTM, except perhaps using runtimeShell. I haven't done runtime testing yet but hopefully will soon.

pkgs/os-specific/linux/shadow/default.nix Outdated Show resolved Hide resolved
@stale
Copy link

stale bot commented Feb 14, 2021

I marked this as stale due to inactivity. → More info

@stale stale bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Feb 14, 2021
Copy link
Contributor

@lopsided98 lopsided98 left a comment

Choose a reason for hiding this comment

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

This PR is definitely still important. I used an older version of this patch on a cross-compiled Raspberry Pi image and everything seemed to work, although I didn't test shadow specifically.

@@ -1,6 +1,7 @@
{ stdenv, fetchpatch, fetchFromGitHub, autoreconfHook, libxslt, libxml2
, docbook_xml_dtd_45, docbook_xsl, itstool, flex, bison
, pam ? null, glibcCross ? null
, bash
Copy link
Contributor

Choose a reason for hiding this comment

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

Needs to be changed to runtimeShell to make this evaluate.

@stale stale bot removed the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Feb 16, 2021
@ghost ghost force-pushed the shadow-add-runtime-shell branch 3 times, most recently from 49d6de9 to e4f3e31 Compare April 11, 2021 00:07
This gets the right shell in the closure.

By default, shadow wants to pull in the bash we are building it with,
while we would prefer it used the runtime bash.
@ghost ghost force-pushed the shadow-add-runtime-shell branch from e4f3e31 to c30317f Compare April 11, 2021 00:39
@ghost ghost merged commit fbb26ab into NixOS:staging Apr 11, 2021
Staging automation moved this from Needs review to Done Apr 11, 2021
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Staging
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants