summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2018-09-10 14:45:19 +0200
committerLudovic Courtès <ludo@gnu.org>2018-09-10 17:47:52 +0200
commitf8121329b1dcebb55d6dfbae553bfa69d557eede (patch)
treed46b11aa833f41857c40dde7275ebcfff82bcca4
parent8a8662d28693ec4085df7653bafb073ad1b6f8a3 (diff)
syscalls: Report lack of a libc symbol as ENOSYS.
* guix/build/syscalls.scm (syscall->procedure): Throw to 'system-error with ENOSYS when NAME cannot be found.
-rw-r--r--guix/build/syscalls.scm4
1 files changed, 2 insertions, 2 deletions
diff --git a/guix/build/syscalls.scm b/guix/build/syscalls.scm
index 74cb675fcf..56a689f667 100644
--- a/guix/build/syscalls.scm
+++ b/guix/build/syscalls.scm
@@ -385,8 +385,8 @@ the returned procedure is called."
#:return-errno? #t)))
(lambda args
(lambda _
- (error (format #f "~a: syscall->procedure failed: ~s"
- name args))))))
+ (throw 'system-error name "~A" (list (strerror ENOSYS))
+ (list ENOSYS))))))
(define-syntax define-as-needed
(syntax-rules ()