Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package ocaml-cairo for openSUSE:Factory checked in at 2021-04-29 01:36:40 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/ocaml-cairo (Old) and /work/SRC/openSUSE:Factory/.ocaml-cairo.new.12324 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ocaml-cairo" Thu Apr 29 01:36:40 2021 rev:3 rq:867924 version:0.6.2 Changes: -------- --- /work/SRC/openSUSE:Factory/ocaml-cairo/ocaml-cairo.changes 2020-03-09 15:22:49.288182694 +0100 +++ /work/SRC/openSUSE:Factory/.ocaml-cairo.new.12324/ocaml-cairo.changes 2021-04-29 01:37:06.286468252 +0200 @@ -1,0 +2,7 @@ +Thu Jan 21 21:21:21 UTC 2021 - oher...@suse.de + +- Update to version 0.6.2 + See included CHANGES.md for details + remove obsolete ocaml-cairo.patch + +------------------------------------------------------------------- Old: ---- ocaml-cairo-0.6.1.tar.xz ocaml-cairo.patch New: ---- ocaml-cairo-0.6.2.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ ocaml-cairo.spec ++++++ --- /var/tmp/diff_new_pack.Tl9bev/_old 2021-04-29 01:37:06.682468814 +0200 +++ /var/tmp/diff_new_pack.Tl9bev/_new 2021-04-29 01:37:06.686468819 +0200 @@ -1,7 +1,7 @@ # # spec file for package ocaml-cairo # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# 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 @@ -17,23 +17,22 @@ Name: ocaml-cairo -Version: 0.6.1 +Version: 0.6.2 Release: 0 Summary: Binding to Cairo, a 2D Vector Graphics Library. -License: LGPL-3.0+ +License: LGPL-3.0-or-later Group: Development/Languages/OCaml -Url: https://github.com/Chris00/ocaml-cairo +URL: https://opam.ocaml.org/packages/cairo2 Source: %{name}-%{version}.tar.xz -Patch0: ocaml-cairo.patch BuildRequires: ocaml BuildRequires: ocaml-dune -BuildRequires: ocaml-rpm-macros >= 20200220 +BuildRequires: ocaml-rpm-macros >= 20210121 +BuildRequires: pkg-config BuildRequires: ocamlfind(bigarray) -BuildRequires: ocamlfind(dune.configurator) +BuildRequires: ocamlfind(dune-configurator) BuildRequires: ocamlfind(lablgtk2) BuildRequires: ocamlfind(str) BuildRequires: ocamlfind(threads) -BuildRequires: pkg-config BuildRequires: pkgconfig(cairo) BuildRequires: pkgconfig(fontconfig) BuildRequires: pkgconfig(freetype2) ++++++ _service ++++++ --- /var/tmp/diff_new_pack.Tl9bev/_old 2021-04-29 01:37:06.710468854 +0200 +++ /var/tmp/diff_new_pack.Tl9bev/_new 2021-04-29 01:37:06.710468854 +0200 @@ -1,11 +1,13 @@ <services> <service name="tar_scm" mode="disabled"> - <param name="url">https://github.com/Chris00/ocaml-cairo.git</param> + <param name="filename">ocaml-cairo</param> + <param name="revision">202674a8d0c533b689ceacdb523ca167611e1b4c</param> <param name="scm">git</param> + <param name="submodules">disable</param> + <param name="url">https://github.com/Chris00/ocaml-cairo.git</param> <param name="versionformat">@PARENT_TAG@</param> - <!-- 0.6.1 --> - <param name="revision">4d96c3ce32a02a36471b4fd413f3536a8d70214f</param> - <param name="filename">ocaml-cairo</param> + <param name="versionrewrite-pattern">[v]?([^\+]+)(.*)</param> + <param name="versionrewrite-replacement">\1</param> </service> <service name="recompress" mode="disabled"> <param name="file">*.tar</param> ++++++ ocaml-cairo-0.6.1.tar.xz -> ocaml-cairo-0.6.2.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/CHANGES.md new/ocaml-cairo-0.6.2/CHANGES.md --- old/ocaml-cairo-0.6.1/CHANGES.md 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/CHANGES.md 2020-11-25 11:41:22.000000000 +0100 @@ -1,3 +1,11 @@ +0.6.2 2020-11-23 +---------------- + +- Fix a memory leak (#19). +- Fix GCC warnings, in particular the ???multiple definition of ?????? (#23). +- Clarify the license. +- Use `dune-configurator`. + 0.6.1 2019-03-20 ---------------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/cairo2-gtk.opam new/ocaml-cairo-0.6.2/cairo2-gtk.opam --- old/ocaml-cairo-0.6.1/cairo2-gtk.opam 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/cairo2-gtk.opam 2020-11-25 11:41:22.000000000 +0100 @@ -2,7 +2,7 @@ maintainer: "Christophe Troestler <christophe.troest...@umons.ac.be>" authors: [ "Christophe Troestler <christophe.troest...@umons.ac.be>" "Pierre Hauweele <pie...@hauweele.net>" ] -license: "LGPL-3.0 with OCaml linking exception" +license: "LGPL-3.0" homepage: "https://github.com/Chris00/ocaml-cairo" dev-repo: "git+https://github.com/Chris00/ocaml-cairo.git" bug-reports: "https://github.com/Chris00/ocaml-cairo/issues" @@ -16,7 +16,7 @@ depends: [ "ocaml" {>= "4.02"} "base-bigarray" - "dune" {build} + "dune" "conf-pkg-config" {build} "conf-cairo" "cairo2" {= version} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/cairo2-pango.opam new/ocaml-cairo-0.6.2/cairo2-pango.opam --- old/ocaml-cairo-0.6.1/cairo2-pango.opam 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/cairo2-pango.opam 2020-11-25 11:41:22.000000000 +0100 @@ -2,7 +2,7 @@ maintainer: "Christophe Troestler <christophe.troest...@umons.ac.be>" authors: [ "Christophe Troestler <christophe.troest...@umons.ac.be>" "Pierre Hauweele <pie...@hauweele.net>" ] -license: "LGPL-3.0 with OCaml linking exception" +license: "LGPL-3.0" homepage: "https://github.com/Chris00/ocaml-cairo" dev-repo: "git+https://github.com/Chris00/ocaml-cairo.git" bug-reports: "https://github.com/Chris00/ocaml-cairo/issues" @@ -16,7 +16,7 @@ depends: [ "ocaml" {>= "4.02"} "base-bigarray" - "dune" {build} + "dune" "conf-pkg-config" {build} "conf-cairo" "cairo2" {= version} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/cairo2.opam new/ocaml-cairo-0.6.2/cairo2.opam --- old/ocaml-cairo-0.6.1/cairo2.opam 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/cairo2.opam 2020-11-25 11:41:22.000000000 +0100 @@ -2,7 +2,7 @@ maintainer: "Christophe Troestler <christophe.troest...@umons.ac.be>" authors: [ "Christophe Troestler <christophe.troest...@umons.ac.be>" "Pierre Hauweele <pie...@hauweele.net>" ] -license: "LGPL-3.0 with OCaml linking exception" +license: "LGPL-3.0" homepage: "https://github.com/Chris00/ocaml-cairo" dev-repo: "git+https://github.com/Chris00/ocaml-cairo.git" bug-reports: "https://github.com/Chris00/ocaml-cairo/issues" @@ -17,7 +17,8 @@ depends: [ "ocaml" {>= "4.02"} "base-bigarray" - "dune" {build} + "dune" + "dune-configurator" "conf-cairo" ] depopts: [ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/config/dune new/ocaml-cairo-0.6.2/config/dune --- old/ocaml-cairo-0.6.1/config/dune 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/config/dune 2020-11-25 11:41:22.000000000 +0100 @@ -2,4 +2,4 @@ (executable (name discover) (modules discover) - (libraries dune.configurator str)) + (libraries dune-configurator str)) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/docs/tutorial.html new/ocaml-cairo-0.6.2/docs/tutorial.html --- old/ocaml-cairo-0.6.1/docs/tutorial.html 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/docs/tutorial.html 2020-11-25 11:41:22.000000000 +0100 @@ -28,7 +28,9 @@ tutorial for python programmers</a> and the <a href="http://cairographics.org/tutorial/">Cairo Tutorial</a>. The original code snippets have been translated to -OCaml, the text has only been changed as much as necessary.<br> +OCaml, the text has only been changed as much as necessary. +This version is released with the permission of Michael Urman +and is licensed under the GLP??v3. </p> <p> In order to follow along on your computer, you need the following diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/dune-project new/ocaml-cairo-0.6.2/dune-project --- old/ocaml-cairo-0.6.1/dune-project 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/dune-project 2020-11-25 11:41:22.000000000 +0100 @@ -1,3 +1,3 @@ -(lang dune 1.1) +(lang dune 1.0) (name cairo2) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/src/cairo_macros.h new/ocaml-cairo-0.6.2/src/cairo_macros.h --- old/ocaml-cairo-0.6.1/src/cairo_macros.h 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/src/cairo_macros.h 2020-11-25 11:41:22.000000000 +0100 @@ -173,7 +173,7 @@ /* holds the pointer to the Unavailable exception; shared several functions. */ -value * caml_cairo_Unavailable = NULL; +const value * caml_cairo_Unavailable; #define RAISE_UNAVAILABLE(name, args ...) \ CAMLexport value caml_##name(args) \ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/src/cairo_ocaml.h.p new/ocaml-cairo-0.6.2/src/cairo_ocaml.h.p --- old/ocaml-cairo-0.6.1/src/cairo_ocaml.h.p 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/src/cairo_ocaml.h.p 2020-11-25 11:41:22.000000000 +0100 @@ -25,7 +25,7 @@ /* cairo_t ***********************************************************************/ #define CAIRO_VAL(v) (* (cairo_t **) Data_custom_val(v)) -struct custom_operations caml_cairo_ops; +extern struct custom_operations caml_cairo_ops; void caml_cairo_raise_Error(cairo_status_t status); /* raise [Cairo.Error] if the status indicates a failure. */ @@ -33,7 +33,7 @@ /* cairo_pattern_t ***********************************************************************/ #define PATTERN_VAL(v) (* (cairo_pattern_t **) Data_custom_val(v)) -struct custom_operations caml_pattern_ops; +extern struct custom_operations caml_pattern_ops; #define EXTEND_VAL(v) ((cairo_extend_t) Int_val(v)) #define VAL_EXTEND(v) Val_int(v) @@ -45,12 +45,12 @@ ***********************************************************************/ #define FONT_OPTIONS_VAL(v) (* (cairo_font_options_t**) Data_custom_val(v)) -struct custom_operations caml_font_options_ops; +extern struct custom_operations caml_font_options_ops; /* cairo_font_type_t ***********************************************************************/ -value caml_cairo_font_type[5]; +extern value caml_cairo_font_type[5]; cairo_font_type_t caml_cairo_font_type_val(value vft); @@ -61,13 +61,13 @@ ***********************************************************************/ #define SCALED_FONT_VAL(v) (* (cairo_scaled_font_t**) Data_custom_val(v)) -struct custom_operations caml_scaled_font_ops; +extern struct custom_operations caml_scaled_font_ops; /* cairo_surface_t ***********************************************************************/ #define SURFACE_VAL(v) (* (cairo_surface_t **) Data_custom_val(v)) -struct custom_operations caml_surface_ops; +extern struct custom_operations caml_surface_ops; /* Type cairo_content_t */ @@ -93,7 +93,7 @@ ***********************************************************************/ #define PATH_VAL(v) (* (cairo_path_t **) Data_custom_val(v)) -struct custom_operations caml_path_ops; +extern struct custom_operations caml_path_ops; #define PATH_DATA_ASSIGN(vdata, data) \ switch (data->header.type) { \ @@ -151,10 +151,10 @@ #include <cairo-ft.h> #define FT_LIBRARY_VAL(v) (* (FT_Library*) Data_custom_val(v)) -struct custom_operations caml_cairo_ft_library_ops; +extern struct custom_operations caml_cairo_ft_library_ops; #define FT_FACE_VAL(v) (* (FT_Face*) Data_custom_val(v)) -struct custom_operations caml_cairo_ft_face_ops; +extern struct custom_operations caml_cairo_ft_face_ops; #endif /* OCAML_CAIRO_HAS_FT */ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/src/cairo_ocaml_types.h new/ocaml-cairo-0.6.2/src/cairo_ocaml_types.h --- old/ocaml-cairo-0.6.1/src/cairo_ocaml_types.h 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/src/cairo_ocaml_types.h 2020-11-25 11:41:22.000000000 +0100 @@ -45,7 +45,7 @@ /* raise [Error] if the status indicates a failure. */ void caml_cairo_raise_Error(cairo_status_t status) { - static value * exn = NULL; + static const value * exn = NULL; if (status != CAIRO_STATUS_SUCCESS) { if (exn == NULL) { @@ -275,8 +275,8 @@ custom_serialize_default, custom_deserialize_default }; +value caml_cairo_font_type[5]; -/* caml_cairo_font_type is defined in "cairo_ocaml.h". */ CAMLexport value caml_cairo_font_type_init(value unit) { /* noalloc */ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/src/cairo_stubs.c new/ocaml-cairo-0.6.2/src/cairo_stubs.c --- old/ocaml-cairo-0.6.1/src/cairo_stubs.c 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/src/cairo_stubs.c 2020-11-25 11:41:22.000000000 +0100 @@ -1494,7 +1494,7 @@ /* Adapted from caml_ba_finalize in the OCaml library sources. */ if (-- proxy->refcount == 0) { free(proxy->data); - caml_stat_free(proxy); + free(proxy); } #undef proxy } @@ -1573,13 +1573,14 @@ if (proxy == NULL) return(CAIRO_STATUS_NO_MEMORY); proxy->refcount = 2; /* original array + surface */ proxy->data = b->data; - proxy->size = 0; /* CAML_BA_MANAGED_MASK excluded by the calling fun */ + proxy->size = 0; /* CAML_BA_MAPPED_FILE excluded by the calling fun */ b->proxy = proxy; } return cairo_surface_set_user_data(surf, &image_bigarray_key, b->proxy, caml_cairo_image_bigarray_finalize); } +#define b (Caml_ba_array_val(vb)) #define SURFACE_CREATE_DATA(name) \ CAMLexport value caml_cairo_image_surface_create_for_##name \ (value vb, value vformat, value vwidth, value vheight, value vstride) \ @@ -1588,7 +1589,6 @@ CAMLlocal1(vsurf); \ cairo_surface_t* surf; \ const int width = Int_val(vwidth); \ - struct caml_ba_array *b = Caml_ba_array_val(vb); \ cairo_status_t status; \ \ if ((b->flags & CAML_BA_MANAGED_MASK) == CAML_BA_MAPPED_FILE) \ @@ -1610,6 +1610,7 @@ SURFACE_CREATE_DATA(data8) SURFACE_CREATE_DATA(data32) +#undef b #define SURFACE_GET_DATA(type, num_dims, dims ...) \ CAMLexport value caml_cairo_image_surface_get_##type(value vsurf) \ @@ -1681,7 +1682,7 @@ CAMLlocal2(s, r); s = caml_alloc_string(length); - memmove(String_val(s), data, length); + memmove((char *) String_val(s), data, length); r = caml_callback_exn(* ((value *) fn), s); if (Is_exception_result(r)) CAMLreturn(CAIRO_STATUS_WRITE_ERROR); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/ocaml-cairo-0.6.1/tests/image_create.ml new/ocaml-cairo-0.6.2/tests/image_create.ml --- old/ocaml-cairo-0.6.1/tests/image_create.ml 2019-03-26 00:10:18.000000000 +0100 +++ new/ocaml-cairo-0.6.2/tests/image_create.ml 2020-11-25 11:41:22.000000000 +0100 @@ -10,6 +10,7 @@ let () = let cr = create() in + printf "With Cairo handle:\n%!"; set_source_rgb cr 1. 1. 1.; rectangle cr 0. 0. ~w:300. ~h:300.; fill cr; @@ -21,9 +22,9 @@ show_text cr "Hello"; Gc.compact(); Gc.compact(); - eprintf "Write image\n%!"; + eprintf "- Write image\n%!"; PNG.write (get_target cr) "test_image.png"; - eprintf "Finish surface\n%!"; + eprintf "- Finish surface\n%!"; Surface.finish (get_target cr); Gc.compact()