Skip to content

formats/all.cpp: Include IPF, 86F disk formats in floptool #13935

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 18, 2025

Conversation

invertego
Copy link
Contributor

IPF is included unconditionally by scripts/formats.lua, so the HAS_FORMATS condition was always false.

86F is also included unconditionally but simply wasn't added to formats/all.cpp when it was introduced.

I added 86F to the "Container FM/MFM" category for consistency with the grouping in devices/imagedev/floppy.cpp and moved IPF to the "PC" category for the same reason.

cf. 3b13ae6, add6b45

IPF is included unconditionally by scripts/formats.lua, so the
HAS_FORMATS condition was always false.

86F is also included unconditionally but simply wasn't added to
formats/all.cpp when it was introduced.

I added 86F to the "Container FM/MFM" category for consistency with the
grouping in devices/imagedev/floppy.cpp and moved IPF to the "PC"
category for the same reason.
@invertego
Copy link
Contributor Author

While I was doing this, I ran some regexes and found other formats that are missing from all.cpp. However, I don't know much about these additional formats or have samples to test, so I left them out of this change. If anyone want to take that up, here is the missing code.

#ifdef HAS_FORMATS_ABC1600_DSK
#include "abc1600_dsk.h"
#endif
#ifdef HAS_FORMATS_BK0010_DSK
#include "bk0010_dsk.h"
#endif
#ifdef HAS_FORMATS_IDPART_DSK
#include "idpart_dsk.h"
#endif
#ifdef HAS_FORMATS_LW30_DSK
#include "lw30_dsk.h"
#endif
#ifdef HAS_FORMATS_TIBDD001_DSK
#include "tibdd001_dsk.h"
#endif

#ifdef HAS_FORMATS_ABC1600_DSK
	en.add(FLOPPY_ABC1600_FORMAT); // abc1600_dsk.h
#endif
#ifdef HAS_FORMATS_BK0010_DSK
	en.add(FLOPPY_BK0010_FORMAT); // bk0010_dsk.h
#endif
#ifdef HAS_FORMATS_IDPART_DSK
	en.add(FLOPPY_IDPART_FORMAT); // idpart_dsk.h
#endif
#ifdef HAS_FORMATS_LW30_DSK
	en.add(FLOPPY_LW30_FORMAT); // lw30_dsk.h
#endif
#ifdef HAS_FORMATS_TIBDD001_DSK
	en.add(FLOPPY_TIB_DD_001_FORMAT); // tibdd001_dsk.h
#endif
#ifdef HAS_FORMATS_CP68_DSK
	en.add(FLOPPY_CP68_FORMAT); // cp68_dsk.h
#endif
#ifdef HAS_FORMATS_FDOS_DSK
	en.add(FLOPPY_FDOS_FORMAT); // fdos_dsk.h
#endif
#ifdef HAS_FORMATS_MFM_HD
	en.add(MFMHD_GEN_FORMAT); // mfm_hd.h
#endif
#ifdef HAS_FORMATS_ACORN_DSK
	en.add(FLOPPY_CUMANA_DFS_FORMAT); // acorn_dsk.h
#endif

@angelosa
Copy link
Member

Is it okay to have IPF and 86F enabled everywhere? @galibert

@galibert
Copy link
Member

galibert commented Jul 17, 2025 via email

@invertego
Copy link
Contributor Author

To be clear, this change doesn't enable these formats for any new devices. It adds two formats to mame_formats_full_list(), which is only utilized by floptool. It will affect the auto-detect feature of that tool, but both formats have unique header identifiers.

@galibert galibert merged commit 49e5a7d into mamedev:master Jul 18, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants