mirror of
https://github.com/NixOS/nix
synced 2025-06-27 00:11:17 +02:00
Fix "Bad system call" running i686-linux binaries on x86_64-linux
To determine which seccomp filters to install, we were incorrectly using settings.thisSystem, which doesn't denote the actual system when --system is used. Fixes #2791.
This commit is contained in:
parent
989cb37777
commit
f9a2ea4486
3 changed files with 11 additions and 4 deletions
|
@ -38,6 +38,9 @@ extern char * * environ;
|
|||
namespace nix {
|
||||
|
||||
|
||||
const std::string nativeSystem = SYSTEM;
|
||||
|
||||
|
||||
BaseError & BaseError::addPrefix(const FormatOrString & fs)
|
||||
{
|
||||
prefix_ = fs.s + prefix_;
|
||||
|
|
|
@ -30,6 +30,10 @@ struct Sink;
|
|||
struct Source;
|
||||
|
||||
|
||||
/* The system for which Nix is compiled. */
|
||||
extern const std::string nativeSystem;
|
||||
|
||||
|
||||
/* Return an environment variable. */
|
||||
string getEnv(const string & key, const string & def = "");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue