1 |
|
# Copyright 1999-2024 Gentoo Authors
|
|
1 |
# Copyright 1999-2025 Gentoo Authors
|
2 |
2 |
# Distributed under the terms of the GNU General Public License v2
|
3 |
3 |
|
4 |
4 |
EAPI=8
|
... | ... | |
22 |
22 |
"
|
23 |
23 |
|
24 |
24 |
GENTOO_PATCH_DEV=sam
|
25 |
|
GENTOO_PATCH_PV=6.4_p20240413
|
|
25 |
GENTOO_PATCH_PV=6.5_p20241109
|
26 |
26 |
GENTOO_PATCH_NAME=${PN}-${GENTOO_PATCH_PV}-patches
|
27 |
27 |
|
28 |
28 |
# Populated below in a loop. Do not add patches manually here.
|
... | ... | |
43 |
43 |
# This array should contain a list of all the snapshots since the last
|
44 |
44 |
# release if there's no megapatch available yet.
|
45 |
45 |
PATCH_DATES=(
|
46 |
|
20230107
|
47 |
|
20230114
|
48 |
|
20230121
|
49 |
|
20230128
|
50 |
|
20230211
|
51 |
|
20230218
|
52 |
|
20230225
|
53 |
|
20230311
|
54 |
|
20230401
|
55 |
|
20230408
|
56 |
|
20230415
|
57 |
|
20230418
|
58 |
|
20230423
|
59 |
|
20230424
|
60 |
|
20230429
|
61 |
|
20230506
|
62 |
|
20230514
|
63 |
|
20230520
|
64 |
|
20230527
|
65 |
|
20230603
|
66 |
|
20230610
|
67 |
|
20230615
|
68 |
|
20230617
|
69 |
|
20230624
|
70 |
|
20230625
|
71 |
|
20230701
|
72 |
|
20230708
|
73 |
|
20230715
|
74 |
|
20230722
|
75 |
|
20230729
|
76 |
|
20230805
|
77 |
|
20230812
|
78 |
|
20230819
|
79 |
|
20230826
|
80 |
|
20230902
|
81 |
|
20230909
|
82 |
|
20230917
|
83 |
|
20230918
|
84 |
|
20230923
|
85 |
|
20231001
|
86 |
|
20231007
|
87 |
|
20231014
|
88 |
|
20231016
|
89 |
|
20231021
|
90 |
|
20231028
|
91 |
|
20231104
|
92 |
|
20231111
|
93 |
|
20231118
|
94 |
|
20231121
|
95 |
|
20231125
|
96 |
|
20231202
|
97 |
|
20231209
|
98 |
|
20231217
|
99 |
|
20231223
|
100 |
|
20231230
|
101 |
|
20240106
|
102 |
|
20240113
|
103 |
|
20240120
|
104 |
|
20240127
|
105 |
|
20240203
|
106 |
|
20240210
|
107 |
|
20240217
|
108 |
|
20240224
|
109 |
|
20240302
|
110 |
|
20240309
|
111 |
|
20240323
|
112 |
|
20240330
|
113 |
|
20240413
|
|
46 |
20240504
|
|
47 |
20240511
|
|
48 |
20240518
|
|
49 |
20240519
|
|
50 |
20240525
|
|
51 |
20240601
|
|
52 |
20240608
|
|
53 |
20240615
|
|
54 |
20240622
|
|
55 |
20240629
|
|
56 |
20240706
|
|
57 |
20240713
|
|
58 |
20240720
|
|
59 |
20240727
|
|
60 |
20240810
|
|
61 |
20240817
|
|
62 |
20240824
|
|
63 |
20240831
|
|
64 |
20240914
|
|
65 |
20240922
|
|
66 |
20240928
|
|
67 |
20241006
|
|
68 |
20241019
|
|
69 |
20241026
|
|
70 |
20241102
|
114 |
71 |
|
115 |
72 |
# Latest patch is just _pN = $(ver_cut 4)
|
116 |
73 |
$(ver_cut 4)
|
... | ... | |
152 |
109 |
LICENSE="MIT"
|
153 |
110 |
# The subslot reflects the SONAME.
|
154 |
111 |
SLOT="0/6"
|
155 |
|
KEYWORDS="~alpha amd64 arm arm64 hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
|
|
112 |
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
|
156 |
113 |
IUSE="ada +cxx debug doc gpm minimal profile split-usr +stack-realign static-libs test tinfo trace"
|
157 |
114 |
RESTRICT="!test? ( test )"
|
158 |
115 |
|
|
116 |
# TODO: ncurses allows (and we take advantage of this, even) passing
|
|
117 |
# the SONAME for dlopen() use, so only the header is needed at build time.
|
|
118 |
# Maybe we should bundle a copy of gpm.h so we can move gpm to PDEPEND
|
|
119 |
# which would be far nicer UX-wise.
|
159 |
120 |
DEPEND="gpm? ( sys-libs/gpm[${MULTILIB_USEDEP}] )"
|
160 |
121 |
# Block the older ncurses that installed all files w/SLOT=5, bug #557472
|
161 |
122 |
RDEPEND="
|
... | ... | |
178 |
139 |
# For the same reasons, please include the original configure.in changes,
|
179 |
140 |
# NOT just the generated results!
|
180 |
141 |
"${WORKDIR}"/${GENTOO_PATCH_NAME}
|
181 |
|
|
182 |
|
# Avoid breakage with CHOST ending in t64
|
183 |
|
"${FILESDIR}"/ncurses-6.4-t64-1.patch
|
184 |
|
"${FILESDIR}"/ncurses-6.4-t64-2.patch
|
185 |
142 |
)
|
186 |
143 |
|
187 |
144 |
src_unpack() {
|
... | ... | |
211 |
168 |
# bug #214642
|
212 |
169 |
BUILD_CPPFLAGS+=" -D_GNU_SOURCE"
|
213 |
170 |
|
|
171 |
# NCURSES_BOOL confusion, see https://lists.gnu.org/archive/html/bug-ncurses/2024-11/msg00010.html
|
|
172 |
append-cflags $(test-flags-CC -std=gnu17)
|
|
173 |
|
214 |
174 |
# Build the various variants of ncurses -- narrow, wide, and threaded. #510440
|
215 |
175 |
# Order matters here -- we want unicode/thread versions to come last so that the
|
216 |
176 |
# binaries in /usr/bin support both wide and narrow.
|
... | ... | |
288 |
248 |
|
289 |
249 |
# Now the rest of the various standard flags.
|
290 |
250 |
--with-shared
|
|
251 |
--enable-fvisibility
|
291 |
252 |
# (Originally disabled until bug #245417 is sorted out, but now
|
292 |
253 |
# just keeping it off for good, given nobody needed it until now
|
293 |
254 |
# (2022) and we're trying to phase out bdb.)
|
... | ... | |
301 |
262 |
# The configure script uses ldd to parse the linked output which
|
302 |
263 |
# is flaky for cross-compiling/multilib/ldd versions/etc...
|
303 |
264 |
$(use_with gpm gpm libgpm.so.1)
|
304 |
|
--disable-term-driver
|
|
265 |
|
|
266 |
# bug #930806
|
|
267 |
--disable-setuid-environ
|
|
268 |
# TODO: Maybe do these for USE=hardened
|
|
269 |
#--disable-root-access
|
|
270 |
#--disable-root-environ
|
|
271 |
|
305 |
272 |
--disable-termcap
|
306 |
273 |
--enable-symlinks
|
307 |
274 |
--with-manpage-format=normal
|
... | ... | |
322 |
289 |
--disable-pkg-ldflags
|
323 |
290 |
)
|
324 |
291 |
|
|
292 |
case ${CHOST} in
|
|
293 |
*-mingw32*)
|
|
294 |
conf+=( --enable-term-driver )
|
|
295 |
;;
|
|
296 |
*)
|
|
297 |
conf+=( --disable-term-driver )
|
|
298 |
;;
|
|
299 |
esac
|
|
300 |
|
325 |
301 |
if [[ ${target} == ncurses*w ]] ; then
|
326 |
302 |
conf+=( --enable-widec )
|
327 |
303 |
else
|
... | ... | |
330 |
306 |
if [[ ${target} == ncursest* ]] ; then
|
331 |
307 |
conf+=( --with-{pthread,reentrant} )
|
332 |
308 |
else
|
333 |
|
conf+=(
|
334 |
|
--without-{pthread,reentrant}
|
335 |
|
|
336 |
|
# XXX: Revisit on next ABI break (>6) (bug #928873)
|
337 |
|
--disable-opaque-curses
|
338 |
|
--disable-opaque-form
|
339 |
|
--disable-opaque-menu
|
340 |
|
--disable-opaque-panel
|
341 |
|
)
|
|
309 |
conf+=( --without-{pthread,reentrant} )
|
342 |
310 |
fi
|
343 |
311 |
|
344 |
312 |
# Make sure each variant goes in a unique location.
|