Browse code

update screen

Hanno Böck authored on 22/01/2023 17:55:29
Showing 3 changed files
... ...
@@ -1,6 +1,6 @@
1 1
 AUX screen-4.3.0-no-utempter.patch 341 BLAKE2B 3339783b3574f82f093c82a613ad18c5c58c184c082c2c311281cdd57e7176abae0f5935466a4a8b4d931d1d1b93d8f0a4e6b558a268553af4a0170061e6ebfe SHA512 f4191ba1ecac3076f958f56309c0a1d523b455fa4e3388f1cfca59c8ccff0afdfb20ef18d54794ba539b2b6d1511ed599dc44787344dc5ccce2902c9b9848155
2 2
 AUX screen-4.6.2-utmp-exit.patch 1558 BLAKE2B e08e83f8b9f0cd09cd9bad4486a75d71bd899a7917954702ece0837099639079a746138374cbeaf71072cca64ae36a3c2a32250123c6747089e724272227e0dd SHA512 0e7c6c224f6fb8e01650b778cb2b155942752504dc97112d9594b7fa0da1bb8bd828240a2519b1c21f1c162181da89a8daa51ef7f74c8ced0b85cdb3e911a67c
3
+AUX screen-4.9.0-configure-implicit-function-decls.patch 16667 BLAKE2B 6079042dae21c51b81176aadf27314cf0502fcee995bd9668102bc114ac0c2fdb6587fe2c647cbd92d994cb9b6fdba9e259a1f0a6bd7cf7d7905c3f7e36e8aff SHA512 c9ff18fccba0a0ed19e64509ea128b91bbb6fac405e8395ce724435f1af2f2015f645342aa1fc1b4cb023927412db6e1c242c8060a81deab2a8c064523dedd4d
3 4
 AUX screenrc 10412 BLAKE2B f4866f4a83b22c37484b66e4c7d52ec479fe12ae3e72e5c9e769b1b543ecf04d14ef4339e1c72064741cbf39502ef82d3beb213326a30889f128e135f60bd528 SHA512 06fbec5e28480a2c369330fac0c94faa47e5d28e037d9fefd0cb3e813002c504866dc8ac86872b7ac6f16059a219e396a9c425b578b8afe882153ddb506158f7
4 5
 DIST screen-4.9.0.tar.gz 798229 BLAKE2B 0f64a14ce9a719bd4a6d045c55069769045a09ee2086c44c2e3d9da6d1e5ada2f094e00e16029767e1155ce35d4f360d0e2879995eefa052f3214ced71b7617c SHA512 18bbb085d77ecd02cbc02fa88a945c39f06e0c6de4eeaa16b278440dac5c9896811abbe0838144e997cd344ae08b9530399fa8fcb31a65fc571ead90e8307f84
5
-EBUILD screen-4.9.0.ebuild 3726 BLAKE2B 33d94350bf154c8c25a371181133acbdd08adb0554923d0a727fe39babf39901fcd24dc8a6b899d974e3509a63dc5dcc23ac60647a1b741ab2986836e12767d8 SHA512 198ef89eb2dba1e5eff7bcfbc14de3bbfe7692cd8576ae51b6aef7f78d4b6af94432e15f172d06c05ce4109da628c0e1491b09779e6a8c934726e00172c5dcc4
6
-MISC metadata.xml 1783 BLAKE2B 6b1b392339f6786f95c151a7f311c24adf76c32d23e0f5bf50ff97571ab7e0a7b878d1ccac6938a01c2783c4f54eb0644dfd1f35b9bc602590fce96eed4a4e99 SHA512 fc4a716f118ab74b7757035ffadaaeebd47ba512a8ff123a7f5df4fa8fd2b384a66d4da88f8b78e7c16314b710e2346cfa6fc644c22f059d065cc1778565d060
6
+EBUILD screen-4.9.0-r1.ebuild 3801 BLAKE2B 371153d0e6ab88c520622a1ffdc58ac05d44972f0d595dbe7ef45863b99630cf6435bece218456089b39cdd3631dfea65e5c6050440f17461e6f52e2288a9e0f SHA512 aafafa8e3a7ce28a50037bc57246d9b43c6928021c2618dc36954d0c4e410f5336b8d77819140b1eae8bd43750d1ee8fa624e6bd502239ef39f58bd6d88fec9d
7 7
new file mode 100644
... ...
@@ -0,0 +1,747 @@
1
+https://bugs.gentoo.org/869371
2
+
3
+Upstream variant: https://lists.gnu.org/archive/html/screen-devel/2022-08/msg00000.html
4
+--- a/configure.ac
5
+@@ -157,10 +157,11 @@ if test -n "$ULTRIX"; then
6
+ fi
7
+ AC_CHECKING(for POSIX.1)
8
+ AC_EGREP_CPP(YES_IS_DEFINED,
9
+ [#include <sys/types.h>
10
+ #include <unistd.h>
11
++int
12
+ main () {
13
+ #ifdef _POSIX_VERSION
14
+   YES_IS_DEFINED;
15
+ #endif
16
+ ], AC_NOTE(- you have a POSIX system) AC_DEFINE(POSIX) posix=1)
17
+@@ -231,10 +232,11 @@ dnl
18
+ 
19
+ AC_CHECKING(BSD job jontrol)
20
+ AC_TRY_LINK(
21
+ [#include <sys/types.h>
22
+ #include <sys/ioctl.h>
23
++#include <unistd.h>
24
+ ], [
25
+ #ifdef POSIX
26
+ tcsetpgrp(0, 0);
27
+ #else
28
+ int x = TIOCSPGRP;
29
+@@ -248,48 +250,64 @@ int y = TIOCNOTTY;
30
+ 
31
+ dnl
32
+ dnl    ****  setresuid(), setreuid(), seteuid()  ****
33
+ dnl
34
+ AC_CHECKING(setresuid)
35
+-AC_TRY_LINK(,[
36
++AC_TRY_LINK(
37
++[#include <unistd.h>
38
++], [
39
+ setresuid(0, 0, 0);
40
+ ], AC_DEFINE(HAVE_SETRESUID))
41
+ AC_CHECKING(setreuid)
42
+-AC_TRY_LINK(,[
43
++AC_TRY_LINK(
44
++[#include <unistd.h>
45
++], [
46
+ setreuid(0, 0);
47
+ ], AC_DEFINE(HAVE_SETREUID))
48
+ dnl
49
+ dnl seteuid() check:
50
+ dnl   linux seteuid was broken before V1.1.11
51
+ dnl   NeXT, AUX, ISC, and ultrix are still broken (no saved uid support)
52
+ dnl   Solaris seteuid doesn't change the saved uid, bad for
53
+ dnl     multiuser screen sessions
54
+ AC_CHECKING(seteuid)
55
+-AC_TRY_LINK(,[
56
++AC_TRY_LINK(
57
++[#include <unistd.h>
58
++],[
59
+ #if defined(linux) || defined(NeXT) || defined(_AUX_SOURCE) || defined(AUX) || defined(ultrix) || (defined(sun) && defined(SVR4)) || defined(ISC) || defined(sony_news)
60
+-seteuid_is_broken(0);
61
++int seteuid_is_broken(int); seteuid_is_broken(0);
62
+ #else
63
+ seteuid(0);
64
+ #endif
65
+ ], AC_DEFINE(HAVE_SETEUID))
66
+ 
67
+ dnl execvpe
68
+ AC_CHECKING(execvpe)
69
+-AC_TRY_LINK(,[
70
++AC_TRY_LINK(
71
++[#include <unistd.h>
72
++],[
73
+     execvpe(0, 0, 0);
74
+ ], AC_DEFINE(HAVE_EXECVPE)
75
+ CFLAGS="$CFLAGS -D_GNU_SOURCE")
76
+ 
77
+ dnl
78
+ dnl    ****  select()  ****
79
+ dnl
80
+ 
81
+ AC_CHECKING(select)
82
+-AC_TRY_LINK(,[select(0, 0, 0, 0, 0);],, 
83
++AC_TRY_LINK(
84
++[#include <sys/select.h>
85
++],[
86
++    select(0, 0, 0, 0, 0);
87
++],, 
88
+ LIBS="$LIBS -lnet -lnsl"
89
+ AC_CHECKING(select with $LIBS)
90
+-AC_TRY_LINK(,[select(0, 0, 0, 0, 0);],, 
91
++AC_TRY_LINK(
92
++[#include <sys/select.h>
93
++],[
94
++    select(0, 0, 0, 0, 0);
95
++],, 
96
+ AC_MSG_ERROR(!!! no select - no screen))
97
+ )
98
+ dnl
99
+ dnl    ****  FIFO tests  ****
100
+ dnl
101
+@@ -314,11 +332,11 @@ AC_TRY_RUN([
102
+ #define S_IFIFO 0010000
103
+ #endif
104
+ 
105
+ char *fin = "/tmp/conftest$$";
106
+ 
107
+-main()
108
++int main()
109
+ {
110
+   struct stat stb;
111
+   fd_set f;
112
+ 
113
+   (void)alarm(5);
114
+@@ -326,40 +344,40 @@ main()
115
+ #ifdef POSIX
116
+   if (mkfifo(fin, 0777))
117
+ #else
118
+   if (mknod(fin, S_IFIFO|0777, 0))
119
+ #endif
120
+-    exit(1);
121
++    return 1;
122
+   if (stat(fin, &stb) || (stb.st_mode & S_IFIFO) != S_IFIFO)
123
+-    exit(1);
124
++    return 1;
125
+   close(0);
126
+ #ifdef __386BSD__
127
+   /*
128
+    * The next test fails under 386BSD, but screen works using fifos.
129
+    * Fifos in O_RDWR mode are only used for the BROKEN_PIPE case and for
130
+    * the select() configuration test.
131
+    */
132
+-  exit(0);
133
++  return 0;
134
+ #endif
135
+   if (open(fin, O_RDONLY | O_NONBLOCK))
136
+-    exit(1);
137
++    return 1;
138
+   if (fork() == 0)
139
+     {
140
+       close(0);
141
+       if (open(fin, O_WRONLY | O_NONBLOCK))
142
+-	exit(1);
143
++        return 1;
144
+       close(0);
145
+       if (open(fin, O_WRONLY | O_NONBLOCK))
146
+-	exit(1);
147
++        return 1;
148
+       if (write(0, "TEST", 4) == -1)
149
+-	exit(1);
150
+-      exit(0);
151
++        return 1;
152
++      return 0;
153
+     }
154
+   FD_SET(0, &f);
155
+   if (select(1, &f, 0, 0, 0) == -1)
156
+-    exit(1);
157
+-  exit(0);
158
++    return 1;
159
++  return 0;
160
+ }
161
+ ], AC_NOTE(- your fifos are usable) fifo=1,
162
+ AC_NOTE(- your fifos are not usable),
163
+ AC_NOTE(- skipping check because we are cross compiling; assuming fifos are usable) fifo=1)
164
+ rm -f /tmp/conftest*
165
+@@ -385,30 +403,31 @@ AC_TRY_RUN([
166
+ #define S_IFIFO 0010000
167
+ #endif
168
+ 
169
+ char *fin = "/tmp/conftest$$";
170
+ 
171
++int
172
+ main()
173
+ {
174
+   struct timeval tv;
175
+   fd_set f;
176
+ 
177
+ #ifdef POSIX
178
+   if (mkfifo(fin, 0600))
179
+ #else
180
+   if (mknod(fin, S_IFIFO|0600, 0))
181
+ #endif
182
+-    exit(1);
183
++    return 1;
184
+   close(0);
185
+   if (open(fin, O_RDONLY|O_NONBLOCK))
186
+-    exit(1);
187
++    return 1;
188
+   FD_SET(0, &f);
189
+   tv.tv_sec = 1;
190
+   tv.tv_usec = 0;
191
+   if (select(1, &f, 0, 0, &tv))
192
+-    exit(1);
193
+-  exit(0);
194
++    return 1;
195
++  return 0;
196
+ }
197
+ ], AC_NOTE(- your implementation is ok), 
198
+ AC_NOTE(- you have a broken implementation) AC_DEFINE(BROKEN_PIPE) fifobr=1,
199
+ AC_NOTE(- skipping check because we are cross compiling; assuming fifo implementation is ok))
200
+ rm -f /tmp/conftest*
201
+@@ -432,46 +455,48 @@ AC_TRY_RUN([
202
+ 
203
+ #include <sys/stat.h>
204
+ #include <fcntl.h>
205
+ #include <sys/socket.h>
206
+ #include <sys/un.h>
207
++#include <signal.h>
208
+ 
209
+ char *son = "/tmp/conftest$$";
210
+ 
211
++int
212
+ main()
213
+ {
214
+   int s1, s2, l;
215
+   struct sockaddr_un a;
216
+   fd_set f;
217
+ 
218
+   (void)alarm(5);
219
+   if ((s1 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
220
+-    exit(1);
221
++    return 1;
222
+   a.sun_family = AF_UNIX;
223
+   strcpy(a.sun_path, son);
224
+   (void) unlink(son);
225
+   if (bind(s1, (struct sockaddr *) &a, strlen(son)+2) == -1)
226
+-    exit(1);
227
++    return 1;
228
+   if (listen(s1, 2))
229
+-    exit(1);
230
++    return 1;
231
+   if (fork() == 0)
232
+     {
233
+       if ((s2 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
234
+ 	kill(getppid(), 3);
235
+       (void)connect(s2, (struct sockaddr *)&a, strlen(son) + 2);
236
+       if (write(s2, "HELLO", 5) == -1)
237
+ 	kill(getppid(), 3);
238
+-      exit(0);
239
++      return 0;
240
+     }
241
+   l = sizeof(a);
242
+   close(0);
243
+   if (accept(s1, &a, &l))
244
+-    exit(1);
245
++    return 1;
246
+   FD_SET(0, &f);
247
+   if (select(1, &f, 0, 0, 0) == -1)
248
+-    exit(1);
249
+-  exit(0);
250
++    return 1;
251
++  return 0;
252
+ }
253
+ ], AC_NOTE(- your sockets are usable) sock=1,
254
+ AC_NOTE(- your sockets are not usable),
255
+ AC_NOTE(- skipping check because we are cross compiling; assuming sockets are usable) sock=1)
256
+ rm -f /tmp/conftest*
257
+@@ -491,26 +516,27 @@ AC_TRY_RUN([
258
+ #include <sys/socket.h>
259
+ #include <sys/un.h>
260
+ 
261
+ char *son = "/tmp/conftest$$";
262
+ 
263
++int
264
+ main()
265
+ {
266
+   int s;
267
+   struct stat stb;
268
+   struct sockaddr_un a;
269
+   if ((s = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
270
+-    exit(0);
271
++    return 0;
272
+   a.sun_family = AF_UNIX;
273
+   strcpy(a.sun_path, son);
274
+   (void) unlink(son);
275
+   if (bind(s, (struct sockaddr *) &a, strlen(son)+2) == -1)
276
+-    exit(0);
277
++    return 0;
278
+   if (stat(son, &stb))
279
+-    exit(1);
280
++    return 1;
281
+   close(s);
282
+-  exit(0);
283
++  return 0;
284
+ }
285
+ ],AC_NOTE(- you are normal),
286
+ AC_NOTE(- unix domain sockets are not kept in the filesystem)
287
+ AC_DEFINE(SOCK_NOT_IN_FS) socknofs=1,
288
+ AC_NOTE(- skipping check because we are cross compiling; assuming sockets are normal))
289
+@@ -545,122 +571,167 @@ char *nam = "/tmp/conftest$$";
290
+ #endif
291
+ #ifndef S_IFIFO
292
+ #define S_IFIFO 0010000
293
+ #endif
294
+ 
295
++int
296
+ main()
297
+ {
298
+   fd_set f;
299
+ 
300
+ #ifdef __FreeBSD__
301
+ /* From Andrew A. Chernov (ache@astral.msk.su):
302
+  * opening RDWR fifo fails in BSD 4.4, but select return values are
303
+  * right.
304
+  */
305
+-  exit(0);
306
++  return 0;
307
+ #endif
308
+   (void)alarm(5);
309
+ #ifdef POSIX
310
+   if (mkfifo(nam, 0777))
311
+ #else
312
+   if (mknod(nam, S_IFIFO|0777, 0))
313
+ #endif
314
+-    exit(1);
315
++    return 1;
316
+   close(0);
317
+   if (open(nam, O_RDWR | O_NONBLOCK))
318
+-    exit(1);
319
++    return 1;
320
+   if (write(0, "TEST", 4) == -1)
321
+-    exit(1);
322
++    return 1;
323
+ 
324
+ #else
325
+ 
326
+ #include <sys/types.h>
327
+ #include <sys/socket.h>
328
+ #include <sys/un.h>
329
++#include <signal.h>
330
+ 
331
++int
332
+ main()
333
+ {
334
+   int s1, s2, l;
335
+   struct sockaddr_un a;
336
+   fd_set f;
337
+ 
338
+   (void)alarm(5);
339
+   if ((s1 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
340
+-    exit(1);
341
++    return 1;
342
+   a.sun_family = AF_UNIX;
343
+   strcpy(a.sun_path, nam);
344
+   (void) unlink(nam);
345
+   if (bind(s1, (struct sockaddr *) &a, strlen(nam)+2) == -1)
346
+-    exit(1);
347
++    return 1;
348
+   if (listen(s1, 2))
349
+-    exit(1);
350
++    return 1;
351
+   if (fork() == 0)
352
+     {
353
+       if ((s2 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
354
+ 	kill(getppid(), 3);
355
+       (void)connect(s2, (struct sockaddr *)&a, strlen(nam) + 2);
356
+       if (write(s2, "HELLO", 5) == -1)
357
+ 	kill(getppid(), 3);
358
+-      exit(0);
359
++      return 0;
360
+     }
361
+   l = sizeof(a);
362
+   close(0);
363
+   if (accept(s1, (struct sockaddr *)&a, &l))
364
+-    exit(1);
365
++    return 1;
366
+ #endif
367
+ 
368
+ 
369
+   FD_SET(0, &f);
370
+   if (select(1, &f, 0, 0, 0) == -1)
371
+-    exit(1);
372
++    return 1;
373
+   if (select(1, &f, &f, 0, 0) != 2)
374
+-    exit(1);
375
+-  exit(0);
376
++    return 1;
377
++  return 0;
378
+ }
379
+ ],AC_NOTE(- select is ok),
380
+ AC_NOTE(- select can't count) AC_DEFINE(SELECT_BROKEN),
381
+ AC_NOTE(- skipping check because we are cross compiling; assuming select is ok))
382
+ 
383
+ dnl
384
+ dnl    ****  termcap or terminfo  ****
385
+ dnl
386
+ AC_CHECKING(for tgetent)
387
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
388
++AC_TRY_LINK([
389
++    #include <curses.h>
390
++    #include <term.h>
391
++], [
392
++    tgetent((char *)0, (char *)0);
393
++],,
394
+ olibs="$LIBS"
395
+ LIBS="-lcurses $olibs"
396
+ AC_CHECKING(libcurses)
397
+-AC_TRY_LINK(,[
398
++AC_TRY_LINK([#include <curses.h>
399
++    #include <term.h>
400
++],[
401
+ #ifdef __hpux
402
+ __sorry_hpux_libcurses_is_totally_broken_in_10_10();
403
+ #else
404
+ tgetent((char *)0, (char *)0);
405
+ #endif
406
+ ],,
407
+ LIBS="-ltermcap $olibs"
408
+ AC_CHECKING(libtermcap)
409
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
410
++AC_TRY_LINK(
411
++[#include <curses.h>
412
++    #include <term.h>
413
++],[
414
++    tgetent((char *)0, (char *)0);
415
++],,
416
+ LIBS="-ltermlib $olibs"
417
+ AC_CHECKING(libtermlib)
418
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
419
++AC_TRY_LINK(
420
++[#include <curses.h>
421
++    #include <term.h>
422
++],[
423
++    tgetent((char *)0, (char *)0);
424
++],,
425
+ LIBS="-lncursesw $olibs"
426
+ AC_CHECKING(libncursesw)
427
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
428
++AC_TRY_LINK(
429
++[#include <curses.h>
430
++    #include <term.h>
431
++],[
432
++    tgetent((char *)0, (char *)0);
433
++],,
434
+ LIBS="-ltinfow $olibs"
435
+ AC_CHECKING(libtinfow)
436
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
437
++AC_TRY_LINK(
438
++[#include <curses.h>
439
++    #include <term.h>
440
++],[
441
++    tgetent((char *)0, (char *)0);
442
++],,
443
+ LIBS="-lncurses $olibs"
444
+ AC_CHECKING(libncurses)
445
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
446
++AC_TRY_LINK(
447
++[#include <curses.h>
448
++    #include <term.h>
449
++],[
450
++    tgetent((char *)0, (char *)0);
451
++],,
452
+ LIBS="-ltinfo $olibs"
453
+ AC_CHECKING(libtinfo)
454
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
455
++AC_TRY_LINK(
456
++[#include <curses.h>
457
++    #include <term.h>
458
++],[
459
++    tgetent((char *)0, (char *)0);
460
++],,
461
+ AC_MSG_ERROR(!!! no tgetent - no screen)))))))))
462
+ 
463
+ AC_TRY_RUN([
464
++#include <curses.h>
465
++#include <string.h>
466
++#include <term.h>
467
++
468
++int
469
+ main()
470
+ {
471
+- exit(strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1);
472
++ return(strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1);
473
+ }], AC_NOTE(- you use the termcap database),
474
+ AC_NOTE(- you use the terminfo database) AC_DEFINE(TERMINFO),
475
+ AC_NOTE(- skipping check because we are cross compiling; assuming terminfo database is used) AC_DEFINE(TERMINFO))
476
+ AC_CHECKING(ospeed)
477
+ AC_TRY_LINK(extern short ospeed;,ospeed=5;,,AC_DEFINE(NEED_OSPEED))
478
+@@ -677,11 +748,15 @@ fi
479
+ 
480
+ if test "$cross_compiling" = no ; then
481
+ AC_CHECKING(for SVR4 ptys)
482
+ sysvr4ptys=
483
+ if test -c /dev/ptmx ; then
484
+-AC_TRY_LINK([],[ptsname(0);grantpt(0);unlockpt(0);],[AC_DEFINE(HAVE_SVR4_PTYS)
485
++AC_TRY_LINK([
486
++    #include <stdlib.h>
487
++], [
488
++    ptsname(0);grantpt(0);unlockpt(0);
489
++],[AC_DEFINE(HAVE_SVR4_PTYS)
490
+ sysvr4ptys=1])
491
+ fi
492
+ fi
493
+ 
494
+ AC_CHECK_FUNCS(getpt)
495
+@@ -733,33 +808,36 @@ AC_CHECKING(default tty permissions/group)
496
+ rm -f conftest_grp
497
+ AC_TRY_RUN([
498
+ #include <sys/types.h>
499
+ #include <sys/stat.h>
500
+ #include <stdio.h>
501
++#include <stdlib.h>
502
++#include <unistd.h>
503
++int
504
+ main()
505
+ {
506
+   struct stat sb;
507
+   char *x,*ttyname();
508
+   int om, m;
509
+   FILE *fp;
510
+ 
511
+-  if (!(x = ttyname(0))) exit(1);
512
+-  if (stat(x, &sb)) exit(1);
513
++  if (!(x = ttyname(0))) return 1;
514
++  if (stat(x, &sb)) return 1;
515
+   om = sb.st_mode;
516
+-  if (om & 002) exit(0);
517
++  if (om & 002) return 0;
518
+   m = system("mesg y");
519
+-  if (m == -1 || m == 127) exit(1);
520
+-  if (stat(x, &sb)) exit(1);
521
++  if (m == -1 || m == 127) return 1;
522
++  if (stat(x, &sb)) return 1;
523
+   m = sb.st_mode;
524
+-  if (chmod(x, om)) exit(1);
525
+-  if (m & 002) exit(0);
526
+-  if (sb.st_gid == getgid()) exit(1);
527
++  if (chmod(x, om)) return 1;
528
++  if (m & 002) return 0;
529
++  if (sb.st_gid == getgid()) return 1;
530
+   if (!(fp=fopen("conftest_grp", "w")))
531
+-    exit(1);
532
++    return 1;
533
+   fprintf(fp, "%d\n", sb.st_gid);
534
+   fclose(fp);
535
+-  exit(0);
536
++  return 0;
537
+ }
538
+ ],[
539
+     if test -f conftest_grp; then
540
+ 	ptygrp=`cat conftest_grp`
541
+ 	AC_NOTE([- pty mode: $ptymode, group: $ptygrp])
542
+@@ -869,17 +942,25 @@ AC_CHECKING(for libutil(s))
543
+ test -f /usr/lib/libutils.a && LIBS="$LIBS -lutils"
544
+ test -f /usr/lib/libutil.a && LIBS="$LIBS -lutil"
545
+ fi
546
+ 
547
+ AC_CHECKING(getloadavg)
548
+-AC_TRY_LINK(,[getloadavg((double *)0, 0);],
549
++AC_TRY_LINK(
550
++[
551
++    #include <stdlib.h>
552
++],[
553
++    getloadavg((double *)0, 0);],
554
+ AC_DEFINE(LOADAV_GETLOADAVG) load=1,
555
+ if test "$cross_compiling" = no && test -f /usr/lib/libkvm.a ; then
556
+ olibs="$LIBS"
557
+ LIBS="$LIBS -lkvm"
558
+ AC_CHECKING(getloadavg with -lkvm)
559
+-AC_TRY_LINK(,[getloadavg((double *)0, 0);],
560
++AC_TRY_LINK(
561
++[
562
++    #include <stdlib.h>
563
++],[
564
++    getloadavg((double *)0, 0);],
565
+ AC_DEFINE(LOADAV_GETLOADAVG) load=1, LIBS="$olibs")
566
+ fi
567
+ )
568
+ 
569
+ if test -z "$load" ; then
570
+@@ -931,10 +1012,11 @@ else
571
+ 
572
+ $nlist64
573
+ 
574
+ struct nlist nl[2];
575
+ 
576
++int
577
+ main()
578
+ {
579
+ #if !defined(_AUX_SOURCE) && !defined(AUX)
580
+ # ifdef NLIST_NAME_UNION
581
+   nl[0].n_un.n_name = "$av";
582
+@@ -944,12 +1026,12 @@ main()
583
+ #else
584
+   strncpy(nl[0].n_name, "$av", sizeof(nl[0].n_name));
585
+ #endif
586
+   nlist(LOADAV_UNIX, nl);
587
+   if (nl[0].n_value == 0)
588
+-    exit(1);
589
+-  exit(0);
590
++    return 1;
591
++  return 0;
592
+ }
593
+   ],avensym=$av;break)
594
+   if test "$av" = _Loadavg; then
595
+     nlist64='#define nlist nlist64'
596
+   fi
597
+@@ -1068,21 +1150,22 @@ void
598
+ hand()
599
+ {
600
+   got++;
601
+ }
602
+ 
603
++int
604
+ main()
605
+ {
606
+   /* on hpux we use sigvec to get bsd signals */
607
+ #ifdef __hpux
608
+   (void)signal(SIGCLD, hand);
609
+   kill(getpid(), SIGCLD);
610
+   kill(getpid(), SIGCLD);
611
+   if (got < 2)
612
+-    exit(1);
613
++    return 1;
614
+ #endif
615
+-  exit(0);
616
++  return 0;
617
+ }
618
+ ],,AC_DEFINE(SYSVSIGS),:)
619
+ 
620
+ fi
621
+ 
622
+@@ -1107,14 +1190,22 @@ oldlibs="$LIBS"
623
+ LIBS="$LIBS -lsun"
624
+ AC_CHECKING(IRIX sun library)
625
+ AC_TRY_LINK(,,,LIBS="$oldlibs")
626
+ 
627
+ AC_CHECKING(syslog)
628
+-AC_TRY_LINK(,[closelog();], , [oldlibs="$LIBS"
629
++AC_TRY_LINK(
630
++[#include <syslog.h>
631
++], [
632
++    closelog();
633
++], , [oldlibs="$LIBS"
634
+ LIBS="$LIBS -lbsd"
635
+ AC_CHECKING(syslog in libbsd.a)
636
+-AC_TRY_LINK(, [closelog();], AC_NOTE(- found.), [LIBS="$oldlibs"
637
++AC_TRY_LINK(
638
++[#include <syslog.h>
639
++], [
640
++    closelog();
641
++], AC_NOTE(- found.), [LIBS="$oldlibs"
642
+ AC_NOTE(- bad news: syslog missing.) AC_DEFINE(NOSYSLOG)])])
643
+ 
644
+ AC_EGREP_CPP(YES_IS_DEFINED,
645
+ [#ifdef M_UNIX
646
+    YES_IS_DEFINED;
647
+@@ -1147,66 +1238,87 @@ fi
648
+ dnl AC_CHECK_HEADER(shadow.h, AC_DEFINE(SHADOWPW))
649
+ AC_CHECKING(getspnam)
650
+ AC_TRY_LINK([#include <shadow.h>], [getspnam("x");],AC_DEFINE(SHADOWPW))
651
+ 
652
+ AC_CHECKING(getttyent)
653
+-AC_TRY_LINK(,[getttyent();], AC_DEFINE(GETTTYENT))
654
++AC_TRY_LINK(
655
++[
656
++    #include <ttyent.h>
657
++],[
658
++    getttyent();
659
++], AC_DEFINE(GETTTYENT))
660
+ 
661
+ AC_CHECKING(fdwalk)
662
+ AC_TRY_LINK([#include <stdlib.h>], [fdwalk(NULL, NULL);],AC_DEFINE(HAVE_FDWALK))
663
+ 
664
+ AC_CHECKING(whether memcpy/memmove/bcopy handles overlapping arguments)
665
+ AC_TRY_RUN([
666
++#include <string.h>
667
++
668
++int
669
+ main() {
670
+   char buf[10];
671
+   strcpy(buf, "abcdefghi");
672
+   bcopy(buf, buf + 2, 3);
673
+   if (strncmp(buf, "ababcf", 6))
674
+-    exit(1);
675
++    return 1;
676
+   strcpy(buf, "abcdefghi");
677
+   bcopy(buf + 2, buf, 3);
678
+   if (strncmp(buf, "cdedef", 6))
679
+-    exit(1);
680
+-  exit(0); /* libc version works properly.  */
681
++    return 1;
682
++  return 0; /* libc version works properly.  */
683
+ }], AC_DEFINE(USEBCOPY),,:)
684
+ 
685
+ AC_TRY_RUN([
686
++#include <string.h>
687
++
688
+ #define bcopy(s,d,l) memmove(d,s,l)
689
++int
690
+ main() {
691
+   char buf[10];
692
+   strcpy(buf, "abcdefghi");
693
+   bcopy(buf, buf + 2, 3);
694
+   if (strncmp(buf, "ababcf", 6))
695
+-    exit(1);
696
++    return 1;
697
+   strcpy(buf, "abcdefghi");
698
+   bcopy(buf + 2, buf, 3);
699
+   if (strncmp(buf, "cdedef", 6))
700
+-    exit(1);
701
+-  exit(0); /* libc version works properly.  */
702
++    return 1;
703
++  return 0; /* libc version works properly.  */
704
+ }], AC_DEFINE(USEMEMMOVE),,
705
+   AC_NOTE(- skipping check because we are cross compiling; use memmove) AC_DEFINE(USEMEMMOVE))
706
+ 
707
+ 
708
+ AC_TRY_RUN([
709
++#include <string.h>
710
++
711
+ #define bcopy(s,d,l) memcpy(d,s,l)
712
++int
713
+ main() {
714
+   char buf[10];
715
+   strcpy(buf, "abcdefghi");
716
+   bcopy(buf, buf + 2, 3);
717
+   if (strncmp(buf, "ababcf", 6))
718
+-    exit(1);
719
++    return 1;
720
+   strcpy(buf, "abcdefghi");
721
+   bcopy(buf + 2, buf, 3);
722
+   if (strncmp(buf, "cdedef", 6))
723
+-    exit(1);
724
+-  exit(0); /* libc version works properly.  */
725
++    return 1;
726
++  return 0; /* libc version works properly.  */
727
+ }], AC_DEFINE(USEMEMCPY),,:)
728
+ 
729
+ AC_SYS_LONG_FILE_NAMES
730
+ 
731
+ AC_MSG_CHECKING(for vsprintf)
732
+-AC_TRY_LINK([#include <stdarg.h>],[va_list valist; vsprintf(0,0,valist);], AC_MSG_RESULT(yes);AC_DEFINE(USEVARARGS), AC_MSG_RESULT(no))
733
++AC_TRY_LINK(
734
++[
735
++    #include <stdarg.h>
736
++    #include <stdio.h>
737
++],
738
++[
739
++    va_list valist; vsprintf(0,0,valist);
740
++], AC_MSG_RESULT(yes);AC_DEFINE(USEVARARGS), AC_MSG_RESULT(no))
741
+ 
742
+ AC_HEADER_DIRENT
743
+ 
744
+ AC_MSG_CHECKING(for setenv)
745
+ if test -z "$ac_setenv_args"; then
746
+
0 747
similarity index 92%
1 748
rename from app-misc/screen/screen-4.9.0.ebuild
2 749
rename to app-misc/screen/screen-4.9.0-r1.ebuild
... ...
@@ -10,7 +10,7 @@ HOMEPAGE="https://www.gnu.org/software/screen/"
10 10
 
11 11
 if [[ ${PV} != 9999 ]] ; then
12 12
 	SRC_URI="mirror://gnu/${PN}/${P}.tar.gz"
13
-	KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
13
+	KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
14 14
 else
15 15
 	inherit git-r3
16 16
 	EGIT_REPO_URI="https://git.savannah.gnu.org/git/screen.git"
... ...
@@ -18,7 +18,7 @@ else
18 18
 	S="${WORKDIR}"/${P}/src
19 19
 fi
20 20
 
21
-LICENSE="GPL-2"
21
+LICENSE="GPL-3+"
22 22
 SLOT="0"
23 23
 IUSE="debug nethack pam selinux multiuser"
24 24
 
... ...
@@ -34,6 +34,7 @@ PATCHES=(
34 34
 	# Don't use utempter even if it is found on the system.
35 35
 	"${FILESDIR}"/${PN}-4.3.0-no-utempter.patch
36 36
 	"${FILESDIR}"/${PN}-4.6.2-utmp-exit.patch
37
+	"${FILESDIR}"/${PN}-4.9.0-configure-implicit-function-decls.patch
37 38
 )
38 39
 
39 40
 src_prepare() {