diff options
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 53 |
1 files changed, 42 insertions, 11 deletions
diff --git a/meson.build b/meson.build index 9b33574b..8b0bd404 100644 --- a/meson.build +++ b/meson.build @@ -1,6 +1,6 @@ project('hexchat', 'c', - version: '2.14.3', - meson_version: '>= 0.40.0', + version: '2.16.1', + meson_version: '>= 0.47.0', default_options: [ 'c_std=gnu89', 'buildtype=debugoptimized', @@ -15,12 +15,17 @@ cc = meson.get_compiler('c') libgio_dep = dependency('gio-2.0', version: '>= 2.34.0') libgmodule_dep = dependency('gmodule-2.0') + +libcanberra_dep = dependency('libcanberra', version: '>= 0.22', + required: get_option('libcanberra')) +dbus_glib_dep = dependency('dbus-glib-1', required: get_option('dbus')) + global_deps = [] if cc.get_id() == 'msvc' - libssl_dep = cc.find_library('libeay32') + libssl_dep = cc.find_library('libssl') else libssl_dep = dependency('openssl', version: '>= 0.9.8', - required: get_option('with-ssl')) + required: get_option('tls')) endif config_h = configuration_data() @@ -29,14 +34,14 @@ config_h.set_quoted('PACKAGE_NAME', meson.project_name()) config_h.set_quoted('GETTEXT_PACKAGE', 'hexchat') config_h.set_quoted('LOCALEDIR', join_paths(get_option('prefix'), get_option('datadir'), 'locale')) +config_h.set_quoted('G_LOG_DOMAIN', 'hexchat') config_h.set10('ENABLE_NLS', true) # Optional features -config_h.set('USE_OPENSSL', get_option('with-ssl')) -config_h.set('USE_LIBPROXY', get_option('with-libproxy')) -config_h.set('USE_LIBCANBERRA', get_option('with-libcanberra')) -config_h.set('USE_DBUS', get_option('with-dbus')) -config_h.set('USE_PLUGIN', get_option('with-plugin')) +config_h.set('USE_OPENSSL', libssl_dep.found()) +config_h.set('USE_LIBCANBERRA', libcanberra_dep.found()) +config_h.set('USE_DBUS', dbus_glib_dep.found()) +config_h.set('USE_PLUGIN', get_option('plugin')) config_h.set('G_DISABLE_SINGLE_INCLUDES', true) config_h.set('GTK_DISABLE_DEPRECATED', true) @@ -153,7 +158,7 @@ endforeach add_project_link_arguments(global_ldflags, language: 'c') subdir('src') -if get_option('with-plugin') +if get_option('plugin') subdir('plugins') endif if cc.get_id() != 'msvc' @@ -161,6 +166,32 @@ if cc.get_id() != 'msvc' subdir('po') # FIXME: build xgettext meson.add_install_script('meson_post_install.py', - '@0@'.format(get_option('with-theme-manager')) + '@0@'.format(get_option('theme-manager')) ) endif + +if meson.version().version_compare('>= 0.53.0') + summary({ + 'prefix': get_option('prefix'), + 'bindir': get_option('bindir'), + 'libdir': get_option('libdir'), + 'datadir': get_option('datadir'), + }, section: 'Directories') + + summary({ + 'TLS (openssl)': libssl_dep.found(), + 'Plugin Support': get_option('plugin'), + 'DBus Support': dbus_glib_dep.found(), + 'libcanberra': libcanberra_dep.found(), + }, section: 'Features') + + summary({ + 'Lua': get_option('with-lua'), + 'Python': get_option('with-python'), + 'Perl': get_option('with-perl'), + 'Perl Legacy API': get_option('with-perl-legacy-api'), + 'FiSH': get_option('with-fishlim'), + 'Sysinfo': get_option('with-sysinfo'), + 'DCC Checksum': get_option('with-checksum'), + }, section: 'Plugins') +endif |