summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2015-08-14 00:05:15 -0400
committerMike Frysinger <vapier@gentoo.org>2015-08-14 00:05:36 -0400
commitda13077dd7c1f545e760447fd9b451d29a24d74d (patch)
tree0d2085f1a2dcb9c7f289ec8acc6fd7d654c4defe /app-editors/curses-hexedit/files
parentapp-portage/eclass-manpages: fix gensub warnings (diff)
downloadgentoo-da13077dd7c1f545e760447fd9b451d29a24d74d.tar.gz
gentoo-da13077dd7c1f545e760447fd9b451d29a24d74d.tar.bz2
gentoo-da13077dd7c1f545e760447fd9b451d29a24d74d.zip
app-editors/curses-hexedit: look up ncurses details via pkg-config
Diffstat (limited to 'app-editors/curses-hexedit/files')
-rw-r--r--app-editors/curses-hexedit/files/curses-hexedit-0.9.7-ncurses-pkg-config.patch34
1 files changed, 34 insertions, 0 deletions
diff --git a/app-editors/curses-hexedit/files/curses-hexedit-0.9.7-ncurses-pkg-config.patch b/app-editors/curses-hexedit/files/curses-hexedit-0.9.7-ncurses-pkg-config.patch
new file mode 100644
index 000000000000..94d6263589cf
--- /dev/null
+++ b/app-editors/curses-hexedit/files/curses-hexedit-0.9.7-ncurses-pkg-config.patch
@@ -0,0 +1,34 @@
+use pkg-config to locate ncurses rather than a library search
+
+--- a/configure.in
++++ b/configure.in
+@@ -19,14 +19,9 @@
+ AC_HEADER_STDC
+ AC_PROG_GCC_TRADITIONAL
+
+-AC_CHECK_HEADERS(ncurses.h)
+-if test "$ac_cv_header_ncurses_h" = "no"; then
+- AC_CHECK_HEADERS(curses.h)
+- if test "$ac_cv_header_curses_h" = "no"; then
+- echo "*** Cannot find Curses headers, probably not installed"
+- echo "*** Hexedit will not run without the curses library"
+- fi
+-fi
++PKG_CHECK_MODULES(NCURSES, ncurses)
++CFLAGS="$CFLAGS $NCURSES_CFLAGS -DHAVE_NCURSES_H=1"
++LIBS="$LIBS $NCURSES_LIBS"
+
+ AC_CHECK_HEADERS(fcntl.h getopt.h limits.h sys/ioctl.h unistd.h)
+ AC_HEADER_DIRENT
+@@ -96,11 +91,4 @@ else
+ fi
+ fi
+
+-AC_CHECK_LIB(ncurses, newwin, ,
+- AC_CHECK_LIB(curses, newwin), ,
+- echo "Hexedit requires the curses library"
+- echo "Ncurses is freely available: ftp://ftp.gnu.org/pub/gnu/"
+- exit 1)
+-
+-
+ AC_OUTPUT(Makefile docs/Makefile gnu/Makefile src/Makefile)