2017-11-09 03:36:41 +00:00
|
|
|
import glob
|
2019-05-31 02:20:15 +00:00
|
|
|
import sys
|
|
|
|
|
2019-08-03 04:33:53 +00:00
|
|
|
# establish UTF-8 encoding for Python 2
|
|
|
|
if sys.version_info < (3, 0):
|
|
|
|
reload(sys)
|
|
|
|
sys.setdefaultencoding('utf-8')
|
2017-11-09 03:36:41 +00:00
|
|
|
|
|
|
|
# create build environment
|
|
|
|
env = Environment()
|
|
|
|
|
|
|
|
# determine compiler and linker flags for SDL
|
|
|
|
env.ParseConfig('sdl2-config --cflags')
|
|
|
|
env.ParseConfig('sdl2-config --libs')
|
|
|
|
|
|
|
|
# gather a list of source files
|
|
|
|
SOURCES = glob.glob('*.cpp')
|
|
|
|
|
2018-02-19 13:13:41 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Dynamic/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Analyser/Dynamic/MultiMachine/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Analyser/Dynamic/MultiMachine/Implementation/*.cpp')
|
|
|
|
|
|
|
|
SOURCES += glob.glob('../../Analyser/Static/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Analyser/Static/Acorn/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Analyser/Static/AmstradCPC/*.cpp')
|
2018-04-20 14:58:57 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/AppleII/*.cpp')
|
2019-11-09 21:14:00 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/Atari2600/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Analyser/Static/AtariST/*.cpp')
|
2018-03-02 03:19:50 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/Coleco/*.cpp')
|
2018-02-19 13:13:41 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/Commodore/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Analyser/Static/Disassembler/*.cpp')
|
2018-05-05 23:34:22 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/DiskII/*.cpp')
|
2019-07-08 21:38:43 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/Macintosh/*.cpp')
|
2018-02-19 13:13:41 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/MSX/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Analyser/Static/Oric/*.cpp')
|
2018-10-01 00:46:38 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/Sega/*.cpp')
|
2018-02-19 13:13:41 +00:00
|
|
|
SOURCES += glob.glob('../../Analyser/Static/ZX8081/*.cpp')
|
|
|
|
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Components/1770/*.cpp')
|
2019-09-19 01:49:57 +00:00
|
|
|
SOURCES += glob.glob('../../Components/5380/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Components/6522/Implementation/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Components/6560/*.cpp')
|
2019-11-09 20:42:19 +00:00
|
|
|
SOURCES += glob.glob('../../Components/6850/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Components/68901/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Components/8272/*.cpp')
|
2019-07-08 22:18:49 +00:00
|
|
|
SOURCES += glob.glob('../../Components/8530/*.cpp')
|
2017-12-07 02:56:26 +00:00
|
|
|
SOURCES += glob.glob('../../Components/9918/*.cpp')
|
2017-12-15 01:27:26 +00:00
|
|
|
SOURCES += glob.glob('../../Components/9918/Implementation/*.cpp')
|
2018-04-20 14:56:59 +00:00
|
|
|
SOURCES += glob.glob('../../Components/AudioToggle/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Components/AY38910/*.cpp')
|
2018-04-21 21:33:42 +00:00
|
|
|
SOURCES += glob.glob('../../Components/DiskII/*.cpp')
|
2018-01-07 01:15:55 +00:00
|
|
|
SOURCES += glob.glob('../../Components/KonamiSCC/*.cpp')
|
2018-03-02 03:19:50 +00:00
|
|
|
SOURCES += glob.glob('../../Components/SN76489/*.cpp')
|
2019-11-09 20:42:19 +00:00
|
|
|
SOURCES += glob.glob('../../Components/Serial/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
|
|
|
|
SOURCES += glob.glob('../../Concurrency/*.cpp')
|
|
|
|
|
2017-11-19 02:13:55 +00:00
|
|
|
SOURCES += glob.glob('../../Configurable/*.cpp')
|
2017-11-19 02:09:26 +00:00
|
|
|
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Inputs/*.cpp')
|
|
|
|
|
|
|
|
SOURCES += glob.glob('../../Machines/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Machines/AmstradCPC/*.cpp')
|
2019-07-08 22:10:39 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/Apple/AppleII/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Machines/Apple/Macintosh/*.cpp')
|
2019-11-09 20:42:19 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/Atari/2600/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Machines/Atari/ST/*.cpp')
|
2018-03-02 03:19:50 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/ColecoVision/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/Commodore/*.cpp')
|
2017-11-11 02:56:15 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/Commodore/1540/Implementation/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/Commodore/Vic-20/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Machines/Electron/*.cpp')
|
2018-10-01 00:48:55 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/MasterSystem/*.cpp')
|
2017-12-07 02:56:26 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/MSX/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Machines/Oric/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Machines/Utility/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Machines/ZX8081/*.cpp')
|
|
|
|
|
2019-01-26 01:26:20 +00:00
|
|
|
SOURCES += glob.glob('../../Outputs/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Outputs/CRT/*.cpp')
|
2019-01-26 00:11:57 +00:00
|
|
|
SOURCES += glob.glob('../../Outputs/OpenGL/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Outputs/OpenGL/Primitives/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
|
|
|
|
SOURCES += glob.glob('../../Processors/6502/Implementation/*.cpp')
|
2019-05-03 18:31:09 +00:00
|
|
|
SOURCES += glob.glob('../../Processors/68000/Implementation/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Processors/Z80/Implementation/*.cpp')
|
|
|
|
|
2017-11-11 02:56:15 +00:00
|
|
|
SOURCES += glob.glob('../../SignalProcessing/*.cpp')
|
|
|
|
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Storage/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/Cartridge/*.cpp')
|
2017-11-11 02:56:15 +00:00
|
|
|
SOURCES += glob.glob('../../Storage/Cartridge/Encodings/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/Cartridge/Formats/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/Data/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Storage/Disk/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/Disk/Controller/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/Disk/DiskImage/Formats/*.cpp')
|
2017-11-11 02:56:15 +00:00
|
|
|
SOURCES += glob.glob('../../Storage/Disk/DiskImage/Formats/Utility/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
SOURCES += glob.glob('../../Storage/Disk/DPLL/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/Disk/Encodings/*.cpp')
|
2018-05-05 23:34:22 +00:00
|
|
|
SOURCES += glob.glob('../../Storage/Disk/Encodings/AppleGCR/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
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')
|
2019-09-19 01:49:57 +00:00
|
|
|
SOURCES += glob.glob('../../Storage/MassStorage/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/MassStorage/Encodings/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/MassStorage/Formats/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/MassStorage/SCSI/*.cpp')
|
2017-11-11 02:56:15 +00:00
|
|
|
SOURCES += glob.glob('../../Storage/Tape/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/Tape/Formats/*.cpp')
|
|
|
|
SOURCES += glob.glob('../../Storage/Tape/Parsers/*.cpp')
|
2017-11-10 03:04:49 +00:00
|
|
|
|
2017-11-09 03:36:41 +00:00
|
|
|
# add additional compiler flags
|
2019-12-22 01:25:43 +00:00
|
|
|
env.Append(CCFLAGS = ['--std=c++17', '-Wall', '-O2', '-DNDEBUG'])
|
2017-11-12 21:46:10 +00:00
|
|
|
|
2017-11-09 03:36:41 +00:00
|
|
|
# add additional libraries to link against
|
2017-11-10 03:04:49 +00:00
|
|
|
env.Append(LIBS = ['libz', 'pthread', 'GL'])
|
2017-11-09 03:36:41 +00:00
|
|
|
|
|
|
|
# build target
|
2017-11-10 03:04:49 +00:00
|
|
|
env.Program(target = 'clksignal', source = SOURCES)
|