Add guile-goblins

DoneSubmitted by Christine Lemmer-Webber.
Details
3 participants
  • Christine Lemmer-Webber
  • Ludovic Courtès
  • Maxime Devos
Owner
unassigned
Severity
normal
C
C
Christine Lemmer-Webber wrote on 24 Jun 23:24 +0200
(address . guix-patches@gnu.org)
87sfntlpns.fsf@dustycloud.org
Finally! ;)

It's a pretty small change, just adding a leaf package, but I figured
since it's adding a package I maintain the project of, best to get
review.

- Christine
From a09c70dac11dcc133c8e86c3c7e953019942e00c Mon Sep 17 00:00:00 2001
From: Christine Lemmer-Webber <cwebber@dustycloud.org>
Date: Fri, 24 Jun 2022 14:28:56 -0400
Subject: [PATCH] gnu: Add guile-goblins.

* gnu/packages/guile-xyz.scm (guile-goblins): New variable.
---
gnu/packages/guile-xyz.scm | 42 +++++++++++++++++++++++++++++++++++++-
1 file changed, 41 insertions(+), 1 deletion(-)

Toggle diff (59 lines)
diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm
index 2ed6617fd2..853dfa832e 100644
--- a/gnu/packages/guile-xyz.scm
+++ b/gnu/packages/guile-xyz.scm
@@ -1,7 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2012-2022 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2014, 2015, 2018 Mark H Weaver <mhw@netris.org>
-;;; Copyright © 2015, 2017 Christine Lemmer-Webber <cwebber@dustycloud.org>
+;;; Copyright © 2015, 2017, 2022 Christine Lemmer-Webber <cwebber@dustycloud.org>
 ;;; Copyright © 2016 Alex Sassmannshausen <alex@pompo.co>
 ;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021, 2022 Ricardo Wurmus <rekado@elephly.net>
 ;;; Copyright © 2016 Erik Edrosa <erik.edrosa@gmail.com>
@@ -5103,3 +5103,43 @@ (define-public guile-termios
 termios API is used.  GNU Guile doesn't have an interface for that built in.
 This module implements this interface by use of Guile's dynamic FFI.")
     (license license:bsd-2)))
+
+(define-public guile-goblins
+  (package
+    (name "guile-goblins")
+    (version "0.8")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://gitlab.com/spritely/guile-goblins/")
+             (commit (string-append "v" version))))
+       (file-name (string-append name "-" version))
+       (sha256
+        (base32
+         "1mmyykh79jwhrfgnhhw94aw7a8m6qw249kj7k60ynj16mcfm5iyy"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (replace 'bootstrap
+           (lambda _
+             (invoke "autoreconf" "-vif"))))
+       #:make-flags
+       ,#~(list "GUILE_AUTO_COMPILE=0")))
+    (native-inputs
+     (list autoconf automake pkg-config texinfo))
+    (inputs
+     `(("guile" ,guile-3.0)))
+    (propagated-inputs
+     (list guile-fibers guile-gcrypt))
+    (home-page "https://spritely.institute/goblins")
+    (synopsis "Distributed programming environment for Guile")
+    (description
+     "@code{guile-goblins} is the Guile version of
+@url{https://spritely.institute/goblins, Spritely Goblins},
+a transactional, distributed programming environment following object
+capability security designs.  Goblins is a general toolkit, and also
+the core layer of Spritely's work to support healthy distributed
+networked communities.")
+    (license license:asl2.0)))
-- 
2.36.1
M
M
Maxime Devos wrote on 24 Jun 23:57 +0200
5119fa39ab7e05a49635b624da4d46e1ecb5459b.camel@telenet.be
Christine Lemmer-Webber schreef op vr 24-06-2022 om 17:24 [-0400]:
Toggle quote (7 lines)
> +    (arguments
> +     `(#:phases
> +       (modify-phases %standard-phases
> +         (replace 'bootstrap
> +           (lambda _
> +             (invoke "autoreconf" "-vif"))))

I don't know if it works in this particular case, but I thought that
normally 'bootstrap' would automatically do that already?

Toggle quote (3 lines)
> +       #:make-flags
> +       ,#~(list "GUILE_AUTO_COMPILE=0")))

Nesting different forms of quasiquotation seems to be disliked (at
least according to a mini poll I did on #guix some time ago),
apparently

(arguments
(list #:phases
#~(modify-phases ...)
#:make-flags
#~(list ...)))

seems to be the way to go?


Toggle quote (5 lines)
> +    (native-inputs
> +     (list autoconf automake pkg-config texinfo))
> +    (inputs
> +     `(("guile" ,guile-3.0)))

Can be simplified to (inputs (list guile-3.0))?


Toggle quote (7 lines)
> + "@code{guile-goblins} is the Guile version of
> + @url{https://spritely.institute/goblins, Spritely Goblins},
> +a transactional, distributed programming environment following object
> +capability security designs. Goblins is a general toolkit, and also
> +the core layer of Spritely's work to support healthy distributed
> +networked communities.")

Maybe mention that it can network with non-Guile goblin peers as well
(e.g. Racket?), assuming that's correct?

Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYrYzZhccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7iQhAQDfD2K83j9I8D949elDlHFfx/Jf
5Fbm6DUjvfPzvEGOmAD/QU+z//1On0+RNidckMJVkrX0nAX0N/pvrgPE6g6ihQ4=
=bQB0
-----END PGP SIGNATURE-----


M
M
Maxime Devos wrote on 25 Jun 11:32 +0200
4e2b670f22b19164f7307a3a6579f84d96368dbf.camel@telenet.be
Christine Lemmer-Webber schreef op vr 24-06-2022 om 17:24 [-0400]:
Toggle quote (13 lines)
> +    (version "0.8")
> +    (source
> +     (origin
> +       (method git-fetch)
> +       (uri (git-reference
> +             (url "https://gitlab.com/spritely/guile-goblins/")
> +             (commit (string-append "v" version))))
> +       (file-name (string-append name "-" version))
> +       (sha256
> +        (base32
> +         "1mmyykh79jwhrfgnhhw94aw7a8m6qw249kj7k60ynj16mcfm5iyy"))))


I'm not seeing "--target" in the invocation of "$(GUILE_TOOLS)
compile", so I don't think that currently it will cross-compile
correctly. Could you add a --target=... in the Makefile.am?

Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYrbWIBccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7pxnAP91qrlqD5BMrL2Vj4hCnqPHtuR8
v2r7VOfA/3BJTZ7NFwD/R+3qquDDdzl6i4GR5X61y1r3fsCOVvLNZyJ8PHYsdAQ=
=BAtY
-----END PGP SIGNATURE-----


L
L
Ludovic Courtès wrote on 25 Jun 23:46 +0200
Re: bug#56204: Add guile-goblins
(name . Maxime Devos)(address . maximedevos@telenet.be)
87zgi0s9f8.fsf_-_@gnu.org
Maxime Devos <maximedevos@telenet.be> skribis:
Toggle quote (17 lines)
> Christine Lemmer-Webber schreef op vr 24-06-2022 om 17:24 [-0400]:
>> +    (version "0.8")
>> +    (source
>> +     (origin
>> +       (method git-fetch)
>> +       (uri (git-reference
>> +             (url "https://gitlab.com/spritely/guile-goblins/")
>> +             (commit (string-append "v" version))))
>> +       (file-name (string-append name "-" version))
>> +       (sha256
>> +        (base32
>> +         "1mmyykh79jwhrfgnhhw94aw7a8m6qw249kj7k60ynj16mcfm5iyy"))))
>
>
> I'm not seeing "--target" in the invocation of "$(GUILE_TOOLS)
> compile", so I don't think that currently it will cross-compile
> correctly. Could you add a --target=... in the Makefile.am?
That can come upstream in the next version of Goblins IMO.
Ludo’.
L
L
Ludovic Courtès wrote on 25 Jun 23:49 +0200
(name . Christine Lemmer-Webber)(address . cwebber@dustycloud.org)(address . 56204@debbugs.gnu.org)
87v8sos9bk.fsf@gnu.org
Hello Christine,

Christine Lemmer-Webber <cwebber@dustycloud.org> skribis:

Toggle quote (7 lines)
>>From a09c70dac11dcc133c8e86c3c7e953019942e00c Mon Sep 17 00:00:00 2001
> From: Christine Lemmer-Webber <cwebber@dustycloud.org>
> Date: Fri, 24 Jun 2022 14:28:56 -0400
> Subject: [PATCH] gnu: Add guile-goblins.
>
> * gnu/packages/guile-xyz.scm (guile-goblins): New variable.

Woohoo, awesome!

I agree with the minor issues Maxime noted, but otherwise looks great
to me! Go Spritely, go!!

Ludo’.
C
C
Christine Lemmer-Webber wrote on 26 Jun 21:09 +0200
(name . Ludovic Courtès)(address . ludo@gnu.org)
87edzbjl2h.fsf@dustycloud.org
Ludovic Courtès <ludo@gnu.org> writes:

Toggle quote (24 lines)
> Maxime Devos <maximedevos@telenet.be> skribis:
>
>> Christine Lemmer-Webber schreef op vr 24-06-2022 om 17:24 [-0400]:
>>> +    (version "0.8")
>>> +    (source
>>> +     (origin
>>> +       (method git-fetch)
>>> +       (uri (git-reference
>>> +             (url "https://gitlab.com/spritely/guile-goblins/")
>>> +             (commit (string-append "v" version))))
>>> +       (file-name (string-append name "-" version))
>>> +       (sha256
>>> +        (base32
>>> +         "1mmyykh79jwhrfgnhhw94aw7a8m6qw249kj7k60ynj16mcfm5iyy"))))
>>
>>
>> I'm not seeing "--target" in the invocation of "$(GUILE_TOOLS)
>> compile", so I don't think that currently it will cross-compile
>> correctly. Could you add a --target=... in the Makefile.am?
>
> That can come upstream in the next version of Goblins IMO.
>
> Ludo’.

Cool, I added it to commit 6664daa27e9b3eb3220ba83d9c874b730e792f90 in
guile-goblins. However I was just mimicing guile-gcrypt, so I'm not
sure if it's right:

#+BEGIN_SRC diff
Toggle diff (23 lines)
diff --git a/Makefile.am b/Makefile.am
index b8d4944..b056337 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -32,7 +32,7 @@ EXTRA_DIST = $(SOURCES) $(NOCOMP_SOURCES)
 GUILE_WARNINGS = -Wunbound-variable -Warity-mismatch -Wformat
 SUFFIXES = .scm .go
 .scm.go:
-	$(AM_V_GEN)$(top_builddir)/pre-inst-env $(GUILE_TOOLS) compile $(GUILE_WARNINGS) -o "$@" "$<"
+	$(AM_V_GEN)$(top_builddir)/pre-inst-env $(GUILE_TOOLS) compile $(GUILE_TARGET) $(GUILE_WARNINGS) -o "$@" "$<"
 
 SOURCES = goblins.scm \
           goblins/ocapn/crypto-stubs.scm \
#+END_SRC

Should that be sufficient?

Notably, the Makefile.am here was bootstrapped using guile-hall, so my
suspicion is that this is an update that should be made in guile-hall's
templates also, then everyone can benefit.

The next release of Goblins should be due out very quickly, I think, so
we'll be able to take advantage of it then.
C
C
Christine Lemmer-Webber wrote on 25 Jun 04:36 +0200
Re: [bug#56204] Add guile-goblins
(name . Maxime Devos)(address . maximedevos@telenet.be)(address . 56204-done@debbugs.gnu.org)
87v8sni5kk.fsf@dustycloud.org
Hey Maxime!

Maxime Devos <maximedevos@telenet.be> writes:

Toggle quote (12 lines)
> [[PGP Signed Part:Undecided]]
> Christine Lemmer-Webber schreef op vr 24-06-2022 om 17:24 [-0400]:
>> +    (arguments
>> +     `(#:phases
>> +       (modify-phases %standard-phases
>> +         (replace 'bootstrap
>> +           (lambda _
>> +             (invoke "autoreconf" "-vif"))))
>
> I don't know if it works in this particular case, but I thought that
> normally 'bootstrap' would automatically do that already?

Ah yeah, seems to work without it...!

Toggle quote (22 lines)
>> +       #:make-flags
>> +       ,#~(list "GUILE_AUTO_COMPILE=0")))
>
> Nesting different forms of quasiquotation seems to be disliked (at
> least according to a mini poll I did on #guix some time ago),
> apparently
>
> (arguments
> (list #:phases
> #~(modify-phases ...)
> #:make-flags
> #~(list ...)))
>
> seems to be the way to go?
>
>> +    (native-inputs
>> +     (list autoconf automake pkg-config texinfo))
>> +    (inputs
>> +     `(("guile" ,guile-3.0)))
>
> Can be simplified to (inputs (list guile-3.0))?

Cool, done. For (inputs ...) anyway... the above native-inputs did
still seem needed, presumably because we *are* running the bootstrap
code in this case.

Toggle quote (13 lines)
>> + "@code{guile-goblins} is the Guile version of
>> + @url{https://spritely.institute/goblins, Spritely Goblins},
>> +a transactional, distributed programming environment following object
>> +capability security designs. Goblins is a general toolkit, and also
>> +the core layer of Spritely's work to support healthy distributed
>> +networked communities.")
>
> Maybe mention that it can network with non-Guile goblin peers as well
> (e.g. Racket?), assuming that's correct?
>
> Greetings,
> Maxime.

It's true, but more accurately, it will be true in the next version,
since guile-goblins v0.8 doesn't have finished networking support.
But yes, that's coming, so I put this comment above the description:

;; In guile-goblins 0.9, OCapN support will be added (it already
;; exists in racket-goblins). At that point we should add the
;; following to this description:
;;
;; Goblins allows for cooperation between networked programs
;; in a mutually suspicious network through OCapN, the Object
;; Capability Network. This includes collaboration across
;; runtimes; for instance, programs written in the Guile and Racket
;; versions of Goblins are able to speak to each other.

And we can do that then. As said in the other email, I don't think this
is far away.

Thanks to both Maxime and Ludo' for reviewing! I pushed it upstream.
Happy hacking with guile-goblins... if someone does anything with it,
let me know. The next release will be the first big guile-goblins
release to celebrate, but was eager to get what we have up there. :)
Closed
M
M
Maxime Devos wrote on 26 Jun 22:50 +0200
Re: bug#56204: Add guile-goblins
(address . 56204@debbugs.gnu.org)
ec8f3c47d54d6f115b41175e3eb6f0c0b1e8ab23.camel@telenet.be
Christine Lemmer-Webber schreef op zo 26-06-2022 om 15:09 [-0400]:
Toggle quote (18 lines)
> #+BEGIN_SRC diff
> diff --git a/Makefile.am b/Makefile.am
> index b8d4944..b056337 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -32,7 +32,7 @@ EXTRA_DIST = $(SOURCES) $(NOCOMP_SOURCES)
>  GUILE_WARNINGS = -Wunbound-variable -Warity-mismatch -Wformat
>  SUFFIXES = .scm .go
>  .scm.go:
> - $(AM_V_GEN)$(top_builddir)/pre-inst-env $(GUILE_TOOLS) compile $(GUILE_WARNINGS) -o "$@" "$<"
> + $(AM_V_GEN)$(top_builddir)/pre-inst-env $(GUILE_TOOLS) compile $(GUILE_TARGET) $(GUILE_WARNINGS) -o "$@" "$<"
>  
>  SOURCES = goblins.scm \
>            goblins/ocapn/crypto-stubs.scm \
> #+END_SRC
>
> Should that be sufficient?

I think so (untested)?

Toggle quote (4 lines)
> Notably, the Makefile.am here was bootstrapped using guile-hall, so
> my suspicion is that this is an update that should be made in
> guile-hall's templates also, then everyone can benefit.

Agreed.

Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYrjGfxccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7tfTAQDgSlQHiPj1i/cFANTXvuKtQejA
xU9eP2w/kMjSydbvBQD+J6++sJHLfcnvgL6g7Vyl7edCHO2dlxNeuXWG6n/Zmg0=
=9VBa
-----END PGP SIGNATURE-----


L
L
Ludovic Courtès wrote on 27 Jun 12:22 +0200
(name . Christine Lemmer-Webber)(address . cwebber@dustycloud.org)
87ilomiexk.fsf@gnu.org
Hi,

Christine Lemmer-Webber <cwebber@dustycloud.org> skribis:

Toggle quote (18 lines)
> #+BEGIN_SRC diff
> diff --git a/Makefile.am b/Makefile.am
> index b8d4944..b056337 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -32,7 +32,7 @@ EXTRA_DIST = $(SOURCES) $(NOCOMP_SOURCES)
> GUILE_WARNINGS = -Wunbound-variable -Warity-mismatch -Wformat
> SUFFIXES = .scm .go
> .scm.go:
> - $(AM_V_GEN)$(top_builddir)/pre-inst-env $(GUILE_TOOLS) compile $(GUILE_WARNINGS) -o "$@" "$<"
> + $(AM_V_GEN)$(top_builddir)/pre-inst-env $(GUILE_TOOLS) compile $(GUILE_TARGET) $(GUILE_WARNINGS) -o "$@" "$<"
>
> SOURCES = goblins.scm \
> goblins/ocapn/crypto-stubs.scm \
> #+END_SRC
>
> Should that be sufficient?

Yes, that LGTM, provided GUILE_TARGET is properly computed, like in
Guile-Gcrypt’s ‘configure.ac’.

Thanks,
Ludo’.
?
Your comment

This issue is archived.

To comment on this conversation send email to 56204@debbugs.gnu.org