guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#45591] environment: gracefully handle unsupported system.


From: guy fleury iteriteka
Subject: [bug#45591] environment: gracefully handle unsupported system.
Date: Fri, 01 Jan 2021 12:53:08 +0200

hi guix,

if this patch looks good, feel free to change message diagnostic.

>From d9b4727885744abda8afc179182a2cc975122487 Mon Sep 17 00:00:00 2001
From: guy fleury iteriteka <gfleury@disroot.org>
Date: Fri, 1 Jan 2021 11:01:49 +0200
Subject: [PATCH] environment: gracefully handle unsupported system.

* guix/scripts/environment.scm(guix-environment): Add a test
  to ensure that the system is supported.
---
 guix/scripts/environment.scm | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm
index e435bf0..40af012 100644
--- a/guix/scripts/environment.scm
+++ b/guix/scripts/environment.scm
@@ -719,6 +719,10 @@ message if any test fails."
            (mappings   (pick-all opts 'file-system-mapping))
            (white-list (pick-all opts 'inherit-regexp)))
 
+      (when (not (member system '("armhf-linux" "aarch64-linux"
+                                  "i686-linux" "x86_64-linux" "i586-gnu")))
+        (leave (G_ "guix does not support ~A system~%") system))
+
       (when container? (assert-container-features))
 
       (when (and (not container?) link-prof?)
-- 
2.20.1


reply via email to

[Prev in Thread] Current Thread [Next in Thread]