summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--meson.build4
-rw-r--r--meson_options.txt2
-rw-r--r--src/libtracker-common/meson.build4
3 files changed, 7 insertions, 3 deletions
diff --git a/meson.build b/meson.build
index 36e008447..8a159af50 100644
--- a/meson.build
+++ b/meson.build
@@ -54,8 +54,8 @@ enable_fts = get_option('fts')
have_libstemmer = false
if get_option('stemmer') != 'no'
- stemmer = cc.find_library('stemmer')
- if stemmer.found()
+ libstemmer = cc.find_library('stemmer', required: false)
+ if libstemmer.found()
have_libstemmer = true
elif get_option('stemmer') == 'yes'
error('stemmer support explicitly requested, but stemmer library couldn\'t be found')
diff --git a/meson_options.txt b/meson_options.txt
index 496d35613..05c65c948 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -7,7 +7,7 @@ option('functional_tests', type: 'boolean', value: true,
option('journal', type: 'boolean', value: true,
description: 'Enable database journal backup mechanism')
-option('stemmer', type: 'combo', choices: ['auto', 'no', 'yes'], value: 'no',
+option('stemmer', type: 'combo', choices: ['auto', 'no', 'yes'], value: 'auto',
description: 'Enable stemming words while indexing')
option('unicode_support', type: 'combo', choices: ['icu', 'unistring', 'auto'], value: 'auto',
description: 'Unicode support library to use')
diff --git a/src/libtracker-common/meson.build b/src/libtracker-common/meson.build
index d56d909a7..4e82e6c7e 100644
--- a/src/libtracker-common/meson.build
+++ b/src/libtracker-common/meson.build
@@ -38,6 +38,10 @@ endif
# FIXME: need to link against -lkvm on OpenBSD, see configure.ac
tracker_common_dependencies = [glib, gio, gio_unix, libmath]
+if have_libstemmer
+ tracker_common_dependencies += [libstemmer]
+endif
+
libtracker_common = library('tracker-common',
tracker_common_sources,
dependencies: tracker_common_dependencies + [unicode_library],