all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#39825] [PATCH] gnu: Add warsow-qfusion.
@ 2020-02-28 16:04 Pierre Neidhardt
  2020-02-29 19:13 ` Nicolas Goaziou
  0 siblings, 1 reply; 8+ messages in thread
From: Pierre Neidhardt @ 2020-02-28 16:04 UTC (permalink / raw)
  To: 39825

* gnu/packages/game-development.scm (warsow-qfusion): New variable.
* gnu/packages/patches/warsow-fix-bool-return-type.patch: New file.
* gnu/local.mk: Add patch.
---
 gnu/local.mk                                  |  1 +
 gnu/packages/game-development.scm             | 49 +++++++++++++++++++
 .../patches/warsow-fix-bool-return-type.patch | 24 +++++++++
 3 files changed, 74 insertions(+)
 create mode 100644 gnu/packages/patches/warsow-fix-bool-return-type.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 857345cfad..82d5490dd8 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1482,6 +1482,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/vsearch-unbundle-cityhash.patch		\
   %D%/packages/patches/vte-CVE-2012-2738-pt1.patch			\
   %D%/packages/patches/vte-CVE-2012-2738-pt2.patch			\
+  %D%/packages/patches/warsow-fix-bool-return-type.patch	\
   %D%/packages/patches/weasyprint-library-paths.patch		\
   %D%/packages/patches/websocketpp-fix-for-boost-1.70.patch	\
   %D%/packages/patches/wicd-bitrate-none-fix.patch		\
diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm
index 05e026a846..f0b1b5f066 100644
--- a/gnu/packages/game-development.scm
+++ b/gnu/packages/game-development.scm
@@ -2188,3 +2188,52 @@ rigid body physics library written in C.")
 developers providing an advanced true color console, input, and lots of other
 utilities frequently used in roguelikes.")
     (license license:bsd-3)))
+
+(define-public warsow-qfusion
+  (let ((commit "5ec6887887850fa9e6f0a4418ab2b776f54fb395"))
+    (package
+      (name "warsow-qfusion")
+      (version (git-version "2.1.0" "1" commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://github.com/Warsow/qfusion/")
+                      (commit commit)
+                      (recursive? #t)))
+                (file-name (git-file-name name version))
+                (sha256
+                 (base32
+                  "0bfwyikpwgwqcli33hxscdp557li1hkwyxy069csx5dy6sfvci6q"))
+                ;; Issue reported here: https://github.com/Warsow/qfusion/issues/46
+                (patches (search-patches "warsow-fix-bool-return-type.patch"))))
+      (build-system cmake-build-system)
+      (arguments
+       `(#:tests? #f                    ; No tests.
+         #:configure-flags '("-DQFUSION_GAME=Warsow")
+         #:phases
+         (modify-phases %standard-phases
+           (add-after 'unpack 'change-to-build-dir
+             (lambda _
+               (chdir "source")
+               #t)))))
+      (inputs
+       `(("sdl2" ,sdl2)
+         ("libjpeg" ,libjpeg)
+         ("libpng" ,libpng)
+         ("libvorbis" ,libvorbis)
+         ("libogg" ,libogg)
+         ("libtheora" ,libtheora)
+         ("freetype" ,freetype)
+         ("mesa" ,mesa)
+         ("openal" ,openal)
+         ("zlib" ,zlib)
+         ("curl" ,curl)
+         ("qtbase" ,qtbase)
+         ("qtdeclarative" ,qtdeclarative)
+         ("uuid.h" ,util-linux)))
+      (home-page "https://github.com/Warsow/qfusion")
+      (synopsis "Warsow's fork of qfusion, the id Tech 2 derived game engine")
+      (description
+       "This package contains Warsow's fork of qfusion, the id Tech 2 derived
+game engine.  id Tech 2 is the engine originally behind Quake 2.")
+      (license license:gpl2))))
diff --git a/gnu/packages/patches/warsow-fix-bool-return-type.patch b/gnu/packages/patches/warsow-fix-bool-return-type.patch
new file mode 100644
index 0000000000..cd2c58afef
--- /dev/null
+++ b/gnu/packages/patches/warsow-fix-bool-return-type.patch
@@ -0,0 +1,24 @@
+diff --git a/source/ref/imagelib.cpp b/source/ref/imagelib.cpp
+index 33337ac..bb9a156 100644
+--- a/source/ref/imagelib.cpp
++++ b/source/ref/imagelib.cpp
+@@ -762,7 +762,7 @@ static void q_jpg_noop( j_decompress_ptr cinfo ) {
+
+ static boolean q_jpg_fill_input_buffer( j_decompress_ptr cinfo ) {
+ 	Com_DPrintf( "Premature end of jpeg file\n" );
+-	return 1;
++	return TRUE;
+ }
+
+ static void q_jpg_skip_input_data( j_decompress_ptr cinfo, long num_bytes ) {
+@@ -955,7 +955,7 @@ bool WriteJPG( const char *name, r_imginfo_t *info, int quality ) {
+ 	}
+
+ 	// start compression
+-	qjpeg_start_compress( &cinfo, true );
++	qjpeg_start_compress( &cinfo, TRUE );
+
+ 	// feed scanline data
+ 	w3 = cinfo.image_width * info->samples;
+--
+2.25.1
-- 
2.25.1

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

* [bug#39825] [PATCH] gnu: Add warsow-qfusion.
  2020-02-28 16:04 [bug#39825] [PATCH] gnu: Add warsow-qfusion Pierre Neidhardt
@ 2020-02-29 19:13 ` Nicolas Goaziou
  2020-02-29 21:48   ` Tobias Geerinckx-Rice via Guix-patches via
  2020-03-02  8:46   ` Pierre Neidhardt
  0 siblings, 2 replies; 8+ messages in thread
From: Nicolas Goaziou @ 2020-02-29 19:13 UTC (permalink / raw)
  To: Pierre Neidhardt; +Cc: 39825

Hello,

Pierre Neidhardt <mail@ambrevar.xyz> writes:

> +(define-public warsow-qfusion

Thank you!

> +  (let ((commit "5ec6887887850fa9e6f0a4418ab2b776f54fb395"))
> +    (package
> +      (name "warsow-qfusion")
> +      (version (git-version "2.1.0" "1" commit))

You may add a comment explaining why we don't provide (outdated) stable
version.

> +      (inputs
> +       `(("sdl2" ,sdl2)
> +         ("libjpeg" ,libjpeg)
> +         ("libpng" ,libpng)
> +         ("libvorbis" ,libvorbis)
> +         ("libogg" ,libogg)
> +         ("libtheora" ,libtheora)
> +         ("freetype" ,freetype)
> +         ("mesa" ,mesa)
> +         ("openal" ,openal)
> +         ("zlib" ,zlib)
> +         ("curl" ,curl)
> +         ("qtbase" ,qtbase)
> +         ("qtdeclarative" ,qtdeclarative)
> +         ("uuid.h" ,util-linux)))

Could you re-order the inputs?

> +      (home-page "https://github.com/Warsow/qfusion")
> +      (synopsis "Warsow's fork of qfusion, the id Tech 2 derived game engine")
> +      (description
> +       "This package contains Warsow's fork of qfusion, the id Tech 2 derived
> +game engine.  id Tech 2 is the engine originally behind Quake 2.")

Even though it is spelled "id" in the repository, I think this is really
"ID".

> +      (license license:gpl2))))

AFAICT, this is gpl2+.

Otherwise, FWIW, LGTM!

Regards,

-- 
Nicolas Goaziou

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

* [bug#39825] [PATCH] gnu: Add warsow-qfusion.
  2020-02-29 19:13 ` Nicolas Goaziou
@ 2020-02-29 21:48   ` Tobias Geerinckx-Rice via Guix-patches via
  2020-02-29 22:56     ` Nicolas Goaziou
  2020-03-02  8:46   ` Pierre Neidhardt
  1 sibling, 1 reply; 8+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches via @ 2020-02-29 21:48 UTC (permalink / raw)
  To: 39825

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

Nicolas Goaziou 写道:
> Even though it is spelled "id" in the repository, I think this 
> is really
> "ID".

‘Id’.

Kind regards,

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

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

* [bug#39825] [PATCH] gnu: Add warsow-qfusion.
  2020-02-29 21:48   ` Tobias Geerinckx-Rice via Guix-patches via
@ 2020-02-29 22:56     ` Nicolas Goaziou
  2020-03-03 12:57       ` Tobias Geerinckx-Rice via Guix-patches via
  0 siblings, 1 reply; 8+ messages in thread
From: Nicolas Goaziou @ 2020-02-29 22:56 UTC (permalink / raw)
  To: 39825; +Cc: me

Hello,

Tobias Geerinckx-Rice via Guix-patches via <guix-patches@gnu.org>
writes:

> Nicolas Goaziou 写道:
>> Even though it is spelled "id" in the repository, I think this is
>> really
>> "ID".
>
> ‘Id’.

<nitpick>
Actually, I think we're both wrong. That should be "id Software", per
<https://en.wikipedia.org/wiki/Id_Software>
</nitpick>

Regards,

-- 
Nicolas Goaziou

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

* [bug#39825] [PATCH] gnu: Add warsow-qfusion.
  2020-02-29 19:13 ` Nicolas Goaziou
  2020-02-29 21:48   ` Tobias Geerinckx-Rice via Guix-patches via
@ 2020-03-02  8:46   ` Pierre Neidhardt
  2020-03-03 10:35     ` Pierre Neidhardt
  1 sibling, 1 reply; 8+ messages in thread
From: Pierre Neidhardt @ 2020-03-02  8:46 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: 39825

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

Thanks for the review!

> Even though it is spelled "id" in the repository, I think this is really
> "ID".

Actually nope :)

https://en.wikipedia.org/wiki/Id_tech

-- 
Pierre Neidhardt
https://ambrevar.xyz/

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

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

* Re: [bug#39825] [PATCH] gnu: Add warsow-qfusion.
  2020-03-02  8:46   ` Pierre Neidhardt
@ 2020-03-03 10:35     ` Pierre Neidhardt
  2020-05-02 14:03       ` Pierre Neidhardt
  0 siblings, 1 reply; 8+ messages in thread
From: Pierre Neidhardt @ 2020-03-03 10:35 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: guix-devel, 39825

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

I'm trying to use commit c4de15df559410aff0ca6643724e24cddb0ecbbd as
suggested upstream
(https://github.com/Warsow/qfusion/issues/46#issuecomment-592940682) but
git-fetch fails with

--8<---------------cut here---------------start------------->8---
Submodule 'libsrcs' (https://github.com/Warsow/qfusion-libsrcs.git) registered for path 'libsrcs'
Submodule 'third-party/angelscript' (https://github.com/Qfusion/angelscript.git) registered for path 'third-party/angelscript'
Submodule 'third-party/libRocket' (https://github.com/Qfusion/libRocket) registered for path 'third-party/libRocket'
Submodule 'third-party/openal-soft' (https://github.com/Warsow/openal-soft.git) registered for path 'third-party/openal-soft'
Submodule 'third-party/recastnavigation' (https://github.com/Warsow/recastnavigation.git) registered for path 'third-party/recastnavigation'
Submodule 'third-party/sqlite-amalgamation' (https://github.com/Warsow/sqlite-amalgamation.git) registered for path 'third-party/sqlite-amalgamation'
Cloning into '/gnu/store/l4bjqp1yjkx0hczz0y2i9h0gzayfdx11-warsow-qfusion-2.5-1.c4de15d-checkout/libsrcs'...
Cloning into '/gnu/store/l4bjqp1yjkx0hczz0y2i9h0gzayfdx11-warsow-qfusion-2.5-1.c4de15d-checkout/third-party/angelscript'...
Cloning into '/gnu/store/l4bjqp1yjkx0hczz0y2i9h0gzayfdx11-warsow-qfusion-2.5-1.c4de15d-checkout/third-party/libRocket'...
Cloning into '/gnu/store/l4bjqp1yjkx0hczz0y2i9h0gzayfdx11-warsow-qfusion-2.5-1.c4de15d-checkout/third-party/openal-soft'...
Cloning into '/gnu/store/l4bjqp1yjkx0hczz0y2i9h0gzayfdx11-warsow-qfusion-2.5-1.c4de15d-checkout/third-party/recastnavigation'...
Cloning into '/gnu/store/l4bjqp1yjkx0hczz0y2i9h0gzayfdx11-warsow-qfusion-2.5-1.c4de15d-checkout/third-party/sqlite-amalgamation'...
Submodule path 'libsrcs': checked out 'd3c01feeed14aa2f24c1839fedfb43b4c38a3412'
Submodule path 'third-party/angelscript': checked out '478944145ce6d278abc2a119355c425b332482df'
error: Server does not allow request for unadvertised object 867fc72f980b40325c35d2a9182f741e8e0ca876
Fetched in submodule path 'third-party/libRocket', but it did not contain 867fc72f980b40325c35d2a9182f741e8e0ca876. Direct fetching of that commit failed.
git-fetch: '/gnu/store/zm51w1zv9zchx3n3xjw81zrjnlaswawa-git-minimal-2.25.1/bin/git submodule update --init --recursive' failed with exit code 1
--8<---------------cut here---------------end--------------->8---

Indeed, 867fc72f980b40325c35d2a9182f741e8e0ca876 does not exist in
libRocket, so I suspect it was removed, but isn't Git supposed to fetch
master?  Where did it guess this commit from.  I don't understand how
this is possible.  The .gitmodules file is

--8<---------------cut here---------------start------------->8---
[submodule "third-party/libRocket"]
	path = third-party/libRocket
	url = https://github.com/Qfusion/libRocket
[submodule "third-party/angelscript"]
	path = third-party/angelscript
	url = https://github.com/Qfusion/angelscript.git
[submodule "third-party/recastnavigation"]
	path = third-party/recastnavigation
	url = https://github.com/Warsow/recastnavigation.git
[submodule "third-party/openal-soft"]
	path = third-party/openal-soft
	url = https://github.com/Warsow/openal-soft.git
[submodule "third-party/sqlite-amalgamation"]
	path = third-party/sqlite-amalgamation
	url = https://github.com/Warsow/sqlite-amalgamation.git
[submodule "libsrcs"]
	path = libsrcs
	url = https://github.com/Warsow/qfusion-libsrcs.git
--8<---------------cut here---------------end--------------->8---

and

--8<---------------cut here---------------start------------->8---
> git submodule status --recursive
 d3c01feeed14aa2f24c1839fedfb43b4c38a3412 libsrcs (d3c01fe)
 478944145ce6d278abc2a119355c425b332482df third-party/angelscript (heads/master)
+4889e4c100920cbd0fc9004566d6380771bd77a7 third-party/libRocket (release-1.2.1-1264-g4889e4c1)
 6761218e51699f46bf25c377e65b3e9ea5e434b9 third-party/openal-soft (openal-soft-1.18.1-694-g6761218e)
 2c85309280dbc9c82029e7ab16dfb01b9235c74e third-party/recastnavigation (1.5.0-78-g2c85309)
 bc1dd8284590b5092a9bed4deb80a49e01cfb911 third-party/sqlite-amalgamation (heads/master)
--8<---------------cut here---------------end--------------->8---

I must be missing something about Git submodules...

-- 
Pierre Neidhardt
https://ambrevar.xyz/

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

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

* [bug#39825] [PATCH] gnu: Add warsow-qfusion.
  2020-02-29 22:56     ` Nicolas Goaziou
@ 2020-03-03 12:57       ` Tobias Geerinckx-Rice via Guix-patches via
  0 siblings, 0 replies; 8+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches via @ 2020-03-03 12:57 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: 39825

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

Nicolas Goaziou 写道:
> <nitpick>
> Actually, I think we're both wrong. That should be "id 
> Software", per
> <https://en.wikipedia.org/wiki/Id_Software>
> </nitpick>

<ahkshually>
Id read that article as well and was… surprised: Wikipedia does 
not take kindly to marketingCase™, let alone promote it.

id obviously gets ‘special’ treatment from sympathetic editors in 
a certain age bracket.  ;-)  Any other brand would be forced to 
use Regularcase.

I wrote ‘Id’ just to make clear that it's a word, not an 
abbreviation, and because GNU doesn't recognise trademarks either, 
and oh god none of this matters let's go play in the sun.

Just don't call them I.D.
</ahkshually>

Kind regards,

T G-R, now installing gzdoom again

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

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

* Re: [bug#39825] [PATCH] gnu: Add warsow-qfusion.
  2020-03-03 10:35     ` Pierre Neidhardt
@ 2020-05-02 14:03       ` Pierre Neidhardt
  0 siblings, 0 replies; 8+ messages in thread
From: Pierre Neidhardt @ 2020-05-02 14:03 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: guix-devel, 39825

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

Somehow this issue went away by itself.

I've fixed added sound support to the package definition.

Merged with 39f1806ca1d04b9aee70e897e06466aadbbee152.

-- 
Pierre Neidhardt
https://ambrevar.xyz/

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

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

end of thread, other threads:[~2020-05-02 14:03 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-02-28 16:04 [bug#39825] [PATCH] gnu: Add warsow-qfusion Pierre Neidhardt
2020-02-29 19:13 ` Nicolas Goaziou
2020-02-29 21:48   ` Tobias Geerinckx-Rice via Guix-patches via
2020-02-29 22:56     ` Nicolas Goaziou
2020-03-03 12:57       ` Tobias Geerinckx-Rice via Guix-patches via
2020-03-02  8:46   ` Pierre Neidhardt
2020-03-03 10:35     ` Pierre Neidhardt
2020-05-02 14:03       ` Pierre Neidhardt

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.