Move the VFS stuff into its own library.

This commit is contained in:
David Given
2024-10-01 21:06:14 +02:00
parent 12f999e9e4
commit c55032531c
5 changed files with 35 additions and 23 deletions

View File

@@ -91,25 +91,6 @@ cxxlibrary(
"./lib/usb/serial.cc",
"./lib/usb/usb.cc",
"./lib/usb/usbfinder.cc",
"./lib/vfs/acorndfs.cc",
"./lib/vfs/amigaffs.cc",
"./lib/vfs/appledos.cc",
"./lib/vfs/applesingle.cc",
"./lib/vfs/brother120fs.cc",
"./lib/vfs/cbmfs.cc",
"./lib/vfs/cpmfs.cc",
"./lib/vfs/fatfs.cc",
"./lib/vfs/fluxsectorinterface.cc",
"./lib/vfs/imagesectorinterface.cc",
"./lib/vfs/lif.cc",
"./lib/vfs/machfs.cc",
"./lib/vfs/microdos.cc",
"./lib/vfs/philefs.cc",
"./lib/vfs/prodos.cc",
"./lib/vfs/roland.cc",
"./lib/vfs/smaky6fs.cc",
"./lib/vfs/vfs.cc",
"./lib/vfs/zdos.cc",
"./arch/aeslanier/decoder.cc",
"./arch/agat/agat.cc",
"./arch/agat/decoder.cc",
@@ -202,9 +183,6 @@ cxxlibrary(
"lib/usb/greaseweazle.h": "./lib/usb/greaseweazle.h",
"lib/usb/usb.h": "./lib/usb/usb.h",
"lib/usb/usbfinder.h": "./lib/usb/usbfinder.h",
"lib/vfs/applesingle.h": "./lib/vfs/applesingle.h",
"lib/vfs/sectorinterface.h": "./lib/vfs/sectorinterface.h",
"lib/vfs/vfs.h": "./lib/vfs/vfs.h",
},
deps=[
"+fl2_proto_lib",

31
lib/vfs/build.py Normal file
View File

@@ -0,0 +1,31 @@
from build.c import cxxlibrary
cxxlibrary(
name="vfs",
srcs=[
"./acorndfs.cc",
"./amigaffs.cc",
"./appledos.cc",
"./applesingle.cc",
"./brother120fs.cc",
"./cbmfs.cc",
"./cpmfs.cc",
"./fatfs.cc",
"./fluxsectorinterface.cc",
"./imagesectorinterface.cc",
"./lif.cc",
"./machfs.cc",
"./microdos.cc",
"./philefs.cc",
"./prodos.cc",
"./roland.cc",
"./smaky6fs.cc",
"./vfs.cc",
"./zdos.cc",
],
hdrs={
"lib/vfs/applesingle.h": "./applesingle.h",
"lib/vfs/sectorinterface.h": "./sectorinterface.h",
"lib/vfs/vfs.h": "./vfs.h",
},
deps=["+lib"])

View File

@@ -43,6 +43,7 @@ cxxprogram(
"dep/stb",
"+lib",
"lib/core",
"lib/vfs",
"lib+config_proto_lib",
"src/formats",
],

View File

@@ -63,6 +63,7 @@ cxxprogram(
"extras+icons",
"+lib",
"lib/core",
"lib/vfs",
"lib+config_proto_lib",
"src/formats",
"src/gui/drivetypes",

View File

@@ -100,7 +100,8 @@ export(
"lib+config_proto_lib",
"src/formats",
]
+ ([".+test_proto_lib"] if n == "options" else []),
+ ([".+test_proto_lib"] if n == "options" else [])
+ (["lib/vfs"] if n in {"cpmfs", "applesingle", "vfs"} else []),
),
)
for n in tests