diff --git a/config2.h.in b/config2.h.in index 788b8ae1..38331597 100644 --- a/config2.h.in +++ b/config2.h.in @@ -143,6 +143,9 @@ /* Define if you want: libevent support */ #mesondefine CONFIG_LIBEVENT +/* Define if you want: libsixel support */ +#mesondefine CONFIG_LIBSIXEL + /* Define if you want: lzma support */ #mesondefine CONFIG_LZMA diff --git a/meson.build b/meson.build index 1d146132..ea31ebcf 100644 --- a/meson.build +++ b/meson.build @@ -82,6 +82,8 @@ conf_data.set('CONFIG_SCRIPTING_GUILE', get_option('guile')) conf_data.set('CONFIG_SCRIPTING_PERL', get_option('perl')) conf_data.set('CONFIG_SCRIPTING_PYTHON', get_option('python')) +conf_data.set('CONFIG_LIBSIXEL', get_option('libsixel')) + conf_data.set('CONFIG_REPRODUCIBLE', get_option('reproducible')) conf_data.set('SOURCE_DATE_EPOCH', get_option('source-date-epoch')) @@ -537,6 +539,11 @@ if conf_data.get('CONFIG_TERMINFO') deps += terminfodeps endif +if conf_data.get('CONFIG_LIBSIXEL') + sixeldeps = dependency('libsixel', static: st) + deps += sixeldeps +endif + if conf_data.get('CONFIG_OS_DOS') wattdeps = compiler.find_library('watt', static: st, dirs: ['/usr/local/lib']) deps += wattdeps diff --git a/meson_options.txt b/meson_options.txt index 19d9c9dc..2b9dc40f 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -77,3 +77,4 @@ option('apidoc', type: 'boolean', value: true, description: 'whether to generate option('htmldoc', type: 'boolean', value: true, description: 'whether to build html docs') option('pdfdoc', type: 'boolean', value: true, description: 'whether to build manual.pdf') option('libcss', type: 'boolean', value: true, description: 'whether to compile libcss support, requires libdom. This option is automatically enabled with js support') +option('libsixel', type: 'boolean', value: false, description: 'whether to compile libsixel support to show images directly on sixel compatible terminals')