Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

Hi, I'm trying to build this "from source" by running `guix build -f guix.scm` on f022cdbd6cae6fa8c8d7596be5812fbf45ca6a9a, but I get the following error:

starting phase `unpack'
Backtrace:
           9 (primitive-load "/gnu/store/y9smaha1da8szrjd0y7dd0v0d59…")
In ice-9/eval.scm:
   191:35  8 (_ #f)
In guix/build/gnu-build-system.scm:
    838:2  7 (gnu-build #:source _ #:outputs _ #:inputs _ #:phases . #)
In ice-9/boot-9.scm:
  1736:10  6 (with-exception-handler _ _ #:unwind? _ # _)
In srfi/srfi-1.scm:
   857:16  5 (every1 #<procedure 7ffff59b1b60 at guix/build/gnu-bui…> …)
In guix/build/gnu-build-system.scm:
   847:30  4 (_ _)
    151:6  3 (unpack #:source _)
In ice-9/boot-9.scm:
  1966:24  2 (_ _)
In unknown file:
           1 (stat #f #<undefined>)
In ice-9/boot-9.scm:
  1669:16  0 (raise-exception _ #:continuable? _)
ice-9/boot-9.scm:1669:16: In procedure raise-exception:
In procedure stat: Wrong type argument in position 1 (expecting open file port): #f
builder for `/gnu/store/is4874z0z2i9fn2n6jsqlhjshf3vzz3m-spring-lisp-game-jam-2021-0.1.drv' failed with exit code 1

The following patch fixes it:

From d8321a5792811021f5e420ebf9cb6a3d35e8796e Mon Sep 17 00:00:00 2001
From: Leo Prikler <leo.prikler@student.tugraz.at>
Date: Mon, 26 Apr 2021 16:54:26 +0200
Subject: [PATCH] Allow building from source.
---
 guix.scm | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/guix.scm b/guix.scm
index 5338156..924e8f2 100644
--- a/guix.scm
+++ b/guix.scm
@@ -2,6 +2,7 @@
              (srfi srfi-1)
              (guix build-system gnu)
              (guix download)
+             (guix gexp)
              (guix git-download)
              ((guix licenses) #:prefix license:)
              (guix packages)
@@ -175,10 +176,16 @@ yet.")
      (home-page "https://git.dthompson.us/starling.git")
      (license license:gpl3+))))
+(define %source-dir (dirname (current-filename)))
+
 (package
   (name "spring-lisp-game-jam-2021")
   (version "0.1")
-  (source #f)
+  (source
+   (local-file %source-dir #:recursive? #t
+               #:select? (if (file-exists? (string-append %source-dir "/.git"))
+                             (git-predicate %source-dir)
+                             (const #t))))
   (build-system gnu-build-system)
   (native-inputs
    `(("autoconf" ,autoconf)
-- 
2.31.1

`guix build -f` currently isn't supported. For now run `guix environment -l guix.scm` and build from source that way. Instructions are in the README. I can try to make guix.scm a true buildable package soon.

Hacking guix.scm for an ad-hoc environment felt like a better idea at the time, so I did that. On a somewhat related note, do you really need to patch Guile itself? My gut instinct tells me you should be able to ship a patched GOOPS with starling similarly to how I used a "magic" module to introduce pre-release Guile-SDL2 functionality to Tsukundere.

I suppose I could include a modified copy of goops.scm and take advantage of load order to have my version loaded.  Might try that later. At the time I wanted to test a full Guile build since I submitted the patch upstream and wanted a true integration test, but the patch got merged awhile ago so it's no longer necessary. Thanks for the suggestion.