roza/meson.build

68 lines
1.1 KiB
Meson

project(
'roza',
'c',
version: '0.0.0'
)
conf = configuration_data()
conf.set('version', meson.project_version())
configure_file(
input: 'lib/conf.in.h',
output: 'conf.h',
configuration: conf
)
roza_lib = static_library(
'roza',
sources: [
# utils
'lib/str.c',
# core
'lib/err.c',
'lib/loader.c',
# lang
'lib/node.c',
'lib/lexer.c',
'lib/parser.c',
'lib/type.c',
'lib/value.c',
'lib/tysy.c',
# comp
'lib/opcodes.c',
'lib/mod.c',
'lib/prepass.c',
'lib/compiler.c',
# exec
'lib/vm.c',
]
)
roza_dep = declare_dependency(
link_with: roza_lib,
include_directories: ['lib']
)
executable('roza',
sources: [
'src/main.c'
],
dependencies: [
roza_dep
],
install: true)
executable('roza-tests',
sources: [
'tests/units/lexer.c',
'tests/units/parser.c',
],
dependencies: [
roza_dep,
dependency('criterion')
])