diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2021-12-13 20:28:53 +0100 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2021-12-13 20:28:53 +0100 |
commit | 46d86e06ba54dc708fa8fd7d0109845fa2ac402e (patch) | |
tree | 932d68a252112b7b437f20b592aa65d2129afeb8 | |
parent | 9529de2eed48edd1d7da9b77e62a17b9bc415ad1 (diff) |
Simplify
-rw-r--r-- | src/libstore/build/local-derivation-goal.cc | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/libstore/build/local-derivation-goal.cc b/src/libstore/build/local-derivation-goal.cc index edfa46052..66d950b42 100644 --- a/src/libstore/build/local-derivation-goal.cc +++ b/src/libstore/build/local-derivation-goal.cc @@ -1779,15 +1779,14 @@ void LocalDerivationGoal::runChild() i686-linux build on an x86_64-linux machine. */ struct utsname utsbuf; uname(&utsbuf); - if (drv->platform == "i686-linux" && - (settings.thisSystem == "x86_64-linux" || - (!strcmp(utsbuf.sysname, "Linux") && !strcmp(utsbuf.machine, "x86_64")))) { + if ((drv->platform == "i686-linux" + && (settings.thisSystem == "x86_64-linux" + || (!strcmp(utsbuf.sysname, "Linux") && !strcmp(utsbuf.machine, "x86_64")))) + || drv->platform == "armv7l-linux" + || drv->platform == "armv6l-linux") + { if (personality(PER_LINUX32) == -1) - throw SysError("cannot set i686-linux personality"); - } - if (drv->platform == "armv7l-linux" || drv->platform == "armv6l-linux") { - if (personality(PER_LINUX32) == -1) - throw SysError("cannot set 32bit linux personality"); + throw SysError("cannot set 32-bit personality"); } /* Impersonate a Linux 2.6 machine to get some determinism in |