commit: a1e9746ddab66a76492235b2ea4fda8385cac224
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Wed Aug 12 15:03:06 2015 +0000
Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org>
CommitDate: Wed Aug 12 15:03:40 2015 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a1e9746d
app-text/pinfo: fix build w/newer glibc & ncurses
.../pinfo/files/pinfo-0.6.10-libc-basename.patch | 33 ++++++++++++++++++++++
.../pinfo/files/pinfo-0.6.10-ncurses-check.patch | 14 +++++++++
app-text/pinfo/pinfo-0.6.10-r5.ebuild | 6 ++--
3 files changed, 51 insertions(+), 2 deletions(-)
diff --git a/app-text/pinfo/files/pinfo-0.6.10-libc-basename.patch
b/app-text/pinfo/files/pinfo-0.6.10-libc-basename.patch
new file mode 100644
index 0000000..6e9d495
--- /dev/null
+++ b/app-text/pinfo/files/pinfo-0.6.10-libc-basename.patch
@@ -0,0 +1,33 @@
+do not redefine the basename that the C library provides
+
+--- a/src/filehandling_functions.c
++++ b/src/filehandling_functions.c
+@@ -31,7 +31,6 @@ typedef struct
+ }
+ Suffixes;
+
+-char * basename(char *filename);
+
+
+
/******************************************************************************
+@@ -713,20 +712,6 @@ opendirfile(int number)
+ return NULL;
+ }
+
+-char *
+-basename(char *filename)
+-{
+- int len = strlen(filename);
+- char *a = filename + len;
+- while (a > filename)
+- {
+- a--;
+- if (*a == '/')
+- return a + 1;
+- }
+- return filename; /* when it was a basename */
+-}
+-
+ /*
+ * Note: openinfo is a function for reading info files, and putting
+ * uncompressed content into a temporary filename. For a flexibility, there
diff --git a/app-text/pinfo/files/pinfo-0.6.10-ncurses-check.patch
b/app-text/pinfo/files/pinfo-0.6.10-ncurses-check.patch
new file mode 100644
index 0000000..a5f14c5
--- /dev/null
+++ b/app-text/pinfo/files/pinfo-0.6.10-ncurses-check.patch
@@ -0,0 +1,14 @@
+curses_wchar is set to true/false, so trying to assign it to the compiler
+flags variable makes no sense. it's already been set up the right value
+at this point, so delete the assignment.
+
+--- a/macros/curses.m4
++++ b/macros/curses.m4
+@@ -130,7 +130,6 @@ AC_DEFUN([AC_CHECK_CURSES],[
+ else
+ AC_DEFINE(CURSES_WCHAR)
+ CURSES_WCHAR=true
+- CURSES_FLAGS=$curses_wchar
+ AC_SUBST(CURSES_FLAGS)
+ fi
+
diff --git a/app-text/pinfo/pinfo-0.6.10-r5.ebuild
b/app-text/pinfo/pinfo-0.6.10-r5.ebuild
index 793f3b4..f16ddb0 100644
--- a/app-text/pinfo/pinfo-0.6.10-r5.ebuild
+++ b/app-text/pinfo/pinfo-0.6.10-r5.ebuild
@@ -36,11 +36,13 @@ src_prepare() {
"${FILESDIR}"/${PN}-0.6.10-info-suffix.patch \
"${FILESDIR}"/${PN}-0.6.10-dir-file.patch \
"${FILESDIR}"/${PN}-0.6.10-tinfo.patch \
- "${FILESDIR}"/${PN}-0.6.10-gettext-0.19.patch
+ "${FILESDIR}"/${PN}-0.6.10-gettext-0.19.patch \
+ "${FILESDIR}"/${PN}-0.6.10-ncurses-check.patch \
+ "${FILESDIR}"/${PN}-0.6.10-libc-basename.patch
eautoreconf
- append-cflags -D_BSD_SOURCE # sbrk()
+ append-cflags -D_BSD_SOURCE -D_DEFAULT_SOURCE # sbrk()
}
src_configure() {