unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#60192] [PATCH] gnu: Add python-tcod.
@ 2022-12-18 21:02 Adam Kandur via Guix-patches via
  2023-01-26  9:51 ` Ludovic Courtès
  2023-03-22 11:00 ` [bug#60192] Update on issue Adam Kandur
  0 siblings, 2 replies; 4+ messages in thread
From: Adam Kandur via Guix-patches via @ 2022-12-18 21:02 UTC (permalink / raw)
  To: 60192; +Cc: Adam Kandur

* gnu/packages/game-development.scm (python-tcod): New variable.
---
 gnu/packages/game-development.scm | 47 +++++++++++++++++++++++++++++++
 1 file changed, 47 insertions(+)

diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm
index 8fec474d0b..2746c43a5f 100644
--- a/gnu/packages/game-development.scm
+++ b/gnu/packages/game-development.scm
@@ -64,6 +64,7 @@ (define-module (gnu packages game-development)
   #:use-module (gnu packages bash)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages build-tools)
+  #:use-module (gnu packages c)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages check)
   #:use-module (gnu packages curl)
@@ -86,6 +87,7 @@ (define-module (gnu packages game-development)
   #:use-module (gnu packages guile)
   #:use-module (gnu packages image)
   #:use-module (gnu packages linux)
+  #:use-module (gnu packages libffi)
   #:use-module (gnu packages llvm)
   #:use-module (gnu packages lua)
   #:use-module (gnu packages m4)
@@ -97,6 +99,7 @@ (define-module (gnu packages game-development)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages pulseaudio)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages python-check)
   #:use-module (gnu packages python-web)
   #:use-module (gnu packages python-xyz)
   #:use-module (gnu packages readline)
@@ -2604,6 +2607,50 @@ (define-public libtcod
 utilities frequently used in roguelikes.")
     (license license:bsd-3)))
 
+(define-public python-tcod
+  ;; named branch is outdated
+  (let ((commit "d3419a5b4593c7df1580427fc07616d798c85856")
+        (revision "1"))
+    (package
+      (name "python-tcod")
+      (version "13.9.1")
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/libtcod/python-tcod")
+               (commit commit)
+               (recursive? #true)))
+         (file-name (git-file-name name version))
+         (sha256
+          (base32
+           "1b0ligrswvz307bbx5jp8wnnqz52v5s4gcgakxy4i3jvccalm2if"))))
+      (build-system python-build-system)
+      ;; tests fail for a strange reason
+      ;; "ERROR docs/conf.py - FileNotFoundError",
+      ;; but this file is in the checkout
+      (arguments
+       '(#:tests? #f))
+      (native-inputs
+       (list sdl2
+             python-pcpp
+             python-pycparser
+             python-requests
+             python-pytest-runner
+             python-pytest-benchmark
+             python-pytest-cov))
+      (propagated-inputs
+       (list python-numpy
+             python-typing-extensions
+             python-cffi))
+      (home-page "https://github.com/libtcod/python-tcod")
+      (synopsis
+       "This library is a Python cffi port of libtcod")
+      (description
+       "A high-performance Python port of libtcod.
+Includes the libtcodpy module for backwards compatibility with older projects.")
+      (license license:bsd-2))))
+
 (define-public warsow-qfusion
   ;; As of 2020-04-09, the latest stable version 2.1.0 is deprecated.
   ;; The 2.5 beta as published on the homepage is commit
-- 
2.38.1





^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#60192] [PATCH] gnu: Add python-tcod.
  2022-12-18 21:02 [bug#60192] [PATCH] gnu: Add python-tcod Adam Kandur via Guix-patches via
@ 2023-01-26  9:51 ` Ludovic Courtès
  2023-01-26 17:51   ` Adam Kandur via Guix-patches via
  2023-03-22 11:00 ` [bug#60192] Update on issue Adam Kandur
  1 sibling, 1 reply; 4+ messages in thread
From: Ludovic Courtès @ 2023-01-26  9:51 UTC (permalink / raw)
  To: Adam Kandur; +Cc: 60192

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

Hi,

Adam Kandur <manualbot@icloud.com> skribis:

> * gnu/packages/game-development.scm (python-tcod): New variable.

I suggest the attached changes.

However, one comment:

> +      ;; tests fail for a strange reason
> +      ;; "ERROR docs/conf.py - FileNotFoundError",
> +      ;; but this file is in the checkout
> +      (arguments
> +       '(#:tests? #f))
> +      (native-inputs
> +       (list sdl2
> +             python-pcpp
> +             python-pycparser
> +             python-requests
> +             python-pytest-runner
> +             python-pytest-benchmark
> +             python-pytest-cov))
> +      (propagated-inputs
> +       (list python-numpy
> +             python-typing-extensions
> +             python-cffi))
> +      (home-page "https://github.com/libtcod/python-tcod")
> +      (synopsis
> +       "This library is a Python cffi port of libtcod")

That ‘FileNotFoundError’, could it be because libtcod itself is missing?
I would expect libtocd to be in ‘inputs’ since this package provides
bindings to libtcod, no?

> +      (description
> +       "A high-performance Python port of libtcod.
> +Includes the libtcodpy module for backwards compatibility with older projects.")

Please improve the synopsis and description as per:

  https://guix.gnu.org/manual/en/html_node/Synopses-and-Descriptions.html

Could you send an updated patch?

Thanks,
Ludo’.


[-- Attachment #2: Type: text/plain, Size: 980 bytes --]

diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm
index 304df3bd75..dd08241080 100644
--- a/gnu/packages/game-development.scm
+++ b/gnu/packages/game-development.scm
@@ -2584,11 +2584,12 @@ (define-public python-tcod
     (package
       (name "python-tcod")
       (version "13.9.1")
+      (home-page "https://github.com/libtcod/python-tcod")
       (source
        (origin
          (method git-fetch)
          (uri (git-reference
-               (url "https://github.com/libtcod/python-tcod")
+               (url home-page)
                (commit commit)
                (recursive? #true)))
          (file-name (git-file-name name version))
@@ -2613,7 +2614,6 @@ (define-public python-tcod
        (list python-numpy
              python-typing-extensions
              python-cffi))
-      (home-page "https://github.com/libtcod/python-tcod")
       (synopsis
        "This library is a Python cffi port of libtcod")
       (description

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#60192] [PATCH] gnu: Add python-tcod.
  2023-01-26  9:51 ` Ludovic Courtès
@ 2023-01-26 17:51   ` Adam Kandur via Guix-patches via
  0 siblings, 0 replies; 4+ messages in thread
From: Adam Kandur via Guix-patches via @ 2023-01-26 17:51 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 60192

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

Sure, I will fix my patch and will try to build the package with suggested input (probably next week).On Jan 26, 2023, at 1:51 AM, Ludovic Courtès <ludo@gnu.org> wrote:Hi,Adam Kandur <manualbot@icloud.com> skribis:* gnu/packages/game-development.scm (python-tcod): New variable.I suggest the attached changes.However, one comment:+      ;; tests fail for a strange reason+      ;; "ERROR docs/conf.py - FileNotFoundError",+      ;; but this file is in the checkout+      (arguments+       '(#:tests? #f))+      (native-inputs+       (list sdl2+             python-pcpp+             python-pycparser+             python-requests+             python-pytest-runner+             python-pytest-benchmark+             python-pytest-cov))+      (propagated-inputs+       (list python-numpy+             python-typing-extensions+             python-cffi))+      (home-page "https://github.com/libtcod/python-tcod")+      (synopsis+       "This library is a Python cffi port of libtcod")That ‘FileNotFoundError’, could it be because libtcod itself is missing?I would expect libtocd to be in ‘inputs’ since this package providesbindings to libtcod, no?+      (description+       "A high-performance Python port of libtcod.+Includes the libtcodpy module for backwards compatibility with older projects.")Please improve the synopsis and description as per: https://guix.gnu.org/manual/en/html_node/Synopses-and-Descriptions.htmlCould you send an updated patch?Thanks,Ludo’.diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scmindex 304df3bd75..dd08241080 100644--- a/gnu/packages/game-development.scm+++ b/gnu/packages/game-development.scm@@ -2584,11 +2584,12 @@ (define-public python-tcod (package (name "python-tcod") (version "13.9.1")+      (home-page "https://github.com/libtcod/python-tcod") (source (origin (method git-fetch) (uri (git-reference-               (url "https://github.com/libtcod/python-tcod")+               (url home-page) (commit commit) (recursive? #true))) (file-name (git-file-name name version))@@ -2613,7 +2614,6 @@ (define-public python-tcod (list python-numpy python-typing-extensions python-cffi))-      (home-page "https://github.com/libtcod/python-tcod") (synopsis "This library is a Python cffi port of libtcod") (description

[-- Attachment #2.1: Type: text/html, Size: 4116 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#60192] Update on issue
  2022-12-18 21:02 [bug#60192] [PATCH] gnu: Add python-tcod Adam Kandur via Guix-patches via
  2023-01-26  9:51 ` Ludovic Courtès
@ 2023-03-22 11:00 ` Adam Kandur
  1 sibling, 0 replies; 4+ messages in thread
From: Adam Kandur @ 2023-03-22 11:00 UTC (permalink / raw)
  To: 60192

Hi guix!
First of all, sorry for the late reply.
So, there are 2 problems with this package - turned off tests and
wrong synopsis and description. So I tried to fix it and here is my
suggestions:

1) I have added libtcod to propagated-inputs. Which seems reasonable
because this package provides bindings to it. But unfortunately this
didn't solve the problem with tests. Without them the package works
fine and can be used in projects.

2) I suggest these synopsis and description
      (synopsis
       "Python port of libtcod")
      (description
       "Python package which provides bindings to libtcod.  This allows Python
users to use libtcod in their Python projects.  libtcod itself is a collection
of tools and algorithms for developing traditional roguelikes.  Such as
field-of-view, pathfinding, and a tile-based terminal emulator.")

So if these changes are acceptable, can I resend an updated version?




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-03-22 11:01 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-18 21:02 [bug#60192] [PATCH] gnu: Add python-tcod Adam Kandur via Guix-patches via
2023-01-26  9:51 ` Ludovic Courtès
2023-01-26 17:51   ` Adam Kandur via Guix-patches via
2023-03-22 11:00 ` [bug#60192] Update on issue Adam Kandur

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).