From d3420bdd5c2b37ec5fcccbaee449281904d955e3ff028f7529db7679134362fa Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Sun, 15 Aug 2021 17:25:35 +0000 Subject: [PATCH] - Add unbreak-gnulib.diff OBS-URL: https://build.opensuse.org/package/show/devel:tools/cdecl?expand=0&rev=47 --- cdecl.changes | 1 + cdecl.spec | 1 + unbreak-gnulib.diff | 26 ++++++++++++++++++++++++++ 3 files changed, 28 insertions(+) create mode 100644 unbreak-gnulib.diff diff --git a/cdecl.changes b/cdecl.changes index 61e319f..4e3ca87 100644 --- a/cdecl.changes +++ b/cdecl.changes @@ -4,6 +4,7 @@ Sun Aug 15 16:06:00 UTC 2021 - Jan Engelhardt - Update to release 10.3 * Marking functions and conversion operators = delete is now supported. +- Add unbreak-gnulib.diff ------------------------------------------------------------------- Wed Jun 30 16:05:38 UTC 2021 - Jan Engelhardt diff --git a/cdecl.spec b/cdecl.spec index 4fec0c3..8fd2d2b 100644 --- a/cdecl.spec +++ b/cdecl.spec @@ -25,6 +25,7 @@ Group: Development/Languages/C and C++ URL: https://github.com/paul-j-lucas/cdecl/ Source: https://github.com/paul-j-lucas/cdecl/releases/download/cdecl-%version/cdecl-%version.tar.gz +Patch1: unbreak-gnulib.diff BuildRequires: bison BuildRequires: flex BuildRequires: ncurses-devel diff --git a/unbreak-gnulib.diff b/unbreak-gnulib.diff new file mode 100644 index 0000000..092aa00 --- /dev/null +++ b/unbreak-gnulib.diff @@ -0,0 +1,26 @@ +From: Jan Engelhardt +Date: 2021-08-15 19:20:30.942589995 +0200 + +Compiler said _GL_ATTRIBUTE_MALLOC was undefined. +This was a breaking change in gnulib 48ece5c3f2185f52ab8cd73ceac9bd9f0e01eac6. +--- + lib/stdlib.in.h | 6 ++++++ + 1 file changed, 6 insertions(+) + +Index: cdecl-10.3/lib/stdlib.in.h +=================================================================== +--- cdecl-10.3.orig/lib/stdlib.in.h ++++ cdecl-10.3/lib/stdlib.in.h +@@ -108,6 +108,12 @@ struct random_data + # define _GL_ATTRIBUTE_PURE /* empty */ + # endif + #endif ++#ifndef _GL_ATTRIBUTE_MALLOC ++#define _GL_ATTRIBUTE_MALLOC ++#endif ++#ifndef _GL_ATTRIBUTE_DEALLOC_FREE ++#define _GL_ATTRIBUTE_DEALLOC_FREE ++#endif + + /* The definition of _Noreturn is copied here. */ +