GNU bug report logs - #43630
[PATCH] gnu: Add tic-80.

Previous Next

Package: guix-patches;

Reported by: Gabriel Arazas <foo.dogsquared <at> gmail.com>

Date: Sat, 26 Sep 2020 10:20:01 UTC

Severity: normal

Tags: patch

To reply to this bug, email your comments to 43630 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#43630; Package guix-patches. (Sat, 26 Sep 2020 10:20:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Gabriel Arazas <foo.dogsquared <at> gmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sat, 26 Sep 2020 10:20:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Gabriel Arazas <foo.dogsquared <at> gmail.com>
To: guix-patches <at> gnu.org
Subject: [PATCH] gnu: Add tic-80.
Date: Sat, 26 Sep 2020 18:17:37 +0800
TIC-80 features a PRO version that you can easily compile it for yourself
(just add DBUILD_PRO=TRUE to CMake configure flags).
Out of respect, the package is compiling the free version unless someone disagrees.






Information forwarded to guix-patches <at> gnu.org:
bug#43630; Package guix-patches. (Sat, 26 Sep 2020 10:21:01 GMT) Full text and rfc822 format available.

Message #8 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Gabriel Arazas <foo.dogsquared <at> gmail.com>
To: guix-patches <at> gnu.org
Cc: Gabriel Arazas <foo.dogsquared <at> gmail.com>
Subject: [PATCH] gnu: Add tic-80.
Date: Sat, 26 Sep 2020 18:17:38 +0800
* gnu/packages/game-development.scm (tic-80): New variable.
---
 gnu/packages/game-development.scm | 57 +++++++++++++++++++++++++++++++
 1 file changed, 57 insertions(+)

diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm
index 3252eb322e..3d0b2e7413 100644
--- a/gnu/packages/game-development.scm
+++ b/gnu/packages/game-development.scm
@@ -20,6 +20,7 @@
 ;;; Copyright © 2020 Nicolas Goaziou <mail <at> nicolasgoaziou.fr>
 ;;; Copyright © 2020 Timotej Lazar <timotej.lazar <at> araneo.si>
 ;;; Copyright © 2020 Giacomo Leidi <goodoldpaul <at> autistici.org>
+;;; Copyright © 2020 Gabriel Arazas <foo.dogsquared <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -2477,3 +2478,59 @@ fully dynamic omnidirectional shadows, global illumination, HDR lighting,
 deferred shading, morphological / temporal / multisample anti-aliasing, and
 much more.")
       (license license:zlib))))
+
+(define-public tic-80
+  ;; TODO: Package TIC-80 with an additional output as a WASM module.
+  (package
+    (name "tic-80")
+    (version "0.80.1344")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/nesbox/TIC-80")
+                    (commit (string-append "v" version))
+                    (recursive? #t)))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0b1qm1m1wwss4bh3q8gx26kk4g8j4n9mzdd4lbyj7k37fx5v09rp"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:tests? #f                      ; No tests.
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-source
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let* ((out (assoc-ref outputs "out"))
+                    (bin (string-append out "/bin"))
+                    (share/applications (string-append out "/share/applications"))
+                    (share/icons (string-append out "/share/icons")))
+               (substitute* "CMakeLists.txt"
+                 ;; Replace the destinations to be inline with Guix.
+                 (("/usr/share/applications") bin)
+                 (("/usr/share/icons") share/icons)
+                 (("\\$\\{TIC80_DESKTOP_DIR}") share/applications))
+
+               ;; The files inside of the folder should have write permissions
+               ;; but it will be overwritten by the build process anyways so it
+               ;; is faster to delete them instead.
+               (delete-file-recursively "build/assets")
+               (mkdir-p "build/assets"))
+             #t)))))
+    (inputs
+     `(("alsa-lib" ,alsa-lib)
+       ("curl" ,curl)
+       ("freeglut" ,freeglut)
+       ("glu" ,glu)
+       ("gtk+" ,gtk+)
+       ("mesa" ,mesa)))
+    (native-inputs
+     `(("pkg-config" ,pkg-config)))
+    (home-page "https://tic80.com")
+    (synopsis "Fantasy computer with built-in tools for game development")
+    (description
+     "A fantasy computer featuring built-in tools such as a sprite editor,
+music tracker, and a text editor.  This package builds the free version of the
+software which you can override the package and build the PRO version
+yourself.")
+    (license license:expat)))
-- 
2.28.0





Information forwarded to guix-patches <at> gnu.org:
bug#43630; Package guix-patches. (Wed, 28 Oct 2020 15:12:02 GMT) Full text and rfc822 format available.

Message #11 received at 43630 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Gabriel Arazas <foo.dogsquared <at> gmail.com>
Cc: 43630 <at> debbugs.gnu.org
Subject: Re: [bug#43630] [PATCH] gnu: Add tic-80.
Date: Wed, 28 Oct 2020 16:11:07 +0100
Hi Gabriel,

Sorry for the long delay!

Gabriel Arazas <foo.dogsquared <at> gmail.com> skribis:

> * gnu/packages/game-development.scm (tic-80): New variable.

[...]

> +    (description
> +     "A fantasy computer featuring built-in tools such as a sprite editor,
> +music tracker, and a text editor.  This package builds the free version of the
> +software which you can override the package and build the PRO version
> +yourself.")

We need full sentences and, as per the FSDG, we won’t advertise the
“PRO” version (which is non-free I guess?) here.  So instead I propose
this:

    (description
     "TIC-80 is a fantasy computer for making, playing and sharing tiny games.
There are built-in tools for development: code, sprites, maps, sound editors
and the command line, which is enough to create a mini retro game.  At the
exit you will get a cartridge file, which can be stored and played on the
website.")

Another issue: the code bundles quite a few libraries.  We should remove
them in a snippet and use the corresponding packages instead.  Here’s
what I see in the log:

--8<---------------cut here---------------start------------->8---
Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/sdl2'...
Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/sokol'...
Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/squirrel'...
Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/wren'...
Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/zip'...
Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/zlib'...
--8<---------------cut here---------------end--------------->8---

‘sokol’ and ‘wren’ are apparently not packaged yet in Guix.  As a first
step, you could remove everything but these two libraries, leaving a
FIXME about them.

Could you send an updated patch?

Thanks,
Ludo’.




Information forwarded to guix-patches <at> gnu.org:
bug#43630; Package guix-patches. (Sun, 27 Dec 2020 23:10:02 GMT) Full text and rfc822 format available.

Message #14 received at 43630 <at> debbugs.gnu.org (full text, mbox):

From: Björn Höfling <bjoern.hoefling <at> bjoernhoefling.de>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 43630 <at> debbugs.gnu.org, Gabriel Arazas <foo.dogsquared <at> gmail.com>
Subject: Re: [bug#43630] [PATCH] gnu: Add tic-80.
Date: Mon, 28 Dec 2020 00:09:50 +0100
[Message part 1 (text/plain, inline)]
Hi Gabriel,

ping!

Would you like to send an updated patch with Ludovic's suggestions
included?

Thanks,

Björn

 On Wed, 28 Oct 2020 16:11:07 +0100
Ludovic Courtès <ludo <at> gnu.org> wrote:

> Hi Gabriel,
> 
> Sorry for the long delay!
> 
> Gabriel Arazas <foo.dogsquared <at> gmail.com> skribis:
> 
> > * gnu/packages/game-development.scm (tic-80): New variable.  
> 
> [...]
> 
> > +    (description
> > +     "A fantasy computer featuring built-in tools such as a sprite
> > editor, +music tracker, and a text editor.  This package builds the
> > free version of the +software which you can override the package
> > and build the PRO version +yourself.")  
> 
> We need full sentences and, as per the FSDG, we won’t advertise the
> “PRO” version (which is non-free I guess?) here.  So instead I propose
> this:
> 
>     (description
>      "TIC-80 is a fantasy computer for making, playing and sharing
> tiny games. There are built-in tools for development: code, sprites,
> maps, sound editors and the command line, which is enough to create a
> mini retro game.  At the exit you will get a cartridge file, which
> can be stored and played on the website.")
> 
> Another issue: the code bundles quite a few libraries.  We should
> remove them in a snippet and use the corresponding packages instead.
> Here’s what I see in the log:
> 
> --8<---------------cut here---------------start------------->8---
> Cloning into
> '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/sdl2'...
> Cloning into
> '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/sokol'...
> Cloning into
> '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/squirrel'...
> Cloning into
> '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/wren'...
> Cloning into
> '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/zip'...
> Cloning into
> '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/zlib'...
> --8<---------------cut here---------------end--------------->8---
> 
> ‘sokol’ and ‘wren’ are apparently not packaged yet in Guix.  As a
> first step, you could remove everything but these two libraries,
> leaving a FIXME about them.
> 
> Could you send an updated patch?
> 
> Thanks,
> Ludo’.
> 
> 

[Message part 2 (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#43630; Package guix-patches. (Thu, 22 Jul 2021 22:33:02 GMT) Full text and rfc822 format available.

Message #17 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Chris Lemmer-Webber <cwebber <at> dustycloud.org>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 43630 <at> debbugs.gnu.org, Gabriel Arazas <foo.dogsquared <at> gmail.com>,
 guix-patches <at> gnu.org
Subject: Re: [bug#43630] [PATCH] gnu: Add tic-80.
Date: Thu, 22 Jul 2021 18:32:22 -0400
I don't have a version fulfilling all the changes Ludo' recommended,
but I got this to build and run on my computer based on Gabriel's patch.

I also tried bumping to the latest version (v0.90.1706) but curiously
that one built fine but segfaults when you try to run it... some
floating point exception.  Just noting that in case someone is picking
this up and trying to advance it.

Ludovic Courtès writes:

> Hi Gabriel,
>
> Sorry for the long delay!
>
> Gabriel Arazas <foo.dogsquared <at> gmail.com> skribis:
>
>> * gnu/packages/game-development.scm (tic-80): New variable.
>
> [...]
>
>> +    (description
>> +     "A fantasy computer featuring built-in tools such as a sprite editor,
>> +music tracker, and a text editor.  This package builds the free version of the
>> +software which you can override the package and build the PRO version
>> +yourself.")
>
> We need full sentences and, as per the FSDG, we won’t advertise the
> “PRO” version (which is non-free I guess?) here.  So instead I propose
> this:
>
>     (description
>      "TIC-80 is a fantasy computer for making, playing and sharing tiny games.
> There are built-in tools for development: code, sprites, maps, sound editors
> and the command line, which is enough to create a mini retro game.  At the
> exit you will get a cartridge file, which can be stored and played on the
> website.")
>
> Another issue: the code bundles quite a few libraries.  We should remove
> them in a snippet and use the corresponding packages instead.  Here’s
> what I see in the log:
>
> --8<---------------cut here---------------start------------->8---
> Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/sdl2'...
> Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/sokol'...
> Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/squirrel'...
> Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/wren'...
> Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/zip'...
> Cloning into '/gnu/store/hb5kz8vrk5ykyc3xmx30h20f2bm7pmcp-tic-80-0.80.1344-checkout/vendor/zlib'...
> --8<---------------cut here---------------end--------------->8---
>
> ‘sokol’ and ‘wren’ are apparently not packaged yet in Guix.  As a first
> step, you could remove everything but these two libraries, leaving a
> FIXME about them.
>
> Could you send an updated patch?
>
> Thanks,
> Ludo’.





Information forwarded to guix-patches <at> gnu.org:
bug#43630; Package guix-patches. (Thu, 22 Jul 2021 22:33:02 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 120 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.