OwlPath/meson.build

45 lines
890 B
Meson
Raw Normal View History

2022-07-06 14:38:12 +02:00
project('me.sergiotarxz.owlpath', 'vala')
2022-07-07 00:28:25 +02:00
pkg = import('pkgconfig')
2022-07-06 14:38:12 +02:00
compiler = meson.get_compiler('c')
vapidir = meson.project_source_root() / 'vapi'
is_windows = false
ws = '/'
if compiler.has_header('windows.h')
ws = '\\\\'
is_windows = true
endif
config_h = configure_file (
output : 'config.h',
configuration : {
'WS': f'"@ws@"',
},
)
owlpath_deps = [
dependency('glib-2.0'),
dependency('gio-2.0'),
meson.get_compiler('vala').find_library('config', dirs : vapidir),
]
sources = [
'src/owlpath.vala',
]
owlpath_lib = library('owlpath',
sources,
dependencies : owlpath_deps,
install : true,
install_dir: [true, true, true],
)
2022-07-07 00:28:25 +02:00
pkg.generate(owlpath_lib)
2022-07-06 14:38:12 +02:00
2022-07-07 00:28:25 +02:00
owlpath_test = executable('owlpath-test',
2022-07-06 14:38:12 +02:00
['test/00-owlpath.test.vala'],
dependencies : owlpath_deps,
link_with: [owlpath_lib]
)
2022-07-07 00:28:25 +02:00
test ('owlpath', owlpath_test )