diff --git a/arch/agat/agat.proto b/arch/agat/agat.proto index 70c4c321..58377b12 100644 --- a/arch/agat/agat.proto +++ b/arch/agat/agat.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message AgatDecoderProto {} diff --git a/arch/amiga/amiga.proto b/arch/amiga/amiga.proto index 0e84abc3..ee3474dc 100644 --- a/arch/amiga/amiga.proto +++ b/arch/amiga/amiga.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message AmigaDecoderProto {} diff --git a/arch/apple2/apple2.proto b/arch/apple2/apple2.proto index 11fe2023..5a18f837 100644 --- a/arch/apple2/apple2.proto +++ b/arch/apple2/apple2.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message Apple2DecoderProto { optional uint32 side_one_track_offset = 1 diff --git a/arch/build.py b/arch/build.py index 4fa9c2f9..ee4549a5 100644 --- a/arch/build.py +++ b/arch/build.py @@ -24,10 +24,10 @@ "./victor9k/victor9k.proto", "./zilogmcz/zilogmcz.proto", ], - deps=["lib+common_proto"], + deps=["lib/config+common_proto"], ) -protocc(name="proto_lib", srcs=[".+proto"], deps=["lib+common_proto_lib"]) +protocc(name="proto_lib", srcs=[".+proto"], deps=["lib/config+common_proto_lib"]) cxxlibrary( name="arch", diff --git a/arch/c64/c64.proto b/arch/c64/c64.proto index 5e4f7567..641bc182 100644 --- a/arch/c64/c64.proto +++ b/arch/c64/c64.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message Commodore64DecoderProto {} diff --git a/arch/ibm/ibm.proto b/arch/ibm/ibm.proto index d750646c..ee289b34 100644 --- a/arch/ibm/ibm.proto +++ b/arch/ibm/ibm.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message IbmDecoderProto { // Next: 11 diff --git a/arch/macintosh/macintosh.proto b/arch/macintosh/macintosh.proto index 465cfeeb..5ff666a3 100644 --- a/arch/macintosh/macintosh.proto +++ b/arch/macintosh/macintosh.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message MacintoshDecoderProto {} diff --git a/arch/micropolis/micropolis.proto b/arch/micropolis/micropolis.proto index 429c9c05..4c4f3438 100644 --- a/arch/micropolis/micropolis.proto +++ b/arch/micropolis/micropolis.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message MicropolisDecoderProto { enum ChecksumType { diff --git a/arch/northstar/northstar.proto b/arch/northstar/northstar.proto index 1c460408..0693e77d 100644 --- a/arch/northstar/northstar.proto +++ b/arch/northstar/northstar.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message NorthstarDecoderProto {} diff --git a/arch/tartu/tartu.proto b/arch/tartu/tartu.proto index dc906c02..f66b2f27 100644 --- a/arch/tartu/tartu.proto +++ b/arch/tartu/tartu.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message TartuDecoderProto {} diff --git a/arch/tids990/tids990.proto b/arch/tids990/tids990.proto index 0a55a46a..8091e5d7 100644 --- a/arch/tids990/tids990.proto +++ b/arch/tids990/tids990.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message Tids990DecoderProto {} diff --git a/arch/victor9k/victor9k.proto b/arch/victor9k/victor9k.proto index 7a35d638..8d0ea666 100644 --- a/arch/victor9k/victor9k.proto +++ b/arch/victor9k/victor9k.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message Victor9kDecoderProto {} diff --git a/build.py b/build.py index 4d7fcc2c..2c10acfd 100644 --- a/build.py +++ b/build.py @@ -19,36 +19,6 @@ clibrary(name="protocol", hdrs={"protocol.h": "./protocol.h"}) -cxxlibrary( - name="lib", - srcs=[ - "./lib/readerwriter.cc", - ], - hdrs={ - "lib/readerwriter.h": "./lib/readerwriter.h", - }, - deps=[ - "+fmt_lib", - "+protocol", - "dep/adflib", - "dep/fatfs", - "dep/hfsutils", - "dep/libusbp", - "dep/stb", - "src/formats", - "lib/core", - "lib/config", - "lib/data", - "lib/external", - "lib/fluxsink", - "lib/fluxsource", - "lib/imagereader", - "lib/imagewriter", - "lib/decoders", - "lib/encoders", - ], -) - corpustests = [] if not glob("../fluxengine-testdata/data"): print("fluxengine-testdata not found; skipping corpus tests") diff --git a/lib/algorithms/build.py b/lib/algorithms/build.py new file mode 100644 index 00000000..e436aac8 --- /dev/null +++ b/lib/algorithms/build.py @@ -0,0 +1,21 @@ +from build.c import cxxlibrary + +cxxlibrary( + name="algorithms", + srcs=["./readerwriter.cc"], + hdrs={ + "lib/algorithms/readerwriter.h": "./readerwriter.h", + }, + deps=[ + "lib/core", + "lib/config", + "lib/data", + "lib/usb", + "lib/encoders", + "lib/decoders", + "lib/fluxsource", + "lib/fluxsink", + "lib/imagereader", + "lib/imagewriter", + ], +) diff --git a/lib/readerwriter.cc b/lib/algorithms/readerwriter.cc similarity index 99% rename from lib/readerwriter.cc rename to lib/algorithms/readerwriter.cc index fc0bf839..2c8d485a 100644 --- a/lib/readerwriter.cc +++ b/lib/algorithms/readerwriter.cc @@ -2,7 +2,7 @@ #include "lib/config/config.h" #include "lib/config/flags.h" #include "lib/data/fluxmap.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "protocol.h" #include "lib/usb/usb.h" #include "lib/encoders/encoders.h" diff --git a/lib/readerwriter.h b/lib/algorithms/readerwriter.h similarity index 100% rename from lib/readerwriter.h rename to lib/algorithms/readerwriter.h diff --git a/lib/build.py b/lib/build.py deleted file mode 100644 index 0602bd1c..00000000 --- a/lib/build.py +++ /dev/null @@ -1,33 +0,0 @@ -from build.protobuf import proto, protocc - - -proto(name="common_proto", srcs=["./common.proto"]) -protocc( - name="common_proto_lib", srcs=[".+common_proto"], deps=["+protobuf_lib"] -) - -proto( - name="layout_proto", - srcs=["./layout.proto"], - deps=[".+common_proto", "lib/external+fl2_proto"], -) -protocc( - name="layout_proto_lib", - srcs=[".+layout_proto"], - deps=[".+common_proto_lib", "lib/external+fl2_proto_lib"], -) - -proto( - name="drive_proto", - srcs=["./drive.proto"], - deps=[".+common_proto", "lib/external+fl2_proto", ".+layout_proto"], -) -protocc( - name="drive_proto_lib", - srcs=[".+drive_proto"], - deps=[ - ".+common_proto_lib", - "lib/external+fl2_proto_lib", - ".+layout_proto_lib", - ], -) diff --git a/lib/config/build.py b/lib/config/build.py index fe58671a..d1b31695 100644 --- a/lib/config/build.py +++ b/lib/config/build.py @@ -1,22 +1,53 @@ from build.c import cxxlibrary from build.protobuf import proto, protocc +proto(name="common_proto", srcs=["./common.proto"]) +protocc( + name="common_proto_lib", srcs=[".+common_proto"], deps=["+protobuf_lib"] +) + +proto( + name="drive_proto", + srcs=["./drive.proto"], + deps=[".+common_proto", "lib/external+fl2_proto", ".+layout_proto"], +) +protocc( + name="drive_proto_lib", + srcs=[".+drive_proto"], + deps=[ + ".+layout_proto_lib", + ".+common_proto_lib", + "lib/external+fl2_proto_lib", + ], +) + +proto( + name="layout_proto", + srcs=["./layout.proto"], + deps=[".+common_proto", "lib/external+fl2_proto"], +) +protocc( + name="layout_proto_lib", + srcs=[".+layout_proto"], + deps=[".+common_proto_lib", "lib/external+fl2_proto_lib"], +) + proto( name="proto", srcs=["./config.proto"], deps=[ - "lib+common_proto", - "lib+layout_proto", - "lib+drive_proto", + ".+drive_proto", + ".+layout_proto", + ".+common_proto", + "lib/decoders+proto", + "lib/encoders+proto", "lib/external+fl2_proto", - "lib/fluxsource+proto", "lib/fluxsink+proto", - "lib/vfs+proto", - "lib/usb+proto", - "lib/encoders+proto", - "lib/decoders+proto", + "lib/fluxsource+proto", "lib/imagereader+proto", "lib/imagewriter+proto", + "lib/usb+proto", + "lib/vfs+proto", ], ) @@ -24,16 +55,17 @@ name="proto_lib", srcs=[".+proto", "arch+proto"], deps=[ - "lib/fluxsource+proto_lib", - "lib/fluxsink+proto_lib", - "lib/vfs+proto_lib", - "lib/usb+proto_lib", - "lib/encoders+proto_lib", + ".+drive_proto_lib", + ".+common_proto_lib", "lib/decoders+proto_lib", + "lib/encoders+proto_lib", + "lib/external+fl2_proto_lib", + "lib/fluxsink+proto_lib", + "lib/fluxsource+proto_lib", "lib/imagereader+proto_lib", "lib/imagewriter+proto_lib", - "lib/external+fl2_proto_lib", - "lib+drive_proto_lib", + "lib/usb+proto_lib", + "lib/vfs+proto_lib", ], ) diff --git a/lib/common.proto b/lib/config/common.proto similarity index 100% rename from lib/common.proto rename to lib/config/common.proto diff --git a/lib/config/config.h b/lib/config/config.h index 09c975bb..5025347e 100644 --- a/lib/config/config.h +++ b/lib/config/config.h @@ -4,7 +4,7 @@ #include #include "lib/config/config.pb.h" -#include "lib/common.pb.h" +#include "lib/config/common.pb.h" class ConfigProto; class OptionProto; diff --git a/lib/config/config.proto b/lib/config/config.proto index 784f919c..9dc4600e 100644 --- a/lib/config/config.proto +++ b/lib/config/config.proto @@ -8,9 +8,9 @@ import "lib/fluxsource/fluxsource.proto"; import "lib/fluxsink/fluxsink.proto"; import "lib/usb/usb.proto"; import "lib/vfs/vfs.proto"; -import "lib/drive.proto"; -import "lib/common.proto"; -import "lib/layout.proto"; +import "lib/config/drive.proto"; +import "lib/config/common.proto"; +import "lib/config/layout.proto"; enum SupportStatus { diff --git a/lib/drive.proto b/lib/config/drive.proto similarity index 98% rename from lib/drive.proto rename to lib/config/drive.proto index 373400ff..aef3033f 100644 --- a/lib/drive.proto +++ b/lib/config/drive.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; import "lib/external/fl2.proto"; // Next: 15 diff --git a/lib/layout.proto b/lib/config/layout.proto similarity index 98% rename from lib/layout.proto rename to lib/config/layout.proto index 2bf78943..1499809a 100644 --- a/lib/layout.proto +++ b/lib/config/layout.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; import "lib/external/fl2.proto"; message SectorListProto diff --git a/lib/config/proto.cc b/lib/config/proto.cc index 1d258bda..263ecf91 100644 --- a/lib/config/proto.cc +++ b/lib/config/proto.cc @@ -1,6 +1,6 @@ #include "lib/core/globals.h" #include "lib/config/proto.h" -#include "lib/common.pb.h" +#include "lib/config/common.pb.h" #include static ConfigProto config = []() diff --git a/lib/config/proto.h b/lib/config/proto.h index 5809e03b..f2534eba 100644 --- a/lib/config/proto.h +++ b/lib/config/proto.h @@ -2,7 +2,7 @@ #define PROTO_H #include -#include "lib/common.pb.h" +#include "lib/config/common.pb.h" #include "lib/config/config.pb.h" class ProtoPathNotFoundException : public ErrorException diff --git a/lib/decoders/build.py b/lib/decoders/build.py index 4b5fde66..176d1501 100644 --- a/lib/decoders/build.py +++ b/lib/decoders/build.py @@ -4,13 +4,13 @@ proto( name="proto", srcs=["./decoders.proto"], - deps=["lib+common_proto", "arch+proto", "lib/fluxsink+proto"], + deps=["lib/config+common_proto", "arch+proto", "lib/fluxsink+proto"], ) protocc( name="proto_lib", srcs=[".+proto"], - deps=["lib+common_proto_lib", "arch+proto_lib", "lib/fluxsink+proto_lib"], + deps=["lib/config+common_proto_lib", "arch+proto_lib", "lib/fluxsink+proto_lib"], ) cxxlibrary( diff --git a/lib/decoders/decoders.proto b/lib/decoders/decoders.proto index f3103981..df448ec5 100644 --- a/lib/decoders/decoders.proto +++ b/lib/decoders/decoders.proto @@ -20,7 +20,7 @@ import "arch/tids990/tids990.proto"; import "arch/victor9k/victor9k.proto"; import "arch/zilogmcz/zilogmcz.proto"; import "lib/fluxsink/fluxsink.proto"; -import "lib/common.proto"; +import "lib/config/common.proto"; //NEXT: 33 message DecoderProto { diff --git a/lib/encoders/build.py b/lib/encoders/build.py index fe7a8ba4..fe45c05d 100644 --- a/lib/encoders/build.py +++ b/lib/encoders/build.py @@ -4,12 +4,12 @@ proto( name="proto", srcs=["./encoders.proto"], - deps=["lib+common_proto", "arch+proto"], + deps=["lib/config+common_proto", "arch+proto"], ) protocc( name="proto_lib", srcs=[".+proto"], - deps=["lib+common_proto_lib", "arch+proto_lib"], + deps=["lib/config+common_proto_lib", "arch+proto_lib"], ) cxxlibrary( diff --git a/lib/fluxsink/build.py b/lib/fluxsink/build.py index a5b8d375..6f3e480f 100644 --- a/lib/fluxsink/build.py +++ b/lib/fluxsink/build.py @@ -1,8 +1,8 @@ from build.protobuf import proto, protocc from build.c import cxxlibrary -proto(name="proto", srcs=["./fluxsink.proto"], deps=["lib+common_proto"]) -protocc(name="proto_lib", srcs=[".+proto"], deps=["lib+common_proto_lib"]) +proto(name="proto", srcs=["./fluxsink.proto"], deps=["lib/config+common_proto"]) +protocc(name="proto_lib", srcs=[".+proto"], deps=["lib/config+common_proto_lib"]) cxxlibrary( name="fluxsink", diff --git a/lib/fluxsink/fluxsink.proto b/lib/fluxsink/fluxsink.proto index d2a06c55..dd08f658 100644 --- a/lib/fluxsink/fluxsink.proto +++ b/lib/fluxsink/fluxsink.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message HardwareFluxSinkProto {} diff --git a/lib/fluxsource/build.py b/lib/fluxsource/build.py index fa9e660f..ff6641ff 100644 --- a/lib/fluxsource/build.py +++ b/lib/fluxsource/build.py @@ -1,12 +1,12 @@ from build.protobuf import proto, protocc from build.c import cxxlibrary -proto(name="proto", srcs=["./fluxsource.proto"], deps=["lib+common_proto"]) +proto(name="proto", srcs=["./fluxsource.proto"], deps=["lib/config+common_proto"]) protocc( name="proto_lib", srcs=[".+proto"], - deps=["lib+common_proto", "lib+common_proto_lib"], + deps=["lib/config+common_proto", "lib/config+common_proto_lib"], ) cxxlibrary( diff --git a/lib/fluxsource/fluxsource.proto b/lib/fluxsource/fluxsource.proto index ab62bb65..fa377049 100644 --- a/lib/fluxsource/fluxsource.proto +++ b/lib/fluxsource/fluxsource.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message HardwareFluxSourceProto {} diff --git a/lib/imagereader/build.py b/lib/imagereader/build.py index ce265703..0a9b8d40 100644 --- a/lib/imagereader/build.py +++ b/lib/imagereader/build.py @@ -4,12 +4,12 @@ proto( name="proto", srcs=["./imagereader.proto"], - deps=["lib+common_proto"], + deps=["lib/config+common_proto"], ) protocc( name="proto_lib", srcs=[".+proto"], - deps=["lib+common_proto_lib"], + deps=["lib/config+common_proto_lib"], ) cxxlibrary( diff --git a/lib/imagereader/imagereader.proto b/lib/imagereader/imagereader.proto index 403d685f..6feaad47 100644 --- a/lib/imagereader/imagereader.proto +++ b/lib/imagereader/imagereader.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message ImgInputOutputProto {} diff --git a/lib/imagereader/imgimagereader.cc b/lib/imagereader/imgimagereader.cc index ac76e220..42e747b2 100644 --- a/lib/imagereader/imgimagereader.cc +++ b/lib/imagereader/imgimagereader.cc @@ -6,7 +6,7 @@ #include "lib/data/image.h" #include "lib/core/logger.h" #include "lib/config/config.pb.h" -#include "lib/layout.pb.h" +#include "lib/config/layout.pb.h" #include "lib/config/proto.h" #include "lib/data/layout.h" #include diff --git a/lib/imagewriter/build.py b/lib/imagewriter/build.py index 3adf3292..5ace8081 100644 --- a/lib/imagewriter/build.py +++ b/lib/imagewriter/build.py @@ -4,12 +4,12 @@ proto( name="proto", srcs=["./imagewriter.proto"], - deps=["lib+common_proto", "lib/imagereader+proto"], + deps=["lib/config+common_proto", "lib/imagereader+proto"], ) protocc( name="proto_lib", srcs=[".+proto"], - deps=["lib+common_proto_lib", "lib/imagereader+proto_lib"], + deps=["lib/config+common_proto_lib", "lib/imagereader+proto_lib"], ) cxxlibrary( diff --git a/lib/imagewriter/imagewriter.proto b/lib/imagewriter/imagewriter.proto index 74a42ae0..c2b42daf 100644 --- a/lib/imagewriter/imagewriter.proto +++ b/lib/imagewriter/imagewriter.proto @@ -1,7 +1,7 @@ syntax = "proto2"; import "lib/imagereader/imagereader.proto"; -import "lib/common.proto"; +import "lib/config/common.proto"; message D64OutputProto {} diff --git a/lib/imagewriter/imgimagewriter.cc b/lib/imagewriter/imgimagewriter.cc index 7cf05ac2..631059fd 100644 --- a/lib/imagewriter/imgimagewriter.cc +++ b/lib/imagewriter/imgimagewriter.cc @@ -7,7 +7,7 @@ #include "lib/config/proto.h" #include "lib/config/config.pb.h" #include "lib/data/layout.h" -#include "lib/layout.pb.h" +#include "lib/config/layout.pb.h" #include "lib/core/logger.h" #include #include diff --git a/lib/usb/build.py b/lib/usb/build.py index accb2803..070bee09 100644 --- a/lib/usb/build.py +++ b/lib/usb/build.py @@ -1,8 +1,8 @@ from build.protobuf import proto, protocc from build.c import cxxlibrary -proto(name="proto", srcs=["./usb.proto"], deps=["lib+common_proto"]) -protocc(name="proto_lib", srcs=[".+proto"], deps=["lib+common_proto_lib"]) +proto(name="proto", srcs=["./usb.proto"], deps=["lib/config+common_proto"]) +protocc(name="proto_lib", srcs=[".+proto"], deps=["lib/config+common_proto_lib"]) cxxlibrary( name="usb", diff --git a/lib/usb/usb.proto b/lib/usb/usb.proto index 14f865fc..1826341b 100644 --- a/lib/usb/usb.proto +++ b/lib/usb/usb.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message GreaseweazleProto { enum BusType { /* note that these must match CMD_SET_BUS codes */ diff --git a/lib/vfs/build.py b/lib/vfs/build.py index 4398869e..ee3b9430 100644 --- a/lib/vfs/build.py +++ b/lib/vfs/build.py @@ -4,15 +4,15 @@ proto( name="proto", srcs=["./vfs.proto"], - deps=["lib+common_proto", "lib+layout_proto", "lib/external+fl2_proto"], + deps=["lib/config+common_proto", "lib/config+layout_proto", "lib/external+fl2_proto"], ) protocc( name="proto_lib", srcs=[".+proto"], deps=[ - "lib+common_proto_lib", - "lib+layout_proto_lib", + "lib/config+common_proto_lib", + "lib/config+layout_proto_lib", "lib/external+fl2_proto_lib", ], ) @@ -46,9 +46,12 @@ "lib/vfs/vfs.h": "./vfs.h", }, deps=[ - "+lib", "+fmt_lib", "arch", + "lib/algorithms", ".+proto_lib", + "dep/hfsutils", + "dep/adflib", + "dep/fatfs", ], ) diff --git a/lib/vfs/fluxsectorinterface.cc b/lib/vfs/fluxsectorinterface.cc index c3f5ea58..c14584a1 100644 --- a/lib/vfs/fluxsectorinterface.cc +++ b/lib/vfs/fluxsectorinterface.cc @@ -1,7 +1,7 @@ #include "lib/core/globals.h" #include "lib/vfs/sectorinterface.h" #include "lib/data/image.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "lib/decoders/decoders.h" #include "lib/fluxsource/fluxsource.h" #include "lib/data/layout.h" diff --git a/lib/vfs/vfs.cc b/lib/vfs/vfs.cc index 25189f6b..50340539 100644 --- a/lib/vfs/vfs.cc +++ b/lib/vfs/vfs.cc @@ -2,7 +2,7 @@ #include "lib/config/config.h" #include "vfs.h" #include "lib/config/proto.h" -#include "lib/layout.pb.h" +#include "lib/config/layout.pb.h" #include "lib/data/layout.h" #include "lib/data/image.h" #include "lib/data/sector.h" diff --git a/lib/vfs/vfs.proto b/lib/vfs/vfs.proto index 6ba11004..24acb7f9 100644 --- a/lib/vfs/vfs.proto +++ b/lib/vfs/vfs.proto @@ -1,7 +1,7 @@ syntax = "proto2"; -import "lib/common.proto"; -import "lib/layout.proto"; +import "lib/config/common.proto"; +import "lib/config/layout.proto"; message AcornDfsProto { diff --git a/src/build.py b/src/build.py index 2d29420f..68bd0362 100644 --- a/src/build.py +++ b/src/build.py @@ -31,7 +31,6 @@ cflags=["-I."], deps=[ "+fmt_lib", - "+lib", "+protobuf_lib", "+protocol", "+z_lib", @@ -46,6 +45,7 @@ "lib/data", "lib/external", "lib/vfs", + "lib/algorithms", "arch", "src/formats", ], diff --git a/src/fe-putfile.cc b/src/fe-putfile.cc index 704663bc..874e19b0 100644 --- a/src/fe-putfile.cc +++ b/src/fe-putfile.cc @@ -3,7 +3,7 @@ #include "lib/data/fluxmap.h" #include "lib/data/sector.h" #include "lib/config/proto.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "lib/imagereader/imagereader.h" #include "lib/imagewriter/imagewriter.h" #include "lib/fluxsource/fluxsource.h" diff --git a/src/fe-rawread.cc b/src/fe-rawread.cc index d4e14b44..07c8c56a 100644 --- a/src/fe-rawread.cc +++ b/src/fe-rawread.cc @@ -1,7 +1,7 @@ #include "lib/core/globals.h" #include "lib/config/config.h" #include "lib/config/flags.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "lib/data/fluxmap.h" #include "lib/decoders/decoders.h" #include "lib/data/sector.h" diff --git a/src/fe-rawwrite.cc b/src/fe-rawwrite.cc index 9c8ea290..c0fef3e9 100644 --- a/src/fe-rawwrite.cc +++ b/src/fe-rawwrite.cc @@ -1,7 +1,7 @@ #include "lib/core/globals.h" #include "lib/config/config.h" #include "lib/config/flags.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "lib/data/fluxmap.h" #include "lib/data/sector.h" #include "lib/config/proto.h" diff --git a/src/fe-read.cc b/src/fe-read.cc index 80df542a..6bb795ae 100644 --- a/src/fe-read.cc +++ b/src/fe-read.cc @@ -1,7 +1,7 @@ #include "lib/core/globals.h" #include "lib/config/config.h" #include "lib/config/flags.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "lib/data/fluxmap.h" #include "lib/decoders/decoders.h" #include "lib/data/sector.h" diff --git a/src/fe-write.cc b/src/fe-write.cc index 5b73261f..d9e0a854 100644 --- a/src/fe-write.cc +++ b/src/fe-write.cc @@ -1,7 +1,7 @@ #include "lib/core/globals.h" #include "lib/config/config.h" #include "lib/config/flags.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "lib/data/fluxmap.h" #include "lib/decoders/decoders.h" #include "lib/encoders/encoders.h" diff --git a/src/fileutils.cc b/src/fileutils.cc index f588d05f..87e19b39 100644 --- a/src/fileutils.cc +++ b/src/fileutils.cc @@ -4,7 +4,7 @@ #include "lib/data/fluxmap.h" #include "lib/data/sector.h" #include "lib/config/proto.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "lib/fluxsource/fluxsource.h" #include "lib/fluxsink/fluxsink.h" #include "lib/imagereader/imagereader.h" diff --git a/src/gui/build.py b/src/gui/build.py index 1f4e3595..f64ffcd3 100644 --- a/src/gui/build.py +++ b/src/gui/build.py @@ -63,7 +63,6 @@ "dep/hfsutils", "dep/libusbp", "extras+icons", - "+lib", "lib/core", "lib/data", "lib/vfs", diff --git a/src/gui/drivetypes/build.py b/src/gui/drivetypes/build.py index 4314afdf..c5f5d645 100644 --- a/src/gui/drivetypes/build.py +++ b/src/gui/drivetypes/build.py @@ -32,5 +32,5 @@ cxxlibrary( name="drivetypes", srcs=[".+drivetypes_cc", ".+drivetypes_table_cc"], - deps=["+lib"], + deps=["lib/core", "lib/config"], ) diff --git a/src/gui/imagerpanel.cc b/src/gui/imagerpanel.cc index d0305882..45aefa5b 100644 --- a/src/gui/imagerpanel.cc +++ b/src/gui/imagerpanel.cc @@ -8,7 +8,7 @@ #include "lib/encoders/encoders.h" #include "lib/decoders/decoders.h" #include "lib/config/proto.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "gui.h" #include "lib/data/layout.h" #include "fluxviewerwindow.h" diff --git a/src/gui/mainwindow.cc b/src/gui/mainwindow.cc index 62ae14e0..6bf48813 100644 --- a/src/gui/mainwindow.cc +++ b/src/gui/mainwindow.cc @@ -3,7 +3,7 @@ #include "lib/config/proto.h" #include "gui.h" #include "lib/core/logger.h" -#include "lib/readerwriter.h" +#include "lib/algorithms/readerwriter.h" #include "lib/fluxsource/fluxsource.h" #include "lib/fluxsink/fluxsink.h" #include "lib/imagereader/imagereader.h" diff --git a/tests/build.py b/tests/build.py index 3cf1f533..95b99bdc 100644 --- a/tests/build.py +++ b/tests/build.py @@ -5,7 +5,7 @@ from scripts.build import protoencode_single -proto(name="test_proto", srcs=["./testproto.proto"], deps=["lib+common_proto"]) +proto(name="test_proto", srcs=["./testproto.proto"], deps=["lib/config+common_proto"]) protocc( name="test_proto_lib", srcs=[".+test_proto"], deps=["lib/config+proto_lib"] @@ -54,7 +54,6 @@ deps=[ "lib/external+fl2_proto_lib", "+fmt_lib", - "+lib", "+protobuf_lib", "+protocol", "+z_lib", @@ -84,7 +83,6 @@ deps=[ "lib/external+fl2_proto_lib", "+fmt_lib", - "+lib", "+protobuf_lib", "+protocol", "+z_lib", @@ -96,6 +94,7 @@ "dep/libusbp", "dep/snowhouse", "dep/stb", + "lib/algorithms", "lib/config", "lib/core", "lib/data", diff --git a/tests/testproto.proto b/tests/testproto.proto index 00101c73..802e1333 100644 --- a/tests/testproto.proto +++ b/tests/testproto.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lib/common.proto"; +import "lib/config/common.proto"; message TestProto { message SubMessageProto { diff --git a/tools/build.py b/tools/build.py index a0f1c4c2..bdbd384f 100644 --- a/tools/build.py +++ b/tools/build.py @@ -10,13 +10,14 @@ srcs=["./brother120tool.cc"], deps=[ "+fmt_lib", - "+lib", "+protobuf_lib", "+z_lib", "lib/config", "lib/core", "lib/data", "lib/fluxsource+proto_lib", + "lib/algorithms", + "src/formats", ] + emu, ) @@ -26,13 +27,14 @@ srcs=["./brother240tool.cc"], deps=[ "+fmt_lib", - "+lib", "+protobuf_lib", "+z_lib", "lib/config", "lib/core", "lib/data", "lib/fluxsource+proto_lib", + "lib/algorithms", + "src/formats", ] + emu, ) @@ -42,7 +44,6 @@ srcs=["./upgrade-flux-file.cc"], deps=[ "+fmt_lib", - "+lib", "+protobuf_lib", "+protocol", "+sqlite3_lib", @@ -53,6 +54,7 @@ "lib/data", "lib/external+fl2_proto_lib", "lib/fluxsource+proto_lib", + "lib/algorithms", "src/formats", ], )