with_platlibdir
with_wheel_pkg_dir
with_readline
+with_curses
with_computed_gotos
with_tail_call_interp
with_remote_debug
(default: none)
--with(out)-readline[=editline|readline|no]
use libedit for backend or disable readline module
+ --with(out)-curses[=ncursesw|ncurses|curses|no]
+ select the curses backend for the curses and
+ _curses_panel modules, or disable them (default:
+ auto)
--with-computed-gotos enable computed gotos in evaluation loop (enabled by
default on supported compilers)
--with-tail-call-interp enable tail-calling interpreter in evaluation loop
have_curses=no
have_panel=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-curses" >&5
+printf %s "checking for --with-curses... " >&6; }
+
+# Check whether --with-curses was given.
+if test ${with_curses+y}
+then :
+ withval=$with_curses; case $with_curses in #(
+ yes|auto) :
+ with_curses=auto ;; #(
+ ncursesw|ncurses|curses|no) :
+ ;; #(
+ *) :
+ as_fn_error $? "proper usage is --with(out)-curses[=ncursesw|ncurses|curses|no]" "$LINENO" 5 ;;
+esac
+else case e in #(
+ e) with_curses=auto ;;
+esac
+fi
+
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_curses" >&5
+printf "%s\n" "$with_curses" >&6; }
+
+
+
+# Detect the selected backend. ncursesw/ncurses are found via pkg-config;
+# native curses has no .pc file and is left to the header/link probes below.
+# curses_libs/panel_libs drive the AC_SEARCH_LIBS fallback; for "no" they are
+# empty so nothing links and have_curses stays "no".
+case $with_curses in #(
+ ncursesw) :
+
+
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ncursesw" >&5
+printf %s "checking for ncursesw... " >&6; }
+
+if test -n "$CURSES_CFLAGS"; then
+ pkg_cv_CURSES_CFLAGS="$CURSES_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ncursesw\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "ncursesw") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_CURSES_CFLAGS=`$PKG_CONFIG --cflags "ncursesw" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$CURSES_LIBS"; then
+ pkg_cv_CURSES_LIBS="$CURSES_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ncursesw\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "ncursesw") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_CURSES_LIBS=`$PKG_CONFIG --libs "ncursesw" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ CURSES_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "ncursesw" 2>&1`
+ else
+ CURSES_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "ncursesw" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$CURSES_PKG_ERRORS" >&5
+
+ have_curses=no
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+ have_curses=no
+else
+ CURSES_CFLAGS=$pkg_cv_CURSES_CFLAGS
+ CURSES_LIBS=$pkg_cv_CURSES_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_NCURSESW 1" >>confdefs.h
+
+ have_curses=yes
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for panelw" >&5
+printf %s "checking for panelw... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"panelw\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "panelw") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "panelw" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"panelw\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "panelw") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "panelw" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "panelw" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "panelw" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
+
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gnupanel" >&5
+printf %s "checking for gnupanel... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnupanel" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnupanel" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
+
+ have_panel=no
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+ have_panel=no
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+ have_panel=yes
+fi
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gnupanel" >&5
+printf %s "checking for gnupanel... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnupanel" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnupanel" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
+
+ have_panel=no
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+ have_panel=no
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+ have_panel=yes
+fi
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_PANELW 1" >>confdefs.h
+
+ have_panel=yes
+fi
+fi
+
+
+ curses_libs="ncursesw"; panel_libs="panelw gnupanel" ;; #(
+ ncurses) :
+
+
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ncurses" >&5
+printf %s "checking for ncurses... " >&6; }
+
+if test -n "$CURSES_CFLAGS"; then
+ pkg_cv_CURSES_CFLAGS="$CURSES_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ncurses\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "ncurses") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_CURSES_CFLAGS=`$PKG_CONFIG --cflags "ncurses" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$CURSES_LIBS"; then
+ pkg_cv_CURSES_LIBS="$CURSES_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ncurses\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "ncurses") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_CURSES_LIBS=`$PKG_CONFIG --libs "ncurses" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ CURSES_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "ncurses" 2>&1`
+ else
+ CURSES_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "ncurses" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$CURSES_PKG_ERRORS" >&5
+
+ have_curses=no
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+ have_curses=no
+else
+ CURSES_CFLAGS=$pkg_cv_CURSES_CFLAGS
+ CURSES_LIBS=$pkg_cv_CURSES_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_NCURSES 1" >>confdefs.h
+
+ have_curses=yes
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for panel" >&5
+printf %s "checking for panel... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"panel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "panel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "panel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"panel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "panel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "panel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "panel" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "panel" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
+
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gnupanel" >&5
+printf %s "checking for gnupanel... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnupanel" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnupanel" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
+
+ have_panel=no
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+ have_panel=no
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+ have_panel=yes
+fi
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gnupanel" >&5
+printf %s "checking for gnupanel... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnupanel" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnupanel" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
+
+ have_panel=no
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+ have_panel=no
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+ have_panel=yes
+fi
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_PANEL 1" >>confdefs.h
+
+ have_panel=yes
+fi
+fi
+
+
+ curses_libs="ncurses"; panel_libs="panel gnupanel" ;; #(
+ curses) :
+ curses_libs="curses"; panel_libs="panel" ;; #(
+ no) :
+ curses_libs=""; panel_libs="" ;; #(
+ *) :
+
+
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ncursesw" >&5
+printf %s "checking for ncursesw... " >&6; }
+
+if test -n "$CURSES_CFLAGS"; then
+ pkg_cv_CURSES_CFLAGS="$CURSES_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ncursesw\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "ncursesw") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_CURSES_CFLAGS=`$PKG_CONFIG --cflags "ncursesw" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$CURSES_LIBS"; then
+ pkg_cv_CURSES_LIBS="$CURSES_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ncursesw\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "ncursesw") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_CURSES_LIBS=`$PKG_CONFIG --libs "ncursesw" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ CURSES_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "ncursesw" 2>&1`
+ else
+ CURSES_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "ncursesw" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$CURSES_PKG_ERRORS" >&5
+
+ have_curses=no
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+ have_curses=no
+else
+ CURSES_CFLAGS=$pkg_cv_CURSES_CFLAGS
+ CURSES_LIBS=$pkg_cv_CURSES_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+
+printf "%s\n" "#define HAVE_NCURSESW 1" >>confdefs.h
+
+ have_curses=yes
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for panelw" >&5
+printf %s "checking for panelw... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"panelw\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "panelw") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "panelw" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"panelw\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "panelw") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "panelw" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
-# Check for ncursesw/panelw first. If that fails, try ncurses/panel.
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "panelw" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "panelw" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
pkg_failed=no
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ncursesw" >&5
-printf %s "checking for ncursesw... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gnupanel" >&5
+printf %s "checking for gnupanel... " >&6; }
-if test -n "$CURSES_CFLAGS"; then
- pkg_cv_CURSES_CFLAGS="$CURSES_CFLAGS"
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
elif test -n "$PKG_CONFIG"; then
if test -n "$PKG_CONFIG" && \
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ncursesw\""; } >&5
- ($PKG_CONFIG --exists --print-errors "ncursesw") 2>&5
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
ac_status=$?
printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
- pkg_cv_CURSES_CFLAGS=`$PKG_CONFIG --cflags "ncursesw" 2>/dev/null`
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "gnupanel" 2>/dev/null`
test "x$?" != "x0" && pkg_failed=yes
else
pkg_failed=yes
else
pkg_failed=untried
fi
-if test -n "$CURSES_LIBS"; then
- pkg_cv_CURSES_LIBS="$CURSES_LIBS"
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
elif test -n "$PKG_CONFIG"; then
if test -n "$PKG_CONFIG" && \
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"ncursesw\""; } >&5
- ($PKG_CONFIG --exists --print-errors "ncursesw") 2>&5
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
ac_status=$?
printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
- pkg_cv_CURSES_LIBS=`$PKG_CONFIG --libs "ncursesw" 2>/dev/null`
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "gnupanel" 2>/dev/null`
test "x$?" != "x0" && pkg_failed=yes
else
pkg_failed=yes
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- CURSES_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "ncursesw" 2>&1`
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnupanel" 2>&1`
else
- CURSES_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "ncursesw" 2>&1`
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnupanel" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
- echo "$CURSES_PKG_ERRORS" >&5
+ echo "$PANEL_PKG_ERRORS" >&5
- have_curses=no
+ have_panel=no
elif test $pkg_failed = untried; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
- have_curses=no
+ have_panel=no
else
- CURSES_CFLAGS=$pkg_cv_CURSES_CFLAGS
- CURSES_LIBS=$pkg_cv_CURSES_LIBS
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
-
-printf "%s\n" "#define HAVE_NCURSESW 1" >>confdefs.h
-
- have_curses=yes
+ have_panel=yes
+fi
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
pkg_failed=no
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for panelw" >&5
-printf %s "checking for panelw... " >&6; }
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gnupanel" >&5
+printf %s "checking for gnupanel... " >&6; }
if test -n "$PANEL_CFLAGS"; then
pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
elif test -n "$PKG_CONFIG"; then
if test -n "$PKG_CONFIG" && \
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"panelw\""; } >&5
- ($PKG_CONFIG --exists --print-errors "panelw") 2>&5
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
ac_status=$?
printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
- pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "panelw" 2>/dev/null`
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "gnupanel" 2>/dev/null`
test "x$?" != "x0" && pkg_failed=yes
else
pkg_failed=yes
pkg_cv_PANEL_LIBS="$PANEL_LIBS"
elif test -n "$PKG_CONFIG"; then
if test -n "$PKG_CONFIG" && \
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"panelw\""; } >&5
- ($PKG_CONFIG --exists --print-errors "panelw") 2>&5
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
ac_status=$?
printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }; then
- pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "panelw" 2>/dev/null`
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "gnupanel" 2>/dev/null`
test "x$?" != "x0" && pkg_failed=yes
else
pkg_failed=yes
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "panelw" 2>&1`
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnupanel" 2>&1`
else
- PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "panelw" 2>&1`
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnupanel" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$PANEL_PKG_ERRORS" >&5
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
have_panel=no
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+ have_panel=yes
+fi
else
PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
PANEL_LIBS=$pkg_cv_PANEL_LIBS
fi
-if test "x$have_curses" = xno
+ if test "x$have_curses" = xno
then :
# Put the nasty error message in config.log where it belongs
echo "$PANEL_PKG_ERRORS" >&5
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gnupanel" >&5
+printf %s "checking for gnupanel... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnupanel" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnupanel" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
+
+ have_panel=no
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+ have_panel=no
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+ have_panel=yes
+fi
+elif test $pkg_failed = untried; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+pkg_failed=no
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gnupanel" >&5
+printf %s "checking for gnupanel... " >&6; }
+
+if test -n "$PANEL_CFLAGS"; then
+ pkg_cv_PANEL_CFLAGS="$PANEL_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_CFLAGS=`$PKG_CONFIG --cflags "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$PANEL_LIBS"; then
+ pkg_cv_PANEL_LIBS="$PANEL_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnupanel\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "gnupanel") 2>&5
+ ac_status=$?
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PANEL_LIBS=`$PKG_CONFIG --libs "gnupanel" 2>/dev/null`
+ test "x$?" != "x0" && pkg_failed=yes
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnupanel" 2>&1`
+ else
+ PANEL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnupanel" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PANEL_PKG_ERRORS" >&5
+
have_panel=no
elif test $pkg_failed = untried; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
have_panel=no
+else
+ PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
+ PANEL_LIBS=$pkg_cv_PANEL_LIBS
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; }
+ have_panel=yes
+fi
else
PANEL_CFLAGS=$pkg_cv_PANEL_CFLAGS
PANEL_LIBS=$pkg_cv_PANEL_LIBS
fi
+ curses_libs="ncursesw ncurses"; panel_libs="panelw panel gnupanel" ;;
+esac
save_CFLAGS=$CFLAGS
save_CPPFLAGS=$CPPFLAGS
save_LIBS=$LIBS
- # Make sure we've got the header defines.
+ # Make sure we've got the header defines. For the native "curses" backend,
+ # probe only the plain headers: a system may also have ncurses headers (e.g.
+ # ncurses/curses.h), and picking those while linking the native library mixes
+ # incompatible declarations (e.g. tparm()) with the native <term.h>.
as_fn_append CPPFLAGS " $CURSES_CFLAGS $PANEL_CFLAGS"
- ac_fn_c_check_header_compile "$LINENO" "ncursesw/curses.h" "ac_cv_header_ncursesw_curses_h" "$ac_includes_default"
+ if test "x$with_curses" = xcurses
+then :
+ ac_fn_c_check_header_compile "$LINENO" "curses.h" "ac_cv_header_curses_h" "$ac_includes_default"
+if test "x$ac_cv_header_curses_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_CURSES_H 1" >>confdefs.h
+
+fi
+ac_fn_c_check_header_compile "$LINENO" "panel.h" "ac_cv_header_panel_h" "$ac_includes_default"
+if test "x$ac_cv_header_panel_h" = xyes
+then :
+ printf "%s\n" "#define HAVE_PANEL_H 1" >>confdefs.h
+
+fi
+
+else case e in #(
+ e) ac_fn_c_check_header_compile "$LINENO" "ncursesw/curses.h" "ac_cv_header_ncursesw_curses_h" "$ac_includes_default"
if test "x$ac_cv_header_ncursesw_curses_h" = xyes
then :
printf "%s\n" "#define HAVE_NCURSESW_CURSES_H 1" >>confdefs.h
printf "%s\n" "#define HAVE_PANEL_H 1" >>confdefs.h
fi
-
+ ;;
+esac
+fi
# Check that we're able to link with crucial curses/panel functions. This
# also serves as a fallback in case pkg-config failed.
return 0;
}
_ACEOF
-for ac_lib in '' ncursesw ncurses
+for ac_lib in '' $curses_libs
do
if test -z "$ac_lib"; then
ac_res="none required"
return 0;
}
_ACEOF
-for ac_lib in '' panelw panel
+for ac_lib in '' $panel_libs
do
if test -z "$ac_lib"; then
ac_res="none required"
-if test "have_curses" != "no"
+if test "$have_curses" != "no"
then :
CURSES_CFLAGS=$(echo $CURSES_CFLAGS | sed 's/-D_XOPEN_SOURCE=600//g')
PANEL_CFLAGS=$(echo $PANEL_CFLAGS | sed 's/-D_XOPEN_SOURCE=600//g')
+if test "x$with_curses" = xcurses
+then :
+
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether curses supports wide characters" >&5
+printf %s "checking whether curses supports wide characters... " >&6; }
+if test ${ac_cv_curses_wide+y}
+then :
+ printf %s "(cached) " >&6
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+#define NCURSES_OPAQUE 0
+#if defined(HAVE_NCURSESW_NCURSES_H)
+# include <ncursesw/ncurses.h>
+#elif defined(HAVE_NCURSESW_CURSES_H)
+# include <ncursesw/curses.h>
+#elif defined(HAVE_NCURSES_NCURSES_H)
+# include <ncurses/ncurses.h>
+#elif defined(HAVE_NCURSES_CURSES_H)
+# include <ncurses/curses.h>
+#elif defined(HAVE_NCURSES_H)
+# include <ncurses.h>
+#elif defined(HAVE_CURSES_H)
+# include <curses.h>
+#endif
+
+int
+main (void)
+{
+
+ cchar_t wcval;
+ setcchar(&wcval, L"x", A_NORMAL, 0, NULL);
+ add_wch(&wcval);
+
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"
+then :
+ ac_cv_curses_wide=yes
+else case e in #(
+ e) ac_cv_curses_wide=no ;;
+esac
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
+ conftest$ac_exeext conftest.$ac_ext ;;
+esac
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_curses_wide" >&5
+printf "%s\n" "$ac_cv_curses_wide" >&6; }
+ if test "x$ac_cv_curses_wide" = xyes
+then :
+ printf "%s\n" "#define HAVE_NCURSESW 1" >>confdefs.h
+
+fi
+
+fi
+
# On Solaris, term.h requires curses.h
ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "
#define NCURSES_OPAQUE 0
fi
dnl check for ncursesw/ncurses and panelw/panel
-dnl NOTE: old curses is not detected.
dnl have_curses=[no, yes]
dnl have_panel=[no, yes]
have_curses=no
have_panel=no
+dnl Select the curses backend, or disable the curses and _curses_panel modules.
+dnl "auto" (the default) prefers ncursesw and falls back to ncurses, both via
+dnl pkg-config. "curses" links the system's native curses (e.g. on NetBSD or
+dnl Solaris), which has no pkg-config file and is never chosen by "auto".
+AC_MSG_CHECKING([for --with-curses])
+AC_ARG_WITH(
+ [curses],
+ [AS_HELP_STRING([--with(out)-curses@<:@=ncursesw|ncurses|curses|no@:>@],
+ [select the curses backend for the curses and _curses_panel
+ modules, or disable them (default: auto)])],
+ [AS_CASE([$with_curses],
+ [yes|auto], [with_curses=auto],
+ [ncursesw|ncurses|curses|no], [],
+ [AC_MSG_ERROR([proper usage is --with(out)-curses@<:@=ncursesw|ncurses|curses|no@:>@])])],
+ [with_curses=auto])
+AC_MSG_RESULT([$with_curses])
+
dnl PY_CHECK_CURSES(LIBCURSES, LIBPANEL)
dnl Sets 'have_curses' and 'have_panel'.
dnl For the PKG_CHECK_MODULES() calls, we can safely reuse the first variable
PKG_CHECK_MODULES([PANEL], [$2],
[AC_DEFINE([HAVE_]panel_var, [1], [Define if you have the '$2' library])
AS_VAR_SET([have_panel], [yes])],
- [AS_VAR_SET([have_panel], [no])])],
+ [dnl pkgsrc renames the ncurses panel to "gnupanel" so it does not clash
+ dnl with a system libpanel; it Requires the same ncurses, so it matches.
+ PKG_CHECK_MODULES([PANEL], [gnupanel],
+ [AS_VAR_SET([have_panel], [yes])],
+ [AS_VAR_SET([have_panel], [no])])])],
[AS_VAR_SET([have_curses], [no])])
AS_VAR_POPDEF([curses_var])
AS_VAR_POPDEF([panel_var])])
-# Check for ncursesw/panelw first. If that fails, try ncurses/panel.
-PY_CHECK_CURSES([ncursesw], [panelw])
-AS_VAR_IF([have_curses], [no],
- [PY_CHECK_CURSES([ncurses], [panel])])
+# Detect the selected backend. ncursesw/ncurses are found via pkg-config;
+# native curses has no .pc file and is left to the header/link probes below.
+# curses_libs/panel_libs drive the AC_SEARCH_LIBS fallback; for "no" they are
+# empty so nothing links and have_curses stays "no".
+AS_CASE([$with_curses],
+ [ncursesw], [PY_CHECK_CURSES([ncursesw], [panelw])
+ curses_libs="ncursesw"; panel_libs="panelw gnupanel"],
+ [ncurses], [PY_CHECK_CURSES([ncurses], [panel])
+ curses_libs="ncurses"; panel_libs="panel gnupanel"],
+ [curses], [curses_libs="curses"; panel_libs="panel"],
+ [no], [curses_libs=""; panel_libs=""],
+ [dnl auto: prefer ncursesw, fall back to ncurses; never native curses.
+ PY_CHECK_CURSES([ncursesw], [panelw])
+ AS_VAR_IF([have_curses], [no], [PY_CHECK_CURSES([ncurses], [panel])])
+ curses_libs="ncursesw ncurses"; panel_libs="panelw panel gnupanel"])
WITH_SAVE_ENV([
- # Make sure we've got the header defines.
+ # Make sure we've got the header defines. For the native "curses" backend,
+ # probe only the plain headers: a system may also have ncurses headers (e.g.
+ # ncurses/curses.h), and picking those while linking the native library mixes
+ # incompatible declarations (e.g. tparm()) with the native <term.h>.
AS_VAR_APPEND([CPPFLAGS], [" $CURSES_CFLAGS $PANEL_CFLAGS"])
- AC_CHECK_HEADERS(m4_normalize([
- ncursesw/curses.h ncursesw/ncurses.h ncursesw/panel.h
- ncurses/curses.h ncurses/ncurses.h ncurses/panel.h
- curses.h ncurses.h panel.h
- ]))
+ AS_VAR_IF([with_curses], [curses],
+ [AC_CHECK_HEADERS([curses.h panel.h])],
+ [AC_CHECK_HEADERS(m4_normalize([
+ ncursesw/curses.h ncursesw/ncurses.h ncursesw/panel.h
+ ncurses/curses.h ncurses/ncurses.h ncurses/panel.h
+ curses.h ncurses.h panel.h
+ ]))])
# Check that we're able to link with crucial curses/panel functions. This
# also serves as a fallback in case pkg-config failed.
AS_VAR_APPEND([LIBS], [" $CURSES_LIBS $PANEL_LIBS"])
- AC_SEARCH_LIBS([initscr], [ncursesw ncurses],
+ AC_SEARCH_LIBS([initscr], [$curses_libs],
[AS_VAR_IF([have_curses], [no],
[AS_VAR_SET([have_curses], [yes])
CURSES_LIBS=${CURSES_LIBS-"$ac_cv_search_initscr"}])],
[AS_VAR_SET([have_curses], [no])])
- AC_SEARCH_LIBS([update_panels], [panelw panel],
+ AC_SEARCH_LIBS([update_panels], [$panel_libs],
[AS_VAR_IF([have_panel], [no],
[AS_VAR_SET([have_panel], [yes])
PANEL_LIBS=${PANEL_LIBS-"$ac_cv_search_update_panels"}])],
#endif
])
-AS_IF([test "have_curses" != "no"], [
+AS_IF([test "$have_curses" != "no"], [
dnl remove _XOPEN_SOURCE macro from curses cflags. pyconfig.h sets
dnl the macro to 700.
CURSES_CFLAGS=$(echo $CURSES_CFLAGS | sed 's/-D_XOPEN_SOURCE=600//g')
dnl pyconfig.h defines _XOPEN_SOURCE=700
PANEL_CFLAGS=$(echo $PANEL_CFLAGS | sed 's/-D_XOPEN_SOURCE=600//g')
+dnl Native curses ("curses") may be wide-character capable (e.g. on NetBSD)
+dnl even though it is not ncursesw. Probe for the wide API; if present, build
+dnl the module against it like ncursesw by defining HAVE_NCURSESW. ncursesw
+dnl already defines HAVE_NCURSESW, and ncurses must stay narrow, so only the
+dnl native backend is probed here.
+AS_VAR_IF([with_curses], [curses], [
+ AC_CACHE_CHECK([whether curses supports wide characters],
+ [ac_cv_curses_wide],
+ [AC_LINK_IFELSE(
+ [AC_LANG_PROGRAM([_CURSES_INCLUDES], [[
+ cchar_t wcval;
+ setcchar(&wcval, L"x", A_NORMAL, 0, NULL);
+ add_wch(&wcval);
+ ]])],
+ [ac_cv_curses_wide=yes],
+ [ac_cv_curses_wide=no])])
+ dnl HAVE_NCURSESW marks the wide (cchar_t) curses API; its template comes
+ dnl from the ncursesw pkg-config check above, so no description here.
+ AS_VAR_IF([ac_cv_curses_wide], [yes], [AC_DEFINE([HAVE_NCURSESW], [1])])
+])
+
# On Solaris, term.h requires curses.h
AC_CHECK_HEADERS([term.h], [], [], _CURSES_INCLUDES)