Debian package issues

Found a bug in R'n'D? Report it here!

Moderators: Flumminator, Zomis

Post Reply
filbo
Posts: 723
Joined: Fri Jun 20, 2014 10:06 am

Debian package issues

Post by filbo »

Packaging issues with the current Debian package (rocksndiamonds 4.4.0.5+dfsg-1).

NOTE: I understand clearly that this has very little to do with Holger or this site! I am merely reporting what is busted 'out in the world' with regard to the delivery of the package. And I am doing so here in order to get my thoughts down in a semi-coherent fashion, and -- possibly -- to copy-paste or perhaps link to this, when I eventually report it 'properly' to Debian.

1. the Debian package contains an obsolete link to RnD 'jue', http://www.jb-line.de/hp/rnd_jue-v8.zip (along with an md5sum value which correctly matches the data at https://jb-line.de/rnd/rnd_jue-v8.zip)

Therefore, if at install time you tell it to download all the offered levelset packages, it fails to get this one.

The first time this happened to me, it seemed to leave the package in a strange busted state which I had to manually untangle. But I have not been able to subsequently reproduce this, and realize I might have precipitated it by e.g. hitting Ctrl+C in the middle of the failure (I do not remember clearly whether I did so).

2. the download script reacts poorly to the failed download. An error window pops up:

Code: Select all

Configuring rocksndiamonds
Cannot download required resources
An error occurred while downloading game data. You should
check the network connection and settings and retry later on.
<Ok>
This doesn't tell the user anything about which levels-package failed to download, so they would have to poke around in the scripts or the download directory or something, in order to know how to operate the 'choose which levels to fetch' window in a manner which would dodge the faulty download.

3. the 'choose which levels' ('Games to download data for') window currently has some 25 levelsets to choose from, in a klunky ASCII chooser window (or a klunky graphical chooser window under 'Gnome Software'). It would be nice to have a '[ ] ALL' button to toggle all-on, all-off.

4. actually many of the levelset packages have wrong / obsolete URLs, but are corrected by site redirects. It would be better if the package contained the most current URLs, since they're more likely to remain correct or at least continue to have future redirects to The Next Place.

In the following table, column 2 is the URL currently used in the rocksndiamonds.postinst script; column 3 is what it should be.

Column 1 is notes describing what was changed, resulting in the (current) final redirect:

H: 'http' to 'https'
L: 'unix' to 'linux'
W: added 'www.'
M: migrated from ancient web.archive.org URL to artsoft.org (where most of the rest of the files are from)
U: multiple changes to reflect site reorganization

Code: Select all

[HL] http://www.artsoft.org/RELEASES/unix/rocksndiamonds/rocksndiamonds-4.4.0.5-linux.tar.gz https://www.artsoft.org/RELEASES/linux/rocksndiamonds/rocksndiamonds-4.4.0.5-linux.tar.gz
[H]  http://www.artsoft.org/RELEASES/rocksndiamonds/levels/Zelda-1.0.0.zip https://www.artsoft.org/RELEASES/rocksndiamonds/levels/Zelda-1.0.0.zip
[HW] http://artsoft.org/RELEASES/rocksndiamonds/levels/ZeldaII-1.0.0.zip https://www.artsoft.org/RELEASES/rocksndiamonds/levels/ZeldaII-1.0.0.zip
[H]  http://www.artsoft.org/RELEASES/rocksndiamonds/levels/Contributions-1.2.0.7z https://www.artsoft.org/RELEASES/rocksndiamonds/levels/Contributions-1.2.0.7z
[H]  http://www.artsoft.org/RELEASES/rocksndiamonds/levels/Snake_Bite-1.0.0.zip https://www.artsoft.org/RELEASES/rocksndiamonds/levels/Snake_Bite-1.0.0.zip
[H]  http://www.artsoft.org/RELEASES/rocksndiamonds/levels/BD2K3-1.0.0.zip https://www.artsoft.org/RELEASES/rocksndiamonds/levels/BD2K3-1.0.0.zip
[H]  http://www.artsoft.org/RELEASES/rocksndiamonds/levels/Boulder_Dash_Dream-1.0.0.zip https://www.artsoft.org/RELEASES/rocksndiamonds/levels/Boulder_Dash_Dream-1.0.0.zip
[HL] http://www.artsoft.org/RELEASES/unix/rocksndiamonds/levels/rockslevels-dx-1.0.tar.gz https://www.artsoft.org/RELEASES/linux/rocksndiamonds/levels/rockslevels-dx-1.0.tar.gz
[H]  http://www.artsoft.org/RELEASES/rocksndiamonds/levels/Sokoban-1.0.0.7z https://www.artsoft.org/RELEASES/rocksndiamonds/levels/Sokoban-1.0.0.7z
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/r-structure.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/r-structure.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/earth_3120.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/earth_3120.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/r-graphics.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/r-graphics.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/r-sounds.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/r-sounds.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/eem.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/eem.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/might_of_elementals.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/might_of_elementals.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/mod_secret_command.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/mod_secret_command.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/natural.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/natural.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/world_of_amoeba.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/world_of_amoeba.zip
[H]  http://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/r-old.zip https://www.artsoft.org/rocksndiamonds/levels/richardkleber/RnD/r-old.zip
[M]  https://web.archive.org/web/20110101150015/http://home.freeuk.net/jamiecullen/zips/ww_v1-0.zip https://www.artsoft.org/rocksndiamonds/levels/jamiecullen/zips/ww_v1-0.zip
[M]  https://web.archive.org/web/20110101150015/http://home.freeuk.net/jamiecullen/zips/wg_v1-0.zip https://www.artsoft.org/rocksndiamonds/levels/jamiecullen/zips/wg_v1-0.zip
[M]  https://web.archive.org/web/20110101150015/http://home.freeuk.net/jamiecullen/zips/wf_v1-3.zip https://www.artsoft.org/rocksndiamonds/levels/jamiecullen/zips/wf_v1-3.zip
[M]  https://web.archive.org/web/20110101150015/http://home.freeuk.net/jamiecullen/zips/es_b_v1-2.zip https://www.artsoft.org/rocksndiamonds/levels/jamiecullen/zips/es_b_v1-2.zip
[M]  https://web.archive.org/web/20110101150015/http://home.freeuk.net/jamiecullen/zips/ese_v1-1.zip https://www.artsoft.org/rocksndiamonds/levels/jamiecullen/zips/ese_v1-1.zip
[U]  https://www.jb-line.de/hp/rnd_jue-v8.zip https://jb-line.de/rnd/rnd_jue-v8.zip
Last edited by filbo on Wed Jan 07, 2026 8:02 am, edited 1 time in total.
filbo
Posts: 723
Joined: Fri Jun 20, 2014 10:06 am

Re: Debian package issues

Post by filbo »

Holger, there is actually something you could do about a big part of the above (I mean, aside from your volunteering to maintain the Debian packaging, which I suspect they would allow, but you have zero obligation to get involved with...)

... which is, you could provide a maintained and curated list of 'recommended non-free levelset packages to download', in a packager-friendly data format like JSON. Then, instead of their package script containing an old, crumbling list of such files, it could just dynamically download and work from your curated list. (The existing list is in the form of an inline definition of a Perl object `our %info= ( .... )`, with some complexity to account for where each should be expanded, and cross-dependencies.)

They already download the main RnD package itself, presumably to populate /usr/share/rocksndiamonds/..., which is not included in the Debian package. The package does include the actual binary, so it discards that part of your .tar.gz.

In fact, the 'curated JSON'-or-whatever file I'm talking about could easily be a component of your source-and-binary tarball; though, perhaps that is unwise as it might change more rapidly (or at least, on a different schedule than) the source.
filbo
Posts: 723
Joined: Fri Jun 20, 2014 10:06 am

Re: Debian package issues

Post by filbo »

Some further points to the initial report (i.e.: actually, eventually, directed at Debian):

5. the postinstall script destroys any previous contents of /usr/share/games/rocksndiamonds (code in the postinst script function `clean_downloads_dir()`). I actually had a tremendous amount of semi-precious data there, which I will agree was unwise; and I did have backups; but I found this behavior overly aggressive. May I suggest something along the lines of `mv $game_dir/downloads $game_dir/downloads.pre-dpkg; mkdir $game_dir/downloads`? That is, keep any previous contents somewhere (more carefully than the sample code here :)

6. many of the directory names used by the postinst script contain spaces. This is, in many/most cases, in response to the names previously used in the games' own files. For instance, the Debian package downloads the file 'Emerald_Mine_Club-3.1.3.7z', extracts from it a great deal of files which are internally named 'Emerald_Mine_Club/path/file/name', renaming the whole lot to 'Emerald Mine Club/path/file/name' -- in effect, putting back the spaces which the game author got rid of some years ago.

(However, I will note that of the 27 files downloaded, 16 do contain spaces in the archive-internal names; of those, 11 are from the game author's site, while 5 are from the Wayback Machine.)
filbo
Posts: 723
Joined: Fri Jun 20, 2014 10:06 am

Re: Debian package issues

Post by filbo »

... and back to comments to Holger:

The 11 files they download, which still contain internal filenames with spaces, are:

Andreas_Buschbeck-1.0.0.zip
BD2K3-1.0.0.zip
earth_3120.zip
eem.zip
might_of_elementals.zip
mod_secret_command.zip
r-old.zip
r-structure.zip
Snake_Bite-1.0.0.zip
world_of_amoeba.zip
ZeldaII-1.0.0.zip

(the latter has just one). I realize some of these are sort of 'preserved artifacts' which maybe shouldn't be disturbed at all; and that changing pathnames is more than just a matter of renaming the files (may have to change RnD .conf files as well). But ... not having spaces in filenames is perhaps a nice eventual goal :)

Also, the 5 files they download from the Wayback Machine are -- ah, I see they now exist directly on artsoft.org under https://www.artsoft.org/rocksndiamonds/ ... nd/rnd.htm, so I will revise my redirects above.

Also also, of course https://www.artsoft.org/rocksndiamonds/levels/ is your curated recommended list, more or less. But does not have strong enough embedded metadata to make it easy for distro packagers to directly use :)
Post Reply