2024-01-09 19:12:22 +00:00
|
|
|
project('quickerNES','c','cpp',
|
|
|
|
version: '1.0.0',
|
|
|
|
license: 'GPL-3.0-only',
|
|
|
|
default_options : ['cpp_std=c++20', 'default_library=shared', 'buildtype=release']
|
|
|
|
)
|
|
|
|
|
2024-01-14 09:31:17 +00:00
|
|
|
# Getting page alignment option
|
2024-01-14 09:13:28 +00:00
|
|
|
pageSize = get_option('CPUFunctionAlignment')
|
2024-01-14 08:17:06 +00:00
|
|
|
|
2024-01-14 09:59:20 +00:00
|
|
|
# Loading dependencies
|
2024-01-14 09:31:17 +00:00
|
|
|
subdir('source')
|
2024-01-09 19:12:22 +00:00
|
|
|
|
2024-01-14 09:31:17 +00:00
|
|
|
# Common application flags
|
2024-01-14 09:59:20 +00:00
|
|
|
commonCompileArgs = [ '-Wfatal-errors', '-Wall', '-Wno-multichar' ]
|
2024-01-09 19:12:22 +00:00
|
|
|
|
2024-01-12 18:14:57 +00:00
|
|
|
# Building playback tool
|
2024-01-09 19:12:22 +00:00
|
|
|
|
|
|
|
quickerNESPlayerSrc = [
|
2024-01-10 19:11:49 +00:00
|
|
|
'extern/hqn/hqn.cpp',
|
|
|
|
'extern/hqn/hqn_gui_controller.cpp',
|
|
|
|
'extern/hqn/hqn_surface.cpp',
|
|
|
|
'extern/hqn/hqn_util.cpp',
|
2024-01-12 20:13:51 +00:00
|
|
|
'extern/hqn/options.cpp',
|
2024-01-09 19:12:22 +00:00
|
|
|
]
|
|
|
|
|
2024-01-16 21:43:03 +00:00
|
|
|
if get_option('buildPlayer') == true
|
|
|
|
executable('player',
|
|
|
|
'source/player.cpp',
|
|
|
|
cpp_args : [ commonCompileArgs, '-DNCURSES' ],
|
|
|
|
dependencies : [ quickerNESDependency, toolDependency, dependency('sdl2'), dependency('SDL2_image') ],
|
|
|
|
include_directories : include_directories(['source']),
|
|
|
|
link_args : [ '-lncurses' ],
|
|
|
|
sources : quickerNESPlayerSrc
|
|
|
|
)
|
|
|
|
endif
|
2024-01-11 19:23:32 +00:00
|
|
|
|
2024-01-14 09:59:20 +00:00
|
|
|
# Building tester tool for QuickerNES
|
2024-01-12 18:14:57 +00:00
|
|
|
|
2024-01-17 05:59:10 +00:00
|
|
|
quickerNESTester = executable('quickerNESTester',
|
2024-01-14 09:59:20 +00:00
|
|
|
'source/tester.cpp',
|
|
|
|
cpp_args : [ commonCompileArgs, '-Werror' ],
|
2024-01-15 19:56:58 +00:00
|
|
|
dependencies : [ quickerNESDependency, toolDependency ],
|
2024-01-14 09:59:20 +00:00
|
|
|
include_directories : include_directories(['../extern/json'])
|
|
|
|
)
|
|
|
|
|
|
|
|
# Building tester tool for the original QuickNES
|
|
|
|
|
2024-01-17 05:59:10 +00:00
|
|
|
quickNESTester = executable('quickNESTester',
|
2024-01-14 09:31:17 +00:00
|
|
|
'source/tester.cpp',
|
|
|
|
cpp_args : [ commonCompileArgs ],
|
2024-01-15 19:56:58 +00:00
|
|
|
dependencies : [ quickNESDependency, toolDependency ],
|
2024-01-14 09:31:17 +00:00
|
|
|
include_directories : include_directories(['../extern/json'])
|
|
|
|
)
|
2024-01-12 18:14:57 +00:00
|
|
|
|
2024-01-11 19:23:32 +00:00
|
|
|
# Building tests
|
2024-01-16 21:43:03 +00:00
|
|
|
subdir('tests')
|