Bug 237342

Summary: games/eduke32: improvement, allow installation of full game data
Product: Ports & Packages Reporter: Felix Palmen <zirias>
Component: Individual Port(s)Assignee: Piotr Kubaj <pkubaj>
Status: Closed FIXED    
Severity: Affects Only Me CC: swills
Priority: ---    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
patch adding FULL option to build with supplied full game's files
none
patch adding FULL option to build with supplied full game's files none

Description Felix Palmen freebsd_committer freebsd_triage 2019-04-17 17:36:17 UTC
Created attachment 203746 [details]
patch adding FULL option to build with supplied full game's files

If you want to play the full Duke3D version, you have to manually put the files in /usr/local/share/duke3d. I suggest attached patch that adds a port option instead for making the files part of the package.
Comment 1 Bugzilla Automation freebsd_committer freebsd_triage 2019-04-17 17:36:17 UTC
Maintainer informed via mail
Comment 2 Piotr Kubaj freebsd_committer freebsd_triage 2019-05-28 08:38:10 UTC
Looks good, I will post a review shortly.
Comment 3 Piotr Kubaj freebsd_committer freebsd_triage 2019-05-28 09:06:24 UTC
portlint:
WARN: /usr/ports/games/eduke32/pkg-descr: exceeds 24 lines, make it shorter if possible.(currently 27 lines)
Comment 4 Felix Palmen freebsd_committer freebsd_triage 2019-05-28 09:30:33 UTC
Well, it's a warning after all, but of course it would be nice to have pkg-descr fit on a standard 80x25 terminal screen.

What are your thoughts about this? Is there a better place to put this kind of documentation? Or should the original description be shortened instead?

BR, Felix
Comment 5 Piotr Kubaj freebsd_committer freebsd_triage 2019-05-28 09:40:53 UTC
(In reply to Felix Palmen from comment #4)
You could put it option description.

Like:
+FULL_DESC=		Install duke3d.grp and duke.rst from $${DISTDIR}/duke3d
Comment 6 Felix Palmen freebsd_committer freebsd_triage 2019-05-29 09:19:22 UTC
Thanks for the suggestion. I'll review my change again, with only such a short description, I guess I should add a sanity check, so the port doesn't attempt to build when FULL is selected, but the files aren't there.
Comment 7 Felix Palmen freebsd_committer freebsd_triage 2020-05-24 11:00:20 UTC
Created attachment 214805 [details]
patch adding FULL option to build with supplied full game's files

This is a second attempt at a "sane" implementation of a FULL option. Revisiting this idea, I remembered what the initial problems were:

* Adding the commercial game files to DISTFILES triggers testing their
  checksums. This is not a good idea as there are many editions of the game,
  all of them are expected to work with eduke32, and they all have the same
  file names.
* Just installing the files from DISTDIR without adding them to DISTFILES breaks
  with poudriere, because they are never copied to /portdistfiles.
* My initial solution was to provide the variable DUKE3DFULLDIR, overridable
  from make.conf, which can solve the problem with poudriere, but is complicated
  and must be documented somewhere.

So, here's a different suggestion now, but it is far from perfect as well. bsd.port.mk currently allows to override _CKSUMFILES; using this, it's possible to add DISTFILES without testing their checksum. Maybe this would be acceptable for a non-default option requiring user actions (putting the files in the correct place) anyways?

I also added a meaningful IGNORE message when selecting the option without providing the required files.
Comment 8 commit-hook freebsd_committer freebsd_triage 2020-06-10 14:55:38 UTC
A commit references this bug:

Author: pkubaj
Date: Wed Jun 10 14:54:39 UTC 2020
New revision: 538400
URL: https://svnweb.freebsd.org/changeset/ports/538400

Log:
  games/eduke32: allow installation of full game data

  PR:		237342
  Submitted by:	felix@palmen-it.de

Changes:
  head/games/eduke32/Makefile