unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: phodina via Guix-patches via <guix-patches@gnu.org>
To: "48314@debbugs.gnu.org" <48314@debbugs.gnu.org>
Cc: Stefan <stefan-guix@vodafonemail.de>,
	Maxime Devos <maximedevos@telenet.be>
Subject: [bug#48314] [PATCH v4] Install guix system on Raspberry Pi
Date: Thu, 14 Apr 2022 09:25:25 +0000	[thread overview]
Message-ID: <zMqJOXxxdBE_tlTtNY-q9vjI2_uBFY36RprO1tJWhHBh9S6NO4l46DHNOjHgM5GXf3SxAbC4tR27tN3sUZWS9Y69U70BGtc47McF0TE5Gaw=@protonmail.com> (raw)
In-Reply-To: <b661d9b6c7b44262285f544110b335ef02e6a402.camel@telenet.be>

[-- Attachment #1: Type: text/plain, Size: 2493 bytes --]

>
> > +        `(modify-phases ,phases
> > +           (replace 'configure
>
>
> To get rid of the #< error, replace this by
>
> #~(modify-phases #$phases [...])
>
> (and replace the , by #$ etc).
>
> Greetings,
> Maxime.

Thanks for the suggestion Maxime. Here's patch with fixes where I attempt to rewrite the section of the code using Gexps.

Still it ends in error as there is some mistake in the Gexps I made.

$ ./pre-inst-env guix system build gnu/system/examples/raspberry-pi-64.tmpl
;;; note: source file /home/cpethod/guix/gnu/packages/linux.scm
;;;       newer than compiled /home/pethod/guix/gnu/packages/linux.go
substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0%
substitute: updating substitutes from 'https://bordeaux.guix.gnu.org'... 100.0%
The following derivation will be built:
  /gnu/store/zvy703ldgicckqgnggsnz0a21394hb9f-linux-libre-arm64-generic-5.16.19.drv
building /gnu/store/zvy703ldgicckqgnggsnz0a21394hb9f-linux-libre-arm64-generic-5.16.19.drv...
ice-9/psyntax.scm:2794:12: In procedure syntax-violation:
Syntax error:
/gnu/store/2xjp40qfmrdjg28zqsd919cjg00n9wrv-linux-libre-arm64-generic-5.16.19-builder:1:3387: source expression failed to match any pattern in form (let* ((srcarch #{$#}# (system->linux-srcarch (or (%current-target-system) (%current-system)))) (configs (string-append "arch/" srcarch "/configs/")) (guix_defconfig (string-append configs "guix_defconfig"))) #{$#}# (cond ((not defconfig) $~ (begin (apply (assoc-ref #{$#phases}# (quote configure)) arguments) (invoke "make" "savedefconfig") (rename-file "defconfig" guix_defconfig))) ((string? defconfig) $~ (rename-file (string-append configs #{$#defconfig}#) guix_defconfig)) (else (quote (copy-file (assoc-ref inputs "guix_defconfig") guix_defconfig)))) (modify-defconfig guix_defconfig (quote #{$#configs}#)) #{$#@}# (if extra-version $~ ((setenv "EXTRAVERSION" #{$#}# (string-append "-" extra-version))) (quote ())) (invoke "make" "guix_defconfig"))
builder for `/gnu/store/zvy703ldgicckqgnggsnz0a21394hb9f-linux-libre-arm64-generic-5.16.19.drv' failed with exit code 1
build of /gnu/store/zvy703ldgicckqgnggsnz0a21394hb9f-linux-libre-arm64-generic-5.16.19.drv failed
View build log at '/var/log/guix/drvs/zv/y703ldgicckqgnggsnz0a21394hb9f-linux-libre-arm64-generic-5.16.19.drv.gz'.
guix system: error: build of `/gnu/store/zvy703ldgicckqgnggsnz0a21394hb9f-linux-libre-arm64-generic-5.16.19.drv' failed


----
Petr

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: v4-0001-Attempt-to-fix-modify-linux-procedure-using-Gexp.patch --]
[-- Type: text/x-patch; name=v4-0001-Attempt-to-fix-modify-linux-procedure-using-Gexp.patch, Size: 2882 bytes --]

From 57643003418f13d49e45582ef2a6d25de6b36595 Mon Sep 17 00:00:00 2001
From: Petr Hodina <phodina@protonmail.com>
Date: Thu, 14 Apr 2022 11:18:27 +0200
Subject: [PATCH v4] Attempt to fix modify-linux procedure using Gexp.


diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index 61dac905f8..e1ad6069f8 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -1293,15 +1293,15 @@ (define*-public (modify-linux #:key name
            (replace 'configure
              (lambda* (#:key inputs #:allow-other-keys #:rest arguments)
                (let* ((srcarch
-                       ,(system->linux-srcarch (or (%current-target-system)
+                       $#(system->linux-srcarch (or (%current-target-system)
                                                    (%current-system))))
                       (configs (string-append "arch/" srcarch "/configs/"))
                       (guix_defconfig (string-append configs "guix_defconfig")))
-                 ,(cond
+                 $#(cond
                    ((not defconfig)
-                    `(begin
+                    $~(begin
                        ;; Call the original 'configure phase.
-                       (apply (assoc-ref ,phases 'configure) arguments)
+                       (apply (assoc-ref $#phases 'configure) arguments)
                        ;; Save a defconfig file.
                        (invoke "make" "savedefconfig")
                        ;; Move the saved defconfig to the proper location.
@@ -1309,19 +1309,18 @@ (define*-public (modify-linux #:key name
                                     guix_defconfig)))
                    ((string? defconfig)
                     ;; Use another existing defconfig from the Linux sources.
-                    `(rename-file (string-append configs ,defconfig)
+                    $~(rename-file (string-append configs $#defconfig)
                                   guix_defconfig))
                    (else
                     ;; Copy the defconfig input to the proper location.
                     '(copy-file (assoc-ref inputs "guix_defconfig")
                                 guix_defconfig)))
-                 (modify-defconfig guix_defconfig ',configs)
-                 ,@(if extra-version
-                       `((setenv "EXTRAVERSION"
-                                 ,(string-append "-" extra-version)))
+                 (modify-defconfig guix_defconfig '$#configs)
+                 $#@(if extra-version
+                       $~((setenv "EXTRAVERSION"
+                                 $#(string-append "-" extra-version)))
                        '())
-                 (invoke "make" "guix_defconfig"))
-               #t))))))
+                 (invoke "make" "guix_defconfig"))))))))
     (native-inputs
      (append (if (or (not defconfig)
                      (string? defconfig))
-- 
2.34.0


  reply	other threads:[~2022-04-14  9:26 UTC|newest]

Thread overview: 74+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-09 15:32 [bug#48314] Patches to install guix system on Raspberry Pi Stefan
2021-05-16 12:46 ` Stefan
2021-06-19 18:11   ` Danny Milosavljevic
2021-06-19 18:13   ` Danny Milosavljevic
2021-06-19 19:10     ` Stefan
2021-06-19 19:04   ` Danny Milosavljevic
2021-06-19 19:18     ` Stefan
2021-06-19 19:10   ` Danny Milosavljevic
2021-06-19 20:21     ` Stefan
2021-07-28 18:58       ` Stefan
2021-10-31 22:07         ` Stefan
2021-11-13 18:05           ` Vagrant Cascadian
2021-11-13 18:51             ` Vagrant Cascadian
2022-07-17 16:47             ` Stefan via Guix-patches via
2021-11-13 18:23           ` Vagrant Cascadian
2022-07-17 16:47             ` Stefan via Guix-patches via
2021-11-13 20:21           ` Vagrant Cascadian
2022-07-17 16:47             ` Stefan via Guix-patches via
2022-07-17 17:21               ` Vagrant Cascadian
2022-07-17 18:04                 ` Stefan via Guix-patches via
2021-11-17 14:00 ` [bug#48314] Install " phodina via Guix-patches via
2022-04-14  7:38 ` [bug#48314] [PATCH v3] " phodina via Guix-patches via
2022-04-14  8:17   ` phodina via Guix-patches via
2022-04-14  8:32   ` Maxime Devos
2022-04-14  9:25     ` phodina via Guix-patches via [this message]
2022-04-14 11:00       ` [bug#48314] [PATCH v4] " Maxime Devos
2022-04-14 12:23         ` [bug#48314] [PATCH v5] " phodina via Guix-patches via
2022-04-14 13:03           ` phodina via Guix-patches via
2022-04-14 13:57             ` Maxime Devos
2022-04-14 14:00           ` Maxime Devos
2022-04-14 14:06   ` [bug#48314] [PATCH v3] " Maxime Devos
2022-04-14 15:53     ` phodina via Guix-patches via
2022-04-14 17:33       ` Maxime Devos
2022-04-15 17:17       ` Ludovic Courtès
2022-04-16  8:53         ` phodina via Guix-patches via
2022-04-18 21:00           ` Ludovic Courtès
2022-04-21 10:52             ` phodina via Guix-patches via
2022-04-21 19:32               ` Stefan
2022-04-14 15:56   ` Vagrant Cascadian
2022-04-28  2:57     ` Vagrant Cascadian
2022-04-28  6:05       ` Stefan
2022-04-28 15:25         ` Vagrant Cascadian
2022-07-02  6:40           ` phodina via Guix-patches via
2022-07-17 16:48             ` Stefan via Guix-patches via
2022-07-17 16:48             ` Stefan via Guix-patches via
2022-07-18 19:23               ` phodina via Guix-patches via
2022-07-19  6:55                 ` Stefan via Guix-patches via
2022-07-19  7:35                   ` phodina via Guix-patches via
2022-07-20  6:13                     ` Stefan via Guix-patches via
2022-07-20  7:16                       ` phodina via Guix-patches via
2022-07-20 19:42                         ` Stefan via Guix-patches via
2022-08-12 14:27                           ` phodina via Guix-patches via
2022-08-13 10:48                             ` Stefan via Guix-patches via
2022-08-14  9:59                               ` phodina via Guix-patches via
2022-08-14 11:35                                 ` Stefan via Guix-patches via
2022-09-01 23:55                                   ` Stefan via Guix-patches via
2022-09-02  5:49                                     ` phodina via Guix-patches via
2022-09-04 18:41                                       ` Stefan via Guix-patches via
2022-09-22 16:18                                         ` [bug#48314] [PATCH v5] " Stefan via Guix-patches via
2022-10-05 13:02                                           ` Ludovic Courtès
2022-10-08 16:22                                           ` Vagrant Cascadian
2022-10-09 13:41                                             ` Stefan via Guix-patches via
2022-10-30 12:39                                               ` phodina via Guix-patches via
2022-10-30 17:08                                                 ` Stefan via Guix-patches via
2022-10-30 17:31                                                   ` Stefan via Guix-patches via
2022-12-01 14:25                                           ` [bug#48314] [PATCH] " Maxim Cournoyer
2022-12-01 15:32                                           ` Maxim Cournoyer
2022-12-01 16:22                                           ` Maxim Cournoyer
2022-12-01 18:01                                           ` Maxim Cournoyer
2022-12-01 19:33                                           ` bug#48314: " Maxim Cournoyer
2022-12-03  5:53                                             ` [bug#48314] " Vagrant Cascadian
2022-12-04  6:28                                               ` Maxim Cournoyer
2022-10-30 17:32 ` [bug#48314] [PATCH v5] " Stefan via Guix-patches via
2022-10-30 17:33 ` Stefan via Guix-patches via

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='zMqJOXxxdBE_tlTtNY-q9vjI2_uBFY36RprO1tJWhHBh9S6NO4l46DHNOjHgM5GXf3SxAbC4tR27tN3sUZWS9Y69U70BGtc47McF0TE5Gaw=@protonmail.com' \
    --to=guix-patches@gnu.org \
    --cc=48314@debbugs.gnu.org \
    --cc=maximedevos@telenet.be \
    --cc=phodina@protonmail.com \
    --cc=stefan-guix@vodafonemail.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).