Page 1 of 1

Duplicate Machine Disk (CHD) and romof, merge

Posted: Mon Dec 30, 2019 12:01 pm
by spludlow
I was messing around with some code to export and validate machine disks.

There are 787 unique machine disks (0.217). I wanted to see if I can work from a disk set that included no duplicates.

It would appear that MAME requires some disks to be duplicated.

Here is an example.

Parent: "area51"
Children: "area51t" and "area51ta"
Both these children use the disk "area51t" "d2865cc7b1bb08a4393a72013a90e18d8a8f9860".

I can run "area51t" just fine.
If I try to run "area51ta" I get "Required files are missing".
If I copy "area51t/area51t.chd" to "area51ta/area51t.chd" it works.

So this means I need to duplicate disk files in the set.

Is this something that could be fixed in the driver XML? Maybe change area51ta's machine.romof from "area51" to "area51ta" and set disk.merge to "area51t"?

I can see a few of these, that was just the first example I hit.

Cheers

Re: Duplicate Machine Disk (CHD) and romof, merge

Posted: Tue Dec 31, 2019 11:03 am
by spludlow
I've attached a list of all of them, tab delimited.

Re: Duplicate Machine Disk (CHD) and romof, merge

Posted: Sat Jan 04, 2020 3:18 am
by Stiletto
I cast this over to my fellow devs on IRC (you should swing by sometime!) and they had this to say:

area51t is a clone of area51, area51ta is a clone of area51, area51ta can't be a clone of a clone.

You're looking at some technical debt due to old grandfathered-in schemes, aka the parent-clone relationships, which are more about establishing relationships and less about finding ROMs. Still, if we had "sibling groups" instead of 1 parent and x clones, this could maybe be solved.

Or maybe if MAME were smarter, searching for ROMs in other clones as well as the parent, by hash instead of by name. MAME is able to find ROMs by hash but not CHDs.

Maybe the easiest solution for now is to add support for 'clone of clone' but that would break with decades of tradition.

In a perfect world, maybe, we could make it so there was no duplication anywhere.

In the meantime, until this is solved, maybe use a filesystem link.

Re: Duplicate Machine Disk (CHD) and romof, merge

Posted: Mon Jan 06, 2020 11:18 am
by spludlow
Thanks for the detailed answer.

Indeed a perfect world would be nice, but I recon I can live with this.

Cheers