Code

fixed building on systems with libncursesw but without <ncursesw/ncurses.h> like...
authorAndreas Obergrusberger <tradiaz@yahoo.de>
Sat, 5 Aug 2006 16:53:19 +0000 (16:53 +0000)
committerAndreas Obergrusberger <tradiaz@yahoo.de>
Sat, 5 Aug 2006 16:53:19 +0000 (16:53 +0000)
git-svn-id: https://svn.musicpd.org/ncmpc/branches/tradiaz@4563 09075e82-0dd4-0310-85a5-a0d7c8717e4f

ChangeLog
configure.ac

index c574c7e9b0091ab7ae6cf8fcb1a0b23a6f56e5c8..81a79675797a401d1d64236814a17c2e29851479 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -8,6 +8,7 @@
         * updated translation template
         * german lyrics- and search-screen translation added
         * avuton has fixed a lot of warnings
+       * fixed a problem with compiling on Arch Linux
 
 2006-09-4 Anderas Obergrusberger <tradiaz@yahoo.de>
         * tradiaz is temporary maintainer of a special branch of ncmpc now
index e3e68eec19c5a825701df22d60778853abe5b810..1baa12f1743b5fe4143acff87cbb189657e1c703 100644 (file)
@@ -82,6 +82,12 @@ if test "x$ncurses" = "xauto"; then
                     [ncurses=ncurses])
 fi
                     
+AC_CHECK_HEADER([ncursesw/ncurses.h],
+               [have_ncursesw_h=yes],
+               ,)
+
+
+
 
 AC_CHECK_LIB([$ncurses], 
             [initscr],
@@ -89,12 +95,15 @@ AC_CHECK_LIB([$ncurses],
             [AC_MSG_ERROR($ncurses library is required)])
 
 
-if test "x$ncurses" = "xncursesw" ; then
-   AC_DEFINE(_XOPEN_SOURCE_EXTENDED, 1, [wide-char wget_ch()])
-   AC_DEFINE(USE_NCURSESW, 1, [use wide-char ncurses library])
+if test "x$ncurses" != "xncursesw" ; then
+       if test "x$have_ncursesw_h" = "xyes" ; then
+                AC_DEFINE(_XOPEN_SOURCE_EXTENDED, 1, [wide-char wget_ch()])
+                AC_DEFINE(USE_NCURSESW, 1, [use wide-char ncurses library])
+       fi
 fi
 
 
+
 dnl Check for glib-2.4
 PKG_CHECK_MODULES([GLIB], 
                  [glib-2.0 >= 2.4],