From: Ján Veselý Date: Thu, 6 Dec 2018 20:34:51 +0000 (-0500) Subject: meson: Add with-lcms option X-Git-Tag: archive/raspbian/1%0.1.106-3+rpi1^2~15^2~12^2~12^2~1 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=1de7bed3d11cd5521f84340aa65ed4b9d883f626;p=babl.git meson: Add with-lcms option Signed-off-by: Jan Vesely --- diff --git a/babl/meson.build b/babl/meson.build index 77e69a5..240493c 100644 --- a/babl/meson.build +++ b/babl/meson.build @@ -130,7 +130,7 @@ babl = library( cpp_args: [ '-DLIBDIR="' + join_paths(get_option('prefix'), get_option('libdir')) + '"', ], link_whole: [ babl_base, ], link_args: [ babl_link_args, ], - dependencies: [ math, thread, dl, ], + dependencies: [ math, thread, dl, lcms, ], link_depends: [ version_script_target, ], version: so_version, install: true, diff --git a/meson.build b/meson.build index 57a2b9b..f617f15 100644 --- a/meson.build +++ b/meson.build @@ -267,6 +267,15 @@ endif ################################################################################ # Dependencies +# LCMS +with_lcms = get_option('with-lcms') +if with_lcms + lcms = cc.find_library('lcms2', required : true) + if lcms.found() + conf.set('HAVE_LCMS', 1, description: 'Define to 1 if liblcms2 is available') + endif +endif + math = cc.find_library('m', required: false) log = cc.find_library('log', required: false) if platform_win32 diff --git a/meson_options.txt b/meson_options.txt index b2dcc54..ab08ce9 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -5,3 +5,4 @@ option('enable-sse3', type: 'boolean', value: true, description: 'enable SSE3 option('enable-sse4_1', type: 'boolean', value: true, description: 'enable SSE4.1 support') option('enable-f16c', type: 'boolean', value: true, description: 'enable hardware half-float support') option('with-docs', type: 'boolean', value: true, description: 'build website') +option('with-lcms', type: 'boolean', value: true, description: 'build with lcms')