2020-11-25 18:06:37 +08:00
|
|
|
project('libvhost-user', 'c',
|
|
|
|
license: 'GPL-2.0-or-later',
|
|
|
|
default_options: ['c_std=gnu99'])
|
|
|
|
|
2021-01-14 20:56:03 +08:00
|
|
|
threads = dependency('threads')
|
2020-11-25 18:06:37 +08:00
|
|
|
glib = dependency('glib-2.0')
|
|
|
|
|
|
|
|
vhost_user = static_library('vhost-user',
|
|
|
|
files('libvhost-user.c'),
|
2021-01-14 20:56:03 +08:00
|
|
|
dependencies: threads,
|
2020-11-25 18:06:37 +08:00
|
|
|
c_args: '-D_GNU_SOURCE')
|
|
|
|
|
2020-11-25 18:06:39 +08:00
|
|
|
executable('link-test', files('link-test.c'),
|
2021-05-05 23:13:12 +08:00
|
|
|
link_whole: vhost_user)
|
2020-11-25 18:06:39 +08:00
|
|
|
|
2020-11-25 18:06:37 +08:00
|
|
|
vhost_user_glib = static_library('vhost-user-glib',
|
|
|
|
files('libvhost-user-glib.c'),
|
|
|
|
link_with: vhost_user,
|
|
|
|
dependencies: glib)
|
|
|
|
|
|
|
|
vhost_user_dep = declare_dependency(link_with: vhost_user_glib,
|
2021-01-14 20:56:03 +08:00
|
|
|
dependencies: glib,
|
2020-11-25 18:06:37 +08:00
|
|
|
include_directories: include_directories('.'))
|