diff --git a/Components/6560/6560.cpp b/Components/6560/6560.cpp index 39907e705..81dc1065c 100644 --- a/Components/6560/6560.cpp +++ b/Components/6560/6560.cpp @@ -8,6 +8,8 @@ #include "6560.hpp" +#include + using namespace MOS; Speaker::Speaker() : diff --git a/Machines/Atari2600/PIA.hpp b/Machines/Atari2600/PIA.hpp index afd0603aa..cf3900357 100644 --- a/Machines/Atari2600/PIA.hpp +++ b/Machines/Atari2600/PIA.hpp @@ -9,6 +9,8 @@ #ifndef Atari2600_PIA_h #define Atari2600_PIA_h +#include + #include "../../Components/6532/6532.hpp" namespace Atari2600 { diff --git a/Machines/KeyboardMachine.hpp b/Machines/KeyboardMachine.hpp index 4839a1005..a9522b2eb 100644 --- a/Machines/KeyboardMachine.hpp +++ b/Machines/KeyboardMachine.hpp @@ -9,6 +9,8 @@ #ifndef KeyboardMachine_h #define KeyboardMachine_h +#include + #include "../Inputs/Keyboard.hpp" namespace KeyboardMachine { diff --git a/OSBindings/SDL/SConstruct b/OSBindings/SDL/SConstruct index 03270cb2e..3227c8afe 100644 --- a/OSBindings/SDL/SConstruct +++ b/OSBindings/SDL/SConstruct @@ -10,11 +10,65 @@ env.ParseConfig('sdl2-config --libs') # gather a list of source files SOURCES = glob.glob('*.cpp') +SOURCES += glob.glob('../../Components/1770/*.cpp') +SOURCES += glob.glob('../../Components/6522/Implementation/*.cpp') +SOURCES += glob.glob('../../Components/6560/*.cpp') +SOURCES += glob.glob('../../Components/8272/*.cpp') +SOURCES += glob.glob('../../Components/AY38910/*.cpp') + +SOURCES += glob.glob('../../Concurrency/*.cpp') + +SOURCES += glob.glob('../../Inputs/*.cpp') + +SOURCES += glob.glob('../../Machines/*.cpp') +SOURCES += glob.glob('../../Machines/AmstradCPC/*.cpp') +SOURCES += glob.glob('../../Machines/Atari2600/*.cpp') +SOURCES += glob.glob('../../Machines/Commodore/*.cpp') +SOURCES += glob.glob('../../Machines/Commodore/1540/*.cpp') +SOURCES += glob.glob('../../Machines/Commodore/Vic-20/*.cpp') +SOURCES += glob.glob('../../Machines/Electron/*.cpp') +SOURCES += glob.glob('../../Machines/Oric/*.cpp') +SOURCES += glob.glob('../../Machines/Utility/*.cpp') +SOURCES += glob.glob('../../Machines/ZX8081/*.cpp') + +SOURCES += glob.glob('../../Outputs/CRT/*.cpp') +SOURCES += glob.glob('../../Outputs/CRT/Internals/*.cpp') +SOURCES += glob.glob('../../Outputs/CRT/Interals/Shaders/*.cpp') + +SOURCES += glob.glob('../../Processors/6502/Implementation/*.cpp') +SOURCES += glob.glob('../../Processors/Z80/Implementation/*.cpp') + +SOURCES += glob.glob('../../StaticAnalyser/*.cpp') +SOURCES += glob.glob('../../StaticAnalyser/Acorn/*.cpp') +SOURCES += glob.glob('../../StaticAnalyser/AmstradCPC/*.cpp') +SOURCES += glob.glob('../../StaticAnalyser/Atari/*.cpp') +SOURCES += glob.glob('../../StaticAnalyser/Commodore/*.cpp') +SOURCES += glob.glob('../../StaticAnalyser/Disassembler/*.cpp') +SOURCES += glob.glob('../../StaticAnalyser/Oric/*.cpp') +SOURCES += glob.glob('../../StaticAnalyser/ZX8081/*.cpp') + +SOURCES += glob.glob('../../Storage/*.cpp') +SOURCES += glob.glob('../../Storage/Cartridge/*.cpp') +SOURCES += glob.glob('../../Storage/Encodings/*.cpp') +SOURCES += glob.glob('../../Storage/Formats/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Controller/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/DiskImage/Formats/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/DPLL/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Encodings/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Encodings/MFM/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Parsers/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Track/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Data/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Tape/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Tape/Formats/*.cpp') +SOURCES += glob.glob('../../Storage/Disk/Tape/Parsers/*.cpp') + # add additional compiler flags -env.Append(CCFLAGS = ['-g', '-Wall', '--std=c++11']) +env.Append(CCFLAGS = ['-g', '--std=c++11']) # add additional libraries to link against -env.Append(LIBS = ['libz']) +env.Append(LIBS = ['libz', 'pthread', 'GL']) # build target # output executable will be "game" -env.Program(target = 'game', source = SOURCES) +env.Program(target = 'clksignal', source = SOURCES) diff --git a/Outputs/CRT/CRT.cpp b/Outputs/CRT/CRT.cpp index 14487acda..badf2b09d 100644 --- a/Outputs/CRT/CRT.cpp +++ b/Outputs/CRT/CRT.cpp @@ -7,7 +7,7 @@ // #include "CRT.hpp" -#include "CRTOpenGL.hpp" +#include "Internals/CRTOpenGL.hpp" #include #include #include @@ -343,37 +343,33 @@ void CRT::output_scan(const Scan *const scan) { These all merely channel into advance_cycles, supplying appropriate arguments */ void CRT::output_sync(unsigned int number_of_cycles) { - Scan scan{ - .type = Scan::Type::Sync, - .number_of_cycles = number_of_cycles - }; + Scan scan; + scan.type = Scan::Type::Sync; + scan.number_of_cycles = number_of_cycles; output_scan(&scan); } void CRT::output_blank(unsigned int number_of_cycles) { - Scan scan { - .type = Scan::Type::Blank, - .number_of_cycles = number_of_cycles - }; + Scan scan; + scan.type = Scan::Type::Blank; + scan.number_of_cycles = number_of_cycles; output_scan(&scan); } void CRT::output_level(unsigned int number_of_cycles) { openGL_output_builder_.texture_builder.reduce_previous_allocation_to(1); - Scan scan { - .type = Scan::Type::Level, - .number_of_cycles = number_of_cycles, - }; + Scan scan; + scan.type = Scan::Type::Level; + scan.number_of_cycles = number_of_cycles; output_scan(&scan); } void CRT::output_colour_burst(unsigned int number_of_cycles, uint8_t phase, uint8_t amplitude) { - Scan scan { - .type = Scan::Type::ColourBurst, - .number_of_cycles = number_of_cycles, - .phase = phase, - .amplitude = amplitude - }; + Scan scan; + scan.type = Scan::Type::ColourBurst; + scan.number_of_cycles = number_of_cycles; + scan.phase = phase; + scan.amplitude = amplitude; output_scan(&scan); } @@ -383,10 +379,9 @@ void CRT::output_default_colour_burst(unsigned int number_of_cycles) { void CRT::output_data(unsigned int number_of_cycles, unsigned int source_divider) { openGL_output_builder_.texture_builder.reduce_previous_allocation_to(number_of_cycles / source_divider); - Scan scan { - .type = Scan::Type::Data, - .number_of_cycles = number_of_cycles, - }; + Scan scan; + scan.type = Scan::Type::Data; + scan.number_of_cycles = number_of_cycles; output_scan(&scan); } diff --git a/Outputs/CRT/Internals/ArrayBuilder.cpp b/Outputs/CRT/Internals/ArrayBuilder.cpp index 30c4cf6aa..5a71d3778 100644 --- a/Outputs/CRT/Internals/ArrayBuilder.cpp +++ b/Outputs/CRT/Internals/ArrayBuilder.cpp @@ -8,6 +8,8 @@ #include "ArrayBuilder.hpp" +#include + using namespace Outputs::CRT; ArrayBuilder::ArrayBuilder(size_t input_size, size_t output_size) : diff --git a/Outputs/CRT/Internals/CRTOpenGL.cpp b/Outputs/CRT/Internals/CRTOpenGL.cpp index bfccfdc52..a74968606 100644 --- a/Outputs/CRT/Internals/CRTOpenGL.cpp +++ b/Outputs/CRT/Internals/CRTOpenGL.cpp @@ -5,7 +5,7 @@ // Copyright © 2016 Thomas Harte. All rights reserved. // -#include "CRT.hpp" +#include "../CRT.hpp" #include #include diff --git a/Outputs/CRT/Internals/OpenGL.hpp b/Outputs/CRT/Internals/OpenGL.hpp index c8282188f..f400e97fa 100644 --- a/Outputs/CRT/Internals/OpenGL.hpp +++ b/Outputs/CRT/Internals/OpenGL.hpp @@ -18,6 +18,7 @@ #include #endif #else +#define GL_GLEXT_PROTOTYPES #include #endif diff --git a/Outputs/Speaker.hpp b/Outputs/Speaker.hpp index 868fb5967..1b2c77986 100644 --- a/Outputs/Speaker.hpp +++ b/Outputs/Speaker.hpp @@ -9,8 +9,10 @@ #ifndef Speaker_hpp #define Speaker_hpp +#include #include #include +#include #include #include diff --git a/Processors/Z80/Implementation/Z80Implementation.hpp b/Processors/Z80/Implementation/Z80Implementation.hpp index 5e09d9f6d..de98267b5 100644 --- a/Processors/Z80/Implementation/Z80Implementation.hpp +++ b/Processors/Z80/Implementation/Z80Implementation.hpp @@ -849,7 +849,6 @@ template < class T, break; case MicroOp::IndexedPlaceHolder: - printf("Hit placeholder!!!\n"); return; } #undef set_parity diff --git a/Processors/Z80/Implementation/Z80Storage.cpp b/Processors/Z80/Implementation/Z80Storage.cpp index a531e93a7..3e0a63457 100644 --- a/Processors/Z80/Implementation/Z80Storage.cpp +++ b/Processors/Z80/Implementation/Z80Storage.cpp @@ -7,6 +7,7 @@ // #include "../Z80.hpp" +#include using namespace CPU::Z80; diff --git a/StaticAnalyser/AmstradCPC/StaticAnalyser.cpp b/StaticAnalyser/AmstradCPC/StaticAnalyser.cpp index 943f85255..246371deb 100644 --- a/StaticAnalyser/AmstradCPC/StaticAnalyser.cpp +++ b/StaticAnalyser/AmstradCPC/StaticAnalyser.cpp @@ -8,13 +8,16 @@ #include "StaticAnalyser.hpp" +#include +#include + #include "../../Storage/Disk/Parsers/CPM.hpp" #include "../../Storage/Disk/Encodings/MFM/Parser.hpp" static bool strcmp_insensitive(const char *a, const char *b) { if(strlen(a) != strlen(b)) return false; while(*a) { - if(tolower(*a) != towlower(*b)) return false; + if(tolower(*a) != tolower(*b)) return false; a++; b++; } diff --git a/StaticAnalyser/StaticAnalyser.cpp b/StaticAnalyser/StaticAnalyser.cpp index 87e960aba..0676fd903 100644 --- a/StaticAnalyser/StaticAnalyser.cpp +++ b/StaticAnalyser/StaticAnalyser.cpp @@ -9,6 +9,7 @@ #include "StaticAnalyser.hpp" #include +#include // Analysers #include "Acorn/StaticAnalyser.hpp" diff --git a/Storage/Disk/DiskImage/Formats/D64.cpp b/Storage/Disk/DiskImage/Formats/D64.cpp index cd6bde7af..7f35b2397 100644 --- a/Storage/Disk/DiskImage/Formats/D64.cpp +++ b/Storage/Disk/DiskImage/Formats/D64.cpp @@ -9,6 +9,7 @@ #include "D64.hpp" #include +#include #include #include "../../Track/PCMTrack.hpp" diff --git a/Storage/Disk/DiskImage/Formats/G64.cpp b/Storage/Disk/DiskImage/Formats/G64.cpp index 3bb7870d5..8e04c70ef 100644 --- a/Storage/Disk/DiskImage/Formats/G64.cpp +++ b/Storage/Disk/DiskImage/Formats/G64.cpp @@ -8,7 +8,9 @@ #include "G64.hpp" +#include #include + #include "../../Track/PCMTrack.hpp" #include "../../Encodings/CommodoreGCR.hpp" diff --git a/Storage/Disk/DiskImage/Formats/SSD.cpp b/Storage/Disk/DiskImage/Formats/SSD.cpp index d5fcf570b..0b6cbb939 100644 --- a/Storage/Disk/DiskImage/Formats/SSD.cpp +++ b/Storage/Disk/DiskImage/Formats/SSD.cpp @@ -8,6 +8,8 @@ #include "SSD.hpp" +#include + #include "Utility/ImplicitSectors.hpp" namespace { diff --git a/Storage/Disk/Drive.cpp b/Storage/Disk/Drive.cpp index 3e809e3d6..9566428c3 100644 --- a/Storage/Disk/Drive.cpp +++ b/Storage/Disk/Drive.cpp @@ -8,7 +8,7 @@ #include "Drive.hpp" -#include "UnformattedTrack.hpp" +#include "Track/UnformattedTrack.hpp" #include #include diff --git a/Storage/Disk/Encodings/MFM/Encoder.hpp b/Storage/Disk/Encodings/MFM/Encoder.hpp index 791f10450..971746f6d 100644 --- a/Storage/Disk/Encodings/MFM/Encoder.hpp +++ b/Storage/Disk/Encodings/MFM/Encoder.hpp @@ -10,7 +10,9 @@ #define Storage_Disk_Encodings_MFM_hpp #include +#include #include + #include "Sector.hpp" #include "../../Track/Track.hpp" #include "../../../../NumberTheory/CRC.hpp" diff --git a/Storage/Disk/Parsers/CPM.cpp b/Storage/Disk/Parsers/CPM.cpp index 81e26b6ae..03fab488f 100644 --- a/Storage/Disk/Parsers/CPM.cpp +++ b/Storage/Disk/Parsers/CPM.cpp @@ -8,6 +8,9 @@ #include "CPM.hpp" +#include +#include + #include "../Encodings/MFM/Parser.hpp" using namespace Storage::Disk::CPM; diff --git a/Storage/Disk/Track/PCMSegment.hpp b/Storage/Disk/Track/PCMSegment.hpp index f8bebdc17..e072c24f5 100644 --- a/Storage/Disk/Track/PCMSegment.hpp +++ b/Storage/Disk/Track/PCMSegment.hpp @@ -10,6 +10,7 @@ #define PCMSegment_hpp #include +#include #include #include "../../Storage.hpp" diff --git a/Storage/FileHolder.cpp b/Storage/FileHolder.cpp index 4fec9ef73..62a0ee470 100644 --- a/Storage/FileHolder.cpp +++ b/Storage/FileHolder.cpp @@ -8,6 +8,7 @@ #include "FileHolder.hpp" +#include #include using namespace Storage;