mkxp-z/meson.build

36 lines
937 B
Meson
Raw Normal View History

2019-07-31 09:45:12 -04:00
project('mkxp-z', 'cpp', version: '1.0')
2019-07-29 07:56:45 -04:00
2019-08-04 12:00:20 -04:00
xxd = find_program('xxd', native: true)
2019-07-29 07:56:45 -04:00
host_system = host_machine.system()
2019-07-31 10:53:46 -04:00
compiler = meson.get_compiler('cpp')
2019-07-29 07:56:45 -04:00
2019-07-29 08:20:40 -04:00
if get_option('workdir_current') == true
add_project_arguments('-DWORKDIR_CURRENT', language: 'cpp')
endif
2019-07-29 07:56:45 -04:00
subdir('src')
2019-07-31 08:47:44 -04:00
subdir('binding')
2019-07-29 07:56:45 -04:00
subdir('shader')
subdir('assets')
2019-07-31 07:04:13 -04:00
all_sources = [main, bindings, processed_shaders, processed_assets]
2019-07-31 08:47:44 -04:00
include_dirs = [include_directories('src', 'binding')]
2019-07-29 07:56:45 -04:00
linker_args = []
if host_system == 'windows'
subdir('windows')
all_sources += windows_resources
2019-07-30 09:17:20 -04:00
include_dirs += include_directories('windows')
2019-07-29 07:56:45 -04:00
elif host_system == 'darwin'
2019-07-31 15:33:02 -04:00
if compiler.get_id() == 'clang'
2019-07-29 07:56:45 -04:00
add_project_arguments(['-std=c++11','-stdlib=libc++'], language: 'cpp')
endif
endif
2019-07-31 09:45:12 -04:00
executable(meson.project_name(),
2019-07-29 07:56:45 -04:00
sources: all_sources,
dependencies: [main_dependencies, binding_dependencies],
2019-07-30 09:17:20 -04:00
include_directories: include_dirs
2019-07-29 07:56:45 -04:00
)