You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
114 lines
2.6 KiB
114 lines
2.6 KiB
project('raycaster', 'cpp',
|
|
version: '0.1.0',
|
|
default_options: [
|
|
'cpp_std=c++20',
|
|
'cpp_args=-D_GLIBCXX_DEBUG=1 -D_GLIBCXX_DEBUG_PEDANTIC=1',
|
|
])
|
|
|
|
# use this for common options only for our executables
|
|
cpp_args=[]
|
|
# these are passed as override_defaults
|
|
exe_defaults = ['warning_level=2', 'werror=true']
|
|
|
|
cc = meson.get_compiler('cpp')
|
|
|
|
catch2 = dependency('catch2-with-main')
|
|
fmt = subproject('fmt').get_variable('fmt_dep')
|
|
json = dependency('nlohmann_json')
|
|
freetype2 = dependency('freetype2')
|
|
|
|
flac = dependency('flac')
|
|
ogg = dependency('ogg')
|
|
vorbis = dependency('vorbis')
|
|
vorbisfile = dependency('vorbisfile')
|
|
vorbisenc = dependency('vorbisenc')
|
|
sfml_audio = dependency('sfml_audio')
|
|
sfml_graphics = dependency('sfml_graphics')
|
|
sfml_network = dependency('sfml_network')
|
|
sfml_system = dependency('sfml_system')
|
|
sfml_window = dependency('sfml_window')
|
|
ftxui_screen = dependency('ftxui-screen')
|
|
ftxui_dom = dependency('ftxui-dom')
|
|
ftxui_component = dependency('ftxui-component')
|
|
|
|
dependencies = [
|
|
fmt, json, freetype2,
|
|
flac, ogg, vorbis, vorbisfile, vorbisenc,
|
|
sfml_audio, sfml_graphics,
|
|
sfml_network, sfml_system,
|
|
sfml_window, ftxui_screen, ftxui_dom, ftxui_component
|
|
]
|
|
|
|
if build_machine.system() == 'windows'
|
|
sfml_main = dependency('sfml_main')
|
|
opengl32 = cc.find_library('opengl32', required: true)
|
|
winmm = cc.find_library('winmm', required: true)
|
|
gdi32 = cc.find_library('gdi32', required: true)
|
|
|
|
dependencies += [
|
|
opengl32, winmm, gdi32, sfml_main
|
|
]
|
|
endif
|
|
|
|
|
|
sources = [
|
|
'animator.cpp',
|
|
'ansi_parser.cpp',
|
|
'camera.cpp',
|
|
'combat.cpp',
|
|
'combat_ui.cpp',
|
|
'components.cpp',
|
|
'config.cpp',
|
|
'dbc.cpp',
|
|
'devices.cpp',
|
|
'guecs.cpp',
|
|
'gui.cpp',
|
|
'inventory.cpp',
|
|
'lel.cpp',
|
|
'levelmanager.cpp',
|
|
'lights.cpp',
|
|
'map.cpp',
|
|
'map_view.cpp',
|
|
'matrix.cpp',
|
|
'matrix.cpp',
|
|
'panel.cpp',
|
|
'pathing.cpp',
|
|
'rand.cpp',
|
|
'raycaster.cpp',
|
|
'render.cpp',
|
|
'save.cpp',
|
|
'shiterator.hpp',
|
|
'spatialmap.cpp',
|
|
'stats.cpp',
|
|
'status_ui.cpp',
|
|
'systems.cpp',
|
|
'texture.cpp',
|
|
'tilemap.cpp',
|
|
'worldbuilder.cpp',
|
|
]
|
|
|
|
executable('runtests', sources + [
|
|
'tests/ansi_parser.cpp',
|
|
'tests/base.cpp',
|
|
'tests/dbc.cpp',
|
|
'tests/dinkyecs.cpp',
|
|
'tests/guecs.cpp',
|
|
'tests/fsm.cpp',
|
|
'tests/inventory.cpp',
|
|
'tests/lel.cpp',
|
|
'tests/levelmanager.cpp',
|
|
'tests/lighting.cpp',
|
|
'tests/map.cpp',
|
|
'tests/matrix.cpp',
|
|
'tests/pathing.cpp',
|
|
'tests/spatialmap.cpp',
|
|
'tests/tilemap.cpp',
|
|
], override_options: exe_defaults,
|
|
dependencies: dependencies + [catch2])
|
|
|
|
|
|
executable('zedcaster',
|
|
sources + [ 'main.cpp' ],
|
|
cpp_args: cpp_args,
|
|
override_options: exe_defaults,
|
|
dependencies: dependencies)
|
|
|