diff options
| author | Nicolas Graves <ngraves@ngraves.fr> | 2026-07-21 12:27:43 +0200 |
|---|---|---|
| committer | Nguyễn Gia Phong <cnx@loang.net> | 2026-07-23 13:09:47 +0900 |
| commit | c4145027d328b3238d713407899b5afff57de057 (patch) | |
| tree | 8523bbcce9f405b3f1176c60f042fd14066647ba /nix/libstore | |
| parent | addd3e78c2c7251a3382142ff479a71053689e35 (diff) | |
nix: build: Fix error message.
This fixes surprising error message like as follows,
which looks like an overlook:
@ unsupported-platform /gnu/store/4xb677bysagk7pl4xba9xz4gzwvsh0zn-guile-bootstrap-2.0.drv x86_64-gnu
while setting up the child process: in phase exec: a `x86_64-gnu' is required to build `x86_64-linux',
but I am a `/gnu/store/4xb677bysagk7pl4xba9xz4gzwvsh0zn-guile-bootstrap-2.0.drv'
* nix/libstore/build.cc (execBuilderOrBuiltin):
Fix the error message when canBuildLocally fails.
Fixes: 3af52f845fe2 ("[...] use std::format instead of boost::format.")
Merges: https://codeberg.org/guix/guix/pulls/10080
Signed-off-by: Nguyễn Gia Phong <cnx@loang.net>
Diffstat (limited to 'nix/libstore')
| -rw-r--r-- | nix/libstore/build.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nix/libstore/build.cc b/nix/libstore/build.cc index b94bca5359a..3cd7926d750 100644 --- a/nix/libstore/build.cc +++ b/nix/libstore/build.cc | |||
| @@ -2455,7 +2455,7 @@ void DerivationGoal::execBuilderOrBuiltin(SpawnContext & ctx) | |||
| 2455 | if (settings.printBuildTrace) | 2455 | if (settings.printBuildTrace) |
| 2456 | printMsg(lvlError, std::format("@ unsupported-platform {} {}", drvPath, drv.platform)); | 2456 | printMsg(lvlError, std::format("@ unsupported-platform {} {}", drvPath, drv.platform)); |
| 2457 | throw Error(std::format("a `{}' is required to build `{}', but I am a `{}'", | 2457 | throw Error(std::format("a `{}' is required to build `{}', but I am a `{}'", |
| 2458 | drv.platform, settings.thisSystem, drvPath)); | 2458 | drv.platform, drvPath, settings.thisSystem)); |
| 2459 | } | 2459 | } |
| 2460 | 2460 | ||
| 2461 | errno = error; | 2461 | errno = error; |
