libretro / libretro/libretro-database

Redump Sega - Mega-CD - Sega CD missing serials

Open
#839 10 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
1.4k
Forks
877
Avg merge
3d 1h
Merged PRs (30d)
24

Description

It seems that the way index.js currently works at https://github.com/robloach/libretro-dats is creating issues for some games with alternate versions being misidentified/ignored.

In the case of “Sonic CD (USA)” for Sega CD, the official Redump DAT has three entries (tracklist abridged for readability) :

<game name="Sonic CD (USA)">
		<category>Games</category>
		<description>Sonic CD (USA)</description>
		<rom name="Sonic CD (USA).cue" size="3820" crc="33b99240" md5="638f1e41830319de1914772076096626" sha1="5b085f78a6904d275715dcfeb454ecc262e704e5"/>
		<rom name="Sonic CD (USA) (Track 01).bin" size="139381872" crc="a6184e05" md5="ed96420538f989e94480f810d5f90685" sha1="3c316af52cc9ee8c30976a1cdb66339545dda3bd"/>
		[...]

<game name="Sonic CD (USA) (RE125)">
		<category>Games</category>
		<description>Sonic CD (USA) (RE125)</description>
		<rom name="Sonic CD (USA) (RE125).cue" size="4100" crc="e8a15187" md5="92d0c52b29c25b21e8d0bef3e3086115" sha1="ff275b2a8bf5c301fed311addca55aee8a1a13ab"/>
		<rom name="Sonic CD (USA) (RE125) (Track 01).bin" size="139381872" crc="a6184e05" md5="ed96420538f989e94480f810d5f90685" sha1="3c316af52cc9ee8c30976a1cdb66339545dda3bd"/>
		[...]
		
<game name="Sonic CD (USA) (RE125) (Alt)">
		<category>Games</category>
		<description>Sonic CD (USA) (RE125) (Alt)</description>
		<rom name="Sonic CD (USA) (RE125) (Alt).cue" size="4310" crc="53948c76" md5="ac75d9b8331ba59da608c49e5cc03cb7" sha1="4d190b6a7cc7e2284f7c16f6afaf94ff625dfb8c"/>
		<rom name="Sonic CD (USA) (RE125) (Alt) (Track 01).bin" size="139381872" crc="a6184e05" md5="ed96420538f989e94480f810d5f90685" sha1="3c316af52cc9ee8c30976a1cdb66339545dda3bd"/>
		[...]

All versions share the same “Track 01.bin” checksums. Once parsed with the libretro-dat javascript routine, there is only one entry under “Sonic CD (USA) (RE125) (Alt)” in the libretro redump metadat:

game (
	name "Sonic CD (USA) (RE125) (Alt)"
	description "Sonic CD (USA) (RE125) (Alt)"
	rom ( name "Sonic CD (USA) (RE125) (Alt) (Track 01).bin" size 139381872 crc a6184e05 md5 ed96420538f989e94480f810d5f90685 sha1 3c316af52cc9ee8c30976a1cdb66339545dda3bd )

The difference in this case only appears in Track 13:

<rom name="Sonic CD (USA) (Track 13).bin" size="14013216" crc="c41a848e" md5="f01a263ce6475c1f43871483e5ab68f2" sha1="21dcc020dae2a0d650eed76540b54897d34ee889"/>
<rom name="Sonic CD (USA) (RE125) (Track 13).bin" size="14013216" crc="282d4f23" md5="88107ee77b536248c0b9149ac1c71ea4" sha1="5797d380e8df06f7d83a37ac55b3072f8a3dff57"/>
<rom name="Sonic CD (USA) (RE125) (Alt) (Track 13).bin" size="14013216" crc="8e9aaeaf" md5="c02b110395c9cb8a6a1066eb5c36835c" sha1="6cfbd4139d60eb7762874aa0308a01f40e0e17fc"/>

The same is true of “Layer Section (Japan) (3M)” and “Layer Section (Japan) (6M)” in the Sega Saturn set. Except the differences appear from Track 02.bin.

        <rom name="Layer Section (Japan) (6M).cue" size="2183" crc="4a838a68" md5="2f21a45ccdf5b439a35d0ad0a4b9f99a" sha1="75932d563fb498e77e0a107efca33c034a75b04c"/>
		<rom name="Layer Section (Japan) (6M) (Track 01).bin" size="16779168" crc="07e9d8da" md5="4cb2552702a5767be5b791efad43762d" sha1="d90ef75e7a8d0ff60fceb58d4e534308b85391ea"/>
		<rom name="Layer Section (Japan) (6M) (Track 02).bin" size="5644800" crc="4385448d" md5="f52bb23aaf351581cea09442d74e0981" sha1="76ee44b608700841f89a3b0c325e7ccf691562c5"/>
		

		<rom name="Layer Section (Japan) (3M).cue" size="2183" crc="6f8ecb12" md5="e6ec1fb1245f5a5ff095bfa29f9d62e1" sha1="7905e5451fbcd372905dae9c4ef2339dff271357"/>
		<rom name="Layer Section (Japan) (3M) (Track 01).bin" size="16779168" crc="07e9d8da" md5="4cb2552702a5767be5b791efad43762d" sha1="d90ef75e7a8d0ff60fceb58d4e534308b85391ea"/>
		<rom name="Layer Section (Japan) (3M) (Track 02).bin" size="5644800" crc="ccffab2f" md5="c7edd32ea27e9596546b6bf8d7148784" sha1="cce1afd9f917210cdf061bdf23982f1597e6639a"/>

Sega - Saturn Libretro MetaDAT

game (
	name "Layer Section (Japan) (6M)"
	description "Layer Section (Japan) (6M)"
	rom ( name "Layer Section (Japan) (6M) (Track 01).bin" size 16779168 crc 07e9d8da md5 4cb2552702a5767be5b791efad43762d sha1 d90ef75e7a8d0ff60fceb58d4e534308b85391ea )
)

Could the script entries be based on the cue checksums instead to make sure all versions are accounted for?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in index.js and inspect how Redump entries are parsed and deduplicated, then compare its output with the Sega CD and Sega Saturn DAT examples linked in the issue. Verify that alternate versions with shared track checksums remain distinguishable and that the generated libretro metadata retains the relevant entries. No test file is mentioned, so validation should use these generated DAT outputs.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
data, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.