glib2.0/gthread/meson.build

43 lines
1.1 KiB
Meson
Raw Normal View History

2022-06-29 16:02:05 +08:00
# Just a skeleton lib for backwards compatibility since all the functionaliy
# has been moved into glib now
gthread_sources = ['gthread-impl.c']
2024-05-23 15:55:40 +08:00
if host_system == 'windows' and glib_build_shared
2022-06-29 16:02:05 +08:00
gthread_win_rc = configure_file(
input: 'gthread.rc.in',
output: 'gthread.rc',
configuration: glibconfig_conf,
)
gthread_win_res = windows.compile_resources(gthread_win_rc)
gthread_sources += [gthread_win_res]
endif
libgthread = library('gthread-2.0',
sources : gthread_sources,
version : library_version,
soversion : soversion,
darwin_versions : darwin_versions,
install : true,
dependencies : [libglib_dep],
2024-02-29 14:32:35 +08:00
c_args : ['-DG_LOG_DOMAIN="GThread"', glib_c_args_internal],
gnu_symbol_visibility : 'hidden',
2022-06-29 16:02:05 +08:00
link_args : glib_link_flags,
)
pkg.generate(libgthread,
libraries : [thread_dep],
requires : ['glib-2.0'],
version : glib_version,
install_dir : glib_pkgconfigreldir,
filebase : 'gthread-2.0',
name : 'GThread',
description : 'Thread support for GLib',
)
libgthread_dep = declare_dependency(link_with : libgthread)
2023-02-14 16:00:02 +08:00
meson.override_dependency('gthread-2.0', libgthread_dep)
2024-02-29 14:32:35 +08:00
if build_tests
subdir('tests')
endif