* [gentoo-commits] repo/gentoo:master commit in: sys-libs/readline/, sys-libs/readline/files/
@ 2016-11-10 6:03 Mike Frysinger
0 siblings, 0 replies; 7+ messages in thread
From: Mike Frysinger @ 2016-11-10 6:03 UTC (permalink / raw
To: gentoo-commits
commit: 4b0bd0d1d7636f79c4c1a65ab280c7f9009ff26e
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Thu Nov 10 06:01:14 2016 +0000
Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org>
CommitDate: Thu Nov 10 06:01:14 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4b0bd0d1
sys-libs/readline: add upstream patch for excessive history memory allocs #597006
.../files/readline-7.0-history-alloclist.patch | 29 ++++++++++++++++++++++
...{readline-7.0.ebuild => readline-7.0-r1.ebuild} | 1 +
2 files changed, 30 insertions(+)
diff --git a/sys-libs/readline/files/readline-7.0-history-alloclist.patch b/sys-libs/readline/files/readline-7.0-history-alloclist.patch
new file mode 100644
index 00000000..73faa60
--- /dev/null
+++ b/sys-libs/readline/files/readline-7.0-history-alloclist.patch
@@ -0,0 +1,29 @@
+https://bugs.gentoo.org/597006
+https://lists.gnu.org/archive/html/bug-bash/2016-10/msg00010.html
+
+*** ../bash-4.4/lib/readline/history.c 2015-12-28 13:50:31.000000000 -0500
+--- lib/readline/history.c 2016-09-30 14:28:40.000000000 -0400
+***************
+*** 58,61 ****
+--- 58,63 ----
+ #define DEFAULT_HISTORY_INITIAL_SIZE 502
+
++ #define MAX_HISTORY_INITIAL_SIZE 8192
++
+ /* The number of slots to increase the_history by. */
+ #define DEFAULT_HISTORY_GROW_SIZE 50
+***************
+*** 308,312 ****
+ {
+ if (history_stifled && history_max_entries > 0)
+! history_size = history_max_entries + 2;
+ else
+ history_size = DEFAULT_HISTORY_INITIAL_SIZE;
+--- 310,316 ----
+ {
+ if (history_stifled && history_max_entries > 0)
+! history_size = (history_max_entries > MAX_HISTORY_INITIAL_SIZE)
+! ? MAX_HISTORY_INITIAL_SIZE
+! : history_max_entries + 2;
+ else
+ history_size = DEFAULT_HISTORY_INITIAL_SIZE;
diff --git a/sys-libs/readline/readline-7.0.ebuild b/sys-libs/readline/readline-7.0-r1.ebuild
similarity index 98%
rename from sys-libs/readline/readline-7.0.ebuild
rename to sys-libs/readline/readline-7.0-r1.ebuild
index 56fddcb..aecaa1c 100644
--- a/sys-libs/readline/readline-7.0.ebuild
+++ b/sys-libs/readline/readline-7.0-r1.ebuild
@@ -54,6 +54,7 @@ src_prepare() {
epatch "${FILESDIR}"/${PN}-5.0-no_rpath.patch
epatch "${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch #385091
epatch "${FILESDIR}"/${PN}-7.0-headers.patch
+ epatch "${FILESDIR}"/${PN}-7.0-history-alloclist.patch #597006
# Force ncurses linking. #71420
# Use pkg-config to get the right values. #457558
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-libs/readline/, sys-libs/readline/files/
@ 2020-07-30 8:05 Lars Wendler
0 siblings, 0 replies; 7+ messages in thread
From: Lars Wendler @ 2020-07-30 8:05 UTC (permalink / raw
To: gentoo-commits
commit: 2280012d7e09b97fb7441ea8c2b353f30a6ed356
Author: John Helmert III <jchelmert3 <AT> posteo <DOT> net>
AuthorDate: Wed Jul 29 20:30:35 2020 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Thu Jul 30 08:04:52 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2280012d
sys-libs/readline: Security cleanup (drop <8)
Bug: https://bugs.gentoo.org/717924
Package-Manager: Portage-3.0.1, Repoman-2.3.23
Signed-off-by: John Helmert III <jchelmert3 <AT> posteo.net>
Closes: https://github.com/gentoo/gentoo/pull/16893
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
sys-libs/readline/Manifest | 15 --
.../readline-6.3-fix-long-prompt-vi-search.patch | 26 ---
.../readline/files/readline-6.3-read-eof.patch | 54 -------
sys-libs/readline/files/readline-7.0-mingw.patch | 152 ------------------
.../files/readline-7.0-missing-echo-proto.patch | 14 --
sys-libs/readline/readline-6.3_p8-r3.ebuild | 163 -------------------
sys-libs/readline/readline-7.0_p5-r1.ebuild | 174 ---------------------
7 files changed, 598 deletions(-)
diff --git a/sys-libs/readline/Manifest b/sys-libs/readline/Manifest
index 030cef77bba..8dd67c3a4d8 100644
--- a/sys-libs/readline/Manifest
+++ b/sys-libs/readline/Manifest
@@ -1,19 +1,4 @@
-DIST readline-6.3.tar.gz 2468560 BLAKE2B 24488ec141734c050ba985a93423692396f105619bae3ce5b109bc68a4f43862bcf3a6fb8d82fec1145d665cdb408765e179379bb35f008d09c441fa2e5739df SHA512 f70efaf46d570b85c7637172b0ee2eb9a4aa73ba38a62bb45075e665929d9701b96fba0aea6c767fd9a2a0d39dfe8e70ab06da08f8524aee76a7c502f370a401
-DIST readline-7.0.tar.gz 2910016 BLAKE2B 679b8aa7ce003017b729e6d8d4cb69d0f991578441a3e69005090079e61f6aa48b7ad4d0b1f34b6041528cf33254a1bf3ddb05b60db53a06e443d7922d49d0d4 SHA512 18243189d39bf0d4c8a76cddcce75243c1bae8824c686e9b6ba352667607e5b10c5feb79372a1093c1c388d821841670702e940df12eae94bcebdeed90047870
DIST readline-8.0.tar.gz 2975937 BLAKE2B 95e08b28cc46582f036379413810ca40c97d4d3bc59a9e03e04e57d531573abfbe955f6f1cb86e39c208bf6c3f4c618cff70a87bec596d0b9120909d6c5a2f69 SHA512 41759d27bc3a258fefd7f4ff3277fa6ab9c21abb7b160e1a75aa8eba547bd90b288514e76264bd94fb0172da8a4faa54aab2c07b68a0356918ecf7f1969e866f
-DIST readline63-001 1366 BLAKE2B 82af5be99597719329db3f1d6049e75a5654ccf6597cf557c71ad7ada0ac03be87381a7738931eb78716de65902ae87498f574b84150a69eae9cc308c4bfffdd SHA512 e70f89ca52a4eae7e1cddd70de6a7162252231ee029c89bb3fcb0f6c8c8b46c666be910c8b2eee72e96983ec2f1a23663694dc222f67228d82e8e4684f1504a2
-DIST readline63-002 1297 BLAKE2B 5ace4a81381910ee48dee8cdbb2ca95a1bef2d1f8acca6d39a910c078c86de10a0fc29486939b336110ecb0281b3edb16e4b985f41e7ee161904728f289fff04 SHA512 4e23bd67433577e6e361d10a6c32768ea9e13b10e77493e565b870f56069b673fbcb0b860225f79fa9931845fc91d35c9a82c1385c23f8b757ebfd59f27851f4
-DIST readline63-003 985 BLAKE2B cf2cda505b100d5f820d8bfc99eed6b50e65c92b6a495073352fc7385c6456478594e5c2dc293ce556b66853dff705050fb97982aa25fce452ae53d2cb272cf4 SHA512 6bfb84a5b980091b995e2b96bdf5680f97fe670e6cac1b8606d2d75a1ef922ff5bd4e73f029f7af98a115006b7ab7828146f2cd6986287543d8a29987c91dc12
-DIST readline63-004 1363 BLAKE2B c1aec93f1e23acd51b36068d3aac31b93ffd9c1039be2c45ff4e6479135f153888030c68cf19c5ced950f6fbbb38ee7fa644d5a737f3f8ed511e97bf342940f5 SHA512 6b683e9fe28831885135391b5a23bc580cacf0ffe720951a80f545574eda4eb064fe189801d44329b2eb2d3577db5a90f9e5ad9ed131e7e8a8ae349511632721
-DIST readline63-005 1664 BLAKE2B f98f62be8676aca81b91d919bc4eccfe40c382a8baab0e64b1659b714f0d72424e29b709cc5e226fd73daf67eef264a17e07982d2553ce80f5e5f39fad70610b SHA512 b0332d7f999376788155341319d138a899a2278c338a6faaac89ecf3ed1e2248a07413dd810a76996bf25f211de787182b55f34ab3d7d31eb7519d7a48ebed32
-DIST readline63-006 1982 BLAKE2B ad6d16ff769eb8e367cf961ffe152c04778b046a04e4a62e0ce21d08fa16b0eca3d278dbdc274b082d24fa2ec959ffb62168ea7693b4de94b59a4526b1f0c4a2 SHA512 e9fbfa38d7b03ab2aff2e9e48918b85b4b67a729862ee47d1cc8e0aeb90c3224394a79f68829951e1377cae65742aa5385eae865f75e9c0b2e2abde42889431c
-DIST readline63-007 1428 BLAKE2B 60e64c2dd36457e3992cfbfbbcc261337e515be360a37d71b9de236c62c781f10f0ec37e4e196b4634e5d547edebbf915370091ca42fff873b78cd80cfe3a7f2 SHA512 abee331894846b360203a521d9a66fa02c03214120d5cafbd1cb4d680bd7bbef14321ae845dd67f7b5e8c87322801fd96fc9a5fd0ae026b41d98dc24a8949854
-DIST readline63-008 1452 BLAKE2B 4e41c45be1479fba9f74bf9cedb8d1f6237e650962d5b45ea1a61cc48a8323a0fa60d76f68c011b6e7c73a1078b5ff80f9966e983b994f814d471d0efd9efde6 SHA512 8e30bbca3aa5cea8c2ee511abe0ec8f131608d74fe5ab24d68bcf452267f0f97446ed6e7cd482360876ce6c027280e4f4450cae05eb18f56046240f4c224841c
-DIST readline70-001 1777 BLAKE2B ab217bd9d27f30351397db2b745cb33ac7e0ce18bbc00112bb87570da0f62ee0e8d182395c97e4ecc21af51e7e1e580ba48076de1095c556f0744475e4019821 SHA512 4402186905af8cd42c609d640c2e13b9ad61c7778e5a3fd2c2d9da301f0deab05b04d7836f31527262f44f406517823dbb18cb07f2c73931186c806b494699ec
-DIST readline70-002 2953 BLAKE2B 47d729b1babe904855fe5d4f780a5b2153a743def527479c3cb82759cdee5bb4260be722e1050be680f5c0dd6dec8ca25c4c1ff557415abae6b3fac2bd481f0b SHA512 13d1489578508d4d2c3a1618024198a709dbce74a6bbf0f6d7ec67d2419c55bfec9f0ca9de0ed93f129d21d5c3a94307ccdc49408455bbb301c5e3a772b03185
-DIST readline70-003 1294 BLAKE2B 9473e18b582fba69cea83e3f5b9fa278dd8b0544325439307d2b4053cbeca8d2f008104bee181ae5d9405d702e6d3bcf26379c4d46e269906474c8544367b780 SHA512 eaf962a1480eb3870519017b81ecc5cef171e4c41fcf8c17da61ccbfd0379ed6bca85c17b03e2207ae4d51509f33fd010294c75f4bd0433a52118015d4160385
-DIST readline70-004 1501 BLAKE2B cebce69a21bee3a4d6a908de09f371d65eab6af51a8dc0f58fc915b916957db420252ce07b06703c05d984f62e1e849b6975f5444b2af6ba35ff7c939acf9d99 SHA512 7be41558eab3b88a3657f8589ecfaff0b8ee7f59083d385f50e8704fe830e05a50652a5feda19ff1f3cfd98bff4bb8e25e1637ec4dac8a618db9c8220a3d954e
-DIST readline70-005 1641 BLAKE2B f720508f698b113c6328018f7e6e8775c7c79afc464047405a5c3dae017d611535017dfc2759c11483bb536fab1e9bf72c7a9d3c769b7aea3bd2cee9686bd522 SHA512 eeb27f4f9195cb905d5891f26480d58f59c885dde3457f7a30ff57760ac772e2333ee8aeae979214949f3b52030285b10db013e307ee7311abab677a4427e878
DIST readline80-001 927 BLAKE2B 95e3ac33ff4adb65813274864c17781056a8ea065f9a76571b4a6bcb2ebab090c3a021fa2b621832c11b5995e48a8a26dd6e3a8f5864a8e8b520bfcf85d7c4ab SHA512 a148cda6ac97935d51ede1bbacf847d7d2cba8861cf3941d32e3da2f45f16dcc05b20845b63d4264692520db8329e1236cf2bc4fd8ccbe6e40921bbbdeb2cb1c
DIST readline80-002 1401 BLAKE2B a2f511272f6d651208469998330059d6bae17bb8b704b64468685bb0368b76df1ca5b1dcd8e5cb0019e80932130c8a92fd1a305679bf79f0b801532a94c4b4ae SHA512 a941d142a59fe592cc45c1cf4d416e2fc0ab543dd6a0496fb8b2ec6f651cedd6fb9e0c105f14880700b69b2d6912653b3f66371e45cbe4adc0cc9554801afd3c
DIST readline80-003 2158 BLAKE2B d8910aef1b796a59500b255df8db71ad1738dd164fd69827759eade74b6d9806ecd364839cfa904fc2f2d48352342155f670e5ec43aac0693f36820fb7139a4d SHA512 85235fca047b4ac87b846d998fffc67ae67ed365b068fd2743e84f11fd00086f85e622955192e07e3560965e32ff5f6d014e0146cde528fb0d0f7b5b829875ca
diff --git a/sys-libs/readline/files/readline-6.3-fix-long-prompt-vi-search.patch b/sys-libs/readline/files/readline-6.3-fix-long-prompt-vi-search.patch
deleted file mode 100644
index 23d785054e7..00000000000
--- a/sys-libs/readline/files/readline-6.3-fix-long-prompt-vi-search.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-https://lists.gnu.org/archive/html/bug-bash/2014-08/msg00082.html
-
-From 2774192e93991e3d85ccc37c714aa018e442af6d Mon Sep 17 00:00:00 2001
-From: Dylan Cali <calid1984@gmail.com>
-Date: Sat, 23 Aug 2014 02:26:05 -0500
-Subject: [PATCH] fix vi search prompt bug for long prompts
-
----
- display.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/display.c b/display.c
-index 4df1f73..e575b16 100644
---- a/display.c
-+++ b/display.c
-@@ -2259,7 +2259,7 @@ rl_message (va_alist)
- va_start (args);
- format = va_arg (args, char *);
- #endif
-- vsnprintf (msg_buf, msg_bufsiz - 1, format, args);
-+ vsnprintf (msg_buf, msg_bufsiz, format, args);
- }
- #else
- vsprintf (msg_buf, format, args);
---
-1.7.10.4
diff --git a/sys-libs/readline/files/readline-6.3-read-eof.patch b/sys-libs/readline/files/readline-6.3-read-eof.patch
deleted file mode 100644
index f74aad63be1..00000000000
--- a/sys-libs/readline/files/readline-6.3-read-eof.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-http://lists.gnu.org/archive/html/bug-bash/2014-12/msg00152.html
-
-*** ../bash-4.3-patched/lib/readline/readline.c 2014-10-01 13:08:28.000000000 -0400
---- lib/readline/readline.c 2014-12-20 22:37:28.000000000 -0500
-***************
-*** 580,592 ****
- }
-
-! /* EOF typed to a non-blank line is a <NL>. If we want to change this,
-! to force any existing line to be ignored when read(2) reads EOF,
-! for example, this is the place to change. */
- if (c == EOF && rl_end)
-! c = NEWLINE;
-
- /* The character _rl_eof_char typed to blank line, and not as the
-! previous character is interpreted as EOF. */
-! if (((c == _rl_eof_char && lastc != c) || c == EOF) && !rl_end)
- {
- #if defined (READLINE_CALLBACKS)
---- 587,620 ----
- }
-
-! /* EOF typed to a non-blank line is ^D the first time, EOF the second
-! time in a row. This won't return any partial line read from the tty.
-! If we want to change this, to force any existing line to be returned
-! when read(2) reads EOF, for example, this is the place to change. */
- if (c == EOF && rl_end)
-! {
-! if (RL_SIG_RECEIVED ())
-! {
-! RL_CHECK_SIGNALS ();
-! if (rl_signal_event_hook)
-! (*rl_signal_event_hook) (); /* XXX */
-! }
-!
-! /* XXX - reading two consecutive EOFs returns EOF */
-! if (RL_ISSTATE (RL_STATE_TERMPREPPED))
-! {
-! if (lastc == _rl_eof_char || lastc == EOF)
-! rl_end = 0;
-! else
-! c = _rl_eof_char;
-! }
-! else
-! c = NEWLINE;
-! }
-
- /* The character _rl_eof_char typed to blank line, and not as the
-! previous character is interpreted as EOF. This doesn't work when
-! READLINE_CALLBACKS is defined, so hitting a series of ^Ds will
-! erase all the chars on the line and then return EOF. */
-! if (((c == _rl_eof_char && lastc != c) || c == EOF) && rl_end == 0)
- {
- #if defined (READLINE_CALLBACKS)
diff --git a/sys-libs/readline/files/readline-7.0-mingw.patch b/sys-libs/readline/files/readline-7.0-mingw.patch
deleted file mode 100644
index f003038d2c0..00000000000
--- a/sys-libs/readline/files/readline-7.0-mingw.patch
+++ /dev/null
@@ -1,152 +0,0 @@
---- a/colors.c
-+++ b/colors.c
-@@ -37,6 +37,10 @@
- #include "posixstat.h" // stat related macros (S_ISREG, ...)
- #include <fcntl.h> // S_ISUID
-
-+#ifndef S_ISDIR
-+#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
-+#endif
-+
- // strlen()
- #if defined (HAVE_STRING_H)
- # include <string.h>
-@@ -182,12 +186,17 @@ _rl_print_color_indicator (const char *f
- if (S_ISREG (mode))
- {
- colored_filetype = C_FILE;
--
-+#ifdef S_ISUID
- if ((mode & S_ISUID) != 0 && is_colored (C_SETUID))
- colored_filetype = C_SETUID;
-- else if ((mode & S_ISGID) != 0 && is_colored (C_SETGID))
-+ else
-+#endif
-+#ifdef S_ISGID
-+ if ((mode & S_ISGID) != 0 && is_colored (C_SETGID))
- colored_filetype = C_SETGID;
-- else if (is_colored (C_CAP) && 0) //f->has_capability)
-+ else
-+#endif
-+ if (is_colored (C_CAP) && 0) //f->has_capability)
- colored_filetype = C_CAP;
- else if ((mode & S_IXUGO) != 0 && is_colored (C_EXEC))
- colored_filetype = C_EXEC;
-@@ -211,12 +220,16 @@ _rl_print_color_indicator (const char *f
- colored_filetype = C_STICKY;
- #endif
- }
-+#if defined (S_ISLNK)
- else if (S_ISLNK (mode))
- colored_filetype = C_LINK;
-+#endif
- else if (S_ISFIFO (mode))
- colored_filetype = C_FIFO;
-+#if defined (S_ISSOCK)
- else if (S_ISSOCK (mode))
- colored_filetype = C_SOCK;
-+#endif
- else if (S_ISBLK (mode))
- colored_filetype = C_BLK;
- else if (S_ISCHR (mode))
---- a/histfile.c
-+++ b/histfile.c
-@@ -606,12 +606,14 @@ history_truncate_file (fname, lines)
- history_lines_written_to_file = 0;
- }
-
-+#if defined (HAVE_CHOWN)
- /* Make sure the new filename is owned by the same user as the old. If one
- user is running this, it's a no-op. If the shell is running after sudo
- with a shared history file, we don't want to leave the history file
- owned by root. */
- if (rv == 0 && exists)
- r = chown (filename, finfo.st_uid, finfo.st_gid);
-+#endif
-
- xfree (filename);
- FREE (tempname);
-@@ -753,12 +755,14 @@ mmap_error:
- history_lines_written_to_file = 0;
- }
-
-+#if defined (HAVE_CHOWN)
- /* Make sure the new filename is owned by the same user as the old. If one
- user is running this, it's a no-op. If the shell is running after sudo
- with a shared history file, we don't want to leave the history file
- owned by root. */
- if (rv == 0 && exists)
- mode = chown (histname, finfo.st_uid, finfo.st_gid);
-+#endif
-
- FREE (histname);
- FREE (tempname);
---- a/input.c
-+++ b/input.c
-@@ -71,6 +71,10 @@ extern int errno;
- #include "rlshell.h"
- #include "xmalloc.h"
-
-+#if defined (__MINGW32__)
-+#include <conio.h>
-+#endif
-+
- /* What kind of non-blocking I/O do we have? */
- #if !defined (O_NDELAY) && defined (O_NONBLOCK)
- # define O_NDELAY O_NONBLOCK /* Posix style */
---- a/posixstat.h
-+++ b/posixstat.h
-@@ -78,30 +78,44 @@
-
- #if defined (S_IFBLK) && !defined (S_ISBLK)
- #define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) /* block device */
-+#elif !defined (S_IFBLK)
-+#define S_ISBLK(m) 0
- #endif
-
- #if defined (S_IFCHR) && !defined (S_ISCHR)
- #define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) /* character device */
-+#elif !defined (S_IFCHR)
-+#define S_ISCHR(m) 0
- #endif
-
- #if defined (S_IFDIR) && !defined (S_ISDIR)
- #define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) /* directory */
-+#elif !defined (S_IFDIR)
-+#define S_ISDIR(m) 0
- #endif
-
- #if defined (S_IFREG) && !defined (S_ISREG)
- #define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) /* file */
-+#elif !defined (S_IFREG)
-+#define S_ISREG(m) 0
- #endif
-
- #if defined (S_IFIFO) && !defined (S_ISFIFO)
- #define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) /* fifo - named pipe */
-+#elif !defined (S_IFIFO)
-+#define S_ISFIFO(m) 0
- #endif
-
- #if defined (S_IFLNK) && !defined (S_ISLNK)
- #define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) /* symbolic link */
-+#elif !defined (S_IFLNK)
-+#define S_ISLNK(m) 0
- #endif
-
- #if defined (S_IFSOCK) && !defined (S_ISSOCK)
- #define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) /* socket */
-+#elif !defined (S_IFSOCK)
-+#define S_ISSOCK(m) 0
- #endif
-
- /*
-@@ -137,6 +151,8 @@
- /* These are non-standard, but are used in builtins.c$symbolic_umask() */
- #define S_IRUGO (S_IRUSR | S_IRGRP | S_IROTH)
- #define S_IWUGO (S_IWUSR | S_IWGRP | S_IWOTH)
-+#if defined(S_IXUSR) && defined(S_IXOTH)
- #define S_IXUGO (S_IXUSR | S_IXGRP | S_IXOTH)
-+#endif
-
- #endif /* _POSIXSTAT_H_ */
diff --git a/sys-libs/readline/files/readline-7.0-missing-echo-proto.patch b/sys-libs/readline/files/readline-7.0-missing-echo-proto.patch
deleted file mode 100644
index cad3c8ca2c4..00000000000
--- a/sys-libs/readline/files/readline-7.0-missing-echo-proto.patch
+++ /dev/null
@@ -1,14 +0,0 @@
-https://lists.gnu.org/archive/html/bug-readline/2016-11/msg00000.html
-
-fix from upstream
-
---- a/readline.h
-+++ b/readline.h
-@@ -413,6 +413,7 @@
- extern void rl_tty_set_default_bindings PARAMS((Keymap));
- extern void rl_tty_unset_default_bindings PARAMS((Keymap));
-
-+extern int rl_tty_set_echoing PARAMS((int));
- extern int rl_reset_terminal PARAMS((const char *));
- extern void rl_resize_terminal PARAMS((void));
- extern void rl_set_screen_size PARAMS((int, int));
diff --git a/sys-libs/readline/readline-6.3_p8-r3.ebuild b/sys-libs/readline/readline-6.3_p8-r3.ebuild
deleted file mode 100644
index 009f74e037f..00000000000
--- a/sys-libs/readline/readline-6.3_p8-r3.ebuild
+++ /dev/null
@@ -1,163 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit eutils multilib toolchain-funcs flag-o-matic multilib-minimal preserve-libs usr-ldscript
-
-# Official patches
-# See ftp://ftp.cwru.edu/pub/bash/readline-6.3-patches/
-PLEVEL=${PV##*_p}
-MY_PV=${PV/_p*}
-MY_PV=${MY_PV/_/-}
-MY_P=${PN}-${MY_PV}
-[[ ${PV} != *_p* ]] && PLEVEL=0
-patches() {
- [[ ${PLEVEL} -eq 0 ]] && return 1
- local opt=$1
- eval set -- {1..${PLEVEL}}
- set -- $(printf "${PN}${MY_PV/\.}-%03d " "$@")
- if [[ ${opt} == -s ]] ; then
- echo "${@/#/${DISTDIR}/}"
- else
- local u
- for u in ftp://ftp.cwru.edu/pub/bash mirror://gnu/${PN} ; do
- printf "${u}/${PN}-${MY_PV}-patches/%s " "$@"
- done
- fi
-}
-
-DESCRIPTION="Another cute console display library"
-HOMEPAGE="https://tiswww.case.edu/php/chet/readline/rltop.html"
-SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz $(patches)"
-
-LICENSE="GPL-3"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 s390 sparc x86 ~amd64-linux ~x86-linux"
-IUSE="static-libs utils"
-
-RDEPEND=">=sys-libs/ncurses-5.9-r3:0=[${MULTILIB_USEDEP}]"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
-
-S=${WORKDIR}/${MY_P}
-
-PATCHES=(
- "${FILESDIR}"/${PN}-5.0-no_rpath.patch
- "${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch #385091
- "${FILESDIR}"/${PN}-6.3-fix-long-prompt-vi-search.patch
- "${FILESDIR}"/${PN}-6.3-read-eof.patch
-)
-
-src_unpack() {
- unpack ${MY_P}.tar.gz
-}
-
-src_prepare() {
- [[ ${PLEVEL} -gt 0 ]] && epatch $(patches -s)
- epatch "${PATCHES[@]}"
-
- # Force ncurses linking. #71420
- # Use pkg-config to get the right values. #457558
- local ncurses_libs=$($(tc-getPKG_CONFIG) ncurses --libs)
- sed -i \
- -e "/^SHLIB_LIBS=/s:=.*:='${ncurses_libs}':" \
- support/shobj-conf || die
- sed -i \
- -e "/^[[:space:]]*LIBS=.-lncurses/s:-lncurses:${ncurses_libs}:" \
- examples/rlfe/configure || die
-
- # fix building under Gentoo/FreeBSD; upstream FreeBSD deprecated
- # objformat for years, so we don't want to rely on that.
- sed -i -e '/objformat/s:if .*; then:if true; then:' support/shobj-conf || die
-
- ln -s ../.. examples/rlfe/readline # for local readline headers
-}
-
-src_configure() {
- # fix implicit decls with widechar funcs
- append-cppflags -D_GNU_SOURCE
- # https://lists.gnu.org/archive/html/bug-readline/2010-07/msg00013.html
- append-cppflags -Dxrealloc=_rl_realloc -Dxmalloc=_rl_malloc -Dxfree=_rl_free
-
- # Make sure configure picks a better ar than `ar`. #484866
- export ac_cv_prog_AR=$(tc-getAR)
-
- # Force the test since we used sed above to force it.
- export bash_cv_termcap_lib=ncurses
-
- # Control cross-compiling cases when we know the right answer.
- # In cases where the C library doesn't support wide characters, readline
- # itself won't work correctly, so forcing the answer below should be OK.
- if tc-is-cross-compiler ; then
- export bash_cv_func_sigsetjmp='present'
- export bash_cv_func_ctype_nonascii='yes'
- export bash_cv_wcwidth_broken='no' #503312
- fi
-
- # This is for rlfe, but we need to make sure LDFLAGS doesn't change
- # so we can re-use the config cache file between the two.
- append-ldflags -L.
-
- multilib-minimal_src_configure
-}
-
-multilib_src_configure() {
- ECONF_SOURCE=${S} \
- econf \
- --cache-file="${BUILD_DIR}"/config.cache \
- --docdir='$(datarootdir)'/doc/${PF} \
- --with-curses \
- $(use_enable static-libs static)
-
- if use utils && multilib_is_native_abi && ! tc-is-cross-compiler ; then
- # code is full of AC_TRY_RUN()
- mkdir -p examples/rlfe || die
- cd examples/rlfe || die
- ECONF_SOURCE=${S}/examples/rlfe \
- econf --cache-file="${BUILD_DIR}"/config.cache
- fi
-}
-
-multilib_src_compile() {
- emake
-
- if use utils && multilib_is_native_abi && ! tc-is-cross-compiler ; then
- # code is full of AC_TRY_RUN()
- cd examples/rlfe || die
- local l
- for l in readline history ; do
- ln -s ../../shlib/lib${l}$(get_libname)* lib${l}$(get_libname)
- ln -sf ../../lib${l}.a lib${l}.a
- done
- emake
- fi
-}
-
-multilib_src_install() {
- default
-
- if multilib_is_native_abi ; then
- gen_usr_ldscript -a readline history #4411
-
- if use utils && ! tc-is-cross-compiler; then
- dobin examples/rlfe/rlfe
- fi
- fi
-}
-
-multilib_src_install_all() {
- einstalldocs
- dodoc USAGE
- dohtml -r doc/.
- docinto ps
- dodoc doc/*.ps
-}
-
-pkg_preinst() {
- preserve_old_lib /$(get_libdir)/lib{history,readline}.so.{4,5} #29865
-}
-
-pkg_postinst() {
- preserve_old_lib_notify /$(get_libdir)/lib{history,readline}.so.{4,5}
-}
diff --git a/sys-libs/readline/readline-7.0_p5-r1.ebuild b/sys-libs/readline/readline-7.0_p5-r1.ebuild
deleted file mode 100644
index 00c928489ec..00000000000
--- a/sys-libs/readline/readline-7.0_p5-r1.ebuild
+++ /dev/null
@@ -1,174 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-inherit flag-o-matic multilib-minimal toolchain-funcs preserve-libs usr-ldscript
-
-# Official patches
-# See ftp://ftp.cwru.edu/pub/bash/readline-7.0-patches/
-PLEVEL="${PV##*_p}"
-MY_PV="${PV/_p*}"
-MY_PV="${MY_PV/_/-}"
-MY_P="${PN}-${MY_PV}"
-[[ ${PV} != *_p* ]] && PLEVEL=0
-patches() {
- [[ ${PLEVEL} -eq 0 ]] && return 1
- local opt=$1
- eval set -- {1..${PLEVEL}}
- set -- $(printf "${PN}${MY_PV/\.}-%03d " "$@")
- if [[ ${opt} == -s ]] ; then
- echo "${@/#/${DISTDIR}/}"
- else
- local u
- for u in ftp://ftp.cwru.edu/pub/bash mirror://gnu/${PN} ; do
- printf "${u}/${PN}-${MY_PV}-patches/%s " "$@"
- done
- fi
-}
-
-DESCRIPTION="Another cute console display library"
-HOMEPAGE="https://tiswww.case.edu/php/chet/readline/rltop.html"
-
-case ${PV} in
- *_alpha*|*_beta*|*_rc*)
- SRC_URI+=" ftp://ftp.cwru.edu/pub/bash/${MY_P}.tar.gz"
- ;;
- *)
- SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz $(patches)"
- ;;
-esac
-
-LICENSE="GPL-3"
-SLOT="0/7" # subslot matches SONAME major
-KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv s390 sparc x86 ~amd64-linux ~x86-linux"
-IUSE="static-libs +unicode utils"
-
-RDEPEND=">=sys-libs/ncurses-5.9-r3:0=[static-libs?,unicode?,${MULTILIB_USEDEP}]"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
-
-S=${WORKDIR}/${MY_P}
-
-PATCHES=(
- "${FILESDIR}"/${PN}-5.0-no_rpath.patch
- "${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch #385091
- "${FILESDIR}"/${PN}-7.0-headers.patch
- "${FILESDIR}"/${PN}-7.0-missing-echo-proto.patch
- "${FILESDIR}"/${PN}-7.0-mingw.patch
-)
-
-# Needed because we don't want the patches being unpacked
-# (which emits annoying and useless error messages)
-src_unpack() {
- unpack ${MY_P}.tar.gz
-}
-
-src_prepare() {
- [[ ${PLEVEL} -gt 0 ]] && eapply -p0 $(patches -s)
- default
-
- # Force ncurses linking. #71420
- # Use pkg-config to get the right values. #457558
- local ncurses_libs=$($(tc-getPKG_CONFIG) ncurses$(usex unicode w '') --libs)
- sed -i \
- -e "/^SHLIB_LIBS=/s:=.*:='${ncurses_libs}':" \
- support/shobj-conf || die
- sed -i \
- -e "/^[[:space:]]*LIBS=.-lncurses/s:-lncurses:${ncurses_libs}:" \
- examples/rlfe/configure || die
-
- # fix building under Gentoo/FreeBSD; upstream FreeBSD deprecated
- # objformat for years, so we don't want to rely on that.
- sed -i -e '/objformat/s:if .*; then:if true; then:' support/shobj-conf || die
-
- ln -s ../.. examples/rlfe/readline || die # for local readline headers
-}
-
-src_configure() {
- # fix implicit decls with widechar funcs
- append-cppflags -D_GNU_SOURCE
- # https://lists.gnu.org/archive/html/bug-readline/2010-07/msg00013.html
- append-cppflags -Dxrealloc=_rl_realloc -Dxmalloc=_rl_malloc -Dxfree=_rl_free
-
- # Make sure configure picks a better ar than `ar`. #484866
- export ac_cv_prog_AR=$(tc-getAR)
-
- # Force the test since we used sed above to force it.
- export bash_cv_termcap_lib=ncurses
-
- # Control cross-compiling cases when we know the right answer.
- # In cases where the C library doesn't support wide characters, readline
- # itself won't work correctly, so forcing the answer below should be OK.
- if tc-is-cross-compiler ; then
- use kernel_Winnt || export bash_cv_func_sigsetjmp='present'
- export bash_cv_func_ctype_nonascii='yes'
- export bash_cv_wcwidth_broken='no' #503312
- fi
-
- # This is for rlfe, but we need to make sure LDFLAGS doesn't change
- # so we can re-use the config cache file between the two.
- append-ldflags -L.
-
- multilib-minimal_src_configure
-}
-
-multilib_src_configure() {
- local myeconfargs=(
- --cache-file="${BUILD_DIR}"/config.cache
- --with-curses
- $(use_enable static-libs static)
- )
- ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
-
- if use utils && multilib_is_native_abi && ! tc-is-cross-compiler ; then
- # code is full of AC_TRY_RUN()
- mkdir -p examples/rlfe || die
- cd examples/rlfe || die
- ECONF_SOURCE="${S}"/examples/rlfe \
- econf --cache-file="${BUILD_DIR}"/config.cache
- fi
-}
-
-multilib_src_compile() {
- emake
-
- if use utils && multilib_is_native_abi && ! tc-is-cross-compiler ; then
- # code is full of AC_TRY_RUN()
- cd examples/rlfe || die
- local l
- for l in readline history ; do
- ln -s ../../shlib/lib${l}$(get_libname)* lib${l}$(get_libname) || die
- ln -s ../../lib${l}.a lib${l}.a || die
- done
- emake
- fi
-}
-
-multilib_src_install() {
- default
-
- if multilib_is_native_abi ; then
- gen_usr_ldscript -a readline history #4411
-
- if use utils && ! tc-is-cross-compiler; then
- dobin examples/rlfe/rlfe
- fi
- fi
-}
-
-multilib_src_install_all() {
- HTML_DOCS="doc/history.html doc/readline.html doc/rluserman.html" einstalldocs
- dodoc USAGE
- docinto ps
- dodoc doc/*.ps
-}
-pkg_preinst() {
- # bug #29865
- # Reappeared in #595324 with paludis so keeping this for now...
- preserve_old_lib /$(get_libdir)/lib{history,readline}.so.{4,5,6}
-}
-
-pkg_postinst() {
- preserve_old_lib_notify /$(get_libdir)/lib{history,readline}.so.{4,5,6}
-}
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-libs/readline/, sys-libs/readline/files/
@ 2020-07-30 8:53 Lars Wendler
0 siblings, 0 replies; 7+ messages in thread
From: Lars Wendler @ 2020-07-30 8:53 UTC (permalink / raw
To: gentoo-commits
commit: 2ad8bd5161e9eafeb37f46c9a9e321903a1797e0
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Thu Jul 30 08:51:59 2020 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Thu Jul 30 08:52:33 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2ad8bd51
Revert "sys-libs/readline: Security cleanup (drop <8)"
This reverts commit 2280012d7e09b97fb7441ea8c2b353f30a6ed356.
because it breaks app-admin/puppet-agent and dev-lisp/clisp
Bug: https://bugs.gentoo.org/717924
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
sys-libs/readline/Manifest | 15 ++
.../readline-6.3-fix-long-prompt-vi-search.patch | 26 +++
.../readline/files/readline-6.3-read-eof.patch | 54 +++++++
sys-libs/readline/files/readline-7.0-mingw.patch | 152 ++++++++++++++++++
.../files/readline-7.0-missing-echo-proto.patch | 14 ++
sys-libs/readline/readline-6.3_p8-r3.ebuild | 163 +++++++++++++++++++
sys-libs/readline/readline-7.0_p5-r1.ebuild | 174 +++++++++++++++++++++
7 files changed, 598 insertions(+)
diff --git a/sys-libs/readline/Manifest b/sys-libs/readline/Manifest
index 8dd67c3a4d8..030cef77bba 100644
--- a/sys-libs/readline/Manifest
+++ b/sys-libs/readline/Manifest
@@ -1,4 +1,19 @@
+DIST readline-6.3.tar.gz 2468560 BLAKE2B 24488ec141734c050ba985a93423692396f105619bae3ce5b109bc68a4f43862bcf3a6fb8d82fec1145d665cdb408765e179379bb35f008d09c441fa2e5739df SHA512 f70efaf46d570b85c7637172b0ee2eb9a4aa73ba38a62bb45075e665929d9701b96fba0aea6c767fd9a2a0d39dfe8e70ab06da08f8524aee76a7c502f370a401
+DIST readline-7.0.tar.gz 2910016 BLAKE2B 679b8aa7ce003017b729e6d8d4cb69d0f991578441a3e69005090079e61f6aa48b7ad4d0b1f34b6041528cf33254a1bf3ddb05b60db53a06e443d7922d49d0d4 SHA512 18243189d39bf0d4c8a76cddcce75243c1bae8824c686e9b6ba352667607e5b10c5feb79372a1093c1c388d821841670702e940df12eae94bcebdeed90047870
DIST readline-8.0.tar.gz 2975937 BLAKE2B 95e08b28cc46582f036379413810ca40c97d4d3bc59a9e03e04e57d531573abfbe955f6f1cb86e39c208bf6c3f4c618cff70a87bec596d0b9120909d6c5a2f69 SHA512 41759d27bc3a258fefd7f4ff3277fa6ab9c21abb7b160e1a75aa8eba547bd90b288514e76264bd94fb0172da8a4faa54aab2c07b68a0356918ecf7f1969e866f
+DIST readline63-001 1366 BLAKE2B 82af5be99597719329db3f1d6049e75a5654ccf6597cf557c71ad7ada0ac03be87381a7738931eb78716de65902ae87498f574b84150a69eae9cc308c4bfffdd SHA512 e70f89ca52a4eae7e1cddd70de6a7162252231ee029c89bb3fcb0f6c8c8b46c666be910c8b2eee72e96983ec2f1a23663694dc222f67228d82e8e4684f1504a2
+DIST readline63-002 1297 BLAKE2B 5ace4a81381910ee48dee8cdbb2ca95a1bef2d1f8acca6d39a910c078c86de10a0fc29486939b336110ecb0281b3edb16e4b985f41e7ee161904728f289fff04 SHA512 4e23bd67433577e6e361d10a6c32768ea9e13b10e77493e565b870f56069b673fbcb0b860225f79fa9931845fc91d35c9a82c1385c23f8b757ebfd59f27851f4
+DIST readline63-003 985 BLAKE2B cf2cda505b100d5f820d8bfc99eed6b50e65c92b6a495073352fc7385c6456478594e5c2dc293ce556b66853dff705050fb97982aa25fce452ae53d2cb272cf4 SHA512 6bfb84a5b980091b995e2b96bdf5680f97fe670e6cac1b8606d2d75a1ef922ff5bd4e73f029f7af98a115006b7ab7828146f2cd6986287543d8a29987c91dc12
+DIST readline63-004 1363 BLAKE2B c1aec93f1e23acd51b36068d3aac31b93ffd9c1039be2c45ff4e6479135f153888030c68cf19c5ced950f6fbbb38ee7fa644d5a737f3f8ed511e97bf342940f5 SHA512 6b683e9fe28831885135391b5a23bc580cacf0ffe720951a80f545574eda4eb064fe189801d44329b2eb2d3577db5a90f9e5ad9ed131e7e8a8ae349511632721
+DIST readline63-005 1664 BLAKE2B f98f62be8676aca81b91d919bc4eccfe40c382a8baab0e64b1659b714f0d72424e29b709cc5e226fd73daf67eef264a17e07982d2553ce80f5e5f39fad70610b SHA512 b0332d7f999376788155341319d138a899a2278c338a6faaac89ecf3ed1e2248a07413dd810a76996bf25f211de787182b55f34ab3d7d31eb7519d7a48ebed32
+DIST readline63-006 1982 BLAKE2B ad6d16ff769eb8e367cf961ffe152c04778b046a04e4a62e0ce21d08fa16b0eca3d278dbdc274b082d24fa2ec959ffb62168ea7693b4de94b59a4526b1f0c4a2 SHA512 e9fbfa38d7b03ab2aff2e9e48918b85b4b67a729862ee47d1cc8e0aeb90c3224394a79f68829951e1377cae65742aa5385eae865f75e9c0b2e2abde42889431c
+DIST readline63-007 1428 BLAKE2B 60e64c2dd36457e3992cfbfbbcc261337e515be360a37d71b9de236c62c781f10f0ec37e4e196b4634e5d547edebbf915370091ca42fff873b78cd80cfe3a7f2 SHA512 abee331894846b360203a521d9a66fa02c03214120d5cafbd1cb4d680bd7bbef14321ae845dd67f7b5e8c87322801fd96fc9a5fd0ae026b41d98dc24a8949854
+DIST readline63-008 1452 BLAKE2B 4e41c45be1479fba9f74bf9cedb8d1f6237e650962d5b45ea1a61cc48a8323a0fa60d76f68c011b6e7c73a1078b5ff80f9966e983b994f814d471d0efd9efde6 SHA512 8e30bbca3aa5cea8c2ee511abe0ec8f131608d74fe5ab24d68bcf452267f0f97446ed6e7cd482360876ce6c027280e4f4450cae05eb18f56046240f4c224841c
+DIST readline70-001 1777 BLAKE2B ab217bd9d27f30351397db2b745cb33ac7e0ce18bbc00112bb87570da0f62ee0e8d182395c97e4ecc21af51e7e1e580ba48076de1095c556f0744475e4019821 SHA512 4402186905af8cd42c609d640c2e13b9ad61c7778e5a3fd2c2d9da301f0deab05b04d7836f31527262f44f406517823dbb18cb07f2c73931186c806b494699ec
+DIST readline70-002 2953 BLAKE2B 47d729b1babe904855fe5d4f780a5b2153a743def527479c3cb82759cdee5bb4260be722e1050be680f5c0dd6dec8ca25c4c1ff557415abae6b3fac2bd481f0b SHA512 13d1489578508d4d2c3a1618024198a709dbce74a6bbf0f6d7ec67d2419c55bfec9f0ca9de0ed93f129d21d5c3a94307ccdc49408455bbb301c5e3a772b03185
+DIST readline70-003 1294 BLAKE2B 9473e18b582fba69cea83e3f5b9fa278dd8b0544325439307d2b4053cbeca8d2f008104bee181ae5d9405d702e6d3bcf26379c4d46e269906474c8544367b780 SHA512 eaf962a1480eb3870519017b81ecc5cef171e4c41fcf8c17da61ccbfd0379ed6bca85c17b03e2207ae4d51509f33fd010294c75f4bd0433a52118015d4160385
+DIST readline70-004 1501 BLAKE2B cebce69a21bee3a4d6a908de09f371d65eab6af51a8dc0f58fc915b916957db420252ce07b06703c05d984f62e1e849b6975f5444b2af6ba35ff7c939acf9d99 SHA512 7be41558eab3b88a3657f8589ecfaff0b8ee7f59083d385f50e8704fe830e05a50652a5feda19ff1f3cfd98bff4bb8e25e1637ec4dac8a618db9c8220a3d954e
+DIST readline70-005 1641 BLAKE2B f720508f698b113c6328018f7e6e8775c7c79afc464047405a5c3dae017d611535017dfc2759c11483bb536fab1e9bf72c7a9d3c769b7aea3bd2cee9686bd522 SHA512 eeb27f4f9195cb905d5891f26480d58f59c885dde3457f7a30ff57760ac772e2333ee8aeae979214949f3b52030285b10db013e307ee7311abab677a4427e878
DIST readline80-001 927 BLAKE2B 95e3ac33ff4adb65813274864c17781056a8ea065f9a76571b4a6bcb2ebab090c3a021fa2b621832c11b5995e48a8a26dd6e3a8f5864a8e8b520bfcf85d7c4ab SHA512 a148cda6ac97935d51ede1bbacf847d7d2cba8861cf3941d32e3da2f45f16dcc05b20845b63d4264692520db8329e1236cf2bc4fd8ccbe6e40921bbbdeb2cb1c
DIST readline80-002 1401 BLAKE2B a2f511272f6d651208469998330059d6bae17bb8b704b64468685bb0368b76df1ca5b1dcd8e5cb0019e80932130c8a92fd1a305679bf79f0b801532a94c4b4ae SHA512 a941d142a59fe592cc45c1cf4d416e2fc0ab543dd6a0496fb8b2ec6f651cedd6fb9e0c105f14880700b69b2d6912653b3f66371e45cbe4adc0cc9554801afd3c
DIST readline80-003 2158 BLAKE2B d8910aef1b796a59500b255df8db71ad1738dd164fd69827759eade74b6d9806ecd364839cfa904fc2f2d48352342155f670e5ec43aac0693f36820fb7139a4d SHA512 85235fca047b4ac87b846d998fffc67ae67ed365b068fd2743e84f11fd00086f85e622955192e07e3560965e32ff5f6d014e0146cde528fb0d0f7b5b829875ca
diff --git a/sys-libs/readline/files/readline-6.3-fix-long-prompt-vi-search.patch b/sys-libs/readline/files/readline-6.3-fix-long-prompt-vi-search.patch
new file mode 100644
index 00000000000..23d785054e7
--- /dev/null
+++ b/sys-libs/readline/files/readline-6.3-fix-long-prompt-vi-search.patch
@@ -0,0 +1,26 @@
+https://lists.gnu.org/archive/html/bug-bash/2014-08/msg00082.html
+
+From 2774192e93991e3d85ccc37c714aa018e442af6d Mon Sep 17 00:00:00 2001
+From: Dylan Cali <calid1984@gmail.com>
+Date: Sat, 23 Aug 2014 02:26:05 -0500
+Subject: [PATCH] fix vi search prompt bug for long prompts
+
+---
+ display.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/display.c b/display.c
+index 4df1f73..e575b16 100644
+--- a/display.c
++++ b/display.c
+@@ -2259,7 +2259,7 @@ rl_message (va_alist)
+ va_start (args);
+ format = va_arg (args, char *);
+ #endif
+- vsnprintf (msg_buf, msg_bufsiz - 1, format, args);
++ vsnprintf (msg_buf, msg_bufsiz, format, args);
+ }
+ #else
+ vsprintf (msg_buf, format, args);
+--
+1.7.10.4
diff --git a/sys-libs/readline/files/readline-6.3-read-eof.patch b/sys-libs/readline/files/readline-6.3-read-eof.patch
new file mode 100644
index 00000000000..f74aad63be1
--- /dev/null
+++ b/sys-libs/readline/files/readline-6.3-read-eof.patch
@@ -0,0 +1,54 @@
+http://lists.gnu.org/archive/html/bug-bash/2014-12/msg00152.html
+
+*** ../bash-4.3-patched/lib/readline/readline.c 2014-10-01 13:08:28.000000000 -0400
+--- lib/readline/readline.c 2014-12-20 22:37:28.000000000 -0500
+***************
+*** 580,592 ****
+ }
+
+! /* EOF typed to a non-blank line is a <NL>. If we want to change this,
+! to force any existing line to be ignored when read(2) reads EOF,
+! for example, this is the place to change. */
+ if (c == EOF && rl_end)
+! c = NEWLINE;
+
+ /* The character _rl_eof_char typed to blank line, and not as the
+! previous character is interpreted as EOF. */
+! if (((c == _rl_eof_char && lastc != c) || c == EOF) && !rl_end)
+ {
+ #if defined (READLINE_CALLBACKS)
+--- 587,620 ----
+ }
+
+! /* EOF typed to a non-blank line is ^D the first time, EOF the second
+! time in a row. This won't return any partial line read from the tty.
+! If we want to change this, to force any existing line to be returned
+! when read(2) reads EOF, for example, this is the place to change. */
+ if (c == EOF && rl_end)
+! {
+! if (RL_SIG_RECEIVED ())
+! {
+! RL_CHECK_SIGNALS ();
+! if (rl_signal_event_hook)
+! (*rl_signal_event_hook) (); /* XXX */
+! }
+!
+! /* XXX - reading two consecutive EOFs returns EOF */
+! if (RL_ISSTATE (RL_STATE_TERMPREPPED))
+! {
+! if (lastc == _rl_eof_char || lastc == EOF)
+! rl_end = 0;
+! else
+! c = _rl_eof_char;
+! }
+! else
+! c = NEWLINE;
+! }
+
+ /* The character _rl_eof_char typed to blank line, and not as the
+! previous character is interpreted as EOF. This doesn't work when
+! READLINE_CALLBACKS is defined, so hitting a series of ^Ds will
+! erase all the chars on the line and then return EOF. */
+! if (((c == _rl_eof_char && lastc != c) || c == EOF) && rl_end == 0)
+ {
+ #if defined (READLINE_CALLBACKS)
diff --git a/sys-libs/readline/files/readline-7.0-mingw.patch b/sys-libs/readline/files/readline-7.0-mingw.patch
new file mode 100644
index 00000000000..f003038d2c0
--- /dev/null
+++ b/sys-libs/readline/files/readline-7.0-mingw.patch
@@ -0,0 +1,152 @@
+--- a/colors.c
++++ b/colors.c
+@@ -37,6 +37,10 @@
+ #include "posixstat.h" // stat related macros (S_ISREG, ...)
+ #include <fcntl.h> // S_ISUID
+
++#ifndef S_ISDIR
++#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
++#endif
++
+ // strlen()
+ #if defined (HAVE_STRING_H)
+ # include <string.h>
+@@ -182,12 +186,17 @@ _rl_print_color_indicator (const char *f
+ if (S_ISREG (mode))
+ {
+ colored_filetype = C_FILE;
+-
++#ifdef S_ISUID
+ if ((mode & S_ISUID) != 0 && is_colored (C_SETUID))
+ colored_filetype = C_SETUID;
+- else if ((mode & S_ISGID) != 0 && is_colored (C_SETGID))
++ else
++#endif
++#ifdef S_ISGID
++ if ((mode & S_ISGID) != 0 && is_colored (C_SETGID))
+ colored_filetype = C_SETGID;
+- else if (is_colored (C_CAP) && 0) //f->has_capability)
++ else
++#endif
++ if (is_colored (C_CAP) && 0) //f->has_capability)
+ colored_filetype = C_CAP;
+ else if ((mode & S_IXUGO) != 0 && is_colored (C_EXEC))
+ colored_filetype = C_EXEC;
+@@ -211,12 +220,16 @@ _rl_print_color_indicator (const char *f
+ colored_filetype = C_STICKY;
+ #endif
+ }
++#if defined (S_ISLNK)
+ else if (S_ISLNK (mode))
+ colored_filetype = C_LINK;
++#endif
+ else if (S_ISFIFO (mode))
+ colored_filetype = C_FIFO;
++#if defined (S_ISSOCK)
+ else if (S_ISSOCK (mode))
+ colored_filetype = C_SOCK;
++#endif
+ else if (S_ISBLK (mode))
+ colored_filetype = C_BLK;
+ else if (S_ISCHR (mode))
+--- a/histfile.c
++++ b/histfile.c
+@@ -606,12 +606,14 @@ history_truncate_file (fname, lines)
+ history_lines_written_to_file = 0;
+ }
+
++#if defined (HAVE_CHOWN)
+ /* Make sure the new filename is owned by the same user as the old. If one
+ user is running this, it's a no-op. If the shell is running after sudo
+ with a shared history file, we don't want to leave the history file
+ owned by root. */
+ if (rv == 0 && exists)
+ r = chown (filename, finfo.st_uid, finfo.st_gid);
++#endif
+
+ xfree (filename);
+ FREE (tempname);
+@@ -753,12 +755,14 @@ mmap_error:
+ history_lines_written_to_file = 0;
+ }
+
++#if defined (HAVE_CHOWN)
+ /* Make sure the new filename is owned by the same user as the old. If one
+ user is running this, it's a no-op. If the shell is running after sudo
+ with a shared history file, we don't want to leave the history file
+ owned by root. */
+ if (rv == 0 && exists)
+ mode = chown (histname, finfo.st_uid, finfo.st_gid);
++#endif
+
+ FREE (histname);
+ FREE (tempname);
+--- a/input.c
++++ b/input.c
+@@ -71,6 +71,10 @@ extern int errno;
+ #include "rlshell.h"
+ #include "xmalloc.h"
+
++#if defined (__MINGW32__)
++#include <conio.h>
++#endif
++
+ /* What kind of non-blocking I/O do we have? */
+ #if !defined (O_NDELAY) && defined (O_NONBLOCK)
+ # define O_NDELAY O_NONBLOCK /* Posix style */
+--- a/posixstat.h
++++ b/posixstat.h
+@@ -78,30 +78,44 @@
+
+ #if defined (S_IFBLK) && !defined (S_ISBLK)
+ #define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) /* block device */
++#elif !defined (S_IFBLK)
++#define S_ISBLK(m) 0
+ #endif
+
+ #if defined (S_IFCHR) && !defined (S_ISCHR)
+ #define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) /* character device */
++#elif !defined (S_IFCHR)
++#define S_ISCHR(m) 0
+ #endif
+
+ #if defined (S_IFDIR) && !defined (S_ISDIR)
+ #define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) /* directory */
++#elif !defined (S_IFDIR)
++#define S_ISDIR(m) 0
+ #endif
+
+ #if defined (S_IFREG) && !defined (S_ISREG)
+ #define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) /* file */
++#elif !defined (S_IFREG)
++#define S_ISREG(m) 0
+ #endif
+
+ #if defined (S_IFIFO) && !defined (S_ISFIFO)
+ #define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) /* fifo - named pipe */
++#elif !defined (S_IFIFO)
++#define S_ISFIFO(m) 0
+ #endif
+
+ #if defined (S_IFLNK) && !defined (S_ISLNK)
+ #define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) /* symbolic link */
++#elif !defined (S_IFLNK)
++#define S_ISLNK(m) 0
+ #endif
+
+ #if defined (S_IFSOCK) && !defined (S_ISSOCK)
+ #define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) /* socket */
++#elif !defined (S_IFSOCK)
++#define S_ISSOCK(m) 0
+ #endif
+
+ /*
+@@ -137,6 +151,8 @@
+ /* These are non-standard, but are used in builtins.c$symbolic_umask() */
+ #define S_IRUGO (S_IRUSR | S_IRGRP | S_IROTH)
+ #define S_IWUGO (S_IWUSR | S_IWGRP | S_IWOTH)
++#if defined(S_IXUSR) && defined(S_IXOTH)
+ #define S_IXUGO (S_IXUSR | S_IXGRP | S_IXOTH)
++#endif
+
+ #endif /* _POSIXSTAT_H_ */
diff --git a/sys-libs/readline/files/readline-7.0-missing-echo-proto.patch b/sys-libs/readline/files/readline-7.0-missing-echo-proto.patch
new file mode 100644
index 00000000000..cad3c8ca2c4
--- /dev/null
+++ b/sys-libs/readline/files/readline-7.0-missing-echo-proto.patch
@@ -0,0 +1,14 @@
+https://lists.gnu.org/archive/html/bug-readline/2016-11/msg00000.html
+
+fix from upstream
+
+--- a/readline.h
++++ b/readline.h
+@@ -413,6 +413,7 @@
+ extern void rl_tty_set_default_bindings PARAMS((Keymap));
+ extern void rl_tty_unset_default_bindings PARAMS((Keymap));
+
++extern int rl_tty_set_echoing PARAMS((int));
+ extern int rl_reset_terminal PARAMS((const char *));
+ extern void rl_resize_terminal PARAMS((void));
+ extern void rl_set_screen_size PARAMS((int, int));
diff --git a/sys-libs/readline/readline-6.3_p8-r3.ebuild b/sys-libs/readline/readline-6.3_p8-r3.ebuild
new file mode 100644
index 00000000000..009f74e037f
--- /dev/null
+++ b/sys-libs/readline/readline-6.3_p8-r3.ebuild
@@ -0,0 +1,163 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+inherit eutils multilib toolchain-funcs flag-o-matic multilib-minimal preserve-libs usr-ldscript
+
+# Official patches
+# See ftp://ftp.cwru.edu/pub/bash/readline-6.3-patches/
+PLEVEL=${PV##*_p}
+MY_PV=${PV/_p*}
+MY_PV=${MY_PV/_/-}
+MY_P=${PN}-${MY_PV}
+[[ ${PV} != *_p* ]] && PLEVEL=0
+patches() {
+ [[ ${PLEVEL} -eq 0 ]] && return 1
+ local opt=$1
+ eval set -- {1..${PLEVEL}}
+ set -- $(printf "${PN}${MY_PV/\.}-%03d " "$@")
+ if [[ ${opt} == -s ]] ; then
+ echo "${@/#/${DISTDIR}/}"
+ else
+ local u
+ for u in ftp://ftp.cwru.edu/pub/bash mirror://gnu/${PN} ; do
+ printf "${u}/${PN}-${MY_PV}-patches/%s " "$@"
+ done
+ fi
+}
+
+DESCRIPTION="Another cute console display library"
+HOMEPAGE="https://tiswww.case.edu/php/chet/readline/rltop.html"
+SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz $(patches)"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 s390 sparc x86 ~amd64-linux ~x86-linux"
+IUSE="static-libs utils"
+
+RDEPEND=">=sys-libs/ncurses-5.9-r3:0=[${MULTILIB_USEDEP}]"
+DEPEND="${RDEPEND}
+ virtual/pkgconfig"
+
+S=${WORKDIR}/${MY_P}
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-5.0-no_rpath.patch
+ "${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch #385091
+ "${FILESDIR}"/${PN}-6.3-fix-long-prompt-vi-search.patch
+ "${FILESDIR}"/${PN}-6.3-read-eof.patch
+)
+
+src_unpack() {
+ unpack ${MY_P}.tar.gz
+}
+
+src_prepare() {
+ [[ ${PLEVEL} -gt 0 ]] && epatch $(patches -s)
+ epatch "${PATCHES[@]}"
+
+ # Force ncurses linking. #71420
+ # Use pkg-config to get the right values. #457558
+ local ncurses_libs=$($(tc-getPKG_CONFIG) ncurses --libs)
+ sed -i \
+ -e "/^SHLIB_LIBS=/s:=.*:='${ncurses_libs}':" \
+ support/shobj-conf || die
+ sed -i \
+ -e "/^[[:space:]]*LIBS=.-lncurses/s:-lncurses:${ncurses_libs}:" \
+ examples/rlfe/configure || die
+
+ # fix building under Gentoo/FreeBSD; upstream FreeBSD deprecated
+ # objformat for years, so we don't want to rely on that.
+ sed -i -e '/objformat/s:if .*; then:if true; then:' support/shobj-conf || die
+
+ ln -s ../.. examples/rlfe/readline # for local readline headers
+}
+
+src_configure() {
+ # fix implicit decls with widechar funcs
+ append-cppflags -D_GNU_SOURCE
+ # https://lists.gnu.org/archive/html/bug-readline/2010-07/msg00013.html
+ append-cppflags -Dxrealloc=_rl_realloc -Dxmalloc=_rl_malloc -Dxfree=_rl_free
+
+ # Make sure configure picks a better ar than `ar`. #484866
+ export ac_cv_prog_AR=$(tc-getAR)
+
+ # Force the test since we used sed above to force it.
+ export bash_cv_termcap_lib=ncurses
+
+ # Control cross-compiling cases when we know the right answer.
+ # In cases where the C library doesn't support wide characters, readline
+ # itself won't work correctly, so forcing the answer below should be OK.
+ if tc-is-cross-compiler ; then
+ export bash_cv_func_sigsetjmp='present'
+ export bash_cv_func_ctype_nonascii='yes'
+ export bash_cv_wcwidth_broken='no' #503312
+ fi
+
+ # This is for rlfe, but we need to make sure LDFLAGS doesn't change
+ # so we can re-use the config cache file between the two.
+ append-ldflags -L.
+
+ multilib-minimal_src_configure
+}
+
+multilib_src_configure() {
+ ECONF_SOURCE=${S} \
+ econf \
+ --cache-file="${BUILD_DIR}"/config.cache \
+ --docdir='$(datarootdir)'/doc/${PF} \
+ --with-curses \
+ $(use_enable static-libs static)
+
+ if use utils && multilib_is_native_abi && ! tc-is-cross-compiler ; then
+ # code is full of AC_TRY_RUN()
+ mkdir -p examples/rlfe || die
+ cd examples/rlfe || die
+ ECONF_SOURCE=${S}/examples/rlfe \
+ econf --cache-file="${BUILD_DIR}"/config.cache
+ fi
+}
+
+multilib_src_compile() {
+ emake
+
+ if use utils && multilib_is_native_abi && ! tc-is-cross-compiler ; then
+ # code is full of AC_TRY_RUN()
+ cd examples/rlfe || die
+ local l
+ for l in readline history ; do
+ ln -s ../../shlib/lib${l}$(get_libname)* lib${l}$(get_libname)
+ ln -sf ../../lib${l}.a lib${l}.a
+ done
+ emake
+ fi
+}
+
+multilib_src_install() {
+ default
+
+ if multilib_is_native_abi ; then
+ gen_usr_ldscript -a readline history #4411
+
+ if use utils && ! tc-is-cross-compiler; then
+ dobin examples/rlfe/rlfe
+ fi
+ fi
+}
+
+multilib_src_install_all() {
+ einstalldocs
+ dodoc USAGE
+ dohtml -r doc/.
+ docinto ps
+ dodoc doc/*.ps
+}
+
+pkg_preinst() {
+ preserve_old_lib /$(get_libdir)/lib{history,readline}.so.{4,5} #29865
+}
+
+pkg_postinst() {
+ preserve_old_lib_notify /$(get_libdir)/lib{history,readline}.so.{4,5}
+}
diff --git a/sys-libs/readline/readline-7.0_p5-r1.ebuild b/sys-libs/readline/readline-7.0_p5-r1.ebuild
new file mode 100644
index 00000000000..00c928489ec
--- /dev/null
+++ b/sys-libs/readline/readline-7.0_p5-r1.ebuild
@@ -0,0 +1,174 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit flag-o-matic multilib-minimal toolchain-funcs preserve-libs usr-ldscript
+
+# Official patches
+# See ftp://ftp.cwru.edu/pub/bash/readline-7.0-patches/
+PLEVEL="${PV##*_p}"
+MY_PV="${PV/_p*}"
+MY_PV="${MY_PV/_/-}"
+MY_P="${PN}-${MY_PV}"
+[[ ${PV} != *_p* ]] && PLEVEL=0
+patches() {
+ [[ ${PLEVEL} -eq 0 ]] && return 1
+ local opt=$1
+ eval set -- {1..${PLEVEL}}
+ set -- $(printf "${PN}${MY_PV/\.}-%03d " "$@")
+ if [[ ${opt} == -s ]] ; then
+ echo "${@/#/${DISTDIR}/}"
+ else
+ local u
+ for u in ftp://ftp.cwru.edu/pub/bash mirror://gnu/${PN} ; do
+ printf "${u}/${PN}-${MY_PV}-patches/%s " "$@"
+ done
+ fi
+}
+
+DESCRIPTION="Another cute console display library"
+HOMEPAGE="https://tiswww.case.edu/php/chet/readline/rltop.html"
+
+case ${PV} in
+ *_alpha*|*_beta*|*_rc*)
+ SRC_URI+=" ftp://ftp.cwru.edu/pub/bash/${MY_P}.tar.gz"
+ ;;
+ *)
+ SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz $(patches)"
+ ;;
+esac
+
+LICENSE="GPL-3"
+SLOT="0/7" # subslot matches SONAME major
+KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv s390 sparc x86 ~amd64-linux ~x86-linux"
+IUSE="static-libs +unicode utils"
+
+RDEPEND=">=sys-libs/ncurses-5.9-r3:0=[static-libs?,unicode?,${MULTILIB_USEDEP}]"
+DEPEND="${RDEPEND}
+ virtual/pkgconfig"
+
+S=${WORKDIR}/${MY_P}
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-5.0-no_rpath.patch
+ "${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch #385091
+ "${FILESDIR}"/${PN}-7.0-headers.patch
+ "${FILESDIR}"/${PN}-7.0-missing-echo-proto.patch
+ "${FILESDIR}"/${PN}-7.0-mingw.patch
+)
+
+# Needed because we don't want the patches being unpacked
+# (which emits annoying and useless error messages)
+src_unpack() {
+ unpack ${MY_P}.tar.gz
+}
+
+src_prepare() {
+ [[ ${PLEVEL} -gt 0 ]] && eapply -p0 $(patches -s)
+ default
+
+ # Force ncurses linking. #71420
+ # Use pkg-config to get the right values. #457558
+ local ncurses_libs=$($(tc-getPKG_CONFIG) ncurses$(usex unicode w '') --libs)
+ sed -i \
+ -e "/^SHLIB_LIBS=/s:=.*:='${ncurses_libs}':" \
+ support/shobj-conf || die
+ sed -i \
+ -e "/^[[:space:]]*LIBS=.-lncurses/s:-lncurses:${ncurses_libs}:" \
+ examples/rlfe/configure || die
+
+ # fix building under Gentoo/FreeBSD; upstream FreeBSD deprecated
+ # objformat for years, so we don't want to rely on that.
+ sed -i -e '/objformat/s:if .*; then:if true; then:' support/shobj-conf || die
+
+ ln -s ../.. examples/rlfe/readline || die # for local readline headers
+}
+
+src_configure() {
+ # fix implicit decls with widechar funcs
+ append-cppflags -D_GNU_SOURCE
+ # https://lists.gnu.org/archive/html/bug-readline/2010-07/msg00013.html
+ append-cppflags -Dxrealloc=_rl_realloc -Dxmalloc=_rl_malloc -Dxfree=_rl_free
+
+ # Make sure configure picks a better ar than `ar`. #484866
+ export ac_cv_prog_AR=$(tc-getAR)
+
+ # Force the test since we used sed above to force it.
+ export bash_cv_termcap_lib=ncurses
+
+ # Control cross-compiling cases when we know the right answer.
+ # In cases where the C library doesn't support wide characters, readline
+ # itself won't work correctly, so forcing the answer below should be OK.
+ if tc-is-cross-compiler ; then
+ use kernel_Winnt || export bash_cv_func_sigsetjmp='present'
+ export bash_cv_func_ctype_nonascii='yes'
+ export bash_cv_wcwidth_broken='no' #503312
+ fi
+
+ # This is for rlfe, but we need to make sure LDFLAGS doesn't change
+ # so we can re-use the config cache file between the two.
+ append-ldflags -L.
+
+ multilib-minimal_src_configure
+}
+
+multilib_src_configure() {
+ local myeconfargs=(
+ --cache-file="${BUILD_DIR}"/config.cache
+ --with-curses
+ $(use_enable static-libs static)
+ )
+ ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
+
+ if use utils && multilib_is_native_abi && ! tc-is-cross-compiler ; then
+ # code is full of AC_TRY_RUN()
+ mkdir -p examples/rlfe || die
+ cd examples/rlfe || die
+ ECONF_SOURCE="${S}"/examples/rlfe \
+ econf --cache-file="${BUILD_DIR}"/config.cache
+ fi
+}
+
+multilib_src_compile() {
+ emake
+
+ if use utils && multilib_is_native_abi && ! tc-is-cross-compiler ; then
+ # code is full of AC_TRY_RUN()
+ cd examples/rlfe || die
+ local l
+ for l in readline history ; do
+ ln -s ../../shlib/lib${l}$(get_libname)* lib${l}$(get_libname) || die
+ ln -s ../../lib${l}.a lib${l}.a || die
+ done
+ emake
+ fi
+}
+
+multilib_src_install() {
+ default
+
+ if multilib_is_native_abi ; then
+ gen_usr_ldscript -a readline history #4411
+
+ if use utils && ! tc-is-cross-compiler; then
+ dobin examples/rlfe/rlfe
+ fi
+ fi
+}
+
+multilib_src_install_all() {
+ HTML_DOCS="doc/history.html doc/readline.html doc/rluserman.html" einstalldocs
+ dodoc USAGE
+ docinto ps
+ dodoc doc/*.ps
+}
+pkg_preinst() {
+ # bug #29865
+ # Reappeared in #595324 with paludis so keeping this for now...
+ preserve_old_lib /$(get_libdir)/lib{history,readline}.so.{4,5,6}
+}
+
+pkg_postinst() {
+ preserve_old_lib_notify /$(get_libdir)/lib{history,readline}.so.{4,5,6}
+}
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-libs/readline/, sys-libs/readline/files/
@ 2020-12-26 12:55 Fabian Groffen
0 siblings, 0 replies; 7+ messages in thread
From: Fabian Groffen @ 2020-12-26 12:55 UTC (permalink / raw
To: gentoo-commits
commit: 0744aa71b97569b82f51c23fc8164cf31f3d0382
Author: Fabian Groffen <grobian <AT> gentoo <DOT> org>
AuthorDate: Sat Dec 26 12:55:41 2020 +0000
Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org>
CommitDate: Sat Dec 26 12:55:41 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0744aa71
sys-libs/readline-8.1: add Prefix changes, bug #729980
Closes: https://bugs.gentoo.org/729980
Package-Manager: Portage-3.0.9, Repoman-3.0.2
Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org>
.../readline-8.0-darwin-shlib-versioning.patch | 41 ++++++++++++++++++++++
sys-libs/readline/readline-8.1.ebuild | 15 ++++++--
2 files changed, 53 insertions(+), 3 deletions(-)
diff --git a/sys-libs/readline/files/readline-8.0-darwin-shlib-versioning.patch b/sys-libs/readline/files/readline-8.0-darwin-shlib-versioning.patch
new file mode 100644
index 00000000000..88128008771
--- /dev/null
+++ b/sys-libs/readline/files/readline-8.0-darwin-shlib-versioning.patch
@@ -0,0 +1,41 @@
+darwin: don't do multi-arch stuff, just build a normal shared library
+
+--- a/support/shobj-conf
++++ b/support/shobj-conf
+@@ -180,34 +180,8 @@
+ SHLIB_LIBVERSION='$(SHLIB_MAJOR)$(SHLIB_MINOR).$(SHLIB_LIBSUFF)'
+ SHLIB_LIBSUFF='dylib'
+
+- # unused at this time
+- SHLIB_SONAME='$(libdir)/`echo $@ | sed "s:\\..*::"`.$(SHLIB_MAJOR).$(SHLIB_LIBSUFF)'
+-
+- case "${host_os}" in
+- # Darwin versions 1, 5, 6, 7 correspond to Mac OS X 10.0, 10.1, 10.2,
+- # and 10.3, respectively.
+- darwin[1-7].*)
+- SHOBJ_STATUS=unsupported
+- SHOBJ_LDFLAGS='-dynamic'
+- SHLIB_XLDFLAGS='-arch_only `/usr/bin/arch` -install_name $(libdir)/`echo $@ | sed "s:\\..*::"`.$(SHLIB_MAJOR).$(SHLIB_LIBSUFF) -current_version $(SHLIB_MAJOR)$(SHLIB_MINOR) -compatibility_version $(SHLIB_MAJOR)$(SHLIB_MINOR) -v'
+- ;;
+- # Darwin 8 == Mac OS X 10.4; Mac OS X 10.N == Darwin N+4
+- *)
+- case "${host_os}" in
+- darwin[89]*|darwin1[012]*)
+- SHOBJ_ARCHFLAGS='-arch_only `/usr/bin/arch`'
+- ;;
+- *) # Mac OS X 10.9 (Mavericks) and later
+- SHOBJ_ARCHFLAGS=
+- # for 32 and 64bit universal library
+- #SHOBJ_ARCHFLAGS='-arch i386 -arch x86_64'
+- #SHOBJ_CFLAGS=${SHOBJ_CFLAGS}' -arch i386 -arch x86_64'
+- ;;
+- esac
+- SHOBJ_LDFLAGS="-dynamiclib -dynamic -undefined dynamic_lookup ${SHOBJ_ARCHFLAGS}"
+- SHLIB_XLDFLAGS="-dynamiclib ${SHOBJ_ARCHFLAGS}"' -install_name $(libdir)/`echo $@ | sed "s:\\..*::"`.$(SHLIB_MAJOR).$(SHLIB_LIBSUFF) -current_version $(SHLIB_MAJOR)$(SHLIB_MINOR) -compatibility_version $(SHLIB_MAJOR)$(SHLIB_MINOR) -v'
+- ;;
+- esac
++ SHOBJ_LDFLAGS='-dynamiclib -dynamic -undefined dynamic_lookup'
++ SHLIB_XLDFLAGS='-dynamiclib -install_name $(libdir)/`basename $@ $(SHLIB_MINOR)$(SHLIB_DOT)$(SHLIB_LIBSUFF)`$(SHLIB_DOT)$(SHLIB_LIBSUFF) -current_version $(SHLIB_MAJOR)$(SHLIB_MINOR) -compatibility_version $(SHLIB_MAJOR)'
+
+ SHLIB_LIBS='-lncurses' # see if -lcurses works on MacOS X 10.1
+ ;;
diff --git a/sys-libs/readline/readline-8.1.ebuild b/sys-libs/readline/readline-8.1.ebuild
index 025bd0395bd..1fbdc060022 100644
--- a/sys-libs/readline/readline-8.1.ebuild
+++ b/sys-libs/readline/readline-8.1.ebuild
@@ -42,7 +42,7 @@ esac
LICENSE="GPL-3"
SLOT="0/8" # subslot matches SONAME major
[[ "${PV}" == *_rc* ]] || \
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
IUSE="static-libs +unicode utils"
RDEPEND=">=sys-libs/ncurses-5.9-r3:0=[static-libs?,unicode?,${MULTILIB_USEDEP}]"
@@ -58,6 +58,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch #385091
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
+ "${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
)
# Needed because we don't want the patches being unpacked
@@ -168,9 +169,17 @@ multilib_src_install_all() {
pkg_preinst() {
# bug #29865
# Reappeared in #595324 with paludis so keeping this for now...
- preserve_old_lib /$(get_libdir)/lib{history,readline}.so.{4,5,6,7}
+ preserve_old_lib \
+ /$(get_libdir)/lib{history,readline}$(get_libname 4) \
+ /$(get_libdir)/lib{history,readline}$(get_libname 5) \
+ /$(get_libdir)/lib{history,readline}$(get_libname 6) \
+ /$(get_libdir)/lib{history,readline}$(get_libname 7)
}
pkg_postinst() {
- preserve_old_lib_notify /$(get_libdir)/lib{history,readline}.so.{4,5,6,7}
+ preserve_old_lib_notify \
+ /$(get_libdir)/lib{history,readline}$(get_libname 4) \
+ /$(get_libdir)/lib{history,readline}$(get_libname 5) \
+ /$(get_libdir)/lib{history,readline}$(get_libname 6) \
+ /$(get_libdir)/lib{history,readline}$(get_libname 7)
}
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-libs/readline/, sys-libs/readline/files/
@ 2021-06-09 22:07 Mike Frysinger
0 siblings, 0 replies; 7+ messages in thread
From: Mike Frysinger @ 2021-06-09 22:07 UTC (permalink / raw
To: gentoo-commits
commit: be86ca1b22fb91e2ccc6e82719342b38d8ac2afe
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Wed Jun 9 22:06:54 2021 +0000
Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org>
CommitDate: Wed Jun 9 22:07:06 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=be86ca1b
sys-libs/readline: add upstream fix for Windows cross-compiling
Signed-off-by: Mike Frysinger <vapier <AT> gentoo.org>
.../files/readline-8.1-windows-signals.patch | 23 ++++++++++++++++++++++
sys-libs/readline/readline-8.1_p1.ebuild | 1 +
2 files changed, 24 insertions(+)
diff --git a/sys-libs/readline/files/readline-8.1-windows-signals.patch b/sys-libs/readline/files/readline-8.1-windows-signals.patch
new file mode 100644
index 00000000000..2f818fc7f9c
--- /dev/null
+++ b/sys-libs/readline/files/readline-8.1-windows-signals.patch
@@ -0,0 +1,23 @@
+fix from upstream
+
+commit 4be5608573b2be2e31f3d2a01446e22e1c9d7839
+Author: Chet Ramey <chet.ramey@case.edu>
+Date: Wed Jan 27 11:49:50 2021 -0500
+
+ commit bash-20210122 snapshot
+
+diff --git a/lib/readline/signals.c b/lib/readline/signals.c
+index 0943c643b27d..ecaf699e9261 100644
+--- a/signals.c
++++ b/signals.c
+@@ -266,8 +266,10 @@ _rl_handle_signal (int sig)
+ case SIGQUIT:
+ #endif
+
++#if defined (HAVE_POSIX_SIGNALS)
+ if (block_sig)
+ sigprocmask (SIG_BLOCK, &set, &oset);
++#endif
+
+ rl_echo_signal_char (sig);
+ rl_cleanup_after_signal ();
diff --git a/sys-libs/readline/readline-8.1_p1.ebuild b/sys-libs/readline/readline-8.1_p1.ebuild
index 944bdc74689..5cd7a3bdc21 100644
--- a/sys-libs/readline/readline-8.1_p1.ebuild
+++ b/sys-libs/readline/readline-8.1_p1.ebuild
@@ -59,6 +59,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
+ "${FILESDIR}"/${PN}-8.1-windows-signals.patch
)
# Needed because we don't want the patches being unpacked
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-libs/readline/, sys-libs/readline/files/
@ 2024-05-11 0:30 Sam James
0 siblings, 0 replies; 7+ messages in thread
From: Sam James @ 2024-05-11 0:30 UTC (permalink / raw
To: gentoo-commits
commit: 5f2879693f68d2a9a489d923ffd6e4ff96ec714b
Author: Gabi Falk <gabifalk <AT> gmx <DOT> com>
AuthorDate: Thu May 9 23:15:00 2024 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat May 11 00:26:39 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5f287969
sys-libs/readline: USE=utils: port to modern C (C99)
GCC 14 enables -Werror=implicit-function-declaration and
-Werror=implicit-int by default.
Closes: https://bugs.gentoo.org/870424
Closes: https://bugs.gentoo.org/919256
Link: https://lists.gnu.org/archive/html/bug-readline/2024-05/msg00000.html
Signed-off-by: Gabi Falk <gabifalk <AT> gmx.com>
Closes: https://github.com/gentoo/gentoo/pull/36621
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../readline/files/readline-8.1-rlfe-c99.patch | 1201 ++++++++++++++++++++
sys-libs/readline/readline-8.1_p2-r1.ebuild | 2 +-
sys-libs/readline/readline-8.1_p2-r2.ebuild | 2 +-
sys-libs/readline/readline-8.2_p10.ebuild | 2 +-
sys-libs/readline/readline-8.3_alpha.ebuild | 1 +
sys-libs/readline/readline-9999.ebuild | 1 +
6 files changed, 1206 insertions(+), 3 deletions(-)
diff --git a/sys-libs/readline/files/readline-8.1-rlfe-c99.patch b/sys-libs/readline/files/readline-8.1-rlfe-c99.patch
new file mode 100644
index 000000000000..028f44784207
--- /dev/null
+++ b/sys-libs/readline/files/readline-8.1-rlfe-c99.patch
@@ -0,0 +1,1201 @@
+From 565e32f70307a6c1771d19a7dd4041da84358d7f Mon Sep 17 00:00:00 2001
+From: Gabi Falk <gabifalk@gmx.com>
+Date: Thu, 9 May 2024 08:00:00 +0000
+Subject: [PATCH] examples/rlfe/configure.in: Port to modern C (C99)
+To: bug-readline@gnu.org
+Cc: Sam James <sam@gentoo.org>
+
+Due to changes in GCC 14 enabling -Werror=implicit-function-declaration
+and -Werror=implicit-int by default, without this change, this configure
+script fails with:
+configure: error: Can't run the compiler - sorry
+
+AC_USE_SYSTEM_EXTENSIONS is required because pts(4)-related functions
+ptsname(3), grantpt(3), and unlockpt(3) are not exposed otherwise.
+
+Link: https://bugs.gentoo.org/870424
+Link: https://bugs.gentoo.org/919256
+Link: https://lists.gnu.org/archive/html/bug-readline/2024-05/msg00000.html
+Signed-off-by: Gabi Falk <gabifalk@gmx.com>
+---
+ examples/rlfe/configure | 668 ++++++++++++++++++++-----------------
+ examples/rlfe/configure.in | 88 +++--
+ 2 files changed, 422 insertions(+), 334 deletions(-)
+
+diff --git a/examples/rlfe/configure b/examples/rlfe/configure
+index 3928331..063113d 100755
+--- a/examples/rlfe/configure
++++ b/examples/rlfe/configure
+@@ -1490,115 +1490,6 @@ fi
+
+ } # ac_fn_c_try_link
+
+-# ac_fn_c_try_run LINENO
+-# ----------------------
+-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
+-# that executables *can* be run.
+-ac_fn_c_try_run ()
+-{
+- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+- if { { ac_try="$ac_link"
+-case "(($ac_try" in
+- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+- *) ac_try_echo=$ac_try;;
+-esac
+-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+-$as_echo "$ac_try_echo"; } >&5
+- (eval "$ac_link") 2>&5
+- ac_status=$?
+- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
+- { { case "(($ac_try" in
+- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+- *) ac_try_echo=$ac_try;;
+-esac
+-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+-$as_echo "$ac_try_echo"; } >&5
+- (eval "$ac_try") 2>&5
+- ac_status=$?
+- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+- test $ac_status = 0; }; }; then :
+- ac_retval=0
+-else
+- $as_echo "$as_me: program exited with status $ac_status" >&5
+- $as_echo "$as_me: failed program was:" >&5
+-sed 's/^/| /' conftest.$ac_ext >&5
+-
+- ac_retval=$ac_status
+-fi
+- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
+- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
+- as_fn_set_status $ac_retval
+-
+-} # ac_fn_c_try_run
+-
+-# ac_fn_c_check_func LINENO FUNC VAR
+-# ----------------------------------
+-# Tests whether FUNC exists, setting the cache variable VAR accordingly
+-ac_fn_c_check_func ()
+-{
+- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+-$as_echo_n "checking for $2... " >&6; }
+-if eval \${$3+:} false; then :
+- $as_echo_n "(cached) " >&6
+-else
+- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h. */
+-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
+- For example, HP-UX 11i <limits.h> declares gettimeofday. */
+-#define $2 innocuous_$2
+-
+-/* System header to define __stub macros and hopefully few prototypes,
+- which can conflict with char $2 (); below.
+- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+- <limits.h> exists even on freestanding compilers. */
+-
+-#ifdef __STDC__
+-# include <limits.h>
+-#else
+-# include <assert.h>
+-#endif
+-
+-#undef $2
+-
+-/* Override any GCC internal prototype to avoid an error.
+- Use char because int might match the return type of a GCC
+- builtin and then its argument prototype would still apply. */
+-#ifdef __cplusplus
+-extern "C"
+-#endif
+-char $2 ();
+-/* The GNU C library defines this for functions which it implements
+- to always fail with ENOSYS. Some functions are actually named
+- something starting with __ and the normal name is an alias. */
+-#if defined __stub_$2 || defined __stub___$2
+-choke me
+-#endif
+-
+-int
+-main ()
+-{
+-return $2 ();
+- ;
+- return 0;
+-}
+-_ACEOF
+-if ac_fn_c_try_link "$LINENO"; then :
+- eval "$3=yes"
+-else
+- eval "$3=no"
+-fi
+-rm -f core conftest.err conftest.$ac_objext \
+- conftest$ac_exeext conftest.$ac_ext
+-fi
+-eval ac_res=\$$3
+- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+-$as_echo "$ac_res" >&6; }
+- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
+-
+-} # ac_fn_c_check_func
+-
+ # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
+ # -------------------------------------------------------
+ # Tests whether HEADER exists, giving a warning if it cannot be compiled using
+@@ -1686,6 +1577,48 @@ fi
+
+ } # ac_fn_c_check_header_mongrel
+
++# ac_fn_c_try_run LINENO
++# ----------------------
++# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
++# that executables *can* be run.
++ac_fn_c_try_run ()
++{
++ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
++ if { { ac_try="$ac_link"
++case "(($ac_try" in
++ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
++ *) ac_try_echo=$ac_try;;
++esac
++eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
++$as_echo "$ac_try_echo"; } >&5
++ (eval "$ac_link") 2>&5
++ ac_status=$?
++ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
++ test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
++ { { case "(($ac_try" in
++ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
++ *) ac_try_echo=$ac_try;;
++esac
++eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
++$as_echo "$ac_try_echo"; } >&5
++ (eval "$ac_try") 2>&5
++ ac_status=$?
++ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
++ test $ac_status = 0; }; }; then :
++ ac_retval=0
++else
++ $as_echo "$as_me: program exited with status $ac_status" >&5
++ $as_echo "$as_me: failed program was:" >&5
++sed 's/^/| /' conftest.$ac_ext >&5
++
++ ac_retval=$ac_status
++fi
++ rm -rf conftest.dSYM conftest_ipa8_conftest.oo
++ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
++ as_fn_set_status $ac_retval
++
++} # ac_fn_c_try_run
++
+ # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
+ # -------------------------------------------------------
+ # Tests whether HEADER exists and can be compiled using the include files in
+@@ -1716,6 +1649,73 @@ $as_echo "$ac_res" >&6; }
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
+
+ } # ac_fn_c_check_header_compile
++
++# ac_fn_c_check_func LINENO FUNC VAR
++# ----------------------------------
++# Tests whether FUNC exists, setting the cache variable VAR accordingly
++ac_fn_c_check_func ()
++{
++ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
++$as_echo_n "checking for $2... " >&6; }
++if eval \${$3+:} false; then :
++ $as_echo_n "(cached) " >&6
++else
++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h. */
++/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
++ For example, HP-UX 11i <limits.h> declares gettimeofday. */
++#define $2 innocuous_$2
++
++/* System header to define __stub macros and hopefully few prototypes,
++ which can conflict with char $2 (); below.
++ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
++ <limits.h> exists even on freestanding compilers. */
++
++#ifdef __STDC__
++# include <limits.h>
++#else
++# include <assert.h>
++#endif
++
++#undef $2
++
++/* Override any GCC internal prototype to avoid an error.
++ Use char because int might match the return type of a GCC
++ builtin and then its argument prototype would still apply. */
++#ifdef __cplusplus
++extern "C"
++#endif
++char $2 ();
++/* The GNU C library defines this for functions which it implements
++ to always fail with ENOSYS. Some functions are actually named
++ something starting with __ and the normal name is an alias. */
++#if defined __stub_$2 || defined __stub___$2
++choke me
++#endif
++
++int
++main ()
++{
++return $2 ();
++ ;
++ return 0;
++}
++_ACEOF
++if ac_fn_c_try_link "$LINENO"; then :
++ eval "$3=yes"
++else
++ eval "$3=no"
++fi
++rm -f core conftest.err conftest.$ac_objext \
++ conftest$ac_exeext conftest.$ac_ext
++fi
++eval ac_res=\$$3
++ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
++$as_echo "$ac_res" >&6; }
++ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
++
++} # ac_fn_c_check_func
+ cat >config.log <<_ACEOF
+ This file contains any messages produced by compilers while
+ running configure, to aid debugging if configure makes a mistake.
+@@ -3233,32 +3233,223 @@ if test "$ac_res" != no; then :
+ fi
+
+
+-if test "$cross_compiling" = yes; then :
+- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+-as_fn_error $? "cannot run test program while cross compiling
+-See \`config.log' for more details" "$LINENO" 5; }
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
++$as_echo_n "checking for ANSI C header files... " >&6; }
++if ${ac_cv_header_stdc+:} false; then :
++ $as_echo_n "(cached) " >&6
+ else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-main(){exit(0);}
+-_ACEOF
+-if ac_fn_c_try_run "$LINENO"; then :
+-
+-else
+-
+-if test $CC != cc ; then
+-echo "Your $CC failed - restarting with CC=cc" 1>&6
++#include <stdlib.h>
++#include <stdarg.h>
++#include <string.h>
++#include <float.h>
+
+-echo "" 1>&6
++int
++main ()
++{
+
+-CC=cc
+-export CC
+-exec $0 $configure_args
++ ;
++ return 0;
++}
++_ACEOF
++if ac_fn_c_try_compile "$LINENO"; then :
++ ac_cv_header_stdc=yes
++else
++ ac_cv_header_stdc=no
+ fi
++rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
+-fi
+-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
++if test $ac_cv_header_stdc = yes; then
++ # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h. */
++#include <string.h>
++
++_ACEOF
++if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
++ $EGREP "memchr" >/dev/null 2>&1; then :
++
++else
++ ac_cv_header_stdc=no
++fi
++rm -f conftest*
++
++fi
++
++if test $ac_cv_header_stdc = yes; then
++ # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h. */
++#include <stdlib.h>
++
++_ACEOF
++if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
++ $EGREP "free" >/dev/null 2>&1; then :
++
++else
++ ac_cv_header_stdc=no
++fi
++rm -f conftest*
++
++fi
++
++if test $ac_cv_header_stdc = yes; then
++ # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
++ if test "$cross_compiling" = yes; then :
++ :
++else
++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h. */
++#include <ctype.h>
++#include <stdlib.h>
++#if ((' ' & 0x0FF) == 0x020)
++# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
++# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
++#else
++# define ISLOWER(c) \
++ (('a' <= (c) && (c) <= 'i') \
++ || ('j' <= (c) && (c) <= 'r') \
++ || ('s' <= (c) && (c) <= 'z'))
++# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
++#endif
++
++#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
++int
++main ()
++{
++ int i;
++ for (i = 0; i < 256; i++)
++ if (XOR (islower (i), ISLOWER (i))
++ || toupper (i) != TOUPPER (i))
++ return 2;
++ return 0;
++}
++_ACEOF
++if ac_fn_c_try_run "$LINENO"; then :
++
++else
++ ac_cv_header_stdc=no
++fi
++rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
++ conftest.$ac_objext conftest.beam conftest.$ac_ext
++fi
++
++fi
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
++$as_echo "$ac_cv_header_stdc" >&6; }
++if test $ac_cv_header_stdc = yes; then
++
++$as_echo "#define STDC_HEADERS 1" >>confdefs.h
++
++fi
++
++# On IRIX 5.3, sys/types and inttypes.h are conflicting.
++for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
++ inttypes.h stdint.h unistd.h
++do :
++ as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
++ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
++"
++if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
++ cat >>confdefs.h <<_ACEOF
++#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
++_ACEOF
++
++fi
++
++done
++
++
++
++ ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
++if test "x$ac_cv_header_minix_config_h" = xyes; then :
++ MINIX=yes
++else
++ MINIX=
++fi
++
++
++ if test "$MINIX" = yes; then
++
++$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
++
++
++$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
++
++
++$as_echo "#define _MINIX 1" >>confdefs.h
++
++ fi
++
++
++ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
++$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
++if ${ac_cv_safe_to_define___extensions__+:} false; then :
++ $as_echo_n "(cached) " >&6
++else
++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h. */
++
++# define __EXTENSIONS__ 1
++ $ac_includes_default
++int
++main ()
++{
++
++ ;
++ return 0;
++}
++_ACEOF
++if ac_fn_c_try_compile "$LINENO"; then :
++ ac_cv_safe_to_define___extensions__=yes
++else
++ ac_cv_safe_to_define___extensions__=no
++fi
++rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
++$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
++ test $ac_cv_safe_to_define___extensions__ = yes &&
++ $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
++
++ $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
++
++ $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
++
++ $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
++
++ $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
++
++
++
++if test "$cross_compiling" = yes; then :
++ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
++$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
++as_fn_error $? "cannot run test program while cross compiling
++See \`config.log' for more details" "$LINENO" 5; }
++else
++ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
++/* end confdefs.h. */
++int main(){return 0;}
++_ACEOF
++if ac_fn_c_try_run "$LINENO"; then :
++
++else
++
++if test $CC != cc ; then
++echo "Your $CC failed - restarting with CC=cc" 1>&6
++
++echo "" 1>&6
++
++CC=cc
++export CC
++exec $0 $configure_args
++fi
++
++fi
++rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+ conftest.$ac_objext conftest.beam conftest.$ac_ext
+ fi
+
+@@ -3271,7 +3462,7 @@ See \`config.log' for more details" "$LINENO" 5; }
+ else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-main(){exit(0);}
++int main(){return 0;}
+ _ACEOF
+ if ac_fn_c_try_run "$LINENO"; then :
+
+@@ -3298,6 +3489,7 @@ else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+
++int
+ main()
+ {
+ int __something_strange_();
+@@ -3407,7 +3599,7 @@ rm -f conftest*
+ $as_echo "$as_me: checking select..." >&6;}
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-
++#include <sys/select.h>
+ int
+ main ()
+ {
+@@ -3424,7 +3616,7 @@ else
+ $as_echo "$as_me: checking select with $LIBS..." >&6;}
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-
++#include <sys/select.h>
+ int
+ main ()
+ {
+@@ -3459,6 +3651,8 @@ else
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <fcntl.h>
++#include <signal.h>
++#include <unistd.h>
+
+ char *nam = "/tmp/conftest$$";
+
+@@ -3471,7 +3665,7 @@ char *nam = "/tmp/conftest$$";
+ #define S_IFIFO 0010000
+ #endif
+
+-
++int
+ main()
+ {
+ #ifdef FD_SET
+@@ -3485,7 +3679,7 @@ main()
+ * opening RDWR fifo fails in BSD 4.4, but select return values are
+ * right.
+ */
+- exit(0);
++ return 0;
+ #endif
+ (void)alarm(5);
+ #ifdef POSIX
+@@ -3493,12 +3687,12 @@ main()
+ #else
+ if (mknod(nam, S_IFIFO|0777, 0))
+ #endif
+- exit(1);
++ return 1;
+ close(0);
+ if (open(nam, O_RDWR | O_NONBLOCK))
+- exit(1);
++ return 1;
+ if (write(0, "TEST", 4) == -1)
+- exit(1);
++ return 1;
+
+ #else
+
+@@ -3506,6 +3700,7 @@ main()
+ #include <sys/socket.h>
+ #include <sys/un.h>
+
++int
+ main()
+ {
+ int s1, s2, l;
+@@ -3518,14 +3713,14 @@ main()
+
+ (void)alarm(5);
+ if ((s1 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
+- exit(1);
++ return 1;
+ a.sun_family = AF_UNIX;
+ strcpy(a.sun_path, nam);
+ (void) unlink(nam);
+ if (bind(s1, (struct sockaddr *) &a, strlen(nam)+2) == -1)
+- exit(1);
++ return 1;
+ if (listen(s1, 2))
+- exit(1);
++ return 1;
+ if (fork() == 0)
+ {
+ if ((s2 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
+@@ -3533,12 +3728,12 @@ main()
+ (void)connect(s2, (struct sockaddr *)&a, strlen(nam) + 2);
+ if (write(s2, "HELLO", 5) == -1)
+ kill(getppid(), 3);
+- exit(0);
++ return 0;
+ }
+ l = sizeof(a);
+ close(0);
+ if (accept(s1, (struct sockaddr *)&a, &l))
+- exit(1);
++ return 1;
+ #endif
+
+
+@@ -3548,10 +3743,10 @@ main()
+ f = 1;
+ #endif
+ if (select(1, &f, 0, 0, 0) == -1)
+- exit(1);
++ return 1;
+ if (select(1, &f, &f, 0, 0) != 2)
+- exit(1);
+- exit(0);
++ return 1;
++ return 0;
+ }
+
+ _ACEOF
+@@ -3572,11 +3767,11 @@ fi
+ $as_echo "$as_me: checking for tgetent..." >&6;}
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-
++extern char tgetent(void);
+ int
+ main ()
+ {
+-tgetent((char *)0, (char *)0);
++tgetent();
+ ;
+ return 0;
+ }
+@@ -3590,7 +3785,7 @@ LIBS="-lcurses $olibs"
+ $as_echo "$as_me: checking libcurses..." >&6;}
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-
++extern char tgetent(void);
+ int
+ main ()
+ {
+@@ -3598,7 +3793,7 @@ main ()
+ #ifdef __hpux
+ __sorry_hpux_libcurses_is_totally_broken_in_10_10();
+ #else
+-tgetent((char *)0, (char *)0);
++tgetent();
+ #endif
+
+ ;
+@@ -3613,11 +3808,11 @@ else
+ $as_echo "$as_me: checking libtermcap..." >&6;}
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-
++extern char tgetent(void);
+ int
+ main ()
+ {
+-tgetent((char *)0, (char *)0);
++tgetent();
+ ;
+ return 0;
+ }
+@@ -3630,11 +3825,11 @@ else
+ $as_echo "$as_me: checking libtermlib..." >&6;}
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-
++extern char tgetent(void);
+ int
+ main ()
+ {
+-tgetent((char *)0, (char *)0);
++tgetent();
+ ;
+ return 0;
+ }
+@@ -3647,11 +3842,11 @@ else
+ $as_echo "$as_me: checking libncurses..." >&6;}
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-
++extern char tgetent(void);
+ int
+ main ()
+ {
+-tgetent((char *)0, (char *)0);
++tgetent();
+ ;
+ return 0;
+ }
+@@ -3685,10 +3880,13 @@ else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+
++#include <string.h>
+ extern char *tgoto();
++
++int
+ main()
+ {
+- exit(strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1);
++ return strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1;
+ }
+ _ACEOF
+ if ac_fn_c_try_run "$LINENO"; then :
+@@ -3738,7 +3936,7 @@ sysvr4ptys=
+ if test -c /dev/ptmx ; then
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ /* end confdefs.h. */
+-
++#include <stdlib.h>
+ int
+ main ()
+ {
+@@ -3898,6 +4096,10 @@ else
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <stdio.h>
++#include <stdlib.h>
++#include <unistd.h>
++
++int
+ main()
+ {
+ struct stat sb;
+@@ -3905,22 +4107,22 @@ main()
+ int om, m;
+ FILE *fp;
+
+- if (!(x = ttyname(0))) exit(1);
+- if (stat(x, &sb)) exit(1);
++ if (!(x = ttyname(0))) return 1;
++ if (stat(x, &sb)) return 1;
+ om = sb.st_mode;
+- if (om & 002) exit(0);
++ if (om & 002) return 0;
+ m = system("mesg y");
+- if (m == -1 || m == 127) exit(1);
+- if (stat(x, &sb)) exit(1);
++ if (m == -1 || m == 127) return 1;
++ if (stat(x, &sb)) return 1;
+ m = sb.st_mode;
+- if (chmod(x, om)) exit(1);
+- if (m & 002) exit(0);
+- if (sb.st_gid == getgid()) exit(1);
++ if (chmod(x, om)) return 1;
++ if (m & 002) return 0;
++ if (sb.st_gid == getgid()) return 1;
+ if (!(fp=fopen("conftest_grp", "w")))
+- exit(1);
++ return 1;
+ fprintf(fp, "%d\n", sb.st_gid);
+ fclose(fp);
+- exit(0);
++ return 0;
+ }
+
+ _ACEOF
+@@ -4166,6 +4368,7 @@ hand()
+ got++;
+ }
+
++int
+ main()
+ {
+ /* on hpux we use sigvec to get bsd signals */
+@@ -4174,9 +4377,9 @@ main()
+ kill(getpid(), SIGCLD);
+ kill(getpid(), SIGCLD);
+ if (got < 2)
+- exit(1);
++ return 1;
+ #endif
+- exit(0);
++ return 0;
+ }
+
+ _ACEOF
+@@ -4193,135 +4396,6 @@ fi
+
+ fi
+
+-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
+-$as_echo_n "checking for ANSI C header files... " >&6; }
+-if ${ac_cv_header_stdc+:} false; then :
+- $as_echo_n "(cached) " >&6
+-else
+- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h. */
+-#include <stdlib.h>
+-#include <stdarg.h>
+-#include <string.h>
+-#include <float.h>
+-
+-int
+-main ()
+-{
+-
+- ;
+- return 0;
+-}
+-_ACEOF
+-if ac_fn_c_try_compile "$LINENO"; then :
+- ac_cv_header_stdc=yes
+-else
+- ac_cv_header_stdc=no
+-fi
+-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+-
+-if test $ac_cv_header_stdc = yes; then
+- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
+- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h. */
+-#include <string.h>
+-
+-_ACEOF
+-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+- $EGREP "memchr" >/dev/null 2>&1; then :
+-
+-else
+- ac_cv_header_stdc=no
+-fi
+-rm -f conftest*
+-
+-fi
+-
+-if test $ac_cv_header_stdc = yes; then
+- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
+- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h. */
+-#include <stdlib.h>
+-
+-_ACEOF
+-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+- $EGREP "free" >/dev/null 2>&1; then :
+-
+-else
+- ac_cv_header_stdc=no
+-fi
+-rm -f conftest*
+-
+-fi
+-
+-if test $ac_cv_header_stdc = yes; then
+- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
+- if test "$cross_compiling" = yes; then :
+- :
+-else
+- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+-/* end confdefs.h. */
+-#include <ctype.h>
+-#include <stdlib.h>
+-#if ((' ' & 0x0FF) == 0x020)
+-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
+-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
+-#else
+-# define ISLOWER(c) \
+- (('a' <= (c) && (c) <= 'i') \
+- || ('j' <= (c) && (c) <= 'r') \
+- || ('s' <= (c) && (c) <= 'z'))
+-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
+-#endif
+-
+-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
+-int
+-main ()
+-{
+- int i;
+- for (i = 0; i < 256; i++)
+- if (XOR (islower (i), ISLOWER (i))
+- || toupper (i) != TOUPPER (i))
+- return 2;
+- return 0;
+-}
+-_ACEOF
+-if ac_fn_c_try_run "$LINENO"; then :
+-
+-else
+- ac_cv_header_stdc=no
+-fi
+-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+- conftest.$ac_objext conftest.beam conftest.$ac_ext
+-fi
+-
+-fi
+-fi
+-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
+-$as_echo "$ac_cv_header_stdc" >&6; }
+-if test $ac_cv_header_stdc = yes; then
+-
+-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
+-
+-fi
+-
+-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
+-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
+- inttypes.h stdint.h unistd.h
+-do :
+- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
+-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
+-"
+-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
+- cat >>confdefs.h <<_ACEOF
+-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
+-_ACEOF
+-
+-fi
+-
+-done
+-
+-
+ for ac_header in sys/stropts.h sys/wait.h sgtty.h sys/select.h
+ do :
+ as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
+diff --git a/examples/rlfe/configure.in b/examples/rlfe/configure.in
+index ad7ce65..aba06c6 100644
+--- a/examples/rlfe/configure.in
++++ b/examples/rlfe/configure.in
+@@ -30,7 +30,9 @@ AC_PROG_CPP
+ AC_PROG_GCC_TRADITIONAL
+ AC_ISC_POSIX
+
+-AC_TRY_RUN(main(){exit(0);},,[
++AC_USE_SYSTEM_EXTENSIONS
++
++AC_TRY_RUN([int main(){return 0;}],,[
+ if test $CC != cc ; then
+ AC_NOTE(Your $CC failed - restarting with CC=cc)
+ AC_NOTE()
+@@ -40,7 +42,7 @@ exec $0 $configure_args
+ fi
+ ])
+
+-AC_TRY_RUN(main(){exit(0);},,
++AC_TRY_RUN([int main(){return 0;}],,
+ exec 5>&2
+ eval $ac_link
+ AC_NOTE(CC=$CC; CFLAGS=$CFLAGS; LIBS=$LIBS;)
+@@ -48,6 +50,7 @@ AC_NOTE($ac_compile)
+ AC_MSG_ERROR(Can't run the compiler - sorry))
+
+ AC_TRY_RUN([
++int
+ main()
+ {
+ int __something_strange_();
+@@ -84,10 +87,10 @@ dnl **** select() ****
+ dnl
+
+ AC_CHECKING(select)
+-AC_TRY_LINK(,[select(0, 0, 0, 0, 0);],,
++AC_TRY_LINK([#include <sys/select.h>],[select(0, 0, 0, 0, 0);],,
+ LIBS="$LIBS -lnet -lnsl"
+ AC_CHECKING(select with $LIBS)
+-AC_TRY_LINK(,[select(0, 0, 0, 0, 0);],,
++AC_TRY_LINK([#include <sys/select.h>],[select(0, 0, 0, 0, 0);],,
+ AC_MSG_ERROR(!!! no select - no screen))
+ )
+ dnl
+@@ -99,6 +102,8 @@ AC_TRY_RUN([
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <fcntl.h>
++#include <signal.h>
++#include <unistd.h>
+
+ char *nam = "/tmp/conftest$$";
+
+@@ -111,7 +116,7 @@ char *nam = "/tmp/conftest$$";
+ #define S_IFIFO 0010000
+ #endif
+
+-
++int
+ main()
+ {
+ #ifdef FD_SET
+@@ -125,7 +130,7 @@ main()
+ * opening RDWR fifo fails in BSD 4.4, but select return values are
+ * right.
+ */
+- exit(0);
++ return 0;
+ #endif
+ (void)alarm(5);
+ #ifdef POSIX
+@@ -133,12 +138,12 @@ main()
+ #else
+ if (mknod(nam, S_IFIFO|0777, 0))
+ #endif
+- exit(1);
++ return 1;
+ close(0);
+ if (open(nam, O_RDWR | O_NONBLOCK))
+- exit(1);
++ return 1;
+ if (write(0, "TEST", 4) == -1)
+- exit(1);
++ return 1;
+
+ #else
+
+@@ -146,6 +151,7 @@ main()
+ #include <sys/socket.h>
+ #include <sys/un.h>
+
++int
+ main()
+ {
+ int s1, s2, l;
+@@ -158,14 +164,14 @@ main()
+
+ (void)alarm(5);
+ if ((s1 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
+- exit(1);
++ return 1;
+ a.sun_family = AF_UNIX;
+ strcpy(a.sun_path, nam);
+ (void) unlink(nam);
+ if (bind(s1, (struct sockaddr *) &a, strlen(nam)+2) == -1)
+- exit(1);
++ return 1;
+ if (listen(s1, 2))
+- exit(1);
++ return 1;
+ if (fork() == 0)
+ {
+ if ((s2 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
+@@ -173,12 +179,12 @@ main()
+ (void)connect(s2, (struct sockaddr *)&a, strlen(nam) + 2);
+ if (write(s2, "HELLO", 5) == -1)
+ kill(getppid(), 3);
+- exit(0);
++ return 0;
+ }
+ l = sizeof(a);
+ close(0);
+ if (accept(s1, (struct sockaddr *)&a, &l))
+- exit(1);
++ return 1;
+ #endif
+
+
+@@ -188,10 +194,10 @@ main()
+ f = 1;
+ #endif
+ if (select(1, &f, 0, 0, 0) == -1)
+- exit(1);
++ return 1;
+ if (select(1, &f, &f, 0, 0) != 2)
+- exit(1);
+- exit(0);
++ return 1;
++ return 0;
+ }
+ ],AC_NOTE(- select is ok),
+ AC_NOTE(- select can't count) AC_DEFINE(SELECT_BROKEN))
+@@ -200,33 +206,36 @@ dnl
+ dnl **** termcap or terminfo ****
+ dnl
+ AC_CHECKING(for tgetent)
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
++AC_TRY_LINK([extern char tgetent(void);],tgetent();,,
+ olibs="$LIBS"
+ LIBS="-lcurses $olibs"
+ AC_CHECKING(libcurses)
+-AC_TRY_LINK(,[
++AC_TRY_LINK([extern char tgetent(void);],[
+ #ifdef __hpux
+ __sorry_hpux_libcurses_is_totally_broken_in_10_10();
+ #else
+-tgetent((char *)0, (char *)0);
++tgetent();
+ #endif
+ ],,
+ LIBS="-ltermcap $olibs"
+ AC_CHECKING(libtermcap)
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
++AC_TRY_LINK([extern char tgetent(void);],tgetent();,,
+ LIBS="-ltermlib $olibs"
+ AC_CHECKING(libtermlib)
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
++AC_TRY_LINK([extern char tgetent(void);],tgetent();,,
+ LIBS="-lncurses $olibs"
+ AC_CHECKING(libncurses)
+-AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
++AC_TRY_LINK([extern char tgetent(void);],tgetent();,,
+ AC_MSG_ERROR(!!! no tgetent - no screen))))))
+
+ AC_TRY_RUN([
++#include <string.h>
+ extern char *tgoto();
++
++int
+ main()
+ {
+- exit(strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1);
++ return strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1;
+ }], AC_NOTE(- you use the termcap database),
+ AC_NOTE(- you use the terminfo database) AC_DEFINE(TERMINFO))
+ AC_CHECKING(ospeed)
+@@ -243,7 +252,7 @@ fi
+ AC_CHECKING(for SVR4 ptys)
+ sysvr4ptys=
+ if test -c /dev/ptmx ; then
+-AC_TRY_LINK([],[ptsname(0);grantpt(0);unlockpt(0);],[AC_DEFINE(HAVE_SVR4_PTYS)
++AC_TRY_LINK([#include <stdlib.h>],[ptsname(0);grantpt(0);unlockpt(0);],[AC_DEFINE(HAVE_SVR4_PTYS)
+ sysvr4ptys=1])
+ fi
+
+@@ -296,6 +305,10 @@ AC_TRY_RUN([
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <stdio.h>
++#include <stdlib.h>
++#include <unistd.h>
++
++int
+ main()
+ {
+ struct stat sb;
+@@ -303,22 +316,22 @@ main()
+ int om, m;
+ FILE *fp;
+
+- if (!(x = ttyname(0))) exit(1);
+- if (stat(x, &sb)) exit(1);
++ if (!(x = ttyname(0))) return 1;
++ if (stat(x, &sb)) return 1;
+ om = sb.st_mode;
+- if (om & 002) exit(0);
++ if (om & 002) return 0;
+ m = system("mesg y");
+- if (m == -1 || m == 127) exit(1);
+- if (stat(x, &sb)) exit(1);
++ if (m == -1 || m == 127) return 1;
++ if (stat(x, &sb)) return 1;
+ m = sb.st_mode;
+- if (chmod(x, om)) exit(1);
+- if (m & 002) exit(0);
+- if (sb.st_gid == getgid()) exit(1);
++ if (chmod(x, om)) return 1;
++ if (m & 002) return 0;
++ if (sb.st_gid == getgid()) return 1;
+ if (!(fp=fopen("conftest_grp", "w")))
+- exit(1);
++ return 1;
+ fprintf(fp, "%d\n", sb.st_gid);
+ fclose(fp);
+- exit(0);
++ return 0;
+ }
+ ],[
+ if test -f conftest_grp; then
+@@ -420,6 +433,7 @@ hand()
+ got++;
+ }
+
++int
+ main()
+ {
+ /* on hpux we use sigvec to get bsd signals */
+@@ -428,9 +442,9 @@ main()
+ kill(getpid(), SIGCLD);
+ kill(getpid(), SIGCLD);
+ if (got < 2)
+- exit(1);
++ return 1;
+ #endif
+- exit(0);
++ return 0;
+ }
+ ],,AC_DEFINE(SYSVSIGS))
+
diff --git a/sys-libs/readline/readline-8.1_p2-r1.ebuild b/sys-libs/readline/readline-8.1_p2-r1.ebuild
index 8c2239444310..f05a1ab99847 100644
--- a/sys-libs/readline/readline-8.1_p2-r1.ebuild
+++ b/sys-libs/readline/readline-8.1_p2-r1.ebuild
@@ -73,11 +73,11 @@ BDEPEND="virtual/pkgconfig
PATCHES=(
"${FILESDIR}"/${PN}-5.0-no_rpath.patch
- "${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch #385091
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
"${FILESDIR}"/${PN}-8.1-windows-signals.patch
+ "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
)
# Needed because we don't want the patches being unpacked
diff --git a/sys-libs/readline/readline-8.1_p2-r2.ebuild b/sys-libs/readline/readline-8.1_p2-r2.ebuild
index 8c2239444310..f05a1ab99847 100644
--- a/sys-libs/readline/readline-8.1_p2-r2.ebuild
+++ b/sys-libs/readline/readline-8.1_p2-r2.ebuild
@@ -73,11 +73,11 @@ BDEPEND="virtual/pkgconfig
PATCHES=(
"${FILESDIR}"/${PN}-5.0-no_rpath.patch
- "${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch #385091
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
"${FILESDIR}"/${PN}-8.1-windows-signals.patch
+ "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
)
# Needed because we don't want the patches being unpacked
diff --git a/sys-libs/readline/readline-8.2_p10.ebuild b/sys-libs/readline/readline-8.2_p10.ebuild
index 26af570758a2..0abd43ece110 100644
--- a/sys-libs/readline/readline-8.2_p10.ebuild
+++ b/sys-libs/readline/readline-8.2_p10.ebuild
@@ -93,9 +93,9 @@ BDEPEND="virtual/pkgconfig
PATCHES=(
"${FILESDIR}"/${PN}-5.0-no_rpath.patch
- "${FILESDIR}"/${PN}-6.2-rlfe-tgoto.patch # bug #385091
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
+ "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
# TODO: rebase
#"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
diff --git a/sys-libs/readline/readline-8.3_alpha.ebuild b/sys-libs/readline/readline-8.3_alpha.ebuild
index 616ce593d07b..24f51a007309 100644
--- a/sys-libs/readline/readline-8.3_alpha.ebuild
+++ b/sys-libs/readline/readline-8.3_alpha.ebuild
@@ -97,6 +97,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-5.0-no_rpath.patch
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
+ "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
# TODO: rebase
#"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
diff --git a/sys-libs/readline/readline-9999.ebuild b/sys-libs/readline/readline-9999.ebuild
index 616ce593d07b..24f51a007309 100644
--- a/sys-libs/readline/readline-9999.ebuild
+++ b/sys-libs/readline/readline-9999.ebuild
@@ -97,6 +97,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-5.0-no_rpath.patch
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
+ "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
# TODO: rebase
#"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: sys-libs/readline/, sys-libs/readline/files/
@ 2024-05-11 0:42 Sam James
0 siblings, 0 replies; 7+ messages in thread
From: Sam James @ 2024-05-11 0:42 UTC (permalink / raw
To: gentoo-commits
commit: 02041c52541f9634f25cedaa27f6506698cb287e
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sat May 11 00:41:20 2024 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat May 11 00:41:20 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=02041c52
sys-libs/readline: move C99 patch to devspace
While at it, sync src_unpack with app-shells/bash, as we need that
to avoid trying and failing to verify an unsigned patch from devspace.
Signed-off-by: Sam James <sam <AT> gentoo.org>
sys-libs/readline/Manifest | 1 +
.../readline/files/readline-8.1-rlfe-c99.patch | 1192 --------------------
sys-libs/readline/readline-8.1_p2-r1.ebuild | 26 +-
sys-libs/readline/readline-8.1_p2-r2.ebuild | 26 +-
sys-libs/readline/readline-8.2_p10.ebuild | 25 +-
sys-libs/readline/readline-8.3_alpha.ebuild | 26 +-
sys-libs/readline/readline-9999.ebuild | 22 +-
7 files changed, 98 insertions(+), 1220 deletions(-)
diff --git a/sys-libs/readline/Manifest b/sys-libs/readline/Manifest
index 0d184ee7215e..f58de6b40340 100644
--- a/sys-libs/readline/Manifest
+++ b/sys-libs/readline/Manifest
@@ -1,3 +1,4 @@
+DIST readline-8.1-rlfe-c99.patch.xz 5756 BLAKE2B fb2df42d2c16bef68a3716c55374da7a9d95c8f4c5645da9a60aa72624d5baa50c70da78292adcb20e5fb11f28d6320d627522bc4c8faf0f7c4c782fd75664e8 SHA512 1bad39eff82212ed2cd5ae4ff574a4cdbe20ee56ecac1bae469c90304573d10ed82fdab75bc09725e400dbb5568a34345f3241a409b7ede5645a3c02c0101018
DIST readline-8.1.tar.gz 2993288 BLAKE2B f0feca1ea3517b2b613adacac8c997cce0e86aa2f410c82a40ce1a2e128067112b4c68dbf25b808291c28c47583345abac994ce10b8d117958afcb96ee5e7c69 SHA512 27790d0461da3093a7fee6e89a51dcab5dc61928ec42e9228ab36493b17220641d5e481ea3d8fee5ee0044c70bf960f55c7d3f1a704cf6b9c42e5c269b797e00
DIST readline-8.1.tar.gz.sig 95 BLAKE2B 8a297ef2ebf815ac53f02d6395aa2ff9f24234aef6b9793bfcd5a610cd3a5024182ad8ec8beb75eadd5cf876c57cd56d4226075578a86e0e2421d2e9b1677aa5 SHA512 42a6052d5882f16e5b6f8cd16433d793a9cbb43cf1886b2d858dc65ce067a4c39c8dda7331e52f76426c43de02c358f9ffdaf5c8fd7b089479008c1e5aa19112
DIST readline-8.2.tar.gz 3043952 BLAKE2B 7974322b9c092a756a79e537df08e8532f8e0fcb598f77732e28287c33ebec9e9837ed88b43334c310892d56a871b423903f0f564def2fbe700a1004f2ae7b18 SHA512 0a451d459146bfdeecc9cdd94bda6a6416d3e93abd80885a40b334312f16eb890f8618a27ca26868cebbddf1224983e631b1cbc002c1a4d1cd0d65fba9fea49a
diff --git a/sys-libs/readline/files/readline-8.1-rlfe-c99.patch b/sys-libs/readline/files/readline-8.1-rlfe-c99.patch
deleted file mode 100644
index 89a247d056ee..000000000000
--- a/sys-libs/readline/files/readline-8.1-rlfe-c99.patch
+++ /dev/null
@@ -1,1192 +0,0 @@
-From 565e32f70307a6c1771d19a7dd4041da84358d7f Mon Sep 17 00:00:00 2001
-From: Gabi Falk <gabifalk@gmx.com>
-Date: Thu, 9 May 2024 08:00:00 +0000
-Subject: [PATCH] examples/rlfe/configure.in: Port to modern C (C99)
-To: bug-readline@gnu.org
-Cc: Sam James <sam@gentoo.org>
-
-Due to changes in GCC 14 enabling -Werror=implicit-function-declaration
-and -Werror=implicit-int by default, without this change, this configure
-script fails with:
-configure: error: Can't run the compiler - sorry
-
-AC_USE_SYSTEM_EXTENSIONS is required because pts(4)-related functions
-ptsname(3), grantpt(3), and unlockpt(3) are not exposed otherwise.
-
-Link: https://bugs.gentoo.org/870424
-Link: https://bugs.gentoo.org/919256
-Link: https://lists.gnu.org/archive/html/bug-readline/2024-05/msg00000.html
-Signed-off-by: Gabi Falk <gabifalk@gmx.com>
---- a/examples/rlfe/configure
-+++ b/examples/rlfe/configure
-@@ -1490,115 +1490,6 @@ fi
-
- } # ac_fn_c_try_link
-
--# ac_fn_c_try_run LINENO
--# ----------------------
--# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
--# that executables *can* be run.
--ac_fn_c_try_run ()
--{
-- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
-- if { { ac_try="$ac_link"
--case "(($ac_try" in
-- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-- *) ac_try_echo=$ac_try;;
--esac
--eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
--$as_echo "$ac_try_echo"; } >&5
-- (eval "$ac_link") 2>&5
-- ac_status=$?
-- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
-- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
-- { { case "(($ac_try" in
-- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-- *) ac_try_echo=$ac_try;;
--esac
--eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
--$as_echo "$ac_try_echo"; } >&5
-- (eval "$ac_try") 2>&5
-- ac_status=$?
-- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
-- test $ac_status = 0; }; }; then :
-- ac_retval=0
--else
-- $as_echo "$as_me: program exited with status $ac_status" >&5
-- $as_echo "$as_me: failed program was:" >&5
--sed 's/^/| /' conftest.$ac_ext >&5
--
-- ac_retval=$ac_status
--fi
-- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
-- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-- as_fn_set_status $ac_retval
--
--} # ac_fn_c_try_run
--
--# ac_fn_c_check_func LINENO FUNC VAR
--# ----------------------------------
--# Tests whether FUNC exists, setting the cache variable VAR accordingly
--ac_fn_c_check_func ()
--{
-- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
-- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
--$as_echo_n "checking for $2... " >&6; }
--if eval \${$3+:} false; then :
-- $as_echo_n "(cached) " >&6
--else
-- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
-- For example, HP-UX 11i <limits.h> declares gettimeofday. */
--#define $2 innocuous_$2
--
--/* System header to define __stub macros and hopefully few prototypes,
-- which can conflict with char $2 (); below.
-- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-- <limits.h> exists even on freestanding compilers. */
--
--#ifdef __STDC__
--# include <limits.h>
--#else
--# include <assert.h>
--#endif
--
--#undef $2
--
--/* Override any GCC internal prototype to avoid an error.
-- Use char because int might match the return type of a GCC
-- builtin and then its argument prototype would still apply. */
--#ifdef __cplusplus
--extern "C"
--#endif
--char $2 ();
--/* The GNU C library defines this for functions which it implements
-- to always fail with ENOSYS. Some functions are actually named
-- something starting with __ and the normal name is an alias. */
--#if defined __stub_$2 || defined __stub___$2
--choke me
--#endif
--
--int
--main ()
--{
--return $2 ();
-- ;
-- return 0;
--}
--_ACEOF
--if ac_fn_c_try_link "$LINENO"; then :
-- eval "$3=yes"
--else
-- eval "$3=no"
--fi
--rm -f core conftest.err conftest.$ac_objext \
-- conftest$ac_exeext conftest.$ac_ext
--fi
--eval ac_res=\$$3
-- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
--$as_echo "$ac_res" >&6; }
-- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
--
--} # ac_fn_c_check_func
--
- # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
- # -------------------------------------------------------
- # Tests whether HEADER exists, giving a warning if it cannot be compiled using
-@@ -1686,6 +1577,48 @@ fi
-
- } # ac_fn_c_check_header_mongrel
-
-+# ac_fn_c_try_run LINENO
-+# ----------------------
-+# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-+# that executables *can* be run.
-+ac_fn_c_try_run ()
-+{
-+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
-+ if { { ac_try="$ac_link"
-+case "(($ac_try" in
-+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-+ *) ac_try_echo=$ac_try;;
-+esac
-+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-+$as_echo "$ac_try_echo"; } >&5
-+ (eval "$ac_link") 2>&5
-+ ac_status=$?
-+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
-+ test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
-+ { { case "(($ac_try" in
-+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-+ *) ac_try_echo=$ac_try;;
-+esac
-+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-+$as_echo "$ac_try_echo"; } >&5
-+ (eval "$ac_try") 2>&5
-+ ac_status=$?
-+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
-+ test $ac_status = 0; }; }; then :
-+ ac_retval=0
-+else
-+ $as_echo "$as_me: program exited with status $ac_status" >&5
-+ $as_echo "$as_me: failed program was:" >&5
-+sed 's/^/| /' conftest.$ac_ext >&5
-+
-+ ac_retval=$ac_status
-+fi
-+ rm -rf conftest.dSYM conftest_ipa8_conftest.oo
-+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-+ as_fn_set_status $ac_retval
-+
-+} # ac_fn_c_try_run
-+
- # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
- # -------------------------------------------------------
- # Tests whether HEADER exists and can be compiled using the include files in
-@@ -1716,6 +1649,73 @@ $as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
- } # ac_fn_c_check_header_compile
-+
-+# ac_fn_c_check_func LINENO FUNC VAR
-+# ----------------------------------
-+# Tests whether FUNC exists, setting the cache variable VAR accordingly
-+ac_fn_c_check_func ()
-+{
-+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
-+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-+$as_echo_n "checking for $2... " >&6; }
-+if eval \${$3+:} false; then :
-+ $as_echo_n "(cached) " >&6
-+else
-+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-+/* end confdefs.h. */
-+/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
-+ For example, HP-UX 11i <limits.h> declares gettimeofday. */
-+#define $2 innocuous_$2
-+
-+/* System header to define __stub macros and hopefully few prototypes,
-+ which can conflict with char $2 (); below.
-+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-+ <limits.h> exists even on freestanding compilers. */
-+
-+#ifdef __STDC__
-+# include <limits.h>
-+#else
-+# include <assert.h>
-+#endif
-+
-+#undef $2
-+
-+/* Override any GCC internal prototype to avoid an error.
-+ Use char because int might match the return type of a GCC
-+ builtin and then its argument prototype would still apply. */
-+#ifdef __cplusplus
-+extern "C"
-+#endif
-+char $2 ();
-+/* The GNU C library defines this for functions which it implements
-+ to always fail with ENOSYS. Some functions are actually named
-+ something starting with __ and the normal name is an alias. */
-+#if defined __stub_$2 || defined __stub___$2
-+choke me
-+#endif
-+
-+int
-+main ()
-+{
-+return $2 ();
-+ ;
-+ return 0;
-+}
-+_ACEOF
-+if ac_fn_c_try_link "$LINENO"; then :
-+ eval "$3=yes"
-+else
-+ eval "$3=no"
-+fi
-+rm -f core conftest.err conftest.$ac_objext \
-+ conftest$ac_exeext conftest.$ac_ext
-+fi
-+eval ac_res=\$$3
-+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-+$as_echo "$ac_res" >&6; }
-+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-+
-+} # ac_fn_c_check_func
- cat >config.log <<_ACEOF
- This file contains any messages produced by compilers while
- running configure, to aid debugging if configure makes a mistake.
-@@ -3233,32 +3233,223 @@ if test "$ac_res" != no; then :
- fi
-
-
--if test "$cross_compiling" = yes; then :
-- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
--$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
--as_fn_error $? "cannot run test program while cross compiling
--See \`config.log' for more details" "$LINENO" 5; }
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-+$as_echo_n "checking for ANSI C header files... " >&6; }
-+if ${ac_cv_header_stdc+:} false; then :
-+ $as_echo_n "(cached) " >&6
- else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--main(){exit(0);}
--_ACEOF
--if ac_fn_c_try_run "$LINENO"; then :
--
--else
--
--if test $CC != cc ; then
--echo "Your $CC failed - restarting with CC=cc" 1>&6
-+#include <stdlib.h>
-+#include <stdarg.h>
-+#include <string.h>
-+#include <float.h>
-
--echo "" 1>&6
-+int
-+main ()
-+{
-
--CC=cc
--export CC
--exec $0 $configure_args
-+ ;
-+ return 0;
-+}
-+_ACEOF
-+if ac_fn_c_try_compile "$LINENO"; then :
-+ ac_cv_header_stdc=yes
-+else
-+ ac_cv_header_stdc=no
- fi
-+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
--fi
--rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
-+if test $ac_cv_header_stdc = yes; then
-+ # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
-+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-+/* end confdefs.h. */
-+#include <string.h>
-+
-+_ACEOF
-+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-+ $EGREP "memchr" >/dev/null 2>&1; then :
-+
-+else
-+ ac_cv_header_stdc=no
-+fi
-+rm -f conftest*
-+
-+fi
-+
-+if test $ac_cv_header_stdc = yes; then
-+ # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
-+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-+/* end confdefs.h. */
-+#include <stdlib.h>
-+
-+_ACEOF
-+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-+ $EGREP "free" >/dev/null 2>&1; then :
-+
-+else
-+ ac_cv_header_stdc=no
-+fi
-+rm -f conftest*
-+
-+fi
-+
-+if test $ac_cv_header_stdc = yes; then
-+ # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
-+ if test "$cross_compiling" = yes; then :
-+ :
-+else
-+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-+/* end confdefs.h. */
-+#include <ctype.h>
-+#include <stdlib.h>
-+#if ((' ' & 0x0FF) == 0x020)
-+# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-+# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-+#else
-+# define ISLOWER(c) \
-+ (('a' <= (c) && (c) <= 'i') \
-+ || ('j' <= (c) && (c) <= 'r') \
-+ || ('s' <= (c) && (c) <= 'z'))
-+# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-+#endif
-+
-+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-+int
-+main ()
-+{
-+ int i;
-+ for (i = 0; i < 256; i++)
-+ if (XOR (islower (i), ISLOWER (i))
-+ || toupper (i) != TOUPPER (i))
-+ return 2;
-+ return 0;
-+}
-+_ACEOF
-+if ac_fn_c_try_run "$LINENO"; then :
-+
-+else
-+ ac_cv_header_stdc=no
-+fi
-+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
-+ conftest.$ac_objext conftest.beam conftest.$ac_ext
-+fi
-+
-+fi
-+fi
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-+$as_echo "$ac_cv_header_stdc" >&6; }
-+if test $ac_cv_header_stdc = yes; then
-+
-+$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-+
-+fi
-+
-+# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-+for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
-+ inttypes.h stdint.h unistd.h
-+do :
-+ as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-+ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-+"
-+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
-+ cat >>confdefs.h <<_ACEOF
-+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-+_ACEOF
-+
-+fi
-+
-+done
-+
-+
-+
-+ ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
-+if test "x$ac_cv_header_minix_config_h" = xyes; then :
-+ MINIX=yes
-+else
-+ MINIX=
-+fi
-+
-+
-+ if test "$MINIX" = yes; then
-+
-+$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
-+
-+
-+$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
-+
-+
-+$as_echo "#define _MINIX 1" >>confdefs.h
-+
-+ fi
-+
-+
-+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
-+$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
-+if ${ac_cv_safe_to_define___extensions__+:} false; then :
-+ $as_echo_n "(cached) " >&6
-+else
-+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-+/* end confdefs.h. */
-+
-+# define __EXTENSIONS__ 1
-+ $ac_includes_default
-+int
-+main ()
-+{
-+
-+ ;
-+ return 0;
-+}
-+_ACEOF
-+if ac_fn_c_try_compile "$LINENO"; then :
-+ ac_cv_safe_to_define___extensions__=yes
-+else
-+ ac_cv_safe_to_define___extensions__=no
-+fi
-+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-+fi
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
-+$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
-+ test $ac_cv_safe_to_define___extensions__ = yes &&
-+ $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
-+
-+ $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
-+
-+ $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
-+
-+ $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
-+
-+ $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
-+
-+
-+
-+if test "$cross_compiling" = yes; then :
-+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-+as_fn_error $? "cannot run test program while cross compiling
-+See \`config.log' for more details" "$LINENO" 5; }
-+else
-+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-+/* end confdefs.h. */
-+int main(){return 0;}
-+_ACEOF
-+if ac_fn_c_try_run "$LINENO"; then :
-+
-+else
-+
-+if test $CC != cc ; then
-+echo "Your $CC failed - restarting with CC=cc" 1>&6
-+
-+echo "" 1>&6
-+
-+CC=cc
-+export CC
-+exec $0 $configure_args
-+fi
-+
-+fi
-+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
- fi
-
-@@ -3271,7 +3462,7 @@ See \`config.log' for more details" "$LINENO" 5; }
- else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--main(){exit(0);}
-+int main(){return 0;}
- _ACEOF
- if ac_fn_c_try_run "$LINENO"; then :
-
-@@ -3298,6 +3489,7 @@ else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
-
-+int
- main()
- {
- int __something_strange_();
-@@ -3407,7 +3599,7 @@ rm -f conftest*
- $as_echo "$as_me: checking select..." >&6;}
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--
-+#include <sys/select.h>
- int
- main ()
- {
-@@ -3424,7 +3616,7 @@ else
- $as_echo "$as_me: checking select with $LIBS..." >&6;}
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--
-+#include <sys/select.h>
- int
- main ()
- {
-@@ -3459,6 +3651,8 @@ else
- #include <sys/types.h>
- #include <sys/stat.h>
- #include <fcntl.h>
-+#include <signal.h>
-+#include <unistd.h>
-
- char *nam = "/tmp/conftest$$";
-
-@@ -3471,7 +3665,7 @@ char *nam = "/tmp/conftest$$";
- #define S_IFIFO 0010000
- #endif
-
--
-+int
- main()
- {
- #ifdef FD_SET
-@@ -3485,7 +3679,7 @@ main()
- * opening RDWR fifo fails in BSD 4.4, but select return values are
- * right.
- */
-- exit(0);
-+ return 0;
- #endif
- (void)alarm(5);
- #ifdef POSIX
-@@ -3493,12 +3687,12 @@ main()
- #else
- if (mknod(nam, S_IFIFO|0777, 0))
- #endif
-- exit(1);
-+ return 1;
- close(0);
- if (open(nam, O_RDWR | O_NONBLOCK))
-- exit(1);
-+ return 1;
- if (write(0, "TEST", 4) == -1)
-- exit(1);
-+ return 1;
-
- #else
-
-@@ -3506,6 +3700,7 @@ main()
- #include <sys/socket.h>
- #include <sys/un.h>
-
-+int
- main()
- {
- int s1, s2, l;
-@@ -3518,14 +3713,14 @@ main()
-
- (void)alarm(5);
- if ((s1 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
-- exit(1);
-+ return 1;
- a.sun_family = AF_UNIX;
- strcpy(a.sun_path, nam);
- (void) unlink(nam);
- if (bind(s1, (struct sockaddr *) &a, strlen(nam)+2) == -1)
-- exit(1);
-+ return 1;
- if (listen(s1, 2))
-- exit(1);
-+ return 1;
- if (fork() == 0)
- {
- if ((s2 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
-@@ -3533,12 +3728,12 @@ main()
- (void)connect(s2, (struct sockaddr *)&a, strlen(nam) + 2);
- if (write(s2, "HELLO", 5) == -1)
- kill(getppid(), 3);
-- exit(0);
-+ return 0;
- }
- l = sizeof(a);
- close(0);
- if (accept(s1, (struct sockaddr *)&a, &l))
-- exit(1);
-+ return 1;
- #endif
-
-
-@@ -3548,10 +3743,10 @@ main()
- f = 1;
- #endif
- if (select(1, &f, 0, 0, 0) == -1)
-- exit(1);
-+ return 1;
- if (select(1, &f, &f, 0, 0) != 2)
-- exit(1);
-- exit(0);
-+ return 1;
-+ return 0;
- }
-
- _ACEOF
-@@ -3572,11 +3767,11 @@ fi
- $as_echo "$as_me: checking for tgetent..." >&6;}
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--
-+extern char tgetent(void);
- int
- main ()
- {
--tgetent((char *)0, (char *)0);
-+tgetent();
- ;
- return 0;
- }
-@@ -3590,7 +3785,7 @@ LIBS="-lcurses $olibs"
- $as_echo "$as_me: checking libcurses..." >&6;}
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--
-+extern char tgetent(void);
- int
- main ()
- {
-@@ -3598,7 +3793,7 @@ main ()
- #ifdef __hpux
- __sorry_hpux_libcurses_is_totally_broken_in_10_10();
- #else
--tgetent((char *)0, (char *)0);
-+tgetent();
- #endif
-
- ;
-@@ -3613,11 +3808,11 @@ else
- $as_echo "$as_me: checking libtermcap..." >&6;}
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--
-+extern char tgetent(void);
- int
- main ()
- {
--tgetent((char *)0, (char *)0);
-+tgetent();
- ;
- return 0;
- }
-@@ -3630,11 +3825,11 @@ else
- $as_echo "$as_me: checking libtermlib..." >&6;}
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--
-+extern char tgetent(void);
- int
- main ()
- {
--tgetent((char *)0, (char *)0);
-+tgetent();
- ;
- return 0;
- }
-@@ -3647,11 +3842,11 @@ else
- $as_echo "$as_me: checking libncurses..." >&6;}
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--
-+extern char tgetent(void);
- int
- main ()
- {
--tgetent((char *)0, (char *)0);
-+tgetent();
- ;
- return 0;
- }
-@@ -3685,10 +3880,13 @@ else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
-
-+#include <string.h>
- extern char *tgoto();
-+
-+int
- main()
- {
-- exit(strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1);
-+ return strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1;
- }
- _ACEOF
- if ac_fn_c_try_run "$LINENO"; then :
-@@ -3738,7 +3936,7 @@ sysvr4ptys=
- if test -c /dev/ptmx ; then
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
- /* end confdefs.h. */
--
-+#include <stdlib.h>
- int
- main ()
- {
-@@ -3898,6 +4096,10 @@ else
- #include <sys/types.h>
- #include <sys/stat.h>
- #include <stdio.h>
-+#include <stdlib.h>
-+#include <unistd.h>
-+
-+int
- main()
- {
- struct stat sb;
-@@ -3905,22 +4107,22 @@ main()
- int om, m;
- FILE *fp;
-
-- if (!(x = ttyname(0))) exit(1);
-- if (stat(x, &sb)) exit(1);
-+ if (!(x = ttyname(0))) return 1;
-+ if (stat(x, &sb)) return 1;
- om = sb.st_mode;
-- if (om & 002) exit(0);
-+ if (om & 002) return 0;
- m = system("mesg y");
-- if (m == -1 || m == 127) exit(1);
-- if (stat(x, &sb)) exit(1);
-+ if (m == -1 || m == 127) return 1;
-+ if (stat(x, &sb)) return 1;
- m = sb.st_mode;
-- if (chmod(x, om)) exit(1);
-- if (m & 002) exit(0);
-- if (sb.st_gid == getgid()) exit(1);
-+ if (chmod(x, om)) return 1;
-+ if (m & 002) return 0;
-+ if (sb.st_gid == getgid()) return 1;
- if (!(fp=fopen("conftest_grp", "w")))
-- exit(1);
-+ return 1;
- fprintf(fp, "%d\n", sb.st_gid);
- fclose(fp);
-- exit(0);
-+ return 0;
- }
-
- _ACEOF
-@@ -4166,6 +4368,7 @@ hand()
- got++;
- }
-
-+int
- main()
- {
- /* on hpux we use sigvec to get bsd signals */
-@@ -4174,9 +4377,9 @@ main()
- kill(getpid(), SIGCLD);
- kill(getpid(), SIGCLD);
- if (got < 2)
-- exit(1);
-+ return 1;
- #endif
-- exit(0);
-+ return 0;
- }
-
- _ACEOF
-@@ -4193,135 +4396,6 @@ fi
-
- fi
-
--{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
--$as_echo_n "checking for ANSI C header files... " >&6; }
--if ${ac_cv_header_stdc+:} false; then :
-- $as_echo_n "(cached) " >&6
--else
-- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--#include <stdlib.h>
--#include <stdarg.h>
--#include <string.h>
--#include <float.h>
--
--int
--main ()
--{
--
-- ;
-- return 0;
--}
--_ACEOF
--if ac_fn_c_try_compile "$LINENO"; then :
-- ac_cv_header_stdc=yes
--else
-- ac_cv_header_stdc=no
--fi
--rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
--
--if test $ac_cv_header_stdc = yes; then
-- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
-- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--#include <string.h>
--
--_ACEOF
--if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-- $EGREP "memchr" >/dev/null 2>&1; then :
--
--else
-- ac_cv_header_stdc=no
--fi
--rm -f conftest*
--
--fi
--
--if test $ac_cv_header_stdc = yes; then
-- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
-- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--#include <stdlib.h>
--
--_ACEOF
--if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-- $EGREP "free" >/dev/null 2>&1; then :
--
--else
-- ac_cv_header_stdc=no
--fi
--rm -f conftest*
--
--fi
--
--if test $ac_cv_header_stdc = yes; then
-- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
-- if test "$cross_compiling" = yes; then :
-- :
--else
-- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--/* end confdefs.h. */
--#include <ctype.h>
--#include <stdlib.h>
--#if ((' ' & 0x0FF) == 0x020)
--# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
--# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
--#else
--# define ISLOWER(c) \
-- (('a' <= (c) && (c) <= 'i') \
-- || ('j' <= (c) && (c) <= 'r') \
-- || ('s' <= (c) && (c) <= 'z'))
--# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
--#endif
--
--#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
--int
--main ()
--{
-- int i;
-- for (i = 0; i < 256; i++)
-- if (XOR (islower (i), ISLOWER (i))
-- || toupper (i) != TOUPPER (i))
-- return 2;
-- return 0;
--}
--_ACEOF
--if ac_fn_c_try_run "$LINENO"; then :
--
--else
-- ac_cv_header_stdc=no
--fi
--rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
-- conftest.$ac_objext conftest.beam conftest.$ac_ext
--fi
--
--fi
--fi
--{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
--$as_echo "$ac_cv_header_stdc" >&6; }
--if test $ac_cv_header_stdc = yes; then
--
--$as_echo "#define STDC_HEADERS 1" >>confdefs.h
--
--fi
--
--# On IRIX 5.3, sys/types and inttypes.h are conflicting.
--for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
-- inttypes.h stdint.h unistd.h
--do :
-- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
--ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
--"
--if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
-- cat >>confdefs.h <<_ACEOF
--#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
--_ACEOF
--
--fi
--
--done
--
--
- for ac_header in sys/stropts.h sys/wait.h sgtty.h sys/select.h
- do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
---- a/examples/rlfe/configure.in
-+++ b/examples/rlfe/configure.in
-@@ -30,7 +30,9 @@ AC_PROG_CPP
- AC_PROG_GCC_TRADITIONAL
- AC_ISC_POSIX
-
--AC_TRY_RUN(main(){exit(0);},,[
-+AC_USE_SYSTEM_EXTENSIONS
-+
-+AC_TRY_RUN([int main(){return 0;}],,[
- if test $CC != cc ; then
- AC_NOTE(Your $CC failed - restarting with CC=cc)
- AC_NOTE()
-@@ -40,7 +42,7 @@ exec $0 $configure_args
- fi
- ])
-
--AC_TRY_RUN(main(){exit(0);},,
-+AC_TRY_RUN([int main(){return 0;}],,
- exec 5>&2
- eval $ac_link
- AC_NOTE(CC=$CC; CFLAGS=$CFLAGS; LIBS=$LIBS;)
-@@ -48,6 +50,7 @@ AC_NOTE($ac_compile)
- AC_MSG_ERROR(Can't run the compiler - sorry))
-
- AC_TRY_RUN([
-+int
- main()
- {
- int __something_strange_();
-@@ -84,10 +87,10 @@ dnl **** select() ****
- dnl
-
- AC_CHECKING(select)
--AC_TRY_LINK(,[select(0, 0, 0, 0, 0);],,
-+AC_TRY_LINK([#include <sys/select.h>],[select(0, 0, 0, 0, 0);],,
- LIBS="$LIBS -lnet -lnsl"
- AC_CHECKING(select with $LIBS)
--AC_TRY_LINK(,[select(0, 0, 0, 0, 0);],,
-+AC_TRY_LINK([#include <sys/select.h>],[select(0, 0, 0, 0, 0);],,
- AC_MSG_ERROR(!!! no select - no screen))
- )
- dnl
-@@ -99,6 +102,8 @@ AC_TRY_RUN([
- #include <sys/types.h>
- #include <sys/stat.h>
- #include <fcntl.h>
-+#include <signal.h>
-+#include <unistd.h>
-
- char *nam = "/tmp/conftest$$";
-
-@@ -111,7 +116,7 @@ char *nam = "/tmp/conftest$$";
- #define S_IFIFO 0010000
- #endif
-
--
-+int
- main()
- {
- #ifdef FD_SET
-@@ -125,7 +130,7 @@ main()
- * opening RDWR fifo fails in BSD 4.4, but select return values are
- * right.
- */
-- exit(0);
-+ return 0;
- #endif
- (void)alarm(5);
- #ifdef POSIX
-@@ -133,12 +138,12 @@ main()
- #else
- if (mknod(nam, S_IFIFO|0777, 0))
- #endif
-- exit(1);
-+ return 1;
- close(0);
- if (open(nam, O_RDWR | O_NONBLOCK))
-- exit(1);
-+ return 1;
- if (write(0, "TEST", 4) == -1)
-- exit(1);
-+ return 1;
-
- #else
-
-@@ -146,6 +151,7 @@ main()
- #include <sys/socket.h>
- #include <sys/un.h>
-
-+int
- main()
- {
- int s1, s2, l;
-@@ -158,14 +164,14 @@ main()
-
- (void)alarm(5);
- if ((s1 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
-- exit(1);
-+ return 1;
- a.sun_family = AF_UNIX;
- strcpy(a.sun_path, nam);
- (void) unlink(nam);
- if (bind(s1, (struct sockaddr *) &a, strlen(nam)+2) == -1)
-- exit(1);
-+ return 1;
- if (listen(s1, 2))
-- exit(1);
-+ return 1;
- if (fork() == 0)
- {
- if ((s2 = socket(AF_UNIX, SOCK_STREAM, 0)) == -1)
-@@ -173,12 +179,12 @@ main()
- (void)connect(s2, (struct sockaddr *)&a, strlen(nam) + 2);
- if (write(s2, "HELLO", 5) == -1)
- kill(getppid(), 3);
-- exit(0);
-+ return 0;
- }
- l = sizeof(a);
- close(0);
- if (accept(s1, (struct sockaddr *)&a, &l))
-- exit(1);
-+ return 1;
- #endif
-
-
-@@ -188,10 +194,10 @@ main()
- f = 1;
- #endif
- if (select(1, &f, 0, 0, 0) == -1)
-- exit(1);
-+ return 1;
- if (select(1, &f, &f, 0, 0) != 2)
-- exit(1);
-- exit(0);
-+ return 1;
-+ return 0;
- }
- ],AC_NOTE(- select is ok),
- AC_NOTE(- select can't count) AC_DEFINE(SELECT_BROKEN))
-@@ -200,33 +206,36 @@ dnl
- dnl **** termcap or terminfo ****
- dnl
- AC_CHECKING(for tgetent)
--AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
-+AC_TRY_LINK([extern char tgetent(void);],tgetent();,,
- olibs="$LIBS"
- LIBS="-lcurses $olibs"
- AC_CHECKING(libcurses)
--AC_TRY_LINK(,[
-+AC_TRY_LINK([extern char tgetent(void);],[
- #ifdef __hpux
- __sorry_hpux_libcurses_is_totally_broken_in_10_10();
- #else
--tgetent((char *)0, (char *)0);
-+tgetent();
- #endif
- ],,
- LIBS="-ltermcap $olibs"
- AC_CHECKING(libtermcap)
--AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
-+AC_TRY_LINK([extern char tgetent(void);],tgetent();,,
- LIBS="-ltermlib $olibs"
- AC_CHECKING(libtermlib)
--AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
-+AC_TRY_LINK([extern char tgetent(void);],tgetent();,,
- LIBS="-lncurses $olibs"
- AC_CHECKING(libncurses)
--AC_TRY_LINK(,tgetent((char *)0, (char *)0);,,
-+AC_TRY_LINK([extern char tgetent(void);],tgetent();,,
- AC_MSG_ERROR(!!! no tgetent - no screen))))))
-
- AC_TRY_RUN([
-+#include <string.h>
- extern char *tgoto();
-+
-+int
- main()
- {
-- exit(strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1);
-+ return strcmp(tgoto("%p1%d", 0, 1), "1") ? 0 : 1;
- }], AC_NOTE(- you use the termcap database),
- AC_NOTE(- you use the terminfo database) AC_DEFINE(TERMINFO))
- AC_CHECKING(ospeed)
-@@ -243,7 +252,7 @@ fi
- AC_CHECKING(for SVR4 ptys)
- sysvr4ptys=
- if test -c /dev/ptmx ; then
--AC_TRY_LINK([],[ptsname(0);grantpt(0);unlockpt(0);],[AC_DEFINE(HAVE_SVR4_PTYS)
-+AC_TRY_LINK([#include <stdlib.h>],[ptsname(0);grantpt(0);unlockpt(0);],[AC_DEFINE(HAVE_SVR4_PTYS)
- sysvr4ptys=1])
- fi
-
-@@ -296,6 +305,10 @@ AC_TRY_RUN([
- #include <sys/types.h>
- #include <sys/stat.h>
- #include <stdio.h>
-+#include <stdlib.h>
-+#include <unistd.h>
-+
-+int
- main()
- {
- struct stat sb;
-@@ -303,22 +316,22 @@ main()
- int om, m;
- FILE *fp;
-
-- if (!(x = ttyname(0))) exit(1);
-- if (stat(x, &sb)) exit(1);
-+ if (!(x = ttyname(0))) return 1;
-+ if (stat(x, &sb)) return 1;
- om = sb.st_mode;
-- if (om & 002) exit(0);
-+ if (om & 002) return 0;
- m = system("mesg y");
-- if (m == -1 || m == 127) exit(1);
-- if (stat(x, &sb)) exit(1);
-+ if (m == -1 || m == 127) return 1;
-+ if (stat(x, &sb)) return 1;
- m = sb.st_mode;
-- if (chmod(x, om)) exit(1);
-- if (m & 002) exit(0);
-- if (sb.st_gid == getgid()) exit(1);
-+ if (chmod(x, om)) return 1;
-+ if (m & 002) return 0;
-+ if (sb.st_gid == getgid()) return 1;
- if (!(fp=fopen("conftest_grp", "w")))
-- exit(1);
-+ return 1;
- fprintf(fp, "%d\n", sb.st_gid);
- fclose(fp);
-- exit(0);
-+ return 0;
- }
- ],[
- if test -f conftest_grp; then
-@@ -420,6 +433,7 @@ hand()
- got++;
- }
-
-+int
- main()
- {
- /* on hpux we use sigvec to get bsd signals */
-@@ -428,9 +442,9 @@ main()
- kill(getpid(), SIGCLD);
- kill(getpid(), SIGCLD);
- if (got < 2)
-- exit(1);
-+ return 1;
- #endif
-- exit(0);
-+ return 0;
- }
- ],,AC_DEFINE(SYSVSIGS))
-
diff --git a/sys-libs/readline/readline-8.1_p2-r1.ebuild b/sys-libs/readline/readline-8.1_p2-r1.ebuild
index f05a1ab99847..50064ec142ee 100644
--- a/sys-libs/readline/readline-8.1_p2-r1.ebuild
+++ b/sys-libs/readline/readline-8.1_p2-r1.ebuild
@@ -27,6 +27,7 @@ case ${PV} in
*)
SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz"
+ SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/readline-8.1-rlfe-c99.patch.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${MY_P}.tar.gz.sig )"
if [[ ${PLEVEL} -gt 0 ]] ; then
@@ -77,15 +78,30 @@ PATCHES=(
"${FILESDIR}"/${PN}-8.0-headers.patch
"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
"${FILESDIR}"/${PN}-8.1-windows-signals.patch
- "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
+ "${WORKDIR}"/${PN}-8.1-rlfe-c99.patch
)
-# Needed because we don't want the patches being unpacked
-# (which emits annoying and useless error messages)
src_unpack() {
- verify-sig_src_unpack
+ local patch
- unpack ${MY_P}.tar.gz
+ if [[ ${PV} == 9999 ]]; then
+ git-r3_src_unpack
+ else
+ if use verify-sig; then
+ verify-sig_verify_detached "${DISTDIR}/${MY_P}.tar.gz"{,.sig}
+
+ for patch in "${MY_PATCHES[@]}"; do
+ verify-sig_verify_detached "${patch}"{,.sig}
+ done
+ fi
+
+ unpack "${MY_P}.tar.gz"
+ unpack readline-8.1-rlfe-c99.patch.xz
+
+ #if [[ ${GENTOO_PATCH_VER} ]]; then
+ # unpack "${PN}-${GENTOO_PATCH_VER}-patches.tar.xz"
+ #fi
+ fi
}
src_prepare() {
diff --git a/sys-libs/readline/readline-8.1_p2-r2.ebuild b/sys-libs/readline/readline-8.1_p2-r2.ebuild
index f05a1ab99847..50064ec142ee 100644
--- a/sys-libs/readline/readline-8.1_p2-r2.ebuild
+++ b/sys-libs/readline/readline-8.1_p2-r2.ebuild
@@ -27,6 +27,7 @@ case ${PV} in
*)
SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz"
+ SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/readline-8.1-rlfe-c99.patch.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${MY_P}.tar.gz.sig )"
if [[ ${PLEVEL} -gt 0 ]] ; then
@@ -77,15 +78,30 @@ PATCHES=(
"${FILESDIR}"/${PN}-8.0-headers.patch
"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
"${FILESDIR}"/${PN}-8.1-windows-signals.patch
- "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
+ "${WORKDIR}"/${PN}-8.1-rlfe-c99.patch
)
-# Needed because we don't want the patches being unpacked
-# (which emits annoying and useless error messages)
src_unpack() {
- verify-sig_src_unpack
+ local patch
- unpack ${MY_P}.tar.gz
+ if [[ ${PV} == 9999 ]]; then
+ git-r3_src_unpack
+ else
+ if use verify-sig; then
+ verify-sig_verify_detached "${DISTDIR}/${MY_P}.tar.gz"{,.sig}
+
+ for patch in "${MY_PATCHES[@]}"; do
+ verify-sig_verify_detached "${patch}"{,.sig}
+ done
+ fi
+
+ unpack "${MY_P}.tar.gz"
+ unpack readline-8.1-rlfe-c99.patch.xz
+
+ #if [[ ${GENTOO_PATCH_VER} ]]; then
+ # unpack "${PN}-${GENTOO_PATCH_VER}-patches.tar.xz"
+ #fi
+ fi
}
src_prepare() {
diff --git a/sys-libs/readline/readline-8.2_p10.ebuild b/sys-libs/readline/readline-8.2_p10.ebuild
index 0abd43ece110..8445ab394a11 100644
--- a/sys-libs/readline/readline-8.2_p10.ebuild
+++ b/sys-libs/readline/readline-8.2_p10.ebuild
@@ -40,6 +40,7 @@ if [[ ${PV} == 9999 ]] ; then
inherit git-r3
elif is_release ; then
SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz"
+ SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/readline-8.1-rlfe-c99.patch.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${MY_P}.tar.gz.sig )"
if [[ ${PLEVEL} -gt 0 ]] ; then
@@ -95,20 +96,32 @@ PATCHES=(
"${FILESDIR}"/${PN}-5.0-no_rpath.patch
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
- "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
+ "${WORKDIR}"/${PN}-8.1-rlfe-c99.patch
# TODO: rebase
#"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
)
src_unpack() {
- if [[ ${PV} == 9999 ]] ; then
+ local patch
+
+ if [[ ${PV} == 9999 ]]; then
git-r3_src_unpack
else
- # Needed because we don't want the patches being unpacked
- # (which emits annoying and useless error messages)
- verify-sig_src_unpack
- unpack ${MY_P}.tar.gz
+ if use verify-sig; then
+ verify-sig_verify_detached "${DISTDIR}/${MY_P}.tar.gz"{,.sig}
+
+ for patch in "${MY_PATCHES[@]}"; do
+ verify-sig_verify_detached "${patch}"{,.sig}
+ done
+ fi
+
+ unpack "${MY_P}.tar.gz"
+ unpack readline-8.1-rlfe-c99.patch.xz
+
+ #if [[ ${GENTOO_PATCH_VER} ]]; then
+ # unpack "${PN}-${GENTOO_PATCH_VER}-patches.tar.xz"
+ #fi
fi
}
diff --git a/sys-libs/readline/readline-8.3_alpha.ebuild b/sys-libs/readline/readline-8.3_alpha.ebuild
index 24f51a007309..4f953677fd42 100644
--- a/sys-libs/readline/readline-8.3_alpha.ebuild
+++ b/sys-libs/readline/readline-8.3_alpha.ebuild
@@ -40,6 +40,7 @@ if [[ ${PV} == 9999 ]] ; then
inherit git-r3
elif is_release ; then
SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz"
+ SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/readline-8.1-rlfe-c99.patch.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${MY_P}.tar.gz.sig )"
if [[ ${PLEVEL} -gt 0 ]] ; then
@@ -70,6 +71,7 @@ elif is_release ; then
fi
else
SRC_URI="mirror://gnu/${PN}/${MY_P}.tar.gz ftp://ftp.cwru.edu/pub/readline/${MY_P}.tar.gz"
+ SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/readline-8.1-rlfe-c99.patch.xz"
SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${MY_P}.tar.gz.sig ftp://ftp.cwru.edu/pub/readline/${MY_P}.tar.gz.sig )"
fi
@@ -97,20 +99,32 @@ PATCHES=(
"${FILESDIR}"/${PN}-5.0-no_rpath.patch
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
- "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
+ "${WORKDIR}"/${PN}-8.1-rlfe-c99.patch
# TODO: rebase
#"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
)
src_unpack() {
- if [[ ${PV} == 9999 ]] ; then
+ local patch
+
+ if [[ ${PV} == 9999 ]]; then
git-r3_src_unpack
else
- # Needed because we don't want the patches being unpacked
- # (which emits annoying and useless error messages)
- verify-sig_src_unpack
- unpack ${MY_P}.tar.gz
+ if use verify-sig; then
+ verify-sig_verify_detached "${DISTDIR}/${MY_P}.tar.gz"{,.sig}
+
+ for patch in "${MY_PATCHES[@]}"; do
+ verify-sig_verify_detached "${patch}"{,.sig}
+ done
+ fi
+
+ unpack "${MY_P}.tar.gz"
+ unpack readline-8.1-rlfe-c99.patch.xz
+
+ #if [[ ${GENTOO_PATCH_VER} ]]; then
+ # unpack "${PN}-${GENTOO_PATCH_VER}-patches.tar.xz"
+ #fi
fi
}
diff --git a/sys-libs/readline/readline-9999.ebuild b/sys-libs/readline/readline-9999.ebuild
index 24f51a007309..d04b96f587c8 100644
--- a/sys-libs/readline/readline-9999.ebuild
+++ b/sys-libs/readline/readline-9999.ebuild
@@ -97,20 +97,30 @@ PATCHES=(
"${FILESDIR}"/${PN}-5.0-no_rpath.patch
"${FILESDIR}"/${PN}-7.0-headers.patch
"${FILESDIR}"/${PN}-8.0-headers.patch
- "${FILESDIR}"/${PN}-8.1-rlfe-c99.patch
# TODO: rebase
#"${FILESDIR}"/${PN}-8.0-darwin-shlib-versioning.patch
)
src_unpack() {
- if [[ ${PV} == 9999 ]] ; then
+ local patch
+
+ if [[ ${PV} == 9999 ]]; then
git-r3_src_unpack
else
- # Needed because we don't want the patches being unpacked
- # (which emits annoying and useless error messages)
- verify-sig_src_unpack
- unpack ${MY_P}.tar.gz
+ if use verify-sig; then
+ verify-sig_verify_detached "${DISTDIR}/${MY_P}.tar.gz"{,.sig}
+
+ for patch in "${MY_PATCHES[@]}"; do
+ verify-sig_verify_detached "${patch}"{,.sig}
+ done
+ fi
+
+ unpack "${MY_P}.tar.gz"
+
+ #if [[ ${GENTOO_PATCH_VER} ]]; then
+ # unpack "${PN}-${GENTOO_PATCH_VER}-patches.tar.xz"
+ #fi
fi
}
^ permalink raw reply related [flat|nested] 7+ messages in thread
end of thread, other threads:[~2024-05-11 0:42 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-07-30 8:53 [gentoo-commits] repo/gentoo:master commit in: sys-libs/readline/, sys-libs/readline/files/ Lars Wendler
-- strict thread matches above, loose matches on Subject: below --
2024-05-11 0:42 Sam James
2024-05-11 0:30 Sam James
2021-06-09 22:07 Mike Frysinger
2020-12-26 12:55 Fabian Groffen
2020-07-30 8:05 Lars Wendler
2016-11-10 6:03 Mike Frysinger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox