Bug 287205 - games/vkquake: Update to 1.32.2
Summary: games/vkquake: Update to 1.32.2
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Zsolt Udvari
URL: https://github.com/Novum/vkQuake/rele...
Keywords:
Depends on:
Blocks:
 
Reported: 2025-06-01 05:28 UTC by Alastair Hogge
Modified: 2025-06-06 10:09 UTC (History)
2 users (show)

See Also:


Attachments
games/vkquake: Update to 1.32.2 (7.60 KB, patch)
2025-06-01 05:34 UTC, Alastair Hogge
no flags Details | Diff
games/vkquake: Update to 1.32.2 (8.18 KB, patch)
2025-06-05 21:49 UTC, Alastair Hogge
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alastair Hogge 2025-06-01 05:28:40 UTC

    
Comment 1 Alastair Hogge 2025-06-01 05:34:15 UTC
Created attachment 260855 [details]
games/vkquake: Update to 1.32.2

Update to 1.32.2:
* Add DEBUG option
* Complete ${MAINTAINER}
* Drop unneeded gnome, and gmake from ${USES}
* port(clippy|fmt|lint) housekeeping
  - sort variable elements alphabetically
  - sort blocks
* Remove tracker audio decoder options, they are not currently supported
  in the meson build
* Switch to meson build; regenerate patches to suit
* Update ${COMMENT} to reflect upstream project description

https://github.com/Novum/vkQuake/releases/tag/1.32.2

poudriere-testport games/vkquake:
13_4-amd64-release: Pass
13_4-i386-release: Pass
13_5-amd64-release: Pass
13_5-i386-release: Pass
14_2-amd64-release: Pass
14_2-i386-release: Pass
main-amd64-default: Pass
main-i386-default: Pass

Play tested on 15-CURRENT with the GOG enhanced release, and version 1 of the old Quake Revitalization Project[1]

1: http://qrp.quakeone.com/
Comment 2 Zsolt Udvari freebsd_committer freebsd_triage 2025-06-01 12:44:43 UTC
Hi Alastair,
thanks for patch.

I'd suggest:
MAD_MESON_ENABLED=mp3_lib
and 
MP3_MESON_ENABLED=mp3_lib
and
MAD_MESON_ON=mp3_lib=mad
and
MP3_MESON_ON=mp3_lib=mpg123
So can remove "if MAD || MP3"-statement (from line 56).

The patches should generate with 'make makepatch'.
Comment 3 Alastair Hogge 2025-06-02 01:02:34 UTC
(In reply to Zsolt Udvari from comment #2)

If change the Makefile to the following (which I think is what you are requesting?):

> MAD_LIB_DEPENDS=        libmad.so:audio/libmad
> MAD_MESON_ENABLED=      mp3_lib
> MAD_MESON_ENABLED=      use_codec_mp3
> MAD_MESON_ON=           mp3_lib=mad
> MP3_LIB_DEPENDS=        libmpg123.so:audio/mpg123
> MP3_MESON_ENABLED=      mp3_lib
> MP3_MESON_ENABLED=      use_codec_mp3
> MP3_MESON_ON=           mp3_lib=mpg123

make configure phase will fail:
> ===>  Configuring for vkquake-1.32.2
> usage: meson [-h] {setup,configure,dist,install,introspect,init,test,wrap,subprojects,rewrite,compile,devenv,env2mfile,reprotest,format,fmt,help} ...
> meson: error: unrecognized arguments: _build

I vaguely recall spending too many hours on this a couple of weeks ago, and I think that is why I ended up with the current method.

As for makepatch, it does not generate any patches, it will list the patches that is required, with a number of files that are not, however, nothing is generated. From memory, I think I used ${PORTS}/Tools/scripts/patchtool.py to generate the patches:

> root@pkg:/usr/ports/games/vkquake # rm -fr /wrkdirs && make extract
> root@pkg:/usr/ports/games/vkquake # cd /wrkdirs/usr/ports/games/vkquake/work/vkQuake-1.32.2/Quake
> root@pkg:/wrkdirs/usr/ports/games/vkquake/work/vkQuake-1.32.2/Quake # cp common.c common.c.orig && cp pr_edict.c pr_edict.c.orig
> [edit changes]
> root@pkg:/wrkdirs/usr/ports/games/vkquake/work/vkQuake-1.32.2/Quake # cd /usr/ports/games/vkquake
> root@pkg:/usr/ports/games/vkquake # make makepatch
> diff: Misc/vq_pak/maps/e1m1.ent: No such file or directory
> diff: Misc/vq_pak/maps/e1m2.ent: No such file or directory
> diff: Misc/vq_pak/maps/e1m4.ent: No such file or directory
> diff: Misc/vq_pak/maps/e2m2.ent: No such file or directory
> diff: Misc/vq_pak/maps/e2m3.ent: No such file or directory
> diff: Misc/vq_pak/maps/e2m7.ent: No such file or directory
> Generated patch-Misc_vq__pak_maps_e1m1.ent
> Generated patch-Misc_vq__pak_maps_e1m2.ent
> Generated patch-Misc_vq__pak_maps_e1m4.ent
> Generated patch-Misc_vq__pak_maps_e2m2.ent
> Generated patch-Misc_vq__pak_maps_e2m3.ent
> Generated patch-Misc_vq__pak_maps_e2m7.ent
> Generated patch-Quake_common.c
> Generated patch-Quake_pr__edict.c
Comment 4 Zsolt Udvari freebsd_committer freebsd_triage 2025-06-02 17:46:20 UTC
(In reply to Alastair Hogge from comment #3)
> make configure phase will fail:
Indeed. I'm working on it.
Comment 5 Zsolt Udvari freebsd_committer freebsd_triage 2025-06-03 04:09:33 UTC
(In reply to Alastair Hogge from comment #3)
MAD_LIB_DEPENDS=>-------libmad.so:audio/libmad
MAD_MESON_ON=>-->--------Dmp3_lib=mad
MP3_LIB_DEPENDS=>-------libmpg123.so:audio/mpg123
MP3_MESON_ON=>-->--------Dmp3_lib=mpg123

And the use_codec_mp3 should go into MESON_ARGS because the user should choose ONE mp3-codec (isn't possible without mp3 because of radio_mp3library). In the MESON_ARGS would be -Duse_codec_mp3=enabled.

About patching: you should create a copy the original file with suffix .orig (see [1]).

[1]: https://docs.freebsd.org/en/books/porters-handbook/book/#slow-patch
Comment 6 Alastair Hogge 2025-06-03 06:31:30 UTC
(In reply to Zsolt Udvari from comment #5)

> About patching: you should create a copy the original file with suffix .orig (see [1]).

Did you get makepatch working? I did copy the original to a new file with the .orig suffix, see my previous comment #3
Comment 7 Alastair Hogge 2025-06-03 10:58:35 UTC
Just for completeness, upon entering the poudriere jail that was constructed for games/vkquake, if I do the following:

> root@pkg:/usr/ports/games/vkquake # rm -fr /wrkdirs && cd ../../shells/oksh
> root@pkg:/usr/ports/shells/oksh # make extract
> root@pkg:/usr/ports/shells/oksh # cd /wrkdirs/usr/ports/shells/oksh/work-dynamic/oksh-7.7
> root@pkg:/wrkdirs/usr/ports/shells/oksh/work-dynamic/oksh-7.7 # cp c_ksh.c c_ksh.c.orig
> [edit changes]
> root@pkg:/wrkdirs/usr/ports/shells/oksh/work-dynamic/oksh-7.7 # cd /usr/ports/shells/oksh
> root@pkg:/usr/ports/shells/oksh # make makepatch
> Generated patch-c__ksh.c
> root@pkg:/usr/ports/shells/oksh # cat files/patch-c__ksh.c
> --- c_ksh.c.orig        2025-06-03 10:52:20 UTC
> +++ c_ksh.c
> @@ -10,6 +10,7 @@
>  #include <errno.h>
>  #include <string.h>
>  #include <unistd.h>
> +# Added for test

makepatch works.
Comment 8 Alastair Hogge 2025-06-03 10:59:07 UTC
(In reply to Zsolt Udvari from comment #5)
> And the use_codec_mp3 should go into MESON_ARGS because the user should choose ONE mp3-codec (isn't possible without mp3 because of radio_mp3library). In the MESON_ARGS would be -Duse_codec_mp3=enabled.

This appears to work, thanks.
Comment 9 Zsolt Udvari freebsd_committer freebsd_triage 2025-06-04 03:00:48 UTC
I'm glad :) Could you please provide a patch?
Comment 10 Alastair Hogge 2025-06-04 06:34:18 UTC
(In reply to Zsolt Udvari from comment #9)

I will, tho, I might spend some more time on makepatch, if I can get that working, I will document it in the patches.
Comment 11 Zsolt Udvari freebsd_committer freebsd_triage 2025-06-04 09:09:23 UTC
Okay, thanks!
Comment 12 Alastair Hogge 2025-06-05 21:49:23 UTC
Created attachment 261016 [details]
games/vkquake: Update to 1.32.2
Comment 13 Zsolt Udvari freebsd_committer freebsd_triage 2025-06-06 08:36:42 UTC
Thanks for your work, Alastair! Committed.
Comment 14 commit-hook freebsd_committer freebsd_triage 2025-06-06 08:37:16 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=7730b000750cfe0f5c06fe39f93381352d0dba73

commit 7730b000750cfe0f5c06fe39f93381352d0dba73
Author:     Alastair Hogge <agh@riseup.net>
AuthorDate: 2025-06-06 08:31:54 +0000
Commit:     Zsolt Udvari <uzsolt@FreeBSD.org>
CommitDate: 2025-06-06 08:36:09 +0000

    games/vkquake: Update to 1.32.2

    Switch to meson build system, add DEBUG option.
    Submitter takes maintainership.
    Regenerate patch with makepatch.
    Simplify COMMENT.
    Pet portlint, portfmt, portclippy.

    PR:             287205

 games/vkquake/Makefile                            | 98 ++++++++---------------
 games/vkquake/distinfo                            |  6 +-
 games/vkquake/files/patch-Quake_common.c (new)    | 17 ++++
 games/vkquake/files/patch-Quake_pr__edict.c (new) | 19 +++++
 games/vkquake/files/patch-common.c (gone)         | 11 ---
 games/vkquake/files/patch-pr__edict.c (gone)      | 13 ---
 6 files changed, 74 insertions(+), 90 deletions(-)
Comment 15 Alastair Hogge 2025-06-06 10:09:13 UTC
Thanks very much.