guix-devel
[Top][All Lists]
Advanced

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

Re: Racket packages / build system


From: Bonface M. K.
Subject: Re: Racket packages / build system
Date: Mon, 09 Nov 2020 23:54:29 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux)

Christopher Lemmer Webber <cwebber@dustycloud.org>
writes:

> Bonface M. K. writes:
>

[...]

> I have the notes that Dimos wrote up not long ago in case anyone is
> interested.  Dimos, do you mind if I post them to the list?
>
>  - Chris

Hi! I've been trying to hack around the racket
build system(see attached) for some time now;
mostly using raco... The biggest problem I've
faced so far is that AFAICT, when you use raco to
install packages, racket updates some files from
where it's called(in guix's case store this is the
store where racket is in)--- and I don't think you
are allowed to do this. I've tried doing "raco
install <zipfile>", and also just doing "raco
install" from inside the directory.

The command for building:

--8<---------------cut here---------------start------------->8---
env 
GUIX_PACKAGE_PATH="/home/bonface/projects/guix-bioinformatics:/home/bonface/projects/guix-past/modules"
 ./pre-inst-env guix build racket-hello-racket -K
--8<---------------cut here---------------end--------------->8---

with the error:

--8<---------------cut here---------------start------------->8---
starting phase `install'
make-directory: cannot make directory
  path: /homeless-shelter/
  system error: Permission denied; errno=13
  context...:
   
/gnu/store/4f148vh30qmrdl6apq1ff6yqb7kl8xlm-racket-minimal-7.8/share/racket/collects/racket/file.rkt:114:0:
 make-directory*
   [repeats 1 more time]
   
/gnu/store/4f148vh30qmrdl6apq1ff6yqb7kl8xlm-racket-minimal-7.8/share/racket/collects/pkg/private/lock.rkt:26:0:
 with-pkg-lock*
   
/gnu/store/4f148vh30qmrdl6apq1ff6yqb7kl8xlm-racket-minimal-7.8/share/racket/collects/pkg/main.rkt:216:16
   (submod 
"/gnu/store/4f148vh30qmrdl6apq1ff6yqb7kl8xlm-racket-minimal-7.8/share/racket/collects/pkg/main.rkt"
 main): [running body]
   temp35_0
   for-loop
   run-module-instance!
   for-loop
   [repeats 1 more time]
   run-module-instance!
   
"/gnu/store/4f148vh30qmrdl6apq1ff6yqb7kl8xlm-racket-minimal-7.8/share/racket/collects/raco/raco.rkt":
 [running body]
   temp35_0
   for-loop
   run-module-instance!
   
"/gnu/store/4f148vh30qmrdl6apq1ff6yqb7kl8xlm-racket-minimal-7.8/share/racket/collects/raco/main.rkt":
 [running body]
   ...
Inferred package name from given `--clone' path
  package: source
  given path: /tmp/guix-build-racket-hello-racket-0.0.1.drv-0/source
command "raco" "pkg" "install" "--no-cache" "--no-setup" "--ignore-checksums" 
"--clone" "/tmp/guix-build-racket-hello-racket-0.0.1.drv-0/source" failed with 
status 1
builder for 
`/gnu/store/filph2d8m7k1rq6rpglwx1y082ris6g0-racket-hello-racket-0.0.1.drv' 
failed with exit code 1
build of 
/gnu/store/filph2d8m7k1rq6rpglwx1y082ris6g0-racket-hello-racket-0.0.1.drv failed
View build log at 
'/var/log/guix/drvs/fi/lph2d8m7k1rq6rpglwx1y082ris6g0-racket-hello-racket-0.0.1.drv.bz2'.
guix build: error: build of 
`/gnu/store/filph2d8m7k1rq6rpglwx1y082ris6g0-racket-hello-racket-0.0.1.drv' 
failed

--8<---------------cut here---------------end--------------->8---

And when troubleshooting:

--8<---------------cut here---------------start------------->8---
cd /tmp/guix-build-racket-hello-racket-0.0.1.drv-0

/home/bonface/guix/pre-inst-env guix environment \
--no-grafts -C racket-hello-racket --ad-hoc strace gdb

source ./environment-variables

$GUIX_ENVIRONMENT/bin/raco pkg install --no-cache \
--no-setup --ignore-checksums

--8<---------------cut here---------------end--------------->8---

Which works just fine since I'm updating files
inside $GUIX_ENVIRONMENT. Right now I'm looking
for ideas to experiment with to try to overcome
this, and the low hanging fruit is to successfully
build a hello-racket package with zero deps and no
tests.

To simply put it, AFAIU updating a package would
require racket to update it's references(either
links, and other references that I won't go into),
hence creating some form of "global state";
thereby if you use raco, every package updated
would lead to some update with racket's search
paths or dirs somewhere. Any ideas to overcome
this wall? (or anything I've got wrong somewhere?)


Attachment: racket-build-system.scm
Description: /build/racket-build-system

Attachment: racket.scm
Description: build-system/racket.scm

-- 
Bonface M. K. <https://www.bonfacemunyoki.com>
Chief Emacs Bazu / Rieng ya software sare
Mchochezi of: <https://upbookclub.com> / Twitter: @BonfaceKilz
GPG Key: D4F09EB110177E03C28E2FE1F5BBAE1E0392253F

Attachment: signature.asc
Description: PGP signature


reply via email to

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