diff options
135 files changed, 155 insertions, 363 deletions
diff --git a/src/devices/bus/a2bus/a2cffa.cpp b/src/devices/bus/a2bus/a2cffa.cpp index 83124c4a51a..8942e05558d 100644 --- a/src/devices/bus/a2bus/a2cffa.cpp +++ b/src/devices/bus/a2bus/a2cffa.cpp @@ -17,7 +17,6 @@ #include "imagedev/harddriv.h" #include "bus/ata/ataintf.h" -#include "fileio.h" #include "softlist.h" diff --git a/src/devices/bus/abcbus/ssa.h b/src/devices/bus/abcbus/ssa.h index d6376cd9d4b..2be5046b24a 100644 --- a/src/devices/bus/abcbus/ssa.h +++ b/src/devices/bus/abcbus/ssa.h @@ -12,7 +12,7 @@ #pragma once #include "abcbus.h" -#include "fileio.h" +#include "machine/nvram.h" diff --git a/src/devices/bus/ata/cr589.cpp b/src/devices/bus/ata/cr589.cpp index 8f0cfed6556..6142f75ee7a 100644 --- a/src/devices/bus/ata/cr589.cpp +++ b/src/devices/bus/ata/cr589.cpp @@ -3,8 +3,6 @@ #include "emu.h" #include "cr589.h" -#include "fileio.h" - static constexpr int identity_offset = 0x3ab; static constexpr char download_identity[] = "MATSHITA CD98Q4 DOWNLOADGS0N"; diff --git a/src/devices/bus/c64/dqbb.h b/src/devices/bus/c64/dqbb.h index 0fbbff1afd5..af9460a5bbe 100644 --- a/src/devices/bus/c64/dqbb.h +++ b/src/devices/bus/c64/dqbb.h @@ -13,7 +13,7 @@ #include "exp.h" -#include "fileio.h" +#include "machine/nvram.h" diff --git a/src/devices/bus/c64/fcc.h b/src/devices/bus/c64/fcc.h index 5f7a180fe20..15a096f5cf5 100644 --- a/src/devices/bus/c64/fcc.h +++ b/src/devices/bus/c64/fcc.h @@ -14,7 +14,6 @@ #include "exp.h" #include "cpu/m6502/m65sc02.h" #include "machine/gen_latch.h" -#include "fileio.h" diff --git a/src/devices/bus/c64/neoram.h b/src/devices/bus/c64/neoram.h index 295b893b5c7..b6729ec08d4 100644 --- a/src/devices/bus/c64/neoram.h +++ b/src/devices/bus/c64/neoram.h @@ -13,7 +13,6 @@ #include "exp.h" -#include "fileio.h" diff --git a/src/devices/bus/iq151/minigraf.cpp b/src/devices/bus/iq151/minigraf.cpp index b3d51bdf8d3..e0962048411 100644 --- a/src/devices/bus/iq151/minigraf.cpp +++ b/src/devices/bus/iq151/minigraf.cpp @@ -10,7 +10,6 @@ #include "minigraf.h" #include "emuopts.h" -#include "fileio.h" #include "png.h" // paper is A4 (297x210mm) diff --git a/src/devices/bus/iq151/ms151a.cpp b/src/devices/bus/iq151/ms151a.cpp index 6b4116f3d42..651e82bfe6f 100644 --- a/src/devices/bus/iq151/ms151a.cpp +++ b/src/devices/bus/iq151/ms151a.cpp @@ -10,7 +10,6 @@ #include "ms151a.h" #include "emuopts.h" -#include "fileio.h" #include "png.h" // paper is A4 (210x297mm) diff --git a/src/devices/bus/pasopia/rampac2.cpp b/src/devices/bus/pasopia/rampac2.cpp index e1d912b92d4..f9059e24345 100644 --- a/src/devices/bus/pasopia/rampac2.cpp +++ b/src/devices/bus/pasopia/rampac2.cpp @@ -12,8 +12,6 @@ #include "emu.h" #include "rampac2.h" -#include "fileio.h" - //************************************************************************** // GLOBAL VARIABLES //************************************************************************** diff --git a/src/devices/bus/pce/pce_rom.cpp b/src/devices/bus/pce/pce_rom.cpp index 1b532e7f081..897878ad13a 100644 --- a/src/devices/bus/pce/pce_rom.cpp +++ b/src/devices/bus/pce/pce_rom.cpp @@ -12,9 +12,6 @@ #include "emu.h" #include "pce_rom.h" -#include "fileio.h" - - //------------------------------------------------- // pce_rom_device - constructor diff --git a/src/devices/bus/pofo/hpc104.h b/src/devices/bus/pofo/hpc104.h index 0522090614e..6afae6dd5ec 100644 --- a/src/devices/bus/pofo/hpc104.h +++ b/src/devices/bus/pofo/hpc104.h @@ -13,7 +13,7 @@ #include "exp.h" #include "bus/pofo/ccm.h" -#include "fileio.h" +#include "machine/nvram.h" diff --git a/src/devices/bus/pofo/ram.h b/src/devices/bus/pofo/ram.h index fe956525896..fc00ac48d2d 100644 --- a/src/devices/bus/pofo/ram.h +++ b/src/devices/bus/pofo/ram.h @@ -12,7 +12,7 @@ #pragma once #include "ccm.h" -#include "fileio.h" +#include "machine/nvram.h" diff --git a/src/devices/bus/s100/seals8k.cpp b/src/devices/bus/s100/seals8k.cpp index da3699f7244..949c7d6d2c5 100644 --- a/src/devices/bus/s100/seals8k.cpp +++ b/src/devices/bus/s100/seals8k.cpp @@ -29,8 +29,6 @@ #include "emu.h" #include "seals8k.h" -#include "fileio.h" - //************************************************************************** // TYPE DEFINITIONS diff --git a/src/devices/bus/saturn/bram.h b/src/devices/bus/saturn/bram.h index 9d5b0eab1f8..71ff5f0ace9 100644 --- a/src/devices/bus/saturn/bram.h +++ b/src/devices/bus/saturn/bram.h @@ -5,8 +5,6 @@ #include "sat_slot.h" -#include "fileio.h" - // ======================> saturn_bram_device diff --git a/src/devices/bus/ti99/gromport/cartridges.cpp b/src/devices/bus/ti99/gromport/cartridges.cpp index ae52f2db820..a6c80531f19 100644 --- a/src/devices/bus/ti99/gromport/cartridges.cpp +++ b/src/devices/bus/ti99/gromport/cartridges.cpp @@ -15,8 +15,6 @@ #include "emu.h" #include "cartridges.h" -#include "fileio.h" - #include "corestr.h" #include "formats/rpk.h" diff --git a/src/devices/bus/ti99/gromport/gkracker.cpp b/src/devices/bus/ti99/gromport/gkracker.cpp index df0967d54cd..37f13623575 100644 --- a/src/devices/bus/ti99/gromport/gkracker.cpp +++ b/src/devices/bus/ti99/gromport/gkracker.cpp @@ -97,8 +97,6 @@ #include "emu.h" #include "gkracker.h" -#include "fileio.h" - #define LOG_WARN (1U<<1) // Warnings #define LOG_CHANGE (1U<<2) // Cartridge change #define LOG_GKRACKER (1U<<3) // Gram Kracker operation diff --git a/src/devices/bus/ti99/internal/buffram.cpp b/src/devices/bus/ti99/internal/buffram.cpp index 76d84d2d6da..1677e2ede8d 100644 --- a/src/devices/bus/ti99/internal/buffram.cpp +++ b/src/devices/bus/ti99/internal/buffram.cpp @@ -11,8 +11,6 @@ #include "emu.h" #include "buffram.h" -#include "fileio.h" - #define VERBOSE ( LOG_GENERAL ) #include "logmacro.h" diff --git a/src/devices/bus/ti99/peb/evpc.cpp b/src/devices/bus/ti99/peb/evpc.cpp index a6a02c3dccd..b99821baf4a 100644 --- a/src/devices/bus/ti99/peb/evpc.cpp +++ b/src/devices/bus/ti99/peb/evpc.cpp @@ -40,8 +40,6 @@ #include "emu.h" #include "evpc.h" - -#include "fileio.h" #include "speaker.h" #define LOG_WARN (1U<<1) // Warnings diff --git a/src/devices/bus/ti99/peb/horizon.cpp b/src/devices/bus/ti99/peb/horizon.cpp index 41ffcc6557d..1be6264189c 100644 --- a/src/devices/bus/ti99/peb/horizon.cpp +++ b/src/devices/bus/ti99/peb/horizon.cpp @@ -126,8 +126,6 @@ #include "emu.h" #include "horizon.h" -#include "fileio.h" - #define LOG_WARN (1U<<1) // Warnings #define LOG_CONFIG (1U<<2) // Configuration #define LOG_32K (1U<<3) // 32K optional RAM r/w diff --git a/src/devices/bus/vic20/megacart.h b/src/devices/bus/vic20/megacart.h index 090e0c7d60c..08e3ef0a59b 100644 --- a/src/devices/bus/vic20/megacart.h +++ b/src/devices/bus/vic20/megacart.h @@ -12,7 +12,6 @@ #pragma once #include "exp.h" -#include "fileio.h" diff --git a/src/devices/cpu/m6805/m68705.cpp b/src/devices/cpu/m6805/m68705.cpp index 1c7ceb2617b..964286124ba 100644 --- a/src/devices/cpu/m6805/m68705.cpp +++ b/src/devices/cpu/m6805/m68705.cpp @@ -16,8 +16,6 @@ #include "m6805defs.h" #include "6805dasm.h" -#include "fileio.h" - /**************************************************************************** * Configurable logging ****************************************************************************/ diff --git a/src/devices/cpu/mcs51/mcs51.cpp b/src/devices/cpu/mcs51/mcs51.cpp index a2c538e9cca..f9e9afc1470 100644 --- a/src/devices/cpu/mcs51/mcs51.cpp +++ b/src/devices/cpu/mcs51/mcs51.cpp @@ -131,12 +131,10 @@ */ #include "emu.h" +#include "debugger.h" #include "mcs51.h" #include "mcs51dasm.h" -#include "debugger.h" -#include "fileio.h" - #define VERBOSE 0 #define LOG(x) do { if (VERBOSE) logerror x; } while (0) diff --git a/src/devices/imagedev/diablo.cpp b/src/devices/imagedev/diablo.cpp index a74ff5947e9..d14c53ef7f2 100644 --- a/src/devices/imagedev/diablo.cpp +++ b/src/devices/imagedev/diablo.cpp @@ -8,7 +8,6 @@ #include "diablo.h" #include "emuopts.h" -#include "fileio.h" #include "harddisk.h" #include "romload.h" diff --git a/src/devices/imagedev/harddriv.cpp b/src/devices/imagedev/harddriv.cpp index ca3367cee73..f06f464f8b4 100644 --- a/src/devices/imagedev/harddriv.cpp +++ b/src/devices/imagedev/harddriv.cpp @@ -17,7 +17,6 @@ #include "harddriv.h" #include "emuopts.h" -#include "fileio.h" #include "harddisk.h" #include "romload.h" diff --git a/src/devices/machine/28fxxx.cpp b/src/devices/machine/28fxxx.cpp index 7841f15470e..e434a761c46 100644 --- a/src/devices/machine/28fxxx.cpp +++ b/src/devices/machine/28fxxx.cpp @@ -32,8 +32,6 @@ #include "emu.h" #include "28fxxx.h" -#include "fileio.h" - #define VERBOSE 0 #include "logmacro.h" diff --git a/src/devices/machine/at28c16.cpp b/src/devices/machine/at28c16.cpp index f9664fd3dc9..fdc7d5c93ec 100644 --- a/src/devices/machine/at28c16.cpp +++ b/src/devices/machine/at28c16.cpp @@ -10,8 +10,6 @@ #include "emu.h" #include "machine/at28c16.h" -#include "fileio.h" - #define AT28C16_DATA_BYTES ( 0x800 ) #define AT28C16_ID_BYTES ( 0x20 ) #define AT28C16_TOTAL_BYTES ( AT28C16_DATA_BYTES + AT28C16_ID_BYTES ) diff --git a/src/devices/machine/at28c64b.cpp b/src/devices/machine/at28c64b.cpp index b3552c90f4b..96302285f0c 100644 --- a/src/devices/machine/at28c64b.cpp +++ b/src/devices/machine/at28c64b.cpp @@ -10,8 +10,6 @@ #include "emu.h" #include "machine/at28c64b.h" -#include "fileio.h" - static constexpr int AT28C64B_DATA_BYTES = 0x10000; static constexpr int AT28C64B_ID_BYTES = 0x40; static constexpr int AT28C64B_TOTAL_BYTES = AT28C64B_DATA_BYTES + AT28C64B_ID_BYTES; diff --git a/src/devices/machine/at29x.cpp b/src/devices/machine/at29x.cpp index 775a6cb42b5..7cc435d7033 100644 --- a/src/devices/machine/at29x.cpp +++ b/src/devices/machine/at29x.cpp @@ -40,8 +40,6 @@ #include "emu.h" #include "at29x.h" -#include "fileio.h" - #define LOG_DETAIL (1U<<1) // More detail #define LOG_WARN (1U<<2) // Warning #define LOG_PRG (1U<<3) // Programming diff --git a/src/devices/machine/at45dbxx.cpp b/src/devices/machine/at45dbxx.cpp index 268c485dc4c..74fc06b4413 100644 --- a/src/devices/machine/at45dbxx.cpp +++ b/src/devices/machine/at45dbxx.cpp @@ -15,8 +15,6 @@ #include "emu.h" #include "at45dbxx.h" -#include "fileio.h" - #define LOG_LEVEL 1 #define _logerror(level,x) do { if (LOG_LEVEL > level) logerror x; } while (0) diff --git a/src/devices/machine/bq4847.cpp b/src/devices/machine/bq4847.cpp index f3d8a7ec4d8..3be75106707 100644 --- a/src/devices/machine/bq4847.cpp +++ b/src/devices/machine/bq4847.cpp @@ -21,8 +21,6 @@ #include "emu.h" #include "bq4847.h" -#include "fileio.h" - #define LOG_WARN (1U<<1) // Warnings #define LOG_CLOCK (1U<<2) // Clock operation #define LOG_REG (1U<<3) // Register write diff --git a/src/devices/machine/bq48x2.cpp b/src/devices/machine/bq48x2.cpp index 6098e5f04ae..40bfde5a754 100644 --- a/src/devices/machine/bq48x2.cpp +++ b/src/devices/machine/bq48x2.cpp @@ -8,8 +8,6 @@ #include "emu.h" #include "bq48x2.h" -#include "fileio.h" - #define LOG_WARN (1U<<1) // Warnings #define LOG_CLOCK (1U<<2) // Clock operation #define LOG_REGW (1U<<3) // Register write diff --git a/src/devices/machine/dp8573.cpp b/src/devices/machine/dp8573.cpp index 10f5960d6d3..529ed3d90fe 100644 --- a/src/devices/machine/dp8573.cpp +++ b/src/devices/machine/dp8573.cpp @@ -10,8 +10,6 @@ #include "machine/dp8573.h" #include "machine/timehelp.h" -#include "fileio.h" - #define LOG_GENERAL (1 << 0) #define LOG_TICKS (1 << 1) #define LOG_ALL (LOG_GENERAL | LOG_TICKS) diff --git a/src/devices/machine/ds1204.cpp b/src/devices/machine/ds1204.cpp index abdbca4421b..ba86725df66 100644 --- a/src/devices/machine/ds1204.cpp +++ b/src/devices/machine/ds1204.cpp @@ -10,8 +10,6 @@ #include "emu.h" #include "ds1204.h" -#include "fileio.h" - #include <cstdio> diff --git a/src/devices/machine/ds1205.cpp b/src/devices/machine/ds1205.cpp index 25c98f441e7..460d267928a 100644 --- a/src/devices/machine/ds1205.cpp +++ b/src/devices/machine/ds1205.cpp @@ -10,8 +10,6 @@ #include "emu.h" #include "ds1205.h" -#include "fileio.h" - #include <cstdio> diff --git a/src/devices/machine/ds1302.cpp b/src/devices/machine/ds1302.cpp index 34d75224748..e284e359e12 100644 --- a/src/devices/machine/ds1302.cpp +++ b/src/devices/machine/ds1302.cpp @@ -18,8 +18,6 @@ #include "emu.h" #include "ds1302.h" -#include "fileio.h" - //#define VERBOSE 1 #include "logmacro.h" diff --git a/src/devices/machine/ds1386.cpp b/src/devices/machine/ds1386.cpp index edbd46f07b5..cd3f601b0ea 100644 --- a/src/devices/machine/ds1386.cpp +++ b/src/devices/machine/ds1386.cpp @@ -12,8 +12,6 @@ #include "ds1386.h" #include "machine/timehelp.h" -#include "fileio.h" - #define DISABLE_OSC (0x80) #define DISABLE_SQW (0x40) diff --git a/src/devices/machine/ds1994.cpp b/src/devices/machine/ds1994.cpp index 2d16d3eed54..3b9e9f0ebe9 100644 --- a/src/devices/machine/ds1994.cpp +++ b/src/devices/machine/ds1994.cpp @@ -15,8 +15,6 @@ #include "emu.h" #include "machine/ds1994.h" -#include "fileio.h" - #include <ctime> #define VERBOSE_LEVEL 0 diff --git a/src/devices/machine/ds2404.cpp b/src/devices/machine/ds2404.cpp index f488b116aec..7c5876ee9d0 100644 --- a/src/devices/machine/ds2404.cpp +++ b/src/devices/machine/ds2404.cpp @@ -16,8 +16,6 @@ #include "emu.h" #include "ds2404.h" -#include "fileio.h" - #include <algorithm> #include <ctime> // FIXME: re-write in terms of device_rtc_interface and remove this diff --git a/src/devices/machine/eeprom.cpp b/src/devices/machine/eeprom.cpp index 791e5c88ec5..0c81a6701e0 100644 --- a/src/devices/machine/eeprom.cpp +++ b/src/devices/machine/eeprom.cpp @@ -11,8 +11,6 @@ #include "emu.h" #include "machine/eeprom.h" -#include "fileio.h" - //#define VERBOSE 1 #include "logmacro.h" diff --git a/src/devices/machine/er1400.cpp b/src/devices/machine/er1400.cpp index 7f73983e173..e239f621e5d 100644 --- a/src/devices/machine/er1400.cpp +++ b/src/devices/machine/er1400.cpp @@ -24,8 +24,6 @@ #include "emu.h" #include "machine/er1400.h" -#include "fileio.h" - #define VERBOSE 0 #include "logmacro.h" diff --git a/src/devices/machine/er2055.cpp b/src/devices/machine/er2055.cpp index 80faafe3a46..20fd3805e7d 100644 --- a/src/devices/machine/er2055.cpp +++ b/src/devices/machine/er2055.cpp @@ -14,8 +14,6 @@ #include "emu.h" #include "machine/er2055.h" -#include "fileio.h" - #include "logmacro.h" diff --git a/src/devices/machine/hd64610.cpp b/src/devices/machine/hd64610.cpp index bb62c11cb36..beedbeea73d 100644 --- a/src/devices/machine/hd64610.cpp +++ b/src/devices/machine/hd64610.cpp @@ -16,9 +16,7 @@ #include "emu.h" #include "hd64610.h" - #include "coreutil.h" -#include "fileio.h" #define VERBOSE 1 #include "logmacro.h" diff --git a/src/devices/machine/i2cmem.cpp b/src/devices/machine/i2cmem.cpp index a951f325110..d5fd3f3094a 100644 --- a/src/devices/machine/i2cmem.cpp +++ b/src/devices/machine/i2cmem.cpp @@ -25,8 +25,6 @@ there are two standard values. #include "emu.h" #include "machine/i2cmem.h" -#include "fileio.h" - constexpr int STATE_IDLE(0); constexpr int STATE_DEVSEL(1); constexpr int STATE_ADDRESSHIGH(2); diff --git a/src/devices/machine/icm7170.cpp b/src/devices/machine/icm7170.cpp index 097fadf3b57..8537074371a 100644 --- a/src/devices/machine/icm7170.cpp +++ b/src/devices/machine/icm7170.cpp @@ -8,9 +8,7 @@ #include "emu.h" #include "icm7170.h" - #include "coreutil.h" -#include "fileio.h" #define VERBOSE (0) #include "logmacro.h" diff --git a/src/devices/machine/intelfsh.cpp b/src/devices/machine/intelfsh.cpp index 92561edc32a..5221668059f 100644 --- a/src/devices/machine/intelfsh.cpp +++ b/src/devices/machine/intelfsh.cpp @@ -16,8 +16,6 @@ #include "emu.h" #include "intelfsh.h" -#include "fileio.h" - //************************************************************************** // CONSTANTS diff --git a/src/devices/machine/m3002.cpp b/src/devices/machine/m3002.cpp index 9a51792f11d..fd93666a55f 100644 --- a/src/devices/machine/m3002.cpp +++ b/src/devices/machine/m3002.cpp @@ -14,8 +14,6 @@ #include "emu.h" #include "m3002.h" -#include "fileio.h" - #define VERBOSE 0 #include "logmacro.h" diff --git a/src/devices/machine/m6m80011ap.cpp b/src/devices/machine/m6m80011ap.cpp index 56d9911dc6c..79d7073c331 100644 --- a/src/devices/machine/m6m80011ap.cpp +++ b/src/devices/machine/m6m80011ap.cpp @@ -4,8 +4,6 @@ #include "emu.h" #include "machine/m6m80011ap.h" -#include "fileio.h" - //************************************************************************** diff --git a/src/devices/machine/mc146818.cpp b/src/devices/machine/mc146818.cpp index 49f77a3a012..7f2aab30270 100644 --- a/src/devices/machine/mc146818.cpp +++ b/src/devices/machine/mc146818.cpp @@ -12,10 +12,8 @@ *********************************************************************/ #include "emu.h" -#include "machine/mc146818.h" - #include "coreutil.h" -#include "fileio.h" +#include "machine/mc146818.h" //#define VERBOSE 1 #include "logmacro.h" diff --git a/src/devices/machine/mccs1850.cpp b/src/devices/machine/mccs1850.cpp index f422d769cea..ebd70e04f9c 100644 --- a/src/devices/machine/mccs1850.cpp +++ b/src/devices/machine/mccs1850.cpp @@ -18,8 +18,6 @@ #include "emu.h" #include "mccs1850.h" -#include "fileio.h" - //#define VERBOSE 0 #include "logmacro.h" diff --git a/src/devices/machine/msm58321.cpp b/src/devices/machine/msm58321.cpp index 7f7ba37b1a2..c34513e6847 100644 --- a/src/devices/machine/msm58321.cpp +++ b/src/devices/machine/msm58321.cpp @@ -17,8 +17,6 @@ #include "emu.h" #include "msm58321.h" -#include "fileio.h" - //#define VERBOSE 1 #include "logmacro.h" diff --git a/src/devices/machine/nmc9306.cpp b/src/devices/machine/nmc9306.cpp index c977bee7925..d20e77a398b 100644 --- a/src/devices/machine/nmc9306.cpp +++ b/src/devices/machine/nmc9306.cpp @@ -9,8 +9,6 @@ #include "emu.h" #include "nmc9306.h" -#include "fileio.h" - //#define VERBOSE 1 #include "logmacro.h" diff --git a/src/devices/machine/nvram.cpp b/src/devices/machine/nvram.cpp index b6adb230ea5..e00d10447a8 100644 --- a/src/devices/machine/nvram.cpp +++ b/src/devices/machine/nvram.cpp @@ -11,8 +11,6 @@ #include "emu.h" #include "machine/nvram.h" -#include "fileio.h" - //************************************************************************** // LIVE DEVICE //************************************************************************** diff --git a/src/devices/machine/pcf8583.cpp b/src/devices/machine/pcf8583.cpp index fb1eb2b2a79..7883340cf15 100644 --- a/src/devices/machine/pcf8583.cpp +++ b/src/devices/machine/pcf8583.cpp @@ -12,8 +12,6 @@ #include "emu.h" #include "pcf8583.h" -#include "fileio.h" - #define LOG_DATA (1 << 1) #define LOG_LINE (1 << 2) diff --git a/src/devices/machine/pcf8593.cpp b/src/devices/machine/pcf8593.cpp index c0ed932c5fe..dc3d93d7ad1 100644 --- a/src/devices/machine/pcf8593.cpp +++ b/src/devices/machine/pcf8593.cpp @@ -11,8 +11,6 @@ #include "emu.h" #include "pcf8593.h" -#include "fileio.h" - /*************************************************************************** PARAMETERS/CONSTANTS/MACROS diff --git a/src/devices/machine/rp5c01.cpp b/src/devices/machine/rp5c01.cpp index 61e523afe51..8ea9e85e6ef 100644 --- a/src/devices/machine/rp5c01.cpp +++ b/src/devices/machine/rp5c01.cpp @@ -19,8 +19,6 @@ #include "emu.h" #include "rp5c01.h" -#include "fileio.h" - // device type definitions DEFINE_DEVICE_TYPE(RP5C01, rp5c01_device, "rp5c01", "Ricoh RP5C01 RTC") diff --git a/src/devices/machine/rtc65271.cpp b/src/devices/machine/rtc65271.cpp index a74c9ecd06d..b39730fb372 100644 --- a/src/devices/machine/rtc65271.cpp +++ b/src/devices/machine/rtc65271.cpp @@ -21,8 +21,6 @@ #include "emu.h" #include "rtc65271.h" -#include "fileio.h" - /* Delay between the beginning (UIP asserted) and the end (UIP cleared and update interrupt asserted) of the update cycle */ #define UPDATE_CYCLE_TIME attotime::from_usec(1984) diff --git a/src/devices/machine/rtc9701.cpp b/src/devices/machine/rtc9701.cpp index f022d9fe329..a8ccc5cec7f 100644 --- a/src/devices/machine/rtc9701.cpp +++ b/src/devices/machine/rtc9701.cpp @@ -14,8 +14,6 @@ #include "emu.h" #include "machine/rtc9701.h" -#include "fileio.h" - ALLOW_SAVE_TYPE(rtc9701_device::state_t); diff --git a/src/devices/machine/s3520cf.cpp b/src/devices/machine/s3520cf.cpp index 6cc780e7175..abdd1d83638 100644 --- a/src/devices/machine/s3520cf.cpp +++ b/src/devices/machine/s3520cf.cpp @@ -17,8 +17,6 @@ TODO: #include "emu.h" #include "machine/s3520cf.h" -#include "fileio.h" - //************************************************************************** diff --git a/src/devices/machine/sda2006.cpp b/src/devices/machine/sda2006.cpp index e44cf48881c..853e5cf871d 100644 --- a/src/devices/machine/sda2006.cpp +++ b/src/devices/machine/sda2006.cpp @@ -4,8 +4,6 @@ #include "emu.h" #include "machine/sda2006.h" -#include "fileio.h" - //------------------------------------------------- // // Siemens SDA2006 512-bit (32x16) NV EEPROM diff --git a/src/devices/machine/sensorboard.cpp b/src/devices/machine/sensorboard.cpp index 0889e80a016..3d4188396dd 100644 --- a/src/devices/machine/sensorboard.cpp +++ b/src/devices/machine/sensorboard.cpp @@ -59,8 +59,6 @@ sensor state instead. #include "emu.h" #include "machine/sensorboard.h" -#include "fileio.h" - DEFINE_DEVICE_TYPE(SENSORBOARD, sensorboard_device, "sensorboard", "Sensorboard") diff --git a/src/devices/machine/serflash.cpp b/src/devices/machine/serflash.cpp index 801a212a592..c616b4d34a7 100644 --- a/src/devices/machine/serflash.cpp +++ b/src/devices/machine/serflash.cpp @@ -8,8 +8,6 @@ #include "emu.h" #include "machine/serflash.h" -#include "fileio.h" - #include <algorithm> ALLOW_SAVE_TYPE(serflash_device::flash_state_t); diff --git a/src/devices/machine/sonydriv.cpp b/src/devices/machine/sonydriv.cpp index e99c077b02a..d65c1146359 100644 --- a/src/devices/machine/sonydriv.cpp +++ b/src/devices/machine/sonydriv.cpp @@ -39,8 +39,6 @@ #include "formats/ap_dsk35.h" #include "imagedev/flopdrv.h" -#include "fileio.h" - #ifdef MAME_DEBUG #define LOG_SONY 1 diff --git a/src/devices/machine/strata.cpp b/src/devices/machine/strata.cpp index 57383ef8e11..7976a16def9 100644 --- a/src/devices/machine/strata.cpp +++ b/src/devices/machine/strata.cpp @@ -23,8 +23,6 @@ #include "emu.h" #include "strata.h" -#include "fileio.h" - #define FEEPROM_SIZE 0x800000 // 64Mbit #define BLOCK_SIZE 0x020000 diff --git a/src/devices/machine/timekpr.cpp b/src/devices/machine/timekpr.cpp index bf3225103b8..fbddc56d1ab 100644 --- a/src/devices/machine/timekpr.cpp +++ b/src/devices/machine/timekpr.cpp @@ -18,8 +18,6 @@ #include "machine/timekpr.h" #include "machine/timehelp.h" -#include "fileio.h" - #define LOG_GENERAL (1U << 0) #define LOG_TICKS (1U << 1) diff --git a/src/devices/machine/x2201.cpp b/src/devices/machine/x2201.cpp index 50be117403e..d93fca101ff 100644 --- a/src/devices/machine/x2201.cpp +++ b/src/devices/machine/x2201.cpp @@ -24,9 +24,6 @@ #include "emu.h" #include "machine/x2201.h" - -#include "fileio.h" - #include <algorithm> diff --git a/src/devices/machine/x2212.cpp b/src/devices/machine/x2212.cpp index e055f860640..cc5028e0cc7 100644 --- a/src/devices/machine/x2212.cpp +++ b/src/devices/machine/x2212.cpp @@ -10,9 +10,6 @@ #include "emu.h" #include "machine/x2212.h" - -#include "fileio.h" - #include <algorithm> diff --git a/src/devices/machine/x76f041.cpp b/src/devices/machine/x76f041.cpp index 0f2f0f87f09..06b831eeda6 100644 --- a/src/devices/machine/x76f041.cpp +++ b/src/devices/machine/x76f041.cpp @@ -16,8 +16,6 @@ #include "emu.h" #include "machine/x76f041.h" -#include "fileio.h" - #define VERBOSE_LEVEL ( 0 ) inline void ATTR_PRINTF( 3, 4 ) x76f041_device::verboselog( int n_level, const char *s_fmt, ... ) diff --git a/src/devices/machine/x76f100.cpp b/src/devices/machine/x76f100.cpp index 825486c0e27..b03829265ac 100644 --- a/src/devices/machine/x76f100.cpp +++ b/src/devices/machine/x76f100.cpp @@ -14,8 +14,6 @@ #include "emu.h" #include "machine/x76f100.h" -#include "fileio.h" - #define VERBOSE_LEVEL ( 0 ) inline void ATTR_PRINTF( 3, 4 ) x76f100_device::verboselog( int n_level, const char *s_fmt, ... ) diff --git a/src/devices/sound/samples.cpp b/src/devices/sound/samples.cpp index bd8fbb1144f..7663d921475 100644 --- a/src/devices/sound/samples.cpp +++ b/src/devices/sound/samples.cpp @@ -26,7 +26,6 @@ #include "samples.h" #include "emuopts.h" -#include "fileio.h" #include "flac.h" diff --git a/src/emu/config.cpp b/src/emu/config.cpp index c6b85bb6ae8..792da6f255d 100644 --- a/src/emu/config.cpp +++ b/src/emu/config.cpp @@ -13,7 +13,6 @@ #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "xmlfile.h" diff --git a/src/emu/crsshair.cpp b/src/emu/crsshair.cpp index d90cc9a7f5e..3c6a6b807f0 100644 --- a/src/emu/crsshair.cpp +++ b/src/emu/crsshair.cpp @@ -13,7 +13,6 @@ #include "config.h" #include "emuopts.h" -#include "fileio.h" #include "render.h" #include "rendutil.h" #include "screen.h" diff --git a/src/emu/debug/debugcmd.cpp b/src/emu/debug/debugcmd.cpp index 9b68c234d2f..b8de0298432 100644 --- a/src/emu/debug/debugcmd.cpp +++ b/src/emu/debug/debugcmd.cpp @@ -21,7 +21,6 @@ #include "debugger.h" #include "emuopts.h" -#include "fileio.h" #include "natkeyboard.h" #include "render.h" #include "screen.h" @@ -2192,7 +2191,8 @@ void debugger_commands::execute_rplist(const std::vector<std::string> ¶ms) void debugger_commands::execute_statesave(const std::vector<std::string> ¶ms) { - m_machine.immediate_save(params[0]); + const std::string &filename(params[0]); + m_machine.immediate_save(filename.c_str()); m_console.printf("State save attempted. Please refer to window message popup for results.\n"); } @@ -2203,7 +2203,8 @@ void debugger_commands::execute_statesave(const std::vector<std::string> ¶ms void debugger_commands::execute_stateload(const std::vector<std::string> ¶ms) { - m_machine.immediate_load(params[0]); + const std::string &filename(params[0]); + m_machine.immediate_load(filename.c_str()); // clear all PC & memory tracks for (device_t &device : device_enumerator(m_machine.root_device())) @@ -4258,7 +4259,7 @@ void debugger_commands::execute_unmount(const std::vector<std::string> ¶ms) void debugger_commands::execute_input(const std::vector<std::string> ¶ms) { - m_machine.natkeyboard().post_coded(params[0]); + m_machine.natkeyboard().post_coded(params[0].c_str()); } diff --git a/src/emu/debug/debugcon.cpp b/src/emu/debug/debugcon.cpp index 210087ab1c0..32a4888c285 100644 --- a/src/emu/debug/debugcon.cpp +++ b/src/emu/debug/debugcon.cpp @@ -16,7 +16,6 @@ #include "textbuf.h" #include "debugger.h" -#include "fileio.h" #include "corestr.h" @@ -87,10 +86,6 @@ debugger_console::debugger_console(running_machine &machine) } } -debugger_console::~debugger_console() -{ -} - /*------------------------------------------------- exit - frees the console system diff --git a/src/emu/debug/debugcon.h b/src/emu/debug/debugcon.h index f8a0bafc7c1..5271b0e5ae5 100644 --- a/src/emu/debug/debugcon.h +++ b/src/emu/debug/debugcon.h @@ -79,7 +79,6 @@ class debugger_console { public: debugger_console(running_machine &machine); - ~debugger_console(); // command handling CMDERR execute_command(const std::string &command, bool echo); diff --git a/src/emu/debug/debugcpu.cpp b/src/emu/debug/debugcpu.cpp index 978702094b9..b4689bc9892 100644 --- a/src/emu/debug/debugcpu.cpp +++ b/src/emu/debug/debugcpu.cpp @@ -19,7 +19,6 @@ #include "debugger.h" #include "emuopts.h" -#include "fileio.h" #include "screen.h" #include "uiinput.h" diff --git a/src/emu/diimage.cpp b/src/emu/diimage.cpp index 6f01f8f26b5..81bd272ef6a 100644 --- a/src/emu/diimage.cpp +++ b/src/emu/diimage.cpp @@ -11,7 +11,6 @@ #include "emu.h" #include "emuopts.h" -#include "fileio.h" #include "romload.h" #include "softlist.h" #include "softlist_dev.h" diff --git a/src/emu/emu.h b/src/emu/emu.h index 5ba862171a4..67d879cd772 100644 --- a/src/emu/emu.h +++ b/src/emu/emu.h @@ -39,12 +39,12 @@ // commonly-referenced utilities imported from lib/util #include "corealloc.h" -#include "corefile.h" -#include "delegate.h" -#include "hash.h" #include "palette.h" // emulator-specific utilities +#include "hash.h" +#include "fileio.h" +#include "delegate.h" #include "devdelegate.h" // memory and address spaces diff --git a/src/emu/emufwd.h b/src/emu/emufwd.h index 6d0528015c4..13e6d40865a 100644 --- a/src/emu/emufwd.h +++ b/src/emu/emufwd.h @@ -152,9 +152,6 @@ class memory_view; // declared in emuopts.h class emu_options; -// declared in fileio.h -class emu_file; - // declared in http.h class http_manager; diff --git a/src/emu/hashfile.cpp b/src/emu/hashfile.cpp index 8436ad339fb..a6107e5e630 100644 --- a/src/emu/hashfile.cpp +++ b/src/emu/hashfile.cpp @@ -13,7 +13,6 @@ #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "hash.h" diff --git a/src/emu/image.cpp b/src/emu/image.cpp index e7f070eb9ea..5e58758eb89 100644 --- a/src/emu/image.cpp +++ b/src/emu/image.cpp @@ -14,7 +14,6 @@ #include "config.h" #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "softlist.h" #include "corestr.h" diff --git a/src/emu/ioport.cpp b/src/emu/ioport.cpp index f96b2a8d323..a9b86776247 100644 --- a/src/emu/ioport.cpp +++ b/src/emu/ioport.cpp @@ -93,7 +93,6 @@ #include "emu.h" #include "emuopts.h" #include "config.h" -#include "fileio.h" #include "xmlfile.h" #include "profiler.h" #include "ui/uimain.h" @@ -340,117 +339,6 @@ std::string substitute_player(std::string_view name, u8 player) return result; } - - -// ======================> inp_header - -// header at the front of INP files -class inp_header -{ -public: - // parameters - static constexpr unsigned MAJVERSION = 3; - static constexpr unsigned MINVERSION = 0; - - bool read(emu_file &f) - { - return f.read(m_data, sizeof(m_data)) == sizeof(m_data); - } - bool write(emu_file &f) const - { - return f.write(m_data, sizeof(m_data)) == sizeof(m_data); - } - - bool check_magic() const - { - return 0 == std::memcmp(MAGIC, m_data + OFFS_MAGIC, OFFS_BASETIME - OFFS_MAGIC); - } - u64 get_basetime() const - { - return - (u64(m_data[OFFS_BASETIME + 0]) << (0 * 8)) | - (u64(m_data[OFFS_BASETIME + 1]) << (1 * 8)) | - (u64(m_data[OFFS_BASETIME + 2]) << (2 * 8)) | - (u64(m_data[OFFS_BASETIME + 3]) << (3 * 8)) | - (u64(m_data[OFFS_BASETIME + 4]) << (4 * 8)) | - (u64(m_data[OFFS_BASETIME + 5]) << (5 * 8)) | - (u64(m_data[OFFS_BASETIME + 6]) << (6 * 8)) | - (u64(m_data[OFFS_BASETIME + 7]) << (7 * 8)); - } - unsigned get_majversion() const - { - return m_data[OFFS_MAJVERSION]; - } - unsigned get_minversion() const - { - return m_data[OFFS_MINVERSION]; - } - std::string get_sysname() const - { - return get_string<OFFS_SYSNAME, OFFS_APPDESC>(); - } - std::string get_appdesc() const - { - return get_string<OFFS_APPDESC, OFFS_END>(); - } - - void set_magic() - { - std::memcpy(m_data + OFFS_MAGIC, MAGIC, OFFS_BASETIME - OFFS_MAGIC); - } - void set_basetime(u64 time) - { - m_data[OFFS_BASETIME + 0] = u8((time >> (0 * 8)) & 0x00ff); - m_data[OFFS_BASETIME + 1] = u8((time >> (1 * 8)) & 0x00ff); - m_data[OFFS_BASETIME + 2] = u8((time >> (2 * 8)) & 0x00ff); - m_data[OFFS_BASETIME + 3] = u8((time >> (3 * 8)) & 0x00ff); - m_data[OFFS_BASETIME + 4] = u8((time >> (4 * 8)) & 0x00ff); - m_data[OFFS_BASETIME + 5] = u8((time >> (5 * 8)) & 0x00ff); - m_data[OFFS_BASETIME + 6] = u8((time >> (6 * 8)) & 0x00ff); - m_data[OFFS_BASETIME + 7] = u8((time >> (7 * 8)) & 0x00ff); - } - void set_version() - { - m_data[OFFS_MAJVERSION] = MAJVERSION; - m_data[OFFS_MINVERSION] = MINVERSION; - } - void set_sysname(std::string const &name) - { - set_string<OFFS_SYSNAME, OFFS_APPDESC>(name); - } - void set_appdesc(std::string const &desc) - { - set_string<OFFS_APPDESC, OFFS_END>(desc); - } - -private: - template <std::size_t BEGIN, std::size_t END> void set_string(std::string const &str) - { - std::size_t const used = (std::min<std::size_t>)(str.size() + 1, END - BEGIN); - std::memcpy(m_data + BEGIN, str.c_str(), used); - if ((END - BEGIN) > used) - std::memset(m_data + BEGIN + used, 0, (END - BEGIN) - used); - } - template <std::size_t BEGIN, std::size_t END> std::string get_string() const - { - char const *const begin = reinterpret_cast<char const *>(m_data + BEGIN); - return std::string(begin, std::find(begin, reinterpret_cast<char const *>(m_data + END), '\0')); - } - - static constexpr std::size_t OFFS_MAGIC = 0x00; // 0x08 bytes - static constexpr std::size_t OFFS_BASETIME = 0x08; // 0x08 bytes (little-endian binary integer) - static constexpr std::size_t OFFS_MAJVERSION = 0x10; // 0x01 bytes (binary integer) - static constexpr std::size_t OFFS_MINVERSION = 0x11; // 0x01 bytes (binary integer) - // 0x02 bytes reserved - static constexpr std::size_t OFFS_SYSNAME = 0x14; // 0x0c bytes (ASCII) - static constexpr std::size_t OFFS_APPDESC = 0x20; // 0x20 bytes (ASCII) - static constexpr std::size_t OFFS_END = 0x40; - - static u8 const MAGIC[OFFS_BASETIME - OFFS_MAGIC]; - - u8 m_data[OFFS_END]; -}; - } // anonymous namespace @@ -1828,6 +1716,8 @@ ioport_manager::ioport_manager(running_machine &machine) , m_safe_to_read(false) , m_last_frame_time(attotime::zero) , m_last_delta_nsec(0) + , m_record_file(machine.options().input_directory(), OPEN_FLAG_WRITE | OPEN_FLAG_CREATE | OPEN_FLAG_CREATE_PATHS) + , m_playback_file(machine.options().input_directory(), OPEN_FLAG_READ) , m_playback_accumulated_speed(0) , m_playback_accumulated_frames(0) , m_deselected_card_config() @@ -2903,8 +2793,7 @@ time_t ioport_manager::playback_init() return 0; // open the playback file - m_playback_file = std::make_unique<emu_file>(machine().options().input_directory(), OPEN_FLAG_READ); - std::error_condition const filerr = m_playback_file->open(filename); + std::error_condition const filerr = m_playback_file.open(filename); // return an explicit error if file isn't found in given path if (filerr == std::errc::no_such_file_or_directory) @@ -2916,7 +2805,7 @@ time_t ioport_manager::playback_init() // read the header and verify that it is a modern version; if not, print an error inp_header header; - if (!header.read(*m_playback_file)) + if (!header.read(m_playback_file)) fatalerror("Input file is corrupt or invalid (missing header)\n"); if (!header.check_magic()) fatalerror("Input file invalid or in an older, unsupported format\n"); @@ -2936,7 +2825,7 @@ time_t ioport_manager::playback_init() osd_printf_info("Input file is for machine '%s', not for current machine '%s'\n", sysname, machine().system().name); // enable compression - m_playback_stream = util::zlib_read(*m_playback_file, 16386); + m_playback_stream = util::zlib_read(m_playback_file, 16386); return basetime; } @@ -2952,7 +2841,7 @@ void ioport_manager::playback_end(const char *message) { // close the file m_playback_stream.reset(); - m_playback_file.reset(); + m_playback_file.close(); // pop a message if (message != nullptr) @@ -3074,8 +2963,7 @@ void ioport_manager::record_init() return; // open the record file - m_record_file = std::make_unique<emu_file>(machine().options().input_directory(), OPEN_FLAG_WRITE | OPEN_FLAG_CREATE | OPEN_FLAG_CREATE_PATHS); - std::error_condition const filerr = m_record_file->open(filename); + std::error_condition const filerr = m_record_file.open(filename); if (filerr) throw emu_fatalerror("ioport_manager::record_init: Failed to open file for recording (%s:%d %s)", filerr.category().name(), filerr.value(), filerr.message()); @@ -3092,10 +2980,10 @@ void ioport_manager::record_init() header.set_appdesc(util::string_format("%s %s", emulator_info::get_appname(), emulator_info::get_build_version())); // write it - header.write(*m_record_file); + header.write(m_record_file); // enable compression - m_record_stream = util::zlib_write(*m_record_file, 6, 16384); + m_record_stream = util::zlib_write(m_record_file, 6, 16384); } @@ -3110,7 +2998,7 @@ void ioport_manager::record_end(const char *message) { // close the file m_record_stream.reset(); // TODO: check for errors flushing the last compressed block before doing this - m_record_file.reset(); + m_record_file.close(); // pop a message if (message != nullptr) diff --git a/src/emu/ioport.h b/src/emu/ioport.h index 2d9bd855918..e81cce1e8c4 100644 --- a/src/emu/ioport.h +++ b/src/emu/ioport.h @@ -662,6 +662,116 @@ typedef device_delegate<void (ioport_field &, u32, ioport_value, ioport_value)> typedef device_delegate<float (float)> ioport_field_crossmap_delegate; +// ======================> inp_header + +// header at the front of INP files +class inp_header +{ +public: + // parameters + static constexpr unsigned MAJVERSION = 3; + static constexpr unsigned MINVERSION = 0; + + bool read(emu_file &f) + { + return f.read(m_data, sizeof(m_data)) == sizeof(m_data); + } + bool write(emu_file &f) const + { + return f.write(m_data, sizeof(m_data)) == sizeof(m_data); + } + + bool check_magic() const + { + return 0 == std::memcmp(MAGIC, m_data + OFFS_MAGIC, OFFS_BASETIME - OFFS_MAGIC); + } + u64 get_basetime() const + { + return + (u64(m_data[OFFS_BASETIME + 0]) << (0 * 8)) | + (u64(m_data[OFFS_BASETIME + 1]) << (1 * 8)) | + (u64(m_data[OFFS_BASETIME + 2]) << (2 * 8)) | + (u64(m_data[OFFS_BASETIME + 3]) << (3 * 8)) | + (u64(m_data[OFFS_BASETIME + 4]) << (4 * 8)) | + (u64(m_data[OFFS_BASETIME + 5]) << (5 * 8)) | + (u64(m_data[OFFS_BASETIME + 6]) << (6 * 8)) | + (u64(m_data[OFFS_BASETIME + 7]) << (7 * 8)); + } + unsigned get_majversion() const + { + return m_data[OFFS_MAJVERSION]; + } + unsigned get_minversion() const + { + return m_data[OFFS_MINVERSION]; + } + std::string get_sysname() const + { + return get_string<OFFS_SYSNAME, OFFS_APPDESC>(); + } + std::string get_appdesc() const + { + return get_string<OFFS_APPDESC, OFFS_END>(); + } + + void set_magic() + { + std::memcpy(m_data + OFFS_MAGIC, MAGIC, OFFS_BASETIME - OFFS_MAGIC); + } + void set_basetime(u64 time) + { + m_data[OFFS_BASETIME + 0] = u8((time >> (0 * 8)) & 0x00ff); + m_data[OFFS_BASETIME + 1] = u8((time >> (1 * 8)) & 0x00ff); + m_data[OFFS_BASETIME + 2] = u8((time >> (2 * 8)) & 0x00ff); + m_data[OFFS_BASETIME + 3] = u8((time >> (3 * 8)) & 0x00ff); + m_data[OFFS_BASETIME + 4] = u8((time >> (4 * 8)) & 0x00ff); + m_data[OFFS_BASETIME + 5] = u8((time >> (5 * 8)) & 0x00ff); + m_data[OFFS_BASETIME + 6] = u8((time >> (6 * 8)) & 0x00ff); + m_data[OFFS_BASETIME + 7] = u8((time >> (7 * 8)) & 0x00ff); + } + void set_version() + { + m_data[OFFS_MAJVERSION] = MAJVERSION; + m_data[OFFS_MINVERSION] = MINVERSION; + } + void set_sysname(std::string const &name) + { + set_string<OFFS_SYSNAME, OFFS_APPDESC>(name); + } + void set_appdesc(std::string const &desc) + { + set_string<OFFS_APPDESC, OFFS_END>(desc); + } + +private: + template <std::size_t BEGIN, std::size_t END> void set_string(std::string const &str) + { + std::size_t const used = (std::min<std::size_t>)(str.size() + 1, END - BEGIN); + std::memcpy(m_data + BEGIN, str.c_str(), used); + if ((END - BEGIN) > used) + std::memset(m_data + BEGIN + used, 0, (END - BEGIN) - used); + } + template <std::size_t BEGIN, std::size_t END> std::string get_string() const + { + char const *const begin = reinterpret_cast<char const *>(m_data + BEGIN); + return std::string(begin, std::find(begin, reinterpret_cast<char const *>(m_data + END), '\0')); + } + + static constexpr std::size_t OFFS_MAGIC = 0x00; // 0x08 bytes + static constexpr std::size_t OFFS_BASETIME = 0x08; // 0x08 bytes (little-endian binary integer) + static constexpr std::size_t OFFS_MAJVERSION = 0x10; // 0x01 bytes (binary integer) + static constexpr std::size_t OFFS_MINVERSION = 0x11; // 0x01 bytes (binary integer) + // 0x02 bytes reserved + static constexpr std::size_t OFFS_SYSNAME = 0x14; // 0x0c bytes (ASCII) + static constexpr std::size_t OFFS_APPDESC = 0x20; // 0x20 bytes (ASCII) + static constexpr std::size_t OFFS_END = 0x40; + + static u8 const MAGIC[OFFS_BASETIME - OFFS_MAGIC]; + + u8 m_data[OFFS_END]; +}; + + // ======================> input_device_default // device defined default input settings @@ -1339,8 +1449,8 @@ private: attoseconds_t m_last_delta_nsec; // nanoseconds that passed since the previous callback // playback/record information - std::unique_ptr<emu_file> m_record_file; // recording file (nullptr if not recording) - std::unique_ptr<emu_file> m_playback_file; // playback file (nullptr if not recording) + emu_file m_record_file; // recording file (closed if not recording) + emu_file m_playback_file; // playback file (closed if not recording) util::write_stream::ptr m_record_stream; // recording stream (nullptr if not recording) util::read_stream::ptr m_playback_stream; // playback stream (nullptr if not recording) u64 m_playback_accumulated_speed; // accumulated speed during playback diff --git a/src/emu/machine.cpp b/src/emu/machine.cpp index db9a1b211c5..d6f29dc0dce 100644 --- a/src/emu/machine.cpp +++ b/src/emu/machine.cpp @@ -20,7 +20,6 @@ #include "debug/debugvw.h" #include "debug/debugcpu.h" #include "dirtc.h" -#include "fileio.h" #include "image.h" #include "network.h" #include "romload.h" @@ -591,10 +590,10 @@ void running_machine::schedule_save(std::string &&filename) // immediate_save - save state. //------------------------------------------------- -void running_machine::immediate_save(std::string_view filename) +void running_machine::immediate_save(const char *filename) { // specify the filename to save or load - set_saveload_filename(std::string(filename)); + set_saveload_filename(filename); // set up some parameters for handle_saveload() m_saveload_schedule = saveload_schedule::SAVE; @@ -628,10 +627,10 @@ void running_machine::schedule_load(std::string &&filename) // immediate_load - load state. //------------------------------------------------- -void running_machine::immediate_load(std::string_view filename) +void running_machine::immediate_load(const char *filename) { // specify the filename to save or load - set_saveload_filename(std::string(filename)); + set_saveload_filename(filename); // set up some parameters for handle_saveload() m_saveload_schedule = saveload_schedule::LOAD; @@ -1133,7 +1132,6 @@ void running_machine::nvram_load() emu_file file(options().nvram_directory(), OPEN_FLAG_READ); if (!file.open(nvram_filename(nvram.device()))) { - // FIXME: don't swallow errors nvram.nvram_load(file); file.close(); } @@ -1156,7 +1154,6 @@ void running_machine::nvram_save() emu_file file(options().nvram_directory(), OPEN_FLAG_WRITE | OPEN_FLAG_CREATE | OPEN_FLAG_CREATE_PATHS); if (!file.open(nvram_filename(nvram.device()))) { - // FIXME: don't swallow errors nvram.nvram_save(file); file.close(); } diff --git a/src/emu/machine.h b/src/emu/machine.h index 4bef86ce3a7..702d79bcd6e 100644 --- a/src/emu/machine.h +++ b/src/emu/machine.h @@ -177,8 +177,8 @@ public: void export_http_api(); // TODO: Do saves and loads still require scheduling? - void immediate_save(std::string_view filename); - void immediate_load(std::string_view filename); + void immediate_save(const char *filename); + void immediate_load(const char *filename); // rewind operations bool rewind_capture(); diff --git a/src/emu/recording.cpp b/src/emu/recording.cpp index 611e5ae327b..9e3c1f3f4ae 100644 --- a/src/emu/recording.cpp +++ b/src/emu/recording.cpp @@ -9,10 +9,7 @@ ***************************************************************************/ #include "emu.h" - -#include "fileio.h" #include "screen.h" - #include "aviio.h" #include "png.h" diff --git a/src/emu/render.cpp b/src/emu/render.cpp index b9a96e81fad..0cd396ac52c 100644 --- a/src/emu/render.cpp +++ b/src/emu/render.cpp @@ -41,7 +41,6 @@ #include "corestr.h" #include "emuopts.h" -#include "fileio.h" #include "rendfont.h" #include "rendlay.h" #include "rendutil.h" diff --git a/src/emu/rendfont.cpp b/src/emu/rendfont.cpp index 3d79f0e6ac2..9984bf9497b 100644 --- a/src/emu/rendfont.cpp +++ b/src/emu/rendfont.cpp @@ -10,10 +10,7 @@ #include "emu.h" #include "rendfont.h" - #include "emuopts.h" -#include "fileio.h" - #include "corestr.h" #include "coreutil.h" diff --git a/src/emu/rendlay.cpp b/src/emu/rendlay.cpp index 88cc161e22f..28011b8372c 100644 --- a/src/emu/rendlay.cpp +++ b/src/emu/rendlay.cpp @@ -13,7 +13,6 @@ #include "rendlay.h" #include "emuopts.h" -#include "fileio.h" #include "rendfont.h" #include "rendutil.h" #include "video/rgbutil.h" diff --git a/src/emu/romload.cpp b/src/emu/romload.cpp index 1ab26947946..73bbd5b62c9 100644 --- a/src/emu/romload.cpp +++ b/src/emu/romload.cpp @@ -11,14 +11,12 @@ #include "emu.h" #include "romload.h" -#include "drivenum.h" +#include "corestr.h" #include "emuopts.h" -#include "fileio.h" +#include "drivenum.h" #include "softlist_dev.h" #include "ui/uimain.h" -#include "corestr.h" - #include <algorithm> #include <set> diff --git a/src/emu/save.cpp b/src/emu/save.cpp index b8acfa24b0a..a27a98ee23c 100644 --- a/src/emu/save.cpp +++ b/src/emu/save.cpp @@ -208,7 +208,7 @@ void save_manager::save_memory(device_t *device, const char *module, const char // state //------------------------------------------------- -save_error save_manager::check_file(running_machine &machine, util::core_file &file, const char *gamename, void (CLIB_DECL *errormsg)(const char *fmt, ...)) +save_error save_manager::check_file(running_machine &machine, emu_file &file, const char *gamename, void (CLIB_DECL *errormsg)(const char *fmt, ...)) { // if we want to validate the signature, compute it u32 sig; @@ -217,8 +217,7 @@ save_error save_manager::check_file(running_machine &machine, util::core_file &f // seek to the beginning and read the header file.seek(0, SEEK_SET); u8 header[HEADER_SIZE]; - size_t actual(0); - if (file.read(header, sizeof(header), actual) || actual != sizeof(header)) + if (file.read(header, sizeof(header)) != sizeof(header)) { if (errormsg != nullptr) (*errormsg)("Could not read %s save file header",emulator_info::get_appname()); @@ -258,7 +257,7 @@ void save_manager::dispatch_presave() // write_file - writes the data to a file //------------------------------------------------- -save_error save_manager::write_file(util::core_file &file) +save_error save_manager::write_file(emu_file &file) { util::write_stream::ptr writer; save_error err = do_write( @@ -291,7 +290,7 @@ save_error save_manager::write_file(util::core_file &file) // read_file - read the data from a file //------------------------------------------------- -save_error save_manager::read_file(util::core_file &file) +save_error save_manager::read_file(emu_file &file) { util::read_stream::ptr reader; return do_read( diff --git a/src/emu/save.h b/src/emu/save.h index 677f127853a..2ea17ab9921 100644 --- a/src/emu/save.h +++ b/src/emu/save.h @@ -300,9 +300,9 @@ public: { save_pointer(nullptr, "global", nullptr, index, std::forward<ItemType>(value), element, valname, count); } // file processing - static save_error check_file(running_machine &machine, util::core_file &file, const char *gamename, void (CLIB_DECL *errormsg)(const char *fmt, ...)); - save_error write_file(util::core_file &file); - save_error read_file(util::core_file &file); + static save_error check_file(running_machine &machine, emu_file &file, const char *gamename, void (CLIB_DECL *errormsg)(const char *fmt, ...)); + save_error write_file(emu_file &file); + save_error read_file(emu_file &file); save_error write_stream(std::ostream &str); save_error read_stream(std::istream &str); diff --git a/src/emu/screen.cpp b/src/emu/screen.cpp index 4925874251f..82a4d3c70d2 100644 --- a/src/emu/screen.cpp +++ b/src/emu/screen.cpp @@ -12,7 +12,6 @@ #include "screen.h" #include "emuopts.h" -#include "fileio.h" #include "render.h" #include "rendutil.h" diff --git a/src/emu/softlist_dev.cpp b/src/emu/softlist_dev.cpp index c6a32f0b30f..7d25dd17013 100644 --- a/src/emu/softlist_dev.cpp +++ b/src/emu/softlist_dev.cpp @@ -13,7 +13,6 @@ #include "diimage.h" #include "emuopts.h" -#include "fileio.h" #include "romload.h" #include "validity.h" diff --git a/src/emu/video.cpp b/src/emu/video.cpp index 6a6c75477aa..5d3691c08c9 100644 --- a/src/emu/video.cpp +++ b/src/emu/video.cpp @@ -11,7 +11,6 @@ #include "emu.h" #include "emuopts.h" #include "debugger.h" -#include "fileio.h" #include "ui/uimain.h" #include "crsshair.h" #include "rendersw.hxx" @@ -319,7 +318,7 @@ std::string video_manager::speed_text() // file handle //------------------------------------------------- -void video_manager::save_snapshot(screen_device *screen, util::core_file &file) +void video_manager::save_snapshot(screen_device *screen, emu_file &file) { // validate assert(!m_snap_native || screen != nullptr); diff --git a/src/emu/video.h b/src/emu/video.h index eb77d0d4ddb..edb00e4f00a 100644 --- a/src/emu/video.h +++ b/src/emu/video.h @@ -79,7 +79,7 @@ public: // snapshots bool snap_native() const { return m_snap_native; } render_target &snapshot_target() { return *m_snap_target; } - void save_snapshot(screen_device *screen, util::core_file &file); + void save_snapshot(screen_device *screen, emu_file &file); void save_active_screen_snapshots(); // movies diff --git a/src/frontend/mame/audit.cpp b/src/frontend/mame/audit.cpp index 7d7a2088b01..6f1d52f2f0f 100644 --- a/src/frontend/mame/audit.cpp +++ b/src/frontend/mame/audit.cpp @@ -15,7 +15,6 @@ #include "emuopts.h" #include "drivenum.h" -#include "fileio.h" #include "romload.h" #include "softlist_dev.h" diff --git a/src/frontend/mame/cheat.cpp b/src/frontend/mame/cheat.cpp index d5221a71213..c16316e8d02 100644 --- a/src/frontend/mame/cheat.cpp +++ b/src/frontend/mame/cheat.cpp @@ -81,7 +81,6 @@ #include "corestr.h" #include "emuopts.h" -#include "fileio.h" #include <cstring> #include <iterator> diff --git a/src/frontend/mame/clifront.cpp b/src/frontend/mame/clifront.cpp index a7779183894..08c8dbf366e 100644 --- a/src/frontend/mame/clifront.cpp +++ b/src/frontend/mame/clifront.cpp @@ -23,7 +23,6 @@ #include "pluginopts.h" #include "emuopts.h" -#include "fileio.h" #include "romload.h" #include "softlist_dev.h" #include "validity.h" diff --git a/src/frontend/mame/language.cpp b/src/frontend/mame/language.cpp index 635ed5817d3..0525aab56c2 100644 --- a/src/frontend/mame/language.cpp +++ b/src/frontend/mame/language.cpp @@ -12,7 +12,6 @@ #include "language.h" #include "emuopts.h" -#include "fileio.h" #include "corestr.h" diff --git a/src/frontend/mame/luaengine.cpp b/src/frontend/mame/luaengine.cpp index b6fc0014a4c..831f445faa5 100644 --- a/src/frontend/mame/luaengine.cpp +++ b/src/frontend/mame/luaengine.cpp @@ -21,7 +21,6 @@ #include "debugger.h" #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "inputdev.h" #include "natkeyboard.h" #include "screen.h" diff --git a/src/frontend/mame/mame.cpp b/src/frontend/mame/mame.cpp index b0e2ca2ddfa..4cff9226aa0 100644 --- a/src/frontend/mame/mame.cpp +++ b/src/frontend/mame/mame.cpp @@ -19,7 +19,6 @@ #include "cheat.h" #include "clifront.h" #include "emuopts.h" -#include "fileio.h" #include "luaengine.h" #include "mameopts.h" #include "pluginopts.h" diff --git a/src/frontend/mame/mameopts.cpp b/src/frontend/mame/mameopts.cpp index bbdf8a692b4..a1d370ddb74 100644 --- a/src/frontend/mame/mameopts.cpp +++ b/src/frontend/mame/mameopts.cpp @@ -12,7 +12,6 @@ #include "mameopts.h" #include "drivenum.h" -#include "fileio.h" #include "screen.h" #include "softlist_dev.h" #include "zippath.h" diff --git a/src/frontend/mame/ui/auditmenu.cpp b/src/frontend/mame/ui/auditmenu.cpp index 651464cfdab..a5cb46fc4d8 100644 --- a/src/frontend/mame/ui/auditmenu.cpp +++ b/src/frontend/mame/ui/auditmenu.cpp @@ -17,7 +17,6 @@ #include "audit.h" #include "drivenum.h" -#include "fileio.h" #include "uiinput.h" #include "util/corestr.h" diff --git a/src/frontend/mame/ui/custui.cpp b/src/frontend/mame/ui/custui.cpp index 9359bc5d4a8..02da9310207 100644 --- a/src/frontend/mame/ui/custui.cpp +++ b/src/frontend/mame/ui/custui.cpp @@ -17,7 +17,6 @@ #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "uiinput.h" #include "corestr.h" diff --git a/src/frontend/mame/ui/dirmenu.cpp b/src/frontend/mame/ui/dirmenu.cpp index 32916d6e8f0..d37217afd9d 100644 --- a/src/frontend/mame/ui/dirmenu.cpp +++ b/src/frontend/mame/ui/dirmenu.cpp @@ -16,7 +16,6 @@ #include "ui/optsmenu.h" #include "emuopts.h" -#include "fileio.h" #include "mame.h" #include "util/corestr.h" diff --git a/src/frontend/mame/ui/inifile.cpp b/src/frontend/mame/ui/inifile.cpp index 9dab127b383..fe8f11236de 100644 --- a/src/frontend/mame/ui/inifile.cpp +++ b/src/frontend/mame/ui/inifile.cpp @@ -16,7 +16,6 @@ #include "language.h" #include "drivenum.h" -#include "fileio.h" #include "softlist_dev.h" #include "corestr.h" diff --git a/src/frontend/mame/ui/menu.cpp b/src/frontend/mame/ui/menu.cpp index c69b792e1c0..1b8290f77f5 100644 --- a/src/frontend/mame/ui/menu.cpp +++ b/src/frontend/mame/ui/menu.cpp @@ -21,7 +21,6 @@ #include "corestr.h" #include "drivenum.h" -#include "fileio.h" #include "rendutil.h" #include "uiinput.h" diff --git a/src/frontend/mame/ui/miscmenu.cpp b/src/frontend/mame/ui/miscmenu.cpp index aef5a60a7c3..0d052562fa0 100644 --- a/src/frontend/mame/ui/miscmenu.cpp +++ b/src/frontend/mame/ui/miscmenu.cpp @@ -24,7 +24,6 @@ #include "mameopts.h" #include "pluginopts.h" #include "drivenum.h" -#include "fileio.h" #include "romload.h" #include "uiinput.h" diff --git a/src/frontend/mame/ui/optsmenu.cpp b/src/frontend/mame/ui/optsmenu.cpp index bafbe9d2af0..d21f069f6f7 100644 --- a/src/frontend/mame/ui/optsmenu.cpp +++ b/src/frontend/mame/ui/optsmenu.cpp @@ -22,8 +22,6 @@ #include "mame.h" #include "mameopts.h" - -#include "fileio.h" #include "rendfont.h" diff --git a/src/frontend/mame/ui/selgame.cpp b/src/frontend/mame/ui/selgame.cpp index abda7047971..77fcefd208e 100644 --- a/src/frontend/mame/ui/selgame.cpp +++ b/src/frontend/mame/ui/selgame.cpp @@ -28,7 +28,6 @@ #include "corestr.h" #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "rendutil.h" #include "romload.h" #include "softlist_dev.h" diff --git a/src/frontend/mame/ui/selmenu.cpp b/src/frontend/mame/ui/selmenu.cpp index 85efff4b8cd..3c16f83f112 100644 --- a/src/frontend/mame/ui/selmenu.cpp +++ b/src/frontend/mame/ui/selmenu.cpp @@ -27,7 +27,6 @@ #include "corestr.h" #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "rendfont.h" #include "rendutil.h" #include "romload.h" diff --git a/src/frontend/mame/ui/selsoft.cpp b/src/frontend/mame/ui/selsoft.cpp index dc3904f2169..c5c32303e93 100644 --- a/src/frontend/mame/ui/selsoft.cpp +++ b/src/frontend/mame/ui/selsoft.cpp @@ -19,7 +19,6 @@ #include "corestr.h" #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "mame.h" #include "rendutil.h" #include "softlist_dev.h" diff --git a/src/frontend/mame/ui/simpleselgame.cpp b/src/frontend/mame/ui/simpleselgame.cpp index 3a230e88a89..7cb346ee397 100644 --- a/src/frontend/mame/ui/simpleselgame.cpp +++ b/src/frontend/mame/ui/simpleselgame.cpp @@ -20,7 +20,6 @@ #include "audit.h" #include "drivenum.h" #include "emuopts.h" -#include "fileio.h" #include "mame.h" #include "uiinput.h" diff --git a/src/frontend/mame/ui/systemlist.cpp b/src/frontend/mame/ui/systemlist.cpp index 5038c7e9783..a05ebeecc12 100644 --- a/src/frontend/mame/ui/systemlist.cpp +++ b/src/frontend/mame/ui/systemlist.cpp @@ -14,7 +14,6 @@ #include "ui/moptions.h" #include "drivenum.h" -#include "fileio.h" #include "util/corestr.h" #include "util/unicode.h" diff --git a/src/frontend/mame/ui/ui.cpp b/src/frontend/mame/ui/ui.cpp index b3d02b3bd98..0ca570337a7 100644 --- a/src/frontend/mame/ui/ui.cpp +++ b/src/frontend/mame/ui/ui.cpp @@ -33,7 +33,6 @@ #include "emuopts.h" #include "mameopts.h" #include "drivenum.h" -#include "fileio.h" #include "natkeyboard.h" #include "render.h" #include "cheat.h" diff --git a/src/mame/drivers/ldplayer.cpp b/src/mame/drivers/ldplayer.cpp index a8150b2d7cc..9c60fe06453 100644 --- a/src/mame/drivers/ldplayer.cpp +++ b/src/mame/drivers/ldplayer.cpp @@ -17,7 +17,6 @@ #include "ui/uimain.h" #include "emuopts.h" -#include "fileio.h" #include "romload.h" #include "speaker.h" #include "screen.h" diff --git a/src/mame/drivers/ngp.cpp b/src/mame/drivers/ngp.cpp index e4a57483617..412fd75a81b 100644 --- a/src/mame/drivers/ngp.cpp +++ b/src/mame/drivers/ngp.cpp @@ -105,7 +105,6 @@ the Neogeo Pocket. #include "sound/t6w28.h" #include "sound/dac.h" #include "video/k1ge.h" -#include "fileio.h" #include "screen.h" #include "softlist_dev.h" #include "speaker.h" diff --git a/src/mame/machine/cuda.cpp b/src/mame/machine/cuda.cpp index 4442c6f9287..83f8f126494 100644 --- a/src/mame/machine/cuda.cpp +++ b/src/mame/machine/cuda.cpp @@ -43,8 +43,6 @@ #include "cpu/m6805/m6805.h" #include "sound/asc.h" -#include "fileio.h" - //************************************************************************** // MACROS / CONSTANTS //************************************************************************** diff --git a/src/mame/machine/docg3.cpp b/src/mame/machine/docg3.cpp index e9210144b31..13e7fcee3a5 100644 --- a/src/mame/machine/docg3.cpp +++ b/src/mame/machine/docg3.cpp @@ -11,8 +11,6 @@ #include "emu.h" #include "machine/docg3.h" -#include "fileio.h" - #define VERBOSE_LEVEL ( 0 ) static inline void ATTR_PRINTF(3,4) verboselog( device_t &device, int n_level, const char *s_fmt, ... ) diff --git a/src/mame/machine/egret.cpp b/src/mame/machine/egret.cpp index fa3d641545e..f62c8484821 100644 --- a/src/mame/machine/egret.cpp +++ b/src/mame/machine/egret.cpp @@ -42,8 +42,6 @@ #include "cpu/m6805/m6805.h" #include "sound/asc.h" -#include "fileio.h" - //************************************************************************** // MACROS / CONSTANTS //************************************************************************** diff --git a/src/mame/machine/kr1601rr1.cpp b/src/mame/machine/kr1601rr1.cpp index 836fd981813..30da9ff9534 100644 --- a/src/mame/machine/kr1601rr1.cpp +++ b/src/mame/machine/kr1601rr1.cpp @@ -13,9 +13,8 @@ ***************************************************************************/ #include "emu.h" -#include "kr1601rr1.h" -#include "fileio.h" +#include "kr1601rr1.h" #include <algorithm> diff --git a/src/mame/machine/m3comm.h b/src/mame/machine/m3comm.h index e0dfdb074c0..529c0bec578 100644 --- a/src/mame/machine/m3comm.h +++ b/src/mame/machine/m3comm.h @@ -8,8 +8,6 @@ #include "machine/ram.h" #include "cpu/m68000/m68000.h" -#include "fileio.h" - //************************************************************************** // TYPE DEFINITIONS diff --git a/src/mame/machine/macrtc.cpp b/src/mame/machine/macrtc.cpp index fcd64f34604..19e0909c8d5 100644 --- a/src/mame/machine/macrtc.cpp +++ b/src/mame/machine/macrtc.cpp @@ -14,8 +14,6 @@ #include "emu.h" #include "macrtc.h" -#include "fileio.h" - #ifdef MAME_DEBUG #define LOG_RTC 0 #else diff --git a/src/mame/machine/midwayic.cpp b/src/mame/machine/midwayic.cpp index 8f6ed497403..9db6471d4d3 100644 --- a/src/mame/machine/midwayic.cpp +++ b/src/mame/machine/midwayic.cpp @@ -7,10 +7,9 @@ ***************************************************************************/ #include "emu.h" +#include "debugger.h" #include "midwayic.h" -#include "fileio.h" - #define LOG_NVRAM (0) diff --git a/src/mame/machine/msx_matsushita.cpp b/src/mame/machine/msx_matsushita.cpp index 10e989419c6..169fd809458 100644 --- a/src/mame/machine/msx_matsushita.cpp +++ b/src/mame/machine/msx_matsushita.cpp @@ -3,8 +3,6 @@ #include "emu.h" #include "msx_matsushita.h" -#include "fileio.h" - const uint8_t manufacturer_id = 0x08; DEFINE_DEVICE_TYPE(MSX_MATSUSHITA, msx_matsushita_device, "msx_matsushita", "Matsushita switched device") diff --git a/src/mame/machine/msx_s1985.cpp b/src/mame/machine/msx_s1985.cpp index fbe6ccafb8a..5e562e5cbbf 100644 --- a/src/mame/machine/msx_s1985.cpp +++ b/src/mame/machine/msx_s1985.cpp @@ -3,8 +3,6 @@ #include "emu.h" #include "msx_s1985.h" -#include "fileio.h" - const uint8_t manufacturer_id = 0xfe; DEFINE_DEVICE_TYPE(MSX_S1985, msx_s1985_device, "msx_s1985", "MSX-Engine S1985") diff --git a/src/mame/machine/pc9801_memsw.cpp b/src/mame/machine/pc9801_memsw.cpp index e636eebc841..93392aefc0f 100644 --- a/src/mame/machine/pc9801_memsw.cpp +++ b/src/mame/machine/pc9801_memsw.cpp @@ -78,9 +78,7 @@ #include "emu.h" #include "pc9801_memsw.h" - #include "coreutil.h" -#include "fileio.h" //************************************************************************** // GLOBAL VARIABLES diff --git a/src/mame/machine/tosh1000_bram.cpp b/src/mame/machine/tosh1000_bram.cpp index 401467c078e..391539472b6 100644 --- a/src/mame/machine/tosh1000_bram.cpp +++ b/src/mame/machine/tosh1000_bram.cpp @@ -11,8 +11,6 @@ #include "emu.h" #include "tosh1000_bram.h" -#include "fileio.h" - #include <algorithm> diff --git a/src/mame/machine/zs01.cpp b/src/mame/machine/zs01.cpp index eb93c5c6ead..c5e4606ec91 100644 --- a/src/mame/machine/zs01.cpp +++ b/src/mame/machine/zs01.cpp @@ -14,8 +14,6 @@ #include "emu.h" #include "machine/zs01.h" -#include "fileio.h" - #define VERBOSE_LEVEL ( 0 ) inline void ATTR_PRINTF( 3, 4 ) zs01_device::verboselog( int n_level, const char *s_fmt, ... ) diff --git a/src/mame/video/midtunit.cpp b/src/mame/video/midtunit.cpp index 5d045ed616c..506697640a7 100644 --- a/src/mame/video/midtunit.cpp +++ b/src/mame/video/midtunit.cpp @@ -18,7 +18,6 @@ #include "debugger.h" #include "emuopts.h" // Used by PNG logging -#include "fileio.h" // Used by PNG logging #include "png.h" // Used by PNG logging //#include <rapidjson/prettywriter.h> // Used by JSON logging diff --git a/src/osd/modules/debugger/debuggdbstub.cpp b/src/osd/modules/debugger/debuggdbstub.cpp index 5e477200dc2..9f26fb2c778 100644 --- a/src/osd/modules/debugger/debuggdbstub.cpp +++ b/src/osd/modules/debugger/debuggdbstub.cpp @@ -13,7 +13,6 @@ #include "debug/textbuf.h" #include "debug_module.h" #include "debugger.h" -#include "fileio.h" #include "modules/lib/osdobj_common.h" #include "modules/osdmodule.h" diff --git a/src/osd/modules/render/aviwrite.cpp b/src/osd/modules/render/aviwrite.cpp index 9148244111b..ec6ce21c543 100644 --- a/src/osd/modules/render/aviwrite.cpp +++ b/src/osd/modules/render/aviwrite.cpp @@ -10,7 +10,6 @@ #include "aviwrite.h" #include "modules/lib/osdobj_common.h" -#include "fileio.h" #include "screen.h" diff --git a/src/osd/modules/render/bgfx/chainentryreader.cpp b/src/osd/modules/render/bgfx/chainentryreader.cpp index c179992c6b0..ba3ae1c9e67 100644 --- a/src/osd/modules/render/bgfx/chainentryreader.cpp +++ b/src/osd/modules/render/bgfx/chainentryreader.cpp @@ -9,7 +9,6 @@ #include <string> #include "emu.h" -#include "fileio.h" #include "rendutil.h" #include <modules/render/copyutil.h> diff --git a/src/osd/modules/render/bgfx/texturemanager.cpp b/src/osd/modules/render/bgfx/texturemanager.cpp index a61d77c9177..1fe6fe13b60 100644 --- a/src/osd/modules/render/bgfx/texturemanager.cpp +++ b/src/osd/modules/render/bgfx/texturemanager.cpp @@ -14,7 +14,6 @@ #include "texturemanager.h" #include "texture.h" #include "bgfxutil.h" -#include "fileio.h" #include "rendutil.h" #include "modules/render/copyutil.h" diff --git a/src/osd/modules/render/d3d/d3dhlsl.cpp b/src/osd/modules/render/d3d/d3dhlsl.cpp index 599da82c8d3..eabcd5bcb81 100644 --- a/src/osd/modules/render/d3d/d3dhlsl.cpp +++ b/src/osd/modules/render/d3d/d3dhlsl.cpp @@ -13,7 +13,6 @@ #include "rendlay.h" #include "rendutil.h" #include "emuopts.h" -#include "fileio.h" #include "aviio.h" #include "png.h" #include "screen.h" |