wok-current diff texinfo/stuff/texinfo_glibc2.34.patch @ rev 25788

Mass update to fix build with gcc10 and up others packages
author Stanislas Leduc <shann@slitaz.org>
date Tue Sep 30 07:43:04 2025 +0000 (3 weeks ago)
parents
children
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/texinfo/stuff/texinfo_glibc2.34.patch	Tue Sep 30 07:43:04 2025 +0000
     1.3 @@ -0,0 +1,187 @@
     1.4 +
     1.5 +Patch by Vitezslav Crhonek <vcrhonek@redhat.com>
     1.6 +Source: https://src.fedoraproject.org/rpms/texinfo/c/9b2cca4817fa4bd8d520fed05e9560fc7183dcdf?branch=rawhide
     1.7 +
     1.8 +diff -up texinfo-6.8/gnulib/lib/cdefs.h.orig texinfo-6.8/gnulib/lib/cdefs.h
     1.9 +--- texinfo-6.8/gnulib/lib/cdefs.h.orig	2021-03-11 19:57:53.000000000 +0100
    1.10 ++++ texinfo-6.8/gnulib/lib/cdefs.h	2021-07-19 12:26:46.985176475 +0200
    1.11 +@@ -321,15 +321,15 @@
    1.12 + 
    1.13 + /* The nonnull function attribute marks pointer parameters that
    1.14 +    must not be NULL.  */
    1.15 +-#ifndef __attribute_nonnull__
    1.16 ++#ifndef __nonnull
    1.17 + # if __GNUC_PREREQ (3,3) || __glibc_has_attribute (__nonnull__)
    1.18 +-#  define __attribute_nonnull__(params) __attribute__ ((__nonnull__ params))
    1.19 ++#  define __nonnull(params) __attribute__ ((__nonnull__ params))
    1.20 + # else
    1.21 +-#  define __attribute_nonnull__(params)
    1.22 ++#  define __nonnull(params)
    1.23 + # endif
    1.24 +-#endif
    1.25 +-#ifndef __nonnull
    1.26 +-# define __nonnull(params) __attribute_nonnull__ (params)
    1.27 ++#elif !defined __GLIBC__
    1.28 ++# undef __nonnull
    1.29 ++# define __nonnull(params) _GL_ATTRIBUTE_NONNULL (params)
    1.30 + #endif
    1.31 + 
    1.32 + /* If fortification mode, we warn about unused results of certain
    1.33 +diff -up texinfo-6.8/gnulib/lib/libc-config.h.orig texinfo-6.8/gnulib/lib/libc-config.h
    1.34 +--- texinfo-6.8/gnulib/lib/libc-config.h.orig	2021-03-11 19:57:54.000000000 +0100
    1.35 ++++ texinfo-6.8/gnulib/lib/libc-config.h	2021-07-19 12:27:58.810590975 +0200
    1.36 +@@ -33,9 +33,9 @@
    1.37 + #include <config.h>
    1.38 + 
    1.39 + /* On glibc this includes <features.h> and <sys/cdefs.h> and #defines
    1.40 +-   _FEATURES_H, __WORDSIZE, and __set_errno.  On FreeBSD 11 and
    1.41 +-   DragonFlyBSD 5.9 it includes <sys/cdefs.h> which defines __nonnull.
    1.42 +-   Elsewhere it is harmless.  */
    1.43 ++   _FEATURES_H, __WORDSIZE, and __set_errno.  On FreeBSD 11 it
    1.44 ++   includes <sys/cdefs.h> which defines __nonnull.  Elsewhere it
    1.45 ++   is harmless.  */
    1.46 + #include <errno.h>
    1.47 + 
    1.48 + /* From glibc <errno.h>.  */
    1.49 +diff -up texinfo-6.8/gnulib/lib/malloc/dynarray-skeleton.c.orig texinfo-6.8/gnulib/lib/malloc/dynarray-skeleton.c
    1.50 +--- texinfo-6.8/gnulib/lib/malloc/dynarray-skeleton.c.orig	2021-03-11 19:57:54.000000000 +0100
    1.51 ++++ texinfo-6.8/gnulib/lib/malloc/dynarray-skeleton.c	2021-07-19 12:24:46.878419397 +0200
    1.52 +@@ -192,7 +192,7 @@ DYNARRAY_NAME (free__array__) (struct DY
    1.53 + 
    1.54 + /* Initialize a dynamic array object.  This must be called before any
    1.55 +    use of the object.  */
    1.56 +-__attribute_nonnull__ ((1))
    1.57 ++__nonnull ((1))
    1.58 + static void
    1.59 + DYNARRAY_NAME (init) (struct DYNARRAY_STRUCT *list)
    1.60 + {
    1.61 +@@ -202,7 +202,7 @@ DYNARRAY_NAME (init) (struct DYNARRAY_ST
    1.62 + }
    1.63 + 
    1.64 + /* Deallocate the dynamic array and its elements.  */
    1.65 +-__attribute_maybe_unused__ __attribute_nonnull__ ((1))
    1.66 ++__attribute_maybe_unused__ __nonnull ((1))
    1.67 + static void
    1.68 + DYNARRAY_FREE (struct DYNARRAY_STRUCT *list)
    1.69 + {
    1.70 +@@ -213,7 +213,7 @@ DYNARRAY_FREE (struct DYNARRAY_STRUCT *l
    1.71 + }
    1.72 + 
    1.73 + /* Return true if the dynamic array is in an error state.  */
    1.74 +-__attribute_nonnull__ ((1))
    1.75 ++__nonnull ((1))
    1.76 + static inline bool
    1.77 + DYNARRAY_NAME (has_failed) (const struct DYNARRAY_STRUCT *list)
    1.78 + {
    1.79 +@@ -222,7 +222,7 @@ DYNARRAY_NAME (has_failed) (const struct
    1.80 + 
    1.81 + /* Mark the dynamic array as failed.  All elements are deallocated as
    1.82 +    a side effect.  */
    1.83 +-__attribute_nonnull__ ((1))
    1.84 ++__nonnull ((1))
    1.85 + static void
    1.86 + DYNARRAY_NAME (mark_failed) (struct DYNARRAY_STRUCT *list)
    1.87 + {
    1.88 +@@ -236,7 +236,7 @@ DYNARRAY_NAME (mark_failed) (struct DYNA
    1.89 + 
    1.90 + /* Return the number of elements which have been added to the dynamic
    1.91 +    array.  */
    1.92 +-__attribute_nonnull__ ((1))
    1.93 ++__nonnull ((1))
    1.94 + static inline size_t
    1.95 + DYNARRAY_NAME (size) (const struct DYNARRAY_STRUCT *list)
    1.96 + {
    1.97 +@@ -245,7 +245,7 @@ DYNARRAY_NAME (size) (const struct DYNAR
    1.98 + 
    1.99 + /* Return a pointer to the array element at INDEX.  Terminate the
   1.100 +    process if INDEX is out of bounds.  */
   1.101 +-__attribute_nonnull__ ((1))
   1.102 ++__nonnull ((1))
   1.103 + static inline DYNARRAY_ELEMENT *
   1.104 + DYNARRAY_NAME (at) (struct DYNARRAY_STRUCT *list, size_t index)
   1.105 + {
   1.106 +@@ -257,7 +257,7 @@ DYNARRAY_NAME (at) (struct DYNARRAY_STRU
   1.107 + /* Return a pointer to the first array element, if any.  For a
   1.108 +    zero-length array, the pointer can be NULL even though the dynamic
   1.109 +    array has not entered the failure state.  */
   1.110 +-__attribute_nonnull__ ((1))
   1.111 ++__nonnull ((1))
   1.112 + static inline DYNARRAY_ELEMENT *
   1.113 + DYNARRAY_NAME (begin) (struct DYNARRAY_STRUCT *list)
   1.114 + {
   1.115 +@@ -267,7 +267,7 @@ DYNARRAY_NAME (begin) (struct DYNARRAY_S
   1.116 + /* Return a pointer one element past the last array element.  For a
   1.117 +    zero-length array, the pointer can be NULL even though the dynamic
   1.118 +    array has not entered the failure state.  */
   1.119 +-__attribute_nonnull__ ((1))
   1.120 ++__nonnull ((1))
   1.121 + static inline DYNARRAY_ELEMENT *
   1.122 + DYNARRAY_NAME (end) (struct DYNARRAY_STRUCT *list)
   1.123 + {
   1.124 +@@ -294,7 +294,7 @@ DYNARRAY_NAME (add__) (struct DYNARRAY_S
   1.125 + /* Add ITEM at the end of the array, enlarging it by one element.
   1.126 +    Mark *LIST as failed if the dynamic array allocation size cannot be
   1.127 +    increased.  */
   1.128 +-__attribute_nonnull__ ((1))
   1.129 ++__nonnull ((1))
   1.130 + static inline void
   1.131 + DYNARRAY_NAME (add) (struct DYNARRAY_STRUCT *list, DYNARRAY_ELEMENT item)
   1.132 + {
   1.133 +@@ -348,8 +348,7 @@ DYNARRAY_NAME (emplace__) (struct DYNARR
   1.134 + /* Allocate a place for a new element in *LIST and return a pointer to
   1.135 +    it.  The pointer can be NULL if the dynamic array cannot be
   1.136 +    enlarged due to a memory allocation failure.  */
   1.137 +-__attribute_maybe_unused__ __attribute_warn_unused_result__
   1.138 +-__attribute_nonnull__ ((1))
   1.139 ++__attribute_maybe_unused__ __attribute_warn_unused_result__ __nonnull ((1))
   1.140 + static
   1.141 + /* Avoid inlining with the larger initialization code.  */
   1.142 + #if !(defined (DYNARRAY_ELEMENT_INIT) || defined (DYNARRAY_ELEMENT_FREE))
   1.143 +@@ -373,7 +372,7 @@ DYNARRAY_NAME (emplace) (struct DYNARRAY
   1.144 +    existing size, new elements are added (which can be initialized).
   1.145 +    Otherwise, the list is truncated, and elements are freed.  Return
   1.146 +    false on memory allocation failure (and mark *LIST as failed).  */
   1.147 +-__attribute_maybe_unused__ __attribute_nonnull__ ((1))
   1.148 ++__attribute_maybe_unused__ __nonnull ((1))
   1.149 + static bool
   1.150 + DYNARRAY_NAME (resize) (struct DYNARRAY_STRUCT *list, size_t size)
   1.151 + {
   1.152 +@@ -418,7 +417,7 @@ DYNARRAY_NAME (resize) (struct DYNARRAY_
   1.153 + }
   1.154 + 
   1.155 + /* Remove the last element of LIST if it is present.  */
   1.156 +-__attribute_maybe_unused__ __attribute_nonnull__ ((1))
   1.157 ++__attribute_maybe_unused__ __nonnull ((1))
   1.158 + static void
   1.159 + DYNARRAY_NAME (remove_last) (struct DYNARRAY_STRUCT *list)
   1.160 + {
   1.161 +@@ -435,7 +434,7 @@ DYNARRAY_NAME (remove_last) (struct DYNA
   1.162 + 
   1.163 + /* Remove all elements from the list.  The elements are freed, but the
   1.164 +    list itself is not.  */
   1.165 +-__attribute_maybe_unused__ __attribute_nonnull__ ((1))
   1.166 ++__attribute_maybe_unused__ __nonnull ((1))
   1.167 + static void
   1.168 + DYNARRAY_NAME (clear) (struct DYNARRAY_STRUCT *list)
   1.169 + {
   1.170 +@@ -453,8 +452,7 @@ DYNARRAY_NAME (clear) (struct DYNARRAY_S
   1.171 +    stored in *RESULT if LIST refers to an empty list.  On success, the
   1.172 +    pointer in *RESULT is heap-allocated and must be deallocated using
   1.173 +    free.  */
   1.174 +-__attribute_maybe_unused__ __attribute_warn_unused_result__
   1.175 +-__attribute_nonnull__ ((1, 2))
   1.176 ++__attribute_maybe_unused__ __attribute_warn_unused_result__ __nonnull ((1, 2))
   1.177 + static bool
   1.178 + DYNARRAY_NAME (finalize) (struct DYNARRAY_STRUCT *list,
   1.179 +                           DYNARRAY_FINAL_TYPE *result)
   1.180 +@@ -485,8 +483,7 @@ DYNARRAY_NAME (finalize) (struct DYNARRA
   1.181 +    have a sentinel at the end).  If LENGTHP is not NULL, the array
   1.182 +    length is written to *LENGTHP.  *LIST is re-initialized and can be
   1.183 +    reused.  */
   1.184 +-__attribute_maybe_unused__ __attribute_warn_unused_result__
   1.185 +-__attribute_nonnull__ ((1))
   1.186 ++__attribute_maybe_unused__ __attribute_warn_unused_result__ __nonnull ((1))
   1.187 + static DYNARRAY_ELEMENT *
   1.188 + DYNARRAY_NAME (finalize) (struct DYNARRAY_STRUCT *list, size_t *lengthp)
   1.189 + {
   1.190 +