[tracker-miners: 1/5] build: Add feature options for all external deps
- From: Sam Thursfield <sthursfield src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker-miners: 1/5] build: Add feature options for all external deps
- Date: Sun, 17 Feb 2019 14:21:57 +0000 (UTC)
commit db824e0e1fd73aef96c8b0c10ec1563369f5c5bc
Author: Mart Raudsepp <leio gentoo org>
Date: Fri Feb 15 00:15:08 2019 +0200
build: Add feature options for all external deps
Automagic dependencies are bad for distributions. Add feature options
for all of them that didn't have it before. If no options are specified,
the behavior matches with before, but now it's possible to specify
exactly what is linked to and what isn't.
Fixes: #39
meson.build | 36 ++++++++++++++++++------------------
meson_options.txt | 37 +++++++++++++++++++++++++++++++++++++
2 files changed, 55 insertions(+), 18 deletions(-)
---
diff --git a/meson.build b/meson.build
index ef48e77a6..af535329f 100644
--- a/meson.build
+++ b/meson.build
@@ -61,9 +61,9 @@ avcodec = dependency('libavcodec', version: '>= 0.8.4', required: false)
avformat = dependency('libavformat', version: '>= 0.8.4', required: false)
avutil = dependency('libavutil', version: '>= 0.8.4', required: false)
dbus = dependency('dbus-1', version: '> 1.3.1')
-exempi = dependency('exempi-2.0', version: '> 2.1.0', required: false)
-flac = dependency('flac', version: '> 1.2.1', required: false)
-gexiv2 = dependency('gexiv2', required: false)
+exempi = dependency('exempi-2.0', version: '> 2.1.0', required: get_option('xmp'))
+flac = dependency('flac', version: '> 1.2.1', required: get_option('flac'))
+gexiv2 = dependency('gexiv2', required: get_option('raw'))
gio = dependency('gio-2.0', version: '>' + glib_required)
gio_unix = dependency('gio-unix-2.0', version: '>' + glib_required)
glib = dependency('glib-2.0', version: '>' + glib_required)
@@ -76,25 +76,25 @@ gupnp_dlna = dependency('gupnp-dlna-2.0', version: '> 0.9.4', required: false)
gupnp_dlna_gst = dependency('gupnp-dlna-gst-2.0', version: '> 0.9.4', required: false)
icu_i18n = dependency('icu-i18n', version: '> 4.8.1.1', required: false)
icu_uc = dependency('icu-uc', version: '> 4.8.1.1', required: false)
-libcue = dependency('libcue', required: false)
-libexif = dependency('libexif', version: '> 0.6', required: false)
-libgsf = dependency('libgsf-1', version: '> 1.14.24', required: false)
-libgxps = dependency('libgxps', required: false)
-libiptcdata = dependency('libiptcdata', required: false)
-libjpeg = dependency('libjpeg', required: false)
-libosinfo = dependency('libosinfo-1.0', version: '> 0.2.9', required: false)
-libpng = dependency('libpng', version: '> 0.89', required: false)
+libcue = dependency('libcue', required: get_option('cue'))
+libexif = dependency('libexif', version: '> 0.6', required: get_option('exif'))
+libgsf = dependency('libgsf-1', version: '> 1.14.24', required: get_option('gsf'))
+libgxps = dependency('libgxps', required: get_option('xps'))
+libiptcdata = dependency('libiptcdata', required: get_option('iptc'))
+libjpeg = dependency('libjpeg', required: get_option('jpeg'))
+libosinfo = dependency('libosinfo-1.0', version: '> 0.2.9', required: get_option('iso'))
+libpng = dependency('libpng', version: '> 0.89', required: get_option('png'))
libseccomp = dependency('libseccomp', version: '>= 2.0', required: false)
-libtiff = dependency('libtiff-4', required: false)
-libxml2 = dependency('libxml-2.0', version: '> 2.6')
-libvorbis = dependency('vorbisfile', version: '> 0.22')
-poppler = dependency('poppler-glib', version: '> 0.16.0', required: false)
-taglib = dependency('taglib_c', version: '> 1.6', required: false)
-totem_plparser = dependency('totem-plparser', required: false)
+libtiff = dependency('libtiff-4', required: get_option('tiff'))
+libxml2 = dependency('libxml-2.0', version: '> 2.6', required: get_option('xml'))
+libvorbis = dependency('vorbisfile', version: '> 0.22', required: get_option('vorbis'))
+poppler = dependency('poppler-glib', version: '> 0.16.0', required: get_option('pdf'))
+taglib = dependency('taglib_c', version: '> 1.6', required: get_option('taglib'))
+totem_plparser = dependency('totem-plparser', required: get_option('playlist'))
upower = dependency('upower-glib', version: '> 0.9.0', required: false)
zlib = dependency('zlib')
-libgif = cc.find_library('gif', required: false)
+libgif = cc.find_library('gif', required: get_option('gif'))
libmath = cc.find_library('m', required: false)
# FIXME: here we work around a quirk todo with Meson and Vala: the 'uuid'
diff --git a/meson_options.txt b/meson_options.txt
index 04120b12e..77c56e1ef 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -33,6 +33,43 @@ option('text', type: 'boolean', value: 'true',
option('unzip_ps_gz_files', type: 'boolean', value: 'true',
description: 'Enable extractor for PS.GZ metadata')
+option('cue', type: 'feature', value: 'auto',
+ description: 'Support cue sheet parsing')
+option('exif', type: 'feature', value: 'auto',
+ description: 'Support EXIF metadata')
+option('flac', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from Flac audio')
+option('gif', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from GIF images')
+option('gsf', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from MS & Open Office documents')
+option('iptc', type: 'feature', value: 'auto',
+ description: 'Support IPTC photo metadata')
+option('iso', type: 'feature', value: 'auto',
+ description: 'Support ISO image parsing')
+option('jpeg', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from JPEG images')
+option('pdf', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from PDF documents')
+option('playlist', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from playlists (w/ Totem)')
+option('png', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from PNG images')
+option('raw', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from RAW photos')
+option('taglib', type: 'feature', value: 'auto',
+ description: 'Support writeback for audio files using Taglib')
+option('tiff', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from TIFF images')
+option('vorbis', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from Vorbis (ogg/etc) files')
+option('xml', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from XML and HTML documents')
+option('xmp', type: 'feature', value: 'auto',
+ description: 'Support XMP metadata')
+option('xps', type: 'feature', value: 'auto',
+ description: 'Support extracting metadata from XPS documents')
+
option('battery_detection', type: 'combo', choices: ['auto', 'hal', 'upower', 'none'], value: 'auto',
description: 'Enable upower or HAL for battery/mains power detection')
option('charset_detection', type: 'combo', choices: ['auto', 'enca', 'icu', 'none'], value: 'auto',
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]