Codebase list texinfo / 6037e28
Add patch texinfo-6.8-undo-gnulib-nonnul.patch. Hilmar Preuße 2 years ago
3 changed file(s) with 187 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
0 texinfo (6.8-4) UNRELEASED; urgency=medium
1
2 * Add patch texinfo-6.8-undo-gnulib-nonnul.patch to fix build
3 failure w/ glibc 2.34 (Closes: #1003483).
4
5 -- Hilmar Preusse <hille42@web.de> Tue, 11 Jan 2022 00:09:37 +0100
6
07 texinfo (6.8-3) unstable; urgency=high
18
29 * Cherry pick patch "Add missing option value 'single'."
44 #enable-xs-parser
55 upstream-c0666e580a-fix-makeinfo-dash-input
66 13a8894fe2faa45b04033d7122a8fe7939ce6aa2
7 texinfo-6.8-undo-gnulib-nonnul.patch
0 --- texinfo.orig/gnulib/lib/cdefs.h
1 +++ texinfo/gnulib/lib/cdefs.h
2 @@ -321,15 +321,15 @@
3
4 /* The nonnull function attribute marks pointer parameters that
5 must not be NULL. */
6 -#ifndef __attribute_nonnull__
7 +#ifndef __nonnull
8 # if __GNUC_PREREQ (3,3) || __glibc_has_attribute (__nonnull__)
9 -# define __attribute_nonnull__(params) __attribute__ ((__nonnull__ params))
10 +# define __nonnull(params) __attribute__ ((__nonnull__ params))
11 # else
12 -# define __attribute_nonnull__(params)
13 +# define __nonnull(params)
14 # endif
15 -#endif
16 -#ifndef __nonnull
17 -# define __nonnull(params) __attribute_nonnull__ (params)
18 +#elif !defined __GLIBC__
19 +# undef __nonnull
20 +# define __nonnull(params) _GL_ATTRIBUTE_NONNULL (params)
21 #endif
22
23 /* If fortification mode, we warn about unused results of certain
24 --- texinfo.orig/gnulib/lib/libc-config.h
25 +++ texinfo/gnulib/lib/libc-config.h
26 @@ -33,9 +33,9 @@
27 #include <config.h>
28
29 /* On glibc this includes <features.h> and <sys/cdefs.h> and #defines
30 - _FEATURES_H, __WORDSIZE, and __set_errno. On FreeBSD 11 and
31 - DragonFlyBSD 5.9 it includes <sys/cdefs.h> which defines __nonnull.
32 - Elsewhere it is harmless. */
33 + _FEATURES_H, __WORDSIZE, and __set_errno. On FreeBSD 11 it
34 + includes <sys/cdefs.h> which defines __nonnull. Elsewhere it
35 + is harmless. */
36 #include <errno.h>
37
38 /* From glibc <errno.h>. */
39 --- texinfo.orig/gnulib/lib/malloc/dynarray-skeleton.c
40 +++ texinfo/gnulib/lib/malloc/dynarray-skeleton.c
41 @@ -192,7 +192,7 @@
42
43 /* Initialize a dynamic array object. This must be called before any
44 use of the object. */
45 -__attribute_nonnull__ ((1))
46 +__nonnull ((1))
47 static void
48 DYNARRAY_NAME (init) (struct DYNARRAY_STRUCT *list)
49 {
50 @@ -202,7 +202,7 @@
51 }
52
53 /* Deallocate the dynamic array and its elements. */
54 -__attribute_maybe_unused__ __attribute_nonnull__ ((1))
55 +__attribute_maybe_unused__ __nonnull ((1))
56 static void
57 DYNARRAY_FREE (struct DYNARRAY_STRUCT *list)
58 {
59 @@ -213,7 +213,7 @@
60 }
61
62 /* Return true if the dynamic array is in an error state. */
63 -__attribute_nonnull__ ((1))
64 +__nonnull ((1))
65 static inline bool
66 DYNARRAY_NAME (has_failed) (const struct DYNARRAY_STRUCT *list)
67 {
68 @@ -222,7 +222,7 @@
69
70 /* Mark the dynamic array as failed. All elements are deallocated as
71 a side effect. */
72 -__attribute_nonnull__ ((1))
73 +__nonnull ((1))
74 static void
75 DYNARRAY_NAME (mark_failed) (struct DYNARRAY_STRUCT *list)
76 {
77 @@ -236,7 +236,7 @@
78
79 /* Return the number of elements which have been added to the dynamic
80 array. */
81 -__attribute_nonnull__ ((1))
82 +__nonnull ((1))
83 static inline size_t
84 DYNARRAY_NAME (size) (const struct DYNARRAY_STRUCT *list)
85 {
86 @@ -245,7 +245,7 @@
87
88 /* Return a pointer to the array element at INDEX. Terminate the
89 process if INDEX is out of bounds. */
90 -__attribute_nonnull__ ((1))
91 +__nonnull ((1))
92 static inline DYNARRAY_ELEMENT *
93 DYNARRAY_NAME (at) (struct DYNARRAY_STRUCT *list, size_t index)
94 {
95 @@ -257,7 +257,7 @@
96 /* Return a pointer to the first array element, if any. For a
97 zero-length array, the pointer can be NULL even though the dynamic
98 array has not entered the failure state. */
99 -__attribute_nonnull__ ((1))
100 +__nonnull ((1))
101 static inline DYNARRAY_ELEMENT *
102 DYNARRAY_NAME (begin) (struct DYNARRAY_STRUCT *list)
103 {
104 @@ -267,7 +267,7 @@
105 /* Return a pointer one element past the last array element. For a
106 zero-length array, the pointer can be NULL even though the dynamic
107 array has not entered the failure state. */
108 -__attribute_nonnull__ ((1))
109 +__nonnull ((1))
110 static inline DYNARRAY_ELEMENT *
111 DYNARRAY_NAME (end) (struct DYNARRAY_STRUCT *list)
112 {
113 @@ -294,7 +294,7 @@
114 /* Add ITEM at the end of the array, enlarging it by one element.
115 Mark *LIST as failed if the dynamic array allocation size cannot be
116 increased. */
117 -__attribute_nonnull__ ((1))
118 +__nonnull ((1))
119 static inline void
120 DYNARRAY_NAME (add) (struct DYNARRAY_STRUCT *list, DYNARRAY_ELEMENT item)
121 {
122 @@ -348,8 +348,7 @@
123 /* Allocate a place for a new element in *LIST and return a pointer to
124 it. The pointer can be NULL if the dynamic array cannot be
125 enlarged due to a memory allocation failure. */
126 -__attribute_maybe_unused__ __attribute_warn_unused_result__
127 -__attribute_nonnull__ ((1))
128 +__attribute_maybe_unused__ __attribute_warn_unused_result__ __nonnull ((1))
129 static
130 /* Avoid inlining with the larger initialization code. */
131 #if !(defined (DYNARRAY_ELEMENT_INIT) || defined (DYNARRAY_ELEMENT_FREE))
132 @@ -373,7 +372,7 @@
133 existing size, new elements are added (which can be initialized).
134 Otherwise, the list is truncated, and elements are freed. Return
135 false on memory allocation failure (and mark *LIST as failed). */
136 -__attribute_maybe_unused__ __attribute_nonnull__ ((1))
137 +__attribute_maybe_unused__ __nonnull ((1))
138 static bool
139 DYNARRAY_NAME (resize) (struct DYNARRAY_STRUCT *list, size_t size)
140 {
141 @@ -418,7 +417,7 @@
142 }
143
144 /* Remove the last element of LIST if it is present. */
145 -__attribute_maybe_unused__ __attribute_nonnull__ ((1))
146 +__attribute_maybe_unused__ __nonnull ((1))
147 static void
148 DYNARRAY_NAME (remove_last) (struct DYNARRAY_STRUCT *list)
149 {
150 @@ -435,7 +434,7 @@
151
152 /* Remove all elements from the list. The elements are freed, but the
153 list itself is not. */
154 -__attribute_maybe_unused__ __attribute_nonnull__ ((1))
155 +__attribute_maybe_unused__ __nonnull ((1))
156 static void
157 DYNARRAY_NAME (clear) (struct DYNARRAY_STRUCT *list)
158 {
159 @@ -453,8 +452,7 @@
160 stored in *RESULT if LIST refers to an empty list. On success, the
161 pointer in *RESULT is heap-allocated and must be deallocated using
162 free. */
163 -__attribute_maybe_unused__ __attribute_warn_unused_result__
164 -__attribute_nonnull__ ((1, 2))
165 +__attribute_maybe_unused__ __attribute_warn_unused_result__ __nonnull ((1, 2))
166 static bool
167 DYNARRAY_NAME (finalize) (struct DYNARRAY_STRUCT *list,
168 DYNARRAY_FINAL_TYPE *result)
169 @@ -485,8 +483,7 @@
170 have a sentinel at the end). If LENGTHP is not NULL, the array
171 length is written to *LENGTHP. *LIST is re-initialized and can be
172 reused. */
173 -__attribute_maybe_unused__ __attribute_warn_unused_result__
174 -__attribute_nonnull__ ((1))
175 +__attribute_maybe_unused__ __attribute_warn_unused_result__ __nonnull ((1))
176 static DYNARRAY_ELEMENT *
177 DYNARRAY_NAME (finalize) (struct DYNARRAY_STRUCT *list, size_t *lengthp)
178 {