public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in sys-process/htop/files: htop-1.0.3-tinfo.patch
@ 2014-09-30 19:40 Christian Ruppert (idl0r)
  0 siblings, 0 replies; only message in thread
From: Christian Ruppert (idl0r) @ 2014-09-30 19:40 UTC (permalink / raw
  To: gentoo-commits

idl0r       14/09/30 19:40:46

  Added:                htop-1.0.3-tinfo.patch
  Log:
  Fix ncurses linking, bug 509452
  
  (Portage version: 2.2.14_rc1/cvs/Linux x86_64, signed Manifest commit with key B427ABC8)

Revision  Changes    Path
1.1                  sys-process/htop/files/htop-1.0.3-tinfo.patch

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-process/htop/files/htop-1.0.3-tinfo.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-process/htop/files/htop-1.0.3-tinfo.patch?rev=1.1&content-type=text/plain

Index: htop-1.0.3-tinfo.patch
===================================================================
diff --git a/Makefile.am b/Makefile.am
index 820e2e5..85f49e9 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -36,6 +36,8 @@ SUFFIXES = .h
 BUILT_SOURCES = $(myhtopheaders)
 htop_SOURCES = $(myhtopheaders) $(myhtopsources) config.h
 
+htop_LDADD = $(NCURSES_LIBS)
+
 profile:
 	$(MAKE) all CFLAGS="-pg" AM_CPPFLAGS="-pg -O2 -DNDEBUG"
 
diff --git a/configure.ac b/configure.ac
index 2b934e8..3593885 100644
--- a/configure.ac
+++ b/configure.ac
@@ -20,6 +20,7 @@ AM_PROG_CC_C_O
 AC_DISABLE_SHARED
 AC_ENABLE_STATIC
 AC_PROG_LIBTOOL
+PKG_PROG_PKG_CONFIG
 
 # Checks for libraries.
 AC_CHECK_LIB([m], [ceil], [], [missing_libraries="$missing_libraries libm"])
@@ -89,20 +90,24 @@ fi
 
 AC_ARG_ENABLE(unicode, [AC_HELP_STRING([--enable-unicode], [enable Unicode support])], ,enable_unicode="yes")
 if test "x$enable_unicode" = xyes; then
-   AC_CHECK_LIB([ncursesw], [refresh], [], [
-      missing_libraries="$missing_libraries libncursesw"
-      AC_MSG_ERROR([You may want to use --disable-unicode or install libncursesw.])
+   PKG_CHECK_MODULES([NCURSES], [ncursesw],[
+     AC_CHECK_LIB([ncursesw], [refresh], [], [
+         missing_libraries="$missing_libraries libncursesw"
+         AC_MSG_ERROR([You may want to use --disable-unicode or install libncursesw.])
+      ])
+      AC_CHECK_HEADERS([ncursesw/curses.h],[:],
+         [AC_CHECK_HEADERS([ncurses/ncurses.h],[:],
+            [AC_CHECK_HEADERS([ncurses/curses.h],[:],
+               [AC_CHECK_HEADERS([ncurses.h],[:],[missing_headers="$missing_headers $ac_header"])])])])
    ])
-   AC_CHECK_HEADERS([ncursesw/curses.h],[:],
-      [AC_CHECK_HEADERS([ncurses/ncurses.h],[:],
-         [AC_CHECK_HEADERS([ncurses/curses.h],[:],
-            [AC_CHECK_HEADERS([ncurses.h],[:],[missing_headers="$missing_headers $ac_header"])])])])
 else
-   AC_CHECK_LIB([ncurses], [refresh], [], [missing_libraries="$missing_libraries libncurses"])
-   AC_CHECK_HEADERS([curses.h],[:],
-      [AC_CHECK_HEADERS([ncurses/curses.h],[:],
-         [AC_CHECK_HEADERS([ncurses/ncurses.h],[:],
-            [AC_CHECK_HEADERS([ncurses.h],[:],[missing_headers="$missing_headers $ac_header"])])])])
+   PKG_CHECK_MODULES([NCURSES], [ncurses],[
+      AC_CHECK_LIB([ncurses], [refresh], [], [missing_libraries="$missing_libraries libncurses"])
+      AC_CHECK_HEADERS([curses.h],[:],
+         [AC_CHECK_HEADERS([ncurses/curses.h],[:],
+            [AC_CHECK_HEADERS([ncurses/ncurses.h],[:],
+               [AC_CHECK_HEADERS([ncurses.h],[:],[missing_headers="$missing_headers $ac_header"])])])])
+   ])
 fi
 
 if test ! -z "$missing_libraries"; then





^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2014-09-30 19:40 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-30 19:40 [gentoo-commits] gentoo-x86 commit in sys-process/htop/files: htop-1.0.3-tinfo.patch Christian Ruppert (idl0r)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox