Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package babl for openSUSE:Factory checked in at 2021-03-29 18:21:23 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/babl (Old) and /work/SRC/openSUSE:Factory/.babl.new.2401 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "babl" Mon Mar 29 18:21:23 2021 rev:55 rq:880698 version:0.1.86 Changes: -------- --- /work/SRC/openSUSE:Factory/babl/babl.changes 2020-12-30 17:12:16.636824536 +0100 +++ /work/SRC/openSUSE:Factory/.babl.new.2401/babl.changes 2021-03-29 18:21:26.354241461 +0200 @@ -1,0 +2,8 @@ +Tue Mar 16 00:08:54 UTC 2021 - Dirk M??ller <[email protected]> + +- update to 0.1.86: + * input-class (scanner/RGB) ICC profiles are valid for creating RGB spaces. + * improved thread safety for babl_space_from_icc + * build: allow using babl a subproject in other meson projects. + +------------------------------------------------------------------- Old: ---- babl-0.1.84.tar.xz New: ---- babl-0.1.86.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ babl.spec ++++++ --- /var/tmp/diff_new_pack.oCPZ6J/_old 2021-03-29 18:21:27.042242165 +0200 +++ /var/tmp/diff_new_pack.oCPZ6J/_new 2021-03-29 18:21:27.042242165 +0200 @@ -1,7 +1,7 @@ # # spec file for package babl # -# Copyright (c) 2020 SUSE LLC +# Copyright (c) 2021 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -19,10 +19,10 @@ %define debug_package_requires libbabl-0_1-0 = %{version}-%{release} Name: babl -Version: 0.1.84 +Version: 0.1.86 Release: 0 Summary: Dynamic Pixel Format Translation Library -License: LGPL-3.0-or-later AND GPL-3.0-or-later +License: GPL-3.0-or-later AND LGPL-3.0-or-later Group: Development/Libraries/C and C++ URL: http://gegl.org/babl/ ++++++ babl-0.1.84.tar.xz -> babl-0.1.86.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/NEWS new/babl-0.1.86/NEWS --- old/babl-0.1.84/NEWS 2020-12-17 11:32:41.424923000 +0100 +++ new/babl-0.1.86/NEWS 2021-02-26 13:07:12.675609600 +0100 @@ -3,6 +3,11 @@ the news section both in the README and the webpage. --> +2021-02-26 babl-0.1.86 </dt><dd> +input-class (scanner/RGB) ICC profiles are valid for creating RGB spaces. +improved thread safety for babl_space_from_icc +build: allow using babl a subproject in other meson projects. + </dd><dt> 2020-12-17 babl-0.1.84 </dt><dd> Fixed bug in caching of CMYK ICC profiles. </dd><dt> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/babl/babl-fish-reference.c new/babl-0.1.86/babl/babl-fish-reference.c --- old/babl-0.1.84/babl/babl-fish-reference.c 2020-12-17 11:32:41.424923000 +0100 +++ new/babl-0.1.86/babl/babl-fish-reference.c 2021-02-26 13:07:12.679609500 +0100 @@ -358,7 +358,6 @@ src_img->stride[0] = 0; dst_img->data[0] = destination_buf; - dst_img->type[0] = (BablType *) babl_type_from_id (BABL_DOUBLE); dst_img->pitch[0] = destination_fmt->type[0]->bits/8; dst_img->stride[0] = 0; @@ -480,7 +479,6 @@ src_img->stride[0] = 0; dst_img->data[0] = destination_buf; - dst_img->type[0] = (BablType *) babl_type_from_id (BABL_FLOAT); dst_img->pitch[0] = destination_fmt->type[0]->bits/8; dst_img->stride[0] = 0; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/babl/babl-icc.c new/babl-0.1.86/babl/babl-icc.c --- old/babl-0.1.84/babl/babl-icc.c 2020-12-17 11:32:41.428923000 +0100 +++ new/babl-0.1.86/babl/babl-icc.c 2021-02-26 13:07:12.679609500 +0100 @@ -322,6 +322,11 @@ int offset) { sign_t ret; + if (offset < 0 || offset > state->length - 4) + { + for (int i = 0; i < 5; i ++) ret.str[0]=0; + return ret; + } ret.str[0]=icc_read (u8, offset); ret.str[1]=icc_read (u8, offset + 1); ret.str[2]=icc_read (u8, offset + 2); @@ -952,6 +957,8 @@ sign_t profile_class, color_space, pcs; + babl_mutex_lock (babl_space_mutex); + if (!error) error = &int_err; *error = NULL; @@ -968,13 +975,22 @@ { ret = _babl_space_for_lcms (icc_data, icc_length); if (!ret) + { + babl_mutex_unlock (babl_space_mutex); return NULL; + } if (ret->space.icc_type == BablICCTypeCMYK) + { + babl_mutex_unlock (babl_space_mutex); return ret; + } ret->space.icc_length = icc_length; ret->space.icc_profile = malloc (icc_length); if (!ret->space.icc_profile) + { + babl_mutex_unlock (babl_space_mutex); return NULL; + } memcpy (ret->space.icc_profile, icc_data, icc_length); #ifdef HAVE_LCMS @@ -1005,22 +1021,23 @@ cmsCloseProfile (ret->space.cmyk.lcms_profile); // XXX keep it open in case of CMYK to CMYK transforms needed? #endif ret->space.icc_type = BablICCTypeCMYK; + babl_mutex_unlock (babl_space_mutex); return ret; } - if (strcmp (color_space.str, "RGB ") - && strcmp (color_space.str, "GRAY") - ) + if (!(!strcmp (color_space.str, "RGB ")|| + !strcmp (color_space.str, "GRAY"))) { *error = "not defining RGB, CMYK or GRAY space.."; } else - { - if (strcmp (profile_class.str, "mntr")) - *error = "not a monitor-class profile"; - if (!strcmp (color_space.str, "GRAY")) - is_gray = 1; - } + { + if (!(!strcmp (profile_class.str, "mntr")|| + !strcmp (profile_class.str, "scnr"))) + *error = "not a display or input-class profile"; + if (!strcmp (color_space.str, "GRAY")) + is_gray = 1; + } } if (!*error) @@ -1108,6 +1125,7 @@ { babl_free (state); + babl_mutex_unlock (babl_space_mutex); return NULL; } @@ -1125,6 +1143,7 @@ ret->space.icc_profile = malloc (icc_length); memcpy (ret->space.icc_profile, icc_data, icc_length); babl_free (state); + babl_mutex_unlock (babl_space_mutex); return ret; @@ -1170,6 +1189,7 @@ *error = "Inconsistent ICC profile detected, profile contains both cLUTs and a matrix with swapped primaries, this likely means it is an intentionally inconsistent Argyll profile is in use; this profile is only capable of high accuracy rendering and does not permit acceleration for interactive previews."; fprintf (stderr, "babl ICC warning: %s\n", *error); babl_free (state); + babl_mutex_unlock (babl_space_mutex); return NULL; } } @@ -1179,6 +1199,7 @@ if (ret) { babl_free (state); + babl_mutex_unlock (babl_space_mutex); return ret; } @@ -1191,9 +1212,10 @@ trc_red, trc_green, trc_blue); babl_free (state); - ret->space.icc_length = icc_length; + ret->space.icc_length = icc_length; ret->space.icc_profile = malloc (icc_length); memcpy (ret->space.icc_profile, icc_data, icc_length); + babl_mutex_unlock (babl_space_mutex); return ret; } } @@ -1211,11 +1233,13 @@ if (phosporant != 0) { *error = "unhandled phosporants, please report bug against babl with profile"; + babl_mutex_unlock (babl_space_mutex); return NULL; } if (channels != 3) { *error = "unexpected non 3 count of channels"; + babl_mutex_unlock (babl_space_mutex); return NULL; } @@ -1245,6 +1269,7 @@ ret->space.icc_profile = malloc (icc_length); memcpy (ret->space.icc_profile, icc_data, icc_length); + babl_mutex_unlock (babl_space_mutex); return ret; } } @@ -1252,6 +1277,7 @@ } babl_free (state); + babl_mutex_unlock (babl_space_mutex); return NULL; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/babl/babl-internal.c new/babl-0.1.86/babl/babl-internal.c --- old/babl-0.1.84/babl/babl-internal.c 2020-12-17 11:32:41.428923000 +0100 +++ new/babl-0.1.86/babl/babl-internal.c 2021-02-26 13:07:12.679609500 +0100 @@ -84,6 +84,7 @@ BablMutex *babl_debug_mutex; #endif BablMutex *babl_reference_mutex; +BablMutex *babl_space_mutex; void babl_internal_init (void) @@ -93,6 +94,7 @@ babl_fish_mutex = babl_mutex_new (); babl_format_mutex = babl_mutex_new (); babl_reference_mutex = babl_mutex_new (); + babl_space_mutex = babl_mutex_new (); #if BABL_DEBUG_MEM babl_debug_mutex = babl_mutex_new (); #endif diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/babl/babl-internal.h new/babl-0.1.86/babl/babl-internal.h --- old/babl-0.1.84/babl/babl-internal.h 2020-12-17 11:32:41.428923000 +0100 +++ new/babl-0.1.86/babl/babl-internal.h 2021-02-26 13:07:12.679609500 +0100 @@ -249,6 +249,7 @@ extern BablMutex *babl_format_mutex; extern BablMutex *babl_fish_mutex; extern BablMutex *babl_reference_mutex; +extern BablMutex *babl_space_mutex; #define BABL_DEBUG_MEM 0 #if BABL_DEBUG_MEM diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/babl/git-version.h new/babl-0.1.86/babl/git-version.h --- old/babl-0.1.84/babl/git-version.h 2020-12-17 11:32:41.728925500 +0100 +++ new/babl-0.1.86/babl/git-version.h 2021-02-26 13:07:12.859612200 +0100 @@ -1,6 +1,6 @@ #ifndef __GIT_VERSION_H__ #define __GIT_VERSION_H__ -#define BABL_GIT_VERSION "BABL_0_1_82-3-gff6ac9e" +#define BABL_GIT_VERSION "BABL_0_1_86" #endif /* __GIT_VERSION_H__ */ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/babl/meson.build new/babl-0.1.86/babl/meson.build --- old/babl-0.1.84/babl/meson.build 2020-12-17 11:32:41.440923000 +0100 +++ new/babl-0.1.86/babl/meson.build 2021-02-26 13:07:12.687609700 +0100 @@ -13,10 +13,10 @@ # symbol maps version_script = custom_target('babl.map', - input : meson.source_root() / 'export-symbols', + input : export_symbols_file, output: ['babl.map', 'babl.map.clang'], command: [ - find_program(meson.source_root() / 'gen_babl_map.py'), + find_program(gen_babl_map_file), '@INPUT@', '@OUTPUT0@', ], @@ -76,7 +76,7 @@ command: [ git_bin.path(), 'describe', '--always' ], ) - if env_bin.found() + if env_bin.found() and not meson.is_subproject() meson.add_dist_script( [ 'ninja', 'babl/git-version.h', ], ) @@ -139,19 +139,28 @@ subdir: join_paths(lib_name, 'babl') ) +babl_deps = [math, thread, dl, lcms] +babl_includes = [rootInclude, bablBaseInclude] + babl = library( lib_name, babl_sources, - include_directories: [rootInclude, bablBaseInclude], + include_directories: babl_includes, c_args: babl_c_args, link_whole: babl_base, link_args: babl_link_args, - dependencies: [math, thread, dl, lcms], + dependencies: babl_deps, link_depends: version_script, version: so_version, install: true, ) +libbabl_dep = declare_dependency( + include_directories: babl_includes, + link_with: babl, + dependencies: babl_deps +) + if build_gir # identity filter, so GIR doesn't choke on the Babl type # (since it has the same name as the Babl namespace) @@ -169,7 +178,7 @@ ) if build_vapi - gnome.generate_vapi(lib_name, + babl_vapi = gnome.generate_vapi(lib_name, sources: babl_gir[0], install: true, ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/docs/build_as_meson_subproject.md new/babl-0.1.86/docs/build_as_meson_subproject.md --- old/babl-0.1.84/docs/build_as_meson_subproject.md 1970-01-01 01:00:00.000000000 +0100 +++ new/babl-0.1.86/docs/build_as_meson_subproject.md 2021-02-26 13:07:12.687609700 +0100 @@ -0,0 +1,23 @@ + +Including babl as a meson subproject in your project: + +You create a babl.wrap file inside a folder named 'subprojects' +which contains a way to download the babl source. +See https://mesonbuild.com/Wrap-dependency-system-manual.html. +An example will be: +``` +[wrap-git] +url = https://gitlab.gnome.org/GNOME/babl +revision = master +depth = 1 +``` + +Next, include in your meson.build file something like this: +``` +babl = dependency('babl', fallback: ['babl', 'libbabl_dep']) +``` + +If babl is installed in your system, meson will use that one, +otherwise it will download and build babl. + + diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/docs/meson.build new/babl-0.1.86/docs/meson.build --- old/babl-0.1.84/docs/meson.build 2020-12-17 11:32:41.444923200 +0100 +++ new/babl-0.1.86/docs/meson.build 2021-02-26 13:07:12.691609900 +0100 @@ -6,7 +6,7 @@ xml_insert = find_program( - meson.source_root() / 'tools' / 'xml-insert.py', + xml_insert_file, native: true ) @@ -46,9 +46,9 @@ TOC = files('toc') html_files = { 'index': [index_static_html, [ - ['AUTHORS', files(meson.source_root() / 'AUTHORS')], - ['TODO', files(meson.source_root() / 'TODO')], - ['NEWS', files(meson.source_root() / 'NEWS')], + ['AUTHORS', authors_file], + ['TODO', todo_file], + ['NEWS', news_file], ['TOC', TOC], ]], 'Reference': ['auto', [ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/extensions/meson.build new/babl-0.1.86/extensions/meson.build --- old/babl-0.1.84/extensions/meson.build 2020-12-17 11:32:41.448923000 +0100 +++ new/babl-0.1.86/extensions/meson.build 2021-02-26 13:07:12.695609800 +0100 @@ -54,7 +54,7 @@ ] foreach ext : extensions - library( + shared_library( ext[0], ext[0] + '.c', c_args: ext[1], diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/babl-0.1.84/meson.build new/babl-0.1.86/meson.build --- old/babl-0.1.84/meson.build 2020-12-17 11:32:41.452923000 +0100 +++ new/babl-0.1.86/meson.build 2021-02-26 13:07:12.695609800 +0100 @@ -1,6 +1,6 @@ project('babl', 'c', license: 'LGPL3+', - version: '0.1.84', + version: '0.1.86', meson_version: '>=0.54.0', default_options: [ 'buildtype=debugoptimized' @@ -415,6 +415,15 @@ configuration: conf ) +################################################################################ +# Global variables + +xml_insert_file = files('tools' / 'xml-insert.py') +authors_file = files('AUTHORS') +news_file = files('NEWS') +todo_file = files('TODO') +export_symbols_file = files('export-symbols') +gen_babl_map_file = files('gen_babl_map.py') ################################################################################ # Subdirs @@ -447,11 +456,11 @@ # pkg-config file -pkgconfig.generate(filebase: 'babl', +pkgconfig.generate(babl, + filebase: 'babl', name: 'babl', description: 'Pixel encoding and color space conversion engine.', version: meson.project_version(), - libraries: [ babl ], libraries_private: [ '-lm', ],
