commit:     7e2df9a37ba3687faa805c1356480f0e44c85276
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 17 21:31:57 2019 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Wed Jul 17 21:34:53 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7e2df9a3

games-mud/mudix: Fixed build with sys-libs/ncurses[tinfo]

Closes: https://bugs.gentoo.org/690072
Package-Manager: Portage-2.3.69, Repoman-2.3.16
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 games-mud/mudix/files/mudix-4.3-tinfo.patch | 43 +++++++++++++++++++++++++++++
 games-mud/mudix/mudix-4.3-r2.ebuild         | 19 +++++++++----
 2 files changed, 57 insertions(+), 5 deletions(-)

diff --git a/games-mud/mudix/files/mudix-4.3-tinfo.patch 
b/games-mud/mudix/files/mudix-4.3-tinfo.patch
new file mode 100644
index 00000000000..0c11f235244
--- /dev/null
+++ b/games-mud/mudix/files/mudix-4.3-tinfo.patch
@@ -0,0 +1,43 @@
+https://bugs.gentoo.org/690072
+
+--- mudix-4.3/configure.in
++++ mudix-4.3/configure.in
+@@ -4,9 +4,12 @@
+ 
+ dnl Checks for programs.
+ AC_PROG_CC
++PKG_PROG_PKG_CONFIG
+ 
+ dnl Checks for libraries.
+-AC_CHECK_LIB(ncurses, initscr)
++PKG_CHECK_MODULES(NCURSES, ncurses,,
++                [AC_MSG_ERROR([Cannot find ncurses libs])]
++               )
+ AC_CHECK_LIB(panel, new_panel)
+ 
+ dnl Checks for header files.
+--- mudix-4.3/Makefile.in
++++ mudix-4.3/Makefile.in
+@@ -1,5 +1,7 @@
++export NCURSES_LIBS=@NCURSES_LIBS@
++
+ all:
+-      (cd src; make) 
++      $(MAKE) -C src 
+ 
+ clean:
+-      (cd src; make $@)
++      $(MAKE) -C src $@
+--- mudix-4.3/src/Makefile.in
++++ mudix-4.3/src/Makefile.in
+@@ -2,9 +2,8 @@
+ #DEBUG   = -DKEY_DEBUG 
+ DEBUG   = 
+ EXEC    = ../mudix
+-O_FLAGS = -O -g
+ C_FLAGS = $(O_FLAGS) $(DEBUG) -Wall -I../include
+-L_FLAGS = $(O_FLAGS) $(DEBUG) -lpanel -lncurses
++L_FLAGS = $(O_FLAGS) $(DEBUG) -lpanel $(NCURSES_LIBS)
+ 
+ O_FILES = alias.o \
+           commands.o \

diff --git a/games-mud/mudix/mudix-4.3-r2.ebuild 
b/games-mud/mudix/mudix-4.3-r2.ebuild
index 067ddf34461..26a95dbd929 100644
--- a/games-mud/mudix/mudix-4.3-r2.ebuild
+++ b/games-mud/mudix/mudix-4.3-r2.ebuild
@@ -1,7 +1,9 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2019 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=6
+EAPI=7
+
+inherit autotools
 
 DESCRIPTION="A small, stable MUD client for the console"
 HOMEPAGE="http://dw.nl.eu.org/mudix.html";
@@ -12,15 +14,22 @@ SLOT="0"
 KEYWORDS="~amd64 ~x86"
 IUSE=""
 
-DEPEND="sys-libs/ncurses:0"
-RDEPEND=${DEPEND}
+DEPEND="sys-libs/ncurses:0="
+RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
 
 PATCHES=(
        "${FILESDIR}"/${P}-as-needed.patch
+       "${FILESDIR}"/${P}-tinfo.patch
 )
 
+src_prepare() {
+       default
+       eautoreconf
+}
+
 src_compile() {
-       emake -C src O_FLAGS="${CFLAGS}"
+       emake O_FLAGS="${CFLAGS}"
 }
 
 src_install () {

Reply via email to