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

kexec-tools: use depsBuildBuild to get the right compiler #60291

Merged

Conversation

matthewbauer
Copy link
Member

Need this to avoid this issue in pkgsStatic:

ld: cannot find -lc

/cc @Ericson2314 @nh2

Motivation for this change
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • 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 nix-review --run "nix-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)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Need this to avoid this issue in pkgsStatic:

  ld: cannot find -lc

/cc @Ericson2314
@matthewbauer
Copy link
Member Author

@GrahamcOfBorg build pkgsStatic.kexectools

@matthewbauer matthewbauer merged commit fa0208c into NixOS:master Apr 26, 2019
@matthewbauer
Copy link
Member Author

Oh wow the ofborg checker must not have been running. Much larger rebuild than i expected.

@eadwu
Copy link
Member

eadwu commented Apr 27, 2019

Replicated with nix build nixpkgs.pkgsi686Linux.alsaPlugins, originating from hardware.pulseaudio.support32Bit.

➜ nix build nixpkgs.pkgsi686Linux.alsaPlugins
builder for '/nix/store/cps7hzshg0kbyy9j8xdg11xhcfxh634s-libjack2-1.9.12.drv' failed with exit code 1; last 1 log lines:
  while setting up the build environment: executing '/nix/store/cl92j2hbhyfs3l9cpr8lxycnpcrp17yp-bash-4.4-p23/bin/bash': Exec format error
cannot build derivation '/nix/store/8hk05iscvpp1ss5ll7zqxjj8qlxlznq7-alsa-plugins-1.1.8.drv': 1 dependencies couldn't be built
[0 built (1 failed)]
error: build of '/nix/store/8hk05iscvpp1ss5ll7zqxjj8qlxlznq7-alsa-plugins-1.1.8.drv' failed

@matthewbauer
Copy link
Member Author

Can you execute 32-bit binaries? Some hardening configs disable it IIRC.

Try running:

$ file /nix/store/cl92j2hbhyfs3l9cpr8lxycnpcrp17yp-bash-4.4-p23/bin/bash
$ /nix/store/cl92j2hbhyfs3l9cpr8lxycnpcrp17yp-bash-4.4-p23/bin/bash

@eadwu
Copy link
Member

eadwu commented Apr 27, 2019

Oh forgot about the fact I enabled hardened a few hours before that, that should've been the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants