aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2021-02-26 09:05:35 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2021-02-26 09:05:35 +0000
commit01b7bcd408fd9e9dc9088b1df5761fcc0971d7e1 (patch)
tree593f2e62b1846058a020ffcecb0ef93eb7ac2153
parent4dccdce4191d6e2bc3ba9f782b0fe1aa46b743e3 (diff)
downloadsrc-01b7bcd408fd9e9dc9088b1df5761fcc0971d7e1.tar.gz
src-01b7bcd408fd9e9dc9088b1df5761fcc0971d7e1.zip
dialog: vendor import version 1.3-20210117vendor/dialog/1.3-20210117vendor/dialog
-rw-r--r--CHANGES217
-rw-r--r--README4
-rw-r--r--VERSION2
-rw-r--r--aclocal.m41540
-rw-r--r--argv.c43
-rw-r--r--arrows.c16
-rw-r--r--buildlist.c45
-rw-r--r--buttons.c99
-rw-r--r--calendar.c95
-rw-r--r--checklist.c28
-rw-r--r--columns.c13
-rwxr-xr-xconfig.guess401
-rwxr-xr-xconfig.sub1627
-rwxr-xr-xconfigure13682
-rw-r--r--configure.in30
-rw-r--r--dialog-config.in148
-rw-r--r--dialog.1549
-rw-r--r--dialog.3439
-rw-r--r--dialog.c777
-rw-r--r--dialog.h80
-rw-r--r--dlg_colors.h82
-rw-r--r--dlg_internals.h47
-rw-r--r--dlg_keys.c113
-rw-r--r--dlg_keys.h12
-rw-r--r--editbox.c55
-rw-r--r--formbox.c24
-rw-r--r--fselect.c121
-rw-r--r--guage.c17
-rw-r--r--inputbox.c40
-rw-r--r--inputstr.c22
-rw-r--r--makefile.in13
-rw-r--r--menubox.c59
-rw-r--r--mixedgauge.c19
-rw-r--r--mousewget.c9
-rw-r--r--msgbox.c42
-rw-r--r--package/debian/changelog108
-rw-r--r--package/debian/compat2
-rw-r--r--package/debian/control9
-rw-r--r--package/debian/copyright6
-rwxr-xr-xpackage/debian/rules36
-rw-r--r--package/dialog.map43
-rw-r--r--package/dialog.spec57
-rw-r--r--package/dialog.sym25
-rw-r--r--package/freebsd/Makefile2
-rw-r--r--pause.c21
-rw-r--r--po/ast.po115
-rw-r--r--po/dialog.pot44
-rw-r--r--po/hi.po47
-rw-r--r--po/ja.po48
-rw-r--r--po/pt.po53
-rw-r--r--po/ro.po1
-rw-r--r--po/sq.po88
-rw-r--r--prgbox.c11
-rw-r--r--progressbox.c41
-rw-r--r--rangebox.c45
-rw-r--r--rc.c305
-rwxr-xr-xrun_test.sh (renamed from headers.sh)107
-rwxr-xr-xsamples/buildlist4
-rwxr-xr-xsamples/buildlist210
-rwxr-xr-xsamples/buildlist422
-rwxr-xr-xsamples/calendar6
-rwxr-xr-xsamples/calendar-stdout6
-rwxr-xr-xsamples/calendar26
-rwxr-xr-xsamples/calendar2-stdout6
-rwxr-xr-xsamples/calendar36
-rwxr-xr-xsamples/calendar3-stdout6
-rwxr-xr-xsamples/checklist4
-rwxr-xr-xsamples/checklist-8bit18
-rwxr-xr-xsamples/checklist-utf84
-rwxr-xr-xsamples/checklist14
-rwxr-xr-xsamples/checklist104
-rwxr-xr-xsamples/checklist114
-rwxr-xr-xsamples/checklist126
-rwxr-xr-xsamples/checklist24
-rwxr-xr-xsamples/checklist34
-rwxr-xr-xsamples/checklist44
-rwxr-xr-xsamples/checklist54
-rwxr-xr-xsamples/checklist64
-rwxr-xr-xsamples/checklist74
-rwxr-xr-xsamples/checklist84
-rwxr-xr-xsamples/checklist94
-rwxr-xr-xsamples/copifuncs/copi.ifmcfg24
-rwxr-xr-xsamples/copifuncs/copi.ifmcfg44
-rw-r--r--samples/dialog.py6
-rwxr-xr-xsamples/dselect6
-rwxr-xr-xsamples/editbox4
-rwxr-xr-xsamples/editbox-utf84
-rwxr-xr-xsamples/editbox24
-rwxr-xr-xsamples/editbox34
-rwxr-xr-xsamples/editbox44
-rwxr-xr-xsamples/form116
-rwxr-xr-xsamples/form1-both16
-rwxr-xr-xsamples/form1-extra16
-rwxr-xr-xsamples/form1-help16
-rwxr-xr-xsamples/form1-utf816
-rwxr-xr-xsamples/form28
-rwxr-xr-xsamples/form38
-rwxr-xr-xsamples/form48
-rwxr-xr-xsamples/form58
-rwxr-xr-xsamples/form68
-rwxr-xr-xsamples/fselect6
-rwxr-xr-xsamples/fselect-stdout6
-rwxr-xr-xsamples/fselect06
-rwxr-xr-xsamples/fselect18
-rwxr-xr-xsamples/fselect1-stdout8
-rwxr-xr-xsamples/fselect26
-rwxr-xr-xsamples/fselect2-stdout6
-rwxr-xr-xsamples/gauge24
-rwxr-xr-xsamples/infobox4
-rwxr-xr-xsamples/infobox14
-rwxr-xr-xsamples/infobox24
-rwxr-xr-xsamples/infobox34
-rwxr-xr-xsamples/infobox44
-rwxr-xr-xsamples/infobox54
-rwxr-xr-xsamples/infobox64
-rwxr-xr-xsamples/inputbox4
-rwxr-xr-xsamples/inputbox-both4
-rwxr-xr-xsamples/inputbox-extra4
-rwxr-xr-xsamples/inputbox-help4
-rwxr-xr-xsamples/inputbox14
-rwxr-xr-xsamples/inputbox24
-rwxr-xr-xsamples/inputbox34
-rwxr-xr-xsamples/inputbox46
-rwxr-xr-xsamples/inputbox54
-rwxr-xr-xsamples/inputbox6-8bit10
-rwxr-xr-xsamples/inputbox6-utf84
-rwxr-xr-xsamples/inputbox76
-rwxr-xr-xsamples/inputmenu12
-rwxr-xr-xsamples/inputmenu-stdout12
-rwxr-xr-xsamples/inputmenu112
-rwxr-xr-xsamples/inputmenu212
-rwxr-xr-xsamples/inputmenu314
-rwxr-xr-xsamples/inputmenu412
-rw-r--r--samples/install/setup.c2
-rw-r--r--samples/install/setup.help2
-rwxr-xr-xsamples/killall14
-rwxr-xr-xsamples/menubox8
-rwxr-xr-xsamples/menubox-8bit16
-rwxr-xr-xsamples/menubox-utf84
-rwxr-xr-xsamples/menubox18
-rwxr-xr-xsamples/menubox106
-rwxr-xr-xsamples/menubox116
-rwxr-xr-xsamples/menubox1210
-rwxr-xr-xsamples/menubox212
-rwxr-xr-xsamples/menubox38
-rwxr-xr-xsamples/menubox48
-rwxr-xr-xsamples/menubox510
-rwxr-xr-xsamples/menubox68
-rwxr-xr-xsamples/menubox78
-rwxr-xr-xsamples/menubox812
-rwxr-xr-xsamples/menubox96
-rwxr-xr-xsamples/mixedform16
-rwxr-xr-xsamples/mixedform216
-rwxr-xr-xsamples/msgbox4
-rwxr-xr-xsamples/msgbox-help4
-rwxr-xr-xsamples/msgbox-utf84
-rwxr-xr-xsamples/msgbox112
-rwxr-xr-xsamples/msgbox212
-rwxr-xr-xsamples/msgbox34
-rwxr-xr-xsamples/msgbox4-8bit20
-rwxr-xr-xsamples/msgbox4-utf818
-rwxr-xr-xsamples/msgbox54
-rwxr-xr-xsamples/msgbox64
-rwxr-xr-xsamples/msgbox6a4
-rwxr-xr-xsamples/password4
-rwxr-xr-xsamples/password14
-rwxr-xr-xsamples/password24
-rwxr-xr-xsamples/passwordform116
-rwxr-xr-xsamples/passwordform1-utf816
-rwxr-xr-xsamples/pause4
-rwxr-xr-xsamples/pause-both6
-rwxr-xr-xsamples/pause-extra6
-rwxr-xr-xsamples/pause-help4
-rwxr-xr-xsamples/prgbox4
-rwxr-xr-xsamples/prgbox24
-rwxr-xr-xsamples/programbox4
-rwxr-xr-xsamples/programbox24
-rwxr-xr-xsamples/programbox322
-rwxr-xr-xsamples/progress4
-rwxr-xr-xsamples/progress24
-rwxr-xr-xsamples/radiolist4
-rwxr-xr-xsamples/radiolist14
-rwxr-xr-xsamples/radiolist104
-rwxr-xr-xsamples/radiolist24
-rwxr-xr-xsamples/radiolist34
-rwxr-xr-xsamples/radiolist44
-rwxr-xr-xsamples/rangebox6
-rwxr-xr-xsamples/rangebox26
-rwxr-xr-xsamples/rangebox36
-rwxr-xr-xsamples/rangebox46
-rw-r--r--samples/report-button10
-rw-r--r--samples/report-edit10
-rw-r--r--samples/report-string18
-rw-r--r--samples/report-tempfile18
-rw-r--r--samples/report-yesno10
-rwxr-xr-xsamples/rotated-data6
-rwxr-xr-xsamples/run_test.sh10
-rw-r--r--samples/setup-vars29
-rwxr-xr-xsamples/tailbox4
-rwxr-xr-xsamples/tailboxbg4
-rwxr-xr-xsamples/tailboxbg16
-rwxr-xr-xsamples/tailboxbg26
-rw-r--r--[-rwxr-xr-x]samples/testdata-8bit0
-rwxr-xr-xsamples/textbox6
-rwxr-xr-xsamples/textbox-both8
-rwxr-xr-xsamples/textbox-help8
-rwxr-xr-xsamples/textbox26
-rwxr-xr-xsamples/textbox38
-rwxr-xr-xsamples/timebox6
-rwxr-xr-xsamples/timebox-stdout6
-rwxr-xr-xsamples/timebox26
-rwxr-xr-xsamples/timebox2-stdout6
-rwxr-xr-xsamples/treeview4
-rwxr-xr-xsamples/treeview26
-rwxr-xr-xsamples/treeview424
-rwxr-xr-xsamples/wheel81
-rwxr-xr-xsamples/yesno4
-rwxr-xr-xsamples/yesno-both4
-rwxr-xr-xsamples/yesno-extra4
-rwxr-xr-xsamples/yesno-help4
-rwxr-xr-xsamples/yesno-utf84
-rwxr-xr-xsamples/yesno24
-rwxr-xr-xsamples/yesno34
-rwxr-xr-xsamples/yesno44
-rw-r--r--tailbox.c40
-rw-r--r--textbox.c142
-rw-r--r--timebox.c41
-rw-r--r--trace.c32
-rw-r--r--treeview.c38
-rw-r--r--ttysize.c8
-rw-r--r--ui_getc.c67
-rw-r--r--util.c514
-rw-r--r--yesno.c36
233 files changed, 14032 insertions, 9894 deletions
diff --git a/CHANGES b/CHANGES
index 17c5b2735487..8e5d22e400a3 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,9 +1,222 @@
--- $Id: CHANGES,v 1.619 2018/06/21 09:19:45 tom Exp $
+-- $Id: CHANGES,v 1.723 2021/01/17 20:21:41 tom Exp $
-- Thomas E. Dickey <dickey@invisible-island.net>
This version of dialog was originally from a Debian snapshot. I've done this
to it:
+2021/01/17
+ + updated dialog.pot
+ + add option --no-hot-list, to allow suppressing the hotkey feature
+ from lists.
+ + increase minimum height of inputbox to avoid input field overlapping
+ with the button-box (report by Victor Ananjevsky).
+ + modify options-parsing to permit a "no" on any boolean option and
+ deprecating the "no" options without a "-" , e.g., generalizing on
+ "--nook" equivalence to "--no-ok".
+
+2021/01/12
+ + minor spelling fixes, per codespell
+ + update configure macros, for quoting/escaping fixes per shellcheck
+ + update config.guess, config.sub
+
+2020/11/26
+ + modify configure script's compiler check to work around Xcode's
+ useless aliases for standard C.
+ + enable keep-tite feature for NetBSD 8 and up; earlier releases would
+ dump core.
+ > new features/fixes (Glenn Herteg)
+ + add option "--cursor-off-label"
+ + add option "--erase-on-exit"
+ + fix errata in manpage.
+ + fix logic: dlg_button_to_char() would return wrong value if no
+ uppercase was found
+
+2020/11/25
+ + add DIALOG_TIMEOUT to sample scripts, and use report-button more
+ consistently to handle unexpected exit-status values.
+
+2020/11/24
+ + add dlg_getenv_num() and dlg_getenv_str().
+ + add DLG_EXIT_TIMEOUT to allow scripts to exit on an expired timeout
+ with an exit-status different from DLG_EXIT_ERROR or DLG_EXIT_ESC
+ (patch by Norbert Koch).
+
+2020/11/23
+ + modify dlg_ok_label() and dlg_ok_labels() to ignore --no-ok if all
+ buttons would be omitted.
+ + add/use dlg_der_window() to account for derived windows just like
+ subwindows, to fix regression in dlg_getc() in fselect/dselect
+ widget.
+ + modify several widgets to make their handling of --no-ok consistent
+ with the majority of the widgets: editbox.c, menubox.c, msgbox.c,
+ rangebox.c, textbox.c, timebox.c
+ + add ^D as binding for new virtual key DLGK_LEAVE, which will close
+ the current dialog by activating the currently-selected button.
+ + improve manual-page description of --no-ok option (reports by
+ Hans Mueller, Gil Delescluse).
+ + modify configure script to make Solaris -R rpath feature work
+
+2020/11/21
+ + fix regression in dlg_getc() caused by not taking into account
+ subwindows used for input (report by Michael Wihl).
+
+2020/11/20
+ + add validity-checks for window pointer (report/testcase by Michael
+ Wihl).
+ + improve configure macros:
+ CF_CLANG_COMPILER: apply compiler-flags needed for test.
+ CF_WITH_SCREEN_PDCURSES: use this to reduce X11-checks.
+
+2020/11/17
+ + amend initialization for dlg_getc to fix regression in pause widget
+ from 2020/03/27 changes (reports by Aidan Tessier, Norbert Koch,
+ Josmar Pierri).
+ + improve configure macros:
+ CF_CLANG_COMPILER: split-out check for -Qunused-arguments to ensure
+ that clang supports it. IBM xlclang does not.
+ CF_MIXEDCASE_FILENAMES: when cross-compiling to darwin (macOS),
+ assume the filesystem doesn't support mixed-case
+
+2020/09/21
+ + modify init_dialog's initialization of tab_len and aspect_ratio to
+ avoid overwriting initialization done in process_common_options
+ (report/patch by Rainer Weikusat, Debian #970508).
+
+2020/09/13
+ + fix out-of-order description for --tailbox vs --rangebox in manpage
+ (report by Glenn Herteg).
+ + updated configure-macros: compiler-warnings and shared-library
+ options. Changed configure --with-warnings to --enable-warnings for
+ consistency.
+ + update config.guess
+
+2020/04/01
+ + updated sq.po from
+ http://translationproject.org/latest/dialog/
+
+2020/03/27
+ + add clarification in manual page to show when the single/double
+ quotes may be needed (prompted by discussion with Danilo G Baio).
+ + fix an extra ".exe" in makefile.in which prevented Cygwin build.
+ + fix most cppcheck warnings
+ + tailbox/tailboxbg's exit-button now works with mouse-clicks
+ + fix repainting while resizing for the editbox widget.
+ + add configure-check for curses_exit() from ncurses 6.2
+ + fix a few memory leaks in fselect.c, mixedgauge.c when resizing.
+ + fix inconsistency in dlg_string_to_argv() which made the checklist9
+ example not work.
+ + add empty-string check in dlg_print_listitem() to avoid indexing past
+ the end of the array of character-offsets.
+ + improve handling of KEY_RESIZE by repainting the backtitle after
+ clearing the screen (integrated patch by Rainer Weikusat, Debian
+ #954185).
+ + improve logic for wtimeout() calls which are used to set temporary
+ non-blocking reads (prompted by patch by Rainer Weikusat, Debian
+ #954220).
+ + add "make check" rule.
+ + updated configure-macros.
+
+2020/02/28
+ + updated configure-macros, to work around ncurses vs xcode's c99 -W
+ + update config.guess
+
+2019/12/31
+ + updated configure-macros.
+ + update config.guess
+
+2019/12/10
+ + correct rc-file lookup of "default" color (report by Grady Martin,
+ cf: 2019/09/24).
+ + fix several issues in the sample scripts reported by shellcheck.
+ + fix a few spelling errors reported by codespell (report by Jens
+ Schleusener).
+ + correct check for return-value of isblank(), which is not necessarily
+ 0/1 (report/patch by Paul Cercueil, Peter Korsgaard, cf: 2018/05/31).
+
+2019/12/09
+ + amend change for parsing command-options before calling init_dialog,
+ to handle --no-shadow, etc., which are initialized in init_dialog
+ (report by Paul Cercueil, cf: 2018/06/21).
+ + add dlg_trace_va_msg to manpage, symbol files.
+
+2019/11/10
+ + improve layout of several widgets' data area when maximizing.
+ + modify dselect/fselect to work with autosizing (Debian #915949).
+ + add error messages from dlg_exiterr() to trace file.
+ + improve manual page description of escaping in key-bindings.
+ + modify inputmenu to recognize the "Cancel" button and keys bound to
+ that feature while editing a renamed menu item.
+ + revert one change, in form.c to the --last-key feature (Debian
+ #942025).
+ + correct ordering of libraries in configure-script, which appended
+ in a case where it should have prepended.
+ + update config.guess, config.sub
+
+2019/09/26
+ + improve dialog-config script's filtering of -L options using the
+ linker default directories.
+ + improve dialog-config script, adding a -L option corresponding to
+ the configure --libdir option if it would be a duplicate (report by
+ Andrew Kosteltsev).
+ + build-fix for configure --disable-trace
+ + updated pt.po from
+ http://translationproject.org/latest/dialog/
+
+2019/09/24
+ + allow for underline- and reverse-video flags in the ".rc" file
+ (integrated patch by Richard Robbins).
+
+2019/08/08
+ + amend change to --last-key feature to eliminate an unnecessary
+ separator (report by Gabriele Balducci).
+
+2019/08/06
+ + extend --last-key feature to the remaining widgets which have
+ ok/cancel buttons, and add logic to map keys which happen to be
+ bound to ok/extra/cancel/help to simulate a button-press on the
+ corresponding button (report by "sgewrk").
+
+2019/08/01
+ + further fixes for dialog-config.in (report by Andrew Kosteltsev).
+
+2019/07/28
+ + modify dialog-config.in so that setting prefix or exec-prefix to
+ a given value with --prefix=VALUE or --exec-prefix=VALUE has the
+ expected result of changing bindir, etc.
+ + correct substitution for $LIBS value in dialog-config.in (report by
+ Andrew Kosteltsev).
+
+2019/07/24
+ + modify dlg_will_resize() and dlg_result_key() functions to reduce
+ the chance that dialog exits on a SIGWINCH (Debian #930775).
+ + make test-package for the development headers/library
+ + add --libs-only-L, etc., to dialog-config script (prompted by
+ discussion with Andrew Kosteltsev).
+ + fix a memory leak in gauge widget (Andrew Kosteltsev).
+ + minor fix for CF_GCC_WARNINGS
+ + update config.guess, config.sub
+
+2019/02/11
+ + modify to work with ncurses' threaded-library, which does not allow
+ assignment to LINES/COLS (report by Marcus Roeckrath).
+ + correct clearing after text in progressbox from 2018/06/21 changes
+ for resizing (reports by David Boyd, Alan Somers).
+ + improved configure macros CF_GNU_SOURCE, CF_POSIX_C_SOURCE,
+ CF_XOPEN_SOURCE
+ + update config.guess, config.sub
+
+2018/11/07
+ + convert ja.po to UTF-8 for consistency (suggested by Stanislav
+ Brabec).
+ + repair mis-encoded hi.po (report/analysis by Stanislav Brabec).
+
+2018/10/22
+ + improved configure macros CF_CC_ENV_FLAGS, CF_LD_RPATH_OPT,
+ CF_LIBRARY_PATH, CF_SHARED_OPTS, CF_WITH_MAN2HTML,
+ CF_WITH_VERSIONED_SYMS from ncurses
+ + add ast.po, from
+ http://translationproject.org/latest/dialog/
+
2018/06/21
+ improve file-offset computation in textbox.c (Werner Fink).
+ fix an overlooked case with real_auto_size() to maximize when
@@ -370,7 +583,7 @@ to it:
2012/12/30 - release 1.2
+ improve some older changelog entries to help with HTML'izing content.
- + various fixes/improvments for scrollbar appearance.
+ + various fixes/improvements for scrollbar appearance.
+ add mappings for some equivalent options provided by whiptail;
add configure option --disable-whiptail to allow suppressing these.
+ add configure option --disable-Xdialog2 to allow suppressing the
diff --git a/README b/README
index b2c9b8595dbc..1bad4311dd40 100644
--- a/README
+++ b/README
@@ -38,11 +38,11 @@ For the future, if any volunteer want, the way to evolve cdialog is to
multithreading.
2) add an option that could permit to read commands (--options) from a
file, like as in a normal programming language, but maintaining
- compatiblity with older version of dialog.
+ compatibility with older version of dialog.
I no longer could maintain cdialog...
Executable and library name of cdialog are the same of dialog, for
-compatiblity.
+compatibility.
I think that only one directive should be follow: don't use a resource
like stdin, stdout when you'll write new options for cdialog; these
diff --git a/VERSION b/VERSION
index 12fccce09544..fc653b601c01 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-15:0:0 1.3 20180621
+15:0:0 1.3 20210117
diff --git a/aclocal.m4 b/aclocal.m4
index c33827fce67b..191ba9c373fe 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,7 +1,7 @@
dnl macros used for DIALOG configure script
-dnl $Id: aclocal.m4,v 1.120 2018/06/21 00:30:26 tom Exp $
+dnl $Id: aclocal.m4,v 1.150 2021/01/11 09:03:36 tom Exp $
dnl ---------------------------------------------------------------------------
-dnl Copyright 1999-2017,2018 -- Thomas E. Dickey
+dnl Copyright 1999-2020,2021 -- Thomas E. Dickey
dnl
dnl Permission is hereby granted, free of charge, to any person obtaining a
dnl copy of this software and associated documentation files (the
@@ -28,10 +28,10 @@ dnl sale, use or other dealings in this Software without prior written
dnl authorization.
dnl
dnl see
-dnl http://invisible-island.net/autoconf/
+dnl https://invisible-island.net/autoconf/
dnl ---------------------------------------------------------------------------
dnl ---------------------------------------------------------------------------
-dnl AM_GNU_GETTEXT version: 14 updated: 2015/04/15 19:08:48
+dnl AM_GNU_GETTEXT version: 15 updated: 2021/01/02 09:31:20
dnl --------------
dnl Usage: Just like AM_WITH_NLS, which see.
AC_DEFUN([AM_GNU_GETTEXT],
@@ -76,7 +76,7 @@ strdup strtoul tsearch __argz_count __argz_stringify __argz_next])
("$presentlang"*) useit=yes;;
esac
done
- if test $useit = yes; then
+ if test "$useit" = yes; then
NEW_LINGUAS="$NEW_LINGUAS $presentlang"
fi
done
@@ -167,7 +167,7 @@ size_t iconv();
AC_SUBST(LIBICONV)
])dnl
dnl ---------------------------------------------------------------------------
-dnl AM_LANGINFO_CODESET version: 4 updated: 2015/04/18 08:56:57
+dnl AM_LANGINFO_CODESET version: 6 updated: 2021/01/01 16:53:59
dnl -------------------
dnl Inserted as requested by gettext 0.10.40
dnl File from /usr/share/aclocal
@@ -180,17 +180,17 @@ AC_DEFUN([AM_LANGINFO_CODESET],
[
AC_CACHE_CHECK([for nl_langinfo and CODESET], am_cv_langinfo_codeset,
[AC_TRY_LINK([#include <langinfo.h>],
- [char* cs = nl_langinfo(CODESET);],
+ [char* cs = nl_langinfo(CODESET); (void)cs],
am_cv_langinfo_codeset=yes,
am_cv_langinfo_codeset=no)
])
- if test $am_cv_langinfo_codeset = yes; then
+ if test "$am_cv_langinfo_codeset" = yes; then
AC_DEFINE(HAVE_LANGINFO_CODESET, 1,
[Define if you have <langinfo.h> and nl_langinfo(CODESET).])
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl AM_LC_MESSAGES version: 5 updated: 2015/05/10 19:52:14
+dnl AM_LC_MESSAGES version: 6 updated: 2021/01/02 09:31:20
dnl --------------
dnl Inserted as requested by gettext 0.10.40
dnl File from /usr/share/aclocal
@@ -211,17 +211,17 @@ dnl
dnl serial 2
dnl
AC_DEFUN([AM_LC_MESSAGES],
-[if test $ac_cv_header_locale_h = yes; then
+[if test "$ac_cv_header_locale_h" = yes; then
AC_CACHE_CHECK([for LC_MESSAGES], am_cv_val_LC_MESSAGES,
[AC_TRY_LINK([#include <locale.h>], [return LC_MESSAGES],
am_cv_val_LC_MESSAGES=yes, am_cv_val_LC_MESSAGES=no)])
- if test $am_cv_val_LC_MESSAGES = yes; then
+ if test "$am_cv_val_LC_MESSAGES" = yes; then
AC_DEFINE(HAVE_LC_MESSAGES, 1,
[Define if your <locale.h> file defines LC_MESSAGES.])
fi
fi])dnl
dnl ---------------------------------------------------------------------------
-dnl AM_PATH_PROG_WITH_TEST version: 9 updated: 2015/04/15 19:08:48
+dnl AM_PATH_PROG_WITH_TEST version: 10 updated: 2021/01/02 09:31:20
dnl ----------------------
dnl Inserted as requested by gettext 0.10.40
dnl File from /usr/share/aclocal
@@ -257,7 +257,7 @@ AC_CACHE_VAL(ac_cv_path_$1,
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}"
for ac_dir in ifelse([$5], , $PATH, [$5]); do
test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word$ac_exeext; then
+ if test -f "$ac_dir/$ac_word$ac_exeext" ; then
if [$3]; then
ac_cv_path_$1="$ac_dir/$ac_word$ac_exeext"
break
@@ -280,7 +280,7 @@ fi
AC_SUBST($1)dnl
])dnl
dnl ---------------------------------------------------------------------------
-dnl AM_WITH_NLS version: 29 updated: 2018/02/21 21:26:03
+dnl AM_WITH_NLS version: 31 updated: 2021/01/04 17:48:08
dnl -----------
dnl Inserted as requested by gettext 0.10.40
dnl File from /usr/share/aclocal
@@ -384,13 +384,13 @@ AC_DEFUN([AM_WITH_NLS],
dnl Search for GNU msgfmt in the PATH.
AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
- [$ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1], :)
+ ["$ac_dir/$ac_word" --statistics /dev/null >/dev/null 2>&1], :)
AC_PATH_PROG(GMSGFMT, gmsgfmt, $MSGFMT)
AC_SUBST(MSGFMT)
dnl Search for GNU xgettext in the PATH.
AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
- [$ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1], :)
+ ["$ac_dir/$ac_word" --omit-header /dev/null >/dev/null 2>&1], :)
cf_save_OPTS_1="$CPPFLAGS"
if test "x$cf_save_msgfmt_path" = "x$MSGFMT" && \
@@ -466,7 +466,7 @@ AC_DEFUN([AM_WITH_NLS],
if test "$nls_cv_use_gnu_gettext" != "no"; then
CATOBJEXT=.gmo
- if test -f $srcdir/intl/libintl.h ; then
+ if test -f "$srcdir/intl/libintl.h" ; then
dnl Mark actions used to generate GNU NLS library.
INTLOBJS="\$(GETTOBJS)"
BUILD_INCLUDED_LIBINTL=yes
@@ -511,10 +511,10 @@ AC_DEFUN([AM_WITH_NLS],
case "$ac_file" in
(*/[Mm]akefile.in)
# Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
+ ac_dir="`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`"
ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- ac_base=`basename $ac_file .in`
+ ac_dots="`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`"
+ ac_base="`basename $ac_file .in`"
# In autoconf-2.13 it is called $ac_given_srcdir.
# In autoconf-2.50 it is called $srcdir.
test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
@@ -561,7 +561,7 @@ AC_DEFUN([AM_WITH_NLS],
AC_MSG_CHECKING([version of bison])
changequote(<<,>>)dnl
ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
- case $ac_prog_version in
+ case "$ac_prog_version" in
('') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
(1.2[6-9]*|1.[3-9][0-9]*|[2-9].*)
changequote([,])dnl
@@ -570,7 +570,7 @@ changequote([,])dnl
esac
AC_MSG_RESULT([$ac_prog_version])
fi
- if test $ac_verc_fail = yes; then
+ if test "$ac_verc_fail" = yes; then
INTLBISON=:
fi
fi
@@ -638,10 +638,11 @@ define([CF_ACVERSION_COMPARE],
[ifelse([$8], , ,[$8])],
[ifelse([$9], , ,[$9])])])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_ADD_CFLAGS version: 13 updated: 2017/02/25 18:57:40
+dnl CF_ADD_CFLAGS version: 15 updated: 2020/12/31 10:54:15
dnl -------------
dnl Copy non-preprocessor flags to $CFLAGS, preprocessor flags to $CPPFLAGS
-dnl The second parameter if given makes this macro verbose.
+dnl $1 = flags to add
+dnl $2 = if given makes this macro verbose.
dnl
dnl Put any preprocessor definitions that use quoted strings in $EXTRA_CPPFLAGS,
dnl to simplify use of $CPPFLAGS in compiler checks, etc., that are easily
@@ -655,19 +656,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $1
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[[^=]]*='\''\"[[^"]]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[[^=]]*='\''\"[[^"]]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
CF_APPEND_TEXT(cf_new_extra_cppflags,$cf_add_cflags)
continue
elif test "${cf_tst_cflags}" = "\"'" ; then
@@ -680,7 +681,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
CF_REMOVE_DEFINE(CPPFLAGS,$CPPFLAGS,$cf_tst_cppflags)
@@ -698,7 +699,7 @@ case $cf_fix_cppflags in
(yes)
CF_APPEND_TEXT(cf_new_extra_cppflags,$cf_add_cflags)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[[^"]]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[[^"]]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -726,7 +727,7 @@ AC_SUBST(EXTRA_CPPFLAGS)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_ADD_INCDIR version: 15 updated: 2018/06/20 20:23:13
+dnl CF_ADD_INCDIR version: 16 updated: 2020/12/31 20:19:42
dnl -------------
dnl Add an include-directory to $CPPFLAGS. Don't add /usr/include, since it's
dnl redundant. We don't normally need to add -I/usr/local/include for gcc,
@@ -738,9 +739,9 @@ AC_DEFUN([CF_ADD_INCDIR],
if test -n "$1" ; then
for cf_add_incdir in $1
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -771,7 +772,7 @@ if test -n "$1" ; then
CF_VERBOSE(adding $cf_add_incdir to include-path)
ifelse([$2],,CPPFLAGS,[$2])="$ifelse([$2],,CPPFLAGS,[$2]) -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -793,7 +794,7 @@ dnl $1 = library to add, without the "-l"
dnl $2 = variable to update (default $LIBS)
AC_DEFUN([CF_ADD_LIB],[CF_ADD_LIBS(-l$1,ifelse($2,,LIBS,[$2]))])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_ADD_LIBDIR version: 10 updated: 2015/04/18 08:56:57
+dnl CF_ADD_LIBDIR version: 11 updated: 2020/12/31 20:19:42
dnl -------------
dnl Adds to the library-path
dnl
@@ -807,9 +808,9 @@ AC_DEFUN([CF_ADD_LIBDIR],
if test -n "$1" ; then
for cf_add_libdir in $1
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -829,7 +830,7 @@ if test -n "$1" ; then
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_ADD_LIBS version: 2 updated: 2014/07/13 14:33:27
+dnl CF_ADD_LIBS version: 3 updated: 2019/11/02 16:47:33
dnl -----------
dnl Add one or more libraries, used to enforce consistency. Libraries are
dnl prepended to an existing list, since their dependencies are assumed to
@@ -838,19 +839,19 @@ dnl
dnl $1 = libraries to add, with the "-l", etc.
dnl $2 = variable to update (default $LIBS)
AC_DEFUN([CF_ADD_LIBS],[
-cf_add_libs="$1"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in [$]ifelse($2,,LIBS,[$2])
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="[$]ifelse($2,,LIBS,[$2])"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $1; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
ifelse($2,,LIBS,[$2])="$cf_add_libs"
])dnl
@@ -887,7 +888,7 @@ case "$1" in
esac
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_ADD_SEARCHPATH version: 5 updated: 2009/01/11 20:40:21
+dnl CF_ADD_SEARCHPATH version: 6 updated: 2020/12/31 20:19:42
dnl -----------------
dnl Set $CPPFLAGS and $LDFLAGS with the directories given via the parameter.
dnl They can be either the common root of include- and lib-directories, or the
@@ -900,16 +901,16 @@ AC_DEFUN([CF_ADD_SEARCHPATH],
[
AC_REQUIRE([CF_PATHSEP])
for cf_searchpath in `echo "$1" | tr $PATH_SEPARATOR ' '`; do
- if test -d $cf_searchpath/include; then
+ if test -d "$cf_searchpath/include" ; then
CF_ADD_INCDIR($cf_searchpath/include)
- elif test -d $cf_searchpath/../include ; then
+ elif test -d "$cf_searchpath/../include" ; then
CF_ADD_INCDIR($cf_searchpath/../include)
ifelse([$2],,,[else
$2])
fi
- if test -d $cf_searchpath/lib; then
+ if test -d "$cf_searchpath/lib" ; then
CF_ADD_LIBDIR($cf_searchpath/lib)
- elif test -d $cf_searchpath ; then
+ elif test -d "$cf_searchpath" ; then
CF_ADD_LIBDIR($cf_searchpath)
ifelse([$2],,,[else
$2])
@@ -917,7 +918,7 @@ $2])
done
])
dnl ---------------------------------------------------------------------------
-dnl CF_ADD_SUBDIR_PATH version: 4 updated: 2013/10/08 17:47:05
+dnl CF_ADD_SUBDIR_PATH version: 5 updated: 2020/12/31 20:19:42
dnl ------------------
dnl Append to a search-list for a nonstandard header/lib-file
dnl $1 = the variable to return as result
@@ -929,13 +930,13 @@ AC_DEFUN([CF_ADD_SUBDIR_PATH],
[
test "x$4" != "x$5" && \
test -d "$4" && \
-ifelse([$5],NONE,,[(test -z "$5" || test x$5 = xNONE || test "x$4" != "x$5") &&]) {
+ifelse([$5],NONE,,[{ test -z "$5" || test "x$5" = xNONE || test "x$4" != "x$5"; } &&]) {
test -n "$verbose" && echo " ... testing for $3-directories under $4"
- test -d $4/$3 && $1="[$]$1 $4/$3"
- test -d $4/$3/$2 && $1="[$]$1 $4/$3/$2"
- test -d $4/$3/$2/$3 && $1="[$]$1 $4/$3/$2/$3"
- test -d $4/$2/$3 && $1="[$]$1 $4/$2/$3"
- test -d $4/$2/$3/$2 && $1="[$]$1 $4/$2/$3/$2"
+ test -d "$4/$3" && $1="[$]$1 $4/$3"
+ test -d "$4/$3/$2" && $1="[$]$1 $4/$3/$2"
+ test -d "$4/$3/$2/$3" && $1="[$]$1 $4/$3/$2/$3"
+ test -d "$4/$2/$3" && $1="[$]$1 $4/$2/$3"
+ test -d "$4/$2/$3/$2" && $1="[$]$1 $4/$2/$3/$2"
}
])dnl
dnl ---------------------------------------------------------------------------
@@ -955,6 +956,12 @@ dnl Allow user to disable a normally-on option.
AC_DEFUN([CF_ARG_DISABLE],
[CF_ARG_OPTION($1,[$2],[$3],[$4],yes)])dnl
dnl ---------------------------------------------------------------------------
+dnl CF_ARG_ENABLE version: 3 updated: 1999/03/30 17:24:31
+dnl -------------
+dnl Allow user to enable a normally-off option.
+AC_DEFUN([CF_ARG_ENABLE],
+[CF_ARG_OPTION($1,[$2],[$3],[$4],no)])dnl
+dnl ---------------------------------------------------------------------------
dnl CF_ARG_MSG_ENABLE version: 2 updated: 2000/07/29 19:32:03
dnl -----------------
dnl Verbose form of AC_ARG_ENABLE:
@@ -1000,7 +1007,7 @@ ifelse([$3],,[ :]dnl
])dnl
])])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_AR_FLAGS version: 6 updated: 2015/10/10 15:25:05
+dnl CF_AR_FLAGS version: 9 updated: 2021/01/01 13:31:04
dnl -----------
dnl Check for suitable "ar" (archiver) options for updating an archive.
dnl
@@ -1011,39 +1018,55 @@ AC_DEFUN([CF_AR_FLAGS],[
AC_REQUIRE([CF_PROG_AR])
AC_CACHE_CHECK(for options to update archives, cf_cv_ar_flags,[
- cf_cv_ar_flags=unknown
- for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
- do
+ case "$cf_cv_system_name" in
+ (*-msvc*)
+ cf_cv_ar_flags=''
+ cat >mk_static_lib.sh <<-EOF
+ #!$SHELL
+ MSVC_BIN="[$]AR"
+ out="\[$]1"
+ shift
+ exec \[$]MSVC_BIN -out:"\[$]out" \[$]@
+ EOF
+ chmod +x mk_static_lib.sh
+ AR=`pwd`/mk_static_lib.sh
+ ;;
+ (*)
+ cf_cv_ar_flags=unknown
+ for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
+ do
- # check if $ARFLAGS already contains this choice
- if test "x$ARFLAGS" != "x" ; then
- cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
- if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
- cf_cv_ar_flags=
- break
+ # check if $ARFLAGS already contains this choice
+ if test "x$ARFLAGS" != "x" ; then
+ cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
+ if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
+ cf_cv_ar_flags=
+ break
+ fi
fi
- fi
- rm -f conftest.$ac_cv_objext
- rm -f conftest.a
+ rm -f "conftest.$ac_cv_objext"
+ rm -f conftest.a
- cat >conftest.$ac_ext <<EOF
+ cat >"conftest.$ac_ext" <<EOF
#line __oline__ "configure"
int testdata[[3]] = { 123, 456, 789 };
EOF
- if AC_TRY_EVAL(ac_compile) ; then
- echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&AC_FD_CC
- $AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&AC_FD_CC 1>/dev/null
- if test -f conftest.a ; then
- cf_cv_ar_flags=$cf_ar_flags
+ if AC_TRY_EVAL(ac_compile) ; then
+ echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&AC_FD_CC
+ $AR $ARFLAGS "$cf_ar_flags" conftest.a "conftest.$ac_cv_objext" 2>&AC_FD_CC 1>/dev/null
+ if test -f conftest.a ; then
+ cf_cv_ar_flags="$cf_ar_flags"
+ break
+ fi
+ else
+ CF_VERBOSE(cannot compile test-program)
break
fi
- else
- CF_VERBOSE(cannot compile test-program)
- break
- fi
- done
- rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext
+ done
+ rm -f conftest.a "conftest.$ac_ext" "conftest.$ac_cv_objext"
+ ;;
+ esac
])
if test -n "$ARFLAGS" ; then
@@ -1057,7 +1080,7 @@ fi
AC_SUBST(ARFLAGS)
])
dnl ---------------------------------------------------------------------------
-dnl CF_BUNDLED_INTL version: 19 updated: 2018/06/20 20:23:13
+dnl CF_BUNDLED_INTL version: 20 updated: 2021/01/02 09:31:20
dnl ---------------
dnl Top-level macro for configuring an application with a bundled copy of
dnl the intl and po directories for gettext.
@@ -1088,7 +1111,7 @@ cf_makefile=ifelse($1,,Makefile,$1)
dnl Set of available languages (based on source distribution). Note that
dnl setting $LINGUAS overrides $ALL_LINGUAS. Some environments set $LINGUAS
dnl rather than $LC_ALL
-test -z "$ALL_LINGUAS" && ALL_LINGUAS=`test -d $srcdir/po && cd $srcdir/po && echo *.po|sed -e 's/\.po//g' -e 's/*//'`
+test -z "$ALL_LINGUAS" && ALL_LINGUAS=`test -d "$srcdir/po" && cd "$srcdir/po" && echo *.po|sed -e 's/\.po//g' -e 's/*//'`
# Allow override of "config.h" definition:
: ${CONFIG_H:=config.h}
@@ -1099,8 +1122,8 @@ if test -z "$PACKAGE" ; then
fi
if test -z "$VERSION" ; then
-if test -f $srcdir/VERSION ; then
- VERSION=`sed -e '2,$d' $srcdir/VERSION|cut -f1`
+if test -f "$srcdir/VERSION" ; then
+ VERSION=`sed -e '2,$d' "$srcdir/VERSION" |cut -f1`
else
VERSION=unknown
fi
@@ -1187,7 +1210,7 @@ if test "$USE_INCLUDED_LIBINTL" = yes ; then
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CC_ENV_FLAGS version: 8 updated: 2017/09/23 08:50:24
+dnl CF_CC_ENV_FLAGS version: 10 updated: 2020/12/31 18:40:20
dnl ---------------
dnl Check for user's environment-breakage by stuffing CFLAGS/CPPFLAGS content
dnl into CC. This will not help with broken scripts that wrap the compiler
@@ -1202,13 +1225,30 @@ dnl outweighs that limitation.
AC_DEFUN([CF_CC_ENV_FLAGS],
[
# This should have been defined by AC_PROG_CC
-: ${CC:=cc}
+: "${CC:=cc}"
+
+AC_MSG_CHECKING(\$CFLAGS variable)
+case "x$CFLAGS" in
+(*-[[IUD]]*)
+ AC_MSG_RESULT(broken)
+ AC_MSG_WARN(your environment uses the CFLAGS variable to hold CPPFLAGS options)
+ cf_flags="$CFLAGS"
+ CFLAGS=
+ for cf_arg in $cf_flags
+ do
+ CF_ADD_CFLAGS($cf_arg)
+ done
+ ;;
+(*)
+ AC_MSG_RESULT(ok)
+ ;;
+esac
AC_MSG_CHECKING(\$CC variable)
case "$CC" in
(*[[\ \ ]]-*)
AC_MSG_RESULT(broken)
- AC_MSG_WARN(your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options)
+ AC_MSG_WARN(your environment uses the CC variable to hold CFLAGS/CPPFLAGS options)
# humor him...
cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[[ ]]* / /g' -e 's/[[ ]]*[[ ]]-[[^ ]].*//'`
cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", [substr]([$]0,1+length(prog))); }'`
@@ -1234,7 +1274,7 @@ case "$CC" in
esac
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CHECK_CACHE version: 12 updated: 2012/10/02 20:55:03
+dnl CF_CHECK_CACHE version: 13 updated: 2020/12/31 10:54:15
dnl --------------
dnl Check if we're accidentally using a cache from a different machine.
dnl Derive the system name, as a check for reusing the autoconf cache.
@@ -1248,7 +1288,7 @@ dnl Note: we would use $ac_config_sub, but that is one of the places where
dnl autoconf 2.5x broke compatibility with autoconf 2.13
AC_DEFUN([CF_CHECK_CACHE],
[
-if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
+if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
ifelse([$1],,[AC_CANONICAL_HOST],[$1])
system_name="$host_os"
else
@@ -1269,7 +1309,7 @@ if test ".$system_name" != ".$cf_cv_system_name" ; then
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CHECK_CFLAGS version: 3 updated: 2014/07/22 05:32:57
+dnl CF_CHECK_CFLAGS version: 4 updated: 2021/01/02 19:22:58
dnl ---------------
dnl Conditionally add to $CFLAGS and $CPPFLAGS values which are derived from
dnl a build-configuration such as imake. These have the pitfall that they
@@ -1287,7 +1327,7 @@ AC_TRY_LINK([#include <stdio.h>],[printf("Hello world");],,
if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
CF_VERBOSE(but keeping change to \$CPPFLAGS)
fi
- CFLAGS="$cf_check_flags"])
+ CFLAGS="$cf_check_cflags"])
fi
])dnl
dnl ---------------------------------------------------------------------------
@@ -1312,7 +1352,7 @@ else
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CLANG_COMPILER version: 2 updated: 2013/11/19 19:23:35
+dnl CF_CLANG_COMPILER version: 8 updated: 2021/01/01 13:31:04
dnl -----------------
dnl Check if the given compiler is really clang. clang's C driver defines
dnl __GNUC__ (fooling the configure script into setting $GCC to yes) but does
@@ -1331,21 +1371,116 @@ ifelse([$2],,CLANG_COMPILER,[$2])=no
if test "$ifelse([$1],,[$1],GCC)" = yes ; then
AC_MSG_CHECKING(if this is really Clang ifelse([$1],GXX,C++,C) compiler)
cf_save_CFLAGS="$ifelse([$3],,CFLAGS,[$3])"
- ifelse([$3],,CFLAGS,[$3])="$ifelse([$3],,CFLAGS,[$3]) -Qunused-arguments"
AC_TRY_COMPILE([],[
#ifdef __clang__
#else
make an error
#endif
],[ifelse([$2],,CLANG_COMPILER,[$2])=yes
-cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
],[])
ifelse([$3],,CFLAGS,[$3])="$cf_save_CFLAGS"
AC_MSG_RESULT($ifelse([$2],,CLANG_COMPILER,[$2]))
fi
+
+CLANG_VERSION=none
+
+if test "x$ifelse([$2],,CLANG_COMPILER,[$2])" = "xyes" ; then
+ case "$CC" in
+ (c[[1-9]][[0-9]]|*/c[[1-9]][[0-9]])
+ AC_MSG_WARN(replacing broken compiler alias $CC)
+ CFLAGS="$CFLAGS -std=`echo "$CC" | sed -e 's%.*/%%'`"
+ CC=clang
+ ;;
+ esac
+
+ AC_MSG_CHECKING(version of $CC)
+ CLANG_VERSION="`$CC --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(CLANG[[^)]]*) //' -e 's/^.*(Debian[[^)]]*) //' -e 's/^[[^0-9.]]*//' -e 's/[[^0-9.]].*//'`"
+ test -z "$CLANG_VERSION" && CLANG_VERSION=unknown
+ AC_MSG_RESULT($CLANG_VERSION)
+
+ for cf_clang_opt in \
+ -Qunused-arguments \
+ -Wno-error=implicit-function-declaration
+ do
+ AC_MSG_CHECKING(if option $cf_clang_opt works)
+ cf_save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS $cf_clang_opt"
+ AC_TRY_LINK([
+ #include <stdio.h>],[
+ printf("hello!\\n");],[
+ cf_clang_optok=yes],[
+ cf_clang_optok=no])
+ AC_MSG_RESULT($cf_clang_optok)
+ CFLAGS="$cf_save_CFLAGS"
+ if test "$cf_clang_optok" = yes; then
+ CF_VERBOSE(adding option $cf_clang_opt)
+ CF_APPEND_TEXT(CFLAGS,$cf_clang_opt)
+ fi
+ done
+fi
+])
+dnl ---------------------------------------------------------------------------
+dnl CF_CONST_X_STRING version: 6 updated: 2021/01/01 13:31:04
+dnl -----------------
+dnl The X11R4-X11R6 Xt specification uses an ambiguous String type for most
+dnl character-strings.
+dnl
+dnl It is ambiguous because the specification accommodated the pre-ANSI
+dnl compilers bundled by more than one vendor in lieu of providing a standard C
+dnl compiler other than by costly add-ons. Because of this, the specification
+dnl did not take into account the use of const for telling the compiler that
+dnl string literals would be in readonly memory.
+dnl
+dnl As a workaround, one could (starting with X11R5) define XTSTRINGDEFINES, to
+dnl let the compiler decide how to represent Xt's strings which were #define'd.
+dnl That does not solve the problem of using the block of Xt's strings which
+dnl are compiled into the library (and is less efficient than one might want).
+dnl
+dnl Xt specification 7 introduces the _CONST_X_STRING symbol which is used both
+dnl when compiling the library and compiling using the library, to tell the
+dnl compiler that String is const.
+AC_DEFUN([CF_CONST_X_STRING],
+[
+AC_REQUIRE([AC_PATH_XTRA])
+
+CF_SAVE_XTRA_FLAGS([CF_CONST_X_STRING])
+
+AC_TRY_COMPILE(
+[
+#include <stdlib.h>
+#include <X11/Intrinsic.h>
+],
+[String foo = malloc(1); (void)foo],[
+
+AC_CACHE_CHECK(for X11/Xt const-feature,cf_cv_const_x_string,[
+ AC_TRY_COMPILE(
+ [
+#define _CONST_X_STRING /* X11R7.8 (perhaps) */
+#undef XTSTRINGDEFINES /* X11R5 and later */
+#include <stdlib.h>
+#include <X11/Intrinsic.h>
+ ],[String foo = malloc(1); *foo = 0],[
+ cf_cv_const_x_string=no
+ ],[
+ cf_cv_const_x_string=yes
+ ])
])
+
+CF_RESTORE_XTRA_FLAGS([CF_CONST_X_STRING])
+
+case "$cf_cv_const_x_string" in
+(no)
+ CF_APPEND_TEXT(CPPFLAGS,-DXTSTRINGDEFINES)
+ ;;
+(*)
+ CF_APPEND_TEXT(CPPFLAGS,-D_CONST_X_STRING)
+ ;;
+esac
+
+])
+])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_CHTYPE version: 8 updated: 2012/10/06 08:57:51
+dnl CF_CURSES_CHTYPE version: 11 updated: 2021/01/02 09:31:20
dnl ----------------
dnl Test if curses defines 'chtype' (usually a 'long' type for SysV curses).
AC_DEFUN([CF_CURSES_CHTYPE],
@@ -1353,17 +1488,17 @@ AC_DEFUN([CF_CURSES_CHTYPE],
AC_REQUIRE([CF_CURSES_CPPFLAGS])dnl
AC_CACHE_CHECK(for chtype typedef,cf_cv_chtype_decl,[
AC_TRY_COMPILE([#include <${cf_cv_ncurses_header:-curses.h}>],
- [chtype foo],
+ [chtype foo; (void)foo],
[cf_cv_chtype_decl=yes],
[cf_cv_chtype_decl=no])])
-if test $cf_cv_chtype_decl = yes ; then
+if test "$cf_cv_chtype_decl" = yes ; then
AC_DEFINE(HAVE_TYPE_CHTYPE,1,[Define to 1 if chtype is declared])
AC_CACHE_CHECK(if chtype is scalar or struct,cf_cv_chtype_type,[
AC_TRY_COMPILE([#include <${cf_cv_ncurses_header:-curses.h}>],
- [chtype foo; long x = foo],
+ [static chtype foo; long x = foo; (void)x],
[cf_cv_chtype_type=scalar],
[cf_cv_chtype_type=struct])])
- if test $cf_cv_chtype_type = scalar ; then
+ if test "$cf_cv_chtype_type" = scalar ; then
AC_DEFINE(TYPE_CHTYPE_IS_SCALAR,1,[Define to 1 if chtype is a scaler/integer])
fi
fi
@@ -1381,14 +1516,14 @@ CF_NCURSES_VERSION
CF_CURSES_LIBS
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_CPPFLAGS version: 13 updated: 2018/06/20 20:23:13
+dnl CF_CURSES_CPPFLAGS version: 14 updated: 2021/01/02 09:31:20
dnl ------------------
dnl Look for the curses headers.
AC_DEFUN([CF_CURSES_CPPFLAGS],[
AC_CACHE_CHECK(for extra include directories,cf_cv_curses_incdir,[
cf_cv_curses_incdir=no
-case $host_os in
+case "$host_os" in
(hpux10.*)
if test "x$cf_cv_screen" = "xcurses_colr"
then
@@ -1415,7 +1550,20 @@ CF_CURSES_HEADER
CF_TERM_HEADER
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_FUNCS version: 19 updated: 2018/01/03 04:47:33
+dnl CF_CURSES_EXIT version: 1 updated: 2020/03/26 19:15:16
+dnl --------------
+dnl Check for ncurses memory-leak/debug feature. Starting with ncurses 6.2,
+dnl the curses_exit() function is always present, simplifying linkage changes
+dnl when switching to/from a debug-library.
+AC_DEFUN([CF_CURSES_EXIT],
+[
+CF_CURSES_FUNCS(\
+curses_exit \
+_nc_free_and_exit \
+)
+])dnl
+dnl ---------------------------------------------------------------------------
+dnl CF_CURSES_FUNCS version: 20 updated: 2020/12/31 20:19:42
dnl ---------------
dnl Curses-functions are a little complicated, since a lot of them are macros.
AC_DEFUN([CF_CURSES_FUNCS],
@@ -1436,7 +1584,7 @@ do
[
#ifndef ${cf_func}
long foo = (long)(&${cf_func});
-fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
+fprintf(stderr, "testing linkage of $cf_func:%p\\n", (void *)foo);
if (foo + 1234L > 5678L)
${cf_cv_main_return:-return}(foo != 0);
#endif
@@ -1444,12 +1592,12 @@ if (foo + 1234L > 5678L)
[cf_result=yes],
[cf_result=no])
fi
- eval 'cf_cv_func_'$cf_func'=$cf_result'
+ eval 'cf_cv_func_'$cf_func'="$cf_result"'
])
# use the computed/retrieved cache-value:
eval 'cf_result=$cf_cv_func_'$cf_func
AC_MSG_RESULT($cf_result)
- if test $cf_result != no; then
+ if test "$cf_result" != no; then
AC_DEFINE_UNQUOTED(HAVE_${cf_tr_func})
fi
done
@@ -1482,7 +1630,7 @@ fi
AC_CHECK_HEADERS($cf_cv_ncurses_header)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_LIBS version: 42 updated: 2018/06/20 20:23:13
+dnl CF_CURSES_LIBS version: 44 updated: 2021/01/02 09:31:20
dnl --------------
dnl Look for the curses libraries. Older curses implementations may require
dnl termcap/termlib to be linked as well. Call CF_CURSES_CPPFLAGS first.
@@ -1497,7 +1645,7 @@ AC_TRY_LINK([#include <${cf_cv_ncurses_header:-curses.h}>],
AC_MSG_RESULT($cf_result)
if test "$cf_result" = no ; then
-case $host_os in
+case "$host_os" in
(freebsd*)
AC_CHECK_LIB(mytinfo,tgoto,[CF_ADD_LIBS(-lmytinfo)])
;;
@@ -1565,7 +1713,7 @@ if test ".$ac_cv_func_initscr" != .yes ; then
for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
do
AC_CHECK_LIB($cf_term_lib,tgoto,[
- : ${cf_nculib_root:=$cf_term_lib}
+ : "${cf_nculib_root:=$cf_term_lib}"
break
])
done
@@ -1586,7 +1734,7 @@ if test ".$ac_cv_func_initscr" != .yes ; then
[cf_result=yes],
[cf_result=no])
AC_MSG_RESULT($cf_result)
- test $cf_result = yes && break
+ test "$cf_result" = yes && break
elif test "$cf_curs_lib" = "$cf_term_lib" ; then
cf_result=no
elif test "$cf_term_lib" != predefined ; then
@@ -1602,17 +1750,17 @@ if test ".$ac_cv_func_initscr" != .yes ; then
[cf_result=error])
])
AC_MSG_RESULT($cf_result)
- test $cf_result != error && break
+ test "$cf_result" != error && break
fi
done
fi
- test $cf_curs_lib = unknown && AC_MSG_ERROR(no curses library found)
+ test "$cf_curs_lib" = unknown && AC_MSG_ERROR(no curses library found)
fi
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_TERM_H version: 11 updated: 2015/04/15 19:08:48
+dnl CF_CURSES_TERM_H version: 15 updated: 2021/01/02 09:31:20
dnl ----------------
dnl SVr4 curses should have term.h as well (where it puts the definitions of
dnl the low-level interface). This may not be true in old/broken implementations,
@@ -1629,9 +1777,9 @@ AC_CACHE_CHECK(for term.h, cf_cv_term_header,[
cf_header_list="term.h ncurses/term.h ncursesw/term.h"
-case ${cf_cv_ncurses_header:-curses.h} in
+case "${cf_cv_ncurses_header:-curses.h}" in
(*/*)
- cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
+ cf_header_item=`echo "${cf_cv_ncurses_header:-curses.h}" | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
cf_header_list="$cf_header_item $cf_header_list"
;;
esac
@@ -1641,13 +1789,13 @@ do
AC_TRY_COMPILE([
#include <${cf_cv_ncurses_header:-curses.h}>
#include <${cf_header}>],
- [WINDOW *x],
+ [WINDOW *x; (void)x],
[cf_cv_term_header=$cf_header
break],
[cf_cv_term_header=no])
done
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(no)
# If curses is ncurses, some packagers still mess it up by trying to make
# us use GNU termcap. This handles the most common case.
@@ -1660,7 +1808,7 @@ case $cf_cv_term_header in
#else
make an error
#endif],
- [WINDOW *x],
+ [WINDOW *x; (void)x],
[cf_cv_term_header=$cf_header
break],
[cf_cv_term_header=no])
@@ -1669,7 +1817,7 @@ make an error
esac
])
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(term.h)
AC_DEFINE(HAVE_TERM_H,1,[Define to 1 if we have term.h])
;;
@@ -1682,7 +1830,7 @@ case $cf_cv_term_header in
esac
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_UNCTRL_H version: 4 updated: 2015/04/15 19:08:48
+dnl CF_CURSES_UNCTRL_H version: 8 updated: 2021/01/02 09:31:20
dnl ------------------
dnl Any X/Open curses implementation must have unctrl.h, but ncurses packages
dnl may put it in a subdirectory (along with ncurses' other headers, of
@@ -1699,9 +1847,9 @@ AC_CACHE_CHECK(for unctrl.h, cf_cv_unctrl_header,[
cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
-case ${cf_cv_ncurses_header:-curses.h} in
+case "${cf_cv_ncurses_header:-curses.h}" in
(*/*)
- cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
+ cf_header_item=`echo "${cf_cv_ncurses_header:-curses.h}" | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
cf_header_list="$cf_header_item $cf_header_list"
;;
esac
@@ -1711,20 +1859,20 @@ do
AC_TRY_COMPILE([
#include <${cf_cv_ncurses_header:-curses.h}>
#include <${cf_header}>],
- [WINDOW *x],
+ [WINDOW *x; (void)x],
[cf_cv_unctrl_header=$cf_header
break],
[cf_cv_unctrl_header=no])
done
])
-case $cf_cv_unctrl_header in
+case "$cf_cv_unctrl_header" in
(no)
AC_MSG_WARN(unctrl.h header not found)
;;
esac
-case $cf_cv_unctrl_header in
+case "$cf_cv_unctrl_header" in
(unctrl.h)
AC_DEFINE(HAVE_UNCTRL_H,1,[Define to 1 if we have unctrl.h])
;;
@@ -1737,7 +1885,7 @@ case $cf_cv_unctrl_header in
esac
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_WACS_MAP version: 6 updated: 2012/10/06 08:57:51
+dnl CF_CURSES_WACS_MAP version: 8 updated: 2021/01/04 19:45:09
dnl ------------------
dnl Check for likely values of wacs_map[].
AC_DEFUN([CF_CURSES_WACS_MAP],
@@ -1751,7 +1899,7 @@ AC_CACHE_CHECK(for wide alternate character set array, cf_cv_curses_wacs_map,[
#define _XOPEN_SOURCE_EXTENDED
#endif
#include <${cf_cv_ncurses_header:-curses.h}>],
- [void *foo = &($name['k'])],
+ [void *foo = &(${name}['k']); (void)foo],
[cf_cv_curses_wacs_map=$name
break])
done])
@@ -1759,7 +1907,7 @@ AC_CACHE_CHECK(for wide alternate character set array, cf_cv_curses_wacs_map,[
test "$cf_cv_curses_wacs_map" != unknown && AC_DEFINE_UNQUOTED(CURSES_WACS_ARRAY,$cf_cv_curses_wacs_map,[Define to name of (n)curses wide-character array])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_WACS_SYMBOLS version: 2 updated: 2012/10/06 08:57:51
+dnl CF_CURSES_WACS_SYMBOLS version: 4 updated: 2021/01/04 19:45:09
dnl ----------------------
dnl Do a check to see if the WACS_xxx constants are defined compatibly with
dnl X/Open Curses. In particular, NetBSD's implementation of the WACS_xxx
@@ -1778,7 +1926,7 @@ then
#endif
#include <${cf_cv_ncurses_header:-curses.h}>],
[cchar_t *foo = WACS_PLUS;
- $cf_cv_curses_wacs_map['k'] = *WACS_PLUS],
+ ${cf_cv_curses_wacs_map}['k'] = *WACS_PLUS; (void)foo],
[cf_cv_curses_wacs_symbols=yes])
else
AC_TRY_LINK([
@@ -1786,7 +1934,7 @@ else
#define _XOPEN_SOURCE_EXTENDED
#endif
#include <${cf_cv_ncurses_header:-curses.h}>],
- [cchar_t *foo = WACS_PLUS],
+ [cchar_t *foo = WACS_PLUS; (void)foo],
[cf_cv_curses_wacs_symbols=yes])
fi
])
@@ -1794,7 +1942,7 @@ fi
test "$cf_cv_curses_wacs_symbols" != no && AC_DEFINE(CURSES_WACS_SYMBOLS,1,[Define to 1 if (n)curses supports wide-character WACS_ symbols])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_CURSES_WGETPARENT version: 3 updated: 2012/10/06 08:57:51
+dnl CF_CURSES_WGETPARENT version: 4 updated: 2020/03/19 20:23:48
dnl --------------------
dnl Check for curses support for directly determining the parent of a given
dnl window. Some implementations make this difficult, so we provide for
@@ -1807,7 +1955,7 @@ if test "x$cf_cv_func_wgetparent" != xyes
then
AC_MSG_CHECKING(if WINDOW has _parent member)
AC_TRY_COMPILE([#include <${cf_cv_ncurses_header:-curses.h}>],
- [WINDOW *p = stdscr->_parent],
+ [WINDOW *p = stdscr->_parent; (void)p],
[cf_window__parent=yes],
[cf_window__parent=no])
AC_MSG_RESULT($cf_window__parent)
@@ -1818,10 +1966,10 @@ then
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_DIRNAME version: 4 updated: 2002/12/21 19:25:52
+dnl CF_DIRNAME version: 5 updated: 2020/12/31 20:19:42
dnl ----------
dnl "dirname" is not portable, so we fake it with a shell script.
-AC_DEFUN([CF_DIRNAME],[$1=`echo $2 | sed -e 's%/[[^/]]*$%%'`])dnl
+AC_DEFUN([CF_DIRNAME],[$1=`echo "$2" | sed -e 's%/[[^/]]*$%%'`])dnl
dnl ---------------------------------------------------------------------------
dnl CF_DISABLE_ECHO version: 13 updated: 2015/04/18 08:56:57
dnl ---------------
@@ -1901,7 +2049,7 @@ AC_SUBST(ABI_VERSION)
AC_SUBST(LIBTOOL_VERSION)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_DISABLE_RPATH_HACK version: 2 updated: 2011/02/13 13:31:33
+dnl CF_DISABLE_RPATH_HACK version: 3 updated: 2021/01/05 20:14:44
dnl ---------------------
dnl The rpath-hack makes it simpler to build programs, particularly with the
dnl *BSD ports which may have essential libraries in unusual places. But it
@@ -1912,10 +2060,13 @@ AC_DEFUN([CF_DISABLE_RPATH_HACK],
AC_MSG_CHECKING(if rpath-hack should be disabled)
CF_ARG_DISABLE(rpath-hack,
[ --disable-rpath-hack don't add rpath options for additional libraries],
- [cf_disable_rpath_hack=yes],
- [cf_disable_rpath_hack=no])
+ [enable_rpath_hack=no],
+ [enable_rpath_hack=yes])
+dnl TODO - drop cf_disable_rpath_hack
+if test "x$enable_rpath_hack" = xno; then cf_disable_rpath_hack=yes; else cf_disable_rpath_hack=no; fi
AC_MSG_RESULT($cf_disable_rpath_hack)
-if test "$cf_disable_rpath_hack" = no ; then
+
+if test "$enable_rpath_hack" = yes ; then
CF_RPATH_HACK
fi
])
@@ -1934,7 +2085,37 @@ AC_ARG_ENABLE(rpath,
AC_MSG_RESULT($cf_cv_enable_rpath)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_FIND_LIBRARY version: 9 updated: 2008/03/23 14:48:54
+dnl CF_ENABLE_WARNINGS version: 9 updated: 2021/01/05 19:40:50
+dnl ------------------
+dnl Configure-option to enable gcc warnings
+dnl
+dnl $1 = extra options to add, if supported
+dnl $2 = option for checking attributes. By default, this is done when
+dnl warnings are enabled. For other values:
+dnl yes: always do this, e.g., to use in generated library-headers
+dnl no: never do this
+AC_DEFUN([CF_ENABLE_WARNINGS],[
+if test "$GCC" = yes || test "$GXX" = yes
+then
+CF_FIX_WARNINGS(CFLAGS)
+CF_FIX_WARNINGS(CPPFLAGS)
+CF_FIX_WARNINGS(LDFLAGS)
+AC_MSG_CHECKING(if you want to turn on gcc warnings)
+CF_ARG_ENABLE(warnings,
+ [ --enable-warnings test: turn on gcc compiler warnings],
+ [enable_warnings=yes],
+ [enable_warnings=no])
+AC_MSG_RESULT($enable_warnings)
+if test "$enable_warnings" = "yes"
+then
+ ifelse($2,,[CF_GCC_ATTRIBUTES])
+ CF_GCC_WARNINGS($1)
+fi
+ifelse($2,yes,[CF_GCC_ATTRIBUTES])
+fi
+])dnl
+dnl ---------------------------------------------------------------------------
+dnl CF_FIND_LIBRARY version: 11 updated: 2021/01/02 09:31:20
dnl ---------------
dnl Look for a non-standard library, given parameters for AC_TRY_LINK. We
dnl prefer a standard location, and use -L options only if we do not find the
@@ -1950,16 +2131,16 @@ dnl Sets the variable "$cf_libdir" as a side-effect, so we can see if we had
dnl to use a -L option.
AC_DEFUN([CF_FIND_LIBRARY],
[
- eval 'cf_cv_have_lib_'$1'=no'
+ eval 'cf_cv_have_lib_'"$1"'=no'
cf_libdir=""
AC_CHECK_FUNC($5,
- eval 'cf_cv_have_lib_'$1'=yes',[
+ eval 'cf_cv_have_lib_'"$1"'=yes',[
cf_save_LIBS="$LIBS"
AC_MSG_CHECKING(for $5 in -l$1)
LIBS="-l$1 $LIBS"
AC_TRY_LINK([$3],[$4],
[AC_MSG_RESULT(yes)
- eval 'cf_cv_have_lib_'$1'=yes'
+ eval 'cf_cv_have_lib_'"$1"'=yes'
],
[AC_MSG_RESULT(no)
CF_LIBRARY_PATH(cf_search,$2)
@@ -1969,22 +2150,22 @@ AC_DEFUN([CF_FIND_LIBRARY],
LIBS="-L$cf_libdir -l$1 $cf_save_LIBS"
AC_TRY_LINK([$3],[$4],
[AC_MSG_RESULT(yes)
- eval 'cf_cv_have_lib_'$1'=yes'
+ eval 'cf_cv_have_lib_'"$1"'=yes'
break],
[AC_MSG_RESULT(no)
LIBS="$cf_save_LIBS"])
done
])
])
-eval 'cf_found_library=[$]cf_cv_have_lib_'$1
+eval 'cf_found_library="[$]cf_cv_have_lib_'"$1"\"
ifelse($6,,[
-if test $cf_found_library = no ; then
+if test "$cf_found_library" = no ; then
AC_MSG_ERROR(Cannot link $1 library)
fi
])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_FIND_LINKAGE version: 21 updated: 2018/06/20 20:23:13
+dnl CF_FIND_LINKAGE version: 22 updated: 2020/12/31 20:19:42
dnl ---------------
dnl Find a library (specifically the linkage used in the code fragment),
dnl searching for it if it is not already in the library path.
@@ -2041,7 +2222,7 @@ AC_TRY_LINK([$1],[$2],[
CF_HEADER_PATH(cf_search,ifelse([$6],,[$3],[$6]))
for cf_cv_header_path_$3 in $cf_search
do
- if test -d $cf_cv_header_path_$3 ; then
+ if test -d "$cf_cv_header_path_$3" ; then
CF_VERBOSE(... testing $cf_cv_header_path_$3)
CPPFLAGS="$cf_save_CPPFLAGS"
CF_APPEND_TEXT(CPPFLAGS,-I$cf_cv_header_path_$3)
@@ -2076,7 +2257,7 @@ AC_TRY_LINK([$1],[$2],[
CF_LIBRARY_PATH(cf_search,$3)
for cf_cv_library_path_$3 in $cf_search
do
- if test -d $cf_cv_library_path_$3 ; then
+ if test -d "$cf_cv_library_path_$3" ; then
CF_VERBOSE(... testing $cf_cv_library_path_$3)
CPPFLAGS="$cf_test_CPPFLAGS"
LIBS="-l$3 $7 $cf_save_LIBS"
@@ -2115,6 +2296,40 @@ ifelse([$5],,AC_MSG_WARN(Cannot find $3 library),[$5])
fi
])dnl
dnl ---------------------------------------------------------------------------
+dnl CF_FIX_WARNINGS version: 3 updated: 2020/12/31 18:40:20
+dnl ---------------
+dnl Warning flags do not belong in CFLAGS, CPPFLAGS, etc. Any of gcc's
+dnl "-Werror" flags can interfere with configure-checks. Those go into
+dnl EXTRA_CFLAGS.
+dnl
+dnl $1 = variable name to repair
+define([CF_FIX_WARNINGS],[
+if test "$GCC" = yes || test "$GXX" = yes
+then
+ case [$]$1 in
+ (*-Werror=*)
+ CF_VERBOSE(repairing $1: [$]$1)
+ cf_temp_flags=
+ for cf_temp_scan in [$]$1
+ do
+ case "x$cf_temp_scan" in
+ (x-Werror=*)
+ CF_APPEND_TEXT(EXTRA_CFLAGS,$cf_temp_scan)
+ ;;
+ (*)
+ CF_APPEND_TEXT(cf_temp_flags,$cf_temp_scan)
+ ;;
+ esac
+ done
+ $1="$cf_temp_flags"
+ CF_VERBOSE(... fixed [$]$1)
+ CF_VERBOSE(... extra $EXTRA_CFLAGS)
+ ;;
+ esac
+fi
+AC_SUBST(EXTRA_CFLAGS)
+])dnl
+dnl ---------------------------------------------------------------------------
dnl CF_FORGET_TOOL version: 1 updated: 2013/04/06 18:03:09
dnl --------------
dnl Forget that we saw the given tool.
@@ -2124,7 +2339,7 @@ unset ac_ct_$1
unset $1
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_FUNC_WAIT version: 3 updated: 2012/10/06 08:57:51
+dnl CF_FUNC_WAIT version: 4 updated: 2021/01/02 09:31:20
dnl ------------
dnl Test for the presence of <sys/wait.h>, 'union wait', arg-type of 'wait()'
dnl and/or 'waitpid()'.
@@ -2139,7 +2354,7 @@ dnl
AC_DEFUN([CF_FUNC_WAIT],
[
AC_REQUIRE([CF_UNION_WAIT])
-if test $cf_cv_type_unionwait = yes; then
+if test "$cf_cv_type_unionwait" = yes; then
AC_MSG_CHECKING(if union wait can be used as wait-arg)
AC_CACHE_VAL(cf_cv_arg_union_wait,[
@@ -2149,7 +2364,7 @@ if test $cf_cv_type_unionwait = yes; then
[cf_cv_arg_union_wait=no])
])
AC_MSG_RESULT($cf_cv_arg_union_wait)
- test $cf_cv_arg_union_wait = yes && AC_DEFINE(WAIT_USES_UNION,1,[Define to 1 if wait() uses a union parameter])
+ test "$cf_cv_arg_union_wait" = yes && AC_DEFINE(WAIT_USES_UNION,1,[Define to 1 if wait() uses a union parameter])
AC_MSG_CHECKING(if union wait can be used as waitpid-arg)
AC_CACHE_VAL(cf_cv_arg_union_waitpid,[
@@ -2159,19 +2374,20 @@ if test $cf_cv_type_unionwait = yes; then
[cf_cv_arg_union_waitpid=no])
])
AC_MSG_RESULT($cf_cv_arg_union_waitpid)
- test $cf_cv_arg_union_waitpid = yes && AC_DEFINE(WAITPID_USES_UNION,1,[Define to 1 if waitpid() uses a union parameter])
+ test "$cf_cv_arg_union_waitpid" = yes && AC_DEFINE(WAITPID_USES_UNION,1,[Define to 1 if waitpid() uses a union parameter])
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_GCC_ATTRIBUTES version: 17 updated: 2015/04/12 15:39:00
+dnl CF_GCC_ATTRIBUTES version: 23 updated: 2021/01/03 18:30:50
dnl -----------------
dnl Test for availability of useful gcc __attribute__ directives to quiet
dnl compiler warnings. Though useful, not all are supported -- and contrary
dnl to documentation, unrecognized directives cause older compilers to barf.
AC_DEFUN([CF_GCC_ATTRIBUTES],
-[
-if test "$GCC" = yes
+[AC_REQUIRE([AC_PROG_FGREP])dnl
+
+if test "$GCC" = yes || test "$GXX" = yes
then
cat > conftest.i <<EOF
#ifndef GCC_PRINTF
@@ -2190,7 +2406,7 @@ EOF
if test "$GCC" = yes
then
AC_CHECKING([for $CC __attribute__ directives])
-cat > conftest.$ac_ext <<EOF
+cat > "conftest.$ac_ext" <<EOF
#line __oline__ "${as_me:-configure}"
#include "confdefs.h"
#include "conftest.h"
@@ -2208,7 +2424,7 @@ cat > conftest.$ac_ext <<EOF
extern void wow(char *,...) GCC_SCANFLIKE(1,2);
extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
extern void foo(void) GCC_NORETURN;
-int main(int argc GCC_UNUSED, char *argv[[]] GCC_UNUSED) { return 0; }
+int main(int argc GCC_UNUSED, char *argv[[]] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
EOF
cf_printf_attribute=no
cf_scanf_attribute=no
@@ -2218,7 +2434,7 @@ EOF
cf_directive="__attribute__(($cf_attribute))"
echo "checking for $CC $cf_directive" 1>&AC_FD_CC
- case $cf_attribute in
+ case "$cf_attribute" in
(printf)
cf_printf_attribute=yes
cat >conftest.h <<EOF
@@ -2241,7 +2457,7 @@ EOF
if AC_TRY_EVAL(ac_compile); then
test -n "$verbose" && AC_MSG_RESULT(... $cf_attribute)
cat conftest.h >>confdefs.h
- case $cf_attribute in
+ case "$cf_attribute" in
(noreturn)
AC_DEFINE_UNQUOTED(GCC_NORETURN,$cf_directive,[Define to noreturn-attribute for gcc])
;;
@@ -2268,15 +2484,16 @@ EOF
fi
done
else
- fgrep define conftest.i >>confdefs.h
+ ${FGREP-fgrep} define conftest.i >>confdefs.h
fi
-rm -rf conftest*
+rm -rf ./conftest*
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_GCC_VERSION version: 7 updated: 2012/10/18 06:46:33
+dnl CF_GCC_VERSION version: 8 updated: 2019/09/07 13:38:36
dnl --------------
-dnl Find version of gcc
+dnl Find version of gcc, and (because icc/clang pretend to be gcc without being
+dnl compatible), attempt to determine if icc/clang is actually used.
AC_DEFUN([CF_GCC_VERSION],[
AC_REQUIRE([AC_PROG_CC])
GCC_VERSION=none
@@ -2286,14 +2503,17 @@ if test "$GCC" = yes ; then
test -z "$GCC_VERSION" && GCC_VERSION=unknown
AC_MSG_RESULT($GCC_VERSION)
fi
+CF_INTEL_COMPILER(GCC,INTEL_COMPILER,CFLAGS)
+CF_CLANG_COMPILER(GCC,CLANG_COMPILER,CFLAGS)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_GCC_WARNINGS version: 33 updated: 2018/06/20 20:23:13
+dnl CF_GCC_WARNINGS version: 41 updated: 2021/01/01 16:53:59
dnl ---------------
dnl Check if the compiler supports useful warning options. There's a few that
dnl we don't use, simply because they're too noisy:
dnl
dnl -Wconversion (useful in older versions of gcc, but not in gcc 2.7.x)
+dnl -Winline (usually not worthwhile)
dnl -Wredundant-decls (system headers make this too noisy)
dnl -Wtraditional (combines too many unrelated messages, only a few useful)
dnl -Wwrite-strings (too noisy, but should review occasionally). This
@@ -2310,14 +2530,11 @@ dnl
AC_DEFUN([CF_GCC_WARNINGS],
[
AC_REQUIRE([CF_GCC_VERSION])
-CF_INTEL_COMPILER(GCC,INTEL_COMPILER,CFLAGS)
-CF_CLANG_COMPILER(GCC,CLANG_COMPILER,CFLAGS)
-
-cat > conftest.$ac_ext <<EOF
+if test "x$have_x" = xyes; then CF_CONST_X_STRING fi
+cat > "conftest.$ac_ext" <<EOF
#line __oline__ "${as_me:-configure}"
int main(int argc, char *argv[[]]) { return (argv[[argc-1]] == 0) ; }
EOF
-
if test "$INTEL_COMPILER" = yes
then
# The "-wdXXX" options suppress warnings:
@@ -2333,7 +2550,7 @@ then
AC_CHECKING([for $CC warning options])
cf_save_CFLAGS="$CFLAGS"
- EXTRA_CFLAGS="-Wall"
+ EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
for cf_opt in \
wd1419 \
wd1683 \
@@ -2352,12 +2569,10 @@ then
fi
done
CFLAGS="$cf_save_CFLAGS"
-
-elif test "$GCC" = yes
+elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
then
AC_CHECKING([for $CC warning options])
cf_save_CFLAGS="$CFLAGS"
- EXTRA_CFLAGS=
cf_warn_CONST=""
test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
@@ -2375,24 +2590,21 @@ then
Wpointer-arith \
Wshadow \
Wstrict-prototypes \
- Wundef $cf_gcc_warnings $cf_warn_CONST $1
+ Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST $1
do
CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
if AC_TRY_EVAL(ac_compile); then
test -n "$verbose" && AC_MSG_RESULT(... -$cf_opt)
- case $cf_opt in
- (Wcast-qual)
- CF_APPEND_TEXT(CPPFLAGS,-DXTSTRINGDEFINES)
- ;;
+ case "$cf_opt" in
(Winline)
- case $GCC_VERSION in
+ case "$GCC_VERSION" in
([[34]].*)
CF_VERBOSE(feature is broken in gcc $GCC_VERSION)
continue;;
esac
;;
(Wpointer-arith)
- case $GCC_VERSION in
+ case "$GCC_VERSION" in
([[12]].*)
CF_VERBOSE(feature is broken in gcc $GCC_VERSION)
continue;;
@@ -2404,12 +2616,12 @@ then
done
CFLAGS="$cf_save_CFLAGS"
fi
-rm -rf conftest*
+rm -rf ./conftest*
AC_SUBST(EXTRA_CFLAGS)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_GNU_SOURCE version: 9 updated: 2018/06/20 20:23:13
+dnl CF_GNU_SOURCE version: 10 updated: 2018/12/10 20:09:41
dnl -------------
dnl Check if we must define _GNU_SOURCE to get a reasonable value for
dnl _XOPEN_SOURCE, upon which many POSIX definitions depend. This is a defect
@@ -2428,6 +2640,8 @@ AC_CACHE_CHECK(if this is the GNU C library,cf_cv_gnu_library,[
AC_TRY_COMPILE([#include <sys/types.h>],[
#if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
return 0;
+ #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
+ return 0;
#else
# error not GNU C library
#endif],
@@ -2438,13 +2652,16 @@ AC_TRY_COMPILE([#include <sys/types.h>],[
if test x$cf_cv_gnu_library = xyes; then
# With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
- # was changed to help a little...
+ # was changed to help a little. newlib incorporated the change about 4
+ # years later.
AC_CACHE_CHECK(if _DEFAULT_SOURCE can be used as a basis,cf_cv_gnu_library_219,[
cf_save="$CPPFLAGS"
CF_APPEND_TEXT(CPPFLAGS,-D_DEFAULT_SOURCE)
AC_TRY_COMPILE([#include <sys/types.h>],[
#if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
return 0;
+ #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
+ return 0;
#else
# error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
#endif],
@@ -2526,7 +2743,7 @@ AC_SUBST(PACKAGE_CONFIG)
EXTRA_OUTPUT="$EXTRA_OUTPUT headers-sh:$srcdir/headers-sh.in"
])
dnl ---------------------------------------------------------------------------
-dnl CF_HEADER_PATH version: 13 updated: 2015/04/15 19:08:48
+dnl CF_HEADER_PATH version: 15 updated: 2021/01/01 13:31:04
dnl --------------
dnl Construct a search-list of directories for a nonstandard header-file
dnl
@@ -2542,7 +2759,7 @@ cf_header_path_list=""
if test -n "${CFLAGS}${CPPFLAGS}" ; then
for cf_header_path in $CPPFLAGS $CFLAGS
do
- case $cf_header_path in
+ case "$cf_header_path" in
(-I*)
cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
CF_ADD_SUBDIR_PATH($1,$2,include,$cf_header_path,NONE)
@@ -2558,21 +2775,21 @@ CF_SUBDIR_PATH($1,$2,include)
test "$includedir" != NONE && \
test "$includedir" != "/usr/include" && \
test -d "$includedir" && {
- test -d $includedir && $1="[$]$1 $includedir"
- test -d $includedir/$2 && $1="[$]$1 $includedir/$2"
+ test -d "$includedir" && $1="[$]$1 $includedir"
+ test -d "$includedir/$2" && $1="[$]$1 $includedir/$2"
}
test "$oldincludedir" != NONE && \
test "$oldincludedir" != "/usr/include" && \
test -d "$oldincludedir" && {
- test -d $oldincludedir && $1="[$]$1 $oldincludedir"
- test -d $oldincludedir/$2 && $1="[$]$1 $oldincludedir/$2"
+ test -d "$oldincludedir" && $1="[$]$1 $oldincludedir"
+ test -d "$oldincludedir/$2" && $1="[$]$1 $oldincludedir/$2"
}
$1="[$]$1 $cf_header_path_list"
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_INTEL_COMPILER version: 7 updated: 2015/04/12 15:39:00
+dnl CF_INTEL_COMPILER version: 8 updated: 2021/01/01 16:53:59
dnl -----------------
dnl Check if the given compiler is really the Intel compiler for Linux. It
dnl tries to imitate gcc, but does not return an error when it finds a mismatch
@@ -2590,7 +2807,7 @@ AC_REQUIRE([AC_CANONICAL_HOST])
ifelse([$2],,INTEL_COMPILER,[$2])=no
if test "$ifelse([$1],,[$1],GCC)" = yes ; then
- case $host_os in
+ case "$host_os" in
(linux*|gnu*)
AC_MSG_CHECKING(if this is really Intel ifelse([$1],GXX,C++,C) compiler)
cf_save_CFLAGS="$ifelse([$3],,CFLAGS,[$3])"
@@ -2610,7 +2827,7 @@ cf_save_CFLAGS="$cf_save_CFLAGS -we147"
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_LARGEFILE version: 11 updated: 2018/06/20 20:23:13
+dnl CF_LARGEFILE version: 12 updated: 2020/03/19 20:23:48
dnl ------------
dnl Add checks for large file support.
AC_DEFUN([CF_LARGEFILE],[
@@ -2650,6 +2867,7 @@ ifdef([AC_FUNC_FSEEKO],[
struct dirent64 *x = readdir((DIR *)0);
struct dirent *y = readdir((DIR *)0);
int z = x - y;
+ (void)z;
],
[cf_cv_struct_dirent64=yes],
[cf_cv_struct_dirent64=no])
@@ -2659,7 +2877,7 @@ ifdef([AC_FUNC_FSEEKO],[
])
])
dnl ---------------------------------------------------------------------------
-dnl CF_LD_RPATH_OPT version: 7 updated: 2016/02/20 18:01:19
+dnl CF_LD_RPATH_OPT version: 9 updated: 2021/01/01 13:31:04
dnl ---------------
dnl For the given system and compiler, find the compiler flags to pass to the
dnl loader to use the "rpath" feature.
@@ -2668,52 +2886,125 @@ AC_DEFUN([CF_LD_RPATH_OPT],
AC_REQUIRE([CF_CHECK_CACHE])
LD_RPATH_OPT=
-AC_MSG_CHECKING(for an rpath option)
-case $cf_cv_system_name in
-(irix*)
- if test "$GCC" = yes; then
+if test "x$cf_cv_enable_rpath" != xno
+then
+ AC_MSG_CHECKING(for an rpath option)
+ case "$cf_cv_system_name" in
+ (irix*)
+ if test "$GCC" = yes; then
+ LD_RPATH_OPT="-Wl,-rpath,"
+ else
+ LD_RPATH_OPT="-rpath "
+ fi
+ ;;
+ (linux*|gnu*|k*bsd*-gnu|freebsd*)
LD_RPATH_OPT="-Wl,-rpath,"
- else
+ ;;
+ (openbsd[[2-9]].*|mirbsd*)
+ LD_RPATH_OPT="-Wl,-rpath,"
+ ;;
+ (dragonfly*)
+ LD_RPATH_OPT="-rpath "
+ ;;
+ (netbsd*)
+ LD_RPATH_OPT="-Wl,-rpath,"
+ ;;
+ (osf*|mls+*)
LD_RPATH_OPT="-rpath "
+ ;;
+ (solaris2*)
+ LD_RPATH_OPT="-R"
+ ;;
+ (*)
+ ;;
+ esac
+ AC_MSG_RESULT($LD_RPATH_OPT)
+
+ case "x$LD_RPATH_OPT" in
+ (x-R*)
+ AC_MSG_CHECKING(if we need a space after rpath option)
+ cf_save_LIBS="$LIBS"
+ CF_ADD_LIBS(${LD_RPATH_OPT}$libdir)
+ AC_TRY_LINK(, , cf_rpath_space=no, cf_rpath_space=yes)
+ LIBS="$cf_save_LIBS"
+ AC_MSG_RESULT($cf_rpath_space)
+ test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
+ ;;
+ esac
+fi
+])dnl
+dnl ---------------------------------------------------------------------------
+dnl CF_LD_SEARCHPATH version: 2 updated: 2019/09/26 20:34:14
+dnl ----------------
+dnl Try to obtain the linker's search-path, for use in scripts.
+dnl
+dnl Ignore LD_LIBRARY_PATH, etc.
+AC_DEFUN([CF_LD_SEARCHPATH],[
+AC_CACHE_CHECK(for linker search path,cf_cv_ld_searchpath,[
+
+if test "$cross_compiling" != yes ; then
+
+# GNU binutils' ld does not involve permissions which may stop ldconfig.
+cf_pathlist=`ld --verbose 2>/dev/null | grep SEARCH_DIR | sed -e 's,SEARCH_DIR[[("=]][[("=]]*,,g' -e 's/"[[)]];//gp' | sort -u`
+
+# The -NX options tell newer versions of Linux ldconfig to not attempt to
+# update the cache, which makes it run faster.
+test -z "$cf_pathlist" && \
+ cf_pathlist=`ldconfig -NX -v 2>/dev/null | sed -e '/^[[ ]]/d' -e 's/:$//' | sort -u`
+
+test -z "$cf_pathlist" &&
+ cf_pathlist=`ldconfig -v 2>/dev/null | sed -n -e '/^[[ ]]/d' -e 's/:$//p' | sort -u`
+
+# This works with OpenBSD 6.5, which lists only filenames
+test -z "$cf_pathlist" &&
+ cf_pathlist=`ldconfig -v 2>/dev/null | sed -n -e 's,^Adding \(.*\)/.*[$],\1,p' | sort -u`
+
+if test -z "$cf_pathlist"
+then
+ # dyld default path with MacOS
+ if test -f /usr/bin/otool && test "x`uname -s`" = xDarwin
+ then
+ # do this to bypass check
+ cf_cv_ld_searchpath='$HOME/lib'
+ cf_pathlist="/usr/local/lib /lib /usr/lib"
fi
- ;;
-(linux*|gnu*|k*bsd*-gnu|freebsd*)
- LD_RPATH_OPT="-Wl,-rpath,"
- ;;
-(openbsd[[2-9]].*|mirbsd*)
- LD_RPATH_OPT="-Wl,-rpath,"
- ;;
-(dragonfly*)
- LD_RPATH_OPT="-rpath "
- ;;
-(netbsd*)
- LD_RPATH_OPT="-Wl,-rpath,"
- ;;
-(osf*|mls+*)
- LD_RPATH_OPT="-rpath "
- ;;
-(solaris2*)
- LD_RPATH_OPT="-R"
- ;;
-(*)
- ;;
-esac
-AC_MSG_RESULT($LD_RPATH_OPT)
+fi
-case "x$LD_RPATH_OPT" in
-(x-R*)
- AC_MSG_CHECKING(if we need a space after rpath option)
- cf_save_LIBS="$LIBS"
- CF_ADD_LIBS(${LD_RPATH_OPT}$libdir)
- AC_TRY_LINK(, , cf_rpath_space=no, cf_rpath_space=yes)
- LIBS="$cf_save_LIBS"
- AC_MSG_RESULT($cf_rpath_space)
- test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
- ;;
-esac
+if test -z "$cf_pathlist"
+then
+ # Solaris is hardcoded
+ if test -d /opt/SUNWspro/lib
+ then
+ cf_pathlist="/opt/SUNWspro/lib /usr/ccs/lib /usr/lib"
+ elif test -d /usr/ccs/lib
+ then
+ cf_pathlist="/usr/ccs/lib /usr/lib"
+ fi
+fi
+
+fi
+
+# If nothing else, assume it is conventional
+test -z "$cf_pathlist" && cf_pathlist="/usr/lib /lib"
+
+# Finally, check that this is only directories
+for cf_path in [$]0 $cf_pathlist
+do
+ if test -d "$cf_path"; then
+ test -n "$cf_cv_ld_searchpath" && cf_cv_ld_searchpath="${cf_cv_ld_searchpath} "
+ cf_cv_ld_searchpath="${cf_cv_ld_searchpath}${cf_path}"
+ fi
+done
+
+# Ensure that it is nonempty
+test -z "$cf_cv_ld_searchpath" && cf_cv_ld_searchpath=/usr/lib
+])
+
+LD_SEARCHPATH=`echo "$cf_cv_ld_searchpath"|sed -e 's/ /|/g'`
+AC_SUBST(LD_SEARCHPATH)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_LIBRARY_PATH version: 10 updated: 2015/04/15 19:08:48
+dnl CF_LIBRARY_PATH version: 11 updated: 2021/01/01 13:31:04
dnl ---------------
dnl Construct a search-list of directories for a nonstandard library-file
dnl
@@ -2727,7 +3018,7 @@ cf_library_path_list=""
if test -n "${LDFLAGS}${LIBS}" ; then
for cf_library_path in $LDFLAGS $LIBS
do
- case $cf_library_path in
+ case "$cf_library_path" in
(-L*)
cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
CF_ADD_SUBDIR_PATH($1,$2,lib,$cf_library_path,NONE)
@@ -2754,13 +3045,13 @@ fi
test -z "$cf_cv_libtool_version" && unset cf_cv_libtool_version
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_LIB_PREFIX version: 12 updated: 2015/10/17 19:03:33
+dnl CF_LIB_PREFIX version: 14 updated: 2021/01/01 13:31:04
dnl -------------
dnl Compute the library-prefix for the given host system
dnl $1 = variable to set
define([CF_LIB_PREFIX],
[
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(OS/2*|os2*)
if test "$DFT_LWR_MODEL" = libtool; then
LIB_PREFIX='lib'
@@ -2768,6 +3059,9 @@ define([CF_LIB_PREFIX],
LIB_PREFIX=''
fi
;;
+ (*-msvc*)
+ LIB_PREFIX=''
+ ;;
(*) LIB_PREFIX='lib'
;;
esac
@@ -2775,7 +3069,7 @@ ifelse($1,,,[$1=$LIB_PREFIX])
AC_SUBST(LIB_PREFIX)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_LIB_SUFFIX version: 25 updated: 2015/04/17 21:13:04
+dnl CF_LIB_SUFFIX version: 28 updated: 2021/01/01 16:53:59
dnl -------------
dnl Compute the library file-suffix from the given model name
dnl $1 = model name
@@ -2790,19 +3084,37 @@ AC_DEFUN([CF_LIB_SUFFIX],
$3=[$]$2
;;
(Xdebug)
- $2='_g.a'
+ case "$cf_cv_system_name" in
+ (*-msvc*)
+ $2='_g.lib'
+ ;;
+ (*)
+ $2='_g.a'
+ ;;
+ esac
$3=[$]$2
;;
(Xprofile)
- $2='_p.a'
+ case "$cf_cv_system_name" in
+ (*-msvc*)
+ $2='_p.lib'
+ ;;
+ (*)
+ $2='_p.a'
+ ;;
+ esac
$3=[$]$2
;;
(Xshared)
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(aix[[5-7]]*)
$2='.so'
$3=[$]$2
;;
+ (*-msvc*)
+ $2='.dll'
+ $3='.dll.lib'
+ ;;
(cygwin*|msys*|mingw*)
$2='.dll'
$3='.dll.a'
@@ -2812,7 +3124,7 @@ AC_DEFUN([CF_LIB_SUFFIX],
$3=[$]$2
;;
(hpux*)
- case $target in
+ case "$target" in
(ia64*)
$2='.so'
$3=[$]$2
@@ -2830,7 +3142,14 @@ AC_DEFUN([CF_LIB_SUFFIX],
esac
;;
(*)
- $2='.a'
+ case "$target" in
+ (*-msvc*)
+ $2='.lib'
+ ;;
+ (*)
+ $2='.a'
+ ;;
+ esac
$3=[$]$2
;;
esac
@@ -2841,14 +3160,15 @@ AC_DEFUN([CF_LIB_SUFFIX],
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_MAKEFLAGS version: 18 updated: 2018/02/21 21:26:03
+dnl CF_MAKEFLAGS version: 20 updated: 2021/01/03 19:29:49
dnl ------------
dnl Some 'make' programs support ${MAKEFLAGS}, some ${MFLAGS}, to pass 'make'
dnl options to lower-levels. It's very useful for "make -n" -- if we have it.
dnl (GNU 'make' does both, something POSIX 'make', which happens to make the
dnl ${MAKEFLAGS} variable incompatible because it adds the assignments :-)
AC_DEFUN([CF_MAKEFLAGS],
-[
+[AC_REQUIRE([AC_PROG_FGREP])dnl
+
AC_CACHE_CHECK(for makeflags variable, cf_cv_makeflags,[
cf_cv_makeflags=''
for cf_option in '-${MAKEFLAGS}' '${MFLAGS}'
@@ -2858,10 +3178,10 @@ SHELL = $SHELL
all :
@ echo '.$cf_option'
CF_EOF
- cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | fgrep -v "ing directory" | sed -e 's,[[ ]]*$,,'`
+ cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | ${FGREP-fgrep} -v "ing directory" | sed -e 's,[[ ]]*$,,'`
case "$cf_result" in
(.*k|.*kw)
- cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`
+ cf_result="`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`"
case "$cf_result" in
(.*CC=*) cf_cv_makeflags=
;;
@@ -2920,7 +3240,7 @@ AC_SUBST(MAKE_UPPER_TAGS)
AC_SUBST(MAKE_LOWER_TAGS)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_MATH_LIB version: 9 updated: 2017/01/21 11:06:25
+dnl CF_MATH_LIB version: 10 updated: 2020/12/31 18:40:20
dnl -----------
dnl Checks for libraries. At least one UNIX system, Apple Macintosh
dnl Rhapsody 5.5, does not have -lm. We cannot use the simpler
@@ -2934,7 +3254,7 @@ AC_CACHE_CHECK(if -lm needed for math functions,
#include <stdlib.h>
#include <math.h>
],
- [double x = rand(); printf("result = %g\n", ]ifelse([$2],,sin(x),$2)[)],
+ [double x = rand(); printf("result = %g\\n", ]ifelse([$2],,sin(x),$2)[)],
[cf_cv_need_libm=no],
[cf_cv_need_libm=yes])])
if test "$cf_cv_need_libm" = yes
@@ -2945,7 +3265,7 @@ ifelse($1,,[
fi
])
dnl ---------------------------------------------------------------------------
-dnl CF_MBSTATE_T version: 4 updated: 2012/10/06 08:57:51
+dnl CF_MBSTATE_T version: 5 updated: 2020/03/19 20:23:48
dnl ------------
dnl Check if mbstate_t is declared, and if so, which header file.
dnl This (including wchar.h) is needed on Tru64 5.0 to declare mbstate_t,
@@ -2959,7 +3279,7 @@ AC_TRY_COMPILE([
#ifdef HAVE_LIBUTF8_H
#include <libutf8.h>
#endif],
- [mbstate_t state],
+ [mbstate_t state; (void)state],
[cf_cv_mbstate_t=no],
[AC_TRY_COMPILE([
#include <stdlib.h>
@@ -2968,7 +3288,7 @@ AC_TRY_COMPILE([
#ifdef HAVE_LIBUTF8_H
#include <libutf8.h>
#endif],
- [mbstate_t value],
+ [mbstate_t value; (void)value],
[cf_cv_mbstate_t=yes],
[cf_cv_mbstate_t=unknown])])])
@@ -2981,7 +3301,20 @@ if test "$cf_cv_mbstate_t" != unknown ; then
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_MIXEDCASE_FILENAMES version: 7 updated: 2015/04/12 15:39:00
+dnl CF_MERGE_EXTRA_CFLAGS version: 2 updated: 2021/01/02 09:31:20
+dnl ---------------------
+dnl CF_FIX_WARNINGS moves problematic flags into EXTRA_CFLAGS, but some scripts
+dnl may depend on being able to override that variable at build-time. Move it
+dnl all back.
+define([CF_MERGE_EXTRA_CFLAGS],[
+if test "$GCC" = yes || test "$GXX" = yes
+then
+ CF_APPEND_TEXT(CFLAGS,$EXTRA_CFLAGS)
+ EXTRA_CFLAGS=
+fi
+])
+dnl ---------------------------------------------------------------------------
+dnl CF_MIXEDCASE_FILENAMES version: 9 updated: 2021/01/01 16:53:59
dnl ----------------------
dnl Check if the file-system supports mixed-case filenames. If we're able to
dnl create a lowercase name and see it as uppercase, it doesn't support that.
@@ -2989,8 +3322,8 @@ AC_DEFUN([CF_MIXEDCASE_FILENAMES],
[
AC_CACHE_CHECK(if filesystem supports mixed-case filenames,cf_cv_mixedcase,[
if test "$cross_compiling" = yes ; then
- case $target_alias in
- (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
+ case "$target_alias" in
+ (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
cf_cv_mixedcase=no
;;
(*)
@@ -3019,7 +3352,7 @@ AC_DEFUN([CF_MSG_LOG],[
echo "${as_me:-configure}:__oline__: testing $* ..." 1>&AC_FD_CC
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_NCURSES_CC_CHECK version: 4 updated: 2007/07/29 10:39:05
+dnl CF_NCURSES_CC_CHECK version: 5 updated: 2020/12/31 20:19:42
dnl -------------------
dnl Check if we can compile with ncurses' header file
dnl $1 is the cache variable to set
@@ -3039,10 +3372,10 @@ AC_DEFUN([CF_NCURSES_CC_CHECK],[
make an error
#endif
])[
-printf("%s\n", NCURSES_VERSION);
+printf("%s\\n", NCURSES_VERSION);
#else
#ifdef __NCURSES_H
-printf("old\n");
+printf("old\\n");
#else
make an error
#endif
@@ -3052,7 +3385,7 @@ printf("old\n");
,[$1=no])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_NCURSES_CONFIG version: 21 updated: 2018/06/20 20:23:13
+dnl CF_NCURSES_CONFIG version: 26 updated: 2021/01/03 08:05:37
dnl -----------------
dnl Tie together the configure-script macros for ncurses, preferring these in
dnl order:
@@ -3074,14 +3407,50 @@ if test "x${PKG_CONFIG:=none}" != xnone; then
AC_MSG_CHECKING(if the $cf_ncuconfig_root package files work)
cf_have_ncuconfig=unknown
+ cf_save_CFLAGS="$CFLAGS"
cf_save_CPPFLAGS="$CPPFLAGS"
cf_save_LIBS="$LIBS"
- CF_ADD_CFLAGS(`$PKG_CONFIG --cflags $cf_ncuconfig_root`)
- CF_ADD_LIBS(`$PKG_CONFIG --libs $cf_ncuconfig_root`)
+ cf_pkg_cflags="`$PKG_CONFIG --cflags $cf_ncuconfig_root`"
+ cf_pkg_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
+
+ # while -W for passing linker flags is prevalent, it is not "standard".
+ # At least one wrapper for c89/c99 (in Apple's xcode) has its own
+ # incompatible _and_ non-standard -W option which gives an error. Work
+ # around that pitfall.
+ case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
+ (x*c[[89]]9@@*-W*)
+ CF_ADD_CFLAGS($cf_pkg_cflags)
+ CF_ADD_LIBS($cf_pkg_libs)
+
+ AC_TRY_LINK([#include <${cf_cv_ncurses_header:-curses.h}>],
+ [initscr(); mousemask(0,0); tigetstr((char *)0);],
+ [AC_TRY_RUN([#include <${cf_cv_ncurses_header:-curses.h}>
+ int main(void)
+ { char *xx = curses_version(); return (xx == 0); }],
+ [cf_test_ncuconfig=yes],
+ [cf_test_ncuconfig=no],
+ [cf_test_ncuconfig=maybe])],
+ [cf_test_ncuconfig=no])
+
+ CFLAGS="$cf_save_CFLAGS"
+ CPPFLAGS="$cf_save_CPPFLAGS"
+ LIBS="$cf_save_LIBS"
+
+ if test "x$cf_test_ncuconfig" != xyes; then
+ cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[[^ ]]*//g'`
+ cf_pkg_cflags="$cf_temp"
+ cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[[^ ]]*//g'`
+ cf_pkg_libs="$cf_temp"
+ fi
+ ;;
+ esac
+
+ CF_ADD_CFLAGS($cf_pkg_cflags)
+ CF_ADD_LIBS($cf_pkg_libs)
AC_TRY_LINK([#include <${cf_cv_ncurses_header:-curses.h}>],
- [initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);],
+ [initscr(); mousemask(0,0); tigetstr((char *)0);],
[AC_TRY_RUN([#include <${cf_cv_ncurses_header:-curses.h}>
int main(void)
{ char *xx = curses_version(); return (xx == 0); }],
@@ -3133,7 +3502,7 @@ if test "x$cf_have_ncuconfig" = "xno"; then
AC_DEFINE_UNQUOTED($cf_nculib_ROOT)
dnl like CF_NCURSES_VERSION
- cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
+ cf_cv_ncurses_version="`$NCURSES_CONFIG --version`"
else
@@ -3146,7 +3515,7 @@ else
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_NCURSES_CPPFLAGS version: 21 updated: 2012/10/06 08:57:51
+dnl CF_NCURSES_CPPFLAGS version: 22 updated: 2021/01/02 09:31:20
dnl -------------------
dnl Look for the SVr4 curses clone 'ncurses' in the standard places, adjusting
dnl the CPPFLAGS variable so we can include its header.
@@ -3180,7 +3549,7 @@ test "$cf_cv_curses_dir" != "no" && { \
AC_CACHE_CHECK(for $cf_ncuhdr_root header in include-path, cf_cv_ncurses_h,[
cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
- ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
+ { test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw; } && cf_header_list="$cf_header_list curses.h ncurses.h"
for cf_header in $cf_header_list
do
CF_NCURSES_CC_CHECK(cf_cv_ncurses_h,$cf_header,$1)
@@ -3197,7 +3566,7 @@ AC_DEFINE(NCURSES,1,[Define to 1 if we are using ncurses headers/libraries])
CF_NCURSES_VERSION
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_NCURSES_HEADER version: 4 updated: 2015/04/15 19:08:48
+dnl CF_NCURSES_HEADER version: 7 updated: 2021/01/04 19:33:05
dnl -----------------
dnl Find a "curses" header file, e.g,. "curses.h", or one of the more common
dnl variations of ncurses' installs.
@@ -3212,7 +3581,7 @@ else
AC_CACHE_CHECK(for $cf_ncuhdr_root include-path, cf_cv_ncurses_h2,[
test -n "$verbose" && echo
CF_HEADER_PATH(cf_search,$cf_ncuhdr_root)
- test -n "$verbose" && echo search path $cf_search
+ test -n "$verbose" && echo "search path $cf_search"
cf_save2_CPPFLAGS="$CPPFLAGS"
for cf_incdir in $cf_search
do
@@ -3224,7 +3593,7 @@ AC_CACHE_CHECK(for $cf_ncuhdr_root include-path, cf_cv_ncurses_h2,[
CF_NCURSES_CC_CHECK(cf_cv_ncurses_h2,$cf_header,$1)
if test "$cf_cv_ncurses_h2" != no ; then
cf_cv_ncurses_h2=$cf_incdir/$cf_header
- test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&AC_FD_MSG
+ test -n "$verbose" && echo $ECHO_N " ... found $ECHO_C" 1>&AC_FD_MSG
break
fi
test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&AC_FD_MSG
@@ -3236,9 +3605,9 @@ AC_CACHE_CHECK(for $cf_ncuhdr_root include-path, cf_cv_ncurses_h2,[
])
CF_DIRNAME(cf_1st_incdir,$cf_cv_ncurses_h2)
- cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
- if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
- cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
+ cf_cv_ncurses_header="`basename "$cf_cv_ncurses_h2"`"
+ if test "`basename "$cf_1st_incdir"`" = "$cf_ncuhdr_root" ; then
+ cf_cv_ncurses_header="$cf_ncuhdr_root/$cf_cv_ncurses_header"
fi
CF_ADD_INCDIR($cf_1st_incdir)
@@ -3246,13 +3615,13 @@ fi
# Set definitions to allow ifdef'ing for ncurses.h
-case $cf_cv_ncurses_header in
+case "$cf_cv_ncurses_header" in
(*ncurses.h)
AC_DEFINE(HAVE_NCURSES_H,1,[Define to 1 if we have ncurses.h])
;;
esac
-case $cf_cv_ncurses_header in
+case "$cf_cv_ncurses_header" in
(ncurses/curses.h|ncurses/ncurses.h)
AC_DEFINE(HAVE_NCURSES_NCURSES_H,1,[Define to 1 if we have ncurses/ncurses.h])
;;
@@ -3263,7 +3632,7 @@ esac
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_NCURSES_LIBS version: 17 updated: 2015/04/15 19:08:48
+dnl CF_NCURSES_LIBS version: 20 updated: 2021/01/03 08:05:37
dnl ---------------
dnl Look for the ncurses library. This is a little complicated on Linux,
dnl because it may be linked with the gpm (general purpose mouse) library.
@@ -3289,7 +3658,7 @@ AC_CHECK_LIB(gpm,Gpm_Open,
[LIBS="$cf_ncurses_SAVE"],
[cf_ncurses_LIBS="-lgpm"])])
-case $host_os in
+case "$host_os" in
(freebsd*)
# This is only necessary if you are linking against an obsolete
# version of ncurses (but it should do no harm, since it's static).
@@ -3301,7 +3670,7 @@ esac
CF_ADD_LIBS($cf_ncurses_LIBS)
-if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
+if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
then
CF_ADD_LIBS(-l$cf_nculib_root)
else
@@ -3315,13 +3684,13 @@ if test -n "$cf_ncurses_LIBS" ; then
AC_MSG_CHECKING(if we can link $cf_nculib_root without $cf_ncurses_LIBS)
cf_ncurses_SAVE="$LIBS"
for p in $cf_ncurses_LIBS ; do
- q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
+ q=`echo "$LIBS" | sed -e "s%$p %%" -e "s%$p$%%"`
if test "$q" != "$LIBS" ; then
LIBS="$q"
fi
done
AC_TRY_LINK([#include <${cf_cv_ncurses_header:-curses.h}>],
- [initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);],
+ [initscr(); mousemask(0,0); tigetstr((char *)0);],
[AC_MSG_RESULT(yes)],
[AC_MSG_RESULT(no)
LIBS="$cf_ncurses_SAVE"])
@@ -3346,7 +3715,7 @@ then
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_NCURSES_VERSION version: 15 updated: 2017/05/09 19:26:10
+dnl CF_NCURSES_VERSION version: 16 updated: 2020/12/31 20:19:42
dnl ------------------
dnl Check for the version of ncurses, to aid in reporting bugs, etc.
dnl Call CF_CURSES_CPPFLAGS first, or CF_NCURSES_CPPFLAGS. We don't use
@@ -3357,7 +3726,7 @@ AC_REQUIRE([CF_CURSES_CPPFLAGS])dnl
AC_CACHE_CHECK(for ncurses version, cf_cv_ncurses_version,[
cf_cv_ncurses_version=no
cf_tempfile=out$$
- rm -f $cf_tempfile
+ rm -f "$cf_tempfile"
AC_TRY_RUN([
#include <${cf_cv_ncurses_header:-curses.h}>
#include <stdio.h>
@@ -3366,13 +3735,13 @@ int main(void)
FILE *fp = fopen("$cf_tempfile", "w");
#ifdef NCURSES_VERSION
# ifdef NCURSES_VERSION_PATCH
- fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
+ fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
# else
- fprintf(fp, "%s\n", NCURSES_VERSION);
+ fprintf(fp, "%s\\n", NCURSES_VERSION);
# endif
#else
# ifdef __NCURSES_H
- fprintf(fp, "old\n");
+ fprintf(fp, "old\\n");
# else
make an error
# endif
@@ -3383,7 +3752,7 @@ int main(void)
# This will not work if the preprocessor splits the line after the
# Autoconf token. The 'unproto' program does that.
- cat > conftest.$ac_ext <<EOF
+ cat > "conftest.$ac_ext" <<EOF
#include <${cf_cv_ncurses_header:-curses.h}>
#undef Autoconf
#ifdef NCURSES_VERSION
@@ -3398,17 +3767,17 @@ EOF
cf_try="$ac_cpp conftest.$ac_ext 2>&AC_FD_CC | grep '^Autoconf ' >conftest.out"
AC_TRY_EVAL(cf_try)
if test -f conftest.out ; then
- cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[[^"]]*"%%' -e 's%".*%%'`
+ cf_out=`sed -e 's%^Autoconf %%' -e 's%^[[^"]]*"%%' -e 's%".*%%' conftest.out`
test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
rm -f conftest.out
fi
])
- rm -f $cf_tempfile
+ rm -f "$cf_tempfile"
])
test "$cf_cv_ncurses_version" = no || AC_DEFINE(NCURSES,1,[Define to 1 if we are using ncurses headers/libraries])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_NL_LANGINFO_1STDAY version: 1 updated: 2016/02/08 19:06:25
+dnl CF_NL_LANGINFO_1STDAY version: 3 updated: 2020/03/19 20:23:48
dnl ---------------------
dnl glibc locale support has runtime extensions which might be implemented in
dnl other systems.
@@ -3421,14 +3790,16 @@ AC_CACHE_CHECK(if runtime has nl_langinfo support for first weekday,
],[
int first_weekday = nl_langinfo (_NL_TIME_FIRST_WEEKDAY)[0];
long week_1stday_l = (long) nl_langinfo (_NL_TIME_WEEK_1STDAY);
+ (void) first_weekday;
+ (void) week_1stday_l;
],[cf_nl_langinfo_1stday=yes
],[cf_nl_langinfo_1stday=no
])
])
-test "x$cf_nl_langinfo_1stday" = xyes && AC_DEFINE(HAVE_NL_LANGINFO_1STDAY)
+test "x$cf_nl_langinfo_1stday" = xyes && AC_DEFINE(HAVE_NL_LANGINFO_1STDAY,1,[Define to 1 if runtime has nl_langinfo support for first weekday])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_NO_LEAKS_OPTION version: 6 updated: 2015/04/12 15:39:00
+dnl CF_NO_LEAKS_OPTION version: 8 updated: 2021/01/05 20:05:09
dnl ------------------
dnl see CF_WITH_NO_LEAKS
AC_DEFUN([CF_NO_LEAKS_OPTION],[
@@ -3438,13 +3809,13 @@ AC_ARG_WITH($1,
[AC_DEFINE_UNQUOTED($3,1,"Define to 1 if you want to use $1 for testing.")ifelse([$4],,[
$4
])
- : ${with_cflags:=-g}
- : ${with_no_leaks:=yes}
+ : "${with_cflags:=-g}"
+ : "${enable_leaks:=no}"
with_$1=yes],
[with_$1=])
AC_MSG_RESULT(${with_$1:-no})
-case .$with_cflags in
+case ".$with_cflags" in
(.*-g*)
case .$CFLAGS in
(.*-g*)
@@ -3476,7 +3847,7 @@ else
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_OUR_MESSAGES version: 7 updated: 2004/09/12 19:45:55
+dnl CF_OUR_MESSAGES version: 8 updated: 2021/01/02 09:31:20
dnl ---------------
dnl Check if we use the messages included with this program
dnl
@@ -3492,7 +3863,7 @@ cf_makefile=ifelse($1,,Makefile,$1)
use_our_messages=no
if test "$USE_NLS" = yes ; then
-if test -d $srcdir/po ; then
+if test -d "$srcdir/po" ; then
AC_MSG_CHECKING(if we should use included message-library)
AC_ARG_ENABLE(included-msgs,
[ --disable-included-msgs use included messages, for i18n support],
@@ -3513,14 +3884,14 @@ AC_SUBST(MSG_DIR_MAKE)
AC_SUBST(SUB_MAKEFILE)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_PATHSEP version: 7 updated: 2015/04/12 15:39:00
+dnl CF_PATHSEP version: 8 updated: 2021/01/01 13:31:04
dnl ----------
dnl Provide a value for the $PATH and similar separator (or amend the value
dnl as provided in autoconf 2.5x).
AC_DEFUN([CF_PATHSEP],
[
AC_MSG_CHECKING(for PATH separator)
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(os2*) PATH_SEPARATOR=';' ;;
(*) ${PATH_SEPARATOR:=':'} ;;
esac
@@ -3529,7 +3900,7 @@ ifelse([$1],,,[$1=$PATH_SEPARATOR])
AC_MSG_RESULT($PATH_SEPARATOR)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_PATH_SYNTAX version: 16 updated: 2015/04/18 08:56:57
+dnl CF_PATH_SYNTAX version: 18 updated: 2020/12/31 18:40:20
dnl --------------
dnl Check the argument to see that it looks like a pathname. Rewrite it if it
dnl begins with one of the prefix/exec_prefix variables, and then again if the
@@ -3549,16 +3920,16 @@ case ".[$]$1" in
;;
(.[[a-zA-Z]]:[[\\/]]*) # OS/2 EMX
;;
-(.\[$]{*prefix}*|.\[$]{*dir}*)
+(.\[$]\{*prefix\}*|.\[$]\{*dir\}*)
eval $1="[$]$1"
case ".[$]$1" in
(.NONE/*)
- $1=`echo [$]$1 | sed -e s%NONE%$cf_path_syntax%`
+ $1=`echo "[$]$1" | sed -e s%NONE%$cf_path_syntax%`
;;
esac
;;
(.no|.NONE/*)
- $1=`echo [$]$1 | sed -e s%NONE%$cf_path_syntax%`
+ $1=`echo "[$]$1" | sed -e s%NONE%$cf_path_syntax%`
;;
(*)
ifelse([$2],,[AC_MSG_ERROR([expected a pathname, not \"[$]$1\"])],$2)
@@ -3566,7 +3937,7 @@ case ".[$]$1" in
esac
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_PDCURSES_X11 version: 14 updated: 2018/06/20 20:23:13
+dnl CF_PDCURSES_X11 version: 15 updated: 2021/01/02 09:31:20
dnl ---------------
dnl Configure for PDCurses' X11 library
AC_DEFUN([CF_PDCURSES_X11],[
@@ -3602,7 +3973,7 @@ char *XCursesProgramName = "test";
fi
-if test $cf_cv_lib_XCurses = yes ; then
+if test "$cf_cv_lib_XCurses" = yes ; then
AC_DEFINE(UNIX,1,[Define to 1 if using PDCurses on Unix])
AC_DEFINE(XCURSES,1,[Define to 1 if using PDCurses on Unix])
AC_CHECK_HEADER(xcurses.h, AC_DEFINE(HAVE_XCURSES,1,[Define to 1 if using PDCurses on Unix]))
@@ -3611,7 +3982,7 @@ else
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_PKG_CONFIG version: 10 updated: 2015/04/26 18:06:58
+dnl CF_PKG_CONFIG version: 11 updated: 2021/01/01 13:31:04
dnl -------------
dnl Check for the package-config program, unless disabled by command-line.
AC_DEFUN([CF_PKG_CONFIG],
@@ -3623,7 +3994,7 @@ AC_ARG_WITH(pkg-config,
[cf_pkg_config=yes])
AC_MSG_RESULT($cf_pkg_config)
-case $cf_pkg_config in
+case "$cf_pkg_config" in
(no)
PKG_CONFIG=none
;;
@@ -3647,7 +4018,7 @@ fi
AC_SUBST(PKG_CONFIG)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_POSIX_C_SOURCE version: 10 updated: 2018/06/20 20:23:13
+dnl CF_POSIX_C_SOURCE version: 11 updated: 2018/12/31 20:46:17
dnl -----------------
dnl Define _POSIX_C_SOURCE to the given level, and _POSIX_SOURCE if needed.
dnl
@@ -3662,7 +4033,10 @@ dnl
dnl Parameters:
dnl $1 is the nominal value for _POSIX_C_SOURCE
AC_DEFUN([CF_POSIX_C_SOURCE],
-[
+[AC_REQUIRE([CF_POSIX_VISIBLE])dnl
+
+if test "$cf_cv_posix_visible" = no; then
+
cf_POSIX_C_SOURCE=ifelse([$1],,199506L,[$1])
cf_save_CFLAGS="$CFLAGS"
@@ -3719,6 +4093,35 @@ if test "$cf_cv_posix_c_source" != no ; then
CF_ADD_CFLAGS($cf_cv_posix_c_source)
fi
+fi # cf_cv_posix_visible
+
+])dnl
+dnl ---------------------------------------------------------------------------
+dnl CF_POSIX_VISIBLE version: 1 updated: 2018/12/31 20:46:17
+dnl ----------------
+dnl POSIX documents test-macros which an application may set before any system
+dnl headers are included to make features available.
+dnl
+dnl Some BSD platforms (originally FreeBSD, but copied by a few others)
+dnl diverged from POSIX in 2002 by setting symbols which make all of the most
+dnl recent features visible in the system header files unless the application
+dnl overrides the corresponding test-macros. Doing that introduces portability
+dnl problems.
+dnl
+dnl This macro makes a special check for the symbols used for this, to avoid a
+dnl conflicting definition.
+AC_DEFUN([CF_POSIX_VISIBLE],
+[
+AC_CACHE_CHECK(if the POSIX test-macros are already defined,cf_cv_posix_visible,[
+AC_TRY_COMPILE([#include <stdio.h>],[
+#if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
+ && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
+ && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
+ && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
+#error conflicting symbols found
+#endif
+],[cf_cv_posix_visible=no],[cf_cv_posix_visible=yes])
+])
])dnl
dnl ---------------------------------------------------------------------------
dnl CF_PROG_AR version: 1 updated: 2009/01/01 20:15:22
@@ -3728,11 +4131,15 @@ AC_DEFUN([CF_PROG_AR],[
AC_CHECK_TOOL(AR, ar, ar)
])
dnl ---------------------------------------------------------------------------
-dnl CF_PROG_CC version: 4 updated: 2014/07/12 18:57:58
+dnl CF_PROG_CC version: 5 updated: 2019/12/31 08:53:54
dnl ----------
dnl standard check for CC, plus followup sanity checks
dnl $1 = optional parameter to pass to AC_PROG_CC to specify compiler name
AC_DEFUN([CF_PROG_CC],[
+CF_ACVERSION_CHECK(2.53,
+ [AC_MSG_WARN(this will incorrectly handle gnatgcc choice)
+ AC_REQUIRE([AC_PROG_CC])],
+ [])
ifelse($1,,[AC_PROG_CC],[AC_PROG_CC($1)])
CF_GCC_VERSION
CF_ACVERSION_CHECK(2.52,
@@ -3741,13 +4148,13 @@ CF_ACVERSION_CHECK(2.52,
CF_CC_ENV_FLAGS
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_PROG_EXT version: 14 updated: 2018/06/20 20:23:13
+dnl CF_PROG_EXT version: 15 updated: 2021/01/02 09:31:20
dnl -----------
dnl Compute $PROG_EXT, used for non-Unix ports, such as OS/2 EMX.
AC_DEFUN([CF_PROG_EXT],
[
AC_REQUIRE([CF_CHECK_CACHE])
-case $cf_cv_system_name in
+case "$cf_cv_system_name" in
(os2*)
CFLAGS="$CFLAGS -Zmt"
CF_APPEND_TEXT(CPPFLAGS,-D__ST_MT_ERRNO__)
@@ -3786,11 +4193,16 @@ AC_SUBST(GROFF_NOTE)
AC_SUBST(NROFF_NOTE)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_PROG_LINT version: 3 updated: 2016/05/22 15:25:54
+dnl CF_PROG_LINT version: 4 updated: 2019/11/20 18:55:37
dnl ------------
AC_DEFUN([CF_PROG_LINT],
[
AC_CHECK_PROGS(LINT, lint cppcheck splint)
+case "x$LINT" in
+(xcppcheck|x*/cppcheck)
+ test -z "$LINT_OPTS" && LINT_OPTS="--enable=all"
+ ;;
+esac
AC_SUBST(LINT_OPTS)
])dnl
dnl ---------------------------------------------------------------------------
@@ -3833,11 +4245,23 @@ $1=`echo "$2" | \
-e 's/-[[UD]]'"$3"'\(=[[^ ]]*\)\?[$]//g'`
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_RPATH_HACK version: 11 updated: 2013/09/01 13:02:00
+dnl CF_RESTORE_XTRA_FLAGS version: 1 updated: 2020/01/11 16:47:45
+dnl ---------------------
+dnl Restore flags saved in CF_SAVE_XTRA_FLAGS
+dnl $1 = name of current macro
+define([CF_RESTORE_XTRA_FLAGS],
+[
+LIBS="$cf_save_LIBS_$1"
+CFLAGS="$cf_save_CFLAGS_$1"
+CPPFLAGS="$cf_save_CPPFLAGS_$1"
+])dnl
+dnl ---------------------------------------------------------------------------
+dnl CF_RPATH_HACK version: 13 updated: 2021/01/03 18:30:50
dnl -------------
AC_DEFUN([CF_RPATH_HACK],
-[
-AC_REQUIRE([CF_LD_RPATH_OPT])
+[AC_REQUIRE([AC_PROG_FGREP])dnl
+AC_REQUIRE([CF_LD_RPATH_OPT])dnl
+
AC_MSG_CHECKING(for updated LDFLAGS)
if test -n "$LD_RPATH_OPT" ; then
AC_MSG_RESULT(maybe)
@@ -3850,8 +4274,8 @@ if test -n "$LD_RPATH_OPT" ; then
AC_TRY_LINK([#include <stdio.h>],
[printf("Hello");],
- [cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
- cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[[ ]]/%/%' -e 's%/[[^/]][[^/]]*$%%' |sort | uniq`])
+ [cf_rpath_oops=`"$cf_ldd_prog" "conftest$ac_exeext" | ${FGREP-fgrep} ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
+ cf_rpath_list=`"$cf_ldd_prog" "conftest$ac_exeext" | ${FGREP-fgrep} / | sed -e 's%^.*[[ ]]/%/%' -e 's%/[[^/]][[^/]]*$%%' |sort | uniq`])
# If we passed the link-test, but get a "not found" on a given library,
# this could be due to inept reconfiguration of gcc to make it only
@@ -3867,7 +4291,7 @@ AC_TRY_LINK([#include <stdio.h>],
/usr/pkg \
/opt/sfw
do
- if test -f $cf_rpath_dir/lib/$cf_rpath_src
+ if test -f "$cf_rpath_dir/lib/$cf_rpath_src"
then
CF_VERBOSE(...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src)
LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
@@ -3890,7 +4314,7 @@ fi
AC_SUBST(EXTRA_LDFLAGS)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_RPATH_HACK_2 version: 7 updated: 2015/04/12 15:39:00
+dnl CF_RPATH_HACK_2 version: 8 updated: 2021/01/01 13:31:04
dnl ---------------
dnl Do one set of substitutions for CF_RPATH_HACK, adding an rpath option to
dnl EXTRA_LDFLAGS for each -L option found.
@@ -3906,7 +4330,7 @@ CF_VERBOSE(...checking $1 [$]$1)
cf_rpath_dst=
for cf_rpath_src in [$]$1
do
- case $cf_rpath_src in
+ case "$cf_rpath_src" in
(-L*)
# check if this refers to a directory which we will ignore
@@ -3950,7 +4374,32 @@ CF_VERBOSE(...checked $1 [$]$1)
AC_SUBST(EXTRA_LDFLAGS)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_SHARED_OPTS version: 92 updated: 2017/12/30 17:26:05
+dnl CF_SAVE_XTRA_FLAGS version: 1 updated: 2020/01/11 16:46:44
+dnl ------------------
+dnl Use this macro to save CFLAGS/CPPFLAGS/LIBS before checks against X headers
+dnl and libraries which do not update those variables.
+dnl
+dnl $1 = name of current macro
+define([CF_SAVE_XTRA_FLAGS],
+[
+cf_save_LIBS_$1="$LIBS"
+cf_save_CFLAGS_$1="$CFLAGS"
+cf_save_CPPFLAGS_$1="$CPPFLAGS"
+LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
+for cf_X_CFLAGS in $X_CFLAGS
+do
+ case "x$cf_X_CFLAGS" in
+ x-[[IUD]]*)
+ CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
+ ;;
+ *)
+ CFLAGS="$CFLAGS $cf_X_CFLAGS"
+ ;;
+ esac
+done
+])dnl
+dnl ---------------------------------------------------------------------------
+dnl CF_SHARED_OPTS version: 105 updated: 2021/01/02 17:09:14
dnl --------------
dnl --------------
dnl Attempt to determine the appropriate CC/LD options for creating a shared
@@ -3978,6 +4427,7 @@ dnl Some loaders leave 'so_locations' lying around. It's nice to clean up.
AC_DEFUN([CF_SHARED_OPTS],
[
AC_REQUIRE([CF_LD_RPATH_OPT])
+
RM_SHARED_OPTS=
LOCAL_LDFLAGS=
LOCAL_LDFLAGS2=
@@ -3999,7 +4449,7 @@ AC_DEFUN([CF_SHARED_OPTS],
AC_ARG_WITH(shlib-version,
[ --with-shlib-version=X Specify rel or abi version for shared libs],
[test -z "$withval" && withval=auto
- case $withval in
+ case "$withval" in
(yes)
cf_cv_shlib_version=auto
;;
@@ -4025,7 +4475,7 @@ AC_DEFUN([CF_SHARED_OPTS],
then
cf_try_fPIC=yes
else
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(*linux*) # e.g., PGI compiler
cf_try_fPIC=yes
;;
@@ -4047,7 +4497,7 @@ AC_DEFUN([CF_SHARED_OPTS],
cf_cv_shlib_version_infix=no
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(aix4.[3-9]*|aix[[5-7]]*)
if test "$GCC" = yes; then
CC_SHARED_OPTS='-Wl,-brtl'
@@ -4116,7 +4566,7 @@ CF_EOF
LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
AC_TRY_LINK(, [int i;], cf_cv_ldflags_search_paths_first=yes, cf_cv_ldflags_search_paths_first=no)
LDFLAGS=$cf_save_LDFLAGS])
- if test $cf_cv_ldflags_search_paths_first = yes; then
+ if test "$cf_cv_ldflags_search_paths_first" = yes; then
LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
fi
;;
@@ -4165,7 +4615,7 @@ CF_EOF
cf_cv_rm_so_locs=yes
;;
(linux*|gnu*|k*bsd*-gnu)
- if test "$DFT_LWR_MODEL" = "shared" ; then
+ if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
fi
@@ -4175,6 +4625,112 @@ CF_EOF
CF_SHARED_SONAME
MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $[@]'
;;
+ (mingw*msvc*)
+ cf_cv_shlib_version=msvcdll
+ cf_cv_shlib_version_infix=msvcdll
+ shlibdir=$bindir
+ MAKE_DLLS=
+ if test "$DFT_LWR_MODEL" = "shared" ; then
+ LOCAL_LDFLAGS="-link -dll"
+ LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
+ EXTRA_LDFLAGS="-link -dll $EXTRA_LDFLAGS"
+ fi
+ CC_SHARED_OPTS=
+ MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh [$]@ ${LD} [$]{CFLAGS}'
+ RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.lib"
+ cat >mk_shared_lib.sh <<-CF_EOF
+ #!$SHELL
+ SHARED_LIB=\[$]1
+ IMPORT_LIB=\`echo "\[$]1" | sed -e 's/[[0-9]]*\.dll[$]/.dll.lib/'\`
+ shift
+ my_ld=\[$]1
+ shift
+ cat <<-EOF
+ Linking shared library
+ ** SHARED LIB \$SHARED_LIB
+ ** IMPORT_LIB \$IMPORT_LIB
+EOF
+ args=\$(echo \[$]* | sed -E "s#-l(\w*)#\1.dll.lib#g" | sed -E "s#-L(\w*)#-LIBPATH:\1#g")
+ exec \$my_ld -DLL -IMPLIB:"\${IMPORT_LIB}" -OUT:"\${SHARED_LIB}" ${LDFLAGS} \$args
+ mv "\${IMPORT_LIB}" "\${IMPORT_LIB}"
+CF_EOF
+ chmod +x mk_shared_lib.sh
+ cat >mk_prog.sh <<-CF_EOF
+ #!$SHELL
+ shift
+ # Ignore first argument (compiler) and use LD (link.exe) unconditionally
+ LD="[$]LD"
+ clopts=()
+ ldopts=("/subsystem:console")
+ libs=()
+ isdll=0
+ while test \[$]# -gt 0; do
+ case "\[$]1" in
+ -link)
+ # ignore -link argument
+ ;;
+ -M[[TD]] | -M[[TD]]d)
+ # ignore runtime-library option
+ ;;
+ -dll)
+ isdll=1
+ ;;
+ -W* | -w*)
+ # ignore warnings
+ ;;
+ -D*)
+ clopts+=("\[$]1")
+ ;;
+ -I*)
+ clopts+=("\[$]1")
+ ;;
+ -l*)
+ libs+=("\`echo \"\[$]1\" | sed \"s/^-l//\"\`")
+ ;;
+ -L*)
+ ldopts+=("\`echo \"\[$]1\" | sed \"s/^-L/-LIBPATH:/\"\`")
+ ;;
+ *.obj | *.o)
+ ldopts+=("\[$]1")
+ ;;
+ -Wl,*)
+ for linkarg in \`echo '\[$]1' | sed -e 's/-Wl,//' -e 's/,/ /'\`; do
+ ldopts+=("\[$]{linkarg}")
+ done
+ ;;
+ *.lib)
+ ldopts+=("\[$]1")
+ ;;
+ -o)
+ shift
+ ldopts+=("-out:\[$]1")
+ ;;
+ *)
+ clopts+=("\[$]1")
+ ldopts+=("\[$]1")
+ ;;
+ esac
+ shift
+ done
+ if [[ "\$isdll" -ne 0 ]]; then
+ for lib in \[$]{libs[[*]]}; do
+ ldopts+=("\[$]lib.dll.lib")
+ done
+ else
+ for lib in \[$]{libs[[*]]}; do
+ ldopts+=("\[$]lib.lib")
+ done
+ fi
+ cat <<-EOF
+ Creating program
+ ** ld options: "\[$]{ldopts[[@]]}"
+EOF
+ exec \[$]LD \[$]{ldopts[[@]]}
+CF_EOF
+ chmod +x mk_prog.sh
+ LINK_PROGS="$SHELL ${rel_builddir}/mk_prog.sh"
+ LINK_TESTS="$SHELL ${rel_builddir}/mk_prog.sh"
+ ;;
(mingw*)
cf_cv_shlib_version=mingw
cf_cv_shlib_version_infix=mingw
@@ -4203,7 +4759,7 @@ CF_EOF
chmod +x mk_shared_lib.sh
;;
(openbsd[[2-9]].*|mirbsd*)
- if test "$DFT_LWR_MODEL" = "shared" ; then
+ if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
fi
@@ -4214,6 +4770,14 @@ CF_EOF
CF_SHARED_SONAME
MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $[@]'
;;
+ (nskJ*)
+ CC_SHARED_OPTS=
+ MK_SHARED_LIB='${LD} -Wshared -Weld=-export_all -o $[@]'
+ ;;
+ (nskL*)
+ CC_SHARED_OPTS=
+ MK_SHARED_LIB='${LD} -Wshared -Wxld=-export_all -o $[@]'
+ ;;
(nto-qnx*|openbsd*|freebsd[[12]].*)
CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
MK_SHARED_LIB='${LD} ${LDFLAGS} -Bshareable -o $[@]'
@@ -4245,7 +4809,7 @@ CF_EOF
CF_SHARED_SONAME
MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $[@]'
else
- MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -Wl,-shared -Wl,-Bshareable -o $[@]'
+ MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -o $[@]'
fi
;;
(osf*|mls+*)
@@ -4253,13 +4817,13 @@ CF_EOF
# tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
# link with shared libs).
MK_SHARED_LIB='${LD} ${LDFLAGS} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $[@]`'
- case $host_os in
+ case "$host_os" in
(osf4*)
MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
;;
esac
MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $[@]'
- if test "$DFT_LWR_MODEL" = "shared" ; then
+ if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
fi
@@ -4303,7 +4867,7 @@ CF_EOF
for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
do
CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
- AC_TRY_COMPILE([#include <stdio.h>],[printf("Hello\n");],[break])
+ AC_TRY_COMPILE([#include <stdio.h>],[printf("Hello\\n");],[break])
done
CFLAGS="$cf_save_CFLAGS"
CC_SHARED_OPTS=$cf_shared_opts
@@ -4346,7 +4910,7 @@ cat > conftest.$ac_ext <<EOF
#include <stdio.h>
int main(int argc, char *argv[[]])
{
- printf("hello\n");
+ printf("hello\\n");
return (argv[[argc-1]] == 0) ;
}
EOF
@@ -4370,7 +4934,7 @@ EOF
test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}"
test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}"
- test $cf_cv_rm_so_locs = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
+ test "$cf_cv_rm_so_locs" = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
CF_VERBOSE(CC_SHARED_OPTS: $CC_SHARED_OPTS)
CF_VERBOSE(MK_SHARED_LIB: $MK_SHARED_LIB)
@@ -4410,7 +4974,7 @@ define([CF_SHARED_SONAME],
fi
])
dnl ---------------------------------------------------------------------------
-dnl CF_SIZECHANGE version: 14 updated: 2018/06/20 20:23:13
+dnl CF_SIZECHANGE version: 17 updated: 2021/01/01 13:31:04
dnl -------------
dnl Check for definitions & structures needed for window size-changing
dnl
@@ -4453,13 +5017,17 @@ do
],[
#ifdef TIOCGSIZE
struct ttysize win; /* SunOS 3.0... */
- int y = win.ts_lines;
- int x = win.ts_cols;
+ int y = win.ts_lines = 2;
+ int x = win.ts_cols = 1;
+ (void)y;
+ (void)x;
#else
#ifdef TIOCGWINSZ
struct winsize win; /* everything else */
- int y = win.ws_row;
- int x = win.ws_col;
+ int y = win.ws_row = 2;
+ int x = win.ws_col = 1;
+ (void)y;
+ (void)x;
#else
no TIOCGSIZE or TIOCGWINSZ
#endif /* TIOCGWINSZ */
@@ -4478,7 +5046,7 @@ done
])
if test "$cf_cv_sizechange" != no ; then
AC_DEFINE(HAVE_SIZECHANGE,1,[Define to 1 if sizechange declarations are provided])
- case $cf_cv_sizechange in
+ case "$cf_cv_sizechange" in
(NEED*)
AC_DEFINE_UNQUOTED($cf_cv_sizechange )
;;
@@ -4486,7 +5054,7 @@ if test "$cf_cv_sizechange" != no ; then
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_STRUCT_TERMIOS version: 9 updated: 2018/06/08 21:57:23
+dnl CF_STRUCT_TERMIOS version: 11 updated: 2020/03/19 20:46:13
dnl -----------------
dnl Some machines require _POSIX_SOURCE to completely define struct termios.
AC_DEFUN([CF_STRUCT_TERMIOS],[
@@ -4509,12 +5077,12 @@ if test "$ac_cv_header_termios_h" = yes ; then
if test "$termios_bad" = maybe ; then
AC_MSG_CHECKING(whether termios.h needs _POSIX_SOURCE)
AC_TRY_COMPILE([#include <termios.h>],
- [struct termios foo; int x = foo.c_iflag],
+ [struct termios foo; int x = foo.c_iflag = 1; (void)x],
termios_bad=no, [
AC_TRY_COMPILE([
#define _POSIX_SOURCE
#include <termios.h>],
- [struct termios foo; int x = foo.c_iflag],
+ [struct termios foo; int x = foo.c_iflag = 2; (void)x],
termios_bad=unknown,
termios_bad=yes AC_DEFINE(_POSIX_SOURCE,1,[Define to 1 if we must define _POSIX_SOURCE]))
])
@@ -4547,14 +5115,14 @@ do
done
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_TERM_HEADER version: 4 updated: 2015/04/15 19:08:48
+dnl CF_TERM_HEADER version: 6 updated: 2021/01/02 09:31:20
dnl --------------
dnl Look for term.h, which is part of X/Open curses. It defines the interface
dnl to terminfo database. Usually it is in the same include-path as curses.h,
dnl but some packagers change this, breaking various applications.
AC_DEFUN([CF_TERM_HEADER],[
AC_CACHE_CHECK(for terminfo header, cf_cv_term_header,[
-case ${cf_cv_ncurses_header} in
+case "${cf_cv_ncurses_header}" in
(*/ncurses.h|*/ncursesw.h)
cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[[^.]]*\.h$%term.h%'`
;;
@@ -4568,7 +5136,7 @@ do
AC_TRY_COMPILE([#include <stdio.h>
#include <${cf_cv_ncurses_header:-curses.h}>
#include <$cf_test>
-],[int x = auto_left_margin],[
+],[int x = auto_left_margin; (void)x],[
cf_cv_term_header="$cf_test"],[
cf_cv_term_header=unknown
])
@@ -4578,13 +5146,13 @@ done
# Set definitions to allow ifdef'ing to accommodate subdirectories
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(*term.h)
AC_DEFINE(HAVE_TERM_H,1,[Define to 1 if we have term.h])
;;
esac
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(ncurses/term.h)
AC_DEFINE(HAVE_NCURSES_TERM_H,1,[Define to 1 if we have ncurses/term.h])
;;
@@ -4610,21 +5178,21 @@ AC_DEFUN([CF_TRIM_X_LIBS],[
done
])
dnl ---------------------------------------------------------------------------
-dnl CF_TRY_PKG_CONFIG version: 5 updated: 2013/07/06 21:27:06
+dnl CF_TRY_PKG_CONFIG version: 6 updated: 2020/12/31 10:54:15
dnl -----------------
dnl This is a simple wrapper to use for pkg-config, for libraries which may be
dnl available in that form.
dnl
-dnl $1 = package name
+dnl $1 = package name, which may be a shell variable
dnl $2 = extra logic to use, if any, after updating CFLAGS and LIBS
dnl $3 = logic to use if pkg-config does not have the package
AC_DEFUN([CF_TRY_PKG_CONFIG],[
AC_REQUIRE([CF_PKG_CONFIG])
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $1; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "$1"; then
CF_VERBOSE(found package $1)
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags $1 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs $1 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "$1" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "$1" 2>/dev/null`"
CF_VERBOSE(package $1 CFLAGS: $cf_pkgconfig_incs)
CF_VERBOSE(package $1 LIBS: $cf_pkgconfig_libs)
CF_ADD_CFLAGS($cf_pkgconfig_incs)
@@ -4676,7 +5244,7 @@ if test "$cf_cv_xopen_source" != no ; then
fi
])
dnl ---------------------------------------------------------------------------
-dnl CF_UNION_WAIT version: 6 updated: 2012/10/06 08:57:51
+dnl CF_UNION_WAIT version: 8 updated: 2021/01/02 09:31:20
dnl -------------
dnl Check to see if the BSD-style union wait is declared. Some platforms may
dnl use this, though it is deprecated in favor of the 'int' type in Posix.
@@ -4700,6 +5268,9 @@ AC_CACHE_VAL(cf_cv_type_unionwait,[
int y = WEXITSTATUS(x);
int z = WTERMSIG(x);
wait(&x);
+ (void)x;
+ (void)y;
+ (void)z;
],
[cf_cv_type_unionwait=no
echo compiles ok w/o union wait 1>&AC_FD_CC
@@ -4713,13 +5284,20 @@ AC_CACHE_VAL(cf_cv_type_unionwait,[
int z = WTERMSIG(x);
#endif
wait(&x);
+ (void)x;
+#ifdef WEXITSTATUS
+ (void)y;
+#endif
+#ifdef WTERMSIG
+ (void)z;
+#endif
],
[cf_cv_type_unionwait=yes
echo compiles ok with union wait and possibly macros too 1>&AC_FD_CC
],
[cf_cv_type_unionwait=no])])])
AC_MSG_RESULT($cf_cv_type_unionwait)
-test $cf_cv_type_unionwait = yes && AC_DEFINE(HAVE_TYPE_UNIONWAIT,1,[Define to 1 if type unionwait is declared])
+test "$cf_cv_type_unionwait" = yes && AC_DEFINE(HAVE_TYPE_UNIONWAIT,1,[Define to 1 if type unionwait is declared])
])dnl
dnl ---------------------------------------------------------------------------
dnl CF_UPPER version: 5 updated: 2001/01/29 23:40:59
@@ -4765,7 +5343,7 @@ AC_DEFUN([CF_VERBOSE],
CF_MSG_LOG([$1])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_VERSION_INFO version: 7 updated: 2015/04/17 21:13:04
+dnl CF_VERSION_INFO version: 8 updated: 2021/01/01 13:31:04
dnl ---------------
dnl Define several useful symbols derived from the VERSION file. A separate
dnl file is preferred to embedding the version numbers in various scripts.
@@ -4793,13 +5371,13 @@ dnl $1 = internal name for package
dnl $2 = external name for package
AC_DEFUN([CF_VERSION_INFO],
[
-if test -f $srcdir/VERSION ; then
+if test -f "$srcdir/VERSION" ; then
AC_MSG_CHECKING(for package version)
# if there are not enough fields, cut returns the last one...
- cf_field1=`sed -e '2,$d' $srcdir/VERSION|cut -f1`
- cf_field2=`sed -e '2,$d' $srcdir/VERSION|cut -f2`
- cf_field3=`sed -e '2,$d' $srcdir/VERSION|cut -f3`
+ cf_field1=`sed -e '2,$d' "$srcdir/VERSION" |cut -f1`
+ cf_field2=`sed -e '2,$d' "$srcdir/VERSION" |cut -f2`
+ cf_field3=`sed -e '2,$d' "$srcdir/VERSION" |cut -f3`
# this is how CF_BUNDLED_INTL uses $VERSION:
VERSION="$cf_field1"
@@ -4853,7 +5431,7 @@ ifelse($1,,,[
])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WAIT_HEADERS version: 2 updated: 1997/10/21 19:45:33
+dnl CF_WAIT_HEADERS version: 3 updated: 2021/01/02 09:31:20
dnl ---------------
dnl Build up an expression $cf_wait_headers with the header files needed to
dnl compile against the prototypes for 'wait()', 'waitpid()', etc. Assume it's
@@ -4864,19 +5442,19 @@ AC_DEFUN([CF_WAIT_HEADERS],
AC_HAVE_HEADERS(sys/wait.h)
cf_wait_headers="#include <sys/types.h>
"
-if test $ac_cv_header_sys_wait_h = yes; then
+if test "$ac_cv_header_sys_wait_h" = yes; then
cf_wait_headers="$cf_wait_headers
#include <sys/wait.h>
"
else
AC_HAVE_HEADERS(wait.h)
AC_HAVE_HEADERS(waitstatus.h)
-if test $ac_cv_header_wait_h = yes; then
+if test "$ac_cv_header_wait_h" = yes; then
cf_wait_headers="$cf_wait_headers
#include <wait.h>
"
fi
-if test $ac_cv_header_waitstatus_h = yes; then
+if test "$ac_cv_header_waitstatus_h" = yes; then
cf_wait_headers="$cf_wait_headers
#include <waitstatus.h>
"
@@ -4884,7 +5462,7 @@ fi
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WIDEC_CURSES version: 5 updated: 2012/11/08 20:57:52
+dnl CF_WIDEC_CURSES version: 6 updated: 2020/03/19 20:23:48
dnl ---------------
dnl Check for curses implementations that can handle wide-characters
AC_DEFUN([CF_WIDEC_CURSES],
@@ -4910,13 +5488,13 @@ if test "$cf_cv_widec_curses" = yes ; then
AC_TRY_COMPILE([
#include <stdlib.h>
#include <${cf_cv_ncurses_header:-curses.h}>],
-[mbstate_t state],
+[mbstate_t state; (void)state],
[cf_cv_widec_mbstate=no],
[AC_TRY_COMPILE([
#include <stdlib.h>
#include <wchar.h>
#include <${cf_cv_ncurses_header:-curses.h}>],
-[mbstate_t state],
+[mbstate_t state; (void)state],
[cf_cv_widec_mbstate=yes],
[cf_cv_widec_mbstate=unknown])])])
@@ -4931,7 +5509,7 @@ fi
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WITH_ABI_VERSION version: 3 updated: 2015/06/06 16:10:11
+dnl CF_WITH_ABI_VERSION version: 4 updated: 2021/01/01 13:31:04
dnl -------------------
dnl Allow library's ABI to be overridden. Generally this happens when a
dnl packager has incremented the ABI past that used in the original package,
@@ -4946,7 +5524,7 @@ AC_ARG_WITH(abi-version,
if test "x$cf_cv_abi_version" != "x$withval"
then
AC_MSG_WARN(overriding ABI version $cf_cv_abi_version to $withval)
- case $cf_cv_rel_version in
+ case "$cf_cv_rel_version" in
(5.*)
cf_cv_rel_version=$withval.0
;;
@@ -4962,7 +5540,7 @@ $1_ABI=$cf_cv_abi_version
])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WITH_CURSES_DIR version: 3 updated: 2010/11/20 17:02:38
+dnl CF_WITH_CURSES_DIR version: 4 updated: 2021/01/02 19:22:58
dnl ------------------
dnl Wrapper for AC_ARG_WITH to specify directory under which to look for curses
dnl libraries.
@@ -4975,7 +5553,7 @@ AC_ARG_WITH(curses-dir,
[cf_cv_curses_dir=no])
AC_MSG_RESULT($cf_cv_curses_dir)
-if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
+if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
then
CF_PATH_SYNTAX(withval)
if test -d "$cf_cv_curses_dir"
@@ -5061,7 +5639,7 @@ fi
AC_SUBST(DESTDIR)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WITH_LIBTOOL version: 35 updated: 2017/08/12 07:58:51
+dnl CF_WITH_LIBTOOL version: 36 updated: 2021/01/01 13:31:04
dnl ---------------
dnl Provide a configure option to incorporate libtool. Define several useful
dnl symbols for the makefile rules.
@@ -5166,7 +5744,7 @@ ifdef([AC_PROG_LIBTOOL],[
AC_SUBST([LT_UNDEF])
# special hack to add --tag option for C++ compiler
- case $cf_cv_libtool_version in
+ case "$cf_cv_libtool_version" in
(1.[[5-9]]*|[[2-9]].[[0-9.a-z]]*)
LIBTOOL_CXX="$LIBTOOL --tag=CXX"
LIBTOOL="$LIBTOOL --tag=CC"
@@ -5225,7 +5803,7 @@ esac
AC_SUBST(LIBTOOL_OPTS)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WITH_MAN2HTML version: 7 updated: 2018/01/07 13:16:19
+dnl CF_WITH_MAN2HTML version: 12 updated: 2021/01/03 18:30:50
dnl ----------------
dnl Check for man2html and groff. Prefer man2html over groff, but use groff
dnl as a fallback. See
@@ -5238,7 +5816,8 @@ dnl We name that "man2html.tmp".
dnl
dnl The shell script can be removed later, e.g., using "make distclean".
AC_DEFUN([CF_WITH_MAN2HTML],[
-AC_REQUIRE([CF_PROG_GROFF])
+AC_REQUIRE([CF_PROG_GROFF])dnl
+AC_REQUIRE([AC_PROG_FGREP])dnl
case "x${with_man2html}" in
(xno)
@@ -5311,6 +5890,7 @@ export GROFF_NO_SGR
CF_EOF
+NROFF_OPTS=
if test "x$cf_with_groff" = xyes
then
MAN2HTML_NOTE="$GROFF_NOTE"
@@ -5319,6 +5899,16 @@ then
$SHELL -c "$TBL_PATH \${ROOT}.\${TYPE} | $GROFF_PATH -P -o0 -I\${ROOT}_ -Thtml -\${MACS}"
CF_EOF
else
+ # disable hyphenation if this is groff
+ if test "x$GROFF_PATH" != xno
+ then
+ AC_MSG_CHECKING(if nroff is really groff)
+ cf_check_groff="`$NROFF_PATH --version 2>/dev/null | grep groff`"
+ test -n "$cf_check_groff" && cf_check_groff=yes
+ test -n "$cf_check_groff" || cf_check_groff=no
+ AC_MSG_RESULT($cf_check_groff)
+ test "x$cf_check_groff" = xyes && NROFF_OPTS="-rHY=0"
+ fi
MAN2HTML_NOTE=""
CF_PATH_SYNTAX(cf_man2html)
MAN2HTML_PATH="$cf_man2html"
@@ -5333,10 +5923,10 @@ CF_EOF
LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
- cf_man2html_1st=`fgrep -n MARKER conftest.out |sed -e 's/^[[^0-9]]*://' -e 's/:.*//'`
- cf_man2html_top=`expr $cf_man2html_1st - 2`
- cf_man2html_bot=`wc -l conftest.out |sed -e 's/[[^0-9]]//g'`
- cf_man2html_bot=`expr $cf_man2html_bot - 2 - $cf_man2html_top`
+ cf_man2html_1st="`${FGREP-fgrep} -n MARKER conftest.out |sed -e 's/^[[^0-9]]*://' -e 's/:.*//'`"
+ cf_man2html_top=`expr "$cf_man2html_1st" - 2`
+ cf_man2html_bot="`wc -l conftest.out |sed -e 's/[[^0-9]]//g'`"
+ cf_man2html_bot=`expr "$cf_man2html_bot" - 2 - "$cf_man2html_top"`
cf_man2html_top_bot="-topm=$cf_man2html_top -botm=$cf_man2html_bot"
AC_MSG_RESULT($cf_man2html_top_bot)
@@ -5360,7 +5950,7 @@ CF_EOF
done
LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
- cf_man2html_page=`fgrep -n HEAD1 conftest.out |tail -n 1 |sed -e 's/^[[^0-9]]*://' -e 's/:.*//'`
+ cf_man2html_page="`${FGREP-fgrep} -n HEAD1 conftest.out |sed -n '$p' |sed -e 's/^[[^0-9]]*://' -e 's/:.*//'`"
test -z "$cf_man2html_page" && cf_man2html_page=99999
test "$cf_man2html_page" -gt 100 && cf_man2html_page=99999
@@ -5369,13 +5959,13 @@ CF_EOF
cat >>$MAN2HTML_TEMP <<CF_EOF
: \${MAN2HTML_PATH=$MAN2HTML_PATH}
-MAN2HTML_OPTS="\$MAN2HTML_OPTS -index -title="\$ROOT\(\$TYPE\)" -compress -pgsize $cf_man2html_page"
+MAN2HTML_OPTS="\$MAN2HTML_OPTS -index -title=\"\$ROOT(\$TYPE)\" -compress -pgsize $cf_man2html_page"
case \${TYPE} in
(ms)
- $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH -\${MACS} | \$MAN2HTML_PATH -topm=0 -botm=0 \$MAN2HTML_OPTS
+ $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH -topm=0 -botm=0 \$MAN2HTML_OPTS
;;
(*)
- $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH -\${MACS} | \$MAN2HTML_PATH $cf_man2html_top_bot \$MAN2HTML_OPTS
+ $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH $cf_man2html_top_bot \$MAN2HTML_OPTS
;;
esac
CF_EOF
@@ -5451,7 +6041,7 @@ CF_NCURSES_PTHREADS($cf_cv_screen)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WITH_NO_LEAKS version: 3 updated: 2015/05/10 19:52:14
+dnl CF_WITH_NO_LEAKS version: 4 updated: 2021/01/05 20:08:11
dnl ----------------
AC_DEFUN([CF_WITH_NO_LEAKS],[
@@ -5469,8 +6059,10 @@ AC_ARG_WITH(no-leaks,
(*yes*) ;;
(*) AC_DEFINE(DOALLOC,10000,[Define to size of malloc-array]) ;;
esac
- with_no_leaks=yes],
- [with_no_leaks=])
+ enable_leaks=no],
+ [enable_leaks=yes])
+dnl TODO - drop with_no_leaks
+if test "x$enable_leaks" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
AC_MSG_RESULT($with_no_leaks)
])dnl
dnl ---------------------------------------------------------------------------
@@ -5509,6 +6101,23 @@ ifelse($1,,[
])
])dnl
dnl ---------------------------------------------------------------------------
+dnl CF_WITH_SCREEN_PDCURSES version: 1 updated: 2020/08/28 16:56:27
+dnl -----------------------
+dnl Call this macro before CF_ENABLE_WARNINGS for configure scripts which use
+dnl the "--with-screen=pdcurses" selection. Doing that allows the configure
+dnl script to search for the X11/Xt header files to declare (or not) the
+dnl symbol needed to enable "const" in those header files. If that configure
+dnl option is not used, then those checks are unnecessary.
+AC_DEFUN([CF_WITH_SCREEN_PDCURSES],[
+AC_PROVIDE([AC_PATH_XTRA])
+AC_PROVIDE([AC_PATH_X])
+if test -n "$with_screen" && test "x$with_screen" = "xpdcurses"
+then
+ AC_PATH_X
+ AC_PATH_XTRA
+fi
+])dnl
+dnl ---------------------------------------------------------------------------
dnl CF_WITH_SHARED_OR_LIBTOOL version: 7 updated: 2014/11/02 16:11:49
dnl -------------------------
dnl Provide shared libraries using either autoconf macros (--with-shared) or
@@ -5601,7 +6210,7 @@ CF_NO_LEAKS_OPTION(valgrind,
[USE_VALGRIND])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WITH_VERSIONED_SYMS version: 7 updated: 2015/10/24 20:50:26
+dnl CF_WITH_VERSIONED_SYMS version: 10 updated: 2021/01/04 18:48:01
dnl ----------------------
dnl Use this when building shared library with ELF, to markup symbols with the
dnl version identifier from the given input file. Generally that identifier is
@@ -5609,17 +6218,29 @@ dnl the same as the SONAME at which the symbol was first introduced.
dnl
dnl $1 = basename of the ".map" file (default $PACKAGE)
AC_DEFUN([CF_WITH_VERSIONED_SYMS],
-[
+[AC_REQUIRE([AC_PROG_FGREP])dnl
+AC_REQUIRE([AC_PROG_EGREP])dnl
+
AC_MSG_CHECKING(if versioned-symbols file should be used)
AC_ARG_WITH(versioned-syms,
[ --with-versioned-syms=X markup versioned symbols using ld],
[with_versioned_syms=$withval],
[with_versioned_syms=no])
-if test "x$with_versioned_syms" = xyes
-then
+case "x$with_versioned_syms" in
+(xyes)
with_versioned_syms='${top_srcdir}/package/ifelse($1,,${PACKAGE},[$1]).map'
AC_SUBST(PACKAGE)
-fi
+ ;;
+(xno)
+ ;;
+(x/*)
+ test -f "$with_versioned_syms" || AC_MSG_ERROR(expected a filename: $with_versioned_syms)
+ ;;
+(*)
+ test -f "$with_versioned_syms" || AC_MSG_ERROR(expected a filename: $with_versioned_syms)
+ with_versioned_syms=`pwd`/"$with_versioned_syms"
+ ;;
+esac
AC_MSG_RESULT($with_versioned_syms)
RESULTING_SYMS=
@@ -5716,7 +6337,7 @@ EOF
if make -f conftest.mk 2>&AC_FD_CC >/dev/null
then
# test for missing symbol in either Data or Text section
- cf_missing=`nm -P conftest.so 2>&AC_FD_CC |fgrep _ismissing | egrep '[[ ]][[DT]][[ ]]'`
+ cf_missing="`nm -P conftest.so 2>&AC_FD_CC |${FGREP-fgrep} _ismissing | ${EGREP-egrep} '[[ ]][[DT]][[ ]]'`"
test -n "$cf_missing" && WILDCARD_SYMS=yes
fi
AC_MSG_RESULT($WILDCARD_SYMS)
@@ -5728,30 +6349,7 @@ AC_SUBST(VERSIONED_SYMS)
AC_SUBST(WILDCARD_SYMS)
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_WITH_WARNINGS version: 5 updated: 2004/07/23 14:40:34
-dnl ----------------
-dnl Combine the checks for gcc features into a configure-script option
-dnl
-dnl Parameters:
-dnl $1 - see CF_GCC_WARNINGS
-AC_DEFUN([CF_WITH_WARNINGS],
-[
-if ( test "$GCC" = yes || test "$GXX" = yes )
-then
-AC_MSG_CHECKING(if you want to check for gcc warnings)
-AC_ARG_WITH(warnings,
- [ --with-warnings test: turn on gcc warnings],
- [cf_opt_with_warnings=$withval],
- [cf_opt_with_warnings=no])
-AC_MSG_RESULT($cf_opt_with_warnings)
-if test "$cf_opt_with_warnings" != no ; then
- CF_GCC_ATTRIBUTES
- CF_GCC_WARNINGS([$1])
-fi
-fi
-])dnl
-dnl ---------------------------------------------------------------------------
-dnl CF_XOPEN_CURSES version: 14 updated: 2018/06/20 20:23:13
+dnl CF_XOPEN_CURSES version: 16 updated: 2021/01/02 09:31:20
dnl ---------------
dnl Test if we should define X/Open source for curses, needed on Digital Unix
dnl 4.x, to see the extended functions, but breaks on IRIX 6.x.
@@ -5777,7 +6375,14 @@ AC_TRY_LINK([
#endif
long x = winnstr(stdscr, "", 0);
int x1, y1;
- getbegyx(stdscr, y1, x1)],
+#ifdef NCURSES_VERSION
+ (void)check2;
+#endif
+ getbegyx(stdscr, y1, x1);
+ (void)x;
+ (void)y1;
+ (void)x1;
+ ],
[cf_cv_need_xopen_extension=none],
[
for cf_try_xopen_extension in _XOPEN_SOURCE_EXTENDED NCURSES_WIDECHAR
@@ -5792,13 +6397,20 @@ AC_TRY_LINK([
#endif
long x = winnstr(stdscr, "", 0);
int x1, y1;
- getbegyx(stdscr, y1, x1)],
+ getbegyx(stdscr, y1, x1);
+#ifdef NCURSES_VERSION
+ (void)check2;
+#endif
+ (void)x;
+ (void)y1;
+ (void)x1;
+ ],
[cf_cv_need_xopen_extension=$cf_try_xopen_extension; break])
done
])
])
-case $cf_cv_need_xopen_extension in
+case "$cf_cv_need_xopen_extension" in
(*_*)
CF_APPEND_TEXT(CPPFLAGS,-D$cf_cv_need_xopen_extension)
;;
@@ -5806,7 +6418,7 @@ esac
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_XOPEN_SOURCE version: 53 updated: 2018/06/16 18:58:58
+dnl CF_XOPEN_SOURCE version: 57 updated: 2021/01/01 16:53:59
dnl ---------------
dnl Try to get _XOPEN_SOURCE defined properly that we can use POSIX functions,
dnl or adapt to the vendor's definitions to get equivalent functionality,
@@ -5817,12 +6429,15 @@ dnl $1 is the nominal value for _XOPEN_SOURCE
dnl $2 is the nominal value for _POSIX_C_SOURCE
AC_DEFUN([CF_XOPEN_SOURCE],[
AC_REQUIRE([AC_CANONICAL_HOST])
+AC_REQUIRE([CF_POSIX_VISIBLE])
+
+if test "$cf_cv_posix_visible" = no; then
cf_XOPEN_SOURCE=ifelse([$1],,500,[$1])
cf_POSIX_C_SOURCE=ifelse([$2],,199506L,[$2])
cf_xopen_source=
-case $host_os in
+case "$host_os" in
(aix[[4-7]]*)
cf_xopen_source="-D_ALL_SOURCE"
;;
@@ -5836,7 +6451,7 @@ case $host_os in
cf_xopen_source="-D_DARWIN_C_SOURCE"
cf_XOPEN_SOURCE=
;;
-(freebsd*|dragonfly*)
+(freebsd*|dragonfly*|midnightbsd*)
# 5.x headers associate
# _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
# _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
@@ -5915,7 +6530,7 @@ make an error
[cf_XOPEN_SOURCE_set=yes],
[cf_XOPEN_SOURCE_set=no])
AC_MSG_RESULT($cf_XOPEN_SOURCE_set)
- if test $cf_XOPEN_SOURCE_set = yes
+ if test "$cf_XOPEN_SOURCE_set" = yes
then
AC_TRY_COMPILE([#include <stdlib.h>],[
#if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
@@ -5923,7 +6538,7 @@ make an error
#endif],
[cf_XOPEN_SOURCE_set_ok=yes],
[cf_XOPEN_SOURCE_set_ok=no])
- if test $cf_XOPEN_SOURCE_set_ok = no
+ if test "$cf_XOPEN_SOURCE_set_ok" = no
then
AC_MSG_WARN(_XOPEN_SOURCE is lower than requested)
fi
@@ -5931,9 +6546,10 @@ make an error
CF_TRY_XOPEN_SOURCE
fi
fi
+fi # cf_cv_posix_visible
])
dnl ---------------------------------------------------------------------------
-dnl CF_X_ATHENA version: 23 updated: 2015/04/12 15:39:00
+dnl CF_X_ATHENA version: 24 updated: 2020/03/10 18:53:47
dnl -----------
dnl Check for Xaw (Athena) libraries
dnl
@@ -6009,7 +6625,8 @@ AC_CACHE_CHECK(for usable $cf_x_athena/Xmu package,cf_cv_xaw_compat,[
AC_TRY_LINK([
#include <X11/Xmu/CharSet.h>
],[
-int check = XmuCompareISOLatin1("big", "small")
+int check = XmuCompareISOLatin1("big", "small");
+(void)check;
],[cf_cv_xaw_compat=yes],[cf_cv_xaw_compat=no])])
if test "$cf_cv_xaw_compat" = no
@@ -6045,12 +6662,13 @@ if test -z "$cf_x_athena_lib" ; then
fi
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_X_ATHENA_CPPFLAGS version: 6 updated: 2018/06/20 20:23:13
+dnl CF_X_ATHENA_CPPFLAGS version: 9 updated: 2020/12/31 10:54:15
dnl --------------------
dnl Normally invoked by CF_X_ATHENA, with $1 set to the appropriate flavor of
dnl the Athena widgets, e.g., Xaw, Xaw3d, neXtaw.
AC_DEFUN([CF_X_ATHENA_CPPFLAGS],
[
+AC_REQUIRE([AC_PATH_XTRA])
cf_x_athena_root=ifelse([$1],,Xaw,[$1])
cf_x_athena_inc=""
@@ -6061,10 +6679,9 @@ for cf_path in default \
/usr/local
do
if test -z "$cf_x_athena_inc" ; then
- cf_save="$CPPFLAGS"
+ CF_SAVE_XTRA_FLAGS([CF_X_ATHENA_CPPFLAGS])
cf_test=X11/$cf_x_athena_root/SimpleMenu.h
- if test $cf_path != default ; then
- CPPFLAGS="$cf_save"
+ if test "$cf_path" != default ; then
CF_APPEND_TEXT(CPPFLAGS,-I$cf_path/include)
AC_MSG_CHECKING(for $cf_test in $cf_path)
else
@@ -6076,24 +6693,23 @@ do
[cf_result=yes],
[cf_result=no])
AC_MSG_RESULT($cf_result)
+ CF_RESTORE_XTRA_FLAGS([CF_X_ATHENA_CPPFLAGS])
if test "$cf_result" = yes ; then
- cf_x_athena_inc=$cf_path
+ test "$cf_path" = default && cf_x_athena_inc=default
+ test "$cf_path" != default && cf_x_athena_inc="$cf_path/include"
break
- else
- CPPFLAGS="$cf_save"
fi
fi
done
if test -z "$cf_x_athena_inc" ; then
- AC_MSG_WARN(
-[Unable to successfully find Athena header files with test program])
+ AC_MSG_WARN([Unable to find Athena header files])
elif test "$cf_x_athena_inc" != default ; then
CF_APPEND_TEXT(CPPFLAGS,-I$cf_x_athena_inc)
fi
])
dnl ---------------------------------------------------------------------------
-dnl CF_X_ATHENA_LIBS version: 12 updated: 2011/07/17 19:55:02
+dnl CF_X_ATHENA_LIBS version: 13 updated: 2020/01/11 18:16:10
dnl ----------------
dnl Normally invoked by CF_X_ATHENA, with $1 set to the appropriate flavor of
dnl the Athena widgets, e.g., Xaw, Xaw3d, neXtaw.
@@ -6118,29 +6734,26 @@ do
"-l$cf_lib -lXpm -lXmu" \
"-l${cf_lib}_s -lXmu_s"
do
- if test -z "$cf_x_athena_lib" ; then
- cf_save="$LIBS"
- cf_test=XawSimpleMenuAddGlobalActions
- if test $cf_path != default ; then
- CF_ADD_LIBS(-L$cf_path/lib $cf_libs)
- AC_MSG_CHECKING(for $cf_libs in $cf_path)
- else
- CF_ADD_LIBS($cf_libs)
- AC_MSG_CHECKING(for $cf_test in $cf_libs)
- fi
- AC_TRY_LINK([
+ test -n "$cf_x_athena_lib" && break
+
+ CF_SAVE_XTRA_FLAGS([CF_X_ATHENA_LIBS])
+ cf_test=XawSimpleMenuAddGlobalActions
+ test "$cf_path" != default && cf_libs="-L$cf_path/lib $cf_libs"
+ CF_ADD_LIBS($cf_libs)
+ AC_MSG_CHECKING(for $cf_test in $cf_libs)
+ AC_TRY_LINK([
#include <X11/Intrinsic.h>
#include <X11/$cf_x_athena_root/SimpleMenu.h>
],[
$cf_test((XtAppContext) 0)],
- [cf_result=yes],
- [cf_result=no])
- AC_MSG_RESULT($cf_result)
- if test "$cf_result" = yes ; then
- cf_x_athena_lib="$cf_libs"
- break
- fi
- LIBS="$cf_save"
+ [cf_result=yes],
+ [cf_result=no])
+ AC_MSG_RESULT($cf_result)
+ CF_RESTORE_XTRA_FLAGS([CF_X_ATHENA_LIBS])
+
+ if test "$cf_result" = yes ; then
+ cf_x_athena_lib="$cf_libs"
+ break
fi
done # cf_libs
test -n "$cf_x_athena_lib" && break
@@ -6152,6 +6765,7 @@ if test -z "$cf_x_athena_lib" ; then
[Unable to successfully link Athena library (-l$cf_x_athena_root) with test program])
fi
+CF_ADD_LIBS($cf_x_athena_lib)
CF_UPPER(cf_x_athena_LIBS,HAVE_LIB_$cf_x_athena)
AC_DEFINE_UNQUOTED($cf_x_athena_LIBS)
])
@@ -6164,7 +6778,7 @@ CF_TRY_PKG_CONFIG(Xext,,[
[CF_ADD_LIB(Xext)])])
])dnl
dnl ---------------------------------------------------------------------------
-dnl CF_X_TOOLKIT version: 23 updated: 2015/04/12 15:39:00
+dnl CF_X_TOOLKIT version: 26 updated: 2021/01/02 09:31:20
dnl ------------
dnl Check for X Toolkit libraries
AC_DEFUN([CF_X_TOOLKIT],
@@ -6172,7 +6786,7 @@ AC_DEFUN([CF_X_TOOLKIT],
AC_REQUIRE([AC_PATH_XTRA])
AC_REQUIRE([CF_CHECK_CACHE])
-# OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new), and (and
+# OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new) (and
# in some cases has installed dummy files in the former, other cases replaced
# it with a link to the new location). This complicates the configure script.
# Check for that pitfall, and recover using pkg-config
@@ -6184,6 +6798,8 @@ then
CF_TRY_PKG_CONFIG(ice,,[AC_MSG_WARN(unable to find ICE library)])
CF_TRY_PKG_CONFIG(sm,,[AC_MSG_WARN(unable to find SM library)])
CF_TRY_PKG_CONFIG(xt,,[AC_MSG_WARN(unable to find Xt library)])
+else
+ LIBS="$X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
fi
cf_have_X_LIBS=no
@@ -6216,7 +6832,7 @@ AC_TRY_LINK([
AC_CACHE_CHECK(for usable X Toolkit package,cf_cv_xt_ice_compat,[
AC_TRY_LINK([
#include <X11/Shell.h>
-],[int num = IceConnectionNumber(0)
+],[int num = IceConnectionNumber(0); (void) num
],[cf_cv_xt_ice_compat=yes],[cf_cv_xt_ice_compat=no])])
if test "$cf_cv_xt_ice_compat" = no
@@ -6246,18 +6862,16 @@ AC_TRY_LINK([
AC_CHECK_FUNC(XOpenDisplay,,[
AC_CHECK_LIB(X11,XOpenDisplay,
- [CF_ADD_LIB(X11)],,
- [$X_PRE_LIBS $LIBS $X_EXTRA_LIBS])])
+ [CF_ADD_LIB(X11)])])
AC_CHECK_FUNC(XtAppInitialize,,[
AC_CHECK_LIB(Xt, XtAppInitialize,
[AC_DEFINE(HAVE_LIBXT,1,[Define to 1 if we can compile with the Xt library])
cf_have_X_LIBS=Xt
- LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"],,
- [$X_PRE_LIBS $LIBS $X_EXTRA_LIBS])])
+ LIBS="-lXt $LIBS"])])
])
-if test $cf_have_X_LIBS = no ; then
+if test "$cf_have_X_LIBS" = no ; then
AC_MSG_WARN(
[Unable to successfully link X Toolkit library (-lXt) with
test program. You will have to check and add the proper libraries by hand
diff --git a/argv.c b/argv.c
index 46acfa6c7bea..e5dc4c8894bc 100644
--- a/argv.c
+++ b/argv.c
@@ -1,9 +1,9 @@
/*
- * $Id: argv.c,v 1.12 2018/06/12 22:47:23 tom Exp $
+ * $Id: argv.c,v 1.13 2020/03/26 02:55:37 tom Exp $
*
* argv - Reusable functions for argv-parsing.
*
- * Copyright 2011-2017,2018 Thomas E. Dickey
+ * Copyright 2011-2018,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -60,37 +60,38 @@ dlg_string_to_argv(char *blob)
for (pass = 0; pass < 2; ++pass) {
bool inparm = FALSE;
bool quoted = FALSE;
- bool escape = FALSE;
char *param = blob;
size_t count = 0;
for (n = 0; n < length; ++n) {
- if (escape) {
- ;
- } else if (quoted && blob[n] == '"') {
+ if (quoted && blob[n] == '"') {
quoted = FALSE;
} else if (blob[n] == '"') {
quoted = TRUE;
if (!inparm) {
- if (pass)
+ if (pass) {
result[count] = param;
+ }
++count;
inparm = TRUE;
}
} else if (!quoted && isspace(UCH(blob[n]))) {
if (inparm) {
if (pass) {
- *param++ = '\0';
+ *param = '\0';
}
+ ++param;
inparm = FALSE;
}
} else {
if (blob[n] == '\\') {
- if (n + 1 == length) {
+ size_t n1 = (n + 1);
+ bool ignore = FALSE;
+ if (n1 == length) {
break; /* The string is terminated by a backslash */
- } else if ((blob[n + 1] == '\\') ||
- (blob[n + 1] == '"') ||
- (!quoted && blob[n + 1] == '\n')) {
+ } else if ((blob[n1] == '\\') ||
+ (blob[n1] == '"') ||
+ (ignore = (blob[n1] == '\n'))) {
/* eat the backslash */
if (pass) {
--length;
@@ -98,33 +99,35 @@ dlg_string_to_argv(char *blob)
blob[k] = blob[k + 1];
blob[length] = '\0';
} else {
- escape = TRUE;
- continue;
+ ++param; /* pretend I ate it */
}
+ if (ignore)
+ continue;
}
}
if (!inparm) {
- if (pass)
+ if (pass) {
result[count] = param;
+ }
++count;
inparm = TRUE;
}
if (pass) {
- *param++ = blob[n];
+ *param = blob[n];
}
+ ++param;
}
- escape = FALSE;
}
- if (!pass) {
+ if (pass) {
+ *param = '\0';
+ } else {
if (count) {
result = dlg_calloc(char *, count + 1);
assert_ptr(result, "string_to_argv");
} else {
break; /* no tokens found */
}
- } else {
- *param = '\0';
}
}
#ifdef HAVE_DLG_TRACE
diff --git a/arrows.c b/arrows.c
index 28f681a0379b..b8bf6c69e61c 100644
--- a/arrows.c
+++ b/arrows.c
@@ -1,9 +1,9 @@
/*
- * $Id: arrows.c,v 1.52 2018/06/18 22:10:54 tom Exp $
+ * $Id: arrows.c,v 1.53 2019/07/24 23:04:14 tom Exp $
*
* arrows.c -- draw arrows to indicate end-of-range for lists
*
- * Copyright 2000-2013,2018 Thomas E. Dickey
+ * Copyright 2000-2018,2019 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -70,7 +70,6 @@ merge_colors(chtype foreground, chtype background)
void
dlg_draw_helpline(WINDOW *win, bool decorations)
{
- int cur_x, cur_y;
int bottom;
if (dialog_vars.help_line != 0
@@ -83,6 +82,8 @@ dlg_draw_helpline(WINDOW *win, bool decorations)
int limit = dlg_count_real_columns(dialog_vars.help_line) + 2;
if (limit < avail) {
+ int cur_x, cur_y;
+
getyx(win, cur_y, cur_x);
other = decorations ? ON_LEFT : 0;
(void) wmove(win, bottom, other + (avail - limit) / 2);
@@ -165,9 +166,6 @@ dlg_draw_scrollbar(WINDOW *win,
chtype attr,
chtype borderattr)
{
- char buffer[80];
- int percent;
- int len;
int oldy, oldx;
chtype save = dlg_get_attrs(win);
@@ -178,6 +176,10 @@ dlg_draw_scrollbar(WINDOW *win,
dlg_draw_helpline(win, TRUE);
if (bottom_arrow || top_arrow || dialog_state.use_scrollbar) {
+ char buffer[80];
+ int percent;
+ int len;
+
percent = (!total_data
? 100
: (int) ((next_data * 100)
@@ -209,7 +211,6 @@ dlg_draw_scrollbar(WINDOW *win,
int all_diff = (int) (total_data + 1);
int bar_diff = (int) (next_data + 1 - this_data);
int bar_high;
- int bar_y;
bar_high = ORDSIZE(bar_diff);
if (bar_high <= 0)
@@ -217,6 +218,7 @@ dlg_draw_scrollbar(WINDOW *win,
if (bar_high < all_high) {
int bar_last = BARSIZE(next_data);
+ int bar_y;
wmove(win, top + 1, right);
diff --git a/buildlist.c b/buildlist.c
index 639056ff25b6..e21700e7c8ae 100644
--- a/buildlist.c
+++ b/buildlist.c
@@ -1,9 +1,9 @@
/*
- * $Id: buildlist.c,v 1.83 2018/06/19 22:57:01 tom Exp $
+ * $Id: buildlist.c,v 1.94 2020/11/23 00:37:17 tom Exp $
*
* buildlist.c -- implements the buildlist dialog
*
- * Copyright 2012-2017,2018 Thomas E. Dickey
+ * Copyright 2012-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -21,7 +21,7 @@
* Boston, MA 02110, USA.
*/
-#include <dialog.h>
+#include <dlg_internals.h>
#include <dlg_keys.h>
/*
@@ -77,9 +77,10 @@ index2row(ALL_DATA * all, int choice, int selected)
{
MY_DATA *data = all->list + selected;
int result = -1;
- int row;
if (okIndex(all, choice)) {
+ int row;
+
for (row = 0; row < all->item_no; ++row) {
TRACE(("!... choice %d: %p vs row %d: %p\n",
choice, all->items + choice,
@@ -270,9 +271,10 @@ first_item(ALL_DATA * all, int selected)
{
MY_DATA *data = all->list + selected;
int result = -1;
- int n;
if (myItem(data, 0) != 0) {
+ int n;
+
for (n = 0; n < all->item_no; ++n) {
if (myItem(data, 0) == &all->items[n]) {
result = n;
@@ -309,9 +311,10 @@ skip_rows(ALL_DATA * all, int row, int skip, int selected)
{
MY_DATA *data = all->list + selected;
int result = row;
- int n;
if (skip > 0) {
+ int n;
+
for (n = row + 1; (n < all->item_no) && (n <= row + skip); ++n) {
if (myItem(data, n) == 0)
break;
@@ -550,11 +553,10 @@ dlg_buildlist(const char *title,
ALL_DATA all;
MY_DATA *data = all.list;
int i, j, k, key2, found, x, y, cur_x, cur_y;
- int key = 0, fkey;
+ int key, fkey;
bool save_visit = dialog_state.visit_items;
int button;
int cur_item;
- int was_mouse;
int name_width, text_width, full_width, list_width;
int result = DLG_EXIT_UNKNOWN;
int num_states;
@@ -650,8 +652,7 @@ dlg_buildlist(const char *title,
* After displaying the prompt, we know how much space we really have.
* Limit the list to avoid overwriting the ok-button.
*/
- if (all.use_height + MIN_HIGH > height - cur_y)
- all.use_height = height - MIN_HIGH - cur_y;
+ all.use_height = height - MIN_HIGH - cur_y;
if (all.use_height <= 0)
all.use_height = 1;
@@ -742,6 +743,7 @@ dlg_buildlist(const char *title,
int at_top = index2row(&all, moi->top_index, which);
int at_end = index2row(&all, -1, which);
int at_bot = skip_rows(&all, at_top, all.use_height, which);
+ int was_mouse;
DLG_TRACE(("# ** state %d:%d top %d (%d:%d:%d) %s\n",
cur_item, item_no - 1,
@@ -769,8 +771,10 @@ dlg_buildlist(const char *title,
}
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
was_mouse = (fkey && is_DLGK_MOUSE(key));
if (was_mouse)
@@ -1090,6 +1094,9 @@ dlg_buildlist(const char *title,
case DLGK_ENTER:
result = dlg_enter_buttoncode(button);
break;
+ case DLGK_LEAVE:
+ result = dlg_ok_buttoncode(button);
+ break;
#ifdef KEY_RESIZE
case KEY_RESIZE:
dlg_will_resize(dialog);
@@ -1097,9 +1104,7 @@ dlg_buildlist(const char *title,
height = old_height;
width = old_width;
free(prompt);
- dlg_clear();
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
/* repaint */
first = TRUE;
goto retry;
@@ -1113,7 +1118,7 @@ dlg_buildlist(const char *title,
beep();
}
}
- } else {
+ } else if (key > 0) {
beep();
}
}
@@ -1232,7 +1237,6 @@ dialog_buildlist(const char *title,
if ((show_status = dialog_vars.help_status)) {
if (separate_output) {
dlg_add_string(help_result);
- dlg_add_separator();
} else {
dlg_add_quoted(help_result);
}
@@ -1245,17 +1249,16 @@ dialog_buildlist(const char *title,
if (show_status) {
for (i = 0; i < item_no; i++) {
if (listitems[i].state) {
+ if (dlg_need_separator())
+ dlg_add_separator();
if (separate_output) {
dlg_add_string(listitems[i].name);
- dlg_add_separator();
} else {
- if (dlg_need_separator())
- dlg_add_separator();
dlg_add_quoted(listitems[i].name);
}
}
}
- dlg_add_last_key(-1);
+ AddLastKey();
}
dlg_free_columns(&listitems[0].text, (int) sizeof(DIALOG_LISTITEM), item_no);
diff --git a/buttons.c b/buttons.c
index b22f64158988..1a9c87ee67a5 100644
--- a/buttons.c
+++ b/buttons.c
@@ -1,9 +1,9 @@
/*
- * $Id: buttons.c,v 1.99 2018/06/18 22:11:16 tom Exp $
+ * $Id: buttons.c,v 1.106 2021/01/17 17:03:16 tom Exp $
*
* buttons.c -- draw buttons, e.g., OK/Cancel
*
- * Copyright 2000-2017,2018 Thomas E. Dickey
+ * Copyright 2000-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -35,11 +35,11 @@ static void
center_label(char *buffer, int longest, const char *label)
{
int len = dlg_count_columns(label);
- int left = 0, right = 0;
+ int right = 0;
*buffer = 0;
if (len < longest) {
- left = (longest - len) / 2;
+ int left = (longest - len) / 2;
right = (longest - len - left);
if (left > 0)
sprintf(buffer, "%*s", left, " ");
@@ -60,14 +60,16 @@ string_to_char(const char **stringp)
#ifdef USE_WIDE_CURSES
const char *string = *stringp;
size_t have = strlen(string);
- size_t check;
size_t len;
wchar_t cmp2[2];
mbstate_t state;
memset(&state, 0, sizeof(state));
len = mbrlen(string, have, &state);
+
if ((int) len > 0 && len <= have) {
+ size_t check;
+
memset(&state, 0, sizeof(state));
memset(cmp2, 0, sizeof(cmp2));
check = mbrtowc(cmp2, string, len, &state);
@@ -132,9 +134,10 @@ get_hotkeys(const char **labels)
{
int *result = 0;
size_t count = count_labels(labels);
- size_t n;
if ((result = dlg_calloc(int, count + 1)) != 0) {
+ size_t n;
+
for (n = 0; n < count; ++n) {
const char *label = labels[n];
const int *indx = dlg_index_wchars(label);
@@ -222,7 +225,9 @@ print_button(WINDOW *win, char *label, int hotkey, int y, int x, int selected)
? button_active_attr
: button_inactive_attr);
(void) waddstr(win, ">");
- (void) wmove(win, y, x + ((int) (strspn) (label, " ")) + 1);
+ if (!dialog_vars.cursor_off_label) {
+ (void) wmove(win, y, x + ((int) (strspn) (label, " ")) + 1);
+ }
}
/*
@@ -281,12 +286,13 @@ dlg_button_x_step(const char **labels, int limit, int *gap, int *margin, int *st
int count = dlg_button_count(labels);
int longest;
int length;
- int unused;
- int used;
int result;
*margin = 0;
if (count != 0) {
+ int unused;
+ int used;
+
dlg_button_sizes(labels, FALSE, &longest, &length);
used = (length + (count * 2));
unused = limit - used;
@@ -312,10 +318,11 @@ dlg_button_x_step(const char **labels, int limit, int *gap, int *margin, int *st
void
dlg_button_layout(const char **labels, int *limit)
{
- int width = 1;
int gap, margin, step;
if (labels != 0 && dlg_button_count(labels)) {
+ int width = 1;
+
while (!dlg_button_x_step(labels, width, &gap, &margin, &step))
++width;
width += (4 * MARGIN);
@@ -338,7 +345,6 @@ dlg_draw_buttons(WINDOW *win,
int limit)
{
chtype save = dlg_get_attrs(win);
- int n;
int step = 0;
int length;
int longest;
@@ -347,7 +353,6 @@ dlg_draw_buttons(WINDOW *win,
int gap;
int margin;
size_t need;
- char *buffer;
dlg_mouse_setbase(getbegx(win), getbegy(win));
@@ -368,7 +373,10 @@ dlg_draw_buttons(WINDOW *win,
*/
need = (size_t) longest;
if (need != 0) {
+ char *buffer;
+ int n;
int *hotkeys = get_hotkeys(labels);
+
assert_ptr(hotkeys, "dlg_draw_buttons");
for (n = 0; labels[n] != 0; ++n) {
@@ -414,19 +422,21 @@ dlg_draw_buttons(WINDOW *win,
int
dlg_match_char(int ch, const char *string)
{
- if (string != 0) {
- int cmp2 = string_to_char(&string);
+ if (!dialog_vars.no_hot_list) {
+ if (string != 0) {
+ int cmp2 = string_to_char(&string);
#ifdef USE_WIDE_CURSES
- wint_t cmp1 = dlg_toupper(ch);
- if (cmp2 != 0 && (wchar_t) cmp1 == (wchar_t) dlg_toupper(cmp2)) {
- return TRUE;
- }
-#else
- if (ch > 0 && ch < 256) {
- if (dlg_toupper(ch) == dlg_toupper(cmp2))
+ wint_t cmp1 = dlg_toupper(ch);
+ if (cmp2 != 0 && (wchar_t) cmp1 == (wchar_t) dlg_toupper(cmp2)) {
return TRUE;
- }
+ }
+#else
+ if (ch > 0 && ch < 256) {
+ if (dlg_toupper(ch) == dlg_toupper(cmp2))
+ return TRUE;
+ }
#endif
+ }
}
return FALSE;
}
@@ -441,8 +451,9 @@ dlg_button_to_char(const char *label)
int cmp = -1;
while (*label != 0) {
- cmp = string_to_char(&label);
- if (dlg_isupper(cmp)) {
+ int ch = string_to_char(&label);
+ if (dlg_isupper(ch)) {
+ cmp = ch;
break;
}
}
@@ -461,11 +472,12 @@ dlg_char_to_button(int ch, const char **labels)
if (labels != 0) {
int *hotkeys = get_hotkeys(labels);
- int j;
ch = (int) dlg_toupper(dlg_last_getc());
if (hotkeys != 0) {
+ int j;
+
for (j = 0; labels[j] != 0; ++j) {
if (ch == hotkeys[j]) {
dlg_flush_getc();
@@ -586,23 +598,42 @@ dlg_exit_buttoncode(int button)
return result;
}
+static const char **
+finish_ok_label(const char **labels, int n)
+{
+ if (n == 0) {
+ labels[n++] = my_ok_label();
+ dialog_vars.nook = FALSE;
+ dlg_trace_msg("# ignore --nook, since at least one button is needed\n");
+ }
+
+ labels[n] = NULL;
+ return labels;
+}
+
+/*
+ * Return a list of button labels for the OK (no Cancel) group, used in msgbox
+ * and progressbox.
+ */
const char **
dlg_ok_label(void)
{
static const char *labels[4];
int n = 0;
- labels[n++] = my_ok_label();
+ if (!dialog_vars.nook)
+ labels[n++] = my_ok_label();
if (dialog_vars.extra_button)
labels[n++] = my_extra_label();
if (dialog_vars.help_button)
labels[n++] = my_help_label();
- labels[n] = 0;
- return labels;
+
+ return finish_ok_label(labels, n);
}
/*
- * Return a list of button labels for the OK/Cancel group.
+ * Return a list of button labels for the OK/Cancel group, used in most widgets
+ * that select an option or data.
*/
const char **
dlg_ok_labels(void)
@@ -618,8 +649,8 @@ dlg_ok_labels(void)
labels[n++] = my_cancel_label();
if (dialog_vars.help_button)
labels[n++] = my_help_label();
- labels[n] = 0;
- return labels;
+
+ return finish_ok_label(labels, n);
}
/*
@@ -640,7 +671,8 @@ dlg_ok_buttoncode(int button)
} else if (dialog_vars.help_button && (button == n)) {
result = DLG_EXIT_HELP;
}
- DLG_TRACE(("# dlg_ok_buttoncode(%d) = %d\n", button, result));
+ DLG_TRACE(("# dlg_ok_buttoncode(%d) = %d:%s\n",
+ button, result, dlg_exitcode2s(result)));
return result;
}
@@ -702,10 +734,11 @@ dlg_defaultno_button(void)
int
dlg_default_button(void)
{
- int i, n;
int result = 0;
if (dialog_vars.default_button >= 0) {
+ int i, n;
+
for (i = 0; (n = dlg_ok_buttoncode(i)) >= 0; i++) {
if (n == dialog_vars.default_button) {
result = i;
diff --git a/calendar.c b/calendar.c
index 497533b3dbbd..0caff60072c5 100644
--- a/calendar.c
+++ b/calendar.c
@@ -1,9 +1,9 @@
/*
- * $Id: calendar.c,v 1.97 2018/06/19 22:57:01 tom Exp $
+ * $Id: calendar.c,v 1.106 2020/11/23 09:03:49 tom Exp $
*
* calendar.c -- implements the calendar box
*
- * Copyright 2001-2017,2018 Thomas E. Dickey
+ * Copyright 2001-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -21,7 +21,7 @@
* Boston, MA 02110, USA.
*/
-#include <dialog.h>
+#include <dlg_internals.h>
#include <dlg_keys.h>
#include <time.h>
@@ -75,16 +75,6 @@ static const char *
nameOfDayOfWeek(int n)
{
static bool shown[MAX_DAYS];
- static const char *posix_days[MAX_DAYS] =
- {
- "Sunday",
- "Monday",
- "Tuesday",
- "Wednesday",
- "Thursday",
- "Friday",
- "Saturday"
- };
while (n < 0) {
n += MAX_DAYS;
@@ -101,7 +91,17 @@ nameOfDayOfWeek(int n)
}
#endif
if (cached_days[n] == 0) {
- size_t len, limit = MON_WIDE - 1;
+ static const char *posix_days[MAX_DAYS] =
+ {
+ "Sunday",
+ "Monday",
+ "Tuesday",
+ "Wednesday",
+ "Thursday",
+ "Friday",
+ "Saturday"
+ };
+ size_t limit = MON_WIDE - 1;
char *value = dlg_strclone(posix_days[n]);
/*
@@ -111,7 +111,7 @@ nameOfDayOfWeek(int n)
* double-width cell. For now (2016/01/26), handle too-long names only
* for POSIX values.
*/
- if ((len = strlen(value)) > limit)
+ if (strlen(value) > limit)
value[limit] = '\0';
cached_days[n] = value;
}
@@ -126,21 +126,6 @@ static const char *
nameOfMonth(int n)
{
static bool shown[MAX_MONTHS];
- static const char *posix_mons[MAX_MONTHS] =
- {
- "January",
- "February",
- "March",
- "April",
- "May",
- "June",
- "July",
- "August",
- "September",
- "October",
- "November",
- "December"
- };
while (n < 0) {
n += MAX_MONTHS;
@@ -158,6 +143,21 @@ nameOfMonth(int n)
}
#endif
if (cached_months[n] == 0) {
+ static const char *posix_mons[MAX_MONTHS] =
+ {
+ "January",
+ "February",
+ "March",
+ "April",
+ "May",
+ "June",
+ "July",
+ "August",
+ "September",
+ "October",
+ "November",
+ "December"
+ };
cached_months[n] = dlg_strclone(posix_mons[n]);
}
if (!shown[n]) {
@@ -301,7 +301,6 @@ iso_week(int year, int month, int day)
if (365 + isleap(year) - diy < MAX_DAYS
&& new_years_eve_dow >= dow
&& new_years_eve_dow < thursday) {
- ++year;
week = 1;
}
return week;
@@ -371,7 +370,7 @@ static int
draw_day(BOX * data, struct tm *current)
{
int cell_wide = MON_WIDE;
- int y, x, this_x = 0;
+ int y, x, this_x;
int save_y = 0, save_x = 0;
int day = current->tm_mday;
int mday;
@@ -513,12 +512,11 @@ init_object(BOX * data,
data->box_draw = box_draw;
data->week_start = key_offset;
- data->window = derwin(data->parent,
- data->height, data->width,
- data->y, data->x);
+ data->window = dlg_der_window(data->parent,
+ data->height, data->width,
+ data->y, data->x);
if (data->window == 0)
return -1;
- (void) keypad(data->window, TRUE);
dlg_mouse_setbase(getbegx(parent), getbegy(parent));
if (code == 'D') {
@@ -715,14 +713,13 @@ dialog_calendar(const char *title,
#endif
BOX dy_box, mn_box, yr_box;
int fkey;
- int key = 0;
- int key2;
+ int key;
int step;
int button;
int result = DLG_EXIT_UNKNOWN;
int week_start;
WINDOW *dialog;
- time_t now_time = time((time_t *) 0);
+ time_t now_time;
struct tm current;
int state = dlg_default_button();
const char **buttons = dlg_ok_labels();
@@ -746,7 +743,7 @@ dialog_calendar(const char *title,
dlg_does_output();
/*
- * Unless overrridden, the current time/date is our starting point.
+ * Unless overridden, the current time/date is our starting point.
*/
now_time = time((time_t *) 0);
current = *localtime(&now_time);
@@ -871,6 +868,7 @@ dialog_calendar(const char *title,
dlg_trace_win(dialog);
while (result == DLG_EXIT_UNKNOWN) {
+ int key2;
BOX *obj = (state == sDAY ? &dy_box
: (state == sMONTH ? &mn_box :
(state == sYEAR ? &yr_box : 0)));
@@ -881,9 +879,10 @@ dialog_calendar(const char *title,
dlg_set_focus(dialog, obj->window);
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
-
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
#define Mouse2Key(key) (key - M_EVENT)
if (fkey && (key >= DLGK_MOUSE(KEY_MIN) && key <= DLGK_MOUSE(KEY_MAX))) {
key = dlg_lookup_key(dialog, Mouse2Key(key), &fkey);
@@ -907,6 +906,9 @@ dialog_calendar(const char *title,
case DLGK_ENTER:
result = dlg_enter_buttoncode(button);
break;
+ case DLGK_LEAVE:
+ result = dlg_ok_buttoncode(button);
+ break;
case DLGK_FIELD_PREV:
state = dlg_prev_ok_buttonindex(state, sMONTH);
break;
@@ -920,9 +922,7 @@ dialog_calendar(const char *title,
height = old_height;
width = old_width;
free(prompt);
- dlg_clear();
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
/* repaint */
goto retry;
#endif
@@ -1010,8 +1010,7 @@ dialog_calendar(const char *title,
DefaultFormat(buffer, current);
dlg_add_result(buffer);
- dlg_add_separator();
- dlg_add_last_key(-1);
+ AddLastKey();
return CleanupResult(result, dialog, prompt, &save_vars);
}
diff --git a/checklist.c b/checklist.c
index 778c4bb7332f..13055b77ab4f 100644
--- a/checklist.c
+++ b/checklist.c
@@ -1,9 +1,9 @@
/*
- * $Id: checklist.c,v 1.160 2018/06/19 22:57:01 tom Exp $
+ * $Id: checklist.c,v 1.167 2020/11/23 00:37:47 tom Exp $
*
* checklist.c -- implements the checklist box
*
- * Copyright 2000-2016,2018 Thomas E. Dickey
+ * Copyright 2000-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -192,12 +192,11 @@ dlg_checklist(const char *title,
#endif
ALL_DATA all;
int i, j, key2, found, x, y, cur_x, cur_y;
- int key = 0, fkey;
+ int key, fkey;
int button = dialog_state.visit_items ? -1 : dlg_default_button();
int choice = dlg_default_listitem(items);
int scrollamt = 0;
int max_choice;
- int was_mouse;
int use_width, list_width, name_width, text_width;
int result = DLG_EXIT_UNKNOWN;
int num_states;
@@ -304,8 +303,7 @@ dlg_checklist(const char *title,
* After displaying the prompt, we know how much space we really have.
* Limit the list to avoid overwriting the ok-button.
*/
- if (all.use_height + MIN_HIGH > height - cur_y)
- all.use_height = height - MIN_HIGH - cur_y;
+ all.use_height = height - MIN_HIGH - cur_y;
if (all.use_height <= 0)
all.use_height = 1;
@@ -379,13 +377,18 @@ dlg_checklist(const char *title,
dlg_draw_buttons(dialog, height - 2, 0, buttons, button, FALSE, width);
dlg_trace_win(dialog);
+
while (result == DLG_EXIT_UNKNOWN) {
+ int was_mouse;
+
if (button < 0) /* --visit-items */
wmove(dialog, all.box_y + choice + 1, all.box_x + all.check_x + 2);
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
was_mouse = (fkey && is_DLGK_MOUSE(key));
if (was_mouse)
@@ -560,6 +563,9 @@ dlg_checklist(const char *title,
case DLGK_ENTER:
result = dlg_enter_buttoncode(button);
break;
+ case DLGK_LEAVE:
+ result = dlg_ok_buttoncode(button);
+ break;
case DLGK_FIELD_PREV:
button = dlg_prev_button(buttons, button);
dlg_draw_buttons(dialog, height - 2, 0, buttons, button,
@@ -577,9 +583,7 @@ dlg_checklist(const char *title,
height = old_height;
width = old_width;
free(prompt);
- dlg_clear();
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
/* repaint */
goto retry;
#endif
@@ -592,7 +596,7 @@ dlg_checklist(const char *title,
beep();
}
}
- } else {
+ } else if (key > 0) {
beep();
}
}
diff --git a/columns.c b/columns.c
index d03761f81621..17f17f5f3d52 100644
--- a/columns.c
+++ b/columns.c
@@ -1,9 +1,9 @@
/*
- * $Id: columns.c,v 1.10 2011/10/20 20:53:55 tom Exp $
+ * $Id: columns.c,v 1.11 2019/07/25 00:06:38 tom Exp $
*
* columns.c -- implements column-alignment
*
- * Copyright 2008-2010,2011 Thomas E. Dickey
+ * Copyright 2008-2011,2019 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -93,8 +93,6 @@ split_row(char *source, unsigned *offsets, unsigned *widths)
void
dlg_align_columns(char **target, int per_row, int num_rows)
{
- int row;
-
if (column_separator()) {
char **value;
unsigned numcols = 1;
@@ -104,6 +102,7 @@ dlg_align_columns(char **target, int per_row, int num_rows)
unsigned *maxwidth;
unsigned realwidth;
unsigned n;
+ int row;
/* first allocate arrays for workspace */
for (each(row, value)) {
@@ -164,10 +163,10 @@ dlg_align_columns(char **target, int per_row, int num_rows)
void
dlg_free_columns(char **target, int per_row, int num_rows)
{
- int row;
- char **value;
-
if (column_separator()) {
+ int row;
+ char **value;
+
for (each(row, value)) {
free(*value);
}
diff --git a/config.guess b/config.guess
index 883a6713bf03..9aff91cfd038 100755
--- a/config.guess
+++ b/config.guess
@@ -1,8 +1,8 @@
#! /bin/sh
# Attempt to guess a canonical system name.
-# Copyright 1992-2018 Free Software Foundation, Inc.
+# Copyright 1992-2020 Free Software Foundation, Inc.
-timestamp='2018-05-19'
+timestamp='2020-08-17'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -50,7 +50,7 @@ version="\
GNU config.guess ($timestamp)
Originally written by Per Bothner.
-Copyright 1992-2018 Free Software Foundation, Inc.
+Copyright 1992-2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -84,8 +84,6 @@ if test $# != 0; then
exit 1
fi
-trap 'exit 1' 1 2 15
-
# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
# compiler to aid in system detection is discouraged as it requires
# temporary files to be created and, as you can see below, it is a
@@ -96,34 +94,40 @@ trap 'exit 1' 1 2 15
# Portable tmp directory creation inspired by the Autoconf team.
-set_cc_for_build='
-trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
-trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
-: ${TMPDIR=/tmp} ;
- { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
- { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
- { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
- { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
-dummy=$tmp/dummy ;
-tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
-case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in
- ,,) echo "int x;" > "$dummy.c" ;
- for c in cc gcc c89 c99 ; do
- if ($c -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then
- CC_FOR_BUILD="$c"; break ;
- fi ;
- done ;
- if test x"$CC_FOR_BUILD" = x ; then
- CC_FOR_BUILD=no_compiler_found ;
- fi
- ;;
- ,,*) CC_FOR_BUILD=$CC ;;
- ,*,*) CC_FOR_BUILD=$HOST_CC ;;
-esac ; set_cc_for_build= ;'
+tmp=
+# shellcheck disable=SC2172
+trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15
+
+set_cc_for_build() {
+ # prevent multiple calls if $tmp is already set
+ test "$tmp" && return 0
+ : "${TMPDIR=/tmp}"
+ # shellcheck disable=SC2039
+ { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
+ { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } ||
+ { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } ||
+ { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; }
+ dummy=$tmp/dummy
+ case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in
+ ,,) echo "int x;" > "$dummy.c"
+ for driver in cc gcc c89 c99 ; do
+ if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then
+ CC_FOR_BUILD="$driver"
+ break
+ fi
+ done
+ if test x"$CC_FOR_BUILD" = x ; then
+ CC_FOR_BUILD=no_compiler_found
+ fi
+ ;;
+ ,,*) CC_FOR_BUILD=$CC ;;
+ ,*,*) CC_FOR_BUILD=$HOST_CC ;;
+ esac
+}
# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
# (ghazi@noc.rutgers.edu 1994-08-24)
-if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
+if test -f /.attbin/uname ; then
PATH=$PATH:/.attbin ; export PATH
fi
@@ -138,7 +142,7 @@ Linux|GNU|GNU/*)
# We could probably try harder.
LIBC=gnu
- eval "$set_cc_for_build"
+ set_cc_for_build
cat <<-EOF > "$dummy.c"
#include <features.h>
#if defined(__UCLIBC__)
@@ -199,7 +203,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
os=netbsdelf
;;
arm*|i386|m68k|ns32k|sh3*|sparc|vax)
- eval "$set_cc_for_build"
+ set_cc_for_build
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ELF__
then
@@ -260,6 +264,9 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
*:SolidBSD:*:*)
echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE"
exit ;;
+ *:OS108:*:*)
+ echo "$UNAME_MACHINE"-unknown-os108_"$UNAME_RELEASE"
+ exit ;;
macppc:MirBSD:*:*)
echo powerpc-unknown-mirbsd"$UNAME_RELEASE"
exit ;;
@@ -269,12 +276,15 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
*:Sortix:*:*)
echo "$UNAME_MACHINE"-unknown-sortix
exit ;;
+ *:Twizzler:*:*)
+ echo "$UNAME_MACHINE"-unknown-twizzler
+ exit ;;
*:Redox:*:*)
echo "$UNAME_MACHINE"-unknown-redox
exit ;;
mips:OSF1:*.*)
- echo mips-dec-osf1
- exit ;;
+ echo mips-dec-osf1
+ exit ;;
alpha:OSF1:*:*)
case $UNAME_RELEASE in
*4.0)
@@ -389,12 +399,12 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
echo i386-pc-auroraux"$UNAME_RELEASE"
exit ;;
i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
- eval "$set_cc_for_build"
+ set_cc_for_build
SUN_ARCH=i386
# If there is a compiler, see if it is configured for 64-bit objects.
# Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
# This test works for both compilers.
- if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
+ if test "$CC_FOR_BUILD" != no_compiler_found; then
if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
(CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
grep IS_64BIT_ARCH >/dev/null
@@ -482,7 +492,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in
echo clipper-intergraph-clix"$UNAME_RELEASE"
exit ;;
mips:*:*:UMIPS | mips:*:*:RISCos)
- eval "$set_cc_for_build"
+ set_cc_for_build
sed 's/^ //' << EOF > "$dummy.c"
#ifdef __cplusplus
#include <stdio.h> /* for printf() prototype */
@@ -534,10 +544,10 @@ EOF
AViiON:dgux:*:*)
# DG/UX returns AViiON for all architectures
UNAME_PROCESSOR=`/usr/bin/uname -p`
- if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ]
+ if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110
then
- if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \
- [ "$TARGET_BINARY_INTERFACE"x = x ]
+ if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \
+ test "$TARGET_BINARY_INTERFACE"x = x
then
echo m88k-dg-dgux"$UNAME_RELEASE"
else
@@ -570,7 +580,7 @@ EOF
echo i386-ibm-aix
exit ;;
ia64:AIX:*:*)
- if [ -x /usr/bin/oslevel ] ; then
+ if test -x /usr/bin/oslevel ; then
IBM_REV=`/usr/bin/oslevel`
else
IBM_REV="$UNAME_VERSION.$UNAME_RELEASE"
@@ -579,7 +589,7 @@ EOF
exit ;;
*:AIX:2:3)
if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
- eval "$set_cc_for_build"
+ set_cc_for_build
sed 's/^ //' << EOF > "$dummy.c"
#include <sys/systemcfg.h>
@@ -610,7 +620,7 @@ EOF
else
IBM_ARCH=powerpc
fi
- if [ -x /usr/bin/lslpp ] ; then
+ if test -x /usr/bin/lslpp ; then
IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
else
@@ -645,7 +655,7 @@ EOF
9000/31?) HP_ARCH=m68000 ;;
9000/[34]??) HP_ARCH=m68k ;;
9000/[678][0-9][0-9])
- if [ -x /usr/bin/getconf ]; then
+ if test -x /usr/bin/getconf; then
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
case "$sc_cpu_version" in
@@ -659,8 +669,8 @@ EOF
esac ;;
esac
fi
- if [ "$HP_ARCH" = "" ]; then
- eval "$set_cc_for_build"
+ if test "$HP_ARCH" = ""; then
+ set_cc_for_build
sed 's/^ //' << EOF > "$dummy.c"
#define _HPUX_SOURCE
@@ -698,9 +708,9 @@ EOF
test -z "$HP_ARCH" && HP_ARCH=hppa
fi ;;
esac
- if [ "$HP_ARCH" = hppa2.0w ]
+ if test "$HP_ARCH" = hppa2.0w
then
- eval "$set_cc_for_build"
+ set_cc_for_build
# hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
# 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler
@@ -726,7 +736,7 @@ EOF
echo ia64-hp-hpux"$HPUX_REV"
exit ;;
3050*:HI-UX:*:*)
- eval "$set_cc_for_build"
+ set_cc_for_build
sed 's/^ //' << EOF > "$dummy.c"
#include <unistd.h>
int
@@ -772,7 +782,7 @@ EOF
echo hppa1.0-hp-osf
exit ;;
i*86:OSF1:*:*)
- if [ -x /usr/sbin/sysversion ] ; then
+ if test -x /usr/sbin/sysversion ; then
echo "$UNAME_MACHINE"-unknown-osf1mk
else
echo "$UNAME_MACHINE"-unknown-osf1
@@ -840,6 +850,17 @@ EOF
*:BSD/OS:*:*)
echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE"
exit ;;
+ arm:FreeBSD:*:*)
+ UNAME_PROCESSOR=`uname -p`
+ set_cc_for_build
+ if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
+ | grep -q __ARM_PCS_VFP
+ then
+ echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi
+ else
+ echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf
+ fi
+ exit ;;
*:FreeBSD:*:*)
UNAME_PROCESSOR=`/usr/bin/uname -p`
case "$UNAME_PROCESSOR" in
@@ -881,7 +902,7 @@ EOF
echo "$UNAME_MACHINE"-pc-uwin
exit ;;
amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
- echo x86_64-unknown-cygwin
+ echo x86_64-pc-cygwin
exit ;;
prep*:SunOS:5.*:*)
echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`"
@@ -894,8 +915,8 @@ EOF
# other systems with GNU libc and userland
echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC"
exit ;;
- i*86:Minix:*:*)
- echo "$UNAME_MACHINE"-pc-minix
+ *:Minix:*:*)
+ echo "$UNAME_MACHINE"-unknown-minix
exit ;;
aarch64:Linux:*:*)
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
@@ -905,7 +926,7 @@ EOF
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
exit ;;
alpha:Linux:*:*)
- case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
+ case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in
EV5) UNAME_MACHINE=alphaev5 ;;
EV56) UNAME_MACHINE=alphaev56 ;;
PCA56) UNAME_MACHINE=alphapca56 ;;
@@ -922,7 +943,7 @@ EOF
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
exit ;;
arm*:Linux:*:*)
- eval "$set_cc_for_build"
+ set_cc_for_build
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
| grep -q __ARM_EABI__
then
@@ -971,23 +992,51 @@ EOF
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
exit ;;
mips:Linux:*:* | mips64:Linux:*:*)
- eval "$set_cc_for_build"
+ set_cc_for_build
+ IS_GLIBC=0
+ test x"${LIBC}" = xgnu && IS_GLIBC=1
sed 's/^ //' << EOF > "$dummy.c"
#undef CPU
- #undef ${UNAME_MACHINE}
- #undef ${UNAME_MACHINE}el
+ #undef mips
+ #undef mipsel
+ #undef mips64
+ #undef mips64el
+ #if ${IS_GLIBC} && defined(_ABI64)
+ LIBCABI=gnuabi64
+ #else
+ #if ${IS_GLIBC} && defined(_ABIN32)
+ LIBCABI=gnuabin32
+ #else
+ LIBCABI=${LIBC}
+ #endif
+ #endif
+
+ #if ${IS_GLIBC} && defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6
+ CPU=mipsisa64r6
+ #else
+ #if ${IS_GLIBC} && !defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6
+ CPU=mipsisa32r6
+ #else
+ #if defined(__mips64)
+ CPU=mips64
+ #else
+ CPU=mips
+ #endif
+ #endif
+ #endif
+
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
- CPU=${UNAME_MACHINE}el
+ MIPS_ENDIAN=el
#else
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
- CPU=${UNAME_MACHINE}
+ MIPS_ENDIAN=
#else
- CPU=
+ MIPS_ENDIAN=
#endif
#endif
EOF
- eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU'`"
- test "x$CPU" != x && { echo "$CPU-unknown-linux-$LIBC"; exit; }
+ eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'`"
+ test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; }
;;
mips64el:Linux:*:*)
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
@@ -1046,7 +1095,17 @@ EOF
echo "$UNAME_MACHINE"-dec-linux-"$LIBC"
exit ;;
x86_64:Linux:*:*)
- echo "$UNAME_MACHINE"-pc-linux-"$LIBC"
+ set_cc_for_build
+ LIBCABI=$LIBC
+ if test "$CC_FOR_BUILD" != no_compiler_found; then
+ if (echo '#ifdef __ILP32__'; echo IS_X32; echo '#endif') | \
+ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
+ grep IS_X32 >/dev/null
+ then
+ LIBCABI="$LIBC"x32
+ fi
+ fi
+ echo "$UNAME_MACHINE"-pc-linux-"$LIBCABI"
exit ;;
xtensa*:Linux:*:*)
echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"
@@ -1100,7 +1159,7 @@ EOF
*Pentium) UNAME_MACHINE=i586 ;;
*Pent*|*Celeron) UNAME_MACHINE=i686 ;;
esac
- echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}{$UNAME_VERSION}"
+ echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}"
exit ;;
i*86:*:3.2:*)
if test -f /usr/options/cb.name; then
@@ -1235,7 +1294,7 @@ EOF
echo mips-sony-newsos6
exit ;;
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
- if [ -d /usr/nec ]; then
+ if test -d /usr/nec; then
echo mips-nec-sysv"$UNAME_RELEASE"
else
echo mips-unknown-sysv"$UNAME_RELEASE"
@@ -1283,39 +1342,43 @@ EOF
*:Rhapsody:*:*)
echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE"
exit ;;
+ arm64:Darwin:*:*)
+ echo aarch64-apple-darwin"$UNAME_RELEASE"
+ exit ;;
*:Darwin:*:*)
- UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
- eval "$set_cc_for_build"
- if test "$UNAME_PROCESSOR" = unknown ; then
- UNAME_PROCESSOR=powerpc
+ UNAME_PROCESSOR=`uname -p`
+ case $UNAME_PROCESSOR in
+ unknown) UNAME_PROCESSOR=powerpc ;;
+ esac
+ if command -v xcode-select > /dev/null 2> /dev/null && \
+ ! xcode-select --print-path > /dev/null 2> /dev/null ; then
+ # Avoid executing cc if there is no toolchain installed as
+ # cc will be a stub that puts up a graphical alert
+ # prompting the user to install developer tools.
+ CC_FOR_BUILD=no_compiler_found
+ else
+ set_cc_for_build
fi
- if test "`echo "$UNAME_RELEASE" | sed -e 's/\..*//'`" -le 10 ; then
- if [ "$CC_FOR_BUILD" != no_compiler_found ]; then
- if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
- (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
- grep IS_64BIT_ARCH >/dev/null
- then
- case $UNAME_PROCESSOR in
- i386) UNAME_PROCESSOR=x86_64 ;;
- powerpc) UNAME_PROCESSOR=powerpc64 ;;
- esac
- fi
- # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc
- if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \
- (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
- grep IS_PPC >/dev/null
- then
- UNAME_PROCESSOR=powerpc
- fi
+ if test "$CC_FOR_BUILD" != no_compiler_found; then
+ if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
+ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
+ grep IS_64BIT_ARCH >/dev/null
+ then
+ case $UNAME_PROCESSOR in
+ i386) UNAME_PROCESSOR=x86_64 ;;
+ powerpc) UNAME_PROCESSOR=powerpc64 ;;
+ esac
+ fi
+ # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc
+ if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \
+ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \
+ grep IS_PPC >/dev/null
+ then
+ UNAME_PROCESSOR=powerpc
fi
elif test "$UNAME_PROCESSOR" = i386 ; then
- # Avoid executing cc on OS X 10.9, as it ships with a stub
- # that puts up a graphical alert prompting to install
- # developer tools. Any system running Mac OS X 10.7 or
- # later (Darwin 11 and later) is required to have a 64-bit
- # processor. This is not true of the ARM version of Darwin
- # that Apple uses in portable devices.
- UNAME_PROCESSOR=x86_64
+ # uname -m returns i386 or x86_64
+ UNAME_PROCESSOR=$UNAME_MACHINE
fi
echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE"
exit ;;
@@ -1358,6 +1421,7 @@ EOF
# "uname -m" is not consistent, so use $cputype instead. 386
# is converted to i386 for consistency with other x86
# operating systems.
+ # shellcheck disable=SC2154
if test "$cputype" = 386; then
UNAME_MACHINE=i386
else
@@ -1414,8 +1478,148 @@ EOF
amd64:Isilon\ OneFS:*:*)
echo x86_64-unknown-onefs
exit ;;
+ *:Unleashed:*:*)
+ echo "$UNAME_MACHINE"-unknown-unleashed"$UNAME_RELEASE"
+ exit ;;
esac
+# No uname command or uname output not recognized.
+set_cc_for_build
+cat > "$dummy.c" <<EOF
+#ifdef _SEQUENT_
+#include <sys/types.h>
+#include <sys/utsname.h>
+#endif
+#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__)
+#if defined (vax) || defined (__vax) || defined (__vax__) || defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__)
+#include <signal.h>
+#if defined(_SIZE_T_) || defined(SIGLOST)
+#include <sys/utsname.h>
+#endif
+#endif
+#endif
+main ()
+{
+#if defined (sony)
+#if defined (MIPSEB)
+ /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed,
+ I don't know.... */
+ printf ("mips-sony-bsd\n"); exit (0);
+#else
+#include <sys/param.h>
+ printf ("m68k-sony-newsos%s\n",
+#ifdef NEWSOS4
+ "4"
+#else
+ ""
+#endif
+ ); exit (0);
+#endif
+#endif
+
+#if defined (NeXT)
+#if !defined (__ARCHITECTURE__)
+#define __ARCHITECTURE__ "m68k"
+#endif
+ int version;
+ version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
+ if (version < 4)
+ printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
+ else
+ printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version);
+ exit (0);
+#endif
+
+#if defined (MULTIMAX) || defined (n16)
+#if defined (UMAXV)
+ printf ("ns32k-encore-sysv\n"); exit (0);
+#else
+#if defined (CMU)
+ printf ("ns32k-encore-mach\n"); exit (0);
+#else
+ printf ("ns32k-encore-bsd\n"); exit (0);
+#endif
+#endif
+#endif
+
+#if defined (__386BSD__)
+ printf ("i386-pc-bsd\n"); exit (0);
+#endif
+
+#if defined (sequent)
+#if defined (i386)
+ printf ("i386-sequent-dynix\n"); exit (0);
+#endif
+#if defined (ns32000)
+ printf ("ns32k-sequent-dynix\n"); exit (0);
+#endif
+#endif
+
+#if defined (_SEQUENT_)
+ struct utsname un;
+
+ uname(&un);
+ if (strncmp(un.version, "V2", 2) == 0) {
+ printf ("i386-sequent-ptx2\n"); exit (0);
+ }
+ if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
+ printf ("i386-sequent-ptx1\n"); exit (0);
+ }
+ printf ("i386-sequent-ptx\n"); exit (0);
+#endif
+
+#if defined (vax)
+#if !defined (ultrix)
+#include <sys/param.h>
+#if defined (BSD)
+#if BSD == 43
+ printf ("vax-dec-bsd4.3\n"); exit (0);
+#else
+#if BSD == 199006
+ printf ("vax-dec-bsd4.3reno\n"); exit (0);
+#else
+ printf ("vax-dec-bsd\n"); exit (0);
+#endif
+#endif
+#else
+ printf ("vax-dec-bsd\n"); exit (0);
+#endif
+#else
+#if defined(_SIZE_T_) || defined(SIGLOST)
+ struct utsname un;
+ uname (&un);
+ printf ("vax-dec-ultrix%s\n", un.release); exit (0);
+#else
+ printf ("vax-dec-ultrix\n"); exit (0);
+#endif
+#endif
+#endif
+#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__)
+#if defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__)
+#if defined(_SIZE_T_) || defined(SIGLOST)
+ struct utsname *un;
+ uname (&un);
+ printf ("mips-dec-ultrix%s\n", un.release); exit (0);
+#else
+ printf ("mips-dec-ultrix\n"); exit (0);
+#endif
+#endif
+#endif
+
+#if defined (alliant) && defined (i860)
+ printf ("i860-alliant-bsd\n"); exit (0);
+#endif
+
+ exit (1);
+}
+EOF
+
+$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`$dummy` &&
+ { echo "$SYSTEM_NAME"; exit; }
+
+# Apollos put the system type in the environment.
+test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; }
+
echo "$0: unable to guess system type" >&2
case "$UNAME_MACHINE:$UNAME_SYSTEM" in
@@ -1438,6 +1642,12 @@ copies of config.guess and config.sub with the latest versions from:
https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
and
https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
+EOF
+
+year=`echo $timestamp | sed 's,-.*,,'`
+# shellcheck disable=SC2003
+if test "`expr "\`date +%Y\`" - "$year"`" -lt 3 ; then
+ cat >&2 <<EOF
If $0 has already been updated, send the following data and any
information you think might be pertinent to config-patches@gnu.org to
@@ -1465,6 +1675,7 @@ UNAME_RELEASE = "$UNAME_RELEASE"
UNAME_SYSTEM = "$UNAME_SYSTEM"
UNAME_VERSION = "$UNAME_VERSION"
EOF
+fi
exit 1
diff --git a/config.sub b/config.sub
index d1f5b5490349..0753e3084581 100755
--- a/config.sub
+++ b/config.sub
@@ -1,8 +1,8 @@
#! /bin/sh
# Configuration validation subroutine script.
-# Copyright 1992-2018 Free Software Foundation, Inc.
+# Copyright 1992-2020 Free Software Foundation, Inc.
-timestamp='2018-05-24'
+timestamp='2020-08-17'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -67,7 +67,7 @@ Report bugs and patches to <config-patches@gnu.org>."
version="\
GNU config.sub ($timestamp)
-Copyright 1992-2018 Free Software Foundation, Inc.
+Copyright 1992-2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -89,7 +89,7 @@ while test $# -gt 0 ; do
- ) # Use stdin as input.
break ;;
-* )
- echo "$me: invalid option $1$help"
+ echo "$me: invalid option $1$help" >&2
exit 1 ;;
*local*)
@@ -111,7 +111,8 @@ case $# in
esac
# Split fields of configuration type
-IFS="-" read -r field1 field2 field3 field4 <<EOF
+# shellcheck disable=SC2162
+IFS="-" read field1 field2 field3 field4 <<EOF
$1
EOF
@@ -123,55 +124,64 @@ case $1 in
;;
*-*-*-*)
basic_machine=$field1-$field2
- os=$field3-$field4
+ basic_os=$field3-$field4
;;
*-*-*)
# Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two
# parts
maybe_os=$field2-$field3
case $maybe_os in
- nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc \
- | linux-newlib* | linux-musl* | linux-uclibc* | uclinux-uclibc* \
+ nto-qnx* | linux-* | uclinux-uclibc* \
| uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \
| netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \
| storm-chaos* | os2-emx* | rtmk-nova*)
basic_machine=$field1
- os=$maybe_os
+ basic_os=$maybe_os
;;
android-linux)
basic_machine=$field1-unknown
- os=linux-android
+ basic_os=linux-android
;;
*)
basic_machine=$field1-$field2
- os=$field3
+ basic_os=$field3
;;
esac
;;
*-*)
- # Second component is usually, but not always the OS
- case $field2 in
- # Prevent following clause from handling this valid os
- sun*os*)
- basic_machine=$field1
- os=$field2
- ;;
- # Manufacturers
- dec* | mips* | sequent* | encore* | pc532* | sgi* | sony* \
- | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \
- | unicom* | ibm* | next | hp | isi* | apollo | altos* \
- | convergent* | ncr* | news | 32* | 3600* | 3100* | hitachi* \
- | c[123]* | convex* | sun | crds | omron* | dg | ultra | tti* \
- | harris | dolphin | highlevel | gould | cbm | ns | masscomp \
- | apple | axis | knuth | cray | microblaze* \
- | sim | cisco | oki | wec | wrs | winbond)
- basic_machine=$field1-$field2
- os=
- ;;
- *)
- basic_machine=$field1
- os=$field2
- ;;
+ # A lone config we happen to match not fitting any pattern
+ case $field1-$field2 in
+ decstation-3100)
+ basic_machine=mips-dec
+ basic_os=
+ ;;
+ *-*)
+ # Second component is usually, but not always the OS
+ case $field2 in
+ # Prevent following clause from handling this valid os
+ sun*os*)
+ basic_machine=$field1
+ basic_os=$field2
+ ;;
+ # Manufacturers
+ dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \
+ | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \
+ | unicom* | ibm* | next | hp | isi* | apollo | altos* \
+ | convergent* | ncr* | news | 32* | 3600* | 3100* \
+ | hitachi* | c[123]* | convex* | sun | crds | omron* | dg \
+ | ultra | tti* | harris | dolphin | highlevel | gould \
+ | cbm | ns | masscomp | apple | axis | knuth | cray \
+ | microblaze* | sim | cisco \
+ | oki | wec | wrs | winbond)
+ basic_machine=$field1-$field2
+ basic_os=
+ ;;
+ *)
+ basic_machine=$field1
+ basic_os=$field2
+ ;;
+ esac
+ ;;
esac
;;
*)
@@ -180,1105 +190,1087 @@ case $1 in
case $field1 in
386bsd)
basic_machine=i386-pc
- os=bsd
+ basic_os=bsd
;;
a29khif)
basic_machine=a29k-amd
- os=udi
+ basic_os=udi
;;
adobe68k)
basic_machine=m68010-adobe
- os=scout
+ basic_os=scout
+ ;;
+ alliant)
+ basic_machine=fx80-alliant
+ basic_os=
+ ;;
+ altos | altos3068)
+ basic_machine=m68k-altos
+ basic_os=
;;
am29k)
basic_machine=a29k-none
- os=bsd
+ basic_os=bsd
;;
amdahl)
basic_machine=580-amdahl
- os=sysv
+ basic_os=sysv
+ ;;
+ amiga)
+ basic_machine=m68k-unknown
+ basic_os=
;;
amigaos | amigados)
basic_machine=m68k-unknown
- os=amigaos
+ basic_os=amigaos
;;
amigaunix | amix)
basic_machine=m68k-unknown
- os=sysv4
+ basic_os=sysv4
;;
apollo68)
basic_machine=m68k-apollo
- os=sysv
+ basic_os=sysv
;;
apollo68bsd)
basic_machine=m68k-apollo
- os=bsd
+ basic_os=bsd
;;
aros)
basic_machine=i386-pc
- os=aros
+ basic_os=aros
;;
aux)
basic_machine=m68k-apple
- os=aux
+ basic_os=aux
;;
balance)
basic_machine=ns32k-sequent
- os=dynix
+ basic_os=dynix
;;
blackfin)
basic_machine=bfin-unknown
- os=linux
+ basic_os=linux
;;
cegcc)
basic_machine=arm-unknown
- os=cegcc
+ basic_os=cegcc
+ ;;
+ convex-c1)
+ basic_machine=c1-convex
+ basic_os=bsd
+ ;;
+ convex-c2)
+ basic_machine=c2-convex
+ basic_os=bsd
+ ;;
+ convex-c32)
+ basic_machine=c32-convex
+ basic_os=bsd
+ ;;
+ convex-c34)
+ basic_machine=c34-convex
+ basic_os=bsd
+ ;;
+ convex-c38)
+ basic_machine=c38-convex
+ basic_os=bsd
;;
cray)
basic_machine=j90-cray
- os=unicos
+ basic_os=unicos
;;
- craynv)
- basic_machine=craynv-cray
- os=unicosmp
+ crds | unos)
+ basic_machine=m68k-crds
+ basic_os=
+ ;;
+ da30)
+ basic_machine=m68k-da30
+ basic_os=
+ ;;
+ decstation | pmax | pmin | dec3100 | decstatn)
+ basic_machine=mips-dec
+ basic_os=
;;
delta88)
basic_machine=m88k-motorola
- os=sysv3
+ basic_os=sysv3
;;
dicos)
basic_machine=i686-pc
- os=dicos
+ basic_os=dicos
;;
djgpp)
basic_machine=i586-pc
- os=msdosdjgpp
+ basic_os=msdosdjgpp
;;
ebmon29k)
basic_machine=a29k-amd
- os=ebmon
+ basic_os=ebmon
;;
es1800 | OSE68k | ose68k | ose | OSE)
basic_machine=m68k-ericsson
- os=ose
+ basic_os=ose
;;
gmicro)
basic_machine=tron-gmicro
- os=sysv
+ basic_os=sysv
;;
go32)
basic_machine=i386-pc
- os=go32
+ basic_os=go32
;;
h8300hms)
basic_machine=h8300-hitachi
- os=hms
+ basic_os=hms
;;
h8300xray)
basic_machine=h8300-hitachi
- os=xray
+ basic_os=xray
;;
h8500hms)
basic_machine=h8500-hitachi
- os=hms
+ basic_os=hms
;;
harris)
basic_machine=m88k-harris
- os=sysv3
+ basic_os=sysv3
;;
- hp300bsd)
+ hp300 | hp300hpux)
basic_machine=m68k-hp
- os=bsd
+ basic_os=hpux
;;
- hp300hpux)
+ hp300bsd)
basic_machine=m68k-hp
- os=hpux
+ basic_os=bsd
;;
hppaosf)
basic_machine=hppa1.1-hp
- os=osf
+ basic_os=osf
;;
hppro)
basic_machine=hppa1.1-hp
- os=proelf
+ basic_os=proelf
;;
i386mach)
basic_machine=i386-mach
- os=mach
- ;;
- vsta)
- basic_machine=i386-unknown
- os=vsta
+ basic_os=mach
;;
isi68 | isi)
basic_machine=m68k-isi
- os=sysv
+ basic_os=sysv
;;
m68knommu)
basic_machine=m68k-unknown
- os=linux
+ basic_os=linux
;;
magnum | m3230)
basic_machine=mips-mips
- os=sysv
+ basic_os=sysv
;;
merlin)
basic_machine=ns32k-utek
- os=sysv
+ basic_os=sysv
;;
mingw64)
basic_machine=x86_64-pc
- os=mingw64
+ basic_os=mingw64
;;
mingw32)
basic_machine=i686-pc
- os=mingw32
+ basic_os=mingw32
;;
mingw32ce)
basic_machine=arm-unknown
- os=mingw32ce
+ basic_os=mingw32ce
;;
monitor)
basic_machine=m68k-rom68k
- os=coff
+ basic_os=coff
;;
morphos)
basic_machine=powerpc-unknown
- os=morphos
+ basic_os=morphos
;;
moxiebox)
basic_machine=moxie-unknown
- os=moxiebox
+ basic_os=moxiebox
;;
msdos)
basic_machine=i386-pc
- os=msdos
+ basic_os=msdos
;;
msys)
basic_machine=i686-pc
- os=msys
+ basic_os=msys
;;
mvs)
basic_machine=i370-ibm
- os=mvs
+ basic_os=mvs
;;
nacl)
basic_machine=le32-unknown
- os=nacl
+ basic_os=nacl
;;
ncr3000)
basic_machine=i486-ncr
- os=sysv4
+ basic_os=sysv4
;;
netbsd386)
- basic_machine=i386-unknown
- os=netbsd
+ basic_machine=i386-pc
+ basic_os=netbsd
;;
netwinder)
basic_machine=armv4l-rebel
- os=linux
+ basic_os=linux
;;
news | news700 | news800 | news900)
basic_machine=m68k-sony
- os=newsos
+ basic_os=newsos
;;
news1000)
basic_machine=m68030-sony
- os=newsos
+ basic_os=newsos
;;
necv70)
basic_machine=v70-nec
- os=sysv
+ basic_os=sysv
;;
nh3000)
basic_machine=m68k-harris
- os=cxux
+ basic_os=cxux
;;
nh[45]000)
basic_machine=m88k-harris
- os=cxux
+ basic_os=cxux
;;
nindy960)
basic_machine=i960-intel
- os=nindy
+ basic_os=nindy
;;
mon960)
basic_machine=i960-intel
- os=mon960
+ basic_os=mon960
;;
nonstopux)
basic_machine=mips-compaq
- os=nonstopux
+ basic_os=nonstopux
;;
os400)
basic_machine=powerpc-ibm
- os=os400
+ basic_os=os400
;;
OSE68000 | ose68000)
basic_machine=m68000-ericsson
- os=ose
+ basic_os=ose
;;
os68k)
basic_machine=m68k-none
- os=os68k
+ basic_os=os68k
;;
paragon)
basic_machine=i860-intel
- os=osf
+ basic_os=osf
;;
parisc)
basic_machine=hppa-unknown
- os=linux
+ basic_os=linux
+ ;;
+ psp)
+ basic_machine=mipsallegrexel-sony
+ basic_os=psp
;;
pw32)
basic_machine=i586-unknown
- os=pw32
+ basic_os=pw32
;;
rdos | rdos64)
basic_machine=x86_64-pc
- os=rdos
+ basic_os=rdos
;;
rdos32)
basic_machine=i386-pc
- os=rdos
+ basic_os=rdos
;;
rom68k)
basic_machine=m68k-rom68k
- os=coff
+ basic_os=coff
;;
sa29200)
basic_machine=a29k-amd
- os=udi
+ basic_os=udi
;;
sei)
basic_machine=mips-sei
- os=seiux
+ basic_os=seiux
+ ;;
+ sequent)
+ basic_machine=i386-sequent
+ basic_os=
;;
sps7)
basic_machine=m68k-bull
- os=sysv2
+ basic_os=sysv2
+ ;;
+ st2000)
+ basic_machine=m68k-tandem
+ basic_os=
;;
stratus)
basic_machine=i860-stratus
- os=sysv4
+ basic_os=sysv4
+ ;;
+ sun2)
+ basic_machine=m68000-sun
+ basic_os=
;;
sun2os3)
basic_machine=m68000-sun
- os=sunos3
+ basic_os=sunos3
;;
sun2os4)
basic_machine=m68000-sun
- os=sunos4
+ basic_os=sunos4
+ ;;
+ sun3)
+ basic_machine=m68k-sun
+ basic_os=
;;
sun3os3)
basic_machine=m68k-sun
- os=sunos3
+ basic_os=sunos3
;;
sun3os4)
basic_machine=m68k-sun
- os=sunos4
+ basic_os=sunos4
+ ;;
+ sun4)
+ basic_machine=sparc-sun
+ basic_os=
;;
sun4os3)
basic_machine=sparc-sun
- os=sunos3
+ basic_os=sunos3
;;
sun4os4)
basic_machine=sparc-sun
- os=sunos4
+ basic_os=sunos4
;;
sun4sol2)
basic_machine=sparc-sun
- os=solaris2
+ basic_os=solaris2
+ ;;
+ sun386 | sun386i | roadrunner)
+ basic_machine=i386-sun
+ basic_os=
;;
sv1)
basic_machine=sv1-cray
- os=unicos
+ basic_os=unicos
;;
symmetry)
basic_machine=i386-sequent
- os=dynix
+ basic_os=dynix
;;
t3e)
basic_machine=alphaev5-cray
- os=unicos
+ basic_os=unicos
;;
t90)
basic_machine=t90-cray
- os=unicos
+ basic_os=unicos
;;
toad1)
basic_machine=pdp10-xkl
- os=tops20
+ basic_os=tops20
;;
tpf)
basic_machine=s390x-ibm
- os=tpf
+ basic_os=tpf
;;
udi29k)
basic_machine=a29k-amd
- os=udi
+ basic_os=udi
;;
ultra3)
basic_machine=a29k-nyu
- os=sym1
+ basic_os=sym1
;;
v810 | necv810)
basic_machine=v810-nec
- os=none
+ basic_os=none
;;
vaxv)
basic_machine=vax-dec
- os=sysv
+ basic_os=sysv
;;
vms)
basic_machine=vax-dec
- os=vms
+ basic_os=vms
+ ;;
+ vsta)
+ basic_machine=i386-pc
+ basic_os=vsta
;;
vxworks960)
basic_machine=i960-wrs
- os=vxworks
+ basic_os=vxworks
;;
vxworks68)
basic_machine=m68k-wrs
- os=vxworks
+ basic_os=vxworks
;;
vxworks29k)
basic_machine=a29k-wrs
- os=vxworks
+ basic_os=vxworks
;;
xbox)
basic_machine=i686-pc
- os=mingw32
+ basic_os=mingw32
;;
ymp)
basic_machine=ymp-cray
- os=unicos
+ basic_os=unicos
;;
*)
basic_machine=$1
- os=
+ basic_os=
;;
esac
;;
esac
-# Decode aliases for certain CPU-COMPANY combinations.
+# Decode 1-component or ad-hoc basic machines
case $basic_machine in
- # Recognize the basic CPU types without company name.
- # Some are omitted here because they have special meanings below.
- 1750a | 580 \
- | a29k \
- | aarch64 | aarch64_be \
- | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
- | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
- | am33_2.0 \
- | arc | arceb \
- | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv6m | armv[78][arm] \
- | avr | avr32 \
- | ba \
- | be32 | be64 \
- | bfin \
- | c4x | c8051 | clipper | csky \
- | d10v | d30v | dlx | dsp16xx \
- | e2k | epiphany \
- | fido | fr30 | frv | ft32 \
- | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
- | hexagon \
- | i370 | i860 | i960 | ia16 | ia64 \
- | ip2k | iq2000 \
- | k1om \
- | le32 | le64 \
- | lm32 \
- | m32c | m32r | m32rle | m68000 | m68k | m88k \
- | maxq | mb | microblaze | microblazeel | mcore | mep | metag \
- | mips | mipsbe | mipseb | mipsel | mipsle \
- | mips16 \
- | mips64 | mips64el \
- | mips64octeon | mips64octeonel \
- | mips64orion | mips64orionel \
- | mips64r5900 | mips64r5900el \
- | mips64vr | mips64vrel \
- | mips64vr4100 | mips64vr4100el \
- | mips64vr4300 | mips64vr4300el \
- | mips64vr5000 | mips64vr5000el \
- | mips64vr5900 | mips64vr5900el \
- | mipsisa32 | mipsisa32el \
- | mipsisa32r2 | mipsisa32r2el \
- | mipsisa32r6 | mipsisa32r6el \
- | mipsisa64 | mipsisa64el \
- | mipsisa64r2 | mipsisa64r2el \
- | mipsisa64r6 | mipsisa64r6el \
- | mipsisa64sb1 | mipsisa64sb1el \
- | mipsisa64sr71k | mipsisa64sr71kel \
- | mipsr5900 | mipsr5900el \
- | mipstx39 | mipstx39el \
- | mn10200 | mn10300 \
- | moxie \
- | mt \
- | msp430 \
- | nds32 | nds32le | nds32be \
- | nfp \
- | nios | nios2 | nios2eb | nios2el \
- | ns16k | ns32k \
- | open8 | or1k | or1knd | or32 \
- | pdp10 | pj | pjl \
- | powerpc | powerpc64 | powerpc64le | powerpcle \
- | pru \
- | pyramid \
- | riscv32 | riscv64 \
- | rl78 | rx \
- | score \
- | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[234]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
- | sh64 | sh64le \
- | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
- | sparcv8 | sparcv9 | sparcv9b | sparcv9v \
- | spu \
- | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
- | ubicom32 \
- | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \
- | visium \
- | wasm32 \
- | x86 | xc16x | xstormy16 | xtensa \
- | z8k | z80)
- basic_machine=$basic_machine-unknown
- ;;
- c54x)
- basic_machine=tic54x-unknown
- ;;
- c55x)
- basic_machine=tic55x-unknown
- ;;
- c6x)
- basic_machine=tic6x-unknown
- ;;
- leon|leon[3-9])
- basic_machine=sparc-$basic_machine
- ;;
- m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip)
- basic_machine=$basic_machine-unknown
- os=${os:-none}
- ;;
- m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65)
+ # Here we handle the default manufacturer of certain CPU types. It is in
+ # some cases the only manufacturer, in others, it is the most popular.
+ w89k)
+ cpu=hppa1.1
+ vendor=winbond
;;
- m9s12z | m68hcs12z | hcs12z | s12z)
- basic_machine=s12z-unknown
- os=${os:-none}
+ op50n)
+ cpu=hppa1.1
+ vendor=oki
;;
- ms1)
- basic_machine=mt-unknown
+ op60c)
+ cpu=hppa1.1
+ vendor=oki
;;
- strongarm | thumb | xscale)
- basic_machine=arm-unknown
+ ibm*)
+ cpu=i370
+ vendor=ibm
;;
- xgate)
- basic_machine=$basic_machine-unknown
- os=${os:-none}
+ orion105)
+ cpu=clipper
+ vendor=highlevel
;;
- xscaleeb)
- basic_machine=armeb-unknown
+ mac | mpw | mac-mpw)
+ cpu=m68k
+ vendor=apple
;;
-
- xscaleel)
- basic_machine=armel-unknown
+ pmac | pmac-mpw)
+ cpu=powerpc
+ vendor=apple
;;
- # We use `pc' rather than `unknown'
- # because (1) that's what they normally are, and
- # (2) the word "unknown" tends to confuse beginning users.
- i*86 | x86_64)
- basic_machine=$basic_machine-pc
- ;;
- # Recognize the basic CPU types with company name.
- 580-* \
- | a29k-* \
- | aarch64-* | aarch64_be-* \
- | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
- | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
- | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \
- | arm-* | armbe-* | armle-* | armeb-* | armv*-* \
- | avr-* | avr32-* \
- | ba-* \
- | be32-* | be64-* \
- | bfin-* | bs2000-* \
- | c[123]* | c30-* | [cjt]90-* | c4x-* \
- | c8051-* | clipper-* | craynv-* | csky-* | cydra-* \
- | d10v-* | d30v-* | dlx-* \
- | e2k-* | elxsi-* \
- | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
- | h8300-* | h8500-* \
- | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
- | hexagon-* \
- | i*86-* | i860-* | i960-* | ia16-* | ia64-* \
- | ip2k-* | iq2000-* \
- | k1om-* \
- | le32-* | le64-* \
- | lm32-* \
- | m32c-* | m32r-* | m32rle-* \
- | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
- | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \
- | microblaze-* | microblazeel-* \
- | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
- | mips16-* \
- | mips64-* | mips64el-* \
- | mips64octeon-* | mips64octeonel-* \
- | mips64orion-* | mips64orionel-* \
- | mips64r5900-* | mips64r5900el-* \
- | mips64vr-* | mips64vrel-* \
- | mips64vr4100-* | mips64vr4100el-* \
- | mips64vr4300-* | mips64vr4300el-* \
- | mips64vr5000-* | mips64vr5000el-* \
- | mips64vr5900-* | mips64vr5900el-* \
- | mipsisa32-* | mipsisa32el-* \
- | mipsisa32r2-* | mipsisa32r2el-* \
- | mipsisa32r6-* | mipsisa32r6el-* \
- | mipsisa64-* | mipsisa64el-* \
- | mipsisa64r2-* | mipsisa64r2el-* \
- | mipsisa64r6-* | mipsisa64r6el-* \
- | mipsisa64sb1-* | mipsisa64sb1el-* \
- | mipsisa64sr71k-* | mipsisa64sr71kel-* \
- | mipsr5900-* | mipsr5900el-* \
- | mipstx39-* | mipstx39el-* \
- | mmix-* \
- | mt-* \
- | msp430-* \
- | nds32-* | nds32le-* | nds32be-* \
- | nfp-* \
- | nios-* | nios2-* | nios2eb-* | nios2el-* \
- | none-* | np1-* | ns16k-* | ns32k-* \
- | open8-* \
- | or1k*-* \
- | orion-* \
- | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
- | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \
- | pru-* \
- | pyramid-* \
- | riscv32-* | riscv64-* \
- | rl78-* | romp-* | rs6000-* | rx-* \
- | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
- | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
- | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
- | sparclite-* \
- | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx*-* \
- | tahoe-* \
- | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
- | tile*-* \
- | tron-* \
- | ubicom32-* \
- | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \
- | vax-* \
- | visium-* \
- | wasm32-* \
- | we32k-* \
- | x86-* | x86_64-* | xc16x-* | xps100-* \
- | xstormy16-* | xtensa*-* \
- | ymp-* \
- | z8k-* | z80-*)
- ;;
- # Recognize the basic CPU types without company name, with glob match.
- xtensa*)
- basic_machine=$basic_machine-unknown
- ;;
# Recognize the various machine names and aliases which stand
# for a CPU type and a company and sometimes even an OS.
3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
- basic_machine=m68000-att
+ cpu=m68000
+ vendor=att
;;
3b*)
- basic_machine=we32k-att
- ;;
- abacus)
- basic_machine=abacus-unknown
- ;;
- alliant | fx80)
- basic_machine=fx80-alliant
- ;;
- altos | altos3068)
- basic_machine=m68k-altos
- ;;
- amd64)
- basic_machine=x86_64-pc
- ;;
- amd64-*)
- basic_machine=x86_64-`echo "$basic_machine" | sed 's/^[^-]*-//'`
- ;;
- amiga | amiga-*)
- basic_machine=m68k-unknown
- ;;
- asmjs)
- basic_machine=asmjs-unknown
- ;;
- blackfin-*)
- basic_machine=bfin-`echo "$basic_machine" | sed 's/^[^-]*-//'`
- os=linux
+ cpu=we32k
+ vendor=att
;;
bluegene*)
- basic_machine=powerpc-ibm
- os=cnk
- ;;
- c54x-*)
- basic_machine=tic54x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
- ;;
- c55x-*)
- basic_machine=tic55x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
- ;;
- c6x-*)
- basic_machine=tic6x-`echo "$basic_machine" | sed 's/^[^-]*-//'`
- ;;
- c90)
- basic_machine=c90-cray
- os=${os:-unicos}
- ;;
- convex-c1)
- basic_machine=c1-convex
- os=bsd
- ;;
- convex-c2)
- basic_machine=c2-convex
- os=bsd
- ;;
- convex-c32)
- basic_machine=c32-convex
- os=bsd
- ;;
- convex-c34)
- basic_machine=c34-convex
- os=bsd
- ;;
- convex-c38)
- basic_machine=c38-convex
- os=bsd
- ;;
- cr16 | cr16-*)
- basic_machine=cr16-unknown
- os=${os:-elf}
- ;;
- crds | unos)
- basic_machine=m68k-crds
- ;;
- crisv32 | crisv32-* | etraxfs*)
- basic_machine=crisv32-axis
- ;;
- cris | cris-* | etrax*)
- basic_machine=cris-axis
- ;;
- crx)
- basic_machine=crx-unknown
- os=${os:-elf}
- ;;
- da30 | da30-*)
- basic_machine=m68k-da30
- ;;
- decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
- basic_machine=mips-dec
+ cpu=powerpc
+ vendor=ibm
+ basic_os=cnk
;;
decsystem10* | dec10*)
- basic_machine=pdp10-dec
- os=tops10
+ cpu=pdp10
+ vendor=dec
+ basic_os=tops10
;;
decsystem20* | dec20*)
- basic_machine=pdp10-dec
- os=tops20
+ cpu=pdp10
+ vendor=dec
+ basic_os=tops20
;;
delta | 3300 | motorola-3300 | motorola-delta \
| 3300-motorola | delta-motorola)
- basic_machine=m68k-motorola
- ;;
- dpx20 | dpx20-*)
- basic_machine=rs6000-bull
- os=${os:-bosx}
+ cpu=m68k
+ vendor=motorola
;;
dpx2*)
- basic_machine=m68k-bull
- os=sysv3
- ;;
- e500v[12])
- basic_machine=powerpc-unknown
- os=$os"spe"
- ;;
- e500v[12]-*)
- basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'`
- os=$os"spe"
+ cpu=m68k
+ vendor=bull
+ basic_os=sysv3
;;
encore | umax | mmax)
- basic_machine=ns32k-encore
+ cpu=ns32k
+ vendor=encore
;;
elxsi)
- basic_machine=elxsi-elxsi
- os=${os:-bsd}
+ cpu=elxsi
+ vendor=elxsi
+ basic_os=${basic_os:-bsd}
;;
fx2800)
- basic_machine=i860-alliant
+ cpu=i860
+ vendor=alliant
;;
genix)
- basic_machine=ns32k-ns
+ cpu=ns32k
+ vendor=ns
;;
h3050r* | hiux*)
- basic_machine=hppa1.1-hitachi
- os=hiuxwe2
- ;;
- hp300-*)
- basic_machine=m68k-hp
+ cpu=hppa1.1
+ vendor=hitachi
+ basic_os=hiuxwe2
;;
hp3k9[0-9][0-9] | hp9[0-9][0-9])
- basic_machine=hppa1.0-hp
+ cpu=hppa1.0
+ vendor=hp
;;
hp9k2[0-9][0-9] | hp9k31[0-9])
- basic_machine=m68000-hp
+ cpu=m68000
+ vendor=hp
;;
hp9k3[2-9][0-9])
- basic_machine=m68k-hp
+ cpu=m68k
+ vendor=hp
;;
hp9k6[0-9][0-9] | hp6[0-9][0-9])
- basic_machine=hppa1.0-hp
+ cpu=hppa1.0
+ vendor=hp
;;
hp9k7[0-79][0-9] | hp7[0-79][0-9])
- basic_machine=hppa1.1-hp
+ cpu=hppa1.1
+ vendor=hp
;;
hp9k78[0-9] | hp78[0-9])
# FIXME: really hppa2.0-hp
- basic_machine=hppa1.1-hp
+ cpu=hppa1.1
+ vendor=hp
;;
hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893)
# FIXME: really hppa2.0-hp
- basic_machine=hppa1.1-hp
+ cpu=hppa1.1
+ vendor=hp
;;
hp9k8[0-9][13679] | hp8[0-9][13679])
- basic_machine=hppa1.1-hp
+ cpu=hppa1.1
+ vendor=hp
;;
hp9k8[0-9][0-9] | hp8[0-9][0-9])
- basic_machine=hppa1.0-hp
- ;;
- i370-ibm* | ibm*)
- basic_machine=i370-ibm
+ cpu=hppa1.0
+ vendor=hp
;;
i*86v32)
- basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
- os=sysv32
+ cpu=`echo "$1" | sed -e 's/86.*/86/'`
+ vendor=pc
+ basic_os=sysv32
;;
i*86v4*)
- basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
- os=sysv4
+ cpu=`echo "$1" | sed -e 's/86.*/86/'`
+ vendor=pc
+ basic_os=sysv4
;;
i*86v)
- basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
- os=sysv
+ cpu=`echo "$1" | sed -e 's/86.*/86/'`
+ vendor=pc
+ basic_os=sysv
;;
i*86sol2)
- basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'`
- os=solaris2
+ cpu=`echo "$1" | sed -e 's/86.*/86/'`
+ vendor=pc
+ basic_os=solaris2
;;
j90 | j90-cray)
- basic_machine=j90-cray
- os=${os:-unicos}
+ cpu=j90
+ vendor=cray
+ basic_os=${basic_os:-unicos}
;;
iris | iris4d)
- basic_machine=mips-sgi
- case $os in
+ cpu=mips
+ vendor=sgi
+ case $basic_os in
irix*)
;;
*)
- os=irix4
+ basic_os=irix4
;;
esac
;;
- leon-*|leon[3-9]-*)
- basic_machine=sparc-`echo "$basic_machine" | sed 's/-.*//'`
- ;;
- m68knommu-*)
- basic_machine=m68k-`echo "$basic_machine" | sed 's/^[^-]*-//'`
- os=linux
- ;;
- microblaze*)
- basic_machine=microblaze-xilinx
- ;;
miniframe)
- basic_machine=m68000-convergent
+ cpu=m68000
+ vendor=convergent
;;
*mint | mint[0-9]* | *MiNT | *MiNT[0-9]*)
- basic_machine=m68k-atari
- os=mint
- ;;
- mips3*-*)
- basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'`
- ;;
- mips3*)
- basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'`-unknown
- ;;
- ms1-*)
- basic_machine=`echo "$basic_machine" | sed -e 's/ms1-/mt-/'`
+ cpu=m68k
+ vendor=atari
+ basic_os=mint
;;
news-3600 | risc-news)
- basic_machine=mips-sony
- os=newsos
+ cpu=mips
+ vendor=sony
+ basic_os=newsos
;;
next | m*-next)
- basic_machine=m68k-next
- case $os in
- nextstep* )
+ cpu=m68k
+ vendor=next
+ case $basic_os in
+ openstep*)
+ ;;
+ nextstep*)
;;
ns2*)
- os=nextstep2
+ basic_os=nextstep2
;;
*)
- os=nextstep3
+ basic_os=nextstep3
;;
esac
;;
np1)
- basic_machine=np1-gould
+ cpu=np1
+ vendor=gould
;;
- neo-tandem)
- basic_machine=neo-tandem
+ op50n-* | op60c-*)
+ cpu=hppa1.1
+ vendor=oki
+ basic_os=proelf
;;
- nse-tandem)
- basic_machine=nse-tandem
+ pa-hitachi)
+ cpu=hppa1.1
+ vendor=hitachi
+ basic_os=hiuxwe2
;;
- nsr-tandem)
- basic_machine=nsr-tandem
+ pbd)
+ cpu=sparc
+ vendor=tti
;;
- nsv-tandem)
- basic_machine=nsv-tandem
+ pbb)
+ cpu=m68k
+ vendor=tti
;;
- nsx-tandem)
- basic_machine=nsx-tandem
+ pc532)
+ cpu=ns32k
+ vendor=pc532
;;
- op50n-* | op60c-*)
- basic_machine=hppa1.1-oki
- os=proelf
+ pn)
+ cpu=pn
+ vendor=gould
;;
- openrisc | openrisc-*)
- basic_machine=or32-unknown
+ power)
+ cpu=power
+ vendor=ibm
;;
- pa-hitachi)
- basic_machine=hppa1.1-hitachi
- os=hiuxwe2
+ ps2)
+ cpu=i386
+ vendor=ibm
;;
- parisc-*)
- basic_machine=hppa-`echo "$basic_machine" | sed 's/^[^-]*-//'`
- os=linux
+ rm[46]00)
+ cpu=mips
+ vendor=siemens
;;
- pbd)
- basic_machine=sparc-tti
+ rtpc | rtpc-*)
+ cpu=romp
+ vendor=ibm
;;
- pbb)
- basic_machine=m68k-tti
+ sde)
+ cpu=mipsisa32
+ vendor=sde
+ basic_os=${basic_os:-elf}
;;
- pc532 | pc532-*)
- basic_machine=ns32k-pc532
+ simso-wrs)
+ cpu=sparclite
+ vendor=wrs
+ basic_os=vxworks
;;
- pc98)
- basic_machine=i386-pc
+ tower | tower-32)
+ cpu=m68k
+ vendor=ncr
;;
- pc98-*)
- basic_machine=i386-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ vpp*|vx|vx-*)
+ cpu=f301
+ vendor=fujitsu
;;
- pentium | p5 | k5 | k6 | nexgen | viac3)
- basic_machine=i586-pc
+ w65)
+ cpu=w65
+ vendor=wdc
;;
- pentiumpro | p6 | 6x86 | athlon | athlon_*)
- basic_machine=i686-pc
+ w89k-*)
+ cpu=hppa1.1
+ vendor=winbond
+ basic_os=proelf
;;
- pentiumii | pentium2 | pentiumiii | pentium3)
- basic_machine=i686-pc
+ none)
+ cpu=none
+ vendor=none
;;
- pentium4)
- basic_machine=i786-pc
+ leon|leon[3-9])
+ cpu=sparc
+ vendor=$basic_machine
;;
- pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
- basic_machine=i586-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ leon-*|leon[3-9]-*)
+ cpu=sparc
+ vendor=`echo "$basic_machine" | sed 's/-.*//'`
;;
- pentiumpro-* | p6-* | 6x86-* | athlon-*)
- basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+
+ *-*)
+ # shellcheck disable=SC2162
+ IFS="-" read cpu vendor <<EOF
+$basic_machine
+EOF
;;
- pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
- basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ # We use `pc' rather than `unknown'
+ # because (1) that's what they normally are, and
+ # (2) the word "unknown" tends to confuse beginning users.
+ i*86 | x86_64)
+ cpu=$basic_machine
+ vendor=pc
;;
- pentium4-*)
- basic_machine=i786-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ # These rules are duplicated from below for sake of the special case above;
+ # i.e. things that normalized to x86 arches should also default to "pc"
+ pc98)
+ cpu=i386
+ vendor=pc
;;
- pn)
- basic_machine=pn-gould
+ x64 | amd64)
+ cpu=x86_64
+ vendor=pc
;;
- power) basic_machine=power-ibm
+ # Recognize the basic CPU types without company name.
+ *)
+ cpu=$basic_machine
+ vendor=unknown
;;
- ppc | ppcbe) basic_machine=powerpc-unknown
+esac
+
+unset -v basic_machine
+
+# Decode basic machines in the full and proper CPU-Company form.
+case $cpu-$vendor in
+ # Here we handle the default manufacturer of certain CPU types in canonical form. It is in
+ # some cases the only manufacturer, in others, it is the most popular.
+ craynv-unknown)
+ vendor=cray
+ basic_os=${basic_os:-unicosmp}
;;
- ppc-* | ppcbe-*)
- basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ c90-unknown | c90-cray)
+ vendor=cray
+ basic_os=${Basic_os:-unicos}
;;
- ppcle | powerpclittle)
- basic_machine=powerpcle-unknown
+ fx80-unknown)
+ vendor=alliant
;;
- ppcle-* | powerpclittle-*)
- basic_machine=powerpcle-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ romp-unknown)
+ vendor=ibm
;;
- ppc64) basic_machine=powerpc64-unknown
+ mmix-unknown)
+ vendor=knuth
;;
- ppc64-*) basic_machine=powerpc64-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ microblaze-unknown | microblazeel-unknown)
+ vendor=xilinx
;;
- ppc64le | powerpc64little)
- basic_machine=powerpc64le-unknown
+ rs6000-unknown)
+ vendor=ibm
;;
- ppc64le-* | powerpc64little-*)
- basic_machine=powerpc64le-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ vax-unknown)
+ vendor=dec
;;
- ps2)
- basic_machine=i386-ibm
+ pdp11-unknown)
+ vendor=dec
;;
- rm[46]00)
- basic_machine=mips-siemens
+ we32k-unknown)
+ vendor=att
;;
- rtpc | rtpc-*)
- basic_machine=romp-ibm
+ cydra-unknown)
+ vendor=cydrome
;;
- s390 | s390-*)
- basic_machine=s390-ibm
+ i370-ibm*)
+ vendor=ibm
;;
- s390x | s390x-*)
- basic_machine=s390x-ibm
+ orion-unknown)
+ vendor=highlevel
;;
- sb1)
- basic_machine=mipsisa64sb1-unknown
+ xps-unknown | xps100-unknown)
+ cpu=xps100
+ vendor=honeywell
;;
- sb1el)
- basic_machine=mipsisa64sb1el-unknown
+
+ # Here we normalize CPU types with a missing or matching vendor
+ dpx20-unknown | dpx20-bull)
+ cpu=rs6000
+ vendor=bull
+ basic_os=${basic_os:-bosx}
;;
- sde)
- basic_machine=mipsisa32-sde
- os=${os:-elf}
+
+ # Here we normalize CPU types irrespective of the vendor
+ amd64-*)
+ cpu=x86_64
;;
- sequent)
- basic_machine=i386-sequent
+ blackfin-*)
+ cpu=bfin
+ basic_os=linux
;;
- sh5el)
- basic_machine=sh5le-unknown
+ c54x-*)
+ cpu=tic54x
;;
- simso-wrs)
- basic_machine=sparclite-wrs
- os=vxworks
+ c55x-*)
+ cpu=tic55x
;;
- spur)
- basic_machine=spur-unknown
+ c6x-*)
+ cpu=tic6x
;;
- st2000)
- basic_machine=m68k-tandem
+ e500v[12]-*)
+ cpu=powerpc
+ basic_os=${basic_os}"spe"
;;
- strongarm-* | thumb-*)
- basic_machine=arm-`echo "$basic_machine" | sed 's/^[^-]*-//'`
+ mips3*-*)
+ cpu=mips64
;;
- sun2)
- basic_machine=m68000-sun
+ ms1-*)
+ cpu=mt
;;
- sun3 | sun3-*)
- basic_machine=m68k-sun
+ m68knommu-*)
+ cpu=m68k
+ basic_os=linux
;;
- sun4)
- basic_machine=sparc-sun
+ m9s12z-* | m68hcs12z-* | hcs12z-* | s12z-*)
+ cpu=s12z
;;
- sun386 | sun386i | roadrunner)
- basic_machine=i386-sun
+ openrisc-*)
+ cpu=or32
;;
- tile*)
- basic_machine=$basic_machine-unknown
- os=linux-gnu
+ parisc-*)
+ cpu=hppa
+ basic_os=linux
;;
- tx39)
- basic_machine=mipstx39-unknown
+ pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
+ cpu=i586
;;
- tx39el)
- basic_machine=mipstx39el-unknown
+ pentiumpro-* | p6-* | 6x86-* | athlon-* | athalon_*-*)
+ cpu=i686
;;
- tower | tower-32)
- basic_machine=m68k-ncr
+ pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
+ cpu=i686
;;
- vpp*|vx|vx-*)
- basic_machine=f301-fujitsu
+ pentium4-*)
+ cpu=i786
;;
- w65*)
- basic_machine=w65-wdc
- os=none
+ pc98-*)
+ cpu=i386
;;
- w89k-*)
- basic_machine=hppa1.1-winbond
- os=proelf
+ ppc-* | ppcbe-*)
+ cpu=powerpc
;;
- x64)
- basic_machine=x86_64-pc
+ ppcle-* | powerpclittle-*)
+ cpu=powerpcle
;;
- xps | xps100)
- basic_machine=xps100-honeywell
+ ppc64-*)
+ cpu=powerpc64
;;
- xscale-* | xscalee[bl]-*)
- basic_machine=`echo "$basic_machine" | sed 's/^xscale/arm/'`
+ ppc64le-* | powerpc64little-*)
+ cpu=powerpc64le
;;
- none)
- basic_machine=none-none
- os=${os:-none}
+ sb1-*)
+ cpu=mipsisa64sb1
;;
-
-# Here we handle the default manufacturer of certain CPU types. It is in
-# some cases the only manufacturer, in others, it is the most popular.
- w89k)
- basic_machine=hppa1.1-winbond
+ sb1el-*)
+ cpu=mipsisa64sb1el
;;
- op50n)
- basic_machine=hppa1.1-oki
+ sh5e[lb]-*)
+ cpu=`echo "$cpu" | sed 's/^\(sh.\)e\(.\)$/\1\2e/'`
;;
- op60c)
- basic_machine=hppa1.1-oki
+ spur-*)
+ cpu=spur
;;
- romp)
- basic_machine=romp-ibm
+ strongarm-* | thumb-*)
+ cpu=arm
;;
- mmix)
- basic_machine=mmix-knuth
+ tx39-*)
+ cpu=mipstx39
;;
- rs6000)
- basic_machine=rs6000-ibm
+ tx39el-*)
+ cpu=mipstx39el
;;
- vax)
- basic_machine=vax-dec
+ x64-*)
+ cpu=x86_64
;;
- pdp11)
- basic_machine=pdp11-dec
+ xscale-* | xscalee[bl]-*)
+ cpu=`echo "$cpu" | sed 's/^xscale/arm/'`
;;
- we32k)
- basic_machine=we32k-att
+ arm64-*)
+ cpu=aarch64
;;
- sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele)
- basic_machine=sh-unknown
+
+ # Recognize the canonical CPU Types that limit and/or modify the
+ # company names they are paired with.
+ cr16-*)
+ basic_os=${basic_os:-elf}
;;
- cydra)
- basic_machine=cydra-cydrome
+ crisv32-* | etraxfs*-*)
+ cpu=crisv32
+ vendor=axis
;;
- orion)
- basic_machine=orion-highlevel
+ cris-* | etrax*-*)
+ cpu=cris
+ vendor=axis
;;
- orion105)
- basic_machine=clipper-highlevel
+ crx-*)
+ basic_os=${basic_os:-elf}
;;
- mac | mpw | mac-mpw)
- basic_machine=m68k-apple
+ neo-tandem)
+ cpu=neo
+ vendor=tandem
;;
- pmac | pmac-mpw)
- basic_machine=powerpc-apple
+ nse-tandem)
+ cpu=nse
+ vendor=tandem
;;
- *-unknown)
- # Make sure to match an already-canonicalized machine name.
+ nsr-tandem)
+ cpu=nsr
+ vendor=tandem
+ ;;
+ nsv-tandem)
+ cpu=nsv
+ vendor=tandem
;;
+ nsx-tandem)
+ cpu=nsx
+ vendor=tandem
+ ;;
+ mipsallegrexel-sony)
+ cpu=mipsallegrexel
+ vendor=sony
+ ;;
+ tile*-*)
+ basic_os=${basic_os:-linux-gnu}
+ ;;
+
*)
- echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2
- exit 1
+ # Recognize the canonical CPU types that are allowed with any
+ # company name.
+ case $cpu in
+ 1750a | 580 \
+ | a29k \
+ | aarch64 | aarch64_be \
+ | abacus \
+ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] \
+ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] \
+ | alphapca5[67] | alpha64pca5[67] \
+ | am33_2.0 \
+ | amdgcn \
+ | arc | arceb \
+ | arm | arm[lb]e | arme[lb] | armv* \
+ | avr | avr32 \
+ | asmjs \
+ | ba \
+ | be32 | be64 \
+ | bfin | bpf | bs2000 \
+ | c[123]* | c30 | [cjt]90 | c4x \
+ | c8051 | clipper | craynv | csky | cydra \
+ | d10v | d30v | dlx | dsp16xx \
+ | e2k | elxsi | epiphany \
+ | f30[01] | f700 | fido | fr30 | frv | ft32 | fx80 \
+ | h8300 | h8500 \
+ | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
+ | hexagon \
+ | i370 | i*86 | i860 | i960 | ia16 | ia64 \
+ | ip2k | iq2000 \
+ | k1om \
+ | le32 | le64 \
+ | lm32 \
+ | m32c | m32r | m32rle \
+ | m5200 | m68000 | m680[012346]0 | m68360 | m683?2 | m68k \
+ | m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x \
+ | m88110 | m88k | maxq | mb | mcore | mep | metag \
+ | microblaze | microblazeel \
+ | mips | mipsbe | mipseb | mipsel | mipsle \
+ | mips16 \
+ | mips64 | mips64eb | mips64el \
+ | mips64octeon | mips64octeonel \
+ | mips64orion | mips64orionel \
+ | mips64r5900 | mips64r5900el \
+ | mips64vr | mips64vrel \
+ | mips64vr4100 | mips64vr4100el \
+ | mips64vr4300 | mips64vr4300el \
+ | mips64vr5000 | mips64vr5000el \
+ | mips64vr5900 | mips64vr5900el \
+ | mipsisa32 | mipsisa32el \
+ | mipsisa32r2 | mipsisa32r2el \
+ | mipsisa32r6 | mipsisa32r6el \
+ | mipsisa64 | mipsisa64el \
+ | mipsisa64r2 | mipsisa64r2el \
+ | mipsisa64r6 | mipsisa64r6el \
+ | mipsisa64sb1 | mipsisa64sb1el \
+ | mipsisa64sr71k | mipsisa64sr71kel \
+ | mipsr5900 | mipsr5900el \
+ | mipstx39 | mipstx39el \
+ | mmix \
+ | mn10200 | mn10300 \
+ | moxie \
+ | mt \
+ | msp430 \
+ | nds32 | nds32le | nds32be \
+ | nfp \
+ | nios | nios2 | nios2eb | nios2el \
+ | none | np1 | ns16k | ns32k | nvptx \
+ | open8 \
+ | or1k* \
+ | or32 \
+ | orion \
+ | picochip \
+ | pdp10 | pdp11 | pj | pjl | pn | power \
+ | powerpc | powerpc64 | powerpc64le | powerpcle | powerpcspe \
+ | pru \
+ | pyramid \
+ | riscv | riscv32 | riscv64 \
+ | rl78 | romp | rs6000 | rx \
+ | s390 | s390x \
+ | score \
+ | sh | shl \
+ | sh[1234] | sh[24]a | sh[24]ae[lb] | sh[23]e | she[lb] | sh[lb]e \
+ | sh[1234]e[lb] | sh[12345][lb]e | sh[23]ele | sh64 | sh64le \
+ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet \
+ | sparclite \
+ | sparcv8 | sparcv9 | sparcv9b | sparcv9v | sv1 | sx* \
+ | spu \
+ | tahoe \
+ | tic30 | tic4x | tic54x | tic55x | tic6x | tic80 \
+ | tron \
+ | ubicom32 \
+ | v70 | v850 | v850e | v850e1 | v850es | v850e2 | v850e2v3 \
+ | vax \
+ | visium \
+ | w65 \
+ | wasm32 | wasm64 \
+ | we32k \
+ | x86 | x86_64 | xc16x | xgate | xps100 \
+ | xstormy16 | xtensa* \
+ | ymp \
+ | z8k | z80)
+ ;;
+
+ *)
+ echo Invalid configuration \`"$1"\': machine \`"$cpu-$vendor"\' not recognized 1>&2
+ exit 1
+ ;;
+ esac
;;
esac
# Here we canonicalize certain aliases for manufacturers.
-case $basic_machine in
- *-digital*)
- basic_machine=`echo "$basic_machine" | sed 's/digital.*/dec/'`
+case $vendor in
+ digital*)
+ vendor=dec
;;
- *-commodore*)
- basic_machine=`echo "$basic_machine" | sed 's/commodore.*/cbm/'`
+ commodore*)
+ vendor=cbm
;;
*)
;;
@@ -1286,8 +1278,43 @@ esac
# Decode manufacturer-specific aliases for certain operating systems.
-if [ x$os != x ]
+if test x$basic_os != x
then
+
+# First recognize some ad-hoc caes, or perhaps split kernel-os, or else just
+# set os.
+case $basic_os in
+ gnu/linux*)
+ kernel=linux
+ os=`echo $basic_os | sed -e 's|gnu/linux|gnu|'`
+ ;;
+ nto-qnx*)
+ kernel=nto
+ os=`echo $basic_os | sed -e 's|nto-qnx|qnx|'`
+ ;;
+ *-*)
+ # shellcheck disable=SC2162
+ IFS="-" read kernel os <<EOF
+$basic_os
+EOF
+ ;;
+ # Default OS when just kernel was specified
+ nto*)
+ kernel=nto
+ os=`echo $basic_os | sed -e 's|nto|qnx|'`
+ ;;
+ linux*)
+ kernel=linux
+ os=`echo $basic_os | sed -e 's|linux|gnu|'`
+ ;;
+ *)
+ kernel=
+ os=$basic_os
+ ;;
+esac
+
+# Now, normalize the OS (knowing we just have one component, it's not a kernel,
+# etc.)
case $os in
# First match some system type aliases that might get confused
# with valid system types.
@@ -1307,9 +1334,6 @@ case $os in
unixware*)
os=sysv4.2uw
;;
- gnu/linux*)
- os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
- ;;
# es1800 is here to avoid being matched by es* (a different OS)
es1800*)
os=ose
@@ -1333,10 +1357,7 @@ case $os in
sco3.2.[4-9]*)
os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
;;
- sco3.2v[4-9]* | sco5v6*)
- # Don't forget version if it is 3.2v4 or newer.
- ;;
- scout)
+ sco*v* | scout)
# Don't match below
;;
sco*)
@@ -1345,43 +1366,9 @@ case $os in
psos*)
os=psos
;;
- # Now accept the basic system types.
- # The portable systems comes first.
- # Each alternative MUST end in a * to match a version number.
- # sysv* is not here because it comes later, after sysvr4.
- gnu* | bsd* | mach* | minix* | genix* | ultrix* | irix* \
- | *vms* | esix* | aix* | cnk* | sunos | sunos[34]*\
- | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \
- | sym* | kopensolaris* | plan9* \
- | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \
- | aos* | aros* | cloudabi* | sortix* \
- | nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \
- | clix* | riscos* | uniplus* | iris* | rtu* | xenix* \
- | knetbsd* | mirbsd* | netbsd* \
- | bitrig* | openbsd* | solidbsd* | libertybsd* \
- | ekkobsd* | kfreebsd* | freebsd* | riscix* | lynxos* \
- | bosx* | nextstep* | cxux* | aout* | elf* | oabi* \
- | ptx* | coff* | ecoff* | winnt* | domain* | vsta* \
- | udi* | eabi* | lites* | ieee* | go32* | aux* | hcos* \
- | chorusrdb* | cegcc* | glidix* \
- | cygwin* | msys* | pe* | moss* | proelf* | rtems* \
- | midipix* | mingw32* | mingw64* | linux-gnu* | linux-android* \
- | linux-newlib* | linux-musl* | linux-uclibc* \
- | uxpv* | beos* | mpeix* | udk* | moxiebox* \
- | interix* | uwin* | mks* | rhapsody* | darwin* \
- | openstep* | oskit* | conix* | pw32* | nonstopux* \
- | storm-chaos* | tops10* | tenex* | tops20* | its* \
- | os2* | vos* | palmos* | uclinux* | nucleus* \
- | morphos* | superux* | rtmk* | windiss* \
- | powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \
- | skyos* | haiku* | rdos* | toppers* | drops* | es* \
- | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \
- | midnightbsd*)
- # Remember, each alternative MUST END IN *, to match a version number.
- ;;
qnx*)
- case $basic_machine in
- x86-* | i*86-*)
+ case $cpu in
+ x86 | i*86)
;;
*)
os=nto-$os
@@ -1391,31 +1378,19 @@ case $os in
hiux*)
os=hiuxwe2
;;
- nto-qnx*)
- ;;
- nto*)
- os=`echo $os | sed -e 's|nto|nto-qnx|'`
- ;;
- sim | xray | os68k* | v88r* \
- | windows* | osx | abug | netware* | os9* \
- | macos* | mpw* | magic* | mmixware* | mon960* | lnews*)
- ;;
- linux-dietlibc)
- os=linux-dietlibc
- ;;
- linux*)
- os=`echo $os | sed -e 's|linux|linux-gnu|'`
- ;;
lynx*178)
os=lynxos178
;;
lynx*5)
os=lynxos5
;;
+ lynxos*)
+ # don't get caught up in next wildcard
+ ;;
lynx*)
os=lynxos
;;
- mac*)
+ mac[0-9]*)
os=`echo "$os" | sed -e 's|mac|macos|'`
;;
opened*)
@@ -1460,9 +1435,6 @@ case $os in
ns2)
os=nextstep2
;;
- nsk*)
- os=nsk
- ;;
# Preserve the version number of sinix5.
sinix5.*)
os=`echo $os | sed -e 's|sinix|sysv|'`
@@ -1488,18 +1460,12 @@ case $os in
sysvr4)
os=sysv4
;;
- # This must come after sysvr4.
- sysv*)
- ;;
ose*)
os=ose
;;
*mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
os=mint
;;
- zvmoe)
- os=zvmoe
- ;;
dicos*)
os=dicos
;;
@@ -1507,7 +1473,7 @@ case $os in
# Until real need of OS specific support for
# particular features comes up, bare metal
# configurations are quite functional.
- case $basic_machine in
+ case $cpu in
arm*)
os=eabi
;;
@@ -1516,19 +1482,11 @@ case $os in
;;
esac
;;
- nacl*)
- ;;
- ios)
- ;;
- none)
- ;;
- *-eabi)
- ;;
*)
- echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2
- exit 1
+ # No normalization, but not necessarily accepted, that comes below.
;;
esac
+
else
# Here we handle the default operating systems that come with various machines.
@@ -1541,7 +1499,8 @@ else
# will signal an error saying that MANUFACTURER isn't an operating
# system, and we'll never get to this point.
-case $basic_machine in
+kernel=
+case $cpu-$vendor in
score-*)
os=elf
;;
@@ -1552,7 +1511,8 @@ case $basic_machine in
os=riscix1.2
;;
arm*-rebel)
- os=linux
+ kernel=linux
+ os=gnu
;;
arm*-semi)
os=aout
@@ -1718,86 +1678,169 @@ case $basic_machine in
os=none
;;
esac
+
fi
+# Now, validate our (potentially fixed-up) OS.
+case $os in
+ # Sometimes we do "kernel-abi", so those need to count as OSes.
+ musl* | newlib* | uclibc*)
+ ;;
+ # Likewise for "kernel-libc"
+ eabi | eabihf | gnueabi | gnueabihf)
+ ;;
+ # Now accept the basic system types.
+ # The portable systems comes first.
+ # Each alternative MUST end in a * to match a version number.
+ gnu* | android* | bsd* | mach* | minix* | genix* | ultrix* | irix* \
+ | *vms* | esix* | aix* | cnk* | sunos | sunos[34]* \
+ | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \
+ | sym* | plan9* | psp* | sim* | xray* | os68k* | v88r* \
+ | hiux* | abug | nacl* | netware* | windows* \
+ | os9* | macos* | osx* | ios* \
+ | mpw* | magic* | mmixware* | mon960* | lnews* \
+ | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \
+ | aos* | aros* | cloudabi* | sortix* | twizzler* \
+ | nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \
+ | clix* | riscos* | uniplus* | iris* | isc* | rtu* | xenix* \
+ | mirbsd* | netbsd* | dicos* | openedition* | ose* \
+ | bitrig* | openbsd* | solidbsd* | libertybsd* | os108* \
+ | ekkobsd* | freebsd* | riscix* | lynxos* | os400* \
+ | bosx* | nextstep* | cxux* | aout* | elf* | oabi* \
+ | ptx* | coff* | ecoff* | winnt* | domain* | vsta* \
+ | udi* | lites* | ieee* | go32* | aux* | hcos* \
+ | chorusrdb* | cegcc* | glidix* \
+ | cygwin* | msys* | pe* | moss* | proelf* | rtems* \
+ | midipix* | mingw32* | mingw64* | mint* \
+ | uxpv* | beos* | mpeix* | udk* | moxiebox* \
+ | interix* | uwin* | mks* | rhapsody* | darwin* \
+ | openstep* | oskit* | conix* | pw32* | nonstopux* \
+ | storm-chaos* | tops10* | tenex* | tops20* | its* \
+ | os2* | vos* | palmos* | uclinux* | nucleus* | morphos* \
+ | scout* | superux* | sysv* | rtmk* | tpf* | windiss* \
+ | powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \
+ | skyos* | haiku* | rdos* | toppers* | drops* | es* \
+ | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \
+ | midnightbsd* | amdhsa* | unleashed* | emscripten* | wasi* \
+ | nsk* | powerunix* | genode* | zvmoe* )
+ ;;
+ # This one is extra strict with allowed versions
+ sco3.2v2 | sco3.2v[4-9]* | sco5v6*)
+ # Don't forget version if it is 3.2v4 or newer.
+ ;;
+ none)
+ ;;
+ *)
+ echo Invalid configuration \`"$1"\': OS \`"$os"\' not recognized 1>&2
+ exit 1
+ ;;
+esac
+
+# As a final step for OS-related things, validate the OS-kernel combination
+# (given a valid OS), if there is a kernel.
+case $kernel-$os in
+ linux-gnu* | linux-dietlibc* | linux-android* | linux-newlib* | linux-musl* | linux-uclibc* )
+ ;;
+ -dietlibc* | -newlib* | -musl* | -uclibc* )
+ # These are just libc implementations, not actual OSes, and thus
+ # require a kernel.
+ echo "Invalid configuration \`$1': libc \`$os' needs explicit kernel." 1>&2
+ exit 1
+ ;;
+ kfreebsd*-gnu* | kopensolaris*-gnu*)
+ ;;
+ nto-qnx*)
+ ;;
+ *-eabi* | *-gnueabi*)
+ ;;
+ -*)
+ # Blank kernel with real OS is always fine.
+ ;;
+ *-*)
+ echo "Invalid configuration \`$1': Kernel \`$kernel' not known to work with OS \`$os'." 1>&2
+ exit 1
+ ;;
+esac
+
# Here we handle the case where we know the os, and the CPU type, but not the
# manufacturer. We pick the logical manufacturer.
-vendor=unknown
-case $basic_machine in
- *-unknown)
- case $os in
- riscix*)
+case $vendor in
+ unknown)
+ case $cpu-$os in
+ *-riscix*)
vendor=acorn
;;
- sunos*)
+ *-sunos*)
vendor=sun
;;
- cnk*|-aix*)
+ *-cnk* | *-aix*)
vendor=ibm
;;
- beos*)
+ *-beos*)
vendor=be
;;
- hpux*)
+ *-hpux*)
vendor=hp
;;
- mpeix*)
+ *-mpeix*)
vendor=hp
;;
- hiux*)
+ *-hiux*)
vendor=hitachi
;;
- unos*)
+ *-unos*)
vendor=crds
;;
- dgux*)
+ *-dgux*)
vendor=dg
;;
- luna*)
+ *-luna*)
vendor=omron
;;
- genix*)
+ *-genix*)
vendor=ns
;;
- clix*)
+ *-clix*)
vendor=intergraph
;;
- mvs* | opened*)
+ *-mvs* | *-opened*)
+ vendor=ibm
+ ;;
+ *-os400*)
vendor=ibm
;;
- os400*)
+ s390-* | s390x-*)
vendor=ibm
;;
- ptx*)
+ *-ptx*)
vendor=sequent
;;
- tpf*)
+ *-tpf*)
vendor=ibm
;;
- vxsim* | vxworks* | windiss*)
+ *-vxsim* | *-vxworks* | *-windiss*)
vendor=wrs
;;
- aux*)
+ *-aux*)
vendor=apple
;;
- hms*)
+ *-hms*)
vendor=hitachi
;;
- mpw* | macos*)
+ *-mpw* | *-macos*)
vendor=apple
;;
- *mint | mint[0-9]* | *MiNT | MiNT[0-9]*)
+ *-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*)
vendor=atari
;;
- vos*)
+ *-vos*)
vendor=stratus
;;
esac
- basic_machine=`echo "$basic_machine" | sed "s/unknown/$vendor/"`
;;
esac
-echo "$basic_machine-$os"
+echo "$cpu-$vendor-${kernel:+$kernel-}$os"
exit
# Local variables:
diff --git a/configure b/configure
index 5b1b53de1533..1e5c94ceb37c 100755
--- a/configure
+++ b/configure
@@ -1,7 +1,8 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by Autoconf 2.52.20170501.
+# Generated by Autoconf 2.52.20210105.
#
+# Copyright 2003-2020,2021 Thomas E. Dickey
# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
# Free Software Foundation, Inc.
# This configure script is free software; the Free Software Foundation
@@ -59,9 +60,9 @@ as_executable_p="test -f"
# Support unset when possible.
if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
- as_unset=unset
+ as_unset="unset"
else
- as_unset=false
+ as_unset="false"
fi
# NLS nuisances.
@@ -96,13 +97,14 @@ exec 6>&1
ac_default_prefix=/usr/local
cross_compiling=no
subdirs=
-MFLAGS= MAKEFLAGS=
+MFLAGS=
+MAKEFLAGS=
SHELL=${CONFIG_SHELL-/bin/sh}
# Maximum number of lines to put in a shell here document.
# This variable seems obsolete. It should probably be removed, and
# only ac_max_sed_lines should be used.
-: ${ac_max_here_lines=38}
+: "${ac_max_here_lines=38}"
ac_unique_file="dialog.h"
# Factoring default headers for most tests.
@@ -175,6 +177,7 @@ datadir='${datarootdir}'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
+runstatedir='${localstatedir}/run'
libdir='${exec_prefix}/lib'
includedir='${prefix}/include'
oldincludedir='/usr/include'
@@ -202,7 +205,7 @@ do
# Accept the important Cygnus configure options, so we can diagnose typos.
- case $ac_option in
+ case "$ac_option" in
-bindir | --bindir | --bindi | --bind | --bin | --bi)
ac_prev=bindir ;;
@@ -243,7 +246,7 @@ do
expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid feature name: $ac_feature" >&2
{ (exit 1); exit 1; }; }
- ac_feature=`echo $ac_feature | sed 's/-/_/g'`
+ ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
eval "enable_$ac_feature=no" ;;
-enable-* | --enable-*)
@@ -252,8 +255,8 @@ do
expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid feature name: $ac_feature" >&2
{ (exit 1); exit 1; }; }
- ac_feature=`echo $ac_feature | sed 's/-/_/g'`
- case $ac_option in
+ ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
+ case "$ac_option" in
*=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
*) ac_optarg=yes ;;
esac
@@ -317,6 +320,15 @@ do
| --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
localstatedir=$ac_optarg ;;
+ -runstatedir | --runstatedir | --runstatedi | --runstated \
+ | --runstate | --runstat | --runsta | --runst \
+ | --runs | --run | --ru)
+ ac_prev=runstatedir ;;
+ -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
+ | --runstate=* | --runstat=* | --runsta=* | --runst=* \
+ | --runs=* | --run=* | --ru=*)
+ runstatedir=$ac_optarg ;;
+
-mandir | --mandir | --mandi | --mand | --man | --ma | --m)
ac_prev=mandir ;;
-mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
@@ -434,8 +446,8 @@ do
expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid package name: $ac_package" >&2
{ (exit 1); exit 1; }; }
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- case $ac_option in
+ ac_package=`echo "$ac_package" | sed 's/-/_/g'`
+ case "$ac_option" in
*=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
*) ac_optarg=yes ;;
esac
@@ -447,7 +459,7 @@ do
expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
{ echo "$as_me: error: invalid package name: $ac_package" >&2
{ (exit 1); exit 1; }; }
- ac_package=`echo $ac_package | sed 's/-/_/g'`
+ ac_package=`echo "$ac_package" | sed 's/-/_/g'`
eval "with_$ac_package=no" ;;
--x)
@@ -481,21 +493,21 @@ Try \`$0 --help' for more information." >&2
{ (exit 1); exit 1; }; }
ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
eval "$ac_envvar='$ac_optarg'"
- export $ac_envvar ;;
+ export "$ac_envvar" ;;
*)
# FIXME: should be removed in autoconf 3.0.
echo "$as_me: WARNING: you should use --build, --host, --target" >&2
expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
+ : "${build_alias=$ac_option}" "${host_alias=$ac_option}" "${target_alias=$ac_option}"
;;
esac
done
if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
+ ac_option=--`echo "$ac_prev" | sed 's/_/-/g'`
{ echo "$as_me: error: missing argument to $ac_option" >&2
{ (exit 1); exit 1; }; }
fi
@@ -503,8 +515,8 @@ fi
# Be sure to have absolute paths.
for ac_var in exec_prefix prefix
do
- eval ac_val=$`echo $ac_var`
- case $ac_val in
+ eval ac_val=$`echo "$ac_var"`
+ case "$ac_val" in
[\\/$]* | ?:[\\/]* | NONE | '' ) ;;
*) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
{ (exit 1); exit 1; }; };;
@@ -515,8 +527,8 @@ done
for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
localstatedir libdir includedir oldincludedir infodir mandir
do
- eval ac_val=$`echo $ac_var`
- case $ac_val in
+ eval ac_val=$`echo "$ac_var"`
+ case "$ac_val" in
[\\/$]* | ?:[\\/]* ) ;;
*) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
{ (exit 1); exit 1; }; };;
@@ -553,13 +565,13 @@ if test -z "$srcdir"; then
ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
srcdir=$ac_confdir
- if test ! -r $srcdir/$ac_unique_file; then
+ if test ! -r "$srcdir/$ac_unique_file"; then
srcdir=..
fi
else
ac_srcdir_defaulted=no
fi
-if test ! -r $srcdir/$ac_unique_file; then
+if test ! -r "$srcdir/$ac_unique_file"; then
if test "$ac_srcdir_defaulted" = yes; then
{ echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
{ (exit 1); exit 1; }; }
@@ -654,6 +666,7 @@ Fine tuning of the installation directories:
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
+ --runstatedir=DIR extra definition of runtime data [LOCALSTATEDIR/run]
--libdir=DIR object code libraries [EPREFIX/lib]
--includedir=DIR C header files [PREFIX/include]
--oldincludedir=DIR C header files for non-gcc [/usr/include]
@@ -693,7 +706,8 @@ Optional Packages:
--disable-echo do not display "compiling" commands
--disable-largefile omit support for large files
--with-install-prefix=XXX sets DESTDIR, useful for packaging
- --with-warnings test: turn on gcc warnings
+ --with-x use the X Window System
+ --enable-warnings test: turn on gcc compiler warnings
--with-pkg-config{=path} enable/disable use of pkg-config
--with-package=XXX rename dialog to XXX, library to libXXX.a, etc
--enable-header-subdir install dlg_XXX headers to subdirectory
@@ -710,6 +724,7 @@ Optional Packages:
--with-valgrind test: use valgrind
--with-no-leaks test: free permanent memory, analyze leaks
--disable-trace do not support --trace option
+ --enable-rpath use rpath option when generating shared libraries
--with-rel-version=XXX override derived release version
--with-abi-version=XXX override derived ABI version
--disable-libtool-version enable to use libtool's incompatible naming scheme
@@ -720,7 +735,6 @@ Optional Packages:
--with-shlib-version=X Specify rel or abi version for shared libs
--with-versioned-syms=X markup versioned symbols using ld
--with-curses-dir=DIR directory in which (n)curses is installed
- --enable-rpath use rpath option when generating shared libraries
--with-screen=XXX use specified curses-libraries
--with-ncursesw use wide ncurses-libraries
--with-ncurses use ncurses-libraries
@@ -731,9 +745,9 @@ Optional Packages:
--with-Xaw3dxft link with Xaw 3d xft library
--with-neXtaw link with neXT Athena library
--with-XawPlus link with Athena-Plus library
- --with-x use the X Window System
--disable-extras do not include extra dialogs
--disable-rc-file do not include config-file support
+ --disable-rc-file2 do not use extra attributes in config-file
--disable-Xdialog do not include Xdialog-style dialogs (1.1)
--disable-Xdialog2 do not include extra Xdialog-style dialogs (1.2)
--disable-whiptail do not map extra whiptail options
@@ -764,42 +778,43 @@ if test "$ac_init_help" = "recursive"; then
# If there are subdirs, report their specific --help.
ac_popdir=`pwd`
for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
- cd $ac_subdir
+ cd "$ac_subdir"
# A "../" for each directory in /$ac_subdir.
- ac_dots=`echo $ac_subdir |
+ ac_dots=`echo "$ac_subdir" |
sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
- case $srcdir in
+ case "$srcdir" in
.) # No --srcdir option. We are building in place.
- ac_sub_srcdir=$srcdir ;;
+ ac_sub_srcdir="$srcdir" ;;
[\\/]* | ?:[\\/]* ) # Absolute path.
- ac_sub_srcdir=$srcdir/$ac_subdir ;;
+ ac_sub_srcdir="$srcdir/$ac_subdir" ;;
*) # Relative path.
- ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
+ ac_sub_srcdir="$ac_dots$srcdir/$ac_subdir" ;;
esac
# Check for guested configure; otherwise get Cygnus style configure.
- if test -f $ac_sub_srcdir/configure.gnu; then
+ if test -f "$ac_sub_srcdir/configure.gnu"; then
echo
- $SHELL $ac_sub_srcdir/configure.gnu --help=recursive
- elif test -f $ac_sub_srcdir/configure; then
+ $SHELL "$ac_sub_srcdir/configure.gnu" --help=recursive
+ elif test -f "$ac_sub_srcdir/configure"; then
echo
- $SHELL $ac_sub_srcdir/configure --help=recursive
- elif test -f $ac_sub_srcdir/configure.ac ||
- test -f $ac_sub_srcdir/configure.in; then
+ $SHELL "$ac_sub_srcdir/configure" --help=recursive
+ elif test -f "$ac_sub_srcdir/configure.ac" ||
+ test -f "$ac_sub_srcdir/configure.in"; then
echo
- $ac_configure --help
+ "$ac_configure" --help
else
echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
fi
- cd $ac_popdir
+ cd "$ac_popdir"
done
fi
test -n "$ac_init_help" && exit 0
-if $ac_init_version; then
+if "$ac_init_version"; then
cat <<\EOF
+Copyright 2003-2020,2021 Thomas E. Dickey
Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
@@ -813,7 +828,7 @@ This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by $as_me, which was
-generated by GNU Autoconf 2.52.20170501. Invocation command line was
+generated by GNU Autoconf 2.52.20210105. Invocation command line was
$ $0 $@
@@ -860,7 +875,7 @@ ac_configure_args=
ac_sep=
for ac_arg
do
- case $ac_arg in
+ case "$ac_arg" in
-no-create | --no-create | --no-creat | --no-crea | --no-cre \
| --no-cr | --no-c) ;;
-no-recursion | --no-recursion | --no-recursio | --no-recursi \
@@ -917,7 +932,7 @@ trap 'exit_status=$?
exit $exit_status
' 0
for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
+ trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' "$ac_signal"
done
ac_signal=0
@@ -937,7 +952,7 @@ if test -z "$CONFIG_SITE"; then
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
- { echo "$as_me:940: loading site script $ac_site_file" >&5
+ { echo "$as_me:955: loading site script $ac_site_file" >&5
echo "$as_me: loading site script $ac_site_file" >&6;}
cat "$ac_site_file" >&5
. "$ac_site_file"
@@ -948,7 +963,7 @@ if test -r "$cache_file"; then
# Some versions of bash will fail to source /dev/null (special
# files actually), so we avoid doing that.
if test -f "$cache_file"; then
- { echo "$as_me:951: loading cache $cache_file" >&5
+ { echo "$as_me:966: loading cache $cache_file" >&5
echo "$as_me: loading cache $cache_file" >&6;}
case $cache_file in
[\\/]* | ?:[\\/]* ) . $cache_file;;
@@ -956,7 +971,7 @@ echo "$as_me: loading cache $cache_file" >&6;}
esac
fi
else
- { echo "$as_me:959: creating cache $cache_file" >&5
+ { echo "$as_me:974: creating cache $cache_file" >&5
echo "$as_me: creating cache $cache_file" >&6;}
>$cache_file
fi
@@ -970,23 +985,23 @@ for ac_var in `(set) 2>&1 |
eval ac_new_set=\$ac_env_${ac_var}_set
eval ac_old_val="\$ac_cv_env_${ac_var}_value"
eval ac_new_val="\$ac_env_${ac_var}_value"
- case $ac_old_set,$ac_new_set in
+ case "$ac_old_set,$ac_new_set" in
set,)
- { echo "$as_me:975: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
+ { echo "$as_me:990: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
ac_cache_corrupted=: ;;
,set)
- { echo "$as_me:979: error: \`$ac_var' was not set in the previous run" >&5
+ { echo "$as_me:994: error: \`$ac_var' was not set in the previous run" >&5
echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
ac_cache_corrupted=: ;;
,);;
*)
if test "x$ac_old_val" != "x$ac_new_val"; then
- { echo "$as_me:985: error: \`$ac_var' has changed since the previous run:" >&5
+ { echo "$as_me:1000: error: \`$ac_var' has changed since the previous run:" >&5
echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- { echo "$as_me:987: former value: $ac_old_val" >&5
+ { echo "$as_me:1002: former value: $ac_old_val" >&5
echo "$as_me: former value: $ac_old_val" >&2;}
- { echo "$as_me:989: current value: $ac_new_val" >&5
+ { echo "$as_me:1004: current value: $ac_new_val" >&5
echo "$as_me: current value: $ac_new_val" >&2;}
ac_cache_corrupted=:
fi;;
@@ -994,7 +1009,7 @@ echo "$as_me: current value: $ac_new_val" >&2;}
# Pass precious variables to config.status. It doesn't matter if
# we pass some twice (in addition to the command line arguments).
if test "$ac_new_set" = set; then
- case $ac_new_val in
+ case "$ac_new_val" in
*" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
ac_configure_args="$ac_configure_args '$ac_arg'"
@@ -1004,35 +1019,43 @@ echo "$as_me: current value: $ac_new_val" >&2;}
esac
fi
done
-if $ac_cache_corrupted; then
- { echo "$as_me:1008: error: changes in the environment can compromise the build" >&5
+if "$ac_cache_corrupted"; then
+ { echo "$as_me:1023: error: changes in the environment can compromise the build" >&5
echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- { { echo "$as_me:1010: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
+ { { echo "$as_me:1025: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
{ (exit 1); exit 1; }; }
fi
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
+ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-ac_main_return=return
+ac_main_return="return"
case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
- *c*,-n*) ECHO_N= ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
- ECHO_T=' ' ;;
- *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
- *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
+ *c*,-n*) ECHO_N=
+ ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
+ ECHO_T=' '
+ ;;
+ *c*,* ) ECHO_N=-n
+ ECHO_C=
+ ECHO_T=
+ ;;
+ *) ECHO_N=
+ ECHO_C='\c'
+ ECHO_T=
+ ;;
esac
echo "#! $SHELL" >conftest.sh
echo "exit 0" >>conftest.sh
chmod +x conftest.sh
-if { (echo "$as_me:1031: PATH=\".;.\"; conftest.sh") >&5
+if { (echo "$as_me:1054: PATH=\".;.\"; conftest.sh") >&5
(PATH=".;."; conftest.sh) 2>&5
ac_status=$?
- echo "$as_me:1034: \$? = $ac_status" >&5
- (exit $ac_status); }; then
+ echo "$as_me:1057: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; then
ac_path_separator=';'
else
ac_path_separator=:
@@ -1057,16 +1080,93 @@ rm conftest.sed
DESTDIR=
+ac_aux_dir=
+for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
+ if test -f "$ac_dir/install-sh"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f "$ac_dir/install.sh"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ elif test -f "$ac_dir/shtool"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/shtool install -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { { echo "$as_me:1100: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
+echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+ac_config_guess="$SHELL $ac_aux_dir/config.guess"
+ac_config_sub="$SHELL $ac_aux_dir/config.sub"
+ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
+
+# Make sure we can run config.sub.
+$ac_config_sub sun4 >/dev/null 2>&1 ||
+ { { echo "$as_me:1110: error: cannot run $ac_config_sub" >&5
+echo "$as_me: error: cannot run $ac_config_sub" >&2;}
+ { (exit 1); exit 1; }; }
+
+echo "$as_me:1114: checking build system type" >&5
+echo $ECHO_N "checking build system type... $ECHO_C" >&6
+if test "${ac_cv_build+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_cv_build_alias=$build_alias
+test -z "$ac_cv_build_alias" &&
+ ac_cv_build_alias=`$ac_config_guess`
+test -z "$ac_cv_build_alias" &&
+ { { echo "$as_me:1123: error: cannot guess build type; you must specify one" >&5
+echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
+ { (exit 1); exit 1; }; }
+ac_cv_build=`$ac_config_sub "$ac_cv_build_alias"` ||
+ { { echo "$as_me:1127: error: $ac_config_sub $ac_cv_build_alias failed." >&5
+echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
+ { (exit 1); exit 1; }; }
+
+fi
+echo "$as_me:1132: result: $ac_cv_build" >&5
+echo "${ECHO_T}$ac_cv_build" >&6
+build=$ac_cv_build
+build_cpu=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+build_vendor=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+build_os=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+
+echo "$as_me:1139: checking host system type" >&5
+echo $ECHO_N "checking host system type... $ECHO_C" >&6
+if test "${ac_cv_host+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_cv_host_alias=$host_alias
+test -z "$ac_cv_host_alias" &&
+ ac_cv_host_alias=$ac_cv_build_alias
+ac_cv_host=`$ac_config_sub "$ac_cv_host_alias"` ||
+ { { echo "$as_me:1148: error: $ac_config_sub $ac_cv_host_alias failed" >&5
+echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
+ { (exit 1); exit 1; }; }
+
+fi
+echo "$as_me:1153: result: $ac_cv_host" >&5
+echo "${ECHO_T}$ac_cv_host" >&6
+host=$ac_cv_host
+host_cpu=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+host_vendor=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+host_os=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
+ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-ac_main_return=return
+ac_main_return="return"
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
-echo "$as_me:1069: checking for $ac_word" >&5
+echo "$as_me:1169: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -1081,7 +1181,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_CC="${ac_tool_prefix}gcc"
-echo "$as_me:1084: found $ac_dir/$ac_word" >&5
+echo "$as_me:1184: found $ac_dir/$ac_word" >&5
break
done
@@ -1089,10 +1189,10 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:1092: result: $CC" >&5
+ echo "$as_me:1192: result: $CC" >&5
echo "${ECHO_T}$CC" >&6
else
- echo "$as_me:1095: result: no" >&5
+ echo "$as_me:1195: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -1101,7 +1201,7 @@ if test -z "$ac_cv_prog_CC"; then
ac_ct_CC=$CC
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
-echo "$as_me:1104: checking for $ac_word" >&5
+echo "$as_me:1204: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -1116,7 +1216,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_CC="gcc"
-echo "$as_me:1119: found $ac_dir/$ac_word" >&5
+echo "$as_me:1219: found $ac_dir/$ac_word" >&5
break
done
@@ -1124,10 +1224,10 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- echo "$as_me:1127: result: $ac_ct_CC" >&5
+ echo "$as_me:1227: result: $ac_ct_CC" >&5
echo "${ECHO_T}$ac_ct_CC" >&6
else
- echo "$as_me:1130: result: no" >&5
+ echo "$as_me:1230: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -1140,7 +1240,7 @@ if test -z "$CC"; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
set dummy ${ac_tool_prefix}cc; ac_word=$2
-echo "$as_me:1143: checking for $ac_word" >&5
+echo "$as_me:1243: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -1155,7 +1255,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_CC="${ac_tool_prefix}cc"
-echo "$as_me:1158: found $ac_dir/$ac_word" >&5
+echo "$as_me:1258: found $ac_dir/$ac_word" >&5
break
done
@@ -1163,10 +1263,10 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:1166: result: $CC" >&5
+ echo "$as_me:1266: result: $CC" >&5
echo "${ECHO_T}$CC" >&6
else
- echo "$as_me:1169: result: no" >&5
+ echo "$as_me:1269: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -1175,7 +1275,7 @@ if test -z "$ac_cv_prog_CC"; then
ac_ct_CC=$CC
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
-echo "$as_me:1178: checking for $ac_word" >&5
+echo "$as_me:1278: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -1190,7 +1290,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_CC="cc"
-echo "$as_me:1193: found $ac_dir/$ac_word" >&5
+echo "$as_me:1293: found $ac_dir/$ac_word" >&5
break
done
@@ -1198,10 +1298,10 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- echo "$as_me:1201: result: $ac_ct_CC" >&5
+ echo "$as_me:1301: result: $ac_ct_CC" >&5
echo "${ECHO_T}$ac_ct_CC" >&6
else
- echo "$as_me:1204: result: no" >&5
+ echo "$as_me:1304: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -1214,7 +1314,7 @@ fi
if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
-echo "$as_me:1217: checking for $ac_word" >&5
+echo "$as_me:1317: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -1234,11 +1334,11 @@ if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
continue
fi
ac_cv_prog_CC="cc"
-echo "$as_me:1237: found $ac_dir/$ac_word" >&5
+echo "$as_me:1337: found $ac_dir/$ac_word" >&5
break
done
-if test $ac_prog_rejected = yes; then
+if test "$ac_prog_rejected" = yes; then
# We found a bogon in the path, so make sure we never use it.
set dummy $ac_cv_prog_CC
shift
@@ -1256,10 +1356,10 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:1259: result: $CC" >&5
+ echo "$as_me:1359: result: $CC" >&5
echo "${ECHO_T}$CC" >&6
else
- echo "$as_me:1262: result: no" >&5
+ echo "$as_me:1362: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -1270,7 +1370,7 @@ if test -z "$CC"; then
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:1273: checking for $ac_word" >&5
+echo "$as_me:1373: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -1285,7 +1385,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
-echo "$as_me:1288: found $ac_dir/$ac_word" >&5
+echo "$as_me:1388: found $ac_dir/$ac_word" >&5
break
done
@@ -1293,10 +1393,10 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$as_me:1296: result: $CC" >&5
+ echo "$as_me:1396: result: $CC" >&5
echo "${ECHO_T}$CC" >&6
else
- echo "$as_me:1299: result: no" >&5
+ echo "$as_me:1399: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -1309,7 +1409,7 @@ if test -z "$CC"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:1312: checking for $ac_word" >&5
+echo "$as_me:1412: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -1324,7 +1424,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_CC="$ac_prog"
-echo "$as_me:1327: found $ac_dir/$ac_word" >&5
+echo "$as_me:1427: found $ac_dir/$ac_word" >&5
break
done
@@ -1332,10 +1432,10 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- echo "$as_me:1335: result: $ac_ct_CC" >&5
+ echo "$as_me:1435: result: $ac_ct_CC" >&5
echo "${ECHO_T}$ac_ct_CC" >&6
else
- echo "$as_me:1338: result: no" >&5
+ echo "$as_me:1438: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -1347,32 +1447,32 @@ fi
fi
-test -z "$CC" && { { echo "$as_me:1350: error: no acceptable cc found in \$PATH" >&5
+test -z "$CC" && { { echo "$as_me:1450: error: no acceptable cc found in \$PATH" >&5
echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
{ (exit 1); exit 1; }; }
# Provide some information about the compiler.
-echo "$as_me:1355:" \
+echo "$as_me:1455:" \
"checking for C compiler version" >&5
-ac_compiler=`set X $ac_compile; echo $2`
-{ (eval echo "$as_me:1358: \"$ac_compiler --version </dev/null >&5\"") >&5
+ac_compiler=`set X $ac_compile; echo "$2"`
+{ (eval echo "$as_me:1458: \"$ac_compiler --version </dev/null >&5\"") >&5
(eval $ac_compiler --version </dev/null >&5) 2>&5
ac_status=$?
- echo "$as_me:1361: \$? = $ac_status" >&5
- (exit $ac_status); }
-{ (eval echo "$as_me:1363: \"$ac_compiler -v </dev/null >&5\"") >&5
+ echo "$as_me:1461: \$? = $ac_status" >&5
+ (exit "$ac_status"); }
+{ (eval echo "$as_me:1463: \"$ac_compiler -v </dev/null >&5\"") >&5
(eval $ac_compiler -v </dev/null >&5) 2>&5
ac_status=$?
- echo "$as_me:1366: \$? = $ac_status" >&5
- (exit $ac_status); }
-{ (eval echo "$as_me:1368: \"$ac_compiler -V </dev/null >&5\"") >&5
+ echo "$as_me:1466: \$? = $ac_status" >&5
+ (exit "$ac_status"); }
+{ (eval echo "$as_me:1468: \"$ac_compiler -V </dev/null >&5\"") >&5
(eval $ac_compiler -V </dev/null >&5) 2>&5
ac_status=$?
- echo "$as_me:1371: \$? = $ac_status" >&5
- (exit $ac_status); }
+ echo "$as_me:1471: \$? = $ac_status" >&5
+ (exit "$ac_status"); }
-cat >conftest.$ac_ext <<_ACEOF
-#line 1375 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 1475 "configure"
#include "confdefs.h"
int
@@ -1388,14 +1488,14 @@ ac_clean_files="$ac_clean_files a.out a.exe"
# Try to create an executable without -o first, disregard a.out.
# It will help us diagnose broken compilers, and finding out an intuition
# of exeext.
-echo "$as_me:1391: checking for C compiler default output" >&5
+echo "$as_me:1491: checking for C compiler default output" >&5
echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
-ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-if { (eval echo "$as_me:1394: \"$ac_link_default\"") >&5
+ac_link_default=`echo "$ac_link" | sed 's/ -o *"conftest[^"]*"//'`
+if { (eval echo "$as_me:1494: \"$ac_link_default\"") >&5
(eval $ac_link_default) 2>&5
ac_status=$?
- echo "$as_me:1397: \$? = $ac_status" >&5
- (exit $ac_status); }; then
+ echo "$as_me:1497: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; then
# Find the output, starting from the most likely. This scheme is
# not robust to junk in `.', hence go to wildcards (a.*) only as a last
# resort.
@@ -1416,35 +1516,35 @@ for ac_file in `ls a.exe conftest.exe 2>/dev/null;
done
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-{ { echo "$as_me:1420: error: C compiler cannot create executables" >&5
+cat "conftest.$ac_ext" >&5
+{ { echo "$as_me:1520: error: C compiler cannot create executables" >&5
echo "$as_me: error: C compiler cannot create executables" >&2;}
{ (exit 77); exit 77; }; }
fi
ac_exeext=$ac_cv_exeext
-echo "$as_me:1426: result: $ac_file" >&5
+echo "$as_me:1526: result: $ac_file" >&5
echo "${ECHO_T}$ac_file" >&6
# Check the compiler produces executables we can run. If not, either
# the compiler is broken, or we cross compile.
-echo "$as_me:1431: checking whether the C compiler works" >&5
+echo "$as_me:1531: checking whether the C compiler works" >&5
echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
# If not cross compiling, check that we can run a simple program.
if test "$cross_compiling" != yes; then
if { ac_try='./$ac_file'
- { (eval echo "$as_me:1437: \"$ac_try\"") >&5
+ { (eval echo "$as_me:1537: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:1440: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:1540: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cross_compiling=no
else
if test "$cross_compiling" = maybe; then
cross_compiling=yes
else
- { { echo "$as_me:1447: error: cannot run C compiled programs.
+ { { echo "$as_me:1547: error: cannot run C compiled programs.
If you meant to cross compile, use \`--host'." >&5
echo "$as_me: error: cannot run C compiled programs.
If you meant to cross compile, use \`--host'." >&2;}
@@ -1452,25 +1552,25 @@ If you meant to cross compile, use \`--host'." >&2;}
fi
fi
fi
-echo "$as_me:1455: result: yes" >&5
+echo "$as_me:1555: result: yes" >&5
echo "${ECHO_T}yes" >&6
-rm -f a.out a.exe conftest$ac_cv_exeext
+rm -f a.out a.exe "conftest$ac_cv_exeext"
ac_clean_files=$ac_clean_files_save
# Check the compiler produces executables we can run. If not, either
# the compiler is broken, or we cross compile.
-echo "$as_me:1462: checking whether we are cross compiling" >&5
+echo "$as_me:1562: checking whether we are cross compiling" >&5
echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
-echo "$as_me:1464: result: $cross_compiling" >&5
+echo "$as_me:1564: result: $cross_compiling" >&5
echo "${ECHO_T}$cross_compiling" >&6
-echo "$as_me:1467: checking for executable suffix" >&5
+echo "$as_me:1567: checking for executable suffix" >&5
echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
-if { (eval echo "$as_me:1469: \"$ac_link\"") >&5
+if { (eval echo "$as_me:1569: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:1472: \$? = $ac_status" >&5
- (exit $ac_status); }; then
+ echo "$as_me:1572: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; then
# If both `conftest.exe' and `conftest' are `present' (well, observable)
# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
# work properly (i.e., refer to `conftest.exe'), while it won't with
@@ -1485,25 +1585,25 @@ for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
esac
done
else
- { { echo "$as_me:1488: error: cannot compute EXEEXT: cannot compile and link" >&5
+ { { echo "$as_me:1588: error: cannot compute EXEEXT: cannot compile and link" >&5
echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
{ (exit 1); exit 1; }; }
fi
-rm -f conftest$ac_cv_exeext
-echo "$as_me:1494: result: $ac_cv_exeext" >&5
+rm -f "conftest$ac_cv_exeext"
+echo "$as_me:1594: result: $ac_cv_exeext" >&5
echo "${ECHO_T}$ac_cv_exeext" >&6
-rm -f conftest.$ac_ext
+rm -f "conftest.$ac_ext"
EXEEXT=$ac_cv_exeext
ac_exeext=$EXEEXT
-echo "$as_me:1500: checking for object suffix" >&5
+echo "$as_me:1600: checking for object suffix" >&5
echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
if test "${ac_cv_objext+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 1506 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 1606 "configure"
#include "confdefs.h"
int
@@ -1515,11 +1615,11 @@ main (void)
}
_ACEOF
rm -f conftest.o conftest.obj
-if { (eval echo "$as_me:1518: \"$ac_compile\"") >&5
+if { (eval echo "$as_me:1618: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:1521: \$? = $ac_status" >&5
- (exit $ac_status); }; then
+ echo "$as_me:1621: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; then
for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
case $ac_file in
*.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
@@ -1529,25 +1629,25 @@ if { (eval echo "$as_me:1518: \"$ac_compile\"") >&5
done
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-{ { echo "$as_me:1533: error: cannot compute OBJEXT: cannot compile" >&5
+cat "conftest.$ac_ext" >&5
+{ { echo "$as_me:1633: error: cannot compute OBJEXT: cannot compile" >&5
echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
{ (exit 1); exit 1; }; }
fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
+rm -f "conftest.$ac_cv_objext" "conftest.$ac_ext"
fi
-echo "$as_me:1540: result: $ac_cv_objext" >&5
+echo "$as_me:1640: result: $ac_cv_objext" >&5
echo "${ECHO_T}$ac_cv_objext" >&6
OBJEXT=$ac_cv_objext
ac_objext=$OBJEXT
-echo "$as_me:1544: checking whether we are using the GNU C compiler" >&5
+echo "$as_me:1644: checking whether we are using the GNU C compiler" >&5
echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
if test "${ac_cv_c_compiler_gnu+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 1550 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 1650 "configure"
#include "confdefs.h"
int
@@ -1561,41 +1661,41 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:1565: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:1665: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:1568: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:1571: \"$ac_try\"") >&5
+ echo "$as_me:1668: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:1671: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:1574: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:1674: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_compiler_gnu=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_compiler_gnu=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
ac_cv_c_compiler_gnu=$ac_compiler_gnu
fi
-echo "$as_me:1586: result: $ac_cv_c_compiler_gnu" >&5
+echo "$as_me:1686: result: $ac_cv_c_compiler_gnu" >&5
echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
GCC=`test $ac_compiler_gnu = yes && echo yes`
ac_test_CFLAGS=${CFLAGS+set}
ac_save_CFLAGS=$CFLAGS
CFLAGS="-g"
-echo "$as_me:1592: checking whether $CC accepts -g" >&5
+echo "$as_me:1692: checking whether $CC accepts -g" >&5
echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
if test "${ac_cv_prog_cc_g+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 1598 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 1698 "configure"
#include "confdefs.h"
int
@@ -1606,27 +1706,27 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:1610: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:1710: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:1613: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:1616: \"$ac_try\"") >&5
+ echo "$as_me:1713: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:1716: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:1619: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:1719: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_prog_cc_g=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_prog_cc_g=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:1629: result: $ac_cv_prog_cc_g" >&5
+echo "$as_me:1729: result: $ac_cv_prog_cc_g" >&5
echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
if test "$ac_test_CFLAGS" = set; then
CFLAGS=$ac_save_CFLAGS
@@ -1647,23 +1747,23 @@ fi
# in C++ we need to declare it. In case someone uses the same compiler
# for both compiling C and C++ we need to have the C++ compiler decide
# the declaration of exit, since it's the most demanding environment.
-cat >conftest.$ac_ext <<_ACEOF
+cat >"conftest.$ac_ext" <<_ACEOF
#ifndef __cplusplus
choke me
#endif
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:1656: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:1756: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:1659: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:1662: \"$ac_try\"") >&5
+ echo "$as_me:1759: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:1762: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:1665: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:1765: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
for ac_declaration in \
''\
'#include <stdlib.h>' \
@@ -1673,8 +1773,8 @@ if { (eval echo "$as_me:1656: \"$ac_compile\"") >&5
'extern "C" void exit (int);' \
'void exit (int);'
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 1677 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 1777 "configure"
#include "confdefs.h"
#include <stdlib.h>
$ac_declaration
@@ -1686,27 +1786,27 @@ exit (42);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:1690: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:1790: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:1693: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:1696: \"$ac_try\"") >&5
+ echo "$as_me:1793: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:1796: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:1699: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:1799: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
continue
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
-#line 1709 "configure"
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 1809 "configure"
#include "confdefs.h"
$ac_declaration
int
@@ -1717,63 +1817,240 @@ exit (42);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:1721: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:1821: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:1724: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:1727: \"$ac_try\"") >&5
+ echo "$as_me:1824: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:1827: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:1730: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:1830: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
rm -rf conftest*
if test -n "$ac_declaration"; then
echo '#ifdef __cplusplus' >>confdefs.h
- echo $ac_declaration >>confdefs.h
+ echo "$ac_declaration" >>confdefs.h
echo '#endif' >>confdefs.h
fi
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
+ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-ac_main_return=return
+ac_main_return="return"
GCC_VERSION=none
if test "$GCC" = yes ; then
- echo "$as_me:1760: checking version of $CC" >&5
+ echo "$as_me:1860: checking version of $CC" >&5
echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(GCC[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
test -z "$GCC_VERSION" && GCC_VERSION=unknown
- echo "$as_me:1764: result: $GCC_VERSION" >&5
+ echo "$as_me:1864: result: $GCC_VERSION" >&5
echo "${ECHO_T}$GCC_VERSION" >&6
fi
-echo "$as_me:1768: checking for $CC option to accept ANSI C" >&5
+INTEL_COMPILER=no
+
+if test "$GCC" = yes ; then
+ case "$host_os" in
+ (linux*|gnu*)
+ echo "$as_me:1873: checking if this is really Intel C compiler" >&5
+echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
+ cf_save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS -no-gcc"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 1878 "configure"
+#include "confdefs.h"
+
+int
+main (void)
+{
+
+#ifdef __INTEL_COMPILER
+#else
+make an error
+#endif
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:1895: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:1898: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:1901: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:1904: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ INTEL_COMPILER=yes
+cf_save_CFLAGS="$cf_save_CFLAGS -we147"
+
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+fi
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ CFLAGS="$cf_save_CFLAGS"
+ echo "$as_me:1915: result: $INTEL_COMPILER" >&5
+echo "${ECHO_T}$INTEL_COMPILER" >&6
+ ;;
+ esac
+fi
+
+CLANG_COMPILER=no
+
+if test "$GCC" = yes ; then
+ echo "$as_me:1924: checking if this is really Clang C compiler" >&5
+echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
+ cf_save_CFLAGS="$CFLAGS"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 1928 "configure"
+#include "confdefs.h"
+
+int
+main (void)
+{
+
+#ifdef __clang__
+#else
+make an error
+#endif
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:1945: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:1948: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:1951: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:1954: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ CLANG_COMPILER=yes
+
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+fi
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ CFLAGS="$cf_save_CFLAGS"
+ echo "$as_me:1964: result: $CLANG_COMPILER" >&5
+echo "${ECHO_T}$CLANG_COMPILER" >&6
+fi
+
+CLANG_VERSION=none
+
+if test "x$CLANG_COMPILER" = "xyes" ; then
+ case "$CC" in
+ (c[1-9][0-9]|*/c[1-9][0-9])
+ { echo "$as_me:1973: WARNING: replacing broken compiler alias $CC" >&5
+echo "$as_me: WARNING: replacing broken compiler alias $CC" >&2;}
+ CFLAGS="$CFLAGS -std=`echo "$CC" | sed -e 's%.*/%%'`"
+ CC=clang
+ ;;
+ esac
+
+ echo "$as_me:1980: checking version of $CC" >&5
+echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
+ CLANG_VERSION="`$CC --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(CLANG[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
+ test -z "$CLANG_VERSION" && CLANG_VERSION=unknown
+ echo "$as_me:1984: result: $CLANG_VERSION" >&5
+echo "${ECHO_T}$CLANG_VERSION" >&6
+
+ for cf_clang_opt in \
+ -Qunused-arguments \
+ -Wno-error=implicit-function-declaration
+ do
+ echo "$as_me:1991: checking if option $cf_clang_opt works" >&5
+echo $ECHO_N "checking if option $cf_clang_opt works... $ECHO_C" >&6
+ cf_save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS $cf_clang_opt"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 1996 "configure"
+#include "confdefs.h"
+
+ #include <stdio.h>
+int
+main (void)
+{
+
+ printf("hello!\\n");
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:2010: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:2013: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:2016: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:2019: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+
+ cf_clang_optok=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+
+ cf_clang_optok=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ echo "$as_me:2030: result: $cf_clang_optok" >&5
+echo "${ECHO_T}$cf_clang_optok" >&6
+ CFLAGS="$cf_save_CFLAGS"
+ if test "$cf_clang_optok" = yes; then
+ test -n "$verbose" && echo " adding option $cf_clang_opt" 1>&6
+
+echo "${as_me:-configure}:2036: testing adding option $cf_clang_opt ..." 1>&5
+
+ test -n "$CFLAGS" && CFLAGS="$CFLAGS "
+ CFLAGS="${CFLAGS}$cf_clang_opt"
+
+ fi
+ done
+fi
+
+echo "$as_me:2045: checking for $CC option to accept ANSI C" >&5
echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
if test "${ac_cv_prog_cc_stdc+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_cv_prog_cc_stdc=no
ac_save_CC=$CC
-cat >conftest.$ac_ext <<_ACEOF
-#line 1776 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 2053 "configure"
#include "confdefs.h"
#include <stdarg.h>
#include <stdio.h>
@@ -1821,52 +2098,171 @@ _ACEOF
for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
do
CC="$ac_save_CC $ac_arg"
- rm -f conftest.$ac_objext
-if { (eval echo "$as_me:1825: \"$ac_compile\"") >&5
+ rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:2102: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:1828: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:1831: \"$ac_try\"") >&5
+ echo "$as_me:2105: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:2108: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:1834: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:2111: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_prog_cc_stdc=$ac_arg
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext
+rm -f "conftest.$ac_objext"
done
-rm -f conftest.$ac_ext conftest.$ac_objext
+rm -f "conftest.$ac_ext" "conftest.$ac_objext"
CC=$ac_save_CC
fi
case "x$ac_cv_prog_cc_stdc" in
x|xno)
- echo "$as_me:1851: result: none needed" >&5
+ echo "$as_me:2128: result: none needed" >&5
echo "${ECHO_T}none needed" >&6 ;;
*)
- echo "$as_me:1854: result: $ac_cv_prog_cc_stdc" >&5
+ echo "$as_me:2131: result: $ac_cv_prog_cc_stdc" >&5
echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
CC="$CC $ac_cv_prog_cc_stdc" ;;
esac
# This should have been defined by AC_PROG_CC
-: ${CC:=cc}
+: "${CC:=cc}"
+
+echo "$as_me:2139: checking \$CFLAGS variable" >&5
+echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
+case "x$CFLAGS" in
+(*-[IUD]*)
+ echo "$as_me:2143: result: broken" >&5
+echo "${ECHO_T}broken" >&6
+ { echo "$as_me:2145: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
+echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
+ cf_flags="$CFLAGS"
+ CFLAGS=
+ for cf_arg in $cf_flags
+ do
+
+cf_fix_cppflags=no
+cf_new_cflags=
+cf_new_cppflags=
+cf_new_extra_cppflags=
+
+for cf_add_cflags in $cf_arg
+do
+case "$cf_fix_cppflags" in
+(no)
+ case "$cf_add_cflags" in
+ (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
+ case "$cf_add_cflags" in
+ (-D*)
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+
+ test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
+ && test -z "${cf_tst_cflags}" \
+ && cf_fix_cppflags=yes
+
+ if test "$cf_fix_cppflags" = yes ; then
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ continue
+ elif test "${cf_tst_cflags}" = "\"'" ; then
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ continue
+ fi
+ ;;
+ esac
+ case "$CPPFLAGS" in
+ (*$cf_add_cflags)
+ ;;
+ (*)
+ case "$cf_add_cflags" in
+ (-D*)
+ cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
+
+CPPFLAGS=`echo "$CPPFLAGS" | \
+ sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
+ -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
+
+ ;;
+ esac
-echo "$as_me:1862: checking \$CC variable" >&5
+ test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
+ cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
+
+ ;;
+ esac
+ ;;
+ (*)
+
+ test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
+ cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
+
+ ;;
+ esac
+ ;;
+(yes)
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
+
+ test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
+ && test -z "${cf_tst_cflags}" \
+ && cf_fix_cppflags=no
+ ;;
+esac
+done
+
+if test -n "$cf_new_cflags" ; then
+
+ test -n "$CFLAGS" && CFLAGS="$CFLAGS "
+ CFLAGS="${CFLAGS}$cf_new_cflags"
+
+fi
+
+if test -n "$cf_new_cppflags" ; then
+
+ test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
+ CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
+
+fi
+
+if test -n "$cf_new_extra_cppflags" ; then
+
+ test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
+ EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
+
+fi
+
+ done
+ ;;
+(*)
+ echo "$as_me:2253: result: ok" >&5
+echo "${ECHO_T}ok" >&6
+ ;;
+esac
+
+echo "$as_me:2258: checking \$CC variable" >&5
echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
case "$CC" in
(*[\ \ ]-*)
- echo "$as_me:1866: result: broken" >&5
+ echo "$as_me:2262: result: broken" >&5
echo "${ECHO_T}broken" >&6
- { echo "$as_me:1868: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
-echo "$as_me: WARNING: your environment misuses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
+ { echo "$as_me:2264: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
+echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
# humor him...
cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
cf_flags=`echo "$CC" | ${AWK:-awk} -v prog="$cf_prog" '{ printf("%s", substr($0,1+length(prog))); }'`
@@ -1883,19 +2279,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_arg
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -1914,7 +2310,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -1944,7 +2340,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -1982,30 +2378,128 @@ fi
done
test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
-echo "${as_me:-configure}:1985: testing resulting CC: '$CC' ..." 1>&5
+echo "${as_me:-configure}:2381: testing resulting CC: '$CC' ..." 1>&5
test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
-echo "${as_me:-configure}:1989: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
+echo "${as_me:-configure}:2385: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
-echo "${as_me:-configure}:1993: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
+echo "${as_me:-configure}:2389: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
;;
(*)
- echo "$as_me:1997: result: ok" >&5
+ echo "$as_me:2393: result: ok" >&5
echo "${ECHO_T}ok" >&6
;;
esac
+for ac_prog in ggrep grep
+do
+ # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+echo "$as_me:2402: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_GREP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test -n "$GREP"; then
+ ac_cv_prog_GREP="$GREP" # Let the user override the test.
+else
+ ac_save_IFS=$IFS; IFS=$ac_path_separator
+ac_dummy="$PATH"
+for ac_dir in $ac_dummy; do
+ IFS=$ac_save_IFS
+ test -z "$ac_dir" && ac_dir=.
+ $as_executable_p "$ac_dir/$ac_word" || continue
+ac_cv_prog_GREP="$ac_prog"
+echo "$as_me:2417: found $ac_dir/$ac_word" >&5
+break
+done
+
+fi
+fi
+GREP=$ac_cv_prog_GREP
+if test -n "$GREP"; then
+ echo "$as_me:2425: result: $GREP" >&5
+echo "${ECHO_T}$GREP" >&6
+else
+ echo "$as_me:2428: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ test -n "$GREP" && break
+done
+test -n "$GREP" || GREP=": "
+
+echo "$as_me:2436: checking for egrep" >&5
+echo $ECHO_N "checking for egrep... $ECHO_C" >&6
+if test "${ac_cv_path_EGREP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
+ then ac_cv_path_EGREP="$GREP -E"
+ else
+ for ac_prog in gegrep egrep
+do
+ # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+echo "$as_me:2448: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_path_EGREP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ case $EGREP in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
+ ;;
+ *)
+ ac_save_IFS=$IFS; IFS=$ac_path_separator
+ac_dummy="$PATH"
+for ac_dir in $ac_dummy; do
+ IFS=$ac_save_IFS
+ test -z "$ac_dir" && ac_dir=.
+ if $as_executable_p "$ac_dir/$ac_word"; then
+ ac_cv_path_EGREP="$ac_dir/$ac_word"
+ echo "$as_me:2465: found $ac_dir/$ac_word" >&5
+ break
+fi
+done
+
+ ;;
+esac
+fi
+EGREP=$ac_cv_path_EGREP
+
+if test -n "$EGREP"; then
+ echo "$as_me:2476: result: $EGREP" >&5
+echo "${ECHO_T}$EGREP" >&6
+else
+ echo "$as_me:2479: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ test -n "$EGREP" && break
+done
+test -n "$EGREP" || EGREP=": "
+
+ test "x$ac_cv_path_EGREP" = "x:" && { { echo "$as_me:2487: error: cannot find workable egrep" >&5
+echo "$as_me: error: cannot find workable egrep" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+fi
+echo "$as_me:2492: result: $ac_cv_path_EGREP" >&5
+echo "${ECHO_T}$ac_cv_path_EGREP" >&6
+ EGREP="$ac_cv_path_EGREP"
+
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
+ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-ac_main_return=return
-echo "$as_me:2008: checking how to run the C preprocessor" >&5
+ac_main_return="return"
+echo "$as_me:2502: checking how to run the C preprocessor" >&5
echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
@@ -2025,20 +2519,20 @@ do
# with a fresh cross-compiler works.
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp. "Syntax error" is here to catch this case.
- cat >conftest.$ac_ext <<_ACEOF
-#line 2029 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 2523 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax error
_ACEOF
-if { (eval echo "$as_me:2034: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:2528: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:2040: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:2534: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -2051,27 +2545,27 @@ if test -z "$ac_cpp_err"; then
:
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
# Broken: fails on valid input.
continue
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
# OK, works on sane cases. Now check whether non-existent headers
# can be detected and how.
- cat >conftest.$ac_ext <<_ACEOF
-#line 2063 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 2557 "configure"
#include "confdefs.h"
#include <ac_nonexistent.h>
_ACEOF
-if { (eval echo "$as_me:2067: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:2561: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:2073: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:2567: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -2085,16 +2579,16 @@ if test -z "$ac_cpp_err"; then
continue
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
# Passes both tests.
ac_preproc_ok=:
break
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
done
# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
if $ac_preproc_ok; then
break
fi
@@ -2107,7 +2601,7 @@ fi
else
ac_cv_prog_CPP=$CPP
fi
-echo "$as_me:2110: result: $CPP" >&5
+echo "$as_me:2604: result: $CPP" >&5
echo "${ECHO_T}$CPP" >&6
ac_preproc_ok=false
for ac_c_preproc_warn_flag in '' yes
@@ -2116,20 +2610,20 @@ do
# with a fresh cross-compiler works.
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp. "Syntax error" is here to catch this case.
- cat >conftest.$ac_ext <<_ACEOF
-#line 2120 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 2614 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax error
_ACEOF
-if { (eval echo "$as_me:2125: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:2619: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:2131: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:2625: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -2142,27 +2636,27 @@ if test -z "$ac_cpp_err"; then
:
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
# Broken: fails on valid input.
continue
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
# OK, works on sane cases. Now check whether non-existent headers
# can be detected and how.
- cat >conftest.$ac_ext <<_ACEOF
-#line 2154 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 2648 "configure"
#include "confdefs.h"
#include <ac_nonexistent.h>
_ACEOF
-if { (eval echo "$as_me:2158: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:2652: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:2164: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:2658: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -2176,32 +2670,32 @@ if test -z "$ac_cpp_err"; then
continue
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
# Passes both tests.
ac_preproc_ok=:
break
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
done
# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
if $ac_preproc_ok; then
:
else
- { { echo "$as_me:2192: error: C preprocessor \"$CPP\" fails sanity check" >&5
+ { { echo "$as_me:2686: error: C preprocessor \"$CPP\" fails sanity check" >&5
echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
{ (exit 1); exit 1; }; }
fi
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
+ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-ac_main_return=return
+ac_main_return="return"
-echo "$as_me:2204: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "$as_me:2698: checking whether ${MAKE-make} sets \${MAKE}" >&5
echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
@@ -2221,11 +2715,11 @@ fi
rm -f conftest.make
fi
if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
- echo "$as_me:2224: result: yes" >&5
+ echo "$as_me:2718: result: yes" >&5
echo "${ECHO_T}yes" >&6
SET_MAKE=
else
- echo "$as_me:2228: result: no" >&5
+ echo "$as_me:2722: result: no" >&5
echo "${ECHO_T}no" >&6
SET_MAKE="MAKE=${MAKE-make}"
fi
@@ -2233,7 +2727,7 @@ fi
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-echo "$as_me:2236: checking for $ac_word" >&5
+echo "$as_me:2730: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_RANLIB+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2248,7 +2742,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
-echo "$as_me:2251: found $ac_dir/$ac_word" >&5
+echo "$as_me:2745: found $ac_dir/$ac_word" >&5
break
done
@@ -2256,10 +2750,10 @@ fi
fi
RANLIB=$ac_cv_prog_RANLIB
if test -n "$RANLIB"; then
- echo "$as_me:2259: result: $RANLIB" >&5
+ echo "$as_me:2753: result: $RANLIB" >&5
echo "${ECHO_T}$RANLIB" >&6
else
- echo "$as_me:2262: result: no" >&5
+ echo "$as_me:2756: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2268,7 +2762,7 @@ if test -z "$ac_cv_prog_RANLIB"; then
ac_ct_RANLIB=$RANLIB
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
-echo "$as_me:2271: checking for $ac_word" >&5
+echo "$as_me:2765: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2283,7 +2777,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_RANLIB="ranlib"
-echo "$as_me:2286: found $ac_dir/$ac_word" >&5
+echo "$as_me:2780: found $ac_dir/$ac_word" >&5
break
done
@@ -2292,10 +2786,10 @@ fi
fi
ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
if test -n "$ac_ct_RANLIB"; then
- echo "$as_me:2295: result: $ac_ct_RANLIB" >&5
+ echo "$as_me:2789: result: $ac_ct_RANLIB" >&5
echo "${ECHO_T}$ac_ct_RANLIB" >&6
else
- echo "$as_me:2298: result: no" >&5
+ echo "$as_me:2792: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2304,31 +2798,6 @@ else
RANLIB="$ac_cv_prog_RANLIB"
fi
-ac_aux_dir=
-for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f $ac_dir/shtool; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { { echo "$as_me:2324: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
-echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
- { (exit 1); exit 1; }; }
-fi
-ac_config_guess="$SHELL $ac_aux_dir/config.guess"
-ac_config_sub="$SHELL $ac_aux_dir/config.sub"
-ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
-
# Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
# incompatible versions:
@@ -2341,7 +2810,7 @@ ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
-echo "$as_me:2344: checking for a BSD compatible install" >&5
+echo "$as_me:2813: checking for a BSD compatible install" >&5
echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
if test -z "$INSTALL"; then
if test "${ac_cv_path_install+set}" = set; then
@@ -2390,7 +2859,7 @@ fi
INSTALL=$ac_install_sh
fi
fi
-echo "$as_me:2393: result: $INSTALL" >&5
+echo "$as_me:2862: result: $INSTALL" >&5
echo "${ECHO_T}$INSTALL" >&6
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
@@ -2401,18 +2870,18 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-echo "$as_me:2404: checking whether ln -s works" >&5
+echo "$as_me:2873: checking whether ln -s works" >&5
echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
LN_S=$as_ln_s
if test "$LN_S" = "ln -s"; then
- echo "$as_me:2408: result: yes" >&5
+ echo "$as_me:2877: result: yes" >&5
echo "${ECHO_T}yes" >&6
else
- echo "$as_me:2411: result: no, using $LN_S" >&5
+ echo "$as_me:2880: result: no, using $LN_S" >&5
echo "${ECHO_T}no, using $LN_S" >&6
fi
-echo "$as_me:2415: checking if $LN_S -f options work" >&5
+echo "$as_me:2884: checking if $LN_S -f options work" >&5
echo $ECHO_N "checking if $LN_S -f options work... $ECHO_C" >&6
rm -f conf$$.src conf$$dst
@@ -2424,7 +2893,7 @@ else
cf_prog_ln_sf=no
fi
rm -f conf$$.dst conf$$src
-echo "$as_me:2427: result: $cf_prog_ln_sf" >&5
+echo "$as_me:2896: result: $cf_prog_ln_sf" >&5
echo "${ECHO_T}$cf_prog_ln_sf" >&6
test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f"
@@ -2433,7 +2902,7 @@ for ac_prog in lint cppcheck splint
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:2436: checking for $ac_word" >&5
+echo "$as_me:2905: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_LINT+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2448,7 +2917,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_LINT="$ac_prog"
-echo "$as_me:2451: found $ac_dir/$ac_word" >&5
+echo "$as_me:2920: found $ac_dir/$ac_word" >&5
break
done
@@ -2456,19 +2925,25 @@ fi
fi
LINT=$ac_cv_prog_LINT
if test -n "$LINT"; then
- echo "$as_me:2459: result: $LINT" >&5
+ echo "$as_me:2928: result: $LINT" >&5
echo "${ECHO_T}$LINT" >&6
else
- echo "$as_me:2462: result: no" >&5
+ echo "$as_me:2931: result: no" >&5
echo "${ECHO_T}no" >&6
fi
test -n "$LINT" && break
done
+case "x$LINT" in
+(xcppcheck|x*/cppcheck)
+ test -z "$LINT_OPTS" && LINT_OPTS="--enable=all"
+ ;;
+esac
+
# Extract the first word of "groff", so it can be a program name with args.
set dummy groff; ac_word=$2
-echo "$as_me:2471: checking for $ac_word" >&5
+echo "$as_me:2946: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_GROFF_PATH+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2485,7 +2960,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if $as_executable_p "$ac_dir/$ac_word"; then
ac_cv_path_GROFF_PATH="$ac_dir/$ac_word"
- echo "$as_me:2488: found $ac_dir/$ac_word" >&5
+ echo "$as_me:2963: found $ac_dir/$ac_word" >&5
break
fi
done
@@ -2497,10 +2972,10 @@ fi
GROFF_PATH=$ac_cv_path_GROFF_PATH
if test -n "$GROFF_PATH"; then
- echo "$as_me:2500: result: $GROFF_PATH" >&5
+ echo "$as_me:2975: result: $GROFF_PATH" >&5
echo "${ECHO_T}$GROFF_PATH" >&6
else
- echo "$as_me:2503: result: no" >&5
+ echo "$as_me:2978: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2508,7 +2983,7 @@ for ac_prog in nroff mandoc
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:2511: checking for $ac_word" >&5
+echo "$as_me:2986: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_NROFF_PATH+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2525,7 +3000,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if $as_executable_p "$ac_dir/$ac_word"; then
ac_cv_path_NROFF_PATH="$ac_dir/$ac_word"
- echo "$as_me:2528: found $ac_dir/$ac_word" >&5
+ echo "$as_me:3003: found $ac_dir/$ac_word" >&5
break
fi
done
@@ -2536,10 +3011,10 @@ fi
NROFF_PATH=$ac_cv_path_NROFF_PATH
if test -n "$NROFF_PATH"; then
- echo "$as_me:2539: result: $NROFF_PATH" >&5
+ echo "$as_me:3014: result: $NROFF_PATH" >&5
echo "${ECHO_T}$NROFF_PATH" >&6
else
- echo "$as_me:2542: result: no" >&5
+ echo "$as_me:3017: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2549,7 +3024,7 @@ test -n "$NROFF_PATH" || NROFF_PATH="no"
# Extract the first word of "tbl", so it can be a program name with args.
set dummy tbl; ac_word=$2
-echo "$as_me:2552: checking for $ac_word" >&5
+echo "$as_me:3027: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_TBL_PATH+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2566,7 +3041,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if $as_executable_p "$ac_dir/$ac_word"; then
ac_cv_path_TBL_PATH="$ac_dir/$ac_word"
- echo "$as_me:2569: found $ac_dir/$ac_word" >&5
+ echo "$as_me:3044: found $ac_dir/$ac_word" >&5
break
fi
done
@@ -2578,10 +3053,10 @@ fi
TBL_PATH=$ac_cv_path_TBL_PATH
if test -n "$TBL_PATH"; then
- echo "$as_me:2581: result: $TBL_PATH" >&5
+ echo "$as_me:3056: result: $TBL_PATH" >&5
echo "${ECHO_T}$TBL_PATH" >&6
else
- echo "$as_me:2584: result: no" >&5
+ echo "$as_me:3059: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2599,7 +3074,7 @@ test -z "$GROFF_NOTE" && NROFF_NOTE=
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
set dummy ${ac_tool_prefix}ar; ac_word=$2
-echo "$as_me:2602: checking for $ac_word" >&5
+echo "$as_me:3077: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_AR+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2614,7 +3089,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_AR="${ac_tool_prefix}ar"
-echo "$as_me:2617: found $ac_dir/$ac_word" >&5
+echo "$as_me:3092: found $ac_dir/$ac_word" >&5
break
done
@@ -2622,10 +3097,10 @@ fi
fi
AR=$ac_cv_prog_AR
if test -n "$AR"; then
- echo "$as_me:2625: result: $AR" >&5
+ echo "$as_me:3100: result: $AR" >&5
echo "${ECHO_T}$AR" >&6
else
- echo "$as_me:2628: result: no" >&5
+ echo "$as_me:3103: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2634,7 +3109,7 @@ if test -z "$ac_cv_prog_AR"; then
ac_ct_AR=$AR
# Extract the first word of "ar", so it can be a program name with args.
set dummy ar; ac_word=$2
-echo "$as_me:2637: checking for $ac_word" >&5
+echo "$as_me:3112: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2649,7 +3124,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_AR="ar"
-echo "$as_me:2652: found $ac_dir/$ac_word" >&5
+echo "$as_me:3127: found $ac_dir/$ac_word" >&5
break
done
@@ -2658,10 +3133,10 @@ fi
fi
ac_ct_AR=$ac_cv_prog_ac_ct_AR
if test -n "$ac_ct_AR"; then
- echo "$as_me:2661: result: $ac_ct_AR" >&5
+ echo "$as_me:3136: result: $ac_ct_AR" >&5
echo "${ECHO_T}$ac_ct_AR" >&6
else
- echo "$as_me:2664: result: no" >&5
+ echo "$as_me:3139: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2670,55 +3145,71 @@ else
AR="$ac_cv_prog_AR"
fi
-echo "$as_me:2673: checking for options to update archives" >&5
+echo "$as_me:3148: checking for options to update archives" >&5
echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
if test "${cf_cv_ar_flags+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cf_cv_ar_flags=unknown
- for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
- do
+ case "$cf_cv_system_name" in
+ (*-msvc*)
+ cf_cv_ar_flags=''
+ cat >mk_static_lib.sh <<-EOF
+ #!$SHELL
+ MSVC_BIN="$AR"
+ out="\$1"
+ shift
+ exec \$MSVC_BIN -out:"\$out" \$@
+ EOF
+ chmod +x mk_static_lib.sh
+ AR=`pwd`/mk_static_lib.sh
+ ;;
+ (*)
+ cf_cv_ar_flags=unknown
+ for cf_ar_flags in -curvU -curv curv -crv crv -cqv cqv -rv rv
+ do
- # check if $ARFLAGS already contains this choice
- if test "x$ARFLAGS" != "x" ; then
- cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
- if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
- cf_cv_ar_flags=
- break
+ # check if $ARFLAGS already contains this choice
+ if test "x$ARFLAGS" != "x" ; then
+ cf_check_ar_flags=`echo "x$ARFLAGS" | sed -e "s/$cf_ar_flags\$//" -e "s/$cf_ar_flags / /"`
+ if test "x$ARFLAGS" != "$cf_check_ar_flags" ; then
+ cf_cv_ar_flags=
+ break
+ fi
fi
- fi
- rm -f conftest.$ac_cv_objext
- rm -f conftest.a
+ rm -f "conftest.$ac_cv_objext"
+ rm -f conftest.a
- cat >conftest.$ac_ext <<EOF
-#line 2696 "configure"
+ cat >"conftest.$ac_ext" <<EOF
+#line 3185 "configure"
int testdata[3] = { 123, 456, 789 };
EOF
- if { (eval echo "$as_me:2699: \"$ac_compile\"") >&5
+ if { (eval echo "$as_me:3188: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:2702: \$? = $ac_status" >&5
- (exit $ac_status); } ; then
- echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
- $AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null
- if test -f conftest.a ; then
- cf_cv_ar_flags=$cf_ar_flags
- break
- fi
- else
- test -n "$verbose" && echo " cannot compile test-program" 1>&6
+ echo "$as_me:3191: \$? = $ac_status" >&5
+ (exit "$ac_status"); } ; then
+ echo "$AR $ARFLAGS $cf_ar_flags conftest.a conftest.$ac_cv_objext" >&5
+ $AR $ARFLAGS "$cf_ar_flags" conftest.a "conftest.$ac_cv_objext" 2>&5 1>/dev/null
+ if test -f conftest.a ; then
+ cf_cv_ar_flags="$cf_ar_flags"
+ break
+ fi
+ else
+ test -n "$verbose" && echo " cannot compile test-program" 1>&6
-echo "${as_me:-configure}:2713: testing cannot compile test-program ..." 1>&5
+echo "${as_me:-configure}:3202: testing cannot compile test-program ..." 1>&5
- break
- fi
- done
- rm -f conftest.a conftest.$ac_ext conftest.$ac_cv_objext
+ break
+ fi
+ done
+ rm -f conftest.a "conftest.$ac_ext" "conftest.$ac_cv_objext"
+ ;;
+ esac
fi
-echo "$as_me:2721: result: $cf_cv_ar_flags" >&5
+echo "$as_me:3212: result: $cf_cv_ar_flags" >&5
echo "${ECHO_T}$cf_cv_ar_flags" >&6
if test -n "$ARFLAGS" ; then
@@ -2729,7 +3220,67 @@ else
ARFLAGS=$cf_cv_ar_flags
fi
-echo "$as_me:2732: checking for makeflags variable" >&5
+echo "$as_me:3223: checking for fgrep" >&5
+echo $ECHO_N "checking for fgrep... $ECHO_C" >&6
+if test "${ac_cv_path_FGREP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
+ then ac_cv_path_FGREP="$GREP -F"
+ else
+ for ac_prog in gfgrep fgrep
+do
+ # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+echo "$as_me:3235: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_path_FGREP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ case $FGREP in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
+ ;;
+ *)
+ ac_save_IFS=$IFS; IFS=$ac_path_separator
+ac_dummy="$PATH"
+for ac_dir in $ac_dummy; do
+ IFS=$ac_save_IFS
+ test -z "$ac_dir" && ac_dir=.
+ if $as_executable_p "$ac_dir/$ac_word"; then
+ ac_cv_path_FGREP="$ac_dir/$ac_word"
+ echo "$as_me:3252: found $ac_dir/$ac_word" >&5
+ break
+fi
+done
+
+ ;;
+esac
+fi
+FGREP=$ac_cv_path_FGREP
+
+if test -n "$FGREP"; then
+ echo "$as_me:3263: result: $FGREP" >&5
+echo "${ECHO_T}$FGREP" >&6
+else
+ echo "$as_me:3266: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ test -n "$FGREP" && break
+done
+test -n "$FGREP" || FGREP=": "
+
+ test "x$ac_cv_path_FGREP" = "x:" && { { echo "$as_me:3274: error: cannot find workable fgrep" >&5
+echo "$as_me: error: cannot find workable fgrep" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+fi
+echo "$as_me:3279: result: $ac_cv_path_FGREP" >&5
+echo "${ECHO_T}$ac_cv_path_FGREP" >&6
+ FGREP="$ac_cv_path_FGREP"
+
+echo "$as_me:3283: checking for makeflags variable" >&5
echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
if test "${cf_cv_makeflags+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2743,10 +3294,10 @@ SHELL = $SHELL
all :
@ echo '.$cf_option'
CF_EOF
- cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | fgrep -v "ing directory" | sed -e 's,[ ]*$,,'`
+ cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | ${FGREP-fgrep} -v "ing directory" | sed -e 's,[ ]*$,,'`
case "$cf_result" in
(.*k|.*kw)
- cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`
+ cf_result="`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null`"
case "$cf_result" in
(.*CC=*) cf_cv_makeflags=
;;
@@ -2759,7 +3310,7 @@ CF_EOF
;;
(*)
-echo "${as_me:-configure}:2762: testing given option \"$cf_option\",no match \"$cf_result\" ..." 1>&5
+echo "${as_me:-configure}:3313: testing given option \"$cf_option\",no match \"$cf_result\" ..." 1>&5
;;
esac
@@ -2767,18 +3318,18 @@ echo "${as_me:-configure}:2762: testing given option \"$cf_option\",no match \"$
rm -f cf_makeflags.tmp
fi
-echo "$as_me:2770: result: $cf_cv_makeflags" >&5
+echo "$as_me:3321: result: $cf_cv_makeflags" >&5
echo "${ECHO_T}$cf_cv_makeflags" >&6
-echo "$as_me:2773: checking if filesystem supports mixed-case filenames" >&5
+echo "$as_me:3324: checking if filesystem supports mixed-case filenames" >&5
echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
if test "${cf_cv_mixedcase+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test "$cross_compiling" = yes ; then
- case $target_alias in
- (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*)
+ case "$target_alias" in
+ (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
cf_cv_mixedcase=no
;;
(*)
@@ -2797,7 +3348,7 @@ else
fi
fi
-echo "$as_me:2800: result: $cf_cv_mixedcase" >&5
+echo "$as_me:3351: result: $cf_cv_mixedcase" >&5
echo "${ECHO_T}$cf_cv_mixedcase" >&6
test "$cf_cv_mixedcase" = yes &&
cat >>confdefs.h <<\EOF
@@ -2808,7 +3359,7 @@ for ac_prog in exctags ctags
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:2811: checking for $ac_word" >&5
+echo "$as_me:3362: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CTAGS+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2823,7 +3374,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_CTAGS="$ac_prog"
-echo "$as_me:2826: found $ac_dir/$ac_word" >&5
+echo "$as_me:3377: found $ac_dir/$ac_word" >&5
break
done
@@ -2831,10 +3382,10 @@ fi
fi
CTAGS=$ac_cv_prog_CTAGS
if test -n "$CTAGS"; then
- echo "$as_me:2834: result: $CTAGS" >&5
+ echo "$as_me:3385: result: $CTAGS" >&5
echo "${ECHO_T}$CTAGS" >&6
else
- echo "$as_me:2837: result: no" >&5
+ echo "$as_me:3388: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2845,7 +3396,7 @@ for ac_prog in exetags etags
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:2848: checking for $ac_word" >&5
+echo "$as_me:3399: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ETAGS+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2860,7 +3411,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ETAGS="$ac_prog"
-echo "$as_me:2863: found $ac_dir/$ac_word" >&5
+echo "$as_me:3414: found $ac_dir/$ac_word" >&5
break
done
@@ -2868,10 +3419,10 @@ fi
fi
ETAGS=$ac_cv_prog_ETAGS
if test -n "$ETAGS"; then
- echo "$as_me:2871: result: $ETAGS" >&5
+ echo "$as_me:3422: result: $ETAGS" >&5
echo "${ECHO_T}$ETAGS" >&6
else
- echo "$as_me:2874: result: no" >&5
+ echo "$as_me:3425: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2880,7 +3431,7 @@ done
# Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
set dummy ${CTAGS:-ctags}; ac_word=$2
-echo "$as_me:2883: checking for $ac_word" >&5
+echo "$as_me:3434: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2895,7 +3446,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_MAKE_LOWER_TAGS="yes"
-echo "$as_me:2898: found $ac_dir/$ac_word" >&5
+echo "$as_me:3449: found $ac_dir/$ac_word" >&5
break
done
@@ -2904,17 +3455,17 @@ fi
fi
MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
if test -n "$MAKE_LOWER_TAGS"; then
- echo "$as_me:2907: result: $MAKE_LOWER_TAGS" >&5
+ echo "$as_me:3458: result: $MAKE_LOWER_TAGS" >&5
echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
else
- echo "$as_me:2910: result: no" >&5
+ echo "$as_me:3461: result: no" >&5
echo "${ECHO_T}no" >&6
fi
if test "$cf_cv_mixedcase" = yes ; then
# Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
set dummy ${ETAGS:-etags}; ac_word=$2
-echo "$as_me:2917: checking for $ac_word" >&5
+echo "$as_me:3468: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -2929,7 +3480,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_MAKE_UPPER_TAGS="yes"
-echo "$as_me:2932: found $ac_dir/$ac_word" >&5
+echo "$as_me:3483: found $ac_dir/$ac_word" >&5
break
done
@@ -2938,10 +3489,10 @@ fi
fi
MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
if test -n "$MAKE_UPPER_TAGS"; then
- echo "$as_me:2941: result: $MAKE_UPPER_TAGS" >&5
+ echo "$as_me:3492: result: $MAKE_UPPER_TAGS" >&5
echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
else
- echo "$as_me:2944: result: no" >&5
+ echo "$as_me:3495: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -2961,7 +3512,7 @@ else
MAKE_LOWER_TAGS="#"
fi
-echo "$as_me:2964: checking if you want to see long compiling messages" >&5
+echo "$as_me:3515: checking if you want to see long compiling messages" >&5
echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
# Check whether --enable-echo or --disable-echo was given.
@@ -2995,61 +3546,10 @@ else
ECHO_CC=''
fi;
-echo "$as_me:2998: result: $enableval" >&5
+echo "$as_me:3549: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
-# Make sure we can run config.sub.
-$ac_config_sub sun4 >/dev/null 2>&1 ||
- { { echo "$as_me:3003: error: cannot run $ac_config_sub" >&5
-echo "$as_me: error: cannot run $ac_config_sub" >&2;}
- { (exit 1); exit 1; }; }
-
-echo "$as_me:3007: checking build system type" >&5
-echo $ECHO_N "checking build system type... $ECHO_C" >&6
-if test "${ac_cv_build+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_cv_build_alias=$build_alias
-test -z "$ac_cv_build_alias" &&
- ac_cv_build_alias=`$ac_config_guess`
-test -z "$ac_cv_build_alias" &&
- { { echo "$as_me:3016: error: cannot guess build type; you must specify one" >&5
-echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
- { (exit 1); exit 1; }; }
-ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
- { { echo "$as_me:3020: error: $ac_config_sub $ac_cv_build_alias failed." >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
- { (exit 1); exit 1; }; }
-
-fi
-echo "$as_me:3025: result: $ac_cv_build" >&5
-echo "${ECHO_T}$ac_cv_build" >&6
-build=$ac_cv_build
-build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-
-if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
- echo "$as_me:3033: checking host system type" >&5
-echo $ECHO_N "checking host system type... $ECHO_C" >&6
-if test "${ac_cv_host+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_cv_host_alias=$host_alias
-test -z "$ac_cv_host_alias" &&
- ac_cv_host_alias=$ac_cv_build_alias
-ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
- { { echo "$as_me:3042: error: $ac_config_sub $ac_cv_host_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
- { (exit 1); exit 1; }; }
-
-fi
-echo "$as_me:3047: result: $ac_cv_host" >&5
-echo "${ECHO_T}$ac_cv_host" >&6
-host=$ac_cv_host
-host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
system_name="$host_os"
else
@@ -3070,18 +3570,18 @@ else
fi
test -z "$system_name" && system_name="$cf_cv_system_name"
-test -n "$cf_cv_system_name" && echo "$as_me:3073: result: Configuring for $cf_cv_system_name" >&5
+test -n "$cf_cv_system_name" && echo "$as_me:3573: result: Configuring for $cf_cv_system_name" >&5
echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
if test ".$system_name" != ".$cf_cv_system_name" ; then
- echo "$as_me:3077: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
+ echo "$as_me:3577: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
- { { echo "$as_me:3079: error: \"Please remove config.cache and try again.\"" >&5
+ { { echo "$as_me:3579: error: \"Please remove config.cache and try again.\"" >&5
echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
{ (exit 1); exit 1; }; }
fi
-case $cf_cv_system_name in
+case "$cf_cv_system_name" in
(os2*)
CFLAGS="$CFLAGS -Zmt"
@@ -3102,17 +3602,17 @@ cat >>confdefs.h <<EOF
#define PROG_EXT "$PROG_EXT"
EOF
- echo "$as_me:3105: checking for PATH separator" >&5
+ echo "$as_me:3605: checking for PATH separator" >&5
echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(os2*) PATH_SEPARATOR=';' ;;
(*) ${PATH_SEPARATOR:=':'} ;;
esac
- echo "$as_me:3112: result: $PATH_SEPARATOR" >&5
+ echo "$as_me:3612: result: $PATH_SEPARATOR" >&5
echo "${ECHO_T}$PATH_SEPARATOR" >&6
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(OS/2*|os2*)
if test "$DFT_LWR_MODEL" = libtool; then
LIB_PREFIX='lib'
@@ -3120,15 +3620,69 @@ echo "${ECHO_T}$PATH_SEPARATOR" >&6
LIB_PREFIX=''
fi
;;
+ (*-msvc*)
+ LIB_PREFIX=''
+ ;;
(*) LIB_PREFIX='lib'
;;
esac
+echo "$as_me:3630: checking if the POSIX test-macros are already defined" >&5
+echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
+if test "${cf_cv_posix_visible+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 3637 "configure"
+#include "confdefs.h"
+#include <stdio.h>
+int
+main (void)
+{
+
+#if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
+ && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
+ && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
+ && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
+#error conflicting symbols found
+#endif
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:3656: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:3659: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:3662: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:3665: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ cf_cv_posix_visible=no
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+cf_cv_posix_visible=yes
+fi
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+
+fi
+echo "$as_me:3676: result: $cf_cv_posix_visible" >&5
+echo "${ECHO_T}$cf_cv_posix_visible" >&6
+
+if test "$cf_cv_posix_visible" = no; then
+
cf_XOPEN_SOURCE=500
cf_POSIX_C_SOURCE=199506L
cf_xopen_source=
-case $host_os in
+case "$host_os" in
(aix[4-7]*)
cf_xopen_source="-D_ALL_SOURCE"
;;
@@ -3142,7 +3696,7 @@ case $host_os in
cf_xopen_source="-D_DARWIN_C_SOURCE"
cf_XOPEN_SOURCE=
;;
-(freebsd*|dragonfly*)
+(freebsd*|dragonfly*|midnightbsd*)
# 5.x headers associate
# _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
# _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
@@ -3164,14 +3718,14 @@ case $host_os in
cf_gnu_xopen_source=$cf_XOPEN_SOURCE
-echo "$as_me:3167: checking if this is the GNU C library" >&5
+echo "$as_me:3721: checking if this is the GNU C library" >&5
echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
if test "${cf_cv_gnu_library+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-cat >conftest.$ac_ext <<_ACEOF
-#line 3174 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 3728 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -3180,6 +3734,8 @@ main (void)
#if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
return 0;
+ #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
+ return 0;
#else
# error not GNU C library
#endif
@@ -3187,35 +3743,36 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3191: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:3747: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3194: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3197: \"$ac_try\"") >&5
+ echo "$as_me:3750: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:3753: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3200: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:3756: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_gnu_library=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_gnu_library=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:3211: result: $cf_cv_gnu_library" >&5
+echo "$as_me:3767: result: $cf_cv_gnu_library" >&5
echo "${ECHO_T}$cf_cv_gnu_library" >&6
if test x$cf_cv_gnu_library = xyes; then
# With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
- # was changed to help a little...
- echo "$as_me:3218: checking if _DEFAULT_SOURCE can be used as a basis" >&5
+ # was changed to help a little. newlib incorporated the change about 4
+ # years later.
+ echo "$as_me:3775: checking if _DEFAULT_SOURCE can be used as a basis" >&5
echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
if test "${cf_cv_gnu_library_219+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -3226,8 +3783,8 @@ else
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
- cat >conftest.$ac_ext <<_ACEOF
-#line 3230 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 3787 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -3236,6 +3793,8 @@ main (void)
#if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
return 0;
+ #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
+ return 0;
#else
# error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
#endif
@@ -3243,34 +3802,34 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3247: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:3806: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3250: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3253: \"$ac_try\"") >&5
+ echo "$as_me:3809: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:3812: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3256: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:3815: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_gnu_library_219=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_gnu_library_219=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS="$cf_save"
fi
-echo "$as_me:3268: result: $cf_cv_gnu_library_219" >&5
+echo "$as_me:3827: result: $cf_cv_gnu_library_219" >&5
echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
if test "x$cf_cv_gnu_library_219" = xyes; then
cf_save="$CPPFLAGS"
- echo "$as_me:3273: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
+ echo "$as_me:3832: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -3283,19 +3842,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -3314,7 +3873,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -3344,7 +3903,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -3374,8 +3933,8 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
- cat >conftest.$ac_ext <<_ACEOF
-#line 3378 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 3937 "configure"
#include "confdefs.h"
#include <limits.h>
@@ -3394,28 +3953,28 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3398: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:3957: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3401: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3404: \"$ac_try\"") >&5
+ echo "$as_me:3960: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:3963: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3407: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:3966: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_gnu_dftsrc_219=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_gnu_dftsrc_219=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:3418: result: $cf_cv_gnu_dftsrc_219" >&5
+echo "$as_me:3977: result: $cf_cv_gnu_dftsrc_219" >&5
echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
else
@@ -3424,14 +3983,14 @@ echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
- echo "$as_me:3427: checking if we must define _GNU_SOURCE" >&5
+ echo "$as_me:3986: checking if we must define _GNU_SOURCE" >&5
echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
if test "${cf_cv_gnu_source+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 3434 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 3993 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -3445,22 +4004,22 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3449: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4008: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3452: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3455: \"$ac_try\"") >&5
+ echo "$as_me:4011: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4014: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3458: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4017: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_gnu_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_save="$CPPFLAGS"
cf_fix_cppflags=no
@@ -3470,19 +4029,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in -D_GNU_SOURCE
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -3501,7 +4060,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -3531,7 +4090,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -3561,8 +4120,8 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
- cat >conftest.$ac_ext <<_ACEOF
-#line 3565 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4124 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -3576,37 +4135,37 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3580: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4139: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3583: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3586: \"$ac_try\"") >&5
+ echo "$as_me:4142: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4145: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3589: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4148: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_gnu_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_gnu_source=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS="$cf_save"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:3604: result: $cf_cv_gnu_source" >&5
+echo "$as_me:4163: result: $cf_cv_gnu_source" >&5
echo "${ECHO_T}$cf_cv_gnu_source" >&6
if test "$cf_cv_gnu_source" = yes
then
- echo "$as_me:3609: checking if we should also define _DEFAULT_SOURCE" >&5
+ echo "$as_me:4168: checking if we should also define _DEFAULT_SOURCE" >&5
echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
if test "${cf_cv_default_source+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -3615,8 +4174,8 @@ else
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
- cat >conftest.$ac_ext <<_ACEOF
-#line 3619 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4178 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -3630,28 +4189,28 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3634: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4193: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3637: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3640: \"$ac_try\"") >&5
+ echo "$as_me:4196: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4199: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3643: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4202: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_default_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_default_source=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:3654: result: $cf_cv_default_source" >&5
+echo "$as_me:4213: result: $cf_cv_default_source" >&5
echo "${ECHO_T}$cf_cv_default_source" >&6
if test "$cf_cv_default_source" = yes
then
@@ -3673,6 +4232,8 @@ fi
# setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
cf_XOPEN_SOURCE=
+if test "$cf_cv_posix_visible" = no; then
+
cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
cf_save_CFLAGS="$CFLAGS"
@@ -3686,16 +4247,16 @@ cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
-echo "$as_me:3689: checking if we should define _POSIX_C_SOURCE" >&5
+echo "$as_me:4250: checking if we should define _POSIX_C_SOURCE" >&5
echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
if test "${cf_cv_posix_c_source+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-echo "${as_me:-configure}:3695: testing if the symbol is already defined go no further ..." 1>&5
+echo "${as_me:-configure}:4256: testing if the symbol is already defined go no further ..." 1>&5
- cat >conftest.$ac_ext <<_ACEOF
-#line 3698 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4259 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -3709,22 +4270,22 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3713: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4274: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3716: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3719: \"$ac_try\"") >&5
+ echo "$as_me:4277: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4280: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3722: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4283: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_posix_c_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_want_posix_source=no
case .$cf_POSIX_C_SOURCE in
(.[12]??*)
@@ -3739,8 +4300,8 @@ cf_want_posix_source=no
;;
esac
if test "$cf_want_posix_source" = yes ; then
- cat >conftest.$ac_ext <<_ACEOF
-#line 3743 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4304 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -3754,28 +4315,28 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3758: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4319: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3761: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3764: \"$ac_try\"") >&5
+ echo "$as_me:4322: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4325: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3767: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4328: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "${as_me:-configure}:3778: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
+echo "${as_me:-configure}:4339: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
CFLAGS="$cf_trim_CFLAGS"
CPPFLAGS="$cf_trim_CPPFLAGS"
@@ -3783,10 +4344,10 @@ echo "${as_me:-configure}:3778: testing ifdef from value $cf_POSIX_C_SOURCE ..."
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
-echo "${as_me:-configure}:3786: testing if the second compile does not leave our definition intact error ..." 1>&5
+echo "${as_me:-configure}:4347: testing if the second compile does not leave our definition intact error ..." 1>&5
- cat >conftest.$ac_ext <<_ACEOF
-#line 3789 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4350 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -3800,33 +4361,33 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3804: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4365: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3807: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3810: \"$ac_try\"") >&5
+ echo "$as_me:4368: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4371: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:3813: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4374: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_posix_c_source=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CFLAGS="$cf_save_CFLAGS"
CPPFLAGS="$cf_save_CPPFLAGS"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:3829: result: $cf_cv_posix_c_source" >&5
+echo "$as_me:4390: result: $cf_cv_posix_c_source" >&5
echo "${ECHO_T}$cf_cv_posix_c_source" >&6
if test "$cf_cv_posix_c_source" != no ; then
@@ -3840,19 +4401,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_cv_posix_c_source
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -3871,7 +4432,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -3901,7 +4462,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -3933,6 +4494,8 @@ fi
fi
+fi # cf_cv_posix_visible
+
;;
(netbsd*)
cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
@@ -3964,14 +4527,14 @@ fi
;;
(*)
-echo "$as_me:3967: checking if we should define _XOPEN_SOURCE" >&5
+echo "$as_me:4530: checking if we should define _XOPEN_SOURCE" >&5
echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
if test "${cf_cv_xopen_source+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 3974 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4537 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -3989,29 +4552,29 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:3993: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4556: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:3996: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:3999: \"$ac_try\"") >&5
+ echo "$as_me:4559: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4562: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4002: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4565: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_xopen_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_save="$CPPFLAGS"
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
- cat >conftest.$ac_ext <<_ACEOF
-#line 4014 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4577 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -4029,32 +4592,32 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4033: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4596: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4036: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4039: \"$ac_try\"") >&5
+ echo "$as_me:4599: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4602: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4042: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4605: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_xopen_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_xopen_source=$cf_XOPEN_SOURCE
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS="$cf_save"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:4057: result: $cf_cv_xopen_source" >&5
+echo "$as_me:4620: result: $cf_cv_xopen_source" >&5
echo "${ECHO_T}$cf_cv_xopen_source" >&6
if test "$cf_cv_xopen_source" != no ; then
@@ -4076,19 +4639,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_temp_xopen_source
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -4107,7 +4670,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -4137,7 +4700,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -4169,6 +4732,8 @@ fi
fi
+if test "$cf_cv_posix_visible" = no; then
+
cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
cf_save_CFLAGS="$CFLAGS"
@@ -4182,16 +4747,16 @@ cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
-e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
-echo "$as_me:4185: checking if we should define _POSIX_C_SOURCE" >&5
+echo "$as_me:4750: checking if we should define _POSIX_C_SOURCE" >&5
echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
if test "${cf_cv_posix_c_source+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-echo "${as_me:-configure}:4191: testing if the symbol is already defined go no further ..." 1>&5
+echo "${as_me:-configure}:4756: testing if the symbol is already defined go no further ..." 1>&5
- cat >conftest.$ac_ext <<_ACEOF
-#line 4194 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4759 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -4205,22 +4770,22 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4209: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4774: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4212: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4215: \"$ac_try\"") >&5
+ echo "$as_me:4777: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4780: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4218: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4783: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_posix_c_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_want_posix_source=no
case .$cf_POSIX_C_SOURCE in
(.[12]??*)
@@ -4235,8 +4800,8 @@ cf_want_posix_source=no
;;
esac
if test "$cf_want_posix_source" = yes ; then
- cat >conftest.$ac_ext <<_ACEOF
-#line 4239 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4804 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -4250,28 +4815,28 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4254: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4819: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4257: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4260: \"$ac_try\"") >&5
+ echo "$as_me:4822: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4825: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4263: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4828: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "${as_me:-configure}:4274: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
+echo "${as_me:-configure}:4839: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
CFLAGS="$cf_trim_CFLAGS"
CPPFLAGS="$cf_trim_CPPFLAGS"
@@ -4279,10 +4844,10 @@ echo "${as_me:-configure}:4274: testing ifdef from value $cf_POSIX_C_SOURCE ..."
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
-echo "${as_me:-configure}:4282: testing if the second compile does not leave our definition intact error ..." 1>&5
+echo "${as_me:-configure}:4847: testing if the second compile does not leave our definition intact error ..." 1>&5
- cat >conftest.$ac_ext <<_ACEOF
-#line 4285 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 4850 "configure"
#include "confdefs.h"
#include <sys/types.h>
int
@@ -4296,33 +4861,33 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4300: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:4865: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4303: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4306: \"$ac_try\"") >&5
+ echo "$as_me:4868: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:4871: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4309: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:4874: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_posix_c_source=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CFLAGS="$cf_save_CFLAGS"
CPPFLAGS="$cf_save_CPPFLAGS"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:4325: result: $cf_cv_posix_c_source" >&5
+echo "$as_me:4890: result: $cf_cv_posix_c_source" >&5
echo "${ECHO_T}$cf_cv_posix_c_source" >&6
if test "$cf_cv_posix_c_source" != no ; then
@@ -4336,19 +4901,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_cv_posix_c_source
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -4367,7 +4932,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -4397,7 +4962,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -4429,6 +4994,8 @@ fi
fi
+fi # cf_cv_posix_visible
+
;;
esac
@@ -4441,19 +5008,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_xopen_source
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -4472,7 +5039,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -4502,7 +5069,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -4514,7 +5081,7 @@ done
if test -n "$cf_new_cflags" ; then
test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
-echo "${as_me:-configure}:4517: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
+echo "${as_me:-configure}:5084: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
test -n "$CFLAGS" && CFLAGS="$CFLAGS "
CFLAGS="${CFLAGS}$cf_new_cflags"
@@ -4524,7 +5091,7 @@ fi
if test -n "$cf_new_cppflags" ; then
test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
-echo "${as_me:-configure}:4527: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
+echo "${as_me:-configure}:5094: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
@@ -4534,7 +5101,7 @@ fi
if test -n "$cf_new_extra_cppflags" ; then
test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
-echo "${as_me:-configure}:4537: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
+echo "${as_me:-configure}:5104: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
@@ -4544,10 +5111,10 @@ fi
fi
if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
- echo "$as_me:4547: checking if _XOPEN_SOURCE really is set" >&5
+ echo "$as_me:5114: checking if _XOPEN_SOURCE really is set" >&5
echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
- cat >conftest.$ac_ext <<_ACEOF
-#line 4550 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5117 "configure"
#include "confdefs.h"
#include <stdlib.h>
int
@@ -4561,31 +5128,31 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4565: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5132: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4568: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4571: \"$ac_try\"") >&5
+ echo "$as_me:5135: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5138: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4574: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5141: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_XOPEN_SOURCE_set=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_XOPEN_SOURCE_set=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- echo "$as_me:4583: result: $cf_XOPEN_SOURCE_set" >&5
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ echo "$as_me:5150: result: $cf_XOPEN_SOURCE_set" >&5
echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
- if test $cf_XOPEN_SOURCE_set = yes
+ if test "$cf_XOPEN_SOURCE_set" = yes
then
- cat >conftest.$ac_ext <<_ACEOF
-#line 4588 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5155 "configure"
#include "confdefs.h"
#include <stdlib.h>
int
@@ -4599,40 +5166,40 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4603: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5170: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4606: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4609: \"$ac_try\"") >&5
+ echo "$as_me:5173: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5176: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4612: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5179: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_XOPEN_SOURCE_set_ok=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_XOPEN_SOURCE_set_ok=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- if test $cf_XOPEN_SOURCE_set_ok = no
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ if test "$cf_XOPEN_SOURCE_set_ok" = no
then
- { echo "$as_me:4623: WARNING: _XOPEN_SOURCE is lower than requested" >&5
+ { echo "$as_me:5190: WARNING: _XOPEN_SOURCE is lower than requested" >&5
echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
fi
else
-echo "$as_me:4628: checking if we should define _XOPEN_SOURCE" >&5
+echo "$as_me:5195: checking if we should define _XOPEN_SOURCE" >&5
echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
if test "${cf_cv_xopen_source+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 4635 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5202 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -4650,29 +5217,29 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4654: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5221: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4657: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4660: \"$ac_try\"") >&5
+ echo "$as_me:5224: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5227: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4663: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5230: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_xopen_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_save="$CPPFLAGS"
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
- cat >conftest.$ac_ext <<_ACEOF
-#line 4675 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5242 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -4690,32 +5257,32 @@ make an error
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4694: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5261: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4697: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4700: \"$ac_try\"") >&5
+ echo "$as_me:5264: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5267: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4703: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5270: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_xopen_source=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_xopen_source=$cf_XOPEN_SOURCE
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS="$cf_save"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:4718: result: $cf_cv_xopen_source" >&5
+echo "$as_me:5285: result: $cf_cv_xopen_source" >&5
echo "${ECHO_T}$cf_cv_xopen_source" >&6
if test "$cf_cv_xopen_source" != no ; then
@@ -4737,19 +5304,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_temp_xopen_source
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -4768,7 +5335,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -4798,7 +5365,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -4832,6 +5399,7 @@ fi
fi
fi
+fi # cf_cv_posix_visible
# Check whether --enable-largefile or --disable-largefile was given.
if test "${enable_largefile+set}" = set; then
@@ -4840,7 +5408,7 @@ if test "${enable_largefile+set}" = set; then
fi;
if test "$enable_largefile" != no; then
- echo "$as_me:4843: checking for special C compiler options needed for large files" >&5
+ echo "$as_me:5411: checking for special C compiler options needed for large files" >&5
echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
if test "${ac_cv_sys_largefile_CC+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -4851,8 +5419,8 @@ else
while :; do
# IRIX 6.2 and later do not support large files by default,
# so use the C compiler's -n32 option if that helps.
- cat >conftest.$ac_ext <<_ACEOF
-#line 4855 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5423 "configure"
#include "confdefs.h"
#include <sys/types.h>
/* Check that off_t can represent 2**63 - 1 correctly.
@@ -4871,64 +5439,64 @@ main (void)
return 0;
}
_ACEOF
- rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4875: \"$ac_compile\"") >&5
+ rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5443: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4878: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4881: \"$ac_try\"") >&5
+ echo "$as_me:5446: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5449: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4884: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5452: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext
+rm -f "conftest.$ac_objext"
CC="$CC -n32"
- rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4894: \"$ac_compile\"") >&5
+ rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5462: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4897: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4900: \"$ac_try\"") >&5
+ echo "$as_me:5465: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5468: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4903: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5471: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_sys_largefile_CC=' -n32'; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext
+rm -f "conftest.$ac_objext"
break
done
CC=$ac_save_CC
- rm -f conftest.$ac_ext
+ rm -f "conftest.$ac_ext"
fi
fi
-echo "$as_me:4917: result: $ac_cv_sys_largefile_CC" >&5
+echo "$as_me:5485: result: $ac_cv_sys_largefile_CC" >&5
echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
if test "$ac_cv_sys_largefile_CC" != no; then
CC=$CC$ac_cv_sys_largefile_CC
fi
- echo "$as_me:4923: checking for _FILE_OFFSET_BITS value needed for large files" >&5
+ echo "$as_me:5491: checking for _FILE_OFFSET_BITS value needed for large files" >&5
echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
if test "${ac_cv_sys_file_offset_bits+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
while :; do
ac_cv_sys_file_offset_bits=no
- cat >conftest.$ac_ext <<_ACEOF
-#line 4931 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5499 "configure"
#include "confdefs.h"
#include <sys/types.h>
/* Check that off_t can represent 2**63 - 1 correctly.
@@ -4947,26 +5515,26 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4951: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5519: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4954: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4957: \"$ac_try\"") >&5
+ echo "$as_me:5522: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5525: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4960: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5528: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
-#line 4969 "configure"
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5537 "configure"
#include "confdefs.h"
#define _FILE_OFFSET_BITS 64
#include <sys/types.h>
@@ -4986,28 +5554,28 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:4990: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5558: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:4993: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:4996: \"$ac_try\"") >&5
+ echo "$as_me:5561: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5564: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:4999: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5567: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_sys_file_offset_bits=64; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
break
done
fi
-echo "$as_me:5010: result: $ac_cv_sys_file_offset_bits" >&5
+echo "$as_me:5578: result: $ac_cv_sys_file_offset_bits" >&5
echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
if test "$ac_cv_sys_file_offset_bits" != no; then
@@ -5017,15 +5585,15 @@ EOF
fi
rm -rf conftest*
- echo "$as_me:5020: checking for _LARGE_FILES value needed for large files" >&5
+ echo "$as_me:5588: checking for _LARGE_FILES value needed for large files" >&5
echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
if test "${ac_cv_sys_large_files+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
while :; do
ac_cv_sys_large_files=no
- cat >conftest.$ac_ext <<_ACEOF
-#line 5028 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5596 "configure"
#include "confdefs.h"
#include <sys/types.h>
/* Check that off_t can represent 2**63 - 1 correctly.
@@ -5044,26 +5612,26 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:5048: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5616: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:5051: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:5054: \"$ac_try\"") >&5
+ echo "$as_me:5619: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5622: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:5057: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5625: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
-#line 5066 "configure"
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5634 "configure"
#include "confdefs.h"
#define _LARGE_FILES 1
#include <sys/types.h>
@@ -5083,28 +5651,28 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:5087: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5655: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:5090: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:5093: \"$ac_try\"") >&5
+ echo "$as_me:5658: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5661: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:5096: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5664: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_sys_large_files=1; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
break
done
fi
-echo "$as_me:5107: result: $ac_cv_sys_large_files" >&5
+echo "$as_me:5675: result: $ac_cv_sys_large_files" >&5
echo "${ECHO_T}$ac_cv_sys_large_files" >&6
if test "$ac_cv_sys_large_files" != no; then
@@ -5117,15 +5685,15 @@ rm -rf conftest*
fi
if test "$enable_largefile" != no ; then
- echo "$as_me:5120: checking for _LARGEFILE_SOURCE value needed for large files" >&5
+ echo "$as_me:5688: checking for _LARGEFILE_SOURCE value needed for large files" >&5
echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
if test "${ac_cv_sys_largefile_source+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
while :; do
ac_cv_sys_largefile_source=no
- cat >conftest.$ac_ext <<_ACEOF
-#line 5128 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5696 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -5136,26 +5704,26 @@ return !fseeko;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:5140: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5708: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:5143: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:5146: \"$ac_try\"") >&5
+ echo "$as_me:5711: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5714: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:5149: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5717: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- cat >conftest.$ac_ext <<_ACEOF
-#line 5158 "configure"
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5726 "configure"
#include "confdefs.h"
#define _LARGEFILE_SOURCE 1
#include <stdio.h>
@@ -5167,28 +5735,28 @@ return !fseeko;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:5171: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5739: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:5174: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:5177: \"$ac_try\"") >&5
+ echo "$as_me:5742: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5745: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:5180: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5748: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_sys_largefile_source=1; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
break
done
fi
-echo "$as_me:5191: result: $ac_cv_sys_largefile_source" >&5
+echo "$as_me:5759: result: $ac_cv_sys_largefile_source" >&5
echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
if test "$ac_cv_sys_largefile_source" != no; then
@@ -5202,13 +5770,13 @@ rm -rf conftest*
# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
# in glibc 2.1.3, but that breaks too many other things.
# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
-echo "$as_me:5205: checking for fseeko" >&5
+echo "$as_me:5773: checking for fseeko" >&5
echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
if test "${ac_cv_func_fseeko+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 5211 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5779 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -5219,27 +5787,27 @@ return fseeko && fseeko (stdin, 0, 0);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:5223: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:5791: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:5226: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:5229: \"$ac_try\"") >&5
+ echo "$as_me:5794: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:5797: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:5232: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5800: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_fseeko=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_fseeko=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:5242: result: $ac_cv_func_fseeko" >&5
+echo "$as_me:5810: result: $ac_cv_func_fseeko" >&5
echo "${ECHO_T}$ac_cv_func_fseeko" >&6
if test $ac_cv_func_fseeko = yes; then
@@ -5278,14 +5846,14 @@ fi
fi
- echo "$as_me:5281: checking whether to use struct dirent64" >&5
+ echo "$as_me:5849: checking whether to use struct dirent64" >&5
echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
if test "${cf_cv_struct_dirent64+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 5288 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 5856 "configure"
#include "confdefs.h"
#pragma GCC diagnostic error "-Wincompatible-pointer-types"
@@ -5301,33 +5869,34 @@ main (void)
struct dirent64 *x = readdir((DIR *)0);
struct dirent *y = readdir((DIR *)0);
int z = x - y;
+ (void)z;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:5310: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:5879: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:5313: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:5316: \"$ac_try\"") >&5
+ echo "$as_me:5882: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:5885: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:5319: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:5888: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_struct_dirent64=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_struct_dirent64=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:5330: result: $cf_cv_struct_dirent64" >&5
+echo "$as_me:5899: result: $cf_cv_struct_dirent64" >&5
echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
test "$cf_cv_struct_dirent64" = yes &&
cat >>confdefs.h <<\EOF
@@ -5336,7 +5905,7 @@ EOF
fi
-echo "$as_me:5339: checking for install-prefix" >&5
+echo "$as_me:5908: checking for install-prefix" >&5
echo $ECHO_N "checking for install-prefix... $ECHO_C" >&6
# Check whether --with-install-prefix or --without-install-prefix was given.
@@ -5346,7 +5915,7 @@ if test "${with_install_prefix+set}" = set; then
else
cf_opt_with_install_prefix=${DESTDIR:-no}
fi;
-echo "$as_me:5349: result: $cf_opt_with_install_prefix" >&5
+echo "$as_me:5918: result: $cf_opt_with_install_prefix" >&5
echo "${ECHO_T}$cf_opt_with_install_prefix" >&6
if test "$cf_opt_with_install_prefix" != no ; then
@@ -5363,19 +5932,19 @@ case ".$cf_opt_with_install_prefix" in
;;
(.[a-zA-Z]:[\\/]*) # OS/2 EMX
;;
-(.\${*prefix}*|.\${*dir}*)
+(.\$\{*prefix\}*|.\$\{*dir\}*)
eval cf_opt_with_install_prefix="$cf_opt_with_install_prefix"
case ".$cf_opt_with_install_prefix" in
(.NONE/*)
- cf_opt_with_install_prefix=`echo $cf_opt_with_install_prefix | sed -e s%NONE%$cf_path_syntax%`
+ cf_opt_with_install_prefix=`echo "$cf_opt_with_install_prefix" | sed -e s%NONE%$cf_path_syntax%`
;;
esac
;;
(.no|.NONE/*)
- cf_opt_with_install_prefix=`echo $cf_opt_with_install_prefix | sed -e s%NONE%$cf_path_syntax%`
+ cf_opt_with_install_prefix=`echo "$cf_opt_with_install_prefix" | sed -e s%NONE%$cf_path_syntax%`
;;
(*)
- { { echo "$as_me:5378: error: expected a pathname, not \"$cf_opt_with_install_prefix\"" >&5
+ { { echo "$as_me:5947: error: expected a pathname, not \"$cf_opt_with_install_prefix\"" >&5
echo "$as_me: error: expected a pathname, not \"$cf_opt_with_install_prefix\"" >&2;}
{ (exit 1); exit 1; }; }
;;
@@ -5384,263 +5953,1362 @@ esac
DESTDIR=$cf_opt_with_install_prefix
fi
-if ( test "$GCC" = yes || test "$GXX" = yes )
+if test -n "$with_screen" && test "x$with_screen" = "xpdcurses"
then
-echo "$as_me:5389: checking if you want to check for gcc warnings" >&5
-echo $ECHO_N "checking if you want to check for gcc warnings... $ECHO_C" >&6
+ echo "$as_me:5958: checking for X" >&5
+echo $ECHO_N "checking for X... $ECHO_C" >&6
+
+# Check whether --with-x or --without-x was given.
+if test "${with_x+set}" = set; then
+ withval="$with_x"
-# Check whether --with-warnings or --without-warnings was given.
-if test "${with_warnings+set}" = set; then
- withval="$with_warnings"
- cf_opt_with_warnings=$withval
-else
- cf_opt_with_warnings=no
fi;
-echo "$as_me:5399: result: $cf_opt_with_warnings" >&5
-echo "${ECHO_T}$cf_opt_with_warnings" >&6
-if test "$cf_opt_with_warnings" != no ; then
+# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
+if test "x$with_x" = xno; then
+ # The user explicitly disabled X.
+ have_x=disabled
+else
+ if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
+ # Both variables are already set.
+ have_x=yes
+ else
+ if test "${ac_cv_have_x+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ # One or both of the vars are not set, and there is no cached value.
+ac_x_includes=no ac_x_libraries=no
+rm -fr conftest.dir
+if mkdir conftest.dir; then
+ cd conftest.dir
+ # Make sure to not put "make" in the Imakefile rules, since we grep it out.
+ cat >Imakefile <<'EOF'
+acfindx:
+ @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
+EOF
+ if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
+ # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+ eval "`${MAKE-make} acfindx 2>/dev/null | grep -v make`"
+ # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
+ for ac_extension in a so sl dylib dll; do
+ if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
+ test -f "$ac_im_libdir/libX11.$ac_extension"; then
+ ac_im_usrlibdir=$ac_im_libdir; break
+ fi
+ done
+ # Screen out bogus values from the imake configuration. They are
+ # bogus both because they are the default anyway, and because
+ # using them would break gcc on systems where it needs fixed includes.
+ case $ac_im_incroot in
+ /usr/include) ;;
+ *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
+ esac
+ case $ac_im_usrlibdir in
+ /usr/lib | /lib) ;;
+ *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
+ esac
+ fi
+ cd ..
+ rm -fr conftest.dir
+fi
-if test "$GCC" = yes
-then
-cat > conftest.i <<EOF
-#ifndef GCC_PRINTF
-#define GCC_PRINTF 0
-#endif
-#ifndef GCC_SCANF
-#define GCC_SCANF 0
+# Standard set of common directories for X headers.
+# Check X11 before X11Rn because it is often a symlink to the current release.
+ac_x_header_dirs='
+/usr/X11/include
+/usr/X11R7/include
+/usr/X11R6/include
+/usr/X11R5/include
+/usr/X11R4/include
+
+/opt/local/include
+/opt/X11/include
+
+/usr/include/X11
+/usr/include/X11R7
+/usr/include/X11R6
+/usr/include/X11R5
+/usr/include/X11R4
+
+/usr/local/X11/include
+/usr/local/X11R7/include
+/usr/local/X11R6/include
+/usr/local/X11R5/include
+/usr/local/X11R4/include
+
+/usr/local/include/X11
+/usr/local/include/X11R7
+/usr/local/include/X11R6
+/usr/local/include/X11R5
+/usr/local/include/X11R4
+
+/usr/X386/include
+/usr/x386/include
+/usr/XFree86/include/X11
+
+/usr/include
+/usr/local/include
+/usr/unsupported/include
+/usr/athena/include
+/usr/local/x11r5/include
+/usr/lpp/Xamples/include
+
+/usr/openwin/include
+/usr/openwin/share/include'
+
+if test "$ac_x_includes" = no; then
+ # Guess where to find include files, by looking for Intrinsic.h.
+ # First, try using that file with no special directory specified.
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6062 "configure"
+#include "confdefs.h"
+#include <X11/Intrinsic.h>
+_ACEOF
+if { (eval echo "$as_me:6066: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
+ ac_status=$?
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:6072: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+ # We can compile using X headers with no special include directory.
+ac_x_includes=
+else
+ echo "$as_me: failed program was:" >&5
+ cat "conftest.$ac_ext" >&5
+ for ac_dir in $ac_x_header_dirs; do
+ if test -r "$ac_dir/X11/Intrinsic.h"; then
+ ac_x_includes=$ac_dir
+ break
+ fi
+done
+fi
+rm -f conftest.err "conftest.$ac_ext"
+fi # $ac_x_includes = no
+
+if test "$ac_x_libraries" = no; then
+ # Check for the libraries.
+ # See if we find them without any special options.
+ # Don't add to $LIBS permanently.
+ ac_save_LIBS=$LIBS
+ LIBS="-lXt $LIBS"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6105 "configure"
+#include "confdefs.h"
+#include <X11/Intrinsic.h>
+int
+main (void)
+{
+XtMalloc (0)
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6117: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6120: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6123: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6126: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ LIBS=$ac_save_LIBS
+# We can link X programs with no special library path.
+ac_x_libraries=
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+LIBS=$ac_save_LIBS
+for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
+do
+ # Don't even attempt the hair of trying to link an X program!
+ for ac_extension in a so sl dylib dll; do
+ if test -r "$ac_dir/libXt.$ac_extension"; then
+ ac_x_libraries=$ac_dir
+ break 2
+ fi
+ done
+done
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+fi # $ac_x_libraries = no
+
+if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
+ # Didn't find X anywhere. Cache the known absence of X.
+ ac_cv_have_x="have_x=no"
+else
+ # Record where we found X for the cache.
+ ac_cv_have_x="have_x=yes \
+ ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
+fi
+fi
+
+ fi
+ eval "$ac_cv_have_x"
+fi # $with_x != no
+
+if test "$have_x" != yes; then
+ echo "$as_me:6164: result: $have_x" >&5
+echo "${ECHO_T}$have_x" >&6
+ no_x=yes
+else
+ # If each of the values was on the command line, it overrides each guess.
+ test "x$x_includes" = xNONE && x_includes=$ac_x_includes
+ test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
+ # Update the cache value to reflect the command line values.
+ ac_cv_have_x="have_x=yes \
+ ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
+ echo "$as_me:6174: result: libraries $x_libraries, headers $x_includes" >&5
+echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
+fi
+
+ if test "$no_x" = yes; then
+ # Not all programs may use this symbol, but it does not hurt to define it.
+
+cat >>confdefs.h <<\EOF
+#define X_DISPLAY_MISSING 1
+EOF
+
+ X_CFLAGS=
+ X_PRE_LIBS=
+ X_LIBS=
+ X_EXTRA_LIBS=
+else
+ if test -n "$x_includes"; then
+ X_CFLAGS="$X_CFLAGS -I$x_includes"
+ fi
+
+ # It would also be nice to do this for all -L options, not just this one.
+ if test -n "$x_libraries"; then
+ X_LIBS="$X_LIBS -L$x_libraries"
+ # For Solaris; some versions of Sun CC require a space after -R and
+ # others require no space. Words are not sufficient . . . .
+ case `(uname -sr) 2>/dev/null` in
+ "SunOS 5"*)
+ echo "$as_me:6201: checking whether -R must be followed by a space" >&5
+echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
+ ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6205 "configure"
+#include "confdefs.h"
+
+int
+main (void)
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6217: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6220: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6223: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6226: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_R_nospace=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_R_nospace=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ if test $ac_R_nospace = yes; then
+ echo "$as_me:6236: result: no" >&5
+echo "${ECHO_T}no" >&6
+ X_LIBS="$X_LIBS -R$x_libraries"
+ else
+ LIBS="$ac_xsave_LIBS -R $x_libraries"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6242 "configure"
+#include "confdefs.h"
+
+int
+main (void)
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6254: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6257: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6260: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6263: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_R_space=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_R_space=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ if test $ac_R_space = yes; then
+ echo "$as_me:6273: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+ X_LIBS="$X_LIBS -R $x_libraries"
+ else
+ echo "$as_me:6277: result: neither works" >&5
+echo "${ECHO_T}neither works" >&6
+ fi
+ fi
+ LIBS=$ac_xsave_LIBS
+ esac
+ fi
+
+ # Check for system-dependent libraries X programs must link with.
+ # Do this before checking for the system-independent R6 libraries
+ # (-lICE), since we may need -lsocket or whatever for X linking.
+
+ if test "$ISC" = yes; then
+ X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
+ else
+ # Martyn Johnson says this is needed for Ultrix, if the X
+ # libraries were built with DECnet support. And Karl Berry says
+ # the Alpha needs dnet_stub (dnet does not exist).
+ ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6297 "configure"
+#include "confdefs.h"
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
#endif
-#ifndef GCC_NORETURN
-#define GCC_NORETURN /* nothing */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char XOpenDisplay ();
+int
+main (void)
+{
+XOpenDisplay ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6316: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6319: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6322: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6325: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ :
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+echo "$as_me:6331: checking for dnet_ntoa in -ldnet" >&5
+echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
+if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-ldnet $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 6339 "configure"
+#include "confdefs.h"
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
#endif
-#ifndef GCC_UNUSED
-#define GCC_UNUSED /* nothing */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char dnet_ntoa ();
+int
+main (void)
+{
+dnet_ntoa ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6358: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6361: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6364: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6367: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_lib_dnet_dnet_ntoa=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_lib_dnet_dnet_ntoa=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:6378: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
+echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
+if test "$ac_cv_lib_dnet_dnet_ntoa" = yes; then
+ X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
+fi
+
+ if test $ac_cv_lib_dnet_dnet_ntoa = no; then
+ echo "$as_me:6385: checking for dnet_ntoa in -ldnet_stub" >&5
+echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
+if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-ldnet_stub $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 6393 "configure"
+#include "confdefs.h"
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
#endif
-EOF
-if test "$GCC" = yes
-then
- { echo "$as_me:5421: checking for $CC __attribute__ directives..." >&5
-echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
-cat > conftest.$ac_ext <<EOF
-#line 5424 "${as_me:-configure}"
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char dnet_ntoa ();
+int
+main (void)
+{
+dnet_ntoa ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6412: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6415: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6418: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6421: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_lib_dnet_stub_dnet_ntoa=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_lib_dnet_stub_dnet_ntoa=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:6432: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
+echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
+if test "$ac_cv_lib_dnet_stub_dnet_ntoa" = yes; then
+ X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
+fi
+
+ fi
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ LIBS="$ac_xsave_LIBS"
+
+ # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
+ # to get the SysV transport functions.
+ # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
+ # needs -lnsl.
+ # The nsl library prevents programs from opening the X display
+ # on Irix 5.2, according to T.E. Dickey.
+ # The functions gethostbyname, getservbyname, and inet_addr are
+ # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
+ echo "$as_me:6451: checking for gethostbyname" >&5
+echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
+if test "${ac_cv_func_gethostbyname+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6457 "configure"
#include "confdefs.h"
-#include "conftest.h"
-#include "conftest.i"
-#if GCC_PRINTF
-#define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
-#else
-#define GCC_PRINTFLIKE(fmt,var) /*nothing*/
+#define gethostbyname autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef gethostbyname
+
+#ifdef __cplusplus
+extern "C"
#endif
-#if GCC_SCANF
-#define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
-#else
-#define GCC_SCANFLIKE(fmt,var) /*nothing*/
+
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char gethostbyname (void);
+
+int
+main (void)
+{
+
+/* The GNU C library defines stubs for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
+#error found stub for gethostbyname
#endif
-extern void wow(char *,...) GCC_SCANFLIKE(1,2);
-extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
-extern void foo(void) GCC_NORETURN;
-int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { return 0; }
-EOF
- cf_printf_attribute=no
- cf_scanf_attribute=no
- for cf_attribute in scanf printf unused noreturn
- do
-cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
+ return gethostbyname ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6488: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6491: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6494: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6497: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_func_gethostbyname=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_func_gethostbyname=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+fi
+echo "$as_me:6507: result: $ac_cv_func_gethostbyname" >&5
+echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
- cf_directive="__attribute__(($cf_attribute))"
- echo "checking for $CC $cf_directive" 1>&5
+ if test $ac_cv_func_gethostbyname = no; then
+ echo "$as_me:6511: checking for gethostbyname in -lnsl" >&5
+echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
+if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lnsl $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 6519 "configure"
+#include "confdefs.h"
- case $cf_attribute in
- (printf)
- cf_printf_attribute=yes
- cat >conftest.h <<EOF
-#define GCC_$cf_ATTRIBUTE 1
-EOF
- ;;
- (scanf)
- cf_scanf_attribute=yes
- cat >conftest.h <<EOF
-#define GCC_$cf_ATTRIBUTE 1
-EOF
- ;;
- (*)
- cat >conftest.h <<EOF
-#define GCC_$cf_ATTRIBUTE $cf_directive
-EOF
- ;;
- esac
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char gethostbyname ();
+int
+main (void)
+{
+gethostbyname ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6538: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6541: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6544: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6547: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_lib_nsl_gethostbyname=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_lib_nsl_gethostbyname=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:6558: result: $ac_cv_lib_nsl_gethostbyname" >&5
+echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
+if test "$ac_cv_lib_nsl_gethostbyname" = yes; then
+ X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
+fi
- if { (eval echo "$as_me:5473: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
+ if test $ac_cv_lib_nsl_gethostbyname = no; then
+ echo "$as_me:6565: checking for gethostbyname in -lbsd" >&5
+echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
+if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lbsd $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 6573 "configure"
+#include "confdefs.h"
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char gethostbyname ();
+int
+main (void)
+{
+gethostbyname ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6592: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:5476: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- test -n "$verbose" && echo "$as_me:5478: result: ... $cf_attribute" >&5
-echo "${ECHO_T}... $cf_attribute" >&6
- cat conftest.h >>confdefs.h
- case $cf_attribute in
- (noreturn)
+ echo "$as_me:6595: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6598: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6601: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_lib_bsd_gethostbyname=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_lib_bsd_gethostbyname=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:6612: result: $ac_cv_lib_bsd_gethostbyname" >&5
+echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
+if test "$ac_cv_lib_bsd_gethostbyname" = yes; then
+ X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
+fi
-cat >>confdefs.h <<EOF
-#define GCC_NORETURN $cf_directive
-EOF
+ fi
+ fi
- ;;
- (printf)
- cf_value='/* nothing */'
- if test "$cf_printf_attribute" != no ; then
- cf_value='__attribute__((format(printf,fmt,var)))'
+ # lieder@skyler.mavd.honeywell.com says without -lsocket,
+ # socket/setsockopt and other routines are undefined under SCO ODT
+ # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
+ # on later versions), says Simon Leinen: it contains gethostby*
+ # variants that don't use the nameserver (or something). -lsocket
+ # must be given before -lnsl if both are needed. We assume that
+ # if connect needs -lnsl, so does gethostbyname.
+ echo "$as_me:6628: checking for connect" >&5
+echo $ECHO_N "checking for connect... $ECHO_C" >&6
+if test "${ac_cv_func_connect+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6634 "configure"
+#include "confdefs.h"
+#define connect autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef connect
-cat >>confdefs.h <<\EOF
-#define GCC_PRINTF 1
-EOF
+#ifdef __cplusplus
+extern "C"
+#endif
- fi
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char connect (void);
-cat >>confdefs.h <<EOF
-#define GCC_PRINTFLIKE(fmt,var) $cf_value
-EOF
+int
+main (void)
+{
- ;;
- (scanf)
- cf_value='/* nothing */'
- if test "$cf_scanf_attribute" != no ; then
- cf_value='__attribute__((format(scanf,fmt,var)))'
+/* The GNU C library defines stubs for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_connect) || defined (__stub___connect)
+#error found stub for connect
+#endif
-cat >>confdefs.h <<\EOF
-#define GCC_SCANF 1
-EOF
+ return connect ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6665: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6668: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6671: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6674: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_func_connect=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_func_connect=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+fi
+echo "$as_me:6684: result: $ac_cv_func_connect" >&5
+echo "${ECHO_T}$ac_cv_func_connect" >&6
- fi
+ if test $ac_cv_func_connect = no; then
+ echo "$as_me:6688: checking for connect in -lsocket" >&5
+echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
+if test "${ac_cv_lib_socket_connect+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 6696 "configure"
+#include "confdefs.h"
-cat >>confdefs.h <<EOF
-#define GCC_SCANFLIKE(fmt,var) $cf_value
-EOF
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char connect ();
+int
+main (void)
+{
+connect ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6715: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6718: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6721: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6724: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_lib_socket_connect=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_lib_socket_connect=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:6735: result: $ac_cv_lib_socket_connect" >&5
+echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
+if test "$ac_cv_lib_socket_connect" = yes; then
+ X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
+fi
- ;;
- (unused)
+ fi
-cat >>confdefs.h <<EOF
-#define GCC_UNUSED $cf_directive
-EOF
+ # Guillermo Gomez says -lposix is necessary on A/UX.
+ echo "$as_me:6744: checking for remove" >&5
+echo $ECHO_N "checking for remove... $ECHO_C" >&6
+if test "${ac_cv_func_remove+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6750 "configure"
+#include "confdefs.h"
+#define remove autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef remove
- ;;
- esac
- fi
- done
+#ifdef __cplusplus
+extern "C"
+#endif
+
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char remove (void);
+
+int
+main (void)
+{
+
+/* The GNU C library defines stubs for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_remove) || defined (__stub___remove)
+#error found stub for remove
+#endif
+
+ return remove ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6781: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6784: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6787: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6790: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_func_remove=yes
else
- fgrep define conftest.i >>confdefs.h
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_func_remove=no
fi
-rm -rf conftest*
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
+echo "$as_me:6800: result: $ac_cv_func_remove" >&5
+echo "${ECHO_T}$ac_cv_func_remove" >&6
-INTEL_COMPILER=no
+ if test $ac_cv_func_remove = no; then
+ echo "$as_me:6804: checking for remove in -lposix" >&5
+echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
+if test "${ac_cv_lib_posix_remove+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lposix $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 6812 "configure"
+#include "confdefs.h"
-if test "$GCC" = yes ; then
- case $host_os in
- (linux*|gnu*)
- echo "$as_me:5542: checking if this is really Intel C compiler" >&5
-echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
- cf_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -no-gcc"
- cat >conftest.$ac_ext <<_ACEOF
-#line 5547 "configure"
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char remove ();
+int
+main (void)
+{
+remove ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6831: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6834: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6837: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6840: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_lib_posix_remove=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_lib_posix_remove=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:6851: result: $ac_cv_lib_posix_remove" >&5
+echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
+if test "$ac_cv_lib_posix_remove" = yes; then
+ X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
+fi
+
+ fi
+
+ # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
+ echo "$as_me:6860: checking for shmat" >&5
+echo $ECHO_N "checking for shmat... $ECHO_C" >&6
+if test "${ac_cv_func_shmat+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 6866 "configure"
#include "confdefs.h"
+#define shmat autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef shmat
+
+#ifdef __cplusplus
+extern "C"
+#endif
+
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char shmat (void);
int
main (void)
{
-#ifdef __INTEL_COMPILER
-#else
-make an error
+/* The GNU C library defines stubs for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_shmat) || defined (__stub___shmat)
+#error found stub for shmat
#endif
+ return shmat ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:5564: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6897: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:5567: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:5570: \"$ac_try\"") >&5
+ echo "$as_me:6900: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6903: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:5573: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- INTEL_COMPILER=yes
-cf_save_CFLAGS="$cf_save_CFLAGS -we147"
+ echo "$as_me:6906: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_func_shmat=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_func_shmat=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+fi
+echo "$as_me:6916: result: $ac_cv_func_shmat" >&5
+echo "${ECHO_T}$ac_cv_func_shmat" >&6
+ if test $ac_cv_func_shmat = no; then
+ echo "$as_me:6920: checking for shmat in -lipc" >&5
+echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
+if test "${ac_cv_lib_ipc_shmat+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lipc $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 6928 "configure"
+#include "confdefs.h"
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char shmat ();
+int
+main (void)
+{
+shmat ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:6947: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:6950: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:6953: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:6956: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_lib_ipc_shmat=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_lib_ipc_shmat=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- CFLAGS="$cf_save_CFLAGS"
- echo "$as_me:5584: result: $INTEL_COMPILER" >&5
-echo "${ECHO_T}$INTEL_COMPILER" >&6
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:6967: result: $ac_cv_lib_ipc_shmat" >&5
+echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
+if test "$ac_cv_lib_ipc_shmat" = yes; then
+ X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
+fi
+
+ fi
+ fi
+
+ # Check for libraries that X11R6 Xt/Xaw programs need.
+ ac_save_LDFLAGS=$LDFLAGS
+ test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
+ # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
+ # check for ICE first), but we must link in the order -lSM -lICE or
+ # we get undefined symbols. So assume we have SM if we have ICE.
+ # These have to be linked with before -lX11, unlike the other
+ # libraries we check for below, so use a different variable.
+ # John Interrante, Karl Berry
+ echo "$as_me:6985: checking for IceConnectionNumber in -lICE" >&5
+echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
+if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lICE $X_EXTRA_LIBS $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 6993 "configure"
+#include "confdefs.h"
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char IceConnectionNumber ();
+int
+main (void)
+{
+IceConnectionNumber ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:7012: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:7015: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:7018: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:7021: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ ac_cv_lib_ICE_IceConnectionNumber=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+ac_cv_lib_ICE_IceConnectionNumber=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:7032: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
+echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
+if test "$ac_cv_lib_ICE_IceConnectionNumber" = yes; then
+ X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
+fi
+
+ LDFLAGS=$ac_save_LDFLAGS
+
+fi
+
+fi
+
+if test "$GCC" = yes || test "$GXX" = yes
+then
+
+if test "$GCC" = yes || test "$GXX" = yes
+then
+ case $CFLAGS in
+ (*-Werror=*)
+ test -n "$verbose" && echo " repairing CFLAGS: $CFLAGS" 1>&6
+
+echo "${as_me:-configure}:7053: testing repairing CFLAGS: $CFLAGS ..." 1>&5
+
+ cf_temp_flags=
+ for cf_temp_scan in $CFLAGS
+ do
+ case "x$cf_temp_scan" in
+ (x-Werror=*)
+
+ test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
+ EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
+
+ ;;
+ (*)
+
+ test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
+ cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
+
+ ;;
+ esac
+ done
+ CFLAGS="$cf_temp_flags"
+ test -n "$verbose" && echo " ... fixed $CFLAGS" 1>&6
+
+echo "${as_me:-configure}:7076: testing ... fixed $CFLAGS ..." 1>&5
+
+ test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
+
+echo "${as_me:-configure}:7080: testing ... extra $EXTRA_CFLAGS ..." 1>&5
+
;;
esac
fi
-CLANG_COMPILER=no
+if test "$GCC" = yes || test "$GXX" = yes
+then
+ case $CPPFLAGS in
+ (*-Werror=*)
+ test -n "$verbose" && echo " repairing CPPFLAGS: $CPPFLAGS" 1>&6
-if test "$GCC" = yes ; then
- echo "$as_me:5593: checking if this is really Clang C compiler" >&5
-echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
- cf_save_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -Qunused-arguments"
- cat >conftest.$ac_ext <<_ACEOF
-#line 5598 "configure"
+echo "${as_me:-configure}:7092: testing repairing CPPFLAGS: $CPPFLAGS ..." 1>&5
+
+ cf_temp_flags=
+ for cf_temp_scan in $CPPFLAGS
+ do
+ case "x$cf_temp_scan" in
+ (x-Werror=*)
+
+ test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
+ EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
+
+ ;;
+ (*)
+
+ test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
+ cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
+
+ ;;
+ esac
+ done
+ CPPFLAGS="$cf_temp_flags"
+ test -n "$verbose" && echo " ... fixed $CPPFLAGS" 1>&6
+
+echo "${as_me:-configure}:7115: testing ... fixed $CPPFLAGS ..." 1>&5
+
+ test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
+
+echo "${as_me:-configure}:7119: testing ... extra $EXTRA_CFLAGS ..." 1>&5
+
+ ;;
+ esac
+fi
+
+if test "$GCC" = yes || test "$GXX" = yes
+then
+ case $LDFLAGS in
+ (*-Werror=*)
+ test -n "$verbose" && echo " repairing LDFLAGS: $LDFLAGS" 1>&6
+
+echo "${as_me:-configure}:7131: testing repairing LDFLAGS: $LDFLAGS ..." 1>&5
+
+ cf_temp_flags=
+ for cf_temp_scan in $LDFLAGS
+ do
+ case "x$cf_temp_scan" in
+ (x-Werror=*)
+
+ test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
+ EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
+
+ ;;
+ (*)
+
+ test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
+ cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
+
+ ;;
+ esac
+ done
+ LDFLAGS="$cf_temp_flags"
+ test -n "$verbose" && echo " ... fixed $LDFLAGS" 1>&6
+
+echo "${as_me:-configure}:7154: testing ... fixed $LDFLAGS ..." 1>&5
+
+ test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
+
+echo "${as_me:-configure}:7158: testing ... extra $EXTRA_CFLAGS ..." 1>&5
+
+ ;;
+ esac
+fi
+
+echo "$as_me:7164: checking if you want to turn on gcc warnings" >&5
+echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
+
+# Check whether --enable-warnings or --disable-warnings was given.
+if test "${enable_warnings+set}" = set; then
+ enableval="$enable_warnings"
+ test "$enableval" != yes && enableval=no
+ if test "$enableval" != "no" ; then
+ enable_warnings=yes
+ else
+ enable_warnings=no
+ fi
+else
+ enableval=no
+ enable_warnings=no
+
+fi;
+echo "$as_me:7181: result: $enable_warnings" >&5
+echo "${ECHO_T}$enable_warnings" >&6
+if test "$enable_warnings" = "yes"
+then
+
+if test "x$have_x" = xyes; then
+
+cf_save_LIBS_CF_CONST_X_STRING="$LIBS"
+cf_save_CFLAGS_CF_CONST_X_STRING="$CFLAGS"
+cf_save_CPPFLAGS_CF_CONST_X_STRING="$CPPFLAGS"
+LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
+for cf_X_CFLAGS in $X_CFLAGS
+do
+ case "x$cf_X_CFLAGS" in
+ x-[IUD]*)
+ CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
+ ;;
+ *)
+ CFLAGS="$CFLAGS $cf_X_CFLAGS"
+ ;;
+ esac
+done
+
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 7205 "configure"
#include "confdefs.h"
+#include <stdlib.h>
+#include <X11/Intrinsic.h>
+
int
main (void)
{
+String foo = malloc(1); (void)foo
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:7220: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:7223: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:7226: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:7229: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
-#ifdef __clang__
-#else
-make an error
-#endif
+echo "$as_me:7232: checking for X11/Xt const-feature" >&5
+echo $ECHO_N "checking for X11/Xt const-feature... $ECHO_C" >&6
+if test "${cf_cv_const_x_string+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 7239 "configure"
+#include "confdefs.h"
+
+#define _CONST_X_STRING /* X11R7.8 (perhaps) */
+#undef XTSTRINGDEFINES /* X11R5 and later */
+#include <stdlib.h>
+#include <X11/Intrinsic.h>
+
+int
+main (void)
+{
+String foo = malloc(1); *foo = 0
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:5615: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:7256: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:5618: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:5621: \"$ac_try\"") >&5
+ echo "$as_me:7259: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:7262: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:5624: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- CLANG_COMPILER=yes
-cf_save_CFLAGS="$cf_save_CFLAGS -Qunused-arguments"
+ echo "$as_me:7265: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+
+ cf_cv_const_x_string=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
+
+ cf_cv_const_x_string=yes
+
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- CFLAGS="$cf_save_CFLAGS"
- echo "$as_me:5635: result: $CLANG_COMPILER" >&5
-echo "${ECHO_T}$CLANG_COMPILER" >&6
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+
fi
+echo "$as_me:7280: result: $cf_cv_const_x_string" >&5
+echo "${ECHO_T}$cf_cv_const_x_string" >&6
-cat > conftest.$ac_ext <<EOF
-#line 5640 "${as_me:-configure}"
+LIBS="$cf_save_LIBS_CF_CONST_X_STRING"
+CFLAGS="$cf_save_CFLAGS_CF_CONST_X_STRING"
+CPPFLAGS="$cf_save_CPPFLAGS_CF_CONST_X_STRING"
+
+case "$cf_cv_const_x_string" in
+(no)
+
+ test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
+ CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
+
+ ;;
+(*)
+
+ test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
+ CPPFLAGS="${CPPFLAGS}-D_CONST_X_STRING"
+
+ ;;
+esac
+
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+fi
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ fi
+cat > "conftest.$ac_ext" <<EOF
+#line 7309 "${as_me:-configure}"
int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
EOF
-
if test "$INTEL_COMPILER" = yes
then
# The "-wdXXX" options suppress warnings:
@@ -5654,10 +7322,10 @@ then
# remark #981: operands are evaluated in unspecified order
# warning #279: controlling expression is constant
- { echo "$as_me:5657: checking for $CC warning options..." >&5
+ { echo "$as_me:7325: checking for $CC warning options..." >&5
echo "$as_me: checking for $CC warning options..." >&6;}
cf_save_CFLAGS="$CFLAGS"
- EXTRA_CFLAGS="-Wall"
+ EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
for cf_opt in \
wd1419 \
wd1683 \
@@ -5670,24 +7338,22 @@ echo "$as_me: checking for $CC warning options..." >&6;}
wd981
do
CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
- if { (eval echo "$as_me:5673: \"$ac_compile\"") >&5
+ if { (eval echo "$as_me:7341: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:5676: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- test -n "$verbose" && echo "$as_me:5678: result: ... -$cf_opt" >&5
+ echo "$as_me:7344: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; then
+ test -n "$verbose" && echo "$as_me:7346: result: ... -$cf_opt" >&5
echo "${ECHO_T}... -$cf_opt" >&6
EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
fi
done
CFLAGS="$cf_save_CFLAGS"
-
-elif test "$GCC" = yes
+elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
then
- { echo "$as_me:5687: checking for $CC warning options..." >&5
+ { echo "$as_me:7354: checking for $CC warning options..." >&5
echo "$as_me: checking for $CC warning options..." >&6;}
cf_save_CFLAGS="$CFLAGS"
- EXTRA_CFLAGS=
cf_warn_CONST=""
test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
@@ -5705,39 +7371,33 @@ echo "$as_me: checking for $CC warning options..." >&6;}
Wpointer-arith \
Wshadow \
Wstrict-prototypes \
- Wundef $cf_gcc_warnings $cf_warn_CONST
+ Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST
do
CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
- if { (eval echo "$as_me:5711: \"$ac_compile\"") >&5
+ if { (eval echo "$as_me:7377: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:5714: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- test -n "$verbose" && echo "$as_me:5716: result: ... -$cf_opt" >&5
+ echo "$as_me:7380: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; then
+ test -n "$verbose" && echo "$as_me:7382: result: ... -$cf_opt" >&5
echo "${ECHO_T}... -$cf_opt" >&6
- case $cf_opt in
- (Wcast-qual)
-
- test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
- CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
-
- ;;
+ case "$cf_opt" in
(Winline)
- case $GCC_VERSION in
+ case "$GCC_VERSION" in
([34].*)
test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
-echo "${as_me:-configure}:5730: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
+echo "${as_me:-configure}:7390: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
continue;;
esac
;;
(Wpointer-arith)
- case $GCC_VERSION in
+ case "$GCC_VERSION" in
([12].*)
test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
-echo "${as_me:-configure}:5740: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
+echo "${as_me:-configure}:7400: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
continue;;
esac
@@ -5748,12 +7408,147 @@ echo "${as_me:-configure}:5740: testing feature is broken in gcc $GCC_VERSION ..
done
CFLAGS="$cf_save_CFLAGS"
fi
-rm -rf conftest*
+rm -rf ./conftest*
fi
+
+if test "$GCC" = yes || test "$GXX" = yes
+then
+cat > conftest.i <<EOF
+#ifndef GCC_PRINTF
+#define GCC_PRINTF 0
+#endif
+#ifndef GCC_SCANF
+#define GCC_SCANF 0
+#endif
+#ifndef GCC_NORETURN
+#define GCC_NORETURN /* nothing */
+#endif
+#ifndef GCC_UNUSED
+#define GCC_UNUSED /* nothing */
+#endif
+EOF
+if test "$GCC" = yes
+then
+ { echo "$as_me:7433: checking for $CC __attribute__ directives..." >&5
+echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
+cat > "conftest.$ac_ext" <<EOF
+#line 7436 "${as_me:-configure}"
+#include "confdefs.h"
+#include "conftest.h"
+#include "conftest.i"
+#if GCC_PRINTF
+#define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
+#else
+#define GCC_PRINTFLIKE(fmt,var) /*nothing*/
+#endif
+#if GCC_SCANF
+#define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
+#else
+#define GCC_SCANFLIKE(fmt,var) /*nothing*/
+#endif
+extern void wow(char *,...) GCC_SCANFLIKE(1,2);
+extern void oops(char *,...) GCC_PRINTFLIKE(1,2) GCC_NORETURN;
+extern void foo(void) GCC_NORETURN;
+int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
+EOF
+ cf_printf_attribute=no
+ cf_scanf_attribute=no
+ for cf_attribute in scanf printf unused noreturn
+ do
+
+cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
+
+ cf_directive="__attribute__(($cf_attribute))"
+ echo "checking for $CC $cf_directive" 1>&5
+
+ case "$cf_attribute" in
+ (printf)
+ cf_printf_attribute=yes
+ cat >conftest.h <<EOF
+#define GCC_$cf_ATTRIBUTE 1
+EOF
+ ;;
+ (scanf)
+ cf_scanf_attribute=yes
+ cat >conftest.h <<EOF
+#define GCC_$cf_ATTRIBUTE 1
+EOF
+ ;;
+ (*)
+ cat >conftest.h <<EOF
+#define GCC_$cf_ATTRIBUTE $cf_directive
+EOF
+ ;;
+ esac
+
+ if { (eval echo "$as_me:7485: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:7488: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; then
+ test -n "$verbose" && echo "$as_me:7490: result: ... $cf_attribute" >&5
+echo "${ECHO_T}... $cf_attribute" >&6
+ cat conftest.h >>confdefs.h
+ case "$cf_attribute" in
+ (noreturn)
+
+cat >>confdefs.h <<EOF
+#define GCC_NORETURN $cf_directive
+EOF
+
+ ;;
+ (printf)
+ cf_value='/* nothing */'
+ if test "$cf_printf_attribute" != no ; then
+ cf_value='__attribute__((format(printf,fmt,var)))'
+
+cat >>confdefs.h <<\EOF
+#define GCC_PRINTF 1
+EOF
+
+ fi
+
+cat >>confdefs.h <<EOF
+#define GCC_PRINTFLIKE(fmt,var) $cf_value
+EOF
+
+ ;;
+ (scanf)
+ cf_value='/* nothing */'
+ if test "$cf_scanf_attribute" != no ; then
+ cf_value='__attribute__((format(scanf,fmt,var)))'
+
+cat >>confdefs.h <<\EOF
+#define GCC_SCANF 1
+EOF
+
+ fi
+
+cat >>confdefs.h <<EOF
+#define GCC_SCANFLIKE(fmt,var) $cf_value
+EOF
+
+ ;;
+ (unused)
+
+cat >>confdefs.h <<EOF
+#define GCC_UNUSED $cf_directive
+EOF
+
+ ;;
+ esac
+ fi
+ done
+else
+ ${FGREP-fgrep} define conftest.i >>confdefs.h
+fi
+rm -rf ./conftest*
fi
-echo "$as_me:5756: checking if you want to use pkg-config" >&5
+fi
+
+echo "$as_me:7551: checking if you want to use pkg-config" >&5
echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
# Check whether --with-pkg-config or --without-pkg-config was given.
@@ -5763,10 +7558,10 @@ if test "${with_pkg_config+set}" = set; then
else
cf_pkg_config=yes
fi;
-echo "$as_me:5766: result: $cf_pkg_config" >&5
+echo "$as_me:7561: result: $cf_pkg_config" >&5
echo "${ECHO_T}$cf_pkg_config" >&6
-case $cf_pkg_config in
+case "$cf_pkg_config" in
(no)
PKG_CONFIG=none
;;
@@ -5775,7 +7570,7 @@ case $cf_pkg_config in
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
-echo "$as_me:5778: checking for $ac_word" >&5
+echo "$as_me:7573: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -5792,7 +7587,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if $as_executable_p "$ac_dir/$ac_word"; then
ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
- echo "$as_me:5795: found $ac_dir/$ac_word" >&5
+ echo "$as_me:7590: found $ac_dir/$ac_word" >&5
break
fi
done
@@ -5803,10 +7598,10 @@ fi
PKG_CONFIG=$ac_cv_path_PKG_CONFIG
if test -n "$PKG_CONFIG"; then
- echo "$as_me:5806: result: $PKG_CONFIG" >&5
+ echo "$as_me:7601: result: $PKG_CONFIG" >&5
echo "${ECHO_T}$PKG_CONFIG" >&6
else
- echo "$as_me:5809: result: no" >&5
+ echo "$as_me:7604: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -5815,7 +7610,7 @@ if test -z "$ac_cv_path_PKG_CONFIG"; then
ac_pt_PKG_CONFIG=$PKG_CONFIG
# Extract the first word of "pkg-config", so it can be a program name with args.
set dummy pkg-config; ac_word=$2
-echo "$as_me:5818: checking for $ac_word" >&5
+echo "$as_me:7613: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -5832,7 +7627,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if $as_executable_p "$ac_dir/$ac_word"; then
ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
- echo "$as_me:5835: found $ac_dir/$ac_word" >&5
+ echo "$as_me:7630: found $ac_dir/$ac_word" >&5
break
fi
done
@@ -5844,10 +7639,10 @@ fi
ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
if test -n "$ac_pt_PKG_CONFIG"; then
- echo "$as_me:5847: result: $ac_pt_PKG_CONFIG" >&5
+ echo "$as_me:7642: result: $ac_pt_PKG_CONFIG" >&5
echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
else
- echo "$as_me:5850: result: no" >&5
+ echo "$as_me:7645: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -5878,30 +7673,30 @@ case ".$PKG_CONFIG" in
;;
(.[a-zA-Z]:[\\/]*) # OS/2 EMX
;;
-(.\${*prefix}*|.\${*dir}*)
+(.\$\{*prefix\}*|.\$\{*dir\}*)
eval PKG_CONFIG="$PKG_CONFIG"
case ".$PKG_CONFIG" in
(.NONE/*)
- PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
+ PKG_CONFIG=`echo "$PKG_CONFIG" | sed -e s%NONE%$cf_path_syntax%`
;;
esac
;;
(.no|.NONE/*)
- PKG_CONFIG=`echo $PKG_CONFIG | sed -e s%NONE%$cf_path_syntax%`
+ PKG_CONFIG=`echo "$PKG_CONFIG" | sed -e s%NONE%$cf_path_syntax%`
;;
(*)
- { { echo "$as_me:5893: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
+ { { echo "$as_me:7688: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
{ (exit 1); exit 1; }; }
;;
esac
elif test "x$cf_pkg_config" != xno ; then
- { echo "$as_me:5900: WARNING: pkg-config is not installed" >&5
+ { echo "$as_me:7695: WARNING: pkg-config is not installed" >&5
echo "$as_me: WARNING: pkg-config is not installed" >&2;}
fi
-echo "$as_me:5904: checking for this package's name" >&5
+echo "$as_me:7699: checking for this package's name" >&5
echo $ECHO_N "checking for this package's name... $ECHO_C" >&6
# Check whether --with-package or --without-package was given.
@@ -5911,55 +7706,55 @@ if test "${with_package+set}" = set; then
else
PACKAGE=dialog
fi;
-echo "$as_me:5914: result: $PACKAGE" >&5
+echo "$as_me:7709: result: $PACKAGE" >&5
echo "${ECHO_T}$PACKAGE" >&6
-if test -f $srcdir/VERSION ; then
- echo "$as_me:5918: checking for package version" >&5
+if test -f "$srcdir/VERSION" ; then
+ echo "$as_me:7713: checking for package version" >&5
echo $ECHO_N "checking for package version... $ECHO_C" >&6
# if there are not enough fields, cut returns the last one...
- cf_field1=`sed -e '2,$d' $srcdir/VERSION|cut -f1`
- cf_field2=`sed -e '2,$d' $srcdir/VERSION|cut -f2`
- cf_field3=`sed -e '2,$d' $srcdir/VERSION|cut -f3`
+ cf_field1=`sed -e '2,$d' "$srcdir/VERSION" |cut -f1`
+ cf_field2=`sed -e '2,$d' "$srcdir/VERSION" |cut -f2`
+ cf_field3=`sed -e '2,$d' "$srcdir/VERSION" |cut -f3`
# this is how CF_BUNDLED_INTL uses $VERSION:
VERSION="$cf_field1"
VERSION_MAJOR=`echo "$cf_field2" | sed -e 's/\..*//'`
- test -z "$VERSION_MAJOR" && { { echo "$as_me:5930: error: missing major-version" >&5
+ test -z "$VERSION_MAJOR" && { { echo "$as_me:7725: error: missing major-version" >&5
echo "$as_me: error: missing major-version" >&2;}
{ (exit 1); exit 1; }; }
VERSION_MINOR=`echo "$cf_field2" | sed -e 's/^[^.]*\.//' -e 's/-.*//'`
- test -z "$VERSION_MINOR" && { { echo "$as_me:5935: error: missing minor-version" >&5
+ test -z "$VERSION_MINOR" && { { echo "$as_me:7730: error: missing minor-version" >&5
echo "$as_me: error: missing minor-version" >&2;}
{ (exit 1); exit 1; }; }
- echo "$as_me:5939: result: ${VERSION_MAJOR}.${VERSION_MINOR}" >&5
+ echo "$as_me:7734: result: ${VERSION_MAJOR}.${VERSION_MINOR}" >&5
echo "${ECHO_T}${VERSION_MAJOR}.${VERSION_MINOR}" >&6
- echo "$as_me:5942: checking for package patch date" >&5
+ echo "$as_me:7737: checking for package patch date" >&5
echo $ECHO_N "checking for package patch date... $ECHO_C" >&6
VERSION_PATCH=`echo "$cf_field3" | sed -e 's/^[^-]*-//'`
case .$VERSION_PATCH in
(.)
- { { echo "$as_me:5947: error: missing patch-date $VERSION_PATCH" >&5
+ { { echo "$as_me:7742: error: missing patch-date $VERSION_PATCH" >&5
echo "$as_me: error: missing patch-date $VERSION_PATCH" >&2;}
{ (exit 1); exit 1; }; }
;;
(.[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9])
;;
(*)
- { { echo "$as_me:5954: error: illegal patch-date $VERSION_PATCH" >&5
+ { { echo "$as_me:7749: error: illegal patch-date $VERSION_PATCH" >&5
echo "$as_me: error: illegal patch-date $VERSION_PATCH" >&2;}
{ (exit 1); exit 1; }; }
;;
esac
- echo "$as_me:5959: result: $VERSION_PATCH" >&5
+ echo "$as_me:7754: result: $VERSION_PATCH" >&5
echo "${ECHO_T}$VERSION_PATCH" >&6
else
- { { echo "$as_me:5962: error: did not find $srcdir/VERSION" >&5
+ { { echo "$as_me:7757: error: did not find $srcdir/VERSION" >&5
echo "$as_me: error: did not find $srcdir/VERSION" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -5967,19 +7762,19 @@ fi
# show the actual data that we have for versions:
test -n "$verbose" && echo " ABI VERSION $VERSION" 1>&6
-echo "${as_me:-configure}:5970: testing ABI VERSION $VERSION ..." 1>&5
+echo "${as_me:-configure}:7765: testing ABI VERSION $VERSION ..." 1>&5
test -n "$verbose" && echo " VERSION_MAJOR $VERSION_MAJOR" 1>&6
-echo "${as_me:-configure}:5974: testing VERSION_MAJOR $VERSION_MAJOR ..." 1>&5
+echo "${as_me:-configure}:7769: testing VERSION_MAJOR $VERSION_MAJOR ..." 1>&5
test -n "$verbose" && echo " VERSION_MINOR $VERSION_MINOR" 1>&6
-echo "${as_me:-configure}:5978: testing VERSION_MINOR $VERSION_MINOR ..." 1>&5
+echo "${as_me:-configure}:7773: testing VERSION_MINOR $VERSION_MINOR ..." 1>&5
test -n "$verbose" && echo " VERSION_PATCH $VERSION_PATCH" 1>&6
-echo "${as_me:-configure}:5982: testing VERSION_PATCH $VERSION_PATCH ..." 1>&5
+echo "${as_me:-configure}:7777: testing VERSION_PATCH $VERSION_PATCH ..." 1>&5
cf_PACKAGE=dialog
PACKAGE=$PACKAGE
@@ -6002,7 +7797,7 @@ CFG_ROOTNAME=$PACKAGE
HDR_ROOTNAME=$PACKAGE
LIB_ROOTNAME=$PACKAGE
-echo "$as_me:6005: checking if we should install dlg_XXX headers to subdirectory" >&5
+echo "$as_me:7800: checking if we should install dlg_XXX headers to subdirectory" >&5
echo $ECHO_N "checking if we should install dlg_XXX headers to subdirectory... $ECHO_C" >&6
# Check whether --enable-header-subdir or --disable-header-subdir was given.
@@ -6012,7 +7807,7 @@ if test "${enable_header_subdir+set}" = set; then
else
SUB_INC=no
fi;
-echo "$as_me:6015: result: $SUB_INC" >&5
+echo "$as_me:7810: result: $SUB_INC" >&5
echo "${ECHO_T}$SUB_INC" >&6
case "x${with_man2html}" in
@@ -6022,7 +7817,7 @@ case "x${with_man2html}" in
(x|xyes)
# Extract the first word of "man2html", so it can be a program name with args.
set dummy man2html; ac_word=$2
-echo "$as_me:6025: checking for $ac_word" >&5
+echo "$as_me:7820: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_cf_man2html+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -6039,7 +7834,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if $as_executable_p "$ac_dir/$ac_word"; then
ac_cv_path_cf_man2html="$ac_dir/$ac_word"
- echo "$as_me:6042: found $ac_dir/$ac_word" >&5
+ echo "$as_me:7837: found $ac_dir/$ac_word" >&5
break
fi
done
@@ -6051,16 +7846,16 @@ fi
cf_man2html=$ac_cv_path_cf_man2html
if test -n "$cf_man2html"; then
- echo "$as_me:6054: result: $cf_man2html" >&5
+ echo "$as_me:7849: result: $cf_man2html" >&5
echo "${ECHO_T}$cf_man2html" >&6
else
- echo "$as_me:6057: result: no" >&5
+ echo "$as_me:7852: result: no" >&5
echo "${ECHO_T}no" >&6
fi
case "x$cf_man2html" in
(x/*)
- echo "$as_me:6063: checking for the modified Earl Hood script" >&5
+ echo "$as_me:7858: checking for the modified Earl Hood script" >&5
echo $ECHO_N "checking for the modified Earl Hood script... $ECHO_C" >&6
if ( $cf_man2html -help 2>&1 | grep 'Make an index of headers at the end' >/dev/null )
then
@@ -6069,7 +7864,7 @@ echo $ECHO_N "checking for the modified Earl Hood script... $ECHO_C" >&6
cf_man2html=no
cf_man2html_ok=no
fi
- echo "$as_me:6072: result: $cf_man2html_ok" >&5
+ echo "$as_me:7867: result: $cf_man2html_ok" >&5
echo "${ECHO_T}$cf_man2html_ok" >&6
;;
(*)
@@ -6078,7 +7873,7 @@ echo "${ECHO_T}$cf_man2html_ok" >&6
esac
esac
-echo "$as_me:6081: checking for program to convert manpage to html" >&5
+echo "$as_me:7876: checking for program to convert manpage to html" >&5
echo $ECHO_N "checking for program to convert manpage to html... $ECHO_C" >&6
# Check whether --with-man2html or --without-man2html was given.
@@ -6093,11 +7888,11 @@ cf_with_groff=no
case $cf_man2html in
(yes)
- echo "$as_me:6096: result: man2html" >&5
+ echo "$as_me:7891: result: man2html" >&5
echo "${ECHO_T}man2html" >&6
# Extract the first word of "man2html", so it can be a program name with args.
set dummy man2html; ac_word=$2
-echo "$as_me:6100: checking for $ac_word" >&5
+echo "$as_me:7895: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_cf_man2html+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -6114,7 +7909,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if $as_executable_p "$ac_dir/$ac_word"; then
ac_cv_path_cf_man2html="$ac_dir/$ac_word"
- echo "$as_me:6117: found $ac_dir/$ac_word" >&5
+ echo "$as_me:7912: found $ac_dir/$ac_word" >&5
break
fi
done
@@ -6126,10 +7921,10 @@ fi
cf_man2html=$ac_cv_path_cf_man2html
if test -n "$cf_man2html"; then
- echo "$as_me:6129: result: $cf_man2html" >&5
+ echo "$as_me:7924: result: $cf_man2html" >&5
echo "${ECHO_T}$cf_man2html" >&6
else
- echo "$as_me:6132: result: no" >&5
+ echo "$as_me:7927: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -6137,11 +7932,11 @@ fi
(no|groff|*/groff*)
cf_with_groff=yes
cf_man2html=$GROFF_PATH
- echo "$as_me:6140: result: $cf_man2html" >&5
+ echo "$as_me:7935: result: $cf_man2html" >&5
echo "${ECHO_T}$cf_man2html" >&6
;;
(*)
- echo "$as_me:6144: result: $cf_man2html" >&5
+ echo "$as_me:7939: result: $cf_man2html" >&5
echo "${ECHO_T}$cf_man2html" >&6
;;
esac
@@ -6170,6 +7965,7 @@ export GROFF_NO_SGR
CF_EOF
+NROFF_OPTS=
if test "x$cf_with_groff" = xyes
then
MAN2HTML_NOTE="$GROFF_NOTE"
@@ -6178,6 +7974,18 @@ then
$SHELL -c "$TBL_PATH \${ROOT}.\${TYPE} | $GROFF_PATH -P -o0 -I\${ROOT}_ -Thtml -\${MACS}"
CF_EOF
else
+ # disable hyphenation if this is groff
+ if test "x$GROFF_PATH" != xno
+ then
+ echo "$as_me:7980: checking if nroff is really groff" >&5
+echo $ECHO_N "checking if nroff is really groff... $ECHO_C" >&6
+ cf_check_groff="`$NROFF_PATH --version 2>/dev/null | grep groff`"
+ test -n "$cf_check_groff" && cf_check_groff=yes
+ test -n "$cf_check_groff" || cf_check_groff=no
+ echo "$as_me:7985: result: $cf_check_groff" >&5
+echo "${ECHO_T}$cf_check_groff" >&6
+ test "x$cf_check_groff" = xyes && NROFF_OPTS="-rHY=0"
+ fi
MAN2HTML_NOTE=""
if test "x$prefix" != xNONE; then
@@ -6193,26 +8001,26 @@ case ".$cf_man2html" in
;;
(.[a-zA-Z]:[\\/]*) # OS/2 EMX
;;
-(.\${*prefix}*|.\${*dir}*)
+(.\$\{*prefix\}*|.\$\{*dir\}*)
eval cf_man2html="$cf_man2html"
case ".$cf_man2html" in
(.NONE/*)
- cf_man2html=`echo $cf_man2html | sed -e s%NONE%$cf_path_syntax%`
+ cf_man2html=`echo "$cf_man2html" | sed -e s%NONE%$cf_path_syntax%`
;;
esac
;;
(.no|.NONE/*)
- cf_man2html=`echo $cf_man2html | sed -e s%NONE%$cf_path_syntax%`
+ cf_man2html=`echo "$cf_man2html" | sed -e s%NONE%$cf_path_syntax%`
;;
(*)
- { { echo "$as_me:6208: error: expected a pathname, not \"$cf_man2html\"" >&5
+ { { echo "$as_me:8016: error: expected a pathname, not \"$cf_man2html\"" >&5
echo "$as_me: error: expected a pathname, not \"$cf_man2html\"" >&2;}
{ (exit 1); exit 1; }; }
;;
esac
MAN2HTML_PATH="$cf_man2html"
- echo "$as_me:6215: checking for $cf_man2html top/bottom margins" >&5
+ echo "$as_me:8023: checking for $cf_man2html top/bottom margins" >&5
echo $ECHO_N "checking for $cf_man2html top/bottom margins... $ECHO_C" >&6
# for this example, expect 3 lines of content, the remainder is head/foot
@@ -6224,16 +8032,16 @@ CF_EOF
LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
- cf_man2html_1st=`fgrep -n MARKER conftest.out |sed -e 's/^[^0-9]*://' -e 's/:.*//'`
- cf_man2html_top=`expr $cf_man2html_1st - 2`
- cf_man2html_bot=`wc -l conftest.out |sed -e 's/[^0-9]//g'`
- cf_man2html_bot=`expr $cf_man2html_bot - 2 - $cf_man2html_top`
+ cf_man2html_1st="`${FGREP-fgrep} -n MARKER conftest.out |sed -e 's/^[^0-9]*://' -e 's/:.*//'`"
+ cf_man2html_top=`expr "$cf_man2html_1st" - 2`
+ cf_man2html_bot="`wc -l conftest.out |sed -e 's/[^0-9]//g'`"
+ cf_man2html_bot=`expr "$cf_man2html_bot" - 2 - "$cf_man2html_top"`
cf_man2html_top_bot="-topm=$cf_man2html_top -botm=$cf_man2html_bot"
- echo "$as_me:6233: result: $cf_man2html_top_bot" >&5
+ echo "$as_me:8041: result: $cf_man2html_top_bot" >&5
echo "${ECHO_T}$cf_man2html_top_bot" >&6
- echo "$as_me:6236: checking for pagesize to use" >&5
+ echo "$as_me:8044: checking for pagesize to use" >&5
echo $ECHO_N "checking for pagesize to use... $ECHO_C" >&6
for cf_block in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
do
@@ -6253,23 +8061,23 @@ CF_EOF
done
LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
- cf_man2html_page=`fgrep -n HEAD1 conftest.out |tail -n 1 |sed -e 's/^[^0-9]*://' -e 's/:.*//'`
+ cf_man2html_page="`${FGREP-fgrep} -n HEAD1 conftest.out |sed -n '$p' |sed -e 's/^[^0-9]*://' -e 's/:.*//'`"
test -z "$cf_man2html_page" && cf_man2html_page=99999
test "$cf_man2html_page" -gt 100 && cf_man2html_page=99999
rm -rf conftest*
- echo "$as_me:6261: result: $cf_man2html_page" >&5
+ echo "$as_me:8069: result: $cf_man2html_page" >&5
echo "${ECHO_T}$cf_man2html_page" >&6
cat >>$MAN2HTML_TEMP <<CF_EOF
: \${MAN2HTML_PATH=$MAN2HTML_PATH}
-MAN2HTML_OPTS="\$MAN2HTML_OPTS -index -title="\$ROOT\(\$TYPE\)" -compress -pgsize $cf_man2html_page"
+MAN2HTML_OPTS="\$MAN2HTML_OPTS -index -title=\"\$ROOT(\$TYPE)\" -compress -pgsize $cf_man2html_page"
case \${TYPE} in
(ms)
- $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH -\${MACS} | \$MAN2HTML_PATH -topm=0 -botm=0 \$MAN2HTML_OPTS
+ $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH -topm=0 -botm=0 \$MAN2HTML_OPTS
;;
(*)
- $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH -\${MACS} | \$MAN2HTML_PATH $cf_man2html_top_bot \$MAN2HTML_OPTS
+ $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH $cf_man2html_top_bot \$MAN2HTML_OPTS
;;
esac
CF_EOF
@@ -6278,14 +8086,13 @@ fi
chmod 700 $MAN2HTML_TEMP
EXTRAOBJS=""
-
-echo "$as_me:6282: checking for ANSI C header files" >&5
+echo "$as_me:8089: checking for ANSI C header files" >&5
echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
if test "${ac_cv_header_stdc+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6288 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8095 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -6293,14 +8100,14 @@ else
#include <float.h>
_ACEOF
-if { (eval echo "$as_me:6296: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:8103: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:6302: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:8109: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -6313,21 +8120,21 @@ if test -z "$ac_cpp_err"; then
ac_cv_header_stdc=yes
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
ac_cv_header_stdc=no
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat >conftest.$ac_ext <<_ACEOF
-#line 6324 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8131 "configure"
#include "confdefs.h"
#include <string.h>
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "memchr" >/dev/null 2>&1; then
+ $EGREP "memchr" >/dev/null 2>&1; then
:
else
ac_cv_header_stdc=no
@@ -6338,14 +8145,14 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat >conftest.$ac_ext <<_ACEOF
-#line 6342 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8149 "configure"
#include "confdefs.h"
#include <stdlib.h>
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "free" >/dev/null 2>&1; then
+ $EGREP "free" >/dev/null 2>&1; then
:
else
ac_cv_header_stdc=no
@@ -6359,8 +8166,8 @@ if test $ac_cv_header_stdc = yes; then
if test "$cross_compiling" = yes; then
:
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6363 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8170 "configure"
#include "confdefs.h"
#include <ctype.h>
#if ((' ' & 0x0FF) == 0x020)
@@ -6385,29 +8192,29 @@ main (void)
$ac_main_return (0);
}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:6389: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:8196: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:6392: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:6394: \"$ac_try\"") >&5
+ echo "$as_me:8199: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:8201: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6397: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8204: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_header_stdc=no
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
fi
fi
-echo "$as_me:6410: result: $ac_cv_header_stdc" >&5
+echo "$as_me:8217: result: $ac_cv_header_stdc" >&5
echo "${ECHO_T}$ac_cv_header_stdc" >&6
if test $ac_cv_header_stdc = yes; then
@@ -6417,15 +8224,15 @@ EOF
fi
-echo "$as_me:6420: checking for inline" >&5
+echo "$as_me:8227: checking for inline" >&5
echo $ECHO_N "checking for inline... $ECHO_C" >&6
if test "${ac_cv_c_inline+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
- cat >conftest.$ac_ext <<_ACEOF
-#line 6428 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8235 "configure"
#include "confdefs.h"
#ifndef __cplusplus
static $ac_kw int static_foo () {return 0; }
@@ -6433,28 +8240,28 @@ $ac_kw int foo () {return 0; }
#endif
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:6437: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:8244: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:6440: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:6443: \"$ac_try\"") >&5
+ echo "$as_me:8247: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:8250: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6446: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8253: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_c_inline=$ac_kw; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
fi
-echo "$as_me:6457: result: $ac_cv_c_inline" >&5
+echo "$as_me:8264: result: $ac_cv_c_inline" >&5
echo "${ECHO_T}$ac_cv_c_inline" >&6
case $ac_cv_c_inline in
inline | yes) ;;
@@ -6475,40 +8282,40 @@ for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
inttypes.h stdint.h unistd.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:6478: checking for $ac_header" >&5
+echo "$as_me:8285: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6484 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8291 "configure"
#include "confdefs.h"
$ac_includes_default
#include <$ac_header>
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:6490: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:8297: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:6493: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:6496: \"$ac_try\"") >&5
+ echo "$as_me:8300: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:8303: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6499: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8306: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:6509: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:8316: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -6516,13 +8323,13 @@ EOF
fi
done
-echo "$as_me:6519: checking for off_t" >&5
+echo "$as_me:8326: checking for off_t" >&5
echo $ECHO_N "checking for off_t... $ECHO_C" >&6
if test "${ac_cv_type_off_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6525 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8332 "configure"
#include "confdefs.h"
$ac_includes_default
int
@@ -6536,29 +8343,29 @@ if (sizeof (off_t))
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:6540: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:8347: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:6543: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:6546: \"$ac_try\"") >&5
+ echo "$as_me:8350: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:8353: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6549: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8356: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_type_off_t=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_type_off_t=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:6559: result: $ac_cv_type_off_t" >&5
+echo "$as_me:8366: result: $ac_cv_type_off_t" >&5
echo "${ECHO_T}$ac_cv_type_off_t" >&6
-if test $ac_cv_type_off_t = yes; then
+if test "$ac_cv_type_off_t" = yes; then
:
else
@@ -6568,13 +8375,13 @@ EOF
fi
-echo "$as_me:6571: checking for size_t" >&5
+echo "$as_me:8378: checking for size_t" >&5
echo $ECHO_N "checking for size_t... $ECHO_C" >&6
if test "${ac_cv_type_size_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6577 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8384 "configure"
#include "confdefs.h"
$ac_includes_default
int
@@ -6588,29 +8395,29 @@ if (sizeof (size_t))
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:6592: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:8399: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:6595: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:6598: \"$ac_try\"") >&5
+ echo "$as_me:8402: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:8405: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6601: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8408: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_type_size_t=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_type_size_t=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:6611: result: $ac_cv_type_size_t" >&5
+echo "$as_me:8418: result: $ac_cv_type_size_t" >&5
echo "${ECHO_T}$ac_cv_type_size_t" >&6
-if test $ac_cv_type_size_t = yes; then
+if test "$ac_cv_type_size_t" = yes; then
:
else
@@ -6622,13 +8429,13 @@ fi
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
-echo "$as_me:6625: checking for working alloca.h" >&5
+echo "$as_me:8432: checking for working alloca.h" >&5
echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
if test "${ac_cv_working_alloca_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6631 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8438 "configure"
#include "confdefs.h"
#include <alloca.h>
int
@@ -6639,27 +8446,27 @@ char *p = (char *) alloca (2 * sizeof (int));
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:6643: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:8450: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:6646: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:6649: \"$ac_try\"") >&5
+ echo "$as_me:8453: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:8456: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6652: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8459: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_working_alloca_h=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_working_alloca_h=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:6662: result: $ac_cv_working_alloca_h" >&5
+echo "$as_me:8469: result: $ac_cv_working_alloca_h" >&5
echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
if test $ac_cv_working_alloca_h = yes; then
@@ -6669,13 +8476,13 @@ EOF
fi
-echo "$as_me:6672: checking for alloca" >&5
+echo "$as_me:8479: checking for alloca" >&5
echo $ECHO_N "checking for alloca... $ECHO_C" >&6
if test "${ac_cv_func_alloca_works+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6678 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8485 "configure"
#include "confdefs.h"
#ifdef __GNUC__
# define alloca __builtin_alloca
@@ -6706,27 +8513,27 @@ char *p = (char *) alloca (1);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:6710: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:8517: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:6713: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:6716: \"$ac_try\"") >&5
+ echo "$as_me:8520: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:8523: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6719: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8526: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_alloca_works=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_alloca_works=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:6729: result: $ac_cv_func_alloca_works" >&5
+echo "$as_me:8536: result: $ac_cv_func_alloca_works" >&5
echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
if test $ac_cv_func_alloca_works = yes; then
@@ -6741,19 +8548,19 @@ else
# contain a buggy version. If you still want to use their alloca,
# use ar to extract alloca.o from them instead of compiling alloca.c.
-ALLOCA=alloca.$ac_objext
+ALLOCA="alloca.$ac_objext"
cat >>confdefs.h <<\EOF
#define C_ALLOCA 1
EOF
-echo "$as_me:6750: checking whether \`alloca.c' needs Cray hooks" >&5
+echo "$as_me:8557: checking whether \`alloca.c' needs Cray hooks" >&5
echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
if test "${ac_cv_os_cray+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6756 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8563 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
@@ -6763,7 +8570,7 @@ wenotbecray
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "webecray" >/dev/null 2>&1; then
+ $EGREP "webecray" >/dev/null 2>&1; then
ac_cv_os_cray=yes
else
ac_cv_os_cray=no
@@ -6771,70 +8578,70 @@ fi
rm -rf conftest*
fi
-echo "$as_me:6774: result: $ac_cv_os_cray" >&5
+echo "$as_me:8581: result: $ac_cv_os_cray" >&5
echo "${ECHO_T}$ac_cv_os_cray" >&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:6779: checking for $ac_func" >&5
+echo "$as_me:8586: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6785 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8592 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define $ac_func autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef $ac_func
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char $ac_func ();
-char (*f) ();
+char $ac_func (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for $ac_func
#endif
+ return $ac_func ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:6816: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:8623: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:6819: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:6822: \"$ac_try\"") >&5
+ echo "$as_me:8626: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:8629: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6825: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8632: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_var=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_var=no"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:6835: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
+echo "$as_me:8642: result: `eval echo '${'"$as_ac_var"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
+if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define CRAY_STACKSEG_END $ac_func
@@ -6846,7 +8653,7 @@ fi
done
fi
-echo "$as_me:6849: checking stack direction for C alloca" >&5
+echo "$as_me:8656: checking stack direction for C alloca" >&5
echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
if test "${ac_cv_c_stack_direction+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -6854,8 +8661,8 @@ else
if test "$cross_compiling" = yes; then
ac_cv_c_stack_direction=0
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6858 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8665 "configure"
#include "confdefs.h"
int
find_stack_direction (void)
@@ -6877,28 +8684,28 @@ main (void)
$ac_main_return (find_stack_direction () < 0);
}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:6881: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:8688: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:6884: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:6886: \"$ac_try\"") >&5
+ echo "$as_me:8691: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:8693: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:6889: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8696: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_c_stack_direction=1
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_c_stack_direction=-1
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
fi
-echo "$as_me:6901: result: $ac_cv_c_stack_direction" >&5
+echo "$as_me:8708: result: $ac_cv_c_stack_direction" >&5
echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
cat >>confdefs.h <<EOF
@@ -6910,24 +8717,24 @@ fi
for ac_header in stdlib.h unistd.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:6913: checking for $ac_header" >&5
+echo "$as_me:8720: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6919 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8726 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:6923: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:8730: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:6929: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:8736: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -6940,14 +8747,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:6948: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:8755: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -6958,65 +8765,65 @@ done
for ac_func in getpagesize
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:6961: checking for $ac_func" >&5
+echo "$as_me:8768: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 6967 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8774 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define $ac_func autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef $ac_func
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char $ac_func ();
-char (*f) ();
+char $ac_func (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for $ac_func
#endif
+ return $ac_func ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:6998: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:8805: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:7001: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:7004: \"$ac_try\"") >&5
+ echo "$as_me:8808: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:8811: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7007: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8814: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_var=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_var=no"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:7017: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
+echo "$as_me:8824: result: `eval echo '${'"$as_ac_var"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
+if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF
@@ -7024,7 +8831,7 @@ EOF
fi
done
-echo "$as_me:7027: checking for working mmap" >&5
+echo "$as_me:8834: checking for working mmap" >&5
echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -7032,8 +8839,8 @@ else
if test "$cross_compiling" = yes; then
ac_cv_func_mmap_fixed_mapped=no
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 7036 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 8843 "configure"
#include "confdefs.h"
$ac_includes_default
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -7159,28 +8966,28 @@ main (void)
$ac_main_return (0);
}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:7163: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:8970: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:7166: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:7168: \"$ac_try\"") >&5
+ echo "$as_me:8973: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:8975: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7171: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:8978: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_mmap_fixed_mapped=yes
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_mmap_fixed_mapped=no
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
fi
-echo "$as_me:7183: result: $ac_cv_func_mmap_fixed_mapped" >&5
+echo "$as_me:8990: result: $ac_cv_func_mmap_fixed_mapped" >&5
echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
if test $ac_cv_func_mmap_fixed_mapped = yes; then
@@ -7191,13 +8998,13 @@ EOF
fi
rm -f conftest.mmap
-echo "$as_me:7194: checking whether we are using the GNU C Library 2.1 or newer" >&5
+echo "$as_me:9001: checking whether we are using the GNU C Library 2.1 or newer" >&5
echo $ECHO_N "checking whether we are using the GNU C Library 2.1 or newer... $ECHO_C" >&6
if test "${ac_cv_gnu_library_2_1+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 7200 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9007 "configure"
#include "confdefs.h"
#include <features.h>
@@ -7209,7 +9016,7 @@ else
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "Lucky GNU user" >/dev/null 2>&1; then
+ $EGREP "Lucky GNU user" >/dev/null 2>&1; then
ac_cv_gnu_library_2_1=yes
else
ac_cv_gnu_library_2_1=no
@@ -7217,27 +9024,27 @@ fi
rm -rf conftest*
fi
-echo "$as_me:7220: result: $ac_cv_gnu_library_2_1" >&5
+echo "$as_me:9027: result: $ac_cv_gnu_library_2_1" >&5
echo "${ECHO_T}$ac_cv_gnu_library_2_1" >&6
GLIBC21="$ac_cv_gnu_library_2_1"
cf_makefile=makefile
-test -z "$ALL_LINGUAS" && ALL_LINGUAS=`test -d $srcdir/po && cd $srcdir/po && echo *.po|sed -e 's/\.po//g' -e 's/*//'`
+test -z "$ALL_LINGUAS" && ALL_LINGUAS=`test -d "$srcdir/po" && cd "$srcdir/po" && echo *.po|sed -e 's/\.po//g' -e 's/*//'`
# Allow override of "config.h" definition:
: ${CONFIG_H:=config.h}
if test -z "$PACKAGE" ; then
- { { echo "$as_me:7233: error: CF_BUNDLED_INTL used without setting PACKAGE variable" >&5
+ { { echo "$as_me:9040: error: CF_BUNDLED_INTL used without setting PACKAGE variable" >&5
echo "$as_me: error: CF_BUNDLED_INTL used without setting PACKAGE variable" >&2;}
{ (exit 1); exit 1; }; }
fi
if test -z "$VERSION" ; then
-if test -f $srcdir/VERSION ; then
- VERSION=`sed -e '2,$d' $srcdir/VERSION|cut -f1`
+if test -f "$srcdir/VERSION" ; then
+ VERSION=`sed -e '2,$d' "$srcdir/VERSION" |cut -f1`
else
VERSION=unknown
fi
@@ -7247,24 +9054,24 @@ for ac_header in argz.h limits.h locale.h nl_types.h malloc.h stddef.h \
stdlib.h string.h unistd.h sys/param.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:7250: checking for $ac_header" >&5
+echo "$as_me:9057: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 7256 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9063 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:7260: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:9067: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:7266: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:9073: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -7277,14 +9084,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:7285: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:9092: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -7297,65 +9104,65 @@ getgid getuid mempcpy munmap putenv setenv setlocale stpcpy strchr strcasecmp \
strdup strtoul tsearch __argz_count __argz_stringify __argz_next
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:7300: checking for $ac_func" >&5
+echo "$as_me:9107: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 7306 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9113 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define $ac_func autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef $ac_func
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char $ac_func ();
-char (*f) ();
+char $ac_func (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for $ac_func
#endif
+ return $ac_func ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:7337: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:9144: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:7340: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:7343: \"$ac_try\"") >&5
+ echo "$as_me:9147: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:9150: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7346: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9153: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_var=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_var=no"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:7356: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
+echo "$as_me:9163: result: `eval echo '${'"$as_ac_var"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
+if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF
@@ -7375,14 +9182,14 @@ case "$withval" in
(*)
for cf_searchpath in `echo "$withval" | tr $PATH_SEPARATOR ' '`; do
- if test -d $cf_searchpath/include; then
+ if test -d "$cf_searchpath/include" ; then
if test -n "$cf_searchpath/include" ; then
for cf_add_incdir in $cf_searchpath/include
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -7403,8 +9210,8 @@ if test -n "$cf_searchpath/include" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 7407 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9214 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -7415,25 +9222,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:7419: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:9226: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:7422: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:7425: \"$ac_try\"") >&5
+ echo "$as_me:9229: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:9232: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7428: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9235: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -7442,11 +9249,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:7445: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:9252: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -7459,14 +9266,14 @@ echo "${as_me:-configure}:7445: testing adding $cf_add_incdir to include-path ..
done
fi
- elif test -d $cf_searchpath/../include ; then
+ elif test -d "$cf_searchpath/../include" ; then
if test -n "$cf_searchpath/../include" ; then
for cf_add_incdir in $cf_searchpath/../include
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -7487,8 +9294,8 @@ if test -n "$cf_searchpath/../include" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 7491 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9298 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -7499,25 +9306,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:7503: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:9310: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:7506: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:7509: \"$ac_try\"") >&5
+ echo "$as_me:9313: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:9316: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7512: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9319: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -7526,11 +9333,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:7529: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:9336: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -7544,18 +9351,18 @@ echo "${as_me:-configure}:7529: testing adding $cf_add_incdir to include-path ..
fi
else
-{ { echo "$as_me:7547: error: cannot find libiconv under $withval" >&5
+{ { echo "$as_me:9354: error: cannot find libiconv under $withval" >&5
echo "$as_me: error: cannot find libiconv under $withval" >&2;}
{ (exit 1); exit 1; }; }
fi
- if test -d $cf_searchpath/lib; then
+ if test -d "$cf_searchpath/lib" ; then
if test -n "$cf_searchpath/lib" ; then
for cf_add_libdir in $cf_searchpath/lib
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -7569,7 +9376,7 @@ if test -n "$cf_searchpath/lib" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:7572: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:9379: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -7577,14 +9384,14 @@ echo "${as_me:-configure}:7572: testing adding $cf_add_libdir to library-path ..
done
fi
- elif test -d $cf_searchpath ; then
+ elif test -d "$cf_searchpath" ; then
if test -n "$cf_searchpath" ; then
for cf_add_libdir in $cf_searchpath
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -7598,7 +9405,7 @@ if test -n "$cf_searchpath" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:7601: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:9408: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -7607,7 +9414,7 @@ echo "${as_me:-configure}:7601: testing adding $cf_add_libdir to library-path ..
fi
else
-{ { echo "$as_me:7610: error: cannot find libiconv under $withval" >&5
+{ { echo "$as_me:9417: error: cannot find libiconv under $withval" >&5
echo "$as_me: error: cannot find libiconv under $withval" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -7618,7 +9425,7 @@ esac
fi;
- echo "$as_me:7621: checking for iconv" >&5
+ echo "$as_me:9428: checking for iconv" >&5
echo $ECHO_N "checking for iconv... $ECHO_C" >&6
if test "${am_cv_func_iconv+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -7629,12 +9436,12 @@ else
cf_cv_header_path_iconv=
cf_cv_library_path_iconv=
-echo "${as_me:-configure}:7632: testing Starting FIND_LINKAGE(iconv,) ..." 1>&5
+echo "${as_me:-configure}:9439: testing Starting FIND_LINKAGE(iconv,) ..." 1>&5
cf_save_LIBS="$LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 7637 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 9444 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -7652,18 +9459,18 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:7656: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:9463: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:7659: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:7662: \"$ac_try\"") >&5
+ echo "$as_me:9466: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:9469: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7665: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9472: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_find_linkage_iconv=yes
cf_cv_header_path_iconv=/usr/include
@@ -7671,12 +9478,12 @@ if { (eval echo "$as_me:7656: \"$ac_link\"") >&5
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
LIBS="-liconv $cf_save_LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 7679 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 9486 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -7694,18 +9501,18 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:7698: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:9505: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:7701: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:7704: \"$ac_try\"") >&5
+ echo "$as_me:9508: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:9511: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7707: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9514: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_find_linkage_iconv=yes
cf_cv_header_path_iconv=/usr/include
@@ -7714,16 +9521,16 @@ if { (eval echo "$as_me:7698: \"$ac_link\"") >&5
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_find_linkage_iconv=no
LIBS="$cf_save_LIBS"
test -n "$verbose" && echo " find linkage for iconv library" 1>&6
-echo "${as_me:-configure}:7724: testing find linkage for iconv library ..." 1>&5
+echo "${as_me:-configure}:9531: testing find linkage for iconv library ..." 1>&5
-echo "${as_me:-configure}:7726: testing Searching for headers in FIND_LINKAGE(iconv,) ..." 1>&5
+echo "${as_me:-configure}:9533: testing Searching for headers in FIND_LINKAGE(iconv,) ..." 1>&5
cf_save_CPPFLAGS="$CPPFLAGS"
cf_test_CPPFLAGS="$CPPFLAGS"
@@ -7735,7 +9542,7 @@ cf_header_path_list=""
if test -n "${CFLAGS}${CPPFLAGS}" ; then
for cf_header_path in $CPPFLAGS $CFLAGS
do
- case $cf_header_path in
+ case "$cf_header_path" in
(-I*)
cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
@@ -7743,11 +9550,11 @@ test "x$cf_header_path" != "xNONE" && \
test -d "$cf_header_path" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
- test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
- test -d $cf_header_path/include/iconv && cf_search="$cf_search $cf_header_path/include/iconv"
- test -d $cf_header_path/include/iconv/include && cf_search="$cf_search $cf_header_path/include/iconv/include"
- test -d $cf_header_path/iconv/include && cf_search="$cf_search $cf_header_path/iconv/include"
- test -d $cf_header_path/iconv/include/iconv && cf_search="$cf_search $cf_header_path/iconv/include/iconv"
+ test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
+ test -d "$cf_header_path/include/iconv" && cf_search="$cf_search $cf_header_path/include/iconv"
+ test -d "$cf_header_path/include/iconv/include" && cf_search="$cf_search $cf_header_path/include/iconv/include"
+ test -d "$cf_header_path/iconv/include" && cf_search="$cf_search $cf_header_path/iconv/include"
+ test -d "$cf_header_path/iconv/include/iconv" && cf_search="$cf_search $cf_header_path/iconv/include/iconv"
}
cf_header_path_list="$cf_header_path_list $cf_search"
@@ -7764,11 +9571,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $prefix"
- test -d $prefix/include && cf_search="$cf_search $prefix/include"
- test -d $prefix/include/iconv && cf_search="$cf_search $prefix/include/iconv"
- test -d $prefix/include/iconv/include && cf_search="$cf_search $prefix/include/iconv/include"
- test -d $prefix/iconv/include && cf_search="$cf_search $prefix/iconv/include"
- test -d $prefix/iconv/include/iconv && cf_search="$cf_search $prefix/iconv/include/iconv"
+ test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
+ test -d "$prefix/include/iconv" && cf_search="$cf_search $prefix/include/iconv"
+ test -d "$prefix/include/iconv/include" && cf_search="$cf_search $prefix/include/iconv/include"
+ test -d "$prefix/iconv/include" && cf_search="$cf_search $prefix/iconv/include"
+ test -d "$prefix/iconv/include/iconv" && cf_search="$cf_search $prefix/iconv/include/iconv"
}
for cf_subdir_prefix in \
@@ -7782,13 +9589,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
- test -d $cf_subdir_prefix/include/iconv && cf_search="$cf_search $cf_subdir_prefix/include/iconv"
- test -d $cf_subdir_prefix/include/iconv/include && cf_search="$cf_search $cf_subdir_prefix/include/iconv/include"
- test -d $cf_subdir_prefix/iconv/include && cf_search="$cf_search $cf_subdir_prefix/iconv/include"
- test -d $cf_subdir_prefix/iconv/include/iconv && cf_search="$cf_search $cf_subdir_prefix/iconv/include/iconv"
+ test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
+ test -d "$cf_subdir_prefix/include/iconv" && cf_search="$cf_search $cf_subdir_prefix/include/iconv"
+ test -d "$cf_subdir_prefix/include/iconv/include" && cf_search="$cf_search $cf_subdir_prefix/include/iconv/include"
+ test -d "$cf_subdir_prefix/iconv/include" && cf_search="$cf_search $cf_subdir_prefix/iconv/include"
+ test -d "$cf_subdir_prefix/iconv/include/iconv" && cf_search="$cf_search $cf_subdir_prefix/iconv/include/iconv"
}
done
@@ -7796,33 +9603,33 @@ done
test "$includedir" != NONE && \
test "$includedir" != "/usr/include" && \
test -d "$includedir" && {
- test -d $includedir && cf_search="$cf_search $includedir"
- test -d $includedir/iconv && cf_search="$cf_search $includedir/iconv"
+ test -d "$includedir" && cf_search="$cf_search $includedir"
+ test -d "$includedir/iconv" && cf_search="$cf_search $includedir/iconv"
}
test "$oldincludedir" != NONE && \
test "$oldincludedir" != "/usr/include" && \
test -d "$oldincludedir" && {
- test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
- test -d $oldincludedir/iconv && cf_search="$cf_search $oldincludedir/iconv"
+ test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
+ test -d "$oldincludedir/iconv" && cf_search="$cf_search $oldincludedir/iconv"
}
cf_search="$cf_search $cf_header_path_list"
for cf_cv_header_path_iconv in $cf_search
do
- if test -d $cf_cv_header_path_iconv ; then
+ if test -d "$cf_cv_header_path_iconv" ; then
test -n "$verbose" && echo " ... testing $cf_cv_header_path_iconv" 1>&6
-echo "${as_me:-configure}:7817: testing ... testing $cf_cv_header_path_iconv ..." 1>&5
+echo "${as_me:-configure}:9624: testing ... testing $cf_cv_header_path_iconv ..." 1>&5
CPPFLAGS="$cf_save_CPPFLAGS"
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_iconv"
- cat >conftest.$ac_ext <<_ACEOF
-#line 7825 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9632 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -7840,40 +9647,40 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:7844: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:9651: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:7847: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:7850: \"$ac_try\"") >&5
+ echo "$as_me:9654: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:9657: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7853: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9660: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
test -n "$verbose" && echo " ... found iconv headers in $cf_cv_header_path_iconv" 1>&6
-echo "${as_me:-configure}:7858: testing ... found iconv headers in $cf_cv_header_path_iconv ..." 1>&5
+echo "${as_me:-configure}:9665: testing ... found iconv headers in $cf_cv_header_path_iconv ..." 1>&5
cf_cv_find_linkage_iconv=maybe
cf_test_CPPFLAGS="$CPPFLAGS"
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
CPPFLAGS="$cf_save_CPPFLAGS"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
done
if test "$cf_cv_find_linkage_iconv" = maybe ; then
-echo "${as_me:-configure}:7876: testing Searching for iconv library in FIND_LINKAGE(iconv,) ..." 1>&5
+echo "${as_me:-configure}:9683: testing Searching for iconv library in FIND_LINKAGE(iconv,) ..." 1>&5
cf_save_LIBS="$LIBS"
cf_save_LDFLAGS="$LDFLAGS"
@@ -7885,7 +9692,7 @@ cf_library_path_list=""
if test -n "${LDFLAGS}${LIBS}" ; then
for cf_library_path in $LDFLAGS $LIBS
do
- case $cf_library_path in
+ case "$cf_library_path" in
(-L*)
cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
@@ -7893,11 +9700,11 @@ test "x$cf_library_path" != "xNONE" && \
test -d "$cf_library_path" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
- test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
- test -d $cf_library_path/lib/iconv && cf_search="$cf_search $cf_library_path/lib/iconv"
- test -d $cf_library_path/lib/iconv/lib && cf_search="$cf_search $cf_library_path/lib/iconv/lib"
- test -d $cf_library_path/iconv/lib && cf_search="$cf_search $cf_library_path/iconv/lib"
- test -d $cf_library_path/iconv/lib/iconv && cf_search="$cf_search $cf_library_path/iconv/lib/iconv"
+ test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
+ test -d "$cf_library_path/lib/iconv" && cf_search="$cf_search $cf_library_path/lib/iconv"
+ test -d "$cf_library_path/lib/iconv/lib" && cf_search="$cf_search $cf_library_path/lib/iconv/lib"
+ test -d "$cf_library_path/iconv/lib" && cf_search="$cf_search $cf_library_path/iconv/lib"
+ test -d "$cf_library_path/iconv/lib/iconv" && cf_search="$cf_search $cf_library_path/iconv/lib/iconv"
}
cf_library_path_list="$cf_library_path_list $cf_search"
@@ -7912,11 +9719,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
- test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
- test -d $prefix/lib/iconv && cf_search="$cf_search $prefix/lib/iconv"
- test -d $prefix/lib/iconv/lib && cf_search="$cf_search $prefix/lib/iconv/lib"
- test -d $prefix/iconv/lib && cf_search="$cf_search $prefix/iconv/lib"
- test -d $prefix/iconv/lib/iconv && cf_search="$cf_search $prefix/iconv/lib/iconv"
+ test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
+ test -d "$prefix/lib/iconv" && cf_search="$cf_search $prefix/lib/iconv"
+ test -d "$prefix/lib/iconv/lib" && cf_search="$cf_search $prefix/lib/iconv/lib"
+ test -d "$prefix/iconv/lib" && cf_search="$cf_search $prefix/iconv/lib"
+ test -d "$prefix/iconv/lib/iconv" && cf_search="$cf_search $prefix/iconv/lib/iconv"
}
for cf_subdir_prefix in \
@@ -7930,13 +9737,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
- test -d $cf_subdir_prefix/lib/iconv && cf_search="$cf_search $cf_subdir_prefix/lib/iconv"
- test -d $cf_subdir_prefix/lib/iconv/lib && cf_search="$cf_search $cf_subdir_prefix/lib/iconv/lib"
- test -d $cf_subdir_prefix/iconv/lib && cf_search="$cf_search $cf_subdir_prefix/iconv/lib"
- test -d $cf_subdir_prefix/iconv/lib/iconv && cf_search="$cf_search $cf_subdir_prefix/iconv/lib/iconv"
+ test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
+ test -d "$cf_subdir_prefix/lib/iconv" && cf_search="$cf_search $cf_subdir_prefix/lib/iconv"
+ test -d "$cf_subdir_prefix/lib/iconv/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/iconv/lib"
+ test -d "$cf_subdir_prefix/iconv/lib" && cf_search="$cf_search $cf_subdir_prefix/iconv/lib"
+ test -d "$cf_subdir_prefix/iconv/lib/iconv" && cf_search="$cf_search $cf_subdir_prefix/iconv/lib/iconv"
}
done
@@ -7945,16 +9752,16 @@ cf_search="$cf_library_path_list $cf_search"
for cf_cv_library_path_iconv in $cf_search
do
- if test -d $cf_cv_library_path_iconv ; then
+ if test -d "$cf_cv_library_path_iconv" ; then
test -n "$verbose" && echo " ... testing $cf_cv_library_path_iconv" 1>&6
-echo "${as_me:-configure}:7951: testing ... testing $cf_cv_library_path_iconv ..." 1>&5
+echo "${as_me:-configure}:9758: testing ... testing $cf_cv_library_path_iconv ..." 1>&5
CPPFLAGS="$cf_test_CPPFLAGS"
LIBS="-liconv $cf_save_LIBS"
LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_iconv"
- cat >conftest.$ac_ext <<_ACEOF
-#line 7957 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9764 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -7972,36 +9779,36 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:7976: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:9783: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:7979: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:7982: \"$ac_try\"") >&5
+ echo "$as_me:9786: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:9789: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:7985: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9792: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
test -n "$verbose" && echo " ... found iconv library in $cf_cv_library_path_iconv" 1>&6
-echo "${as_me:-configure}:7990: testing ... found iconv library in $cf_cv_library_path_iconv ..." 1>&5
+echo "${as_me:-configure}:9797: testing ... found iconv library in $cf_cv_library_path_iconv ..." 1>&5
cf_cv_find_linkage_iconv=yes
cf_cv_library_file_iconv="-liconv"
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
CPPFLAGS="$cf_save_CPPFLAGS"
LIBS="$cf_save_LIBS"
LDFLAGS="$cf_save_LDFLAGS"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
done
CPPFLAGS="$cf_save_CPPFLAGS"
@@ -8013,10 +9820,10 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS="$cf_save_LIBS"
@@ -8027,7 +9834,7 @@ am_cv_func_iconv="no, consider installing GNU libiconv"
fi
fi
-echo "$as_me:8030: result: $am_cv_func_iconv" >&5
+echo "$as_me:9837: result: $am_cv_func_iconv" >&5
echo "${ECHO_T}$am_cv_func_iconv" >&6
if test "$am_cv_func_iconv" = yes; then
@@ -8036,14 +9843,14 @@ cat >>confdefs.h <<\EOF
#define HAVE_ICONV 1
EOF
- echo "$as_me:8039: checking if the declaration of iconv() needs const." >&5
+ echo "$as_me:9846: checking if the declaration of iconv() needs const." >&5
echo $ECHO_N "checking if the declaration of iconv() needs const.... $ECHO_C" >&6
if test "${am_cv_proto_iconv_const+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 8046 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9853 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -8067,27 +9874,27 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:8071: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:9878: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:8074: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:8077: \"$ac_try\"") >&5
+ echo "$as_me:9881: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:9884: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:8080: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9887: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
am_cv_proto_iconv_const=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
am_cv_proto_iconv_const=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:8090: result: $am_cv_proto_iconv_const" >&5
+echo "$as_me:9897: result: $am_cv_proto_iconv_const" >&5
echo "${ECHO_T}$am_cv_proto_iconv_const" >&6
if test "$am_cv_proto_iconv_const" = yes ; then
@@ -8108,9 +9915,9 @@ EOF
if test -n "$cf_cv_header_path_iconv" ; then
for cf_add_incdir in $cf_cv_header_path_iconv
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -8131,8 +9938,8 @@ if test -n "$cf_cv_header_path_iconv" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 8135 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 9942 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -8143,25 +9950,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:8147: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:9954: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:8150: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:8153: \"$ac_try\"") >&5
+ echo "$as_me:9957: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:9960: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:8156: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:9963: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -8170,11 +9977,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:8173: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:9980: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -8193,9 +10000,9 @@ fi
if test -n "$cf_cv_library_path_iconv" ; then
for cf_add_libdir in $cf_cv_library_path_iconv
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -8209,7 +10016,7 @@ if test -n "$cf_cv_library_path_iconv" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:8212: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:10019: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -8220,47 +10027,47 @@ fi
fi
fi
-echo "$as_me:8223: checking for nl_langinfo and CODESET" >&5
+echo "$as_me:10030: checking for nl_langinfo and CODESET" >&5
echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
if test "${am_cv_langinfo_codeset+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 8229 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 10036 "configure"
#include "confdefs.h"
#include <langinfo.h>
int
main (void)
{
-char* cs = nl_langinfo(CODESET);
+char* cs = nl_langinfo(CODESET); (void)cs
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:8241: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:10048: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:8244: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:8247: \"$ac_try\"") >&5
+ echo "$as_me:10051: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:10054: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:8250: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:10057: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
am_cv_langinfo_codeset=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
am_cv_langinfo_codeset=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:8261: result: $am_cv_langinfo_codeset" >&5
+echo "$as_me:10068: result: $am_cv_langinfo_codeset" >&5
echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
- if test $am_cv_langinfo_codeset = yes; then
+ if test "$am_cv_langinfo_codeset" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_LANGINFO_CODESET 1
@@ -8268,14 +10075,14 @@ EOF
fi
- if test $ac_cv_header_locale_h = yes; then
- echo "$as_me:8272: checking for LC_MESSAGES" >&5
+ if test "$ac_cv_header_locale_h" = yes; then
+ echo "$as_me:10079: checking for LC_MESSAGES" >&5
echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6
if test "${am_cv_val_LC_MESSAGES+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 8278 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 10085 "configure"
#include "confdefs.h"
#include <locale.h>
int
@@ -8286,29 +10093,29 @@ return LC_MESSAGES
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:8290: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:10097: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:8293: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:8296: \"$ac_try\"") >&5
+ echo "$as_me:10100: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:10103: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:8299: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:10106: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
am_cv_val_LC_MESSAGES=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
am_cv_val_LC_MESSAGES=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:8309: result: $am_cv_val_LC_MESSAGES" >&5
+echo "$as_me:10116: result: $am_cv_val_LC_MESSAGES" >&5
echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6
- if test $am_cv_val_LC_MESSAGES = yes; then
+ if test "$am_cv_val_LC_MESSAGES" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_LC_MESSAGES 1
@@ -8316,7 +10123,7 @@ EOF
fi
fi
- echo "$as_me:8319: checking whether NLS is requested" >&5
+ echo "$as_me:10126: checking whether NLS is requested" >&5
echo $ECHO_N "checking whether NLS is requested... $ECHO_C" >&6
# Check whether --enable-nls or --disable-nls was given.
@@ -8326,7 +10133,7 @@ if test "${enable_nls+set}" = set; then
else
USE_NLS=no
fi;
- echo "$as_me:8329: result: $USE_NLS" >&5
+ echo "$as_me:10136: result: $USE_NLS" >&5
echo "${ECHO_T}$USE_NLS" >&6
BUILD_INCLUDED_LIBINTL=no
@@ -8340,7 +10147,7 @@ cat >>confdefs.h <<\EOF
#define ENABLE_NLS 1
EOF
- echo "$as_me:8343: checking whether included gettext is requested" >&5
+ echo "$as_me:10150: checking whether included gettext is requested" >&5
echo $ECHO_N "checking whether included gettext is requested... $ECHO_C" >&6
# Check whether --with-included-gettext or --without-included-gettext was given.
@@ -8350,7 +10157,7 @@ if test "${with_included_gettext+set}" = set; then
else
nls_cv_force_use_gnu_gettext=no
fi;
- echo "$as_me:8353: result: $nls_cv_force_use_gnu_gettext" >&5
+ echo "$as_me:10160: result: $nls_cv_force_use_gnu_gettext" >&5
echo "${ECHO_T}$nls_cv_force_use_gnu_gettext" >&6
nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
@@ -8363,7 +10170,7 @@ echo "${ECHO_T}$nls_cv_force_use_gnu_gettext" >&6
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
-echo "$as_me:8366: checking for $ac_word" >&5
+echo "$as_me:10173: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_MSGFMT+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -8376,8 +10183,8 @@ else
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}"
for ac_dir in $PATH; do
test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word$ac_exeext; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1; then
+ if test -f "$ac_dir/$ac_word$ac_exeext" ; then
+ if "$ac_dir/$ac_word" --statistics /dev/null >/dev/null 2>&1; then
ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exeext"
break
fi
@@ -8390,16 +10197,16 @@ esac
fi
MSGFMT="$ac_cv_path_MSGFMT"
if test "$MSGFMT" != ":"; then
- echo "$as_me:8393: result: $MSGFMT" >&5
+ echo "$as_me:10200: result: $MSGFMT" >&5
echo "${ECHO_T}$MSGFMT" >&6
else
- echo "$as_me:8396: result: no" >&5
+ echo "$as_me:10203: result: no" >&5
echo "${ECHO_T}no" >&6
fi
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
-echo "$as_me:8402: checking for $ac_word" >&5
+echo "$as_me:10209: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_GMSGFMT+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -8416,7 +10223,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
if $as_executable_p "$ac_dir/$ac_word"; then
ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
- echo "$as_me:8419: found $ac_dir/$ac_word" >&5
+ echo "$as_me:10226: found $ac_dir/$ac_word" >&5
break
fi
done
@@ -8428,17 +10235,17 @@ fi
GMSGFMT=$ac_cv_path_GMSGFMT
if test -n "$GMSGFMT"; then
- echo "$as_me:8431: result: $GMSGFMT" >&5
+ echo "$as_me:10238: result: $GMSGFMT" >&5
echo "${ECHO_T}$GMSGFMT" >&6
else
- echo "$as_me:8434: result: no" >&5
+ echo "$as_me:10241: result: no" >&5
echo "${ECHO_T}no" >&6
fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
-echo "$as_me:8441: checking for $ac_word" >&5
+echo "$as_me:10248: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_path_XGETTEXT+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -8451,8 +10258,8 @@ else
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}"
for ac_dir in $PATH; do
test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word$ac_exeext; then
- if $ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1; then
+ if test -f "$ac_dir/$ac_word$ac_exeext" ; then
+ if "$ac_dir/$ac_word" --omit-header /dev/null >/dev/null 2>&1; then
ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exeext"
break
fi
@@ -8465,10 +10272,10 @@ esac
fi
XGETTEXT="$ac_cv_path_XGETTEXT"
if test "$XGETTEXT" != ":"; then
- echo "$as_me:8468: result: $XGETTEXT" >&5
+ echo "$as_me:10275: result: $XGETTEXT" >&5
echo "${ECHO_T}$XGETTEXT" >&6
else
- echo "$as_me:8471: result: no" >&5
+ echo "$as_me:10278: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -8483,19 +10290,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in -DIGNORE_MSGFMT_HACK
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -8514,7 +10321,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -8544,7 +10351,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -8578,19 +10385,19 @@ fi
cf_save_LIBS_1="$LIBS"
-cf_add_libs="$LIBICONV"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $LIBICONV; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -8599,12 +10406,12 @@ LIBS="$cf_add_libs"
cf_cv_header_path_intl=
cf_cv_library_path_intl=
-echo "${as_me:-configure}:8602: testing Starting FIND_LINKAGE(intl,) ..." 1>&5
+echo "${as_me:-configure}:10409: testing Starting FIND_LINKAGE(intl,) ..." 1>&5
cf_save_LIBS="$LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 8607 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 10414 "configure"
#include "confdefs.h"
#include <libintl.h>
@@ -8625,18 +10432,18 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:8629: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:10436: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:8632: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:8635: \"$ac_try\"") >&5
+ echo "$as_me:10439: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:10442: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:8638: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:10445: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_find_linkage_intl=yes
cf_cv_header_path_intl=/usr/include
@@ -8644,12 +10451,12 @@ if { (eval echo "$as_me:8629: \"$ac_link\"") >&5
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
LIBS="-lintl $cf_save_LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 8652 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 10459 "configure"
#include "confdefs.h"
#include <libintl.h>
@@ -8670,18 +10477,18 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:8674: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:10481: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:8677: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:8680: \"$ac_try\"") >&5
+ echo "$as_me:10484: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:10487: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:8683: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:10490: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_find_linkage_intl=yes
cf_cv_header_path_intl=/usr/include
@@ -8690,16 +10497,16 @@ if { (eval echo "$as_me:8674: \"$ac_link\"") >&5
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_find_linkage_intl=no
LIBS="$cf_save_LIBS"
test -n "$verbose" && echo " find linkage for intl library" 1>&6
-echo "${as_me:-configure}:8700: testing find linkage for intl library ..." 1>&5
+echo "${as_me:-configure}:10507: testing find linkage for intl library ..." 1>&5
-echo "${as_me:-configure}:8702: testing Searching for headers in FIND_LINKAGE(intl,) ..." 1>&5
+echo "${as_me:-configure}:10509: testing Searching for headers in FIND_LINKAGE(intl,) ..." 1>&5
cf_save_CPPFLAGS="$CPPFLAGS"
cf_test_CPPFLAGS="$CPPFLAGS"
@@ -8711,7 +10518,7 @@ cf_header_path_list=""
if test -n "${CFLAGS}${CPPFLAGS}" ; then
for cf_header_path in $CPPFLAGS $CFLAGS
do
- case $cf_header_path in
+ case "$cf_header_path" in
(-I*)
cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
@@ -8719,11 +10526,11 @@ test "x$cf_header_path" != "xNONE" && \
test -d "$cf_header_path" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
- test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
- test -d $cf_header_path/include/intl && cf_search="$cf_search $cf_header_path/include/intl"
- test -d $cf_header_path/include/intl/include && cf_search="$cf_search $cf_header_path/include/intl/include"
- test -d $cf_header_path/intl/include && cf_search="$cf_search $cf_header_path/intl/include"
- test -d $cf_header_path/intl/include/intl && cf_search="$cf_search $cf_header_path/intl/include/intl"
+ test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
+ test -d "$cf_header_path/include/intl" && cf_search="$cf_search $cf_header_path/include/intl"
+ test -d "$cf_header_path/include/intl/include" && cf_search="$cf_search $cf_header_path/include/intl/include"
+ test -d "$cf_header_path/intl/include" && cf_search="$cf_search $cf_header_path/intl/include"
+ test -d "$cf_header_path/intl/include/intl" && cf_search="$cf_search $cf_header_path/intl/include/intl"
}
cf_header_path_list="$cf_header_path_list $cf_search"
@@ -8740,11 +10547,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $prefix"
- test -d $prefix/include && cf_search="$cf_search $prefix/include"
- test -d $prefix/include/intl && cf_search="$cf_search $prefix/include/intl"
- test -d $prefix/include/intl/include && cf_search="$cf_search $prefix/include/intl/include"
- test -d $prefix/intl/include && cf_search="$cf_search $prefix/intl/include"
- test -d $prefix/intl/include/intl && cf_search="$cf_search $prefix/intl/include/intl"
+ test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
+ test -d "$prefix/include/intl" && cf_search="$cf_search $prefix/include/intl"
+ test -d "$prefix/include/intl/include" && cf_search="$cf_search $prefix/include/intl/include"
+ test -d "$prefix/intl/include" && cf_search="$cf_search $prefix/intl/include"
+ test -d "$prefix/intl/include/intl" && cf_search="$cf_search $prefix/intl/include/intl"
}
for cf_subdir_prefix in \
@@ -8758,13 +10565,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
- test -d $cf_subdir_prefix/include/intl && cf_search="$cf_search $cf_subdir_prefix/include/intl"
- test -d $cf_subdir_prefix/include/intl/include && cf_search="$cf_search $cf_subdir_prefix/include/intl/include"
- test -d $cf_subdir_prefix/intl/include && cf_search="$cf_search $cf_subdir_prefix/intl/include"
- test -d $cf_subdir_prefix/intl/include/intl && cf_search="$cf_search $cf_subdir_prefix/intl/include/intl"
+ test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
+ test -d "$cf_subdir_prefix/include/intl" && cf_search="$cf_search $cf_subdir_prefix/include/intl"
+ test -d "$cf_subdir_prefix/include/intl/include" && cf_search="$cf_search $cf_subdir_prefix/include/intl/include"
+ test -d "$cf_subdir_prefix/intl/include" && cf_search="$cf_search $cf_subdir_prefix/intl/include"
+ test -d "$cf_subdir_prefix/intl/include/intl" && cf_search="$cf_search $cf_subdir_prefix/intl/include/intl"
}
done
@@ -8772,33 +10579,33 @@ done
test "$includedir" != NONE && \
test "$includedir" != "/usr/include" && \
test -d "$includedir" && {
- test -d $includedir && cf_search="$cf_search $includedir"
- test -d $includedir/intl && cf_search="$cf_search $includedir/intl"
+ test -d "$includedir" && cf_search="$cf_search $includedir"
+ test -d "$includedir/intl" && cf_search="$cf_search $includedir/intl"
}
test "$oldincludedir" != NONE && \
test "$oldincludedir" != "/usr/include" && \
test -d "$oldincludedir" && {
- test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
- test -d $oldincludedir/intl && cf_search="$cf_search $oldincludedir/intl"
+ test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
+ test -d "$oldincludedir/intl" && cf_search="$cf_search $oldincludedir/intl"
}
cf_search="$cf_search $cf_header_path_list"
for cf_cv_header_path_intl in $cf_search
do
- if test -d $cf_cv_header_path_intl ; then
+ if test -d "$cf_cv_header_path_intl" ; then
test -n "$verbose" && echo " ... testing $cf_cv_header_path_intl" 1>&6
-echo "${as_me:-configure}:8793: testing ... testing $cf_cv_header_path_intl ..." 1>&5
+echo "${as_me:-configure}:10600: testing ... testing $cf_cv_header_path_intl ..." 1>&5
CPPFLAGS="$cf_save_CPPFLAGS"
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_intl"
- cat >conftest.$ac_ext <<_ACEOF
-#line 8801 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 10608 "configure"
#include "confdefs.h"
#include <libintl.h>
@@ -8819,40 +10626,40 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:8823: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:10630: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:8826: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:8829: \"$ac_try\"") >&5
+ echo "$as_me:10633: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:10636: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:8832: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:10639: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
test -n "$verbose" && echo " ... found intl headers in $cf_cv_header_path_intl" 1>&6
-echo "${as_me:-configure}:8837: testing ... found intl headers in $cf_cv_header_path_intl ..." 1>&5
+echo "${as_me:-configure}:10644: testing ... found intl headers in $cf_cv_header_path_intl ..." 1>&5
cf_cv_find_linkage_intl=maybe
cf_test_CPPFLAGS="$CPPFLAGS"
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
CPPFLAGS="$cf_save_CPPFLAGS"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
done
if test "$cf_cv_find_linkage_intl" = maybe ; then
-echo "${as_me:-configure}:8855: testing Searching for intl library in FIND_LINKAGE(intl,) ..." 1>&5
+echo "${as_me:-configure}:10662: testing Searching for intl library in FIND_LINKAGE(intl,) ..." 1>&5
cf_save_LIBS="$LIBS"
cf_save_LDFLAGS="$LDFLAGS"
@@ -8864,7 +10671,7 @@ cf_library_path_list=""
if test -n "${LDFLAGS}${LIBS}" ; then
for cf_library_path in $LDFLAGS $LIBS
do
- case $cf_library_path in
+ case "$cf_library_path" in
(-L*)
cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
@@ -8872,11 +10679,11 @@ test "x$cf_library_path" != "xNONE" && \
test -d "$cf_library_path" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
- test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
- test -d $cf_library_path/lib/intl && cf_search="$cf_search $cf_library_path/lib/intl"
- test -d $cf_library_path/lib/intl/lib && cf_search="$cf_search $cf_library_path/lib/intl/lib"
- test -d $cf_library_path/intl/lib && cf_search="$cf_search $cf_library_path/intl/lib"
- test -d $cf_library_path/intl/lib/intl && cf_search="$cf_search $cf_library_path/intl/lib/intl"
+ test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
+ test -d "$cf_library_path/lib/intl" && cf_search="$cf_search $cf_library_path/lib/intl"
+ test -d "$cf_library_path/lib/intl/lib" && cf_search="$cf_search $cf_library_path/lib/intl/lib"
+ test -d "$cf_library_path/intl/lib" && cf_search="$cf_search $cf_library_path/intl/lib"
+ test -d "$cf_library_path/intl/lib/intl" && cf_search="$cf_search $cf_library_path/intl/lib/intl"
}
cf_library_path_list="$cf_library_path_list $cf_search"
@@ -8891,11 +10698,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
- test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
- test -d $prefix/lib/intl && cf_search="$cf_search $prefix/lib/intl"
- test -d $prefix/lib/intl/lib && cf_search="$cf_search $prefix/lib/intl/lib"
- test -d $prefix/intl/lib && cf_search="$cf_search $prefix/intl/lib"
- test -d $prefix/intl/lib/intl && cf_search="$cf_search $prefix/intl/lib/intl"
+ test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
+ test -d "$prefix/lib/intl" && cf_search="$cf_search $prefix/lib/intl"
+ test -d "$prefix/lib/intl/lib" && cf_search="$cf_search $prefix/lib/intl/lib"
+ test -d "$prefix/intl/lib" && cf_search="$cf_search $prefix/intl/lib"
+ test -d "$prefix/intl/lib/intl" && cf_search="$cf_search $prefix/intl/lib/intl"
}
for cf_subdir_prefix in \
@@ -8909,13 +10716,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
- test -d $cf_subdir_prefix/lib/intl && cf_search="$cf_search $cf_subdir_prefix/lib/intl"
- test -d $cf_subdir_prefix/lib/intl/lib && cf_search="$cf_search $cf_subdir_prefix/lib/intl/lib"
- test -d $cf_subdir_prefix/intl/lib && cf_search="$cf_search $cf_subdir_prefix/intl/lib"
- test -d $cf_subdir_prefix/intl/lib/intl && cf_search="$cf_search $cf_subdir_prefix/intl/lib/intl"
+ test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
+ test -d "$cf_subdir_prefix/lib/intl" && cf_search="$cf_search $cf_subdir_prefix/lib/intl"
+ test -d "$cf_subdir_prefix/lib/intl/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/intl/lib"
+ test -d "$cf_subdir_prefix/intl/lib" && cf_search="$cf_search $cf_subdir_prefix/intl/lib"
+ test -d "$cf_subdir_prefix/intl/lib/intl" && cf_search="$cf_search $cf_subdir_prefix/intl/lib/intl"
}
done
@@ -8924,16 +10731,16 @@ cf_search="$cf_library_path_list $cf_search"
for cf_cv_library_path_intl in $cf_search
do
- if test -d $cf_cv_library_path_intl ; then
+ if test -d "$cf_cv_library_path_intl" ; then
test -n "$verbose" && echo " ... testing $cf_cv_library_path_intl" 1>&6
-echo "${as_me:-configure}:8930: testing ... testing $cf_cv_library_path_intl ..." 1>&5
+echo "${as_me:-configure}:10737: testing ... testing $cf_cv_library_path_intl ..." 1>&5
CPPFLAGS="$cf_test_CPPFLAGS"
LIBS="-lintl $cf_save_LIBS"
LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_intl"
- cat >conftest.$ac_ext <<_ACEOF
-#line 8936 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 10743 "configure"
#include "confdefs.h"
#include <libintl.h>
@@ -8954,36 +10761,36 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:8958: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:10765: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:8961: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:8964: \"$ac_try\"") >&5
+ echo "$as_me:10768: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:10771: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:8967: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:10774: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
test -n "$verbose" && echo " ... found intl library in $cf_cv_library_path_intl" 1>&6
-echo "${as_me:-configure}:8972: testing ... found intl library in $cf_cv_library_path_intl ..." 1>&5
+echo "${as_me:-configure}:10779: testing ... found intl library in $cf_cv_library_path_intl ..." 1>&5
cf_cv_find_linkage_intl=yes
cf_cv_library_file_intl="-lintl"
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
CPPFLAGS="$cf_save_CPPFLAGS"
LIBS="$cf_save_LIBS"
LDFLAGS="$cf_save_LDFLAGS"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
done
CPPFLAGS="$cf_save_CPPFLAGS"
@@ -8995,10 +10802,10 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS="$cf_save_LIBS"
@@ -9008,9 +10815,9 @@ else
cf_cv_func_gettext=no
fi
- echo "$as_me:9011: checking for libintl.h and gettext()" >&5
+ echo "$as_me:10818: checking for libintl.h and gettext()" >&5
echo $ECHO_N "checking for libintl.h and gettext()... $ECHO_C" >&6
- echo "$as_me:9013: result: $cf_cv_func_gettext" >&5
+ echo "$as_me:10820: result: $cf_cv_func_gettext" >&5
echo "${ECHO_T}$cf_cv_func_gettext" >&6
LIBS="$cf_save_LIBS_1"
@@ -9031,9 +10838,9 @@ EOF
if test -n "$cf_cv_header_path_intl" ; then
for cf_add_incdir in $cf_cv_header_path_intl
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -9054,8 +10861,8 @@ if test -n "$cf_cv_header_path_intl" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 9058 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 10865 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -9066,25 +10873,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:9070: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:10877: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:9073: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:9076: \"$ac_try\"") >&5
+ echo "$as_me:10880: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:10883: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:9079: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:10886: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -9093,11 +10900,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:9096: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:10903: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -9116,9 +10923,9 @@ fi
if test -n "$cf_cv_library_path_intl" ; then
for cf_add_libdir in $cf_cv_library_path_intl
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -9132,7 +10939,7 @@ if test -n "$cf_cv_library_path_intl" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:9135: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:10942: testing adding $cf_add_libdir to library-path ..." 1>&5
INTLLIBS="-L$cf_add_libdir $INTLLIBS"
fi
@@ -9148,65 +10955,65 @@ fi
for ac_func in dcgettext
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:9151: checking for $ac_func" >&5
+echo "$as_me:10958: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 9157 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 10964 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define $ac_func autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef $ac_func
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char $ac_func ();
-char (*f) ();
+char $ac_func (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for $ac_func
#endif
+ return $ac_func ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:9188: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:10995: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:9191: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:9194: \"$ac_try\"") >&5
+ echo "$as_me:10998: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:11001: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:9197: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:11004: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_var=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_var=no"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:9207: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
+echo "$as_me:11014: result: `eval echo '${'"$as_ac_var"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
+if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF
@@ -9219,7 +11026,7 @@ done
CATOBJEXT=.gmo
fi
elif test -z "$MSGFMT" || test -z "$XGETTEXT" ; then
- { echo "$as_me:9222: WARNING: disabling NLS feature" >&5
+ { echo "$as_me:11029: WARNING: disabling NLS feature" >&5
echo "$as_me: WARNING: disabling NLS feature" >&2;}
sed -e /ENABLE_NLS/d confdefs.h >confdefs.tmp
mv confdefs.tmp confdefs.h
@@ -9242,7 +11049,7 @@ echo "$as_me: WARNING: disabling NLS feature" >&2;}
if test "$nls_cv_use_gnu_gettext" != "no"; then
CATOBJEXT=.gmo
- if test -f $srcdir/intl/libintl.h ; then
+ if test -f "$srcdir/intl/libintl.h" ; then
INTLOBJS="\$(GETTOBJS)"
BUILD_INCLUDED_LIBINTL=yes
USE_INCLUDED_LIBINTL=yes
@@ -9250,7 +11057,7 @@ echo "$as_me: WARNING: disabling NLS feature" >&2;}
LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
elif test "$nls_cv_use_gnu_gettext" = "yes"; then
nls_cv_use_gnu_gettext=no
- { echo "$as_me:9253: WARNING: no NLS library is packaged with this application" >&5
+ { echo "$as_me:11060: WARNING: no NLS library is packaged with this application" >&5
echo "$as_me: WARNING: no NLS library is packaged with this application" >&2;}
fi
fi
@@ -9259,7 +11066,7 @@ echo "$as_me: WARNING: no NLS library is packaged with this application" >&2;}
if $GMSGFMT --statistics /dev/null >/dev/null 2>&1; then
: ;
else
- { echo "$as_me:9262: WARNING: found msgfmt program is not GNU msgfmt" >&5
+ { echo "$as_me:11069: WARNING: found msgfmt program is not GNU msgfmt" >&5
echo "$as_me: WARNING: found msgfmt program is not GNU msgfmt" >&2;}
fi
fi
@@ -9268,7 +11075,7 @@ echo "$as_me: WARNING: found msgfmt program is not GNU msgfmt" >&2;}
if $XGETTEXT --omit-header /dev/null >/dev/null 2>&1; then
: ;
else
- { echo "$as_me:9271: WARNING: found xgettext program is not GNU xgettext" >&5
+ { echo "$as_me:11078: WARNING: found xgettext program is not GNU xgettext" >&5
echo "$as_me: WARNING: found xgettext program is not GNU xgettext" >&2;}
fi
fi
@@ -9286,7 +11093,7 @@ echo "$as_me: WARNING: found xgettext program is not GNU xgettext" >&2;}
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:9289: checking for $ac_word" >&5
+echo "$as_me:11096: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_INTLBISON+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -9301,7 +11108,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_INTLBISON="$ac_prog"
-echo "$as_me:9304: found $ac_dir/$ac_word" >&5
+echo "$as_me:11111: found $ac_dir/$ac_word" >&5
break
done
@@ -9309,10 +11116,10 @@ fi
fi
INTLBISON=$ac_cv_prog_INTLBISON
if test -n "$INTLBISON"; then
- echo "$as_me:9312: result: $INTLBISON" >&5
+ echo "$as_me:11119: result: $INTLBISON" >&5
echo "${ECHO_T}$INTLBISON" >&6
else
- echo "$as_me:9315: result: no" >&5
+ echo "$as_me:11122: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -9322,19 +11129,19 @@ done
if test -z "$INTLBISON"; then
ac_verc_fail=yes
else
- echo "$as_me:9325: checking version of bison" >&5
+ echo "$as_me:11132: checking version of bison" >&5
echo $ECHO_N "checking version of bison... $ECHO_C" >&6
ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
- case $ac_prog_version in
+ case "$ac_prog_version" in
('') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
(1.2[6-9]*|1.[3-9][0-9]*|[2-9].*)
ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
(*) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
esac
- echo "$as_me:9334: result: $ac_prog_version" >&5
+ echo "$as_me:11141: result: $ac_prog_version" >&5
echo "${ECHO_T}$ac_prog_version" >&6
fi
- if test $ac_verc_fail = yes; then
+ if test "$ac_verc_fail" = yes; then
INTLBISON=:
fi
fi
@@ -9358,7 +11165,7 @@ echo "${ECHO_T}$ac_prog_version" >&6
if test "x$ALL_LINGUAS" = "x"; then
LINGUAS=
else
- echo "$as_me:9361: checking for catalogs to be installed" >&5
+ echo "$as_me:11168: checking for catalogs to be installed" >&5
echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6
NEW_LINGUAS=
for presentlang in $ALL_LINGUAS; do
@@ -9373,12 +11180,12 @@ echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6
("$presentlang"*) useit=yes;;
esac
done
- if test $useit = yes; then
+ if test "$useit" = yes; then
NEW_LINGUAS="$NEW_LINGUAS $presentlang"
fi
done
LINGUAS=$NEW_LINGUAS
- echo "$as_me:9381: result: $LINGUAS" >&5
+ echo "$as_me:11188: result: $LINGUAS" >&5
echo "${ECHO_T}$LINGUAS" >&6
fi
@@ -9413,8 +11220,8 @@ cf_makefile=makefile
use_our_messages=no
if test "$USE_NLS" = yes ; then
-if test -d $srcdir/po ; then
-echo "$as_me:9417: checking if we should use included message-library" >&5
+if test -d "$srcdir/po" ; then
+echo "$as_me:11224: checking if we should use included message-library" >&5
echo $ECHO_N "checking if we should use included message-library... $ECHO_C" >&6
# Check whether --enable-included-msgs or --disable-included-msgs was given.
@@ -9425,7 +11232,7 @@ else
use_our_messages=yes
fi;
fi
-echo "$as_me:9428: result: $use_our_messages" >&5
+echo "$as_me:11235: result: $use_our_messages" >&5
echo "${ECHO_T}$use_our_messages" >&6
fi
@@ -9467,24 +11274,24 @@ else
for ac_header in libintl.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:9470: checking for $ac_header" >&5
+echo "$as_me:11277: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 9476 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 11283 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:9480: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:11287: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:9486: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:11293: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -9497,14 +11304,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:9505: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:11312: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -9553,14 +11360,14 @@ EOF
fi
fi
-echo "$as_me:9556: checking if -lm needed for math functions" >&5
+echo "$as_me:11363: checking if -lm needed for math functions" >&5
echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
if test "${cf_cv_need_libm+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 9563 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 11370 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -9570,55 +11377,55 @@ else
int
main (void)
{
-double x = rand(); printf("result = %g\n", sqrt(x))
+double x = rand(); printf("result = %g\\n", sqrt(x))
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:9579: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:11386: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:9582: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:9585: \"$ac_try\"") >&5
+ echo "$as_me:11389: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:11392: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:9588: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:11395: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_need_libm=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_need_libm=yes
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:9598: result: $cf_cv_need_libm" >&5
+echo "$as_me:11405: result: $cf_cv_need_libm" >&5
echo "${ECHO_T}$cf_cv_need_libm" >&6
if test "$cf_cv_need_libm" = yes
then
-cf_add_libs="-lm"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lm; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
fi
-echo "$as_me:9621: checking if you want to use dmalloc for testing" >&5
+echo "$as_me:11428: checking if you want to use dmalloc for testing" >&5
echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
# Check whether --with-dmalloc or --without-dmalloc was given.
@@ -9629,16 +11436,16 @@ cat >>confdefs.h <<EOF
#define USE_DMALLOC 1
EOF
- : ${with_cflags:=-g}
- : ${with_no_leaks:=yes}
+ : "${with_cflags:=-g}"
+ : "${enable_leaks:=no}"
with_dmalloc=yes
else
with_dmalloc=
fi;
-echo "$as_me:9638: result: ${with_dmalloc:-no}" >&5
+echo "$as_me:11445: result: ${with_dmalloc:-no}" >&5
echo "${ECHO_T}${with_dmalloc:-no}" >&6
-case .$with_cflags in
+case ".$with_cflags" in
(.*-g*)
case .$CFLAGS in
(.*-g*)
@@ -9652,19 +11459,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in -g
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -9683,7 +11490,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -9713,7 +11520,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -9749,24 +11556,24 @@ fi
esac
if test "$with_dmalloc" = yes ; then
- echo "$as_me:9752: checking for dmalloc.h" >&5
+ echo "$as_me:11559: checking for dmalloc.h" >&5
echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
if test "${ac_cv_header_dmalloc_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 9758 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 11565 "configure"
#include "confdefs.h"
#include <dmalloc.h>
_ACEOF
-if { (eval echo "$as_me:9762: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:11569: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:9768: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:11575: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -9779,24 +11586,24 @@ if test -z "$ac_cpp_err"; then
ac_cv_header_dmalloc_h=yes
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
ac_cv_header_dmalloc_h=no
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:9787: result: $ac_cv_header_dmalloc_h" >&5
+echo "$as_me:11594: result: $ac_cv_header_dmalloc_h" >&5
echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
-if test $ac_cv_header_dmalloc_h = yes; then
+if test "$ac_cv_header_dmalloc_h" = yes; then
-echo "$as_me:9791: checking for dmalloc_debug in -ldmalloc" >&5
+echo "$as_me:11598: checking for dmalloc_debug in -ldmalloc" >&5
echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldmalloc $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 9799 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 11606 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -9814,30 +11621,30 @@ dmalloc_debug ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:9818: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:11625: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:9821: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:9824: \"$ac_try\"") >&5
+ echo "$as_me:11628: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:11631: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:9827: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:11634: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_dmalloc_dmalloc_debug=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_dmalloc_dmalloc_debug=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:9838: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
+echo "$as_me:11645: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
-if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
+if test "$ac_cv_lib_dmalloc_dmalloc_debug" = yes; then
cat >>confdefs.h <<EOF
#define HAVE_LIBDMALLOC 1
EOF
@@ -9850,7 +11657,7 @@ fi
fi
-echo "$as_me:9853: checking if you want to use dbmalloc for testing" >&5
+echo "$as_me:11660: checking if you want to use dbmalloc for testing" >&5
echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
# Check whether --with-dbmalloc or --without-dbmalloc was given.
@@ -9861,16 +11668,16 @@ cat >>confdefs.h <<EOF
#define USE_DBMALLOC 1
EOF
- : ${with_cflags:=-g}
- : ${with_no_leaks:=yes}
+ : "${with_cflags:=-g}"
+ : "${enable_leaks:=no}"
with_dbmalloc=yes
else
with_dbmalloc=
fi;
-echo "$as_me:9870: result: ${with_dbmalloc:-no}" >&5
+echo "$as_me:11677: result: ${with_dbmalloc:-no}" >&5
echo "${ECHO_T}${with_dbmalloc:-no}" >&6
-case .$with_cflags in
+case ".$with_cflags" in
(.*-g*)
case .$CFLAGS in
(.*-g*)
@@ -9884,19 +11691,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in -g
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -9915,7 +11722,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -9945,7 +11752,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -9981,24 +11788,24 @@ fi
esac
if test "$with_dbmalloc" = yes ; then
- echo "$as_me:9984: checking for dbmalloc.h" >&5
+ echo "$as_me:11791: checking for dbmalloc.h" >&5
echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
if test "${ac_cv_header_dbmalloc_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 9990 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 11797 "configure"
#include "confdefs.h"
#include <dbmalloc.h>
_ACEOF
-if { (eval echo "$as_me:9994: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:11801: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:10000: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:11807: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -10011,24 +11818,24 @@ if test -z "$ac_cpp_err"; then
ac_cv_header_dbmalloc_h=yes
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
ac_cv_header_dbmalloc_h=no
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:10019: result: $ac_cv_header_dbmalloc_h" >&5
+echo "$as_me:11826: result: $ac_cv_header_dbmalloc_h" >&5
echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
-if test $ac_cv_header_dbmalloc_h = yes; then
+if test "$ac_cv_header_dbmalloc_h" = yes; then
-echo "$as_me:10023: checking for debug_malloc in -ldbmalloc" >&5
+echo "$as_me:11830: checking for debug_malloc in -ldbmalloc" >&5
echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldbmalloc $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 10031 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 11838 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -10046,30 +11853,30 @@ debug_malloc ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:10050: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:11857: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:10053: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:10056: \"$ac_try\"") >&5
+ echo "$as_me:11860: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:11863: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:10059: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:11866: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_dbmalloc_debug_malloc=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_dbmalloc_debug_malloc=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:10070: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
+echo "$as_me:11877: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
-if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
+if test "$ac_cv_lib_dbmalloc_debug_malloc" = yes; then
cat >>confdefs.h <<EOF
#define HAVE_LIBDBMALLOC 1
EOF
@@ -10082,7 +11889,7 @@ fi
fi
-echo "$as_me:10085: checking if you want to use purify for testing" >&5
+echo "$as_me:11892: checking if you want to use purify for testing" >&5
echo $ECHO_N "checking if you want to use purify for testing... $ECHO_C" >&6
# Check whether --with-purify or --without-purify was given.
@@ -10093,16 +11900,16 @@ cat >>confdefs.h <<EOF
#define USE_PURIFY 1
EOF
- : ${with_cflags:=-g}
- : ${with_no_leaks:=yes}
+ : "${with_cflags:=-g}"
+ : "${enable_leaks:=no}"
with_purify=yes
else
with_purify=
fi;
-echo "$as_me:10102: result: ${with_purify:-no}" >&5
+echo "$as_me:11909: result: ${with_purify:-no}" >&5
echo "${ECHO_T}${with_purify:-no}" >&6
-case .$with_cflags in
+case ".$with_cflags" in
(.*-g*)
case .$CFLAGS in
(.*-g*)
@@ -10116,19 +11923,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in -g
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -10147,7 +11954,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -10177,7 +11984,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -10212,7 +12019,7 @@ fi
;;
esac
-echo "$as_me:10215: checking if you want to use valgrind for testing" >&5
+echo "$as_me:12022: checking if you want to use valgrind for testing" >&5
echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
# Check whether --with-valgrind or --without-valgrind was given.
@@ -10223,16 +12030,16 @@ cat >>confdefs.h <<EOF
#define USE_VALGRIND 1
EOF
- : ${with_cflags:=-g}
- : ${with_no_leaks:=yes}
+ : "${with_cflags:=-g}"
+ : "${enable_leaks:=no}"
with_valgrind=yes
else
with_valgrind=
fi;
-echo "$as_me:10232: result: ${with_valgrind:-no}" >&5
+echo "$as_me:12039: result: ${with_valgrind:-no}" >&5
echo "${ECHO_T}${with_valgrind:-no}" >&6
-case .$with_cflags in
+case ".$with_cflags" in
(.*-g*)
case .$CFLAGS in
(.*-g*)
@@ -10246,19 +12053,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in -g
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -10277,7 +12084,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -10307,7 +12114,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -10342,7 +12149,7 @@ fi
;;
esac
-echo "$as_me:10345: checking if you want to perform memory-leak testing" >&5
+echo "$as_me:12152: checking if you want to perform memory-leak testing" >&5
echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
# Check whether --with-no-leaks or --without-no-leaks was given.
@@ -10362,14 +12169,15 @@ cat >>confdefs.h <<\EOF
EOF
;;
esac
- with_no_leaks=yes
+ enable_leaks=no
else
- with_no_leaks=
+ enable_leaks=yes
fi;
-echo "$as_me:10369: result: $with_no_leaks" >&5
+if test "x$enable_leaks" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
+echo "$as_me:12177: result: $with_no_leaks" >&5
echo "${ECHO_T}$with_no_leaks" >&6
-echo "$as_me:10372: checking if you want --trace option" >&5
+echo "$as_me:12180: checking if you want --trace option" >&5
echo $ECHO_N "checking if you want --trace option... $ECHO_C" >&6
# Check whether --enable-trace or --disable-trace was given.
@@ -10379,7 +12187,7 @@ if test "${enable_trace+set}" = set; then
else
enableval=yes
fi;
-echo "$as_me:10382: result: $enableval" >&5
+echo "$as_me:12190: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS trace\$o"
@@ -10392,65 +12200,80 @@ else
:
fi
+echo "$as_me:12203: checking if rpath option should be used" >&5
+echo $ECHO_N "checking if rpath option should be used... $ECHO_C" >&6
+
+# Check whether --enable-rpath or --disable-rpath was given.
+if test "${enable_rpath+set}" = set; then
+ enableval="$enable_rpath"
+ cf_cv_enable_rpath=$enableval
+else
+ cf_cv_enable_rpath=no
+fi;
+echo "$as_me:12213: result: $cf_cv_enable_rpath" >&5
+echo "${ECHO_T}$cf_cv_enable_rpath" >&6
+
LD_RPATH_OPT=
-echo "$as_me:10396: checking for an rpath option" >&5
+if test "x$cf_cv_enable_rpath" != xno
+then
+ echo "$as_me:12219: checking for an rpath option" >&5
echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
-case $cf_cv_system_name in
-(irix*)
- if test "$GCC" = yes; then
+ case "$cf_cv_system_name" in
+ (irix*)
+ if test "$GCC" = yes; then
+ LD_RPATH_OPT="-Wl,-rpath,"
+ else
+ LD_RPATH_OPT="-rpath "
+ fi
+ ;;
+ (linux*|gnu*|k*bsd*-gnu|freebsd*)
LD_RPATH_OPT="-Wl,-rpath,"
- else
+ ;;
+ (openbsd[2-9].*|mirbsd*)
+ LD_RPATH_OPT="-Wl,-rpath,"
+ ;;
+ (dragonfly*)
LD_RPATH_OPT="-rpath "
- fi
- ;;
-(linux*|gnu*|k*bsd*-gnu|freebsd*)
- LD_RPATH_OPT="-Wl,-rpath,"
- ;;
-(openbsd[2-9].*|mirbsd*)
- LD_RPATH_OPT="-Wl,-rpath,"
- ;;
-(dragonfly*)
- LD_RPATH_OPT="-rpath "
- ;;
-(netbsd*)
- LD_RPATH_OPT="-Wl,-rpath,"
- ;;
-(osf*|mls+*)
- LD_RPATH_OPT="-rpath "
- ;;
-(solaris2*)
- LD_RPATH_OPT="-R"
- ;;
-(*)
- ;;
-esac
-echo "$as_me:10427: result: $LD_RPATH_OPT" >&5
+ ;;
+ (netbsd*)
+ LD_RPATH_OPT="-Wl,-rpath,"
+ ;;
+ (osf*|mls+*)
+ LD_RPATH_OPT="-rpath "
+ ;;
+ (solaris2*)
+ LD_RPATH_OPT="-R"
+ ;;
+ (*)
+ ;;
+ esac
+ echo "$as_me:12250: result: $LD_RPATH_OPT" >&5
echo "${ECHO_T}$LD_RPATH_OPT" >&6
-case "x$LD_RPATH_OPT" in
-(x-R*)
- echo "$as_me:10432: checking if we need a space after rpath option" >&5
+ case "x$LD_RPATH_OPT" in
+ (x-R*)
+ echo "$as_me:12255: checking if we need a space after rpath option" >&5
echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
- cf_save_LIBS="$LIBS"
+ cf_save_LIBS="$LIBS"
-cf_add_libs="${LD_RPATH_OPT}$libdir"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in ${LD_RPATH_OPT}$libdir; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
- cat >conftest.$ac_ext <<_ACEOF
-#line 10453 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 12276 "configure"
#include "confdefs.h"
int
@@ -10461,31 +12284,32 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:10465: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:12288: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:10468: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:10471: \"$ac_try\"") >&5
+ echo "$as_me:12291: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:12294: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:10474: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:12297: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_rpath_space=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_rpath_space=yes
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- LIBS="$cf_save_LIBS"
- echo "$as_me:10484: result: $cf_rpath_space" >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ LIBS="$cf_save_LIBS"
+ echo "$as_me:12307: result: $cf_rpath_space" >&5
echo "${ECHO_T}$cf_rpath_space" >&6
- test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
- ;;
-esac
+ test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
+ ;;
+ esac
+fi
REL_VERSION=${VERSION_MAJOR}.${VERSION_MINOR}
ABI_VERSION=`echo "$VERSION" |sed -e 's/:/./g'`
@@ -10496,7 +12320,7 @@ test -z "$cf_cv_rel_version" && cf_cv_rel_version=0.0
# Check whether --with-rel-version or --without-rel-version was given.
if test "${with_rel_version+set}" = set; then
withval="$with_rel_version"
- { echo "$as_me:10499: WARNING: overriding release version $cf_cv_rel_version to $withval" >&5
+ { echo "$as_me:12323: WARNING: overriding release version $cf_cv_rel_version to $withval" >&5
echo "$as_me: WARNING: overriding release version $cf_cv_rel_version to $withval" >&2;}
cf_cv_rel_version=$withval
fi;
@@ -10509,13 +12333,13 @@ if test -n "$DIALOG_MAJOR" ; then
([0-9]*)
;;
(*)
- { { echo "$as_me:10512: error: Release major-version is not a number: $DIALOG_MAJOR" >&5
+ { { echo "$as_me:12336: error: Release major-version is not a number: $DIALOG_MAJOR" >&5
echo "$as_me: error: Release major-version is not a number: $DIALOG_MAJOR" >&2;}
{ (exit 1); exit 1; }; }
;;
esac
else
- { { echo "$as_me:10518: error: Release major-version value is empty" >&5
+ { { echo "$as_me:12342: error: Release major-version value is empty" >&5
echo "$as_me: error: Release major-version value is empty" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -10525,13 +12349,13 @@ if test -n "$DIALOG_MINOR" ; then
([0-9]*)
;;
(*)
- { { echo "$as_me:10528: error: Release minor-version is not a number: $DIALOG_MINOR" >&5
+ { { echo "$as_me:12352: error: Release minor-version is not a number: $DIALOG_MINOR" >&5
echo "$as_me: error: Release minor-version is not a number: $DIALOG_MINOR" >&2;}
{ (exit 1); exit 1; }; }
;;
esac
else
- { { echo "$as_me:10534: error: Release minor-version value is empty" >&5
+ { { echo "$as_me:12358: error: Release minor-version value is empty" >&5
echo "$as_me: error: Release minor-version value is empty" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -10544,9 +12368,9 @@ if test "${with_abi_version+set}" = set; then
if test "x$cf_cv_abi_version" != "x$withval"
then
- { echo "$as_me:10547: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&5
+ { echo "$as_me:12371: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&5
echo "$as_me: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&2;}
- case $cf_cv_rel_version in
+ case "$cf_cv_rel_version" in
(5.*)
cf_cv_rel_version=$withval.0
;;
@@ -10563,13 +12387,13 @@ if test -n "$cf_cv_abi_version" ; then
([0-9]*)
;;
(*)
- { { echo "$as_me:10566: error: ABI version is not a number: $cf_cv_abi_version" >&5
+ { { echo "$as_me:12390: error: ABI version is not a number: $cf_cv_abi_version" >&5
echo "$as_me: error: ABI version is not a number: $cf_cv_abi_version" >&2;}
{ (exit 1); exit 1; }; }
;;
esac
else
- { { echo "$as_me:10572: error: ABI version value is empty" >&5
+ { { echo "$as_me:12396: error: ABI version value is empty" >&5
echo "$as_me: error: ABI version value is empty" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -10586,7 +12410,7 @@ MAKE_DLLS="#"
shlibdir=$libdir
-echo "$as_me:10589: checking if libtool -version-number should be used" >&5
+echo "$as_me:12413: checking if libtool -version-number should be used" >&5
echo $ECHO_N "checking if libtool -version-number should be used... $ECHO_C" >&6
# Check whether --enable-libtool-version or --disable-libtool-version was given.
@@ -10603,7 +12427,7 @@ else
cf_libtool_version=yes
fi;
-echo "$as_me:10606: result: $cf_libtool_version" >&5
+echo "$as_me:12430: result: $cf_libtool_version" >&5
echo "${ECHO_T}$cf_libtool_version" >&6
if test "$cf_libtool_version" = yes ; then
@@ -10612,25 +12436,25 @@ else
LIBTOOL_VERSION="-version-info"
case "x$VERSION" in
(x)
- { echo "$as_me:10615: WARNING: VERSION was not set" >&5
+ { echo "$as_me:12439: WARNING: VERSION was not set" >&5
echo "$as_me: WARNING: VERSION was not set" >&2;}
;;
(x*.*.*)
ABI_VERSION="$VERSION"
test -n "$verbose" && echo " ABI_VERSION: $ABI_VERSION" 1>&6
-echo "${as_me:-configure}:10622: testing ABI_VERSION: $ABI_VERSION ..." 1>&5
+echo "${as_me:-configure}:12446: testing ABI_VERSION: $ABI_VERSION ..." 1>&5
;;
(x*:*:*)
ABI_VERSION=`echo "$VERSION" | sed -e 's/:/./g'`
test -n "$verbose" && echo " ABI_VERSION: $ABI_VERSION" 1>&6
-echo "${as_me:-configure}:10629: testing ABI_VERSION: $ABI_VERSION ..." 1>&5
+echo "${as_me:-configure}:12453: testing ABI_VERSION: $ABI_VERSION ..." 1>&5
;;
(*)
- { echo "$as_me:10633: WARNING: unexpected VERSION value: $VERSION" >&5
+ { echo "$as_me:12457: WARNING: unexpected VERSION value: $VERSION" >&5
echo "$as_me: WARNING: unexpected VERSION value: $VERSION" >&2;}
;;
esac
@@ -10652,7 +12476,7 @@ LIB_LINK='${CC}'
LIB_INSTALL=
LIB_UNINSTALL=
-echo "$as_me:10655: checking if you want to build libraries with libtool" >&5
+echo "$as_me:12479: checking if you want to build libraries with libtool" >&5
echo $ECHO_N "checking if you want to build libraries with libtool... $ECHO_C" >&6
# Check whether --with-libtool or --without-libtool was given.
@@ -10662,7 +12486,7 @@ if test "${with_libtool+set}" = set; then
else
with_libtool=no
fi;
-echo "$as_me:10665: result: $with_libtool" >&5
+echo "$as_me:12489: result: $with_libtool" >&5
echo "${ECHO_T}$with_libtool" >&6
if test "$with_libtool" != "no"; then
@@ -10681,19 +12505,19 @@ case ".$with_libtool" in
;;
(.[a-zA-Z]:[\\/]*) # OS/2 EMX
;;
-(.\${*prefix}*|.\${*dir}*)
+(.\$\{*prefix\}*|.\$\{*dir\}*)
eval with_libtool="$with_libtool"
case ".$with_libtool" in
(.NONE/*)
- with_libtool=`echo $with_libtool | sed -e s%NONE%$cf_path_syntax%`
+ with_libtool=`echo "$with_libtool" | sed -e s%NONE%$cf_path_syntax%`
;;
esac
;;
(.no|.NONE/*)
- with_libtool=`echo $with_libtool | sed -e s%NONE%$cf_path_syntax%`
+ with_libtool=`echo "$with_libtool" | sed -e s%NONE%$cf_path_syntax%`
;;
(*)
- { { echo "$as_me:10696: error: expected a pathname, not \"$with_libtool\"" >&5
+ { { echo "$as_me:12520: error: expected a pathname, not \"$with_libtool\"" >&5
echo "$as_me: error: expected a pathname, not \"$with_libtool\"" >&2;}
{ (exit 1); exit 1; }; }
;;
@@ -10706,7 +12530,7 @@ esac
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:10709: checking for $ac_word" >&5
+echo "$as_me:12533: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_LIBTOOL+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -10721,7 +12545,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_LIBTOOL="$ac_tool_prefix$ac_prog"
-echo "$as_me:10724: found $ac_dir/$ac_word" >&5
+echo "$as_me:12548: found $ac_dir/$ac_word" >&5
break
done
@@ -10729,10 +12553,10 @@ fi
fi
LIBTOOL=$ac_cv_prog_LIBTOOL
if test -n "$LIBTOOL"; then
- echo "$as_me:10732: result: $LIBTOOL" >&5
+ echo "$as_me:12556: result: $LIBTOOL" >&5
echo "${ECHO_T}$LIBTOOL" >&6
else
- echo "$as_me:10735: result: no" >&5
+ echo "$as_me:12559: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -10745,7 +12569,7 @@ if test -z "$LIBTOOL"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:10748: checking for $ac_word" >&5
+echo "$as_me:12572: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_LIBTOOL+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -10760,7 +12584,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_LIBTOOL="$ac_prog"
-echo "$as_me:10763: found $ac_dir/$ac_word" >&5
+echo "$as_me:12587: found $ac_dir/$ac_word" >&5
break
done
@@ -10768,10 +12592,10 @@ fi
fi
ac_ct_LIBTOOL=$ac_cv_prog_ac_ct_LIBTOOL
if test -n "$ac_ct_LIBTOOL"; then
- echo "$as_me:10771: result: $ac_ct_LIBTOOL" >&5
+ echo "$as_me:12595: result: $ac_ct_LIBTOOL" >&5
echo "${ECHO_T}$ac_ct_LIBTOOL" >&6
else
- echo "$as_me:10774: result: no" >&5
+ echo "$as_me:12598: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -10802,7 +12626,7 @@ unset LIBTOOL
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:10805: checking for $ac_word" >&5
+echo "$as_me:12629: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_LIBTOOL+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -10817,7 +12641,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_LIBTOOL="$ac_tool_prefix$ac_prog"
-echo "$as_me:10820: found $ac_dir/$ac_word" >&5
+echo "$as_me:12644: found $ac_dir/$ac_word" >&5
break
done
@@ -10825,10 +12649,10 @@ fi
fi
LIBTOOL=$ac_cv_prog_LIBTOOL
if test -n "$LIBTOOL"; then
- echo "$as_me:10828: result: $LIBTOOL" >&5
+ echo "$as_me:12652: result: $LIBTOOL" >&5
echo "${ECHO_T}$LIBTOOL" >&6
else
- echo "$as_me:10831: result: no" >&5
+ echo "$as_me:12655: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -10841,7 +12665,7 @@ if test -z "$LIBTOOL"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:10844: checking for $ac_word" >&5
+echo "$as_me:12668: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_LIBTOOL+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -10856,7 +12680,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_LIBTOOL="$ac_prog"
-echo "$as_me:10859: found $ac_dir/$ac_word" >&5
+echo "$as_me:12683: found $ac_dir/$ac_word" >&5
break
done
@@ -10864,10 +12688,10 @@ fi
fi
ac_ct_LIBTOOL=$ac_cv_prog_ac_ct_LIBTOOL
if test -n "$ac_ct_LIBTOOL"; then
- echo "$as_me:10867: result: $ac_ct_LIBTOOL" >&5
+ echo "$as_me:12691: result: $ac_ct_LIBTOOL" >&5
echo "${ECHO_T}$ac_ct_LIBTOOL" >&6
else
- echo "$as_me:10870: result: no" >&5
+ echo "$as_me:12694: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -10889,7 +12713,7 @@ test -z "$cf_cv_libtool_version" && unset cf_cv_libtool_version
fi
fi
if test -z "$LIBTOOL" ; then
- { { echo "$as_me:10892: error: Cannot find libtool" >&5
+ { { echo "$as_me:12716: error: Cannot find libtool" >&5
echo "$as_me: error: Cannot find libtool" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -10905,7 +12729,7 @@ echo "$as_me: error: Cannot find libtool" >&2;}
if test -n "$LIBTOOL" && test "$LIBTOOL" != none
then
- echo "$as_me:10908: checking version of $LIBTOOL" >&5
+ echo "$as_me:12732: checking version of $LIBTOOL" >&5
echo $ECHO_N "checking version of $LIBTOOL... $ECHO_C" >&6
if test -n "$LIBTOOL" && test "$LIBTOOL" != none
@@ -10916,15 +12740,15 @@ else
fi
test -z "$cf_cv_libtool_version" && unset cf_cv_libtool_version
- echo "$as_me:10919: result: $cf_cv_libtool_version" >&5
+ echo "$as_me:12743: result: $cf_cv_libtool_version" >&5
echo "${ECHO_T}$cf_cv_libtool_version" >&6
if test -z "$cf_cv_libtool_version" ; then
- { { echo "$as_me:10922: error: This is not GNU libtool" >&5
+ { { echo "$as_me:12746: error: This is not GNU libtool" >&5
echo "$as_me: error: This is not GNU libtool" >&2;}
{ (exit 1); exit 1; }; }
fi
else
- { { echo "$as_me:10927: error: GNU libtool has not been found" >&5
+ { { echo "$as_me:12751: error: GNU libtool has not been found" >&5
echo "$as_me: error: GNU libtool has not been found" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -10938,7 +12762,7 @@ fi
esac
# special hack to add --tag option for C++ compiler
- case $cf_cv_libtool_version in
+ case "$cf_cv_libtool_version" in
(1.[5-9]*|[2-9].[0-9.a-z]*)
LIBTOOL_CXX="$LIBTOOL --tag=CXX"
LIBTOOL="$LIBTOOL --tag=CC"
@@ -10962,7 +12786,7 @@ if test "$with_libtool" = "yes" ; then
DFT_LWR_MODEL=$LIB_MODEL
LIBTOOL_MAKE=
-echo "$as_me:10965: checking for additional libtool options" >&5
+echo "$as_me:12789: checking for additional libtool options" >&5
echo $ECHO_N "checking for additional libtool options... $ECHO_C" >&6
# Check whether --with-libtool-opts or --without-libtool-opts was given.
@@ -10972,7 +12796,7 @@ if test "${with_libtool_opts+set}" = set; then
else
with_libtool_opts=no
fi;
-echo "$as_me:10975: result: $with_libtool_opts" >&5
+echo "$as_me:12799: result: $with_libtool_opts" >&5
echo "${ECHO_T}$with_libtool_opts" >&6
case .$with_libtool_opts in
@@ -10983,7 +12807,7 @@ case .$with_libtool_opts in
;;
esac
-echo "$as_me:10986: checking if exported-symbols file should be used" >&5
+echo "$as_me:12810: checking if exported-symbols file should be used" >&5
echo $ECHO_N "checking if exported-symbols file should be used... $ECHO_C" >&6
# Check whether --with-export-syms or --without-export-syms was given.
@@ -10998,7 +12822,7 @@ then
with_export_syms='${top_srcdir}/package/${PACKAGE}.sym'
fi
-echo "$as_me:11001: result: $with_export_syms" >&5
+echo "$as_me:12825: result: $with_export_syms" >&5
echo "${ECHO_T}$with_export_syms" >&6
if test "x$with_export_syms" != xno
then
@@ -11010,7 +12834,7 @@ fi
MAKE_STATIC="#"
MAKE_SHARED=
else
- echo "$as_me:11013: checking if you want to build shared libraries" >&5
+ echo "$as_me:12837: checking if you want to build shared libraries" >&5
echo $ECHO_N "checking if you want to build shared libraries... $ECHO_C" >&6
# Check whether --with-shared or --without-shared was given.
@@ -11020,7 +12844,7 @@ if test "${with_shared+set}" = set; then
else
with_shared=no
fi;
- echo "$as_me:11023: result: $with_shared" >&5
+ echo "$as_me:12847: result: $with_shared" >&5
echo "${ECHO_T}$with_shared" >&6
if test "$with_shared" = "yes" ; then
LIB_MODEL=shared
@@ -11041,14 +12865,14 @@ echo "${ECHO_T}$with_shared" >&6
cf_ld_rpath_opt=
test "$cf_cv_enable_rpath" = yes && cf_ld_rpath_opt="$LD_RPATH_OPT"
- echo "$as_me:11044: checking if release/abi version should be used for shared libs" >&5
+ echo "$as_me:12868: checking if release/abi version should be used for shared libs" >&5
echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
# Check whether --with-shlib-version or --without-shlib-version was given.
if test "${with_shlib_version+set}" = set; then
withval="$with_shlib_version"
test -z "$withval" && withval=auto
- case $withval in
+ case "$withval" in
(yes)
cf_cv_shlib_version=auto
;;
@@ -11056,9 +12880,9 @@ if test "${with_shlib_version+set}" = set; then
cf_cv_shlib_version=$withval
;;
(*)
- echo "$as_me:11059: result: $withval" >&5
+ echo "$as_me:12883: result: $withval" >&5
echo "${ECHO_T}$withval" >&6
- { { echo "$as_me:11061: error: option value must be one of: rel, abi, or auto" >&5
+ { { echo "$as_me:12885: error: option value must be one of: rel, abi, or auto" >&5
echo "$as_me: error: option value must be one of: rel, abi, or auto" >&2;}
{ (exit 1); exit 1; }; }
;;
@@ -11067,7 +12891,7 @@ echo "$as_me: error: option value must be one of: rel, abi, or auto" >&2;}
else
cf_cv_shlib_version=auto
fi;
- echo "$as_me:11070: result: $cf_cv_shlib_version" >&5
+ echo "$as_me:12894: result: $cf_cv_shlib_version" >&5
echo "${ECHO_T}$cf_cv_shlib_version" >&6
cf_cv_rm_so_locs=no
@@ -11081,7 +12905,7 @@ echo "${ECHO_T}$cf_cv_shlib_version" >&6
then
cf_try_fPIC=yes
else
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(*linux*) # e.g., PGI compiler
cf_try_fPIC=yes
;;
@@ -11090,14 +12914,14 @@ echo "${ECHO_T}$cf_cv_shlib_version" >&6
if test "$cf_try_fPIC" = yes
then
- echo "$as_me:11093: checking which $CC option to use" >&5
+ echo "$as_me:12917: checking which $CC option to use" >&5
echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
cf_save_CFLAGS="$CFLAGS"
for CC_SHARED_OPTS in -fPIC -fpic ''
do
CFLAGS="$cf_save_CFLAGS $CC_SHARED_OPTS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 11100 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 12924 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -11108,33 +12932,33 @@ int x = 1
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:11112: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:12936: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:11115: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:11118: \"$ac_try\"") >&5
+ echo "$as_me:12939: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:12942: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:11121: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:12945: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
- echo "$as_me:11130: result: $CC_SHARED_OPTS" >&5
+ echo "$as_me:12954: result: $CC_SHARED_OPTS" >&5
echo "${ECHO_T}$CC_SHARED_OPTS" >&6
CFLAGS="$cf_save_CFLAGS"
fi
cf_cv_shlib_version_infix=no
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(aix4.3-9*|aix[5-7]*)
if test "$GCC" = yes; then
CC_SHARED_OPTS='-Wl,-brtl'
@@ -11198,7 +13022,7 @@ CF_EOF
MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
cf_cv_shlib_version_infix=yes
- echo "$as_me:11201: checking if ld -search_paths_first works" >&5
+ echo "$as_me:13025: checking if ld -search_paths_first works" >&5
echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -11206,8 +13030,8 @@ else
cf_save_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
- cat >conftest.$ac_ext <<_ACEOF
-#line 11210 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 13034 "configure"
#include "confdefs.h"
int
@@ -11218,30 +13042,30 @@ int i;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:11222: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:13046: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:11225: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:11228: \"$ac_try\"") >&5
+ echo "$as_me:13049: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:13052: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:11231: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:13055: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ldflags_search_paths_first=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_ldflags_search_paths_first=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LDFLAGS=$cf_save_LDFLAGS
fi
-echo "$as_me:11242: result: $cf_cv_ldflags_search_paths_first" >&5
+echo "$as_me:13066: result: $cf_cv_ldflags_search_paths_first" >&5
echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
- if test $cf_cv_ldflags_search_paths_first = yes; then
+ if test "$cf_cv_ldflags_search_paths_first" = yes; then
LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
fi
;;
@@ -11290,7 +13114,7 @@ echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
cf_cv_rm_so_locs=yes
;;
(linux*|gnu*|k*bsd*-gnu)
- if test "$DFT_LWR_MODEL" = "shared" ; then
+ if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
fi
@@ -11307,6 +13131,112 @@ echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
;;
+ (mingw*msvc*)
+ cf_cv_shlib_version=msvcdll
+ cf_cv_shlib_version_infix=msvcdll
+ shlibdir=$bindir
+ MAKE_DLLS=
+ if test "$DFT_LWR_MODEL" = "shared" ; then
+ LOCAL_LDFLAGS="-link -dll"
+ LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
+ EXTRA_LDFLAGS="-link -dll $EXTRA_LDFLAGS"
+ fi
+ CC_SHARED_OPTS=
+ MK_SHARED_LIB=$SHELL' '$rel_builddir'/mk_shared_lib.sh $@ ${LD} ${CFLAGS}'
+ RM_SHARED_OPTS="$RM_SHARED_OPTS $rel_builddir/mk_shared_lib.sh *.dll.lib"
+ cat >mk_shared_lib.sh <<-CF_EOF
+ #!$SHELL
+ SHARED_LIB=\$1
+ IMPORT_LIB=\`echo "\$1" | sed -e 's/[0-9]*\.dll$/.dll.lib/'\`
+ shift
+ my_ld=\$1
+ shift
+ cat <<-EOF
+ Linking shared library
+ ** SHARED LIB \$SHARED_LIB
+ ** IMPORT_LIB \$IMPORT_LIB
+EOF
+ args=\$(echo \$* | sed -E "s#-l(\w*)#\1.dll.lib#g" | sed -E "s#-L(\w*)#-LIBPATH:\1#g")
+ exec \$my_ld -DLL -IMPLIB:"\${IMPORT_LIB}" -OUT:"\${SHARED_LIB}" ${LDFLAGS} \$args
+ mv "\${IMPORT_LIB}" "\${IMPORT_LIB}"
+CF_EOF
+ chmod +x mk_shared_lib.sh
+ cat >mk_prog.sh <<-CF_EOF
+ #!$SHELL
+ shift
+ # Ignore first argument (compiler) and use LD (link.exe) unconditionally
+ LD="$LD"
+ clopts=()
+ ldopts=("/subsystem:console")
+ libs=()
+ isdll=0
+ while test \$# -gt 0; do
+ case "\$1" in
+ -link)
+ # ignore -link argument
+ ;;
+ -M[TD] | -M[TD]d)
+ # ignore runtime-library option
+ ;;
+ -dll)
+ isdll=1
+ ;;
+ -W* | -w*)
+ # ignore warnings
+ ;;
+ -D*)
+ clopts+=("\$1")
+ ;;
+ -I*)
+ clopts+=("\$1")
+ ;;
+ -l*)
+ libs+=("\`echo \"\$1\" | sed \"s/^-l//\"\`")
+ ;;
+ -L*)
+ ldopts+=("\`echo \"\$1\" | sed \"s/^-L/-LIBPATH:/\"\`")
+ ;;
+ *.obj | *.o)
+ ldopts+=("\$1")
+ ;;
+ -Wl,*)
+ for linkarg in \`echo '\$1' | sed -e 's/-Wl,//' -e 's/,/ /'\`; do
+ ldopts+=("\${linkarg}")
+ done
+ ;;
+ *.lib)
+ ldopts+=("\$1")
+ ;;
+ -o)
+ shift
+ ldopts+=("-out:\$1")
+ ;;
+ *)
+ clopts+=("\$1")
+ ldopts+=("\$1")
+ ;;
+ esac
+ shift
+ done
+ if [ "\$isdll" -ne 0 ]; then
+ for lib in \${libs[*]}; do
+ ldopts+=("\$lib.dll.lib")
+ done
+ else
+ for lib in \${libs[*]}; do
+ ldopts+=("\$lib.lib")
+ done
+ fi
+ cat <<-EOF
+ Creating program
+ ** ld options: "\${ldopts[@]}"
+EOF
+ exec \$LD \${ldopts[@]}
+CF_EOF
+ chmod +x mk_prog.sh
+ LINK_PROGS="$SHELL ${rel_builddir}/mk_prog.sh"
+ LINK_TESTS="$SHELL ${rel_builddir}/mk_prog.sh"
+ ;;
(mingw*)
cf_cv_shlib_version=mingw
cf_cv_shlib_version_infix=mingw
@@ -11335,7 +13265,7 @@ CF_EOF
chmod +x mk_shared_lib.sh
;;
(openbsd[2-9].*|mirbsd*)
- if test "$DFT_LWR_MODEL" = "shared" ; then
+ if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
fi
@@ -11353,6 +13283,14 @@ CF_EOF
MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-Bshareable,-soname,'$cf_cv_shared_soname',-stats,-lc -o $@'
;;
+ (nskJ*)
+ CC_SHARED_OPTS=
+ MK_SHARED_LIB='${LD} -Wshared -Weld=-export_all -o $@'
+ ;;
+ (nskL*)
+ CC_SHARED_OPTS=
+ MK_SHARED_LIB='${LD} -Wshared -Wxld=-export_all -o $@'
+ ;;
(nto-qnx*|openbsd*|freebsd[12].*)
CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
MK_SHARED_LIB='${LD} ${LDFLAGS} -Bshareable -o $@'
@@ -11398,7 +13336,7 @@ CF_EOF
MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
else
- MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -Wl,-shared -Wl,-Bshareable -o $@'
+ MK_SHARED_LIB='${CC} ${LDFLAGS} ${CFLAGS} -shared -o $@'
fi
;;
(osf*|mls+*)
@@ -11406,13 +13344,13 @@ CF_EOF
# tested with OSF/1 V3.2 and gcc 2.6.3 (but the c++ demo didn't
# link with shared libs).
MK_SHARED_LIB='${LD} ${LDFLAGS} -set_version ${REL_VERSION}:${ABI_VERSION} -expect_unresolved "*" -shared -soname `basename $@`'
- case $host_os in
+ case "$host_os" in
(osf4*)
MK_SHARED_LIB="${MK_SHARED_LIB} -msym"
;;
esac
MK_SHARED_LIB="${MK_SHARED_LIB}"' -o $@'
- if test "$DFT_LWR_MODEL" = "shared" ; then
+ if test "$DFT_LWR_MODEL" = "shared" && test -n "$LD_RPATH_OPT" ; then
LOCAL_LDFLAGS="${LD_RPATH_OPT}\$(LOCAL_LIBDIR)"
LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
fi
@@ -11463,36 +13401,36 @@ CF_EOF
for cf_shared_opts in -xcode=pic32 -xcode=pic13 -KPIC -Kpic -O
do
CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 11467 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 13405 "configure"
#include "confdefs.h"
#include <stdio.h>
int
main (void)
{
-printf("Hello\n");
+printf("Hello\\n");
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:11479: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:13417: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:11482: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:11485: \"$ac_try\"") >&5
+ echo "$as_me:13420: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:13423: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:11488: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:13426: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
CFLAGS="$cf_save_CFLAGS"
CC_SHARED_OPTS=$cf_shared_opts
@@ -11522,7 +13460,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext
test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
;;
(*)
- { echo "$as_me:11525: WARNING: ignored --with-shlib-version" >&5
+ { echo "$as_me:13463: WARNING: ignored --with-shlib-version" >&5
echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
;;
esac
@@ -11532,11 +13470,11 @@ echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
if test -n "$cf_try_cflags"
then
cat > conftest.$ac_ext <<EOF
-#line 11535 "${as_me:-configure}"
+#line 13473 "${as_me:-configure}"
#include <stdio.h>
int main(int argc, char *argv[])
{
- printf("hello\n");
+ printf("hello\\n");
return (argv[argc-1] == 0) ;
}
EOF
@@ -11544,18 +13482,18 @@ EOF
for cf_opt in $cf_try_cflags
do
CFLAGS="$cf_save_CFLAGS -$cf_opt"
- echo "$as_me:11547: checking if CFLAGS option -$cf_opt works" >&5
+ echo "$as_me:13485: checking if CFLAGS option -$cf_opt works" >&5
echo $ECHO_N "checking if CFLAGS option -$cf_opt works... $ECHO_C" >&6
- if { (eval echo "$as_me:11549: \"$ac_compile\"") >&5
+ if { (eval echo "$as_me:13487: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:11552: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- echo "$as_me:11554: result: yes" >&5
+ echo "$as_me:13490: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; then
+ echo "$as_me:13492: result: yes" >&5
echo "${ECHO_T}yes" >&6
cf_save_CFLAGS="$CFLAGS"
else
- echo "$as_me:11558: result: no" >&5
+ echo "$as_me:13496: result: no" >&5
echo "${ECHO_T}no" >&6
fi
done
@@ -11566,17 +13504,17 @@ echo "${ECHO_T}no" >&6
test -n "$cf_ld_rpath_opt" && MK_SHARED_LIB="$MK_SHARED_LIB $cf_ld_rpath_opt\${RPATH_LIST}"
test -z "$RPATH_LIST" && RPATH_LIST="\${libdir}"
- test $cf_cv_rm_so_locs = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
+ test "$cf_cv_rm_so_locs" = yes && RM_SHARED_OPTS="$RM_SHARED_OPTS so_locations"
test -n "$verbose" && echo " CC_SHARED_OPTS: $CC_SHARED_OPTS" 1>&6
-echo "${as_me:-configure}:11573: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5
+echo "${as_me:-configure}:13511: testing CC_SHARED_OPTS: $CC_SHARED_OPTS ..." 1>&5
test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
-echo "${as_me:-configure}:11577: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
+echo "${as_me:-configure}:13515: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
-echo "$as_me:11579: checking if versioned-symbols file should be used" >&5
+echo "$as_me:13517: checking if versioned-symbols file should be used" >&5
echo $ECHO_N "checking if versioned-symbols file should be used... $ECHO_C" >&6
# Check whether --with-versioned-syms or --without-versioned-syms was given.
@@ -11586,12 +13524,26 @@ if test "${with_versioned_syms+set}" = set; then
else
with_versioned_syms=no
fi;
-if test "x$with_versioned_syms" = xyes
-then
+case "x$with_versioned_syms" in
+(xyes)
with_versioned_syms='${top_srcdir}/package/${PACKAGE}.map'
-fi
-echo "$as_me:11594: result: $with_versioned_syms" >&5
+ ;;
+(xno)
+ ;;
+(x/*)
+ test -f "$with_versioned_syms" || { { echo "$as_me:13535: error: expected a filename: $with_versioned_syms" >&5
+echo "$as_me: error: expected a filename: $with_versioned_syms" >&2;}
+ { (exit 1); exit 1; }; }
+ ;;
+(*)
+ test -f "$with_versioned_syms" || { { echo "$as_me:13540: error: expected a filename: $with_versioned_syms" >&5
+echo "$as_me: error: expected a filename: $with_versioned_syms" >&2;}
+ { (exit 1); exit 1; }; }
+ with_versioned_syms=`pwd`/"$with_versioned_syms"
+ ;;
+esac
+echo "$as_me:13546: result: $with_versioned_syms" >&5
echo "${ECHO_T}$with_versioned_syms" >&6
RESULTING_SYMS=
@@ -11607,7 +13559,7 @@ then
MK_SHARED_LIB=`echo "$MK_SHARED_LIB" | sed -e "s%-Wl,%\\${VERSIONED_SYMS} -Wl,%"`
test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
-echo "${as_me:-configure}:11610: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
+echo "${as_me:-configure}:13562: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
;;
(*-dy\ *)
@@ -11615,11 +13567,11 @@ echo "${as_me:-configure}:11610: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&
MK_SHARED_LIB=`echo "$MK_SHARED_LIB" | sed -e "s%-dy%\\${VERSIONED_SYMS} -dy%"`
test -n "$verbose" && echo " MK_SHARED_LIB: $MK_SHARED_LIB" 1>&6
-echo "${as_me:-configure}:11618: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
+echo "${as_me:-configure}:13570: testing MK_SHARED_LIB: $MK_SHARED_LIB ..." 1>&5
;;
(*)
- { echo "$as_me:11622: WARNING: this system does not support versioned-symbols" >&5
+ { echo "$as_me:13574: WARNING: this system does not support versioned-symbols" >&5
echo "$as_me: WARNING: this system does not support versioned-symbols" >&2;}
;;
esac
@@ -11631,7 +13583,7 @@ echo "$as_me: WARNING: this system does not support versioned-symbols" >&2;}
# symbols.
if test "x$VERSIONED_SYMS" != "x"
then
- echo "$as_me:11634: checking if wildcards can be used to selectively omit symbols" >&5
+ echo "$as_me:13586: checking if wildcards can be used to selectively omit symbols" >&5
echo $ECHO_N "checking if wildcards can be used to selectively omit symbols... $ECHO_C" >&6
WILDCARD_SYMS=no
@@ -11668,7 +13620,7 @@ local:
} submodule_1.0;
EOF
cat >conftest.$ac_ext <<EOF
-#line 11671 "configure"
+#line 13623 "configure"
int _ismissing(void) { return 1; }
int _localf1(void) { return 1; }
int _localf2(void) { return 2; }
@@ -11696,10 +13648,10 @@ EOF
if make -f conftest.mk 2>&5 >/dev/null
then
# test for missing symbol in either Data or Text section
- cf_missing=`nm -P conftest.so 2>&5 |fgrep _ismissing | egrep '[ ][DT][ ]'`
+ cf_missing="`nm -P conftest.so 2>&5 |${FGREP-fgrep} _ismissing | ${EGREP-egrep} '[ ][DT][ ]'`"
test -n "$cf_missing" && WILDCARD_SYMS=yes
fi
- echo "$as_me:11702: result: $WILDCARD_SYMS" >&5
+ echo "$as_me:13654: result: $WILDCARD_SYMS" >&5
echo "${ECHO_T}$WILDCARD_SYMS" >&6
rm -f conftest.*
fi
@@ -11722,19 +13674,37 @@ LIB_SUFFIX=
DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
;;
(Xdebug)
- DFT_LIB_SUFFIX='_g.a'
+ case "$cf_cv_system_name" in
+ (*-msvc*)
+ DFT_LIB_SUFFIX='_g.lib'
+ ;;
+ (*)
+ DFT_LIB_SUFFIX='_g.a'
+ ;;
+ esac
DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
;;
(Xprofile)
- DFT_LIB_SUFFIX='_p.a'
+ case "$cf_cv_system_name" in
+ (*-msvc*)
+ DFT_LIB_SUFFIX='_p.lib'
+ ;;
+ (*)
+ DFT_LIB_SUFFIX='_p.a'
+ ;;
+ esac
DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
;;
(Xshared)
- case $cf_cv_system_name in
+ case "$cf_cv_system_name" in
(aix[5-7]*)
DFT_LIB_SUFFIX='.so'
DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
;;
+ (*-msvc*)
+ DFT_LIB_SUFFIX='.dll'
+ DFT_DEP_SUFFIX='.dll.lib'
+ ;;
(cygwin*|msys*|mingw*)
DFT_LIB_SUFFIX='.dll'
DFT_DEP_SUFFIX='.dll.a'
@@ -11744,7 +13714,7 @@ LIB_SUFFIX=
DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
;;
(hpux*)
- case $target in
+ case "$target" in
(ia64*)
DFT_LIB_SUFFIX='.so'
DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
@@ -11762,7 +13732,14 @@ LIB_SUFFIX=
esac
;;
(*)
- DFT_LIB_SUFFIX='.a'
+ case "$target" in
+ (*-msvc*)
+ DFT_LIB_SUFFIX='.lib'
+ ;;
+ (*)
+ DFT_LIB_SUFFIX='.a'
+ ;;
+ esac
DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
;;
esac
@@ -11774,7 +13751,7 @@ LIB_SUFFIX=
LIB_SUFFIX=$DFT_LIB_SUFFIX
-echo "$as_me:11777: checking for specific curses-directory" >&5
+echo "$as_me:13754: checking for specific curses-directory" >&5
echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
# Check whether --with-curses-dir or --without-curses-dir was given.
@@ -11784,10 +13761,10 @@ if test "${with_curses_dir+set}" = set; then
else
cf_cv_curses_dir=no
fi;
-echo "$as_me:11787: result: $cf_cv_curses_dir" >&5
+echo "$as_me:13764: result: $cf_cv_curses_dir" >&5
echo "${ECHO_T}$cf_cv_curses_dir" >&6
-if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
+if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
then
if test "x$prefix" != xNONE; then
@@ -11803,19 +13780,19 @@ case ".$withval" in
;;
(.[a-zA-Z]:[\\/]*) # OS/2 EMX
;;
-(.\${*prefix}*|.\${*dir}*)
+(.\$\{*prefix\}*|.\$\{*dir\}*)
eval withval="$withval"
case ".$withval" in
(.NONE/*)
- withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
+ withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
;;
esac
;;
(.no|.NONE/*)
- withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
+ withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
;;
(*)
- { { echo "$as_me:11818: error: expected a pathname, not \"$withval\"" >&5
+ { { echo "$as_me:13795: error: expected a pathname, not \"$withval\"" >&5
echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
{ (exit 1); exit 1; }; }
;;
@@ -11827,9 +13804,9 @@ esac
if test -n "$cf_cv_curses_dir/include" ; then
for cf_add_incdir in $cf_cv_curses_dir/include
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -11850,8 +13827,8 @@ if test -n "$cf_cv_curses_dir/include" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 11854 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 13831 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -11862,25 +13839,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:11866: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:13843: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:11869: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:11872: \"$ac_try\"") >&5
+ echo "$as_me:13846: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:13849: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:11875: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:13852: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -11889,11 +13866,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:11892: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:13869: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -11909,9 +13886,9 @@ fi
if test -n "$cf_cv_curses_dir/lib" ; then
for cf_add_libdir in $cf_cv_curses_dir/lib
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -11925,7 +13902,7 @@ if test -n "$cf_cv_curses_dir/lib" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:11928: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:13905: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -11936,20 +13913,7 @@ fi
fi
fi
-echo "$as_me:11939: checking if rpath option should be used" >&5
-echo $ECHO_N "checking if rpath option should be used... $ECHO_C" >&6
-
-# Check whether --enable-rpath or --disable-rpath was given.
-if test "${enable_rpath+set}" = set; then
- enableval="$enable_rpath"
- cf_cv_enable_rpath=$enableval
-else
- cf_cv_enable_rpath=no
-fi;
-echo "$as_me:11949: result: $cf_cv_enable_rpath" >&5
-echo "${ECHO_T}$cf_cv_enable_rpath" >&6
-
-echo "$as_me:11952: checking for specific curses-directory" >&5
+echo "$as_me:13916: checking for specific curses-directory" >&5
echo $ECHO_N "checking for specific curses-directory... $ECHO_C" >&6
# Check whether --with-curses-dir or --without-curses-dir was given.
@@ -11959,10 +13923,10 @@ if test "${with_curses_dir+set}" = set; then
else
cf_cv_curses_dir=no
fi;
-echo "$as_me:11962: result: $cf_cv_curses_dir" >&5
+echo "$as_me:13926: result: $cf_cv_curses_dir" >&5
echo "${ECHO_T}$cf_cv_curses_dir" >&6
-if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
+if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
then
if test "x$prefix" != xNONE; then
@@ -11978,19 +13942,19 @@ case ".$withval" in
;;
(.[a-zA-Z]:[\\/]*) # OS/2 EMX
;;
-(.\${*prefix}*|.\${*dir}*)
+(.\$\{*prefix\}*|.\$\{*dir\}*)
eval withval="$withval"
case ".$withval" in
(.NONE/*)
- withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
+ withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
;;
esac
;;
(.no|.NONE/*)
- withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
+ withval=`echo "$withval" | sed -e s%NONE%$cf_path_syntax%`
;;
(*)
- { { echo "$as_me:11993: error: expected a pathname, not \"$withval\"" >&5
+ { { echo "$as_me:13957: error: expected a pathname, not \"$withval\"" >&5
echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
{ (exit 1); exit 1; }; }
;;
@@ -12002,9 +13966,9 @@ esac
if test -n "$cf_cv_curses_dir/include" ; then
for cf_add_incdir in $cf_cv_curses_dir/include
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -12025,8 +13989,8 @@ if test -n "$cf_cv_curses_dir/include" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 12029 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 13993 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -12037,25 +14001,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:12041: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:14005: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:12044: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:12047: \"$ac_try\"") >&5
+ echo "$as_me:14008: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:14011: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12050: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14014: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -12064,11 +14028,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:12067: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:14031: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -12084,9 +14048,9 @@ fi
if test -n "$cf_cv_curses_dir/lib" ; then
for cf_add_libdir in $cf_cv_curses_dir/lib
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -12100,7 +14064,7 @@ if test -n "$cf_cv_curses_dir/lib" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:12103: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:14067: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -12113,7 +14077,7 @@ fi
cf_cv_screen=curses
-echo "$as_me:12116: checking for specified curses library type" >&5
+echo "$as_me:14080: checking for specified curses library type" >&5
echo $ECHO_N "checking for specified curses library type... $ECHO_C" >&6
# Check whether --with-screen or --without-screen was given.
@@ -12157,20 +14121,20 @@ fi;
fi;
fi;
-echo "$as_me:12160: result: $cf_cv_screen" >&5
+echo "$as_me:14124: result: $cf_cv_screen" >&5
echo "${ECHO_T}$cf_cv_screen" >&6
case $cf_cv_screen in
(curses|curses_*)
-echo "$as_me:12166: checking for extra include directories" >&5
+echo "$as_me:14130: checking for extra include directories" >&5
echo $ECHO_N "checking for extra include directories... $ECHO_C" >&6
if test "${cf_cv_curses_incdir+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cf_cv_curses_incdir=no
-case $host_os in
+case "$host_os" in
(hpux10.*)
if test "x$cf_cv_screen" = "xcurses_colr"
then
@@ -12189,7 +14153,7 @@ case $host_os in
esac
fi
-echo "$as_me:12192: result: $cf_cv_curses_incdir" >&5
+echo "$as_me:14156: result: $cf_cv_curses_incdir" >&5
echo "${ECHO_T}$cf_cv_curses_incdir" >&6
if test "$cf_cv_curses_incdir" != no
then
@@ -12199,7 +14163,7 @@ then
fi
-echo "$as_me:12202: checking if we have identified curses headers" >&5
+echo "$as_me:14166: checking if we have identified curses headers" >&5
echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
if test "${cf_cv_ncurses_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -12210,8 +14174,8 @@ for cf_header in \
ncurses.h \
curses.h ncurses/ncurses.h ncurses/curses.h
do
-cat >conftest.$ac_ext <<_ACEOF
-#line 12214 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 14178 "configure"
#include "confdefs.h"
#include <${cf_header}>
int
@@ -12222,32 +14186,32 @@ initscr(); tgoto("?", 0,0)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:12226: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:14190: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:12229: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:12232: \"$ac_try\"") >&5
+ echo "$as_me:14193: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:14196: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12235: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14199: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_header=$cf_header; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
fi
-echo "$as_me:12246: result: $cf_cv_ncurses_header" >&5
+echo "$as_me:14210: result: $cf_cv_ncurses_header" >&5
echo "${ECHO_T}$cf_cv_ncurses_header" >&6
if test "$cf_cv_ncurses_header" = none ; then
- { { echo "$as_me:12250: error: No curses header-files found" >&5
+ { { echo "$as_me:14214: error: No curses header-files found" >&5
echo "$as_me: error: No curses header-files found" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -12257,24 +14221,24 @@ fi
for ac_header in $cf_cv_ncurses_header
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:12260: checking for $ac_header" >&5
+echo "$as_me:14224: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 12266 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 14230 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:12270: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:14234: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:12276: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:14240: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -12287,14 +14251,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:12295: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:14259: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -12302,13 +14266,13 @@ EOF
fi
done
-echo "$as_me:12305: checking for terminfo header" >&5
+echo "$as_me:14269: checking for terminfo header" >&5
echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
if test "${cf_cv_term_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-case ${cf_cv_ncurses_header} in
+case "${cf_cv_ncurses_header}" in
(*/ncurses.h|*/ncursesw.h)
cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
;;
@@ -12319,8 +14283,8 @@ esac
for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
do
-cat >conftest.$ac_ext <<_ACEOF
-#line 12323 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 14287 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -12329,43 +14293,43 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-int x = auto_left_margin
+int x = auto_left_margin; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:12338: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:14302: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:12341: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:12344: \"$ac_try\"") >&5
+ echo "$as_me:14305: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:14308: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12347: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14311: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_term_header="$cf_test"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_term_header=unknown
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
test "$cf_cv_term_header" != unknown && break
done
fi
-echo "$as_me:12363: result: $cf_cv_term_header" >&5
+echo "$as_me:14327: result: $cf_cv_term_header" >&5
echo "${ECHO_T}$cf_cv_term_header" >&6
# Set definitions to allow ifdef'ing to accommodate subdirectories
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(*term.h)
cat >>confdefs.h <<\EOF
@@ -12375,7 +14339,7 @@ EOF
;;
esac
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(ncurses/term.h)
cat >>confdefs.h <<\EOF
@@ -12392,7 +14356,7 @@ EOF
;;
esac
-echo "$as_me:12395: checking for ncurses version" >&5
+echo "$as_me:14359: checking for ncurses version" >&5
echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
if test "${cf_cv_ncurses_version+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -12400,12 +14364,12 @@ else
cf_cv_ncurses_version=no
cf_tempfile=out$$
- rm -f $cf_tempfile
+ rm -f "$cf_tempfile"
if test "$cross_compiling" = yes; then
# This will not work if the preprocessor splits the line after the
# Autoconf token. The 'unproto' program does that.
- cat > conftest.$ac_ext <<EOF
+ cat > "conftest.$ac_ext" <<EOF
#include <${cf_cv_ncurses_header:-curses.h}>
#undef Autoconf
#ifdef NCURSES_VERSION
@@ -12418,20 +14382,20 @@ Autoconf "old"
#endif
EOF
cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
- { (eval echo "$as_me:12421: \"$cf_try\"") >&5
+ { (eval echo "$as_me:14385: \"$cf_try\"") >&5
(eval $cf_try) 2>&5
ac_status=$?
- echo "$as_me:12424: \$? = $ac_status" >&5
- (exit $ac_status); }
+ echo "$as_me:14388: \$? = $ac_status" >&5
+ (exit "$ac_status"); }
if test -f conftest.out ; then
- cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
+ cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
rm -f conftest.out
fi
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 12434 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 14398 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -12441,13 +14405,13 @@ int main(void)
FILE *fp = fopen("$cf_tempfile", "w");
#ifdef NCURSES_VERSION
# ifdef NCURSES_VERSION_PATCH
- fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
+ fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
# else
- fprintf(fp, "%s\n", NCURSES_VERSION);
+ fprintf(fp, "%s\\n", NCURSES_VERSION);
# endif
#else
# ifdef __NCURSES_H
- fprintf(fp, "old\n");
+ fprintf(fp, "old\\n");
# else
make an error
# endif
@@ -12455,40 +14419,40 @@ int main(void)
${cf_cv_main_return:-return}(0);
}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:12459: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:14423: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:12462: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:12464: \"$ac_try\"") >&5
+ echo "$as_me:14426: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:14428: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12467: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14431: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_version=`cat $cf_tempfile`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
- rm -f $cf_tempfile
+ rm -f "$cf_tempfile"
fi
-echo "$as_me:12481: result: $cf_cv_ncurses_version" >&5
+echo "$as_me:14445: result: $cf_cv_ncurses_version" >&5
echo "${ECHO_T}$cf_cv_ncurses_version" >&6
test "$cf_cv_ncurses_version" = no ||
cat >>confdefs.h <<\EOF
#define NCURSES 1
EOF
-echo "$as_me:12488: checking if we have identified curses libraries" >&5
+echo "$as_me:14452: checking if we have identified curses libraries" >&5
echo $ECHO_N "checking if we have identified curses libraries... $ECHO_C" >&6
-cat >conftest.$ac_ext <<_ACEOF
-#line 12491 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 14455 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
@@ -12499,40 +14463,40 @@ initscr(); tgoto("?", 0,0)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:12503: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:14467: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:12506: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:12509: \"$ac_try\"") >&5
+ echo "$as_me:14470: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:14473: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12512: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14476: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_result=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_result=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-echo "$as_me:12521: result: $cf_result" >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+echo "$as_me:14485: result: $cf_result" >&5
echo "${ECHO_T}$cf_result" >&6
if test "$cf_result" = no ; then
-case $host_os in
+case "$host_os" in
(freebsd*)
- echo "$as_me:12527: checking for tgoto in -lmytinfo" >&5
+ echo "$as_me:14491: checking for tgoto in -lmytinfo" >&5
echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lmytinfo $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 12535 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 14499 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -12550,44 +14514,44 @@ tgoto ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:12554: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:14518: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:12557: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:12560: \"$ac_try\"") >&5
+ echo "$as_me:14521: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:14524: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12563: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14527: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_mytinfo_tgoto=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_mytinfo_tgoto=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:12574: result: $ac_cv_lib_mytinfo_tgoto" >&5
+echo "$as_me:14538: result: $ac_cv_lib_mytinfo_tgoto" >&5
echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
-if test $ac_cv_lib_mytinfo_tgoto = yes; then
-
-cf_add_libs="-lmytinfo"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
+
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lmytinfo; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -12601,15 +14565,15 @@ fi
# term.h) for cur_colr
if test "x$cf_cv_screen" = "xcurses_colr"
then
- echo "$as_me:12604: checking for initscr in -lcur_colr" >&5
+ echo "$as_me:14568: checking for initscr in -lcur_colr" >&5
echo $ECHO_N "checking for initscr in -lcur_colr... $ECHO_C" >&6
if test "${ac_cv_lib_cur_colr_initscr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lcur_colr $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 12612 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 14576 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -12627,44 +14591,44 @@ initscr ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:12631: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:14595: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:12634: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:12637: \"$ac_try\"") >&5
+ echo "$as_me:14598: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:14601: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12640: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14604: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_cur_colr_initscr=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_cur_colr_initscr=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:12651: result: $ac_cv_lib_cur_colr_initscr" >&5
+echo "$as_me:14615: result: $ac_cv_lib_cur_colr_initscr" >&5
echo "${ECHO_T}$ac_cv_lib_cur_colr_initscr" >&6
-if test $ac_cv_lib_cur_colr_initscr = yes; then
-
-cf_add_libs="-lcur_colr"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+if test "$ac_cv_lib_cur_colr_initscr" = yes; then
+
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lcur_colr; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -12672,15 +14636,15 @@ LIBS="$cf_add_libs"
else
- echo "$as_me:12675: checking for initscr in -lHcurses" >&5
+ echo "$as_me:14639: checking for initscr in -lHcurses" >&5
echo $ECHO_N "checking for initscr in -lHcurses... $ECHO_C" >&6
if test "${ac_cv_lib_Hcurses_initscr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lHcurses $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 12683 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 14647 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -12698,46 +14662,46 @@ initscr ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:12702: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:14666: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:12705: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:12708: \"$ac_try\"") >&5
+ echo "$as_me:14669: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:14672: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12711: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14675: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_Hcurses_initscr=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_Hcurses_initscr=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:12722: result: $ac_cv_lib_Hcurses_initscr" >&5
+echo "$as_me:14686: result: $ac_cv_lib_Hcurses_initscr" >&5
echo "${ECHO_T}$ac_cv_lib_Hcurses_initscr" >&6
-if test $ac_cv_lib_Hcurses_initscr = yes; then
+if test "$ac_cv_lib_Hcurses_initscr" = yes; then
# HP's header uses __HP_CURSES, but user claims _HP_CURSES.
-cf_add_libs="-lHcurses"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lHcurses; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -12761,9 +14725,9 @@ fi
if test -n "/lib64" ; then
for cf_add_libdir in /lib64
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -12777,7 +14741,7 @@ if test -n "/lib64" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:12780: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:14744: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -12790,9 +14754,9 @@ fi
if test -n "/lib" ; then
for cf_add_libdir in /lib
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -12806,7 +14770,7 @@ if test -n "/lib" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:12809: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:14773: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -12821,9 +14785,9 @@ fi
if test -n "/lib" ; then
for cf_add_libdir in /lib
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -12837,7 +14801,7 @@ if test -n "/lib" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:12840: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:14804: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -12856,9 +14820,9 @@ fi
if test -n "/usr/5lib" ; then
for cf_add_libdir in /usr/5lib
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -12872,7 +14836,7 @@ if test -n "/usr/5lib" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:12875: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:14839: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -12880,19 +14844,19 @@ echo "${as_me:-configure}:12875: testing adding $cf_add_libdir to library-path .
done
fi
-cf_add_libs="-lcurses -ltermcap"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lcurses -ltermcap; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -12916,80 +14880,80 @@ if test ".$ac_cv_func_initscr" != .yes ; then
# because it may be needed to link the test-case for initscr.
if test "x$cf_term_lib" = x
then
- echo "$as_me:12919: checking for tgoto" >&5
+ echo "$as_me:14883: checking for tgoto" >&5
echo $ECHO_N "checking for tgoto... $ECHO_C" >&6
if test "${ac_cv_func_tgoto+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 12925 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 14889 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char tgoto (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define tgoto autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef tgoto
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char tgoto ();
-char (*f) ();
+char tgoto (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_tgoto) || defined (__stub___tgoto)
-choke me
-#else
-f = tgoto; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for tgoto
#endif
+ return tgoto ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:12956: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:14920: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:12959: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:12962: \"$ac_try\"") >&5
+ echo "$as_me:14923: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:14926: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:12965: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14929: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_tgoto=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_tgoto=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:12975: result: $ac_cv_func_tgoto" >&5
+echo "$as_me:14939: result: $ac_cv_func_tgoto" >&5
echo "${ECHO_T}$ac_cv_func_tgoto" >&6
-if test $ac_cv_func_tgoto = yes; then
+if test "$ac_cv_func_tgoto" = yes; then
cf_term_lib=predefined
else
for cf_term_lib in $cf_check_list otermcap termcap tinfo termlib unknown
do
as_ac_Lib=`echo "ac_cv_lib_$cf_term_lib''_tgoto" | $as_tr_sh`
-echo "$as_me:12984: checking for tgoto in -l$cf_term_lib" >&5
+echo "$as_me:14948: checking for tgoto in -l$cf_term_lib" >&5
echo $ECHO_N "checking for tgoto in -l$cf_term_lib... $ECHO_C" >&6
if eval "test \"\${$as_ac_Lib+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-l$cf_term_lib $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 12992 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 14956 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -13007,32 +14971,32 @@ tgoto ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13011: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:14975: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13014: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13017: \"$ac_try\"") >&5
+ echo "$as_me:14978: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:14981: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13020: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:14984: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_Lib=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_Lib=no"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:13031: result: `eval echo '${'$as_ac_Lib'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
-if test `eval echo '${'$as_ac_Lib'}'` = yes; then
+echo "$as_me:14995: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
- : ${cf_nculib_root:=$cf_term_lib}
+ : "${cf_nculib_root:=$cf_term_lib}"
break
fi
@@ -13051,10 +15015,10 @@ fi
do
LIBS="-l$cf_curs_lib $cf_save_LIBS"
if test "$cf_term_lib" = unknown || test "$cf_term_lib" = "$cf_curs_lib" ; then
- echo "$as_me:13054: checking if we can link with $cf_curs_lib library" >&5
+ echo "$as_me:15018: checking if we can link with $cf_curs_lib library" >&5
echo $ECHO_N "checking if we can link with $cf_curs_lib library... $ECHO_C" >&6
- cat >conftest.$ac_ext <<_ACEOF
-#line 13057 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15021 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
@@ -13065,35 +15029,35 @@ initscr()
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13069: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:15033: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13072: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13075: \"$ac_try\"") >&5
+ echo "$as_me:15036: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:15039: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13078: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15042: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_result=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_result=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:13087: result: $cf_result" >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ echo "$as_me:15051: result: $cf_result" >&5
echo "${ECHO_T}$cf_result" >&6
- test $cf_result = yes && break
+ test "$cf_result" = yes && break
elif test "$cf_curs_lib" = "$cf_term_lib" ; then
cf_result=no
elif test "$cf_term_lib" != predefined ; then
- echo "$as_me:13093: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
+ echo "$as_me:15057: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
echo $ECHO_N "checking if we need both $cf_curs_lib and $cf_term_lib libraries... $ECHO_C" >&6
- cat >conftest.$ac_ext <<_ACEOF
-#line 13096 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15060 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
@@ -13104,26 +15068,26 @@ initscr(); tgoto((char *)0, 0, 0);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13108: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:15072: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13111: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13114: \"$ac_try\"") >&5
+ echo "$as_me:15075: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:15078: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13117: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15081: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_result=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 13126 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15090 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
@@ -13134,35 +15098,35 @@ initscr()
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13138: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:15102: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13141: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13144: \"$ac_try\"") >&5
+ echo "$as_me:15105: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:15108: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13147: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15111: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_result=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_result=error
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:13159: result: $cf_result" >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ echo "$as_me:15123: result: $cf_result" >&5
echo "${ECHO_T}$cf_result" >&6
- test $cf_result != error && break
+ test "$cf_result" != error && break
fi
done
fi
- test $cf_curs_lib = unknown && { { echo "$as_me:13165: error: no curses library found" >&5
+ test "$cf_curs_lib" = unknown && { { echo "$as_me:15129: error: no curses library found" >&5
echo "$as_me: error: no curses library found" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -13171,15 +15135,15 @@ fi
;;
(ncursesw*)
-echo "$as_me:13174: checking for multibyte character support" >&5
+echo "$as_me:15138: checking for multibyte character support" >&5
echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
if test "${cf_cv_utf8_lib+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cf_save_LIBS="$LIBS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 13182 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15146 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -13191,34 +15155,34 @@ putwc(0,0);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13195: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:15159: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13198: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13201: \"$ac_try\"") >&5
+ echo "$as_me:15162: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:15165: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13204: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15168: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_utf8_lib=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
# If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
# will be set on completion of the AC_TRY_LINK below.
cf_cv_header_path_utf8=
cf_cv_library_path_utf8=
-echo "${as_me:-configure}:13216: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
+echo "${as_me:-configure}:15180: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
cf_save_LIBS="$LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 13221 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 15185 "configure"
#include "confdefs.h"
#include <libutf8.h>
@@ -13230,18 +15194,18 @@ putwc(0,0);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13234: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:15198: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13237: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13240: \"$ac_try\"") >&5
+ echo "$as_me:15201: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:15204: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13243: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15207: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_find_linkage_utf8=yes
cf_cv_header_path_utf8=/usr/include
@@ -13249,12 +15213,12 @@ if { (eval echo "$as_me:13234: \"$ac_link\"") >&5
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
LIBS="-lutf8 $cf_save_LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 13257 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 15221 "configure"
#include "confdefs.h"
#include <libutf8.h>
@@ -13266,18 +15230,18 @@ putwc(0,0);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13270: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:15234: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13273: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13276: \"$ac_try\"") >&5
+ echo "$as_me:15237: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:15240: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13279: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15243: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_find_linkage_utf8=yes
cf_cv_header_path_utf8=/usr/include
@@ -13286,16 +15250,16 @@ if { (eval echo "$as_me:13270: \"$ac_link\"") >&5
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_find_linkage_utf8=no
LIBS="$cf_save_LIBS"
test -n "$verbose" && echo " find linkage for utf8 library" 1>&6
-echo "${as_me:-configure}:13296: testing find linkage for utf8 library ..." 1>&5
+echo "${as_me:-configure}:15260: testing find linkage for utf8 library ..." 1>&5
-echo "${as_me:-configure}:13298: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
+echo "${as_me:-configure}:15262: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
cf_save_CPPFLAGS="$CPPFLAGS"
cf_test_CPPFLAGS="$CPPFLAGS"
@@ -13307,7 +15271,7 @@ cf_header_path_list=""
if test -n "${CFLAGS}${CPPFLAGS}" ; then
for cf_header_path in $CPPFLAGS $CFLAGS
do
- case $cf_header_path in
+ case "$cf_header_path" in
(-I*)
cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
@@ -13315,11 +15279,11 @@ test "x$cf_header_path" != "xNONE" && \
test -d "$cf_header_path" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
- test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
- test -d $cf_header_path/include/utf8 && cf_search="$cf_search $cf_header_path/include/utf8"
- test -d $cf_header_path/include/utf8/include && cf_search="$cf_search $cf_header_path/include/utf8/include"
- test -d $cf_header_path/utf8/include && cf_search="$cf_search $cf_header_path/utf8/include"
- test -d $cf_header_path/utf8/include/utf8 && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
+ test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
+ test -d "$cf_header_path/include/utf8" && cf_search="$cf_search $cf_header_path/include/utf8"
+ test -d "$cf_header_path/include/utf8/include" && cf_search="$cf_search $cf_header_path/include/utf8/include"
+ test -d "$cf_header_path/utf8/include" && cf_search="$cf_search $cf_header_path/utf8/include"
+ test -d "$cf_header_path/utf8/include/utf8" && cf_search="$cf_search $cf_header_path/utf8/include/utf8"
}
cf_header_path_list="$cf_header_path_list $cf_search"
@@ -13336,11 +15300,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $prefix"
- test -d $prefix/include && cf_search="$cf_search $prefix/include"
- test -d $prefix/include/utf8 && cf_search="$cf_search $prefix/include/utf8"
- test -d $prefix/include/utf8/include && cf_search="$cf_search $prefix/include/utf8/include"
- test -d $prefix/utf8/include && cf_search="$cf_search $prefix/utf8/include"
- test -d $prefix/utf8/include/utf8 && cf_search="$cf_search $prefix/utf8/include/utf8"
+ test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
+ test -d "$prefix/include/utf8" && cf_search="$cf_search $prefix/include/utf8"
+ test -d "$prefix/include/utf8/include" && cf_search="$cf_search $prefix/include/utf8/include"
+ test -d "$prefix/utf8/include" && cf_search="$cf_search $prefix/utf8/include"
+ test -d "$prefix/utf8/include/utf8" && cf_search="$cf_search $prefix/utf8/include/utf8"
}
for cf_subdir_prefix in \
@@ -13354,13 +15318,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
- test -d $cf_subdir_prefix/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
- test -d $cf_subdir_prefix/include/utf8/include && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
- test -d $cf_subdir_prefix/utf8/include && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
- test -d $cf_subdir_prefix/utf8/include/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
+ test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
+ test -d "$cf_subdir_prefix/include/utf8" && cf_search="$cf_search $cf_subdir_prefix/include/utf8"
+ test -d "$cf_subdir_prefix/include/utf8/include" && cf_search="$cf_search $cf_subdir_prefix/include/utf8/include"
+ test -d "$cf_subdir_prefix/utf8/include" && cf_search="$cf_search $cf_subdir_prefix/utf8/include"
+ test -d "$cf_subdir_prefix/utf8/include/utf8" && cf_search="$cf_search $cf_subdir_prefix/utf8/include/utf8"
}
done
@@ -13368,33 +15332,33 @@ done
test "$includedir" != NONE && \
test "$includedir" != "/usr/include" && \
test -d "$includedir" && {
- test -d $includedir && cf_search="$cf_search $includedir"
- test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
+ test -d "$includedir" && cf_search="$cf_search $includedir"
+ test -d "$includedir/utf8" && cf_search="$cf_search $includedir/utf8"
}
test "$oldincludedir" != NONE && \
test "$oldincludedir" != "/usr/include" && \
test -d "$oldincludedir" && {
- test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
- test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
+ test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
+ test -d "$oldincludedir/utf8" && cf_search="$cf_search $oldincludedir/utf8"
}
cf_search="$cf_search $cf_header_path_list"
for cf_cv_header_path_utf8 in $cf_search
do
- if test -d $cf_cv_header_path_utf8 ; then
+ if test -d "$cf_cv_header_path_utf8" ; then
test -n "$verbose" && echo " ... testing $cf_cv_header_path_utf8" 1>&6
-echo "${as_me:-configure}:13389: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
+echo "${as_me:-configure}:15353: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
CPPFLAGS="$cf_save_CPPFLAGS"
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_cv_header_path_utf8"
- cat >conftest.$ac_ext <<_ACEOF
-#line 13397 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15361 "configure"
#include "confdefs.h"
#include <libutf8.h>
@@ -13406,40 +15370,40 @@ putwc(0,0);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:13410: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:15374: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:13413: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:13416: \"$ac_try\"") >&5
+ echo "$as_me:15377: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:15380: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13419: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15383: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
test -n "$verbose" && echo " ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
-echo "${as_me:-configure}:13424: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
+echo "${as_me:-configure}:15388: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
cf_cv_find_linkage_utf8=maybe
cf_test_CPPFLAGS="$CPPFLAGS"
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
CPPFLAGS="$cf_save_CPPFLAGS"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
done
if test "$cf_cv_find_linkage_utf8" = maybe ; then
-echo "${as_me:-configure}:13442: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
+echo "${as_me:-configure}:15406: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
cf_save_LIBS="$LIBS"
cf_save_LDFLAGS="$LDFLAGS"
@@ -13451,7 +15415,7 @@ cf_library_path_list=""
if test -n "${LDFLAGS}${LIBS}" ; then
for cf_library_path in $LDFLAGS $LIBS
do
- case $cf_library_path in
+ case "$cf_library_path" in
(-L*)
cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
@@ -13459,11 +15423,11 @@ test "x$cf_library_path" != "xNONE" && \
test -d "$cf_library_path" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
- test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
- test -d $cf_library_path/lib/utf8 && cf_search="$cf_search $cf_library_path/lib/utf8"
- test -d $cf_library_path/lib/utf8/lib && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
- test -d $cf_library_path/utf8/lib && cf_search="$cf_search $cf_library_path/utf8/lib"
- test -d $cf_library_path/utf8/lib/utf8 && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
+ test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
+ test -d "$cf_library_path/lib/utf8" && cf_search="$cf_search $cf_library_path/lib/utf8"
+ test -d "$cf_library_path/lib/utf8/lib" && cf_search="$cf_search $cf_library_path/lib/utf8/lib"
+ test -d "$cf_library_path/utf8/lib" && cf_search="$cf_search $cf_library_path/utf8/lib"
+ test -d "$cf_library_path/utf8/lib/utf8" && cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
}
cf_library_path_list="$cf_library_path_list $cf_search"
@@ -13478,11 +15442,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
- test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
- test -d $prefix/lib/utf8 && cf_search="$cf_search $prefix/lib/utf8"
- test -d $prefix/lib/utf8/lib && cf_search="$cf_search $prefix/lib/utf8/lib"
- test -d $prefix/utf8/lib && cf_search="$cf_search $prefix/utf8/lib"
- test -d $prefix/utf8/lib/utf8 && cf_search="$cf_search $prefix/utf8/lib/utf8"
+ test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
+ test -d "$prefix/lib/utf8" && cf_search="$cf_search $prefix/lib/utf8"
+ test -d "$prefix/lib/utf8/lib" && cf_search="$cf_search $prefix/lib/utf8/lib"
+ test -d "$prefix/utf8/lib" && cf_search="$cf_search $prefix/utf8/lib"
+ test -d "$prefix/utf8/lib/utf8" && cf_search="$cf_search $prefix/utf8/lib/utf8"
}
for cf_subdir_prefix in \
@@ -13496,13 +15460,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
- test -d $cf_subdir_prefix/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
- test -d $cf_subdir_prefix/lib/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
- test -d $cf_subdir_prefix/utf8/lib && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
- test -d $cf_subdir_prefix/utf8/lib/utf8 && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
+ test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
+ test -d "$cf_subdir_prefix/lib/utf8" && cf_search="$cf_search $cf_subdir_prefix/lib/utf8"
+ test -d "$cf_subdir_prefix/lib/utf8/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/utf8/lib"
+ test -d "$cf_subdir_prefix/utf8/lib" && cf_search="$cf_search $cf_subdir_prefix/utf8/lib"
+ test -d "$cf_subdir_prefix/utf8/lib/utf8" && cf_search="$cf_search $cf_subdir_prefix/utf8/lib/utf8"
}
done
@@ -13511,16 +15475,16 @@ cf_search="$cf_library_path_list $cf_search"
for cf_cv_library_path_utf8 in $cf_search
do
- if test -d $cf_cv_library_path_utf8 ; then
+ if test -d "$cf_cv_library_path_utf8" ; then
test -n "$verbose" && echo " ... testing $cf_cv_library_path_utf8" 1>&6
-echo "${as_me:-configure}:13517: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
+echo "${as_me:-configure}:15481: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
CPPFLAGS="$cf_test_CPPFLAGS"
LIBS="-lutf8 $cf_save_LIBS"
LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
- cat >conftest.$ac_ext <<_ACEOF
-#line 13523 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15487 "configure"
#include "confdefs.h"
#include <libutf8.h>
@@ -13532,36 +15496,36 @@ putwc(0,0);
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13536: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:15500: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13539: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13542: \"$ac_try\"") >&5
+ echo "$as_me:15503: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:15506: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13545: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15509: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
test -n "$verbose" && echo " ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
-echo "${as_me:-configure}:13550: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
+echo "${as_me:-configure}:15514: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
cf_cv_find_linkage_utf8=yes
cf_cv_library_file_utf8="-lutf8"
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
CPPFLAGS="$cf_save_CPPFLAGS"
LIBS="$cf_save_LIBS"
LDFLAGS="$cf_save_LDFLAGS"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
done
CPPFLAGS="$cf_save_CPPFLAGS"
@@ -13573,10 +15537,10 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS="$cf_save_LIBS"
@@ -13587,9 +15551,9 @@ cf_cv_utf8_lib=no
fi
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:13592: result: $cf_cv_utf8_lib" >&5
+echo "$as_me:15556: result: $cf_cv_utf8_lib" >&5
echo "${ECHO_T}$cf_cv_utf8_lib" >&6
# HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
@@ -13603,9 +15567,9 @@ EOF
if test -n "$cf_cv_header_path_utf8" ; then
for cf_add_incdir in $cf_cv_header_path_utf8
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -13626,8 +15590,8 @@ if test -n "$cf_cv_header_path_utf8" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 13630 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15594 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -13638,25 +15602,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:13642: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:15606: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:13645: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:13648: \"$ac_try\"") >&5
+ echo "$as_me:15609: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:15612: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13651: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:15615: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -13665,11 +15629,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:13668: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:15632: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -13685,9 +15649,9 @@ fi
if test -n "$cf_cv_library_path_utf8" ; then
for cf_add_libdir in $cf_cv_library_path_utf8
do
- if test $cf_add_libdir = /usr/lib ; then
+ if test "$cf_add_libdir" = /usr/lib ; then
:
- elif test -d $cf_add_libdir
+ elif test -d "$cf_add_libdir"
then
cf_have_libdir=no
if test -n "$LDFLAGS$LIBS" ; then
@@ -13701,7 +15665,7 @@ if test -n "$cf_cv_library_path_utf8" ; then
if test "$cf_have_libdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_libdir to library-path" 1>&6
-echo "${as_me:-configure}:13704: testing adding $cf_add_libdir to library-path ..." 1>&5
+echo "${as_me:-configure}:15668: testing adding $cf_add_libdir to library-path ..." 1>&5
LDFLAGS="-L$cf_add_libdir $LDFLAGS"
fi
@@ -13709,19 +15673,19 @@ echo "${as_me:-configure}:13704: testing adding $cf_add_libdir to library-path .
done
fi
-cf_add_libs="$cf_cv_library_file_utf8"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_cv_library_file_utf8; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -13731,39 +15695,50 @@ cf_ncuconfig_root=$cf_cv_screen
cf_have_ncuconfig=no
if test "x${PKG_CONFIG:=none}" != xnone; then
- echo "$as_me:13734: checking pkg-config for $cf_ncuconfig_root" >&5
+ echo "$as_me:15698: checking pkg-config for $cf_ncuconfig_root" >&5
echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
- echo "$as_me:13737: result: yes" >&5
+ echo "$as_me:15701: result: yes" >&5
echo "${ECHO_T}yes" >&6
- echo "$as_me:13740: checking if the $cf_ncuconfig_root package files work" >&5
+ echo "$as_me:15704: checking if the $cf_ncuconfig_root package files work" >&5
echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
cf_have_ncuconfig=unknown
+ cf_save_CFLAGS="$CFLAGS"
cf_save_CPPFLAGS="$CPPFLAGS"
cf_save_LIBS="$LIBS"
+ cf_pkg_cflags="`$PKG_CONFIG --cflags $cf_ncuconfig_root`"
+ cf_pkg_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
+
+ # while -W for passing linker flags is prevalent, it is not "standard".
+ # At least one wrapper for c89/c99 (in Apple's xcode) has its own
+ # incompatible _and_ non-standard -W option which gives an error. Work
+ # around that pitfall.
+ case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
+ (x*c[89]9@@*-W*)
+
cf_fix_cppflags=no
cf_new_cflags=
cf_new_cppflags=
cf_new_extra_cppflags=
-for cf_add_cflags in `$PKG_CONFIG --cflags $cf_ncuconfig_root`
+for cf_add_cflags in $cf_pkg_cflags
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -13782,7 +15757,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -13812,7 +15787,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -13842,83 +15817,271 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
+ cf_add_1lib=
+ break
+ fi
+ done
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
+done
+LIBS="$cf_add_libs"
+
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15837 "configure"
+#include "confdefs.h"
+#include <${cf_cv_ncurses_header:-curses.h}>
+int
+main (void)
+{
+initscr(); mousemask(0,0); tigetstr((char *)0);
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:15849: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:15852: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:15855: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:15858: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ if test "$cross_compiling" = yes; then
+ cf_test_ncuconfig=maybe
+else
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 15864 "configure"
+#include "confdefs.h"
+#include <${cf_cv_ncurses_header:-curses.h}>
+ int main(void)
+ { char *xx = curses_version(); return (xx == 0); }
+_ACEOF
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:15871: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:15874: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:15876: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:15879: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ cf_test_ncuconfig=yes
+else
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+cf_test_ncuconfig=no
+fi
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
+fi
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+cf_test_ncuconfig=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+
+ CFLAGS="$cf_save_CFLAGS"
+ CPPFLAGS="$cf_save_CPPFLAGS"
+ LIBS="$cf_save_LIBS"
+
+ if test "x$cf_test_ncuconfig" != xyes; then
+ cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
+ cf_pkg_cflags="$cf_temp"
+ cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
+ cf_pkg_libs="$cf_temp"
+ fi
+ ;;
+ esac
+
+cf_fix_cppflags=no
+cf_new_cflags=
+cf_new_cppflags=
+cf_new_extra_cppflags=
+
+for cf_add_cflags in $cf_pkg_cflags
do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+case "$cf_fix_cppflags" in
+(no)
+ case "$cf_add_cflags" in
+ (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
+ case "$cf_add_cflags" in
+ (-D*)
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+
+ test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
+ && test -z "${cf_tst_cflags}" \
+ && cf_fix_cppflags=yes
+
+ if test "$cf_fix_cppflags" = yes ; then
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ continue
+ elif test "${cf_tst_cflags}" = "\"'" ; then
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ continue
+ fi
+ ;;
+ esac
+ case "$CPPFLAGS" in
+ (*$cf_add_cflags)
+ ;;
+ (*)
+ case "$cf_add_cflags" in
+ (-D*)
+ cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
+
+CPPFLAGS=`echo "$CPPFLAGS" | \
+ sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
+ -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
+
+ ;;
+ esac
+
+ test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
+ cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
+
+ ;;
+ esac
+ ;;
+ (*)
+
+ test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
+ cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
+
+ ;;
+ esac
+ ;;
+(yes)
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
+
+ test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
+ && test -z "${cf_tst_cflags}" \
+ && cf_fix_cppflags=no
+ ;;
+esac
+done
+
+if test -n "$cf_new_cflags" ; then
+
+ test -n "$CFLAGS" && CFLAGS="$CFLAGS "
+ CFLAGS="${CFLAGS}$cf_new_cflags"
+
+fi
+
+if test -n "$cf_new_cppflags" ; then
+
+ test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
+ CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
+
+fi
+
+if test -n "$cf_new_extra_cppflags" ; then
+
+ test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
+ EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
+
+fi
+
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
- cat >conftest.$ac_ext <<_ACEOF
-#line 13862 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 16025 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
main (void)
{
-initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
+initscr(); mousemask(0,0); tigetstr((char *)0);
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:13874: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:16037: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13877: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:13880: \"$ac_try\"") >&5
+ echo "$as_me:16040: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:16043: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13883: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16046: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
if test "$cross_compiling" = yes; then
cf_have_ncuconfig=maybe
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 13889 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 16052 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int main(void)
{ char *xx = curses_version(); return (xx == 0); }
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:13896: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:16059: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:13899: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:13901: \"$ac_try\"") >&5
+ echo "$as_me:16062: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:16064: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13904: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16067: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_have_ncuconfig=yes
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_ncuconfig=no
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_ncuconfig=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:13921: result: $cf_have_ncuconfig" >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ echo "$as_me:16084: result: $cf_have_ncuconfig" >&5
echo "${ECHO_T}$cf_have_ncuconfig" >&6
test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
if test "$cf_have_ncuconfig" != "yes"
@@ -13934,13 +16097,13 @@ EOF
NCURSES_CONFIG_PKG=$cf_ncuconfig_root
-echo "$as_me:13937: checking for terminfo header" >&5
+echo "$as_me:16100: checking for terminfo header" >&5
echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
if test "${cf_cv_term_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-case ${cf_cv_ncurses_header} in
+case "${cf_cv_ncurses_header}" in
(*/ncurses.h|*/ncursesw.h)
cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
;;
@@ -13951,8 +16114,8 @@ esac
for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
do
-cat >conftest.$ac_ext <<_ACEOF
-#line 13955 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 16118 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -13961,43 +16124,43 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-int x = auto_left_margin
+int x = auto_left_margin; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:13970: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:16133: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:13973: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:13976: \"$ac_try\"") >&5
+ echo "$as_me:16136: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:16139: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:13979: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16142: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_term_header="$cf_test"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_term_header=unknown
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
test "$cf_cv_term_header" != unknown && break
done
fi
-echo "$as_me:13995: result: $cf_cv_term_header" >&5
+echo "$as_me:16158: result: $cf_cv_term_header" >&5
echo "${ECHO_T}$cf_cv_term_header" >&6
# Set definitions to allow ifdef'ing to accommodate subdirectories
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(*term.h)
cat >>confdefs.h <<\EOF
@@ -14007,7 +16170,7 @@ EOF
;;
esac
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(ncurses/term.h)
cat >>confdefs.h <<\EOF
@@ -14027,7 +16190,7 @@ esac
fi
else
- echo "$as_me:14030: result: no" >&5
+ echo "$as_me:16193: result: no" >&5
echo "${ECHO_T}no" >&6
NCURSES_CONFIG_PKG=none
fi
@@ -14043,7 +16206,7 @@ if test -n "$ac_tool_prefix"; then
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:14046: checking for $ac_word" >&5
+echo "$as_me:16209: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -14058,7 +16221,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
-echo "$as_me:14061: found $ac_dir/$ac_word" >&5
+echo "$as_me:16224: found $ac_dir/$ac_word" >&5
break
done
@@ -14066,10 +16229,10 @@ fi
fi
NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
if test -n "$NCURSES_CONFIG"; then
- echo "$as_me:14069: result: $NCURSES_CONFIG" >&5
+ echo "$as_me:16232: result: $NCURSES_CONFIG" >&5
echo "${ECHO_T}$NCURSES_CONFIG" >&6
else
- echo "$as_me:14072: result: no" >&5
+ echo "$as_me:16235: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -14082,7 +16245,7 @@ if test -z "$NCURSES_CONFIG"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:14085: checking for $ac_word" >&5
+echo "$as_me:16248: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -14097,7 +16260,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
-echo "$as_me:14100: found $ac_dir/$ac_word" >&5
+echo "$as_me:16263: found $ac_dir/$ac_word" >&5
break
done
@@ -14105,10 +16268,10 @@ fi
fi
ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
if test -n "$ac_ct_NCURSES_CONFIG"; then
- echo "$as_me:14108: result: $ac_ct_NCURSES_CONFIG" >&5
+ echo "$as_me:16271: result: $ac_ct_NCURSES_CONFIG" >&5
echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
else
- echo "$as_me:14111: result: no" >&5
+ echo "$as_me:16274: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -14128,19 +16291,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in `$NCURSES_CONFIG --cflags`
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -14159,7 +16322,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -14189,7 +16352,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -14219,25 +16382,25 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="`$NCURSES_CONFIG --libs`"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
# even with config script, some packages use no-override for curses.h
-echo "$as_me:14240: checking if we have identified curses headers" >&5
+echo "$as_me:16403: checking if we have identified curses headers" >&5
echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
if test "${cf_cv_ncurses_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -14248,8 +16411,8 @@ for cf_header in \
ncurses.h $cf_cv_screen/ncurses.h \
curses.h $cf_cv_screen/curses.h
do
-cat >conftest.$ac_ext <<_ACEOF
-#line 14252 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 16415 "configure"
#include "confdefs.h"
#include <${cf_header}>
int
@@ -14260,32 +16423,32 @@ initscr(); tgoto("?", 0,0)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:14264: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:16427: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:14267: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:14270: \"$ac_try\"") >&5
+ echo "$as_me:16430: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:16433: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:14273: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16436: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_header=$cf_header; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
fi
-echo "$as_me:14284: result: $cf_cv_ncurses_header" >&5
+echo "$as_me:16447: result: $cf_cv_ncurses_header" >&5
echo "${ECHO_T}$cf_cv_ncurses_header" >&6
if test "$cf_cv_ncurses_header" = none ; then
- { { echo "$as_me:14288: error: No curses header-files found" >&5
+ { { echo "$as_me:16451: error: No curses header-files found" >&5
echo "$as_me: error: No curses header-files found" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -14295,24 +16458,24 @@ fi
for ac_header in $cf_cv_ncurses_header
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:14298: checking for $ac_header" >&5
+echo "$as_me:16461: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 14304 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 16467 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:14308: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:16471: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:14314: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:16477: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -14325,14 +16488,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:14333: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:16496: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -14350,7 +16513,7 @@ cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuv
#define $cf_nculib_ROOT 1
EOF
- cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
+ cf_cv_ncurses_version="`$NCURSES_CONFIG --version`"
else
@@ -14362,9 +16525,9 @@ test "$cf_cv_curses_dir" != "no" && { \
if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -14385,8 +16548,8 @@ if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 14389 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 16552 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -14397,25 +16560,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:14401: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:16564: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:14404: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:14407: \"$ac_try\"") >&5
+ echo "$as_me:16567: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:16570: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:14410: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16573: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -14424,11 +16587,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:14427: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:16590: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -14443,19 +16606,19 @@ fi
}
-echo "$as_me:14446: checking for $cf_ncuhdr_root header in include-path" >&5
+echo "$as_me:16609: checking for $cf_ncuhdr_root header in include-path" >&5
echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
if test "${cf_cv_ncurses_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
- ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
+ { test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw; } && cf_header_list="$cf_header_list curses.h ncurses.h"
for cf_header in $cf_header_list
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 14458 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 16621 "configure"
#include "confdefs.h"
#include <$cf_header>
@@ -14465,10 +16628,10 @@ main (void)
#ifdef NCURSES_VERSION
-printf("%s\n", NCURSES_VERSION);
+printf("%s\\n", NCURSES_VERSION);
#else
#ifdef __NCURSES_H
-printf("old\n");
+printf("old\\n");
#else
make an error
#endif
@@ -14478,39 +16641,39 @@ printf("old\n");
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:14482: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:16645: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:14485: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:14488: \"$ac_try\"") >&5
+ echo "$as_me:16648: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:16651: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:14491: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16654: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_h=$cf_header
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_ncurses_h=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
test "$cf_cv_ncurses_h" != no && break
done
fi
-echo "$as_me:14506: result: $cf_cv_ncurses_h" >&5
+echo "$as_me:16669: result: $cf_cv_ncurses_h" >&5
echo "${ECHO_T}$cf_cv_ncurses_h" >&6
if test "$cf_cv_ncurses_h" != no ; then
cf_cv_ncurses_header=$cf_cv_ncurses_h
else
-echo "$as_me:14513: checking for $cf_ncuhdr_root include-path" >&5
+echo "$as_me:16676: checking for $cf_ncuhdr_root include-path" >&5
echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
if test "${cf_cv_ncurses_h2+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -14525,7 +16688,7 @@ cf_header_path_list=""
if test -n "${CFLAGS}${CPPFLAGS}" ; then
for cf_header_path in $CPPFLAGS $CFLAGS
do
- case $cf_header_path in
+ case "$cf_header_path" in
(-I*)
cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
@@ -14533,11 +16696,11 @@ test "x$cf_header_path" != "xNONE" && \
test -d "$cf_header_path" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
- test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
- test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
- test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
- test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
- test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
+ test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
+ test -d "$cf_header_path/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
+ test -d "$cf_header_path/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
+ test -d "$cf_header_path/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
+ test -d "$cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
}
cf_header_path_list="$cf_header_path_list $cf_search"
@@ -14554,11 +16717,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $prefix"
- test -d $prefix/include && cf_search="$cf_search $prefix/include"
- test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
- test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
- test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
- test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
+ test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
+ test -d "$prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
+ test -d "$prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
+ test -d "$prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
+ test -d "$prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
}
for cf_subdir_prefix in \
@@ -14572,13 +16735,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
- test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
- test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
- test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
- test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
+ test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
+ test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
+ test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
+ test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
+ test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
}
done
@@ -14586,20 +16749,20 @@ done
test "$includedir" != NONE && \
test "$includedir" != "/usr/include" && \
test -d "$includedir" && {
- test -d $includedir && cf_search="$cf_search $includedir"
- test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
+ test -d "$includedir" && cf_search="$cf_search $includedir"
+ test -d "$includedir/$cf_ncuhdr_root" && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
}
test "$oldincludedir" != NONE && \
test "$oldincludedir" != "/usr/include" && \
test -d "$oldincludedir" && {
- test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
- test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
+ test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
+ test -d "$oldincludedir/$cf_ncuhdr_root" && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
}
cf_search="$cf_search $cf_header_path_list"
- test -n "$verbose" && echo search path $cf_search
+ test -n "$verbose" && echo "search path $cf_search"
cf_save2_CPPFLAGS="$CPPFLAGS"
for cf_incdir in $cf_search
do
@@ -14607,9 +16770,9 @@ cf_search="$cf_search $cf_header_path_list"
if test -n "$cf_incdir" ; then
for cf_add_incdir in $cf_incdir
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -14630,8 +16793,8 @@ if test -n "$cf_incdir" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 14634 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 16797 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -14642,25 +16805,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:14646: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:16809: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:14649: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:14652: \"$ac_try\"") >&5
+ echo "$as_me:16812: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:16815: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:14655: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16818: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -14669,11 +16832,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:14672: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:16835: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -14691,8 +16854,8 @@ fi
curses.h
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 14695 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 16858 "configure"
#include "confdefs.h"
#include <$cf_header>
@@ -14702,10 +16865,10 @@ main (void)
#ifdef NCURSES_VERSION
-printf("%s\n", NCURSES_VERSION);
+printf("%s\\n", NCURSES_VERSION);
#else
#ifdef __NCURSES_H
-printf("old\n");
+printf("old\\n");
#else
make an error
#endif
@@ -14715,30 +16878,30 @@ printf("old\n");
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:14719: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:16882: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:14722: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:14725: \"$ac_try\"") >&5
+ echo "$as_me:16885: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:16888: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:14728: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16891: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_h2=$cf_header
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_ncurses_h2=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
if test "$cf_cv_ncurses_h2" != no ; then
cf_cv_ncurses_h2=$cf_incdir/$cf_header
- test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
+ test -n "$verbose" && echo $ECHO_N " ... found $ECHO_C" 1>&6
break
fi
test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
@@ -14746,26 +16909,26 @@ rm -f conftest.$ac_objext conftest.$ac_ext
CPPFLAGS="$cf_save2_CPPFLAGS"
test "$cf_cv_ncurses_h2" != no && break
done
- test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:14749: error: not found" >&5
+ test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:16912: error: not found" >&5
echo "$as_me: error: not found" >&2;}
{ (exit 1); exit 1; }; }
fi
-echo "$as_me:14754: result: $cf_cv_ncurses_h2" >&5
+echo "$as_me:16917: result: $cf_cv_ncurses_h2" >&5
echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
- cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
- cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
- if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
- cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
+ cf_1st_incdir=`echo "$cf_cv_ncurses_h2" | sed -e 's%/[^/]*$%%'`
+ cf_cv_ncurses_header="`basename "$cf_cv_ncurses_h2"`"
+ if test "`basename "$cf_1st_incdir"`" = "$cf_ncuhdr_root" ; then
+ cf_cv_ncurses_header="$cf_ncuhdr_root/$cf_cv_ncurses_header"
fi
if test -n "$cf_1st_incdir" ; then
for cf_add_incdir in $cf_1st_incdir
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -14786,8 +16949,8 @@ if test -n "$cf_1st_incdir" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 14790 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 16953 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -14798,25 +16961,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:14802: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:16965: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:14805: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:14808: \"$ac_try\"") >&5
+ echo "$as_me:16968: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:16971: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:14811: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:16974: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -14825,11 +16988,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:14828: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:16991: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -14846,7 +17009,7 @@ fi
# Set definitions to allow ifdef'ing for ncurses.h
-case $cf_cv_ncurses_header in
+case "$cf_cv_ncurses_header" in
(*ncurses.h)
cat >>confdefs.h <<\EOF
@@ -14856,7 +17019,7 @@ EOF
;;
esac
-case $cf_cv_ncurses_header in
+case "$cf_cv_ncurses_header" in
(ncurses/curses.h|ncurses/ncurses.h)
cat >>confdefs.h <<\EOF
@@ -14873,13 +17036,13 @@ EOF
;;
esac
-echo "$as_me:14876: checking for terminfo header" >&5
+echo "$as_me:17039: checking for terminfo header" >&5
echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
if test "${cf_cv_term_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-case ${cf_cv_ncurses_header} in
+case "${cf_cv_ncurses_header}" in
(*/ncurses.h|*/ncursesw.h)
cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
;;
@@ -14890,8 +17053,8 @@ esac
for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
do
-cat >conftest.$ac_ext <<_ACEOF
-#line 14894 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 17057 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -14900,43 +17063,43 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-int x = auto_left_margin
+int x = auto_left_margin; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:14909: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:17072: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:14912: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:14915: \"$ac_try\"") >&5
+ echo "$as_me:17075: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:17078: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:14918: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:17081: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_term_header="$cf_test"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_term_header=unknown
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
test "$cf_cv_term_header" != unknown && break
done
fi
-echo "$as_me:14934: result: $cf_cv_term_header" >&5
+echo "$as_me:17097: result: $cf_cv_term_header" >&5
echo "${ECHO_T}$cf_cv_term_header" >&6
# Set definitions to allow ifdef'ing to accommodate subdirectories
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(*term.h)
cat >>confdefs.h <<\EOF
@@ -14946,7 +17109,7 @@ EOF
;;
esac
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(ncurses/term.h)
cat >>confdefs.h <<\EOF
@@ -14969,7 +17132,7 @@ cat >>confdefs.h <<\EOF
#define NCURSES 1
EOF
-echo "$as_me:14972: checking for ncurses version" >&5
+echo "$as_me:17135: checking for ncurses version" >&5
echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
if test "${cf_cv_ncurses_version+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -14977,12 +17140,12 @@ else
cf_cv_ncurses_version=no
cf_tempfile=out$$
- rm -f $cf_tempfile
+ rm -f "$cf_tempfile"
if test "$cross_compiling" = yes; then
# This will not work if the preprocessor splits the line after the
# Autoconf token. The 'unproto' program does that.
- cat > conftest.$ac_ext <<EOF
+ cat > "conftest.$ac_ext" <<EOF
#include <${cf_cv_ncurses_header:-curses.h}>
#undef Autoconf
#ifdef NCURSES_VERSION
@@ -14995,20 +17158,20 @@ Autoconf "old"
#endif
EOF
cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
- { (eval echo "$as_me:14998: \"$cf_try\"") >&5
+ { (eval echo "$as_me:17161: \"$cf_try\"") >&5
(eval $cf_try) 2>&5
ac_status=$?
- echo "$as_me:15001: \$? = $ac_status" >&5
- (exit $ac_status); }
+ echo "$as_me:17164: \$? = $ac_status" >&5
+ (exit "$ac_status"); }
if test -f conftest.out ; then
- cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
+ cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
rm -f conftest.out
fi
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 15011 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 17174 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -15018,13 +17181,13 @@ int main(void)
FILE *fp = fopen("$cf_tempfile", "w");
#ifdef NCURSES_VERSION
# ifdef NCURSES_VERSION_PATCH
- fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
+ fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
# else
- fprintf(fp, "%s\n", NCURSES_VERSION);
+ fprintf(fp, "%s\\n", NCURSES_VERSION);
# endif
#else
# ifdef __NCURSES_H
- fprintf(fp, "old\n");
+ fprintf(fp, "old\\n");
# else
make an error
# endif
@@ -15032,30 +17195,30 @@ int main(void)
${cf_cv_main_return:-return}(0);
}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:15036: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:17199: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15039: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:15041: \"$ac_try\"") >&5
+ echo "$as_me:17202: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:17204: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15044: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:17207: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_version=`cat $cf_tempfile`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
- rm -f $cf_tempfile
+ rm -f "$cf_tempfile"
fi
-echo "$as_me:15058: result: $cf_cv_ncurses_version" >&5
+echo "$as_me:17221: result: $cf_cv_ncurses_version" >&5
echo "${ECHO_T}$cf_cv_ncurses_version" >&6
test "$cf_cv_ncurses_version" = no ||
cat >>confdefs.h <<\EOF
@@ -15068,15 +17231,15 @@ cf_nculib_root=$cf_cv_screen
# to link gpm.
cf_ncurses_LIBS=""
cf_ncurses_SAVE="$LIBS"
-echo "$as_me:15071: checking for Gpm_Open in -lgpm" >&5
+echo "$as_me:17234: checking for Gpm_Open in -lgpm" >&5
echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lgpm $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 15079 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 17242 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -15094,39 +17257,39 @@ Gpm_Open ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:15098: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:17261: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15101: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:15104: \"$ac_try\"") >&5
+ echo "$as_me:17264: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:17267: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15107: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:17270: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_gpm_Gpm_Open=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_gpm_Gpm_Open=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:15118: result: $ac_cv_lib_gpm_Gpm_Open" >&5
+echo "$as_me:17281: result: $ac_cv_lib_gpm_Gpm_Open" >&5
echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
-if test $ac_cv_lib_gpm_Gpm_Open = yes; then
- echo "$as_me:15121: checking for initscr in -lgpm" >&5
+if test "$ac_cv_lib_gpm_Gpm_Open" = yes; then
+ echo "$as_me:17284: checking for initscr in -lgpm" >&5
echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
if test "${ac_cv_lib_gpm_initscr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lgpm $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 15129 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 17292 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -15144,30 +17307,30 @@ initscr ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:15148: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:17311: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15151: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:15154: \"$ac_try\"") >&5
+ echo "$as_me:17314: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:17317: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15157: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:17320: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_gpm_initscr=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_gpm_initscr=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:15168: result: $ac_cv_lib_gpm_initscr" >&5
+echo "$as_me:17331: result: $ac_cv_lib_gpm_initscr" >&5
echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
-if test $ac_cv_lib_gpm_initscr = yes; then
+if test "$ac_cv_lib_gpm_initscr" = yes; then
LIBS="$cf_ncurses_SAVE"
else
cf_ncurses_LIBS="-lgpm"
@@ -15175,20 +17338,20 @@ fi
fi
-case $host_os in
+case "$host_os" in
(freebsd*)
# This is only necessary if you are linking against an obsolete
# version of ncurses (but it should do no harm, since it's static).
if test "$cf_nculib_root" = ncurses ; then
- echo "$as_me:15183: checking for tgoto in -lmytinfo" >&5
+ echo "$as_me:17346: checking for tgoto in -lmytinfo" >&5
echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lmytinfo $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 15191 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 17354 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -15206,30 +17369,30 @@ tgoto ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:15210: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:17373: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15213: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:15216: \"$ac_try\"") >&5
+ echo "$as_me:17376: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:17379: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15219: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:17382: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_mytinfo_tgoto=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_mytinfo_tgoto=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:15230: result: $ac_cv_lib_mytinfo_tgoto" >&5
+echo "$as_me:17393: result: $ac_cv_lib_mytinfo_tgoto" >&5
echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
-if test $ac_cv_lib_mytinfo_tgoto = yes; then
+if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
fi
@@ -15237,113 +17400,113 @@ fi
;;
esac
-cf_add_libs="$cf_ncurses_LIBS"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
-if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
+if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
then
-cf_add_libs="-l$cf_nculib_root"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
else
- eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
+ eval 'cf_cv_have_lib_'"$cf_nculib_root"'=no'
cf_libdir=""
- echo "$as_me:15279: checking for initscr" >&5
+ echo "$as_me:17442: checking for initscr" >&5
echo $ECHO_N "checking for initscr... $ECHO_C" >&6
if test "${ac_cv_func_initscr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 15285 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 17448 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char initscr (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define initscr autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef initscr
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char initscr ();
-char (*f) ();
+char initscr (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_initscr) || defined (__stub___initscr)
-choke me
-#else
-f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for initscr
#endif
+ return initscr ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:15316: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:17479: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15319: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:15322: \"$ac_try\"") >&5
+ echo "$as_me:17482: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:17485: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15325: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:17488: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_initscr=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_initscr=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:15335: result: $ac_cv_func_initscr" >&5
+echo "$as_me:17498: result: $ac_cv_func_initscr" >&5
echo "${ECHO_T}$ac_cv_func_initscr" >&6
-if test $ac_cv_func_initscr = yes; then
- eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
+if test "$ac_cv_func_initscr" = yes; then
+ eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
else
cf_save_LIBS="$LIBS"
- echo "$as_me:15342: checking for initscr in -l$cf_nculib_root" >&5
+ echo "$as_me:17505: checking for initscr in -l$cf_nculib_root" >&5
echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
LIBS="-l$cf_nculib_root $LIBS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 15346 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 17509 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
@@ -15354,26 +17517,26 @@ initscr()
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:15358: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:17521: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15361: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:15364: \"$ac_try\"") >&5
+ echo "$as_me:17524: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:17527: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15367: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- echo "$as_me:15369: result: yes" >&5
+ echo "$as_me:17530: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ echo "$as_me:17532: result: yes" >&5
echo "${ECHO_T}yes" >&6
- eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
+ eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-echo "$as_me:15376: result: no" >&5
+cat "conftest.$ac_ext" >&5
+echo "$as_me:17539: result: no" >&5
echo "${ECHO_T}no" >&6
cf_search=
@@ -15381,7 +17544,7 @@ cf_library_path_list=""
if test -n "${LDFLAGS}${LIBS}" ; then
for cf_library_path in $LDFLAGS $LIBS
do
- case $cf_library_path in
+ case "$cf_library_path" in
(-L*)
cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
@@ -15389,11 +17552,11 @@ test "x$cf_library_path" != "xNONE" && \
test -d "$cf_library_path" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
- test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
- test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
- test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
- test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
- test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
+ test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
+ test -d "$cf_library_path/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
+ test -d "$cf_library_path/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
+ test -d "$cf_library_path/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
+ test -d "$cf_library_path/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
}
cf_library_path_list="$cf_library_path_list $cf_search"
@@ -15408,11 +17571,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
- test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
- test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
- test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
- test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
- test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
+ test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
+ test -d "$prefix/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
+ test -d "$prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
+ test -d "$prefix/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
+ test -d "$prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
}
for cf_subdir_prefix in \
@@ -15426,13 +17589,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
- test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
- test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
- test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
- test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
+ test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
+ test -d "$cf_subdir_prefix/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
+ test -d "$cf_subdir_prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
+ test -d "$cf_subdir_prefix/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
+ test -d "$cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
}
done
@@ -15441,11 +17604,11 @@ cf_search="$cf_library_path_list $cf_search"
for cf_libdir in $cf_search
do
- echo "$as_me:15444: checking for -l$cf_nculib_root in $cf_libdir" >&5
+ echo "$as_me:17607: checking for -l$cf_nculib_root in $cf_libdir" >&5
echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 15448 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 17611 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
@@ -15456,41 +17619,41 @@ initscr()
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:15460: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:17623: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15463: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:15466: \"$ac_try\"") >&5
+ echo "$as_me:17626: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:17629: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15469: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- echo "$as_me:15471: result: yes" >&5
+ echo "$as_me:17632: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ echo "$as_me:17634: result: yes" >&5
echo "${ECHO_T}yes" >&6
- eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
+ eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-echo "$as_me:15478: result: no" >&5
+cat "conftest.$ac_ext" >&5
+echo "$as_me:17641: result: no" >&5
echo "${ECHO_T}no" >&6
LIBS="$cf_save_LIBS"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
done
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
+eval 'cf_found_library="$cf_cv_have_lib_'"$cf_nculib_root"\"
-if test $cf_found_library = no ; then
- { { echo "$as_me:15493: error: Cannot link $cf_nculib_root library" >&5
+if test "$cf_found_library" = no ; then
+ { { echo "$as_me:17656: error: Cannot link $cf_nculib_root library" >&5
echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -15498,49 +17661,49 @@ fi
fi
if test -n "$cf_ncurses_LIBS" ; then
- echo "$as_me:15501: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
+ echo "$as_me:17664: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
cf_ncurses_SAVE="$LIBS"
for p in $cf_ncurses_LIBS ; do
- q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
+ q=`echo "$LIBS" | sed -e "s%$p %%" -e "s%$p$%%"`
if test "$q" != "$LIBS" ; then
LIBS="$q"
fi
done
- cat >conftest.$ac_ext <<_ACEOF
-#line 15511 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 17674 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
main (void)
{
-initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
+initscr(); mousemask(0,0); tigetstr((char *)0);
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:15523: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:17686: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15526: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:15529: \"$ac_try\"") >&5
+ echo "$as_me:17689: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:17692: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15532: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- echo "$as_me:15534: result: yes" >&5
+ echo "$as_me:17695: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ echo "$as_me:17697: result: yes" >&5
echo "${ECHO_T}yes" >&6
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-echo "$as_me:15539: result: no" >&5
+cat "conftest.$ac_ext" >&5
+echo "$as_me:17702: result: no" >&5
echo "${ECHO_T}no" >&6
LIBS="$cf_ncurses_SAVE"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
@@ -15561,39 +17724,50 @@ cf_ncuconfig_root=$cf_cv_screen
cf_have_ncuconfig=no
if test "x${PKG_CONFIG:=none}" != xnone; then
- echo "$as_me:15564: checking pkg-config for $cf_ncuconfig_root" >&5
+ echo "$as_me:17727: checking pkg-config for $cf_ncuconfig_root" >&5
echo $ECHO_N "checking pkg-config for $cf_ncuconfig_root... $ECHO_C" >&6
if "$PKG_CONFIG" --exists $cf_ncuconfig_root ; then
- echo "$as_me:15567: result: yes" >&5
+ echo "$as_me:17730: result: yes" >&5
echo "${ECHO_T}yes" >&6
- echo "$as_me:15570: checking if the $cf_ncuconfig_root package files work" >&5
+ echo "$as_me:17733: checking if the $cf_ncuconfig_root package files work" >&5
echo $ECHO_N "checking if the $cf_ncuconfig_root package files work... $ECHO_C" >&6
cf_have_ncuconfig=unknown
+ cf_save_CFLAGS="$CFLAGS"
cf_save_CPPFLAGS="$CPPFLAGS"
cf_save_LIBS="$LIBS"
+ cf_pkg_cflags="`$PKG_CONFIG --cflags $cf_ncuconfig_root`"
+ cf_pkg_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
+
+ # while -W for passing linker flags is prevalent, it is not "standard".
+ # At least one wrapper for c89/c99 (in Apple's xcode) has its own
+ # incompatible _and_ non-standard -W option which gives an error. Work
+ # around that pitfall.
+ case "x${CC}@@${cf_pkg_libs}@${cf_pkg_cflags}" in
+ (x*c[89]9@@*-W*)
+
cf_fix_cppflags=no
cf_new_cflags=
cf_new_cppflags=
cf_new_extra_cppflags=
-for cf_add_cflags in `$PKG_CONFIG --cflags $cf_ncuconfig_root`
+for cf_add_cflags in $cf_pkg_cflags
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -15612,7 +17786,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -15642,7 +17816,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -15672,83 +17846,271 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="`$PKG_CONFIG --libs $cf_ncuconfig_root`"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
+ cf_add_1lib=
+ break
+ fi
+ done
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
+done
+LIBS="$cf_add_libs"
+
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 17866 "configure"
+#include "confdefs.h"
+#include <${cf_cv_ncurses_header:-curses.h}>
+int
+main (void)
+{
+initscr(); mousemask(0,0); tigetstr((char *)0);
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:17878: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:17881: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:17884: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:17887: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ if test "$cross_compiling" = yes; then
+ cf_test_ncuconfig=maybe
+else
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 17893 "configure"
+#include "confdefs.h"
+#include <${cf_cv_ncurses_header:-curses.h}>
+ int main(void)
+ { char *xx = curses_version(); return (xx == 0); }
+_ACEOF
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:17900: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:17903: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:17905: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:17908: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ cf_test_ncuconfig=yes
+else
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+cf_test_ncuconfig=no
+fi
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
+fi
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+cf_test_ncuconfig=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+
+ CFLAGS="$cf_save_CFLAGS"
+ CPPFLAGS="$cf_save_CPPFLAGS"
+ LIBS="$cf_save_LIBS"
+
+ if test "x$cf_test_ncuconfig" != xyes; then
+ cf_temp=`echo "x$cf_pkg_cflags" | sed -e s/^x// -e 's/-W[^ ]*//g'`
+ cf_pkg_cflags="$cf_temp"
+ cf_temp=`echo "x$cf_pkg_libs" | sed -e s/^x// -e 's/-W[^ ]*//g'`
+ cf_pkg_libs="$cf_temp"
+ fi
+ ;;
+ esac
+
+cf_fix_cppflags=no
+cf_new_cflags=
+cf_new_cppflags=
+cf_new_extra_cppflags=
+
+for cf_add_cflags in $cf_pkg_cflags
do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+case "$cf_fix_cppflags" in
+(no)
+ case "$cf_add_cflags" in
+ (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
+ case "$cf_add_cflags" in
+ (-D*)
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+
+ test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
+ && test -z "${cf_tst_cflags}" \
+ && cf_fix_cppflags=yes
+
+ if test "$cf_fix_cppflags" = yes ; then
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ continue
+ elif test "${cf_tst_cflags}" = "\"'" ; then
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ continue
+ fi
+ ;;
+ esac
+ case "$CPPFLAGS" in
+ (*$cf_add_cflags)
+ ;;
+ (*)
+ case "$cf_add_cflags" in
+ (-D*)
+ cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
+
+CPPFLAGS=`echo "$CPPFLAGS" | \
+ sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
+ -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
+
+ ;;
+ esac
+
+ test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
+ cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
+
+ ;;
+ esac
+ ;;
+ (*)
+
+ test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
+ cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
+
+ ;;
+ esac
+ ;;
+(yes)
+
+ test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
+ cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
+
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
+
+ test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
+ && test -z "${cf_tst_cflags}" \
+ && cf_fix_cppflags=no
+ ;;
+esac
+done
+
+if test -n "$cf_new_cflags" ; then
+
+ test -n "$CFLAGS" && CFLAGS="$CFLAGS "
+ CFLAGS="${CFLAGS}$cf_new_cflags"
+
+fi
+
+if test -n "$cf_new_cppflags" ; then
+
+ test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
+ CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
+
+fi
+
+if test -n "$cf_new_extra_cppflags" ; then
+
+ test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
+ EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
+
+fi
+
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkg_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
- cat >conftest.$ac_ext <<_ACEOF
-#line 15692 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 18054 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
main (void)
{
-initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
+initscr(); mousemask(0,0); tigetstr((char *)0);
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:15704: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:18066: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15707: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:15710: \"$ac_try\"") >&5
+ echo "$as_me:18069: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:18072: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15713: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:18075: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
if test "$cross_compiling" = yes; then
cf_have_ncuconfig=maybe
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 15719 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 18081 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int main(void)
{ char *xx = curses_version(); return (xx == 0); }
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:15726: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:18088: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:15729: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:15731: \"$ac_try\"") >&5
+ echo "$as_me:18091: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:18093: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15734: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:18096: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_have_ncuconfig=yes
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_ncuconfig=no
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_ncuconfig=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:15751: result: $cf_have_ncuconfig" >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ echo "$as_me:18113: result: $cf_have_ncuconfig" >&5
echo "${ECHO_T}$cf_have_ncuconfig" >&6
test "$cf_have_ncuconfig" = maybe && cf_have_ncuconfig=yes
if test "$cf_have_ncuconfig" != "yes"
@@ -15764,13 +18126,13 @@ EOF
NCURSES_CONFIG_PKG=$cf_ncuconfig_root
-echo "$as_me:15767: checking for terminfo header" >&5
+echo "$as_me:18129: checking for terminfo header" >&5
echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
if test "${cf_cv_term_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-case ${cf_cv_ncurses_header} in
+case "${cf_cv_ncurses_header}" in
(*/ncurses.h|*/ncursesw.h)
cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
;;
@@ -15781,8 +18143,8 @@ esac
for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
do
-cat >conftest.$ac_ext <<_ACEOF
-#line 15785 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 18147 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -15791,43 +18153,43 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-int x = auto_left_margin
+int x = auto_left_margin; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:15800: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:18162: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:15803: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:15806: \"$ac_try\"") >&5
+ echo "$as_me:18165: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:18168: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:15809: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:18171: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_term_header="$cf_test"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_term_header=unknown
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
test "$cf_cv_term_header" != unknown && break
done
fi
-echo "$as_me:15825: result: $cf_cv_term_header" >&5
+echo "$as_me:18187: result: $cf_cv_term_header" >&5
echo "${ECHO_T}$cf_cv_term_header" >&6
# Set definitions to allow ifdef'ing to accommodate subdirectories
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(*term.h)
cat >>confdefs.h <<\EOF
@@ -15837,7 +18199,7 @@ EOF
;;
esac
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(ncurses/term.h)
cat >>confdefs.h <<\EOF
@@ -15857,7 +18219,7 @@ esac
fi
else
- echo "$as_me:15860: result: no" >&5
+ echo "$as_me:18222: result: no" >&5
echo "${ECHO_T}no" >&6
NCURSES_CONFIG_PKG=none
fi
@@ -15873,7 +18235,7 @@ if test -n "$ac_tool_prefix"; then
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:15876: checking for $ac_word" >&5
+echo "$as_me:18238: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_NCURSES_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -15888,7 +18250,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_NCURSES_CONFIG="$ac_tool_prefix$ac_prog"
-echo "$as_me:15891: found $ac_dir/$ac_word" >&5
+echo "$as_me:18253: found $ac_dir/$ac_word" >&5
break
done
@@ -15896,10 +18258,10 @@ fi
fi
NCURSES_CONFIG=$ac_cv_prog_NCURSES_CONFIG
if test -n "$NCURSES_CONFIG"; then
- echo "$as_me:15899: result: $NCURSES_CONFIG" >&5
+ echo "$as_me:18261: result: $NCURSES_CONFIG" >&5
echo "${ECHO_T}$NCURSES_CONFIG" >&6
else
- echo "$as_me:15902: result: no" >&5
+ echo "$as_me:18264: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -15912,7 +18274,7 @@ if test -z "$NCURSES_CONFIG"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:15915: checking for $ac_word" >&5
+echo "$as_me:18277: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_NCURSES_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -15927,7 +18289,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_NCURSES_CONFIG="$ac_prog"
-echo "$as_me:15930: found $ac_dir/$ac_word" >&5
+echo "$as_me:18292: found $ac_dir/$ac_word" >&5
break
done
@@ -15935,10 +18297,10 @@ fi
fi
ac_ct_NCURSES_CONFIG=$ac_cv_prog_ac_ct_NCURSES_CONFIG
if test -n "$ac_ct_NCURSES_CONFIG"; then
- echo "$as_me:15938: result: $ac_ct_NCURSES_CONFIG" >&5
+ echo "$as_me:18300: result: $ac_ct_NCURSES_CONFIG" >&5
echo "${ECHO_T}$ac_ct_NCURSES_CONFIG" >&6
else
- echo "$as_me:15941: result: no" >&5
+ echo "$as_me:18303: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -15958,19 +18320,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in `$NCURSES_CONFIG --cflags`
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -15989,7 +18351,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -16019,7 +18381,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -16049,25 +18411,25 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="`$NCURSES_CONFIG --libs`"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in `$NCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
# even with config script, some packages use no-override for curses.h
-echo "$as_me:16070: checking if we have identified curses headers" >&5
+echo "$as_me:18432: checking if we have identified curses headers" >&5
echo $ECHO_N "checking if we have identified curses headers... $ECHO_C" >&6
if test "${cf_cv_ncurses_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -16078,8 +18440,8 @@ for cf_header in \
ncurses.h $cf_cv_screen/ncurses.h \
curses.h $cf_cv_screen/curses.h
do
-cat >conftest.$ac_ext <<_ACEOF
-#line 16082 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 18444 "configure"
#include "confdefs.h"
#include <${cf_header}>
int
@@ -16090,32 +18452,32 @@ initscr(); tgoto("?", 0,0)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:16094: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:18456: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:16097: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:16100: \"$ac_try\"") >&5
+ echo "$as_me:18459: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:18462: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16103: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:18465: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_header=$cf_header; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
fi
-echo "$as_me:16114: result: $cf_cv_ncurses_header" >&5
+echo "$as_me:18476: result: $cf_cv_ncurses_header" >&5
echo "${ECHO_T}$cf_cv_ncurses_header" >&6
if test "$cf_cv_ncurses_header" = none ; then
- { { echo "$as_me:16118: error: No curses header-files found" >&5
+ { { echo "$as_me:18480: error: No curses header-files found" >&5
echo "$as_me: error: No curses header-files found" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -16125,24 +18487,24 @@ fi
for ac_header in $cf_cv_ncurses_header
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:16128: checking for $ac_header" >&5
+echo "$as_me:18490: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 16134 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 18496 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:16138: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:18500: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:16144: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:18506: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -16155,14 +18517,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:16163: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:18525: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -16180,7 +18542,7 @@ cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuv
#define $cf_nculib_ROOT 1
EOF
- cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
+ cf_cv_ncurses_version="`$NCURSES_CONFIG --version`"
else
@@ -16192,9 +18554,9 @@ test "$cf_cv_curses_dir" != "no" && { \
if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
for cf_add_incdir in $cf_cv_curses_dir/include/$cf_ncuhdr_root
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -16215,8 +18577,8 @@ if test -n "$cf_cv_curses_dir/include/$cf_ncuhdr_root" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 16219 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 18581 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -16227,25 +18589,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:16231: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:18593: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:16234: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:16237: \"$ac_try\"") >&5
+ echo "$as_me:18596: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:18599: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16240: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:18602: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -16254,11 +18616,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:16257: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:18619: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -16273,19 +18635,19 @@ fi
}
-echo "$as_me:16276: checking for $cf_ncuhdr_root header in include-path" >&5
+echo "$as_me:18638: checking for $cf_ncuhdr_root header in include-path" >&5
echo $ECHO_N "checking for $cf_ncuhdr_root header in include-path... $ECHO_C" >&6
if test "${cf_cv_ncurses_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cf_header_list="$cf_ncuhdr_root/curses.h $cf_ncuhdr_root/ncurses.h"
- ( test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw ) && cf_header_list="$cf_header_list curses.h ncurses.h"
+ { test "$cf_ncuhdr_root" = ncurses || test "$cf_ncuhdr_root" = ncursesw; } && cf_header_list="$cf_header_list curses.h ncurses.h"
for cf_header in $cf_header_list
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 16288 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 18650 "configure"
#include "confdefs.h"
#include <$cf_header>
@@ -16295,10 +18657,10 @@ main (void)
#ifdef NCURSES_VERSION
-printf("%s\n", NCURSES_VERSION);
+printf("%s\\n", NCURSES_VERSION);
#else
#ifdef __NCURSES_H
-printf("old\n");
+printf("old\\n");
#else
make an error
#endif
@@ -16308,39 +18670,39 @@ printf("old\n");
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:16312: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:18674: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:16315: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:16318: \"$ac_try\"") >&5
+ echo "$as_me:18677: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:18680: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16321: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:18683: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_h=$cf_header
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_ncurses_h=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
test "$cf_cv_ncurses_h" != no && break
done
fi
-echo "$as_me:16336: result: $cf_cv_ncurses_h" >&5
+echo "$as_me:18698: result: $cf_cv_ncurses_h" >&5
echo "${ECHO_T}$cf_cv_ncurses_h" >&6
if test "$cf_cv_ncurses_h" != no ; then
cf_cv_ncurses_header=$cf_cv_ncurses_h
else
-echo "$as_me:16343: checking for $cf_ncuhdr_root include-path" >&5
+echo "$as_me:18705: checking for $cf_ncuhdr_root include-path" >&5
echo $ECHO_N "checking for $cf_ncuhdr_root include-path... $ECHO_C" >&6
if test "${cf_cv_ncurses_h2+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -16355,7 +18717,7 @@ cf_header_path_list=""
if test -n "${CFLAGS}${CPPFLAGS}" ; then
for cf_header_path in $CPPFLAGS $CFLAGS
do
- case $cf_header_path in
+ case "$cf_header_path" in
(-I*)
cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
@@ -16363,11 +18725,11 @@ test "x$cf_header_path" != "xNONE" && \
test -d "$cf_header_path" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $cf_header_path"
- test -d $cf_header_path/include && cf_search="$cf_search $cf_header_path/include"
- test -d $cf_header_path/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
- test -d $cf_header_path/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
- test -d $cf_header_path/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
- test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
+ test -d "$cf_header_path/include" && cf_search="$cf_search $cf_header_path/include"
+ test -d "$cf_header_path/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
+ test -d "$cf_header_path/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
+ test -d "$cf_header_path/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
+ test -d "$cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
}
cf_header_path_list="$cf_header_path_list $cf_search"
@@ -16384,11 +18746,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for include-directories under $prefix"
- test -d $prefix/include && cf_search="$cf_search $prefix/include"
- test -d $prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
- test -d $prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
- test -d $prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
- test -d $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
+ test -d "$prefix/include" && cf_search="$cf_search $prefix/include"
+ test -d "$prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root"
+ test -d "$prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/include/$cf_ncuhdr_root/include"
+ test -d "$prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include"
+ test -d "$prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
}
for cf_subdir_prefix in \
@@ -16402,13 +18764,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for include-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/include && cf_search="$cf_search $cf_subdir_prefix/include"
- test -d $cf_subdir_prefix/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
- test -d $cf_subdir_prefix/include/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
- test -d $cf_subdir_prefix/$cf_ncuhdr_root/include && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
- test -d $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
+ test -d "$cf_subdir_prefix/include" && cf_search="$cf_search $cf_subdir_prefix/include"
+ test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root"
+ test -d "$cf_subdir_prefix/include/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/include/$cf_ncuhdr_root/include"
+ test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include"
+ test -d "$cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root" && cf_search="$cf_search $cf_subdir_prefix/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
}
done
@@ -16416,20 +18778,20 @@ done
test "$includedir" != NONE && \
test "$includedir" != "/usr/include" && \
test -d "$includedir" && {
- test -d $includedir && cf_search="$cf_search $includedir"
- test -d $includedir/$cf_ncuhdr_root && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
+ test -d "$includedir" && cf_search="$cf_search $includedir"
+ test -d "$includedir/$cf_ncuhdr_root" && cf_search="$cf_search $includedir/$cf_ncuhdr_root"
}
test "$oldincludedir" != NONE && \
test "$oldincludedir" != "/usr/include" && \
test -d "$oldincludedir" && {
- test -d $oldincludedir && cf_search="$cf_search $oldincludedir"
- test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
+ test -d "$oldincludedir" && cf_search="$cf_search $oldincludedir"
+ test -d "$oldincludedir/$cf_ncuhdr_root" && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
}
cf_search="$cf_search $cf_header_path_list"
- test -n "$verbose" && echo search path $cf_search
+ test -n "$verbose" && echo "search path $cf_search"
cf_save2_CPPFLAGS="$CPPFLAGS"
for cf_incdir in $cf_search
do
@@ -16437,9 +18799,9 @@ cf_search="$cf_search $cf_header_path_list"
if test -n "$cf_incdir" ; then
for cf_add_incdir in $cf_incdir
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -16460,8 +18822,8 @@ if test -n "$cf_incdir" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 16464 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 18826 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -16472,25 +18834,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:16476: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:18838: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:16479: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:16482: \"$ac_try\"") >&5
+ echo "$as_me:18841: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:18844: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16485: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:18847: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -16499,11 +18861,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:16502: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:18864: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -16521,8 +18883,8 @@ fi
curses.h
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 16525 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 18887 "configure"
#include "confdefs.h"
#include <$cf_header>
@@ -16532,10 +18894,10 @@ main (void)
#ifdef NCURSES_VERSION
-printf("%s\n", NCURSES_VERSION);
+printf("%s\\n", NCURSES_VERSION);
#else
#ifdef __NCURSES_H
-printf("old\n");
+printf("old\\n");
#else
make an error
#endif
@@ -16545,30 +18907,30 @@ printf("old\n");
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:16549: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:18911: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:16552: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:16555: \"$ac_try\"") >&5
+ echo "$as_me:18914: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:18917: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16558: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:18920: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_h2=$cf_header
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_ncurses_h2=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
if test "$cf_cv_ncurses_h2" != no ; then
cf_cv_ncurses_h2=$cf_incdir/$cf_header
- test -n "$verbose" && echo $ac_n " ... found $ac_c" 1>&6
+ test -n "$verbose" && echo $ECHO_N " ... found $ECHO_C" 1>&6
break
fi
test -n "$verbose" && echo " ... tested $cf_incdir/$cf_header" 1>&6
@@ -16576,26 +18938,26 @@ rm -f conftest.$ac_objext conftest.$ac_ext
CPPFLAGS="$cf_save2_CPPFLAGS"
test "$cf_cv_ncurses_h2" != no && break
done
- test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:16579: error: not found" >&5
+ test "$cf_cv_ncurses_h2" = no && { { echo "$as_me:18941: error: not found" >&5
echo "$as_me: error: not found" >&2;}
{ (exit 1); exit 1; }; }
fi
-echo "$as_me:16584: result: $cf_cv_ncurses_h2" >&5
+echo "$as_me:18946: result: $cf_cv_ncurses_h2" >&5
echo "${ECHO_T}$cf_cv_ncurses_h2" >&6
- cf_1st_incdir=`echo $cf_cv_ncurses_h2 | sed -e 's%/[^/]*$%%'`
- cf_cv_ncurses_header=`basename $cf_cv_ncurses_h2`
- if test `basename $cf_1st_incdir` = $cf_ncuhdr_root ; then
- cf_cv_ncurses_header=$cf_ncuhdr_root/$cf_cv_ncurses_header
+ cf_1st_incdir=`echo "$cf_cv_ncurses_h2" | sed -e 's%/[^/]*$%%'`
+ cf_cv_ncurses_header="`basename "$cf_cv_ncurses_h2"`"
+ if test "`basename "$cf_1st_incdir"`" = "$cf_ncuhdr_root" ; then
+ cf_cv_ncurses_header="$cf_ncuhdr_root/$cf_cv_ncurses_header"
fi
if test -n "$cf_1st_incdir" ; then
for cf_add_incdir in $cf_1st_incdir
do
- while test $cf_add_incdir != /usr/include
+ while test "$cf_add_incdir" != /usr/include
do
- if test -d $cf_add_incdir
+ if test -d "$cf_add_incdir"
then
cf_have_incdir=no
if test -n "$CFLAGS$CPPFLAGS" ; then
@@ -16616,8 +18978,8 @@ if test -n "$cf_1st_incdir" ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_add_incdir"
- cat >conftest.$ac_ext <<_ACEOF
-#line 16620 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 18982 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -16628,25 +18990,25 @@ printf("Hello")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:16632: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:18994: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:16635: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:16638: \"$ac_try\"") >&5
+ echo "$as_me:18997: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:19000: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16641: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:19003: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_have_incdir=yes
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS=$cf_save_CPPFLAGS
fi
fi
@@ -16655,11 +19017,11 @@ rm -f conftest.$ac_objext conftest.$ac_ext
if test "$cf_have_incdir" = no ; then
test -n "$verbose" && echo " adding $cf_add_incdir to include-path" 1>&6
-echo "${as_me:-configure}:16658: testing adding $cf_add_incdir to include-path ..." 1>&5
+echo "${as_me:-configure}:19020: testing adding $cf_add_incdir to include-path ..." 1>&5
CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
- cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
+ cf_top_incdir=`echo "$cf_add_incdir" | sed -e 's%/include/.*$%/include%'`
test "$cf_top_incdir" = "$cf_add_incdir" && break
cf_add_incdir="$cf_top_incdir"
else
@@ -16676,7 +19038,7 @@ fi
# Set definitions to allow ifdef'ing for ncurses.h
-case $cf_cv_ncurses_header in
+case "$cf_cv_ncurses_header" in
(*ncurses.h)
cat >>confdefs.h <<\EOF
@@ -16686,7 +19048,7 @@ EOF
;;
esac
-case $cf_cv_ncurses_header in
+case "$cf_cv_ncurses_header" in
(ncurses/curses.h|ncurses/ncurses.h)
cat >>confdefs.h <<\EOF
@@ -16703,13 +19065,13 @@ EOF
;;
esac
-echo "$as_me:16706: checking for terminfo header" >&5
+echo "$as_me:19068: checking for terminfo header" >&5
echo $ECHO_N "checking for terminfo header... $ECHO_C" >&6
if test "${cf_cv_term_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-case ${cf_cv_ncurses_header} in
+case "${cf_cv_ncurses_header}" in
(*/ncurses.h|*/ncursesw.h)
cf_term_header=`echo "$cf_cv_ncurses_header" | sed -e 's%ncurses[^.]*\.h$%term.h%'`
;;
@@ -16720,8 +19082,8 @@ esac
for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
do
-cat >conftest.$ac_ext <<_ACEOF
-#line 16724 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 19086 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -16730,43 +19092,43 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-int x = auto_left_margin
+int x = auto_left_margin; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:16739: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:19101: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:16742: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:16745: \"$ac_try\"") >&5
+ echo "$as_me:19104: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:19107: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16748: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:19110: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_term_header="$cf_test"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_term_header=unknown
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
test "$cf_cv_term_header" != unknown && break
done
fi
-echo "$as_me:16764: result: $cf_cv_term_header" >&5
+echo "$as_me:19126: result: $cf_cv_term_header" >&5
echo "${ECHO_T}$cf_cv_term_header" >&6
# Set definitions to allow ifdef'ing to accommodate subdirectories
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(*term.h)
cat >>confdefs.h <<\EOF
@@ -16776,7 +19138,7 @@ EOF
;;
esac
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(ncurses/term.h)
cat >>confdefs.h <<\EOF
@@ -16799,7 +19161,7 @@ cat >>confdefs.h <<\EOF
#define NCURSES 1
EOF
-echo "$as_me:16802: checking for ncurses version" >&5
+echo "$as_me:19164: checking for ncurses version" >&5
echo $ECHO_N "checking for ncurses version... $ECHO_C" >&6
if test "${cf_cv_ncurses_version+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -16807,12 +19169,12 @@ else
cf_cv_ncurses_version=no
cf_tempfile=out$$
- rm -f $cf_tempfile
+ rm -f "$cf_tempfile"
if test "$cross_compiling" = yes; then
# This will not work if the preprocessor splits the line after the
# Autoconf token. The 'unproto' program does that.
- cat > conftest.$ac_ext <<EOF
+ cat > "conftest.$ac_ext" <<EOF
#include <${cf_cv_ncurses_header:-curses.h}>
#undef Autoconf
#ifdef NCURSES_VERSION
@@ -16825,20 +19187,20 @@ Autoconf "old"
#endif
EOF
cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
- { (eval echo "$as_me:16828: \"$cf_try\"") >&5
+ { (eval echo "$as_me:19190: \"$cf_try\"") >&5
(eval $cf_try) 2>&5
ac_status=$?
- echo "$as_me:16831: \$? = $ac_status" >&5
- (exit $ac_status); }
+ echo "$as_me:19193: \$? = $ac_status" >&5
+ (exit "$ac_status"); }
if test -f conftest.out ; then
- cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
+ cf_out=`sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%' conftest.out`
test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
rm -f conftest.out
fi
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 16841 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 19203 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -16848,13 +19210,13 @@ int main(void)
FILE *fp = fopen("$cf_tempfile", "w");
#ifdef NCURSES_VERSION
# ifdef NCURSES_VERSION_PATCH
- fprintf(fp, "%s.%d\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
+ fprintf(fp, "%s.%d\\n", NCURSES_VERSION, NCURSES_VERSION_PATCH);
# else
- fprintf(fp, "%s\n", NCURSES_VERSION);
+ fprintf(fp, "%s\\n", NCURSES_VERSION);
# endif
#else
# ifdef __NCURSES_H
- fprintf(fp, "old\n");
+ fprintf(fp, "old\\n");
# else
make an error
# endif
@@ -16862,30 +19224,30 @@ int main(void)
${cf_cv_main_return:-return}(0);
}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:16866: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:19228: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:16869: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:16871: \"$ac_try\"") >&5
+ echo "$as_me:19231: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:19233: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16874: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:19236: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_ncurses_version=`cat $cf_tempfile`
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
- rm -f $cf_tempfile
+ rm -f "$cf_tempfile"
fi
-echo "$as_me:16888: result: $cf_cv_ncurses_version" >&5
+echo "$as_me:19250: result: $cf_cv_ncurses_version" >&5
echo "${ECHO_T}$cf_cv_ncurses_version" >&6
test "$cf_cv_ncurses_version" = no ||
cat >>confdefs.h <<\EOF
@@ -16898,15 +19260,15 @@ cf_nculib_root=$cf_cv_screen
# to link gpm.
cf_ncurses_LIBS=""
cf_ncurses_SAVE="$LIBS"
-echo "$as_me:16901: checking for Gpm_Open in -lgpm" >&5
+echo "$as_me:19263: checking for Gpm_Open in -lgpm" >&5
echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lgpm $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 16909 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 19271 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -16924,39 +19286,39 @@ Gpm_Open ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:16928: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:19290: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:16931: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:16934: \"$ac_try\"") >&5
+ echo "$as_me:19293: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:19296: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16937: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:19299: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_gpm_Gpm_Open=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_gpm_Gpm_Open=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:16948: result: $ac_cv_lib_gpm_Gpm_Open" >&5
+echo "$as_me:19310: result: $ac_cv_lib_gpm_Gpm_Open" >&5
echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
-if test $ac_cv_lib_gpm_Gpm_Open = yes; then
- echo "$as_me:16951: checking for initscr in -lgpm" >&5
+if test "$ac_cv_lib_gpm_Gpm_Open" = yes; then
+ echo "$as_me:19313: checking for initscr in -lgpm" >&5
echo $ECHO_N "checking for initscr in -lgpm... $ECHO_C" >&6
if test "${ac_cv_lib_gpm_initscr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lgpm $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 16959 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 19321 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -16974,30 +19336,30 @@ initscr ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:16978: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:19340: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:16981: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:16984: \"$ac_try\"") >&5
+ echo "$as_me:19343: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:19346: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:16987: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:19349: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_gpm_initscr=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_gpm_initscr=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:16998: result: $ac_cv_lib_gpm_initscr" >&5
+echo "$as_me:19360: result: $ac_cv_lib_gpm_initscr" >&5
echo "${ECHO_T}$ac_cv_lib_gpm_initscr" >&6
-if test $ac_cv_lib_gpm_initscr = yes; then
+if test "$ac_cv_lib_gpm_initscr" = yes; then
LIBS="$cf_ncurses_SAVE"
else
cf_ncurses_LIBS="-lgpm"
@@ -17005,20 +19367,20 @@ fi
fi
-case $host_os in
+case "$host_os" in
(freebsd*)
# This is only necessary if you are linking against an obsolete
# version of ncurses (but it should do no harm, since it's static).
if test "$cf_nculib_root" = ncurses ; then
- echo "$as_me:17013: checking for tgoto in -lmytinfo" >&5
+ echo "$as_me:19375: checking for tgoto in -lmytinfo" >&5
echo $ECHO_N "checking for tgoto in -lmytinfo... $ECHO_C" >&6
if test "${ac_cv_lib_mytinfo_tgoto+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lmytinfo $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 17021 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 19383 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -17036,30 +19398,30 @@ tgoto ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17040: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:19402: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:17043: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17046: \"$ac_try\"") >&5
+ echo "$as_me:19405: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:19408: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:17049: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:19411: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_mytinfo_tgoto=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_mytinfo_tgoto=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:17060: result: $ac_cv_lib_mytinfo_tgoto" >&5
+echo "$as_me:19422: result: $ac_cv_lib_mytinfo_tgoto" >&5
echo "${ECHO_T}$ac_cv_lib_mytinfo_tgoto" >&6
-if test $ac_cv_lib_mytinfo_tgoto = yes; then
+if test "$ac_cv_lib_mytinfo_tgoto" = yes; then
cf_ncurses_LIBS="-lmytinfo $cf_ncurses_LIBS"
fi
@@ -17067,113 +19429,113 @@ fi
;;
esac
-cf_add_libs="$cf_ncurses_LIBS"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_ncurses_LIBS; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
-if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" )
+if test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no"
then
-cf_add_libs="-l$cf_nculib_root"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -l$cf_nculib_root; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
else
- eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
+ eval 'cf_cv_have_lib_'"$cf_nculib_root"'=no'
cf_libdir=""
- echo "$as_me:17109: checking for initscr" >&5
+ echo "$as_me:19471: checking for initscr" >&5
echo $ECHO_N "checking for initscr... $ECHO_C" >&6
if test "${ac_cv_func_initscr+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 17115 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 19477 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char initscr (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define initscr autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef initscr
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char initscr ();
-char (*f) ();
+char initscr (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_initscr) || defined (__stub___initscr)
-choke me
-#else
-f = initscr; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for initscr
#endif
+ return initscr ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17146: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:19508: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:17149: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17152: \"$ac_try\"") >&5
+ echo "$as_me:19511: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:19514: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:17155: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:19517: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_initscr=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_initscr=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:17165: result: $ac_cv_func_initscr" >&5
+echo "$as_me:19527: result: $ac_cv_func_initscr" >&5
echo "${ECHO_T}$ac_cv_func_initscr" >&6
-if test $ac_cv_func_initscr = yes; then
- eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
+if test "$ac_cv_func_initscr" = yes; then
+ eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
else
cf_save_LIBS="$LIBS"
- echo "$as_me:17172: checking for initscr in -l$cf_nculib_root" >&5
+ echo "$as_me:19534: checking for initscr in -l$cf_nculib_root" >&5
echo $ECHO_N "checking for initscr in -l$cf_nculib_root... $ECHO_C" >&6
LIBS="-l$cf_nculib_root $LIBS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 17176 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 19538 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
@@ -17184,26 +19546,26 @@ initscr()
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17188: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:19550: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:17191: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17194: \"$ac_try\"") >&5
+ echo "$as_me:19553: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:19556: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:17197: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- echo "$as_me:17199: result: yes" >&5
+ echo "$as_me:19559: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ echo "$as_me:19561: result: yes" >&5
echo "${ECHO_T}yes" >&6
- eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
+ eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-echo "$as_me:17206: result: no" >&5
+cat "conftest.$ac_ext" >&5
+echo "$as_me:19568: result: no" >&5
echo "${ECHO_T}no" >&6
cf_search=
@@ -17211,7 +19573,7 @@ cf_library_path_list=""
if test -n "${LDFLAGS}${LIBS}" ; then
for cf_library_path in $LDFLAGS $LIBS
do
- case $cf_library_path in
+ case "$cf_library_path" in
(-L*)
cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
@@ -17219,11 +19581,11 @@ test "x$cf_library_path" != "xNONE" && \
test -d "$cf_library_path" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $cf_library_path"
- test -d $cf_library_path/lib && cf_search="$cf_search $cf_library_path/lib"
- test -d $cf_library_path/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
- test -d $cf_library_path/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
- test -d $cf_library_path/$cf_nculib_root/lib && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
- test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
+ test -d "$cf_library_path/lib" && cf_search="$cf_search $cf_library_path/lib"
+ test -d "$cf_library_path/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
+ test -d "$cf_library_path/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
+ test -d "$cf_library_path/$cf_nculib_root/lib" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
+ test -d "$cf_library_path/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
}
cf_library_path_list="$cf_library_path_list $cf_search"
@@ -17238,11 +19600,11 @@ test "x$prefix" != "xNONE" && \
test -d "$prefix" && \
{
test -n "$verbose" && echo " ... testing for lib-directories under $prefix"
- test -d $prefix/lib && cf_search="$cf_search $prefix/lib"
- test -d $prefix/lib/$cf_nculib_root && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
- test -d $prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
- test -d $prefix/$cf_nculib_root/lib && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
- test -d $prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
+ test -d "$prefix/lib" && cf_search="$cf_search $prefix/lib"
+ test -d "$prefix/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/lib/$cf_nculib_root"
+ test -d "$prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/lib/$cf_nculib_root/lib"
+ test -d "$prefix/$cf_nculib_root/lib" && cf_search="$cf_search $prefix/$cf_nculib_root/lib"
+ test -d "$prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $prefix/$cf_nculib_root/lib/$cf_nculib_root"
}
for cf_subdir_prefix in \
@@ -17256,13 +19618,13 @@ do
test "x$cf_subdir_prefix" != "x$prefix" && \
test -d "$cf_subdir_prefix" && \
-(test -z "$prefix" || test x$prefix = xNONE || test "x$cf_subdir_prefix" != "x$prefix") && {
+{ test -z "$prefix" || test "x$prefix" = xNONE || test "x$cf_subdir_prefix" != "x$prefix"; } && {
test -n "$verbose" && echo " ... testing for lib-directories under $cf_subdir_prefix"
- test -d $cf_subdir_prefix/lib && cf_search="$cf_search $cf_subdir_prefix/lib"
- test -d $cf_subdir_prefix/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
- test -d $cf_subdir_prefix/lib/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
- test -d $cf_subdir_prefix/$cf_nculib_root/lib && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
- test -d $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
+ test -d "$cf_subdir_prefix/lib" && cf_search="$cf_search $cf_subdir_prefix/lib"
+ test -d "$cf_subdir_prefix/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root"
+ test -d "$cf_subdir_prefix/lib/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/lib/$cf_nculib_root/lib"
+ test -d "$cf_subdir_prefix/$cf_nculib_root/lib" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib"
+ test -d "$cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root" && cf_search="$cf_search $cf_subdir_prefix/$cf_nculib_root/lib/$cf_nculib_root"
}
done
@@ -17271,11 +19633,11 @@ cf_search="$cf_library_path_list $cf_search"
for cf_libdir in $cf_search
do
- echo "$as_me:17274: checking for -l$cf_nculib_root in $cf_libdir" >&5
+ echo "$as_me:19636: checking for -l$cf_nculib_root in $cf_libdir" >&5
echo $ECHO_N "checking for -l$cf_nculib_root in $cf_libdir... $ECHO_C" >&6
LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 17278 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 19640 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
@@ -17286,41 +19648,41 @@ initscr()
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17290: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:19652: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:17293: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17296: \"$ac_try\"") >&5
+ echo "$as_me:19655: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:19658: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:17299: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- echo "$as_me:17301: result: yes" >&5
+ echo "$as_me:19661: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ echo "$as_me:19663: result: yes" >&5
echo "${ECHO_T}yes" >&6
- eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
+ eval 'cf_cv_have_lib_'"$cf_nculib_root"'=yes'
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-echo "$as_me:17308: result: no" >&5
+cat "conftest.$ac_ext" >&5
+echo "$as_me:19670: result: no" >&5
echo "${ECHO_T}no" >&6
LIBS="$cf_save_LIBS"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
done
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-eval 'cf_found_library=$cf_cv_have_lib_'$cf_nculib_root
+eval 'cf_found_library="$cf_cv_have_lib_'"$cf_nculib_root"\"
-if test $cf_found_library = no ; then
- { { echo "$as_me:17323: error: Cannot link $cf_nculib_root library" >&5
+if test "$cf_found_library" = no ; then
+ { { echo "$as_me:19685: error: Cannot link $cf_nculib_root library" >&5
echo "$as_me: error: Cannot link $cf_nculib_root library" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -17328,49 +19690,49 @@ fi
fi
if test -n "$cf_ncurses_LIBS" ; then
- echo "$as_me:17331: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
+ echo "$as_me:19693: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
echo $ECHO_N "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS... $ECHO_C" >&6
cf_ncurses_SAVE="$LIBS"
for p in $cf_ncurses_LIBS ; do
- q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
+ q=`echo "$LIBS" | sed -e "s%$p %%" -e "s%$p$%%"`
if test "$q" != "$LIBS" ; then
LIBS="$q"
fi
done
- cat >conftest.$ac_ext <<_ACEOF
-#line 17341 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 19703 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
main (void)
{
-initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
+initscr(); mousemask(0,0); tigetstr((char *)0);
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17353: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:19715: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:17356: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17359: \"$ac_try\"") >&5
+ echo "$as_me:19718: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:19721: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:17362: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- echo "$as_me:17364: result: yes" >&5
+ echo "$as_me:19724: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ echo "$as_me:19726: result: yes" >&5
echo "${ECHO_T}yes" >&6
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-echo "$as_me:17369: result: no" >&5
+cat "conftest.$ac_ext" >&5
+echo "$as_me:19731: result: no" >&5
echo "${ECHO_T}no" >&6
LIBS="$cf_ncurses_SAVE"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
cf_nculib_ROOT=`echo "HAVE_LIB$cf_nculib_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
@@ -17386,1083 +19748,10 @@ fi
;;
(pdcurses)
- echo "$as_me:17389: checking for X" >&5
-echo $ECHO_N "checking for X... $ECHO_C" >&6
-
-# Check whether --with-x or --without-x was given.
-if test "${with_x+set}" = set; then
- withval="$with_x"
-
-fi;
-# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
-if test "x$with_x" = xno; then
- # The user explicitly disabled X.
- have_x=disabled
-else
- if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
- # Both variables are already set.
- have_x=yes
- else
- if test "${ac_cv_have_x+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- # One or both of the vars are not set, and there is no cached value.
-ac_x_includes=no ac_x_libraries=no
-rm -fr conftest.dir
-if mkdir conftest.dir; then
- cd conftest.dir
- # Make sure to not put "make" in the Imakefile rules, since we grep it out.
- cat >Imakefile <<'EOF'
-acfindx:
- @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
-EOF
- if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
- # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
- eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
- # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
- for ac_extension in a so sl dylib dll; do
- if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
- test -f $ac_im_libdir/libX11.$ac_extension; then
- ac_im_usrlibdir=$ac_im_libdir; break
- fi
- done
- # Screen out bogus values from the imake configuration. They are
- # bogus both because they are the default anyway, and because
- # using them would break gcc on systems where it needs fixed includes.
- case $ac_im_incroot in
- /usr/include) ;;
- *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
- esac
- case $ac_im_usrlibdir in
- /usr/lib | /lib) ;;
- *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
- esac
- fi
- cd ..
- rm -fr conftest.dir
-fi
-
-# Standard set of common directories for X headers.
-# Check X11 before X11Rn because it is often a symlink to the current release.
-ac_x_header_dirs='
-/usr/X11/include
-/usr/X11R6/include
-/usr/X11R5/include
-/usr/X11R4/include
-
-/usr/include/X11
-/usr/include/X11R6
-/usr/include/X11R5
-/usr/include/X11R4
-
-/usr/local/X11/include
-/usr/local/X11R6/include
-/usr/local/X11R5/include
-/usr/local/X11R4/include
-
-/usr/local/include/X11
-/usr/local/include/X11R6
-/usr/local/include/X11R5
-/usr/local/include/X11R4
-
-/usr/X386/include
-/usr/x386/include
-/usr/XFree86/include/X11
-
-/usr/include
-/usr/local/include
-/usr/unsupported/include
-/usr/athena/include
-/usr/local/x11r5/include
-/usr/lpp/Xamples/include
-
-/usr/openwin/include
-/usr/openwin/share/include'
-
-if test "$ac_x_includes" = no; then
- # Guess where to find include files, by looking for Intrinsic.h.
- # First, try using that file with no special directory specified.
- cat >conftest.$ac_ext <<_ACEOF
-#line 17486 "configure"
-#include "confdefs.h"
-#include <X11/Intrinsic.h>
-_ACEOF
-if { (eval echo "$as_me:17490: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
- ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:17496: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
- if test -s conftest.err; then
- ac_cpp_err=$ac_c_preproc_warn_flag
- else
- ac_cpp_err=
- fi
-else
- ac_cpp_err=yes
-fi
-if test -z "$ac_cpp_err"; then
- # We can compile using X headers with no special include directory.
-ac_x_includes=
-else
- echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
- for ac_dir in $ac_x_header_dirs; do
- if test -r "$ac_dir/X11/Intrinsic.h"; then
- ac_x_includes=$ac_dir
- break
- fi
-done
-fi
-rm -f conftest.err conftest.$ac_ext
-fi # $ac_x_includes = no
-
-if test "$ac_x_libraries" = no; then
- # Check for the libraries.
- # See if we find them without any special options.
- # Don't add to $LIBS permanently.
- ac_save_LIBS=$LIBS
- LIBS="-lXt $LIBS"
- cat >conftest.$ac_ext <<_ACEOF
-#line 17529 "configure"
-#include "confdefs.h"
-#include <X11/Intrinsic.h>
-int
-main (void)
-{
-XtMalloc (0)
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17541: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:17544: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17547: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:17550: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- LIBS=$ac_save_LIBS
-# We can link X programs with no special library path.
-ac_x_libraries=
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-LIBS=$ac_save_LIBS
-for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
-do
- # Don't even attempt the hair of trying to link an X program!
- for ac_extension in a so sl dylib dll; do
- if test -r $ac_dir/libXt.$ac_extension; then
- ac_x_libraries=$ac_dir
- break 2
- fi
- done
-done
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-fi # $ac_x_libraries = no
-
-if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
- # Didn't find X anywhere. Cache the known absence of X.
- ac_cv_have_x="have_x=no"
-else
- # Record where we found X for the cache.
- ac_cv_have_x="have_x=yes \
- ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
-fi
-fi
-
- fi
- eval "$ac_cv_have_x"
-fi # $with_x != no
-
-if test "$have_x" != yes; then
- echo "$as_me:17588: result: $have_x" >&5
-echo "${ECHO_T}$have_x" >&6
- no_x=yes
-else
- # If each of the values was on the command line, it overrides each guess.
- test "x$x_includes" = xNONE && x_includes=$ac_x_includes
- test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
- # Update the cache value to reflect the command line values.
- ac_cv_have_x="have_x=yes \
- ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
- echo "$as_me:17598: result: libraries $x_libraries, headers $x_includes" >&5
-echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
-fi
-
-if test "$no_x" = yes; then
- # Not all programs may use this symbol, but it does not hurt to define it.
-
-cat >>confdefs.h <<\EOF
-#define X_DISPLAY_MISSING 1
-EOF
-
- X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
-else
- if test -n "$x_includes"; then
- X_CFLAGS="$X_CFLAGS -I$x_includes"
- fi
-
- # It would also be nice to do this for all -L options, not just this one.
- if test -n "$x_libraries"; then
- X_LIBS="$X_LIBS -L$x_libraries"
- # For Solaris; some versions of Sun CC require a space after -R and
- # others require no space. Words are not sufficient . . . .
- case `(uname -sr) 2>/dev/null` in
- "SunOS 5"*)
- echo "$as_me:17622: checking whether -R must be followed by a space" >&5
-echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
- ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
- cat >conftest.$ac_ext <<_ACEOF
-#line 17626 "configure"
-#include "confdefs.h"
-
-int
-main (void)
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17638: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:17641: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17644: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:17647: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_R_nospace=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_R_nospace=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- if test $ac_R_nospace = yes; then
- echo "$as_me:17657: result: no" >&5
-echo "${ECHO_T}no" >&6
- X_LIBS="$X_LIBS -R$x_libraries"
- else
- LIBS="$ac_xsave_LIBS -R $x_libraries"
- cat >conftest.$ac_ext <<_ACEOF
-#line 17663 "configure"
-#include "confdefs.h"
-
-int
-main (void)
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17675: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:17678: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17681: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:17684: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_R_space=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_R_space=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- if test $ac_R_space = yes; then
- echo "$as_me:17694: result: yes" >&5
-echo "${ECHO_T}yes" >&6
- X_LIBS="$X_LIBS -R $x_libraries"
- else
- echo "$as_me:17698: result: neither works" >&5
-echo "${ECHO_T}neither works" >&6
- fi
- fi
- LIBS=$ac_xsave_LIBS
- esac
- fi
-
- # Check for system-dependent libraries X programs must link with.
- # Do this before checking for the system-independent R6 libraries
- # (-lICE), since we may need -lsocket or whatever for X linking.
-
- if test "$ISC" = yes; then
- X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
- else
- # Martyn Johnson says this is needed for Ultrix, if the X
- # libraries were built with DECnet support. And Karl Berry says
- # the Alpha needs dnet_stub (dnet does not exist).
- ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
- cat >conftest.$ac_ext <<_ACEOF
-#line 17718 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char XOpenDisplay ();
-int
-main (void)
-{
-XOpenDisplay ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17737: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:17740: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17743: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:17746: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- :
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-echo "$as_me:17752: checking for dnet_ntoa in -ldnet" >&5
-echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
-if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldnet $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 17760 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char dnet_ntoa ();
-int
-main (void)
-{
-dnet_ntoa ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17779: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:17782: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17785: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:17788: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_dnet_dnet_ntoa=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_lib_dnet_dnet_ntoa=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:17799: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
-echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
-if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
- X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
-fi
-
- if test $ac_cv_lib_dnet_dnet_ntoa = no; then
- echo "$as_me:17806: checking for dnet_ntoa in -ldnet_stub" >&5
-echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
-if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldnet_stub $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 17814 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char dnet_ntoa ();
-int
-main (void)
-{
-dnet_ntoa ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17833: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:17836: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17839: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:17842: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_dnet_stub_dnet_ntoa=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_lib_dnet_stub_dnet_ntoa=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:17853: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
-echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
-if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
- X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
-fi
-
- fi
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- LIBS="$ac_xsave_LIBS"
-
- # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
- # to get the SysV transport functions.
- # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
- # needs -lnsl.
- # The nsl library prevents programs from opening the X display
- # on Irix 5.2, according to T.E. Dickey.
- # The functions gethostbyname, getservbyname, and inet_addr are
- # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
- echo "$as_me:17872: checking for gethostbyname" >&5
-echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
-if test "${ac_cv_func_gethostbyname+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-#line 17878 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char gethostbyname (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char gethostbyname ();
-char (*f) ();
-
-int
-main (void)
-{
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
-choke me
-#else
-f = gethostbyname; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17909: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:17912: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17915: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:17918: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_func_gethostbyname=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_func_gethostbyname=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:17928: result: $ac_cv_func_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
-
- if test $ac_cv_func_gethostbyname = no; then
- echo "$as_me:17932: checking for gethostbyname in -lnsl" >&5
-echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
-if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lnsl $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 17940 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char gethostbyname ();
-int
-main (void)
-{
-gethostbyname ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:17959: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:17962: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:17965: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:17968: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_nsl_gethostbyname=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_lib_nsl_gethostbyname=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:17979: result: $ac_cv_lib_nsl_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
-if test $ac_cv_lib_nsl_gethostbyname = yes; then
- X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
-fi
-
- if test $ac_cv_lib_nsl_gethostbyname = no; then
- echo "$as_me:17986: checking for gethostbyname in -lbsd" >&5
-echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
-if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lbsd $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 17994 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char gethostbyname ();
-int
-main (void)
-{
-gethostbyname ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18013: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:18016: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18019: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:18022: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_bsd_gethostbyname=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_lib_bsd_gethostbyname=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:18033: result: $ac_cv_lib_bsd_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
-if test $ac_cv_lib_bsd_gethostbyname = yes; then
- X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
-fi
-
- fi
- fi
-
- # lieder@skyler.mavd.honeywell.com says without -lsocket,
- # socket/setsockopt and other routines are undefined under SCO ODT
- # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
- # on later versions), says Simon Leinen: it contains gethostby*
- # variants that don't use the nameserver (or something). -lsocket
- # must be given before -lnsl if both are needed. We assume that
- # if connect needs -lnsl, so does gethostbyname.
- echo "$as_me:18049: checking for connect" >&5
-echo $ECHO_N "checking for connect... $ECHO_C" >&6
-if test "${ac_cv_func_connect+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-#line 18055 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char connect (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char connect ();
-char (*f) ();
-
-int
-main (void)
-{
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_connect) || defined (__stub___connect)
-choke me
-#else
-f = connect; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18086: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:18089: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18092: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:18095: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_func_connect=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_func_connect=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:18105: result: $ac_cv_func_connect" >&5
-echo "${ECHO_T}$ac_cv_func_connect" >&6
-
- if test $ac_cv_func_connect = no; then
- echo "$as_me:18109: checking for connect in -lsocket" >&5
-echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
-if test "${ac_cv_lib_socket_connect+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 18117 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char connect ();
-int
-main (void)
-{
-connect ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18136: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:18139: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18142: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:18145: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_socket_connect=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_lib_socket_connect=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:18156: result: $ac_cv_lib_socket_connect" >&5
-echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
-if test $ac_cv_lib_socket_connect = yes; then
- X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
-fi
-
- fi
-
- # Guillermo Gomez says -lposix is necessary on A/UX.
- echo "$as_me:18165: checking for remove" >&5
-echo $ECHO_N "checking for remove... $ECHO_C" >&6
-if test "${ac_cv_func_remove+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-#line 18171 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char remove (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char remove ();
-char (*f) ();
-
-int
-main (void)
-{
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_remove) || defined (__stub___remove)
-choke me
-#else
-f = remove; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18202: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:18205: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18208: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:18211: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_func_remove=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_func_remove=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:18221: result: $ac_cv_func_remove" >&5
-echo "${ECHO_T}$ac_cv_func_remove" >&6
-
- if test $ac_cv_func_remove = no; then
- echo "$as_me:18225: checking for remove in -lposix" >&5
-echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
-if test "${ac_cv_lib_posix_remove+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lposix $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 18233 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char remove ();
-int
-main (void)
-{
-remove ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18252: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:18255: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18258: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:18261: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_posix_remove=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_lib_posix_remove=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:18272: result: $ac_cv_lib_posix_remove" >&5
-echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
-if test $ac_cv_lib_posix_remove = yes; then
- X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
-fi
-
- fi
-
- # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
- echo "$as_me:18281: checking for shmat" >&5
-echo $ECHO_N "checking for shmat... $ECHO_C" >&6
-if test "${ac_cv_func_shmat+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-#line 18287 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char shmat (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char shmat ();
-char (*f) ();
-
-int
-main (void)
-{
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_shmat) || defined (__stub___shmat)
-choke me
-#else
-f = shmat; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18318: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:18321: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18324: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:18327: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_func_shmat=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_func_shmat=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:18337: result: $ac_cv_func_shmat" >&5
-echo "${ECHO_T}$ac_cv_func_shmat" >&6
-
- if test $ac_cv_func_shmat = no; then
- echo "$as_me:18341: checking for shmat in -lipc" >&5
-echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
-if test "${ac_cv_lib_ipc_shmat+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lipc $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 18349 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char shmat ();
-int
-main (void)
-{
-shmat ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18368: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:18371: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18374: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:18377: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_ipc_shmat=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_lib_ipc_shmat=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:18388: result: $ac_cv_lib_ipc_shmat" >&5
-echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
-if test $ac_cv_lib_ipc_shmat = yes; then
- X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
-fi
-
- fi
- fi
-
- # Check for libraries that X11R6 Xt/Xaw programs need.
- ac_save_LDFLAGS=$LDFLAGS
- test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
- # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
- # check for ICE first), but we must link in the order -lSM -lICE or
- # we get undefined symbols. So assume we have SM if we have ICE.
- # These have to be linked with before -lX11, unlike the other
- # libraries we check for below, so use a different variable.
- # John Interrante, Karl Berry
- echo "$as_me:18406: checking for IceConnectionNumber in -lICE" >&5
-echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
-if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lICE $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 18414 "configure"
-#include "confdefs.h"
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char IceConnectionNumber ();
-int
-main (void)
-{
-IceConnectionNumber ();
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18433: \"$ac_link\"") >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- echo "$as_me:18436: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18439: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:18442: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- ac_cv_lib_ICE_IceConnectionNumber=yes
-else
- echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-ac_cv_lib_ICE_IceConnectionNumber=no
-fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-echo "$as_me:18453: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
-echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
-if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
- X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
-fi
-
- LDFLAGS=$ac_save_LDFLAGS
-
-fi
cf_x_athena=${cf_x_athena:-Xaw}
-echo "$as_me:18465: checking if you want to link with Xaw 3d library" >&5
+echo "$as_me:19754: checking if you want to link with Xaw 3d library" >&5
echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
withval=
@@ -18473,14 +19762,14 @@ if test "${with_Xaw3d+set}" = set; then
fi;
if test "$withval" = yes ; then
cf_x_athena=Xaw3d
- echo "$as_me:18476: result: yes" >&5
+ echo "$as_me:19765: result: yes" >&5
echo "${ECHO_T}yes" >&6
else
- echo "$as_me:18479: result: no" >&5
+ echo "$as_me:19768: result: no" >&5
echo "${ECHO_T}no" >&6
fi
-echo "$as_me:18483: checking if you want to link with Xaw 3d xft library" >&5
+echo "$as_me:19772: checking if you want to link with Xaw 3d xft library" >&5
echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6
withval=
@@ -18491,14 +19780,14 @@ if test "${with_Xaw3dxft+set}" = set; then
fi;
if test "$withval" = yes ; then
cf_x_athena=Xaw3dxft
- echo "$as_me:18494: result: yes" >&5
+ echo "$as_me:19783: result: yes" >&5
echo "${ECHO_T}yes" >&6
else
- echo "$as_me:18497: result: no" >&5
+ echo "$as_me:19786: result: no" >&5
echo "${ECHO_T}no" >&6
fi
-echo "$as_me:18501: checking if you want to link with neXT Athena library" >&5
+echo "$as_me:19790: checking if you want to link with neXT Athena library" >&5
echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
withval=
@@ -18509,14 +19798,14 @@ if test "${with_neXtaw+set}" = set; then
fi;
if test "$withval" = yes ; then
cf_x_athena=neXtaw
- echo "$as_me:18512: result: yes" >&5
+ echo "$as_me:19801: result: yes" >&5
echo "${ECHO_T}yes" >&6
else
- echo "$as_me:18515: result: no" >&5
+ echo "$as_me:19804: result: no" >&5
echo "${ECHO_T}no" >&6
fi
-echo "$as_me:18519: checking if you want to link with Athena-Plus library" >&5
+echo "$as_me:19808: checking if you want to link with Athena-Plus library" >&5
echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
withval=
@@ -18527,10 +19816,10 @@ if test "${with_XawPlus+set}" = set; then
fi;
if test "$withval" = yes ; then
cf_x_athena=XawPlus
- echo "$as_me:18530: result: yes" >&5
+ echo "$as_me:19819: result: yes" >&5
echo "${ECHO_T}yes" >&6
else
- echo "$as_me:18533: result: no" >&5
+ echo "$as_me:19822: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -18547,20 +19836,20 @@ if test "$PKG_CONFIG" != none ; then
lib${cf_x_athena}-devel
do
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists $cf_athena_pkg; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "$cf_athena_pkg"; then
test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
-echo "${as_me:-configure}:18553: testing found package $cf_athena_pkg ..." 1>&5
+echo "${as_me:-configure}:19842: testing found package $cf_athena_pkg ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags $cf_athena_pkg 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs $cf_athena_pkg 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "$cf_athena_pkg" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "$cf_athena_pkg" 2>/dev/null`"
test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:18559: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:19848: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:18563: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:19852: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -18569,19 +19858,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -18600,7 +19889,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -18630,7 +19919,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -18660,19 +19949,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -18691,20 +19980,20 @@ EOF
LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
-echo "${as_me:-configure}:18694: testing ..trimmed $LIBS ..." 1>&5
+echo "${as_me:-configure}:19983: testing ..trimmed $LIBS ..." 1>&5
;;
esac
done
-echo "$as_me:18700: checking for usable $cf_x_athena/Xmu package" >&5
+echo "$as_me:19989: checking for usable $cf_x_athena/Xmu package" >&5
echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
if test "${cf_cv_xaw_compat+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-cat >conftest.$ac_ext <<_ACEOF
-#line 18707 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 19996 "configure"
#include "confdefs.h"
#include <X11/Xmu/CharSet.h>
@@ -18713,33 +20002,34 @@ int
main (void)
{
-int check = XmuCompareISOLatin1("big", "small")
+int check = XmuCompareISOLatin1("big", "small");
+(void)check;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:18723: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:20013: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:18726: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:18729: \"$ac_try\"") >&5
+ echo "$as_me:20016: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:20019: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:18732: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:20022: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_xaw_compat=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_xaw_compat=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:18742: result: $cf_cv_xaw_compat" >&5
+echo "$as_me:20032: result: $cf_cv_xaw_compat" >&5
echo "${ECHO_T}$cf_cv_xaw_compat" >&6
if test "$cf_cv_xaw_compat" = no
@@ -18751,25 +20041,25 @@ echo "${ECHO_T}$cf_cv_xaw_compat" >&6
(*)
test -n "$verbose" && echo " work around broken package" 1>&6
-echo "${as_me:-configure}:18754: testing work around broken package ..." 1>&5
+echo "${as_me:-configure}:20044: testing work around broken package ..." 1>&5
cf_save_xmu="$LIBS"
cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xmu; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xmu"; then
test -n "$verbose" && echo " found package xmu" 1>&6
-echo "${as_me:-configure}:18762: testing found package xmu ..." 1>&5
+echo "${as_me:-configure}:20052: testing found package xmu ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags xmu 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs xmu 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xmu" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "xmu" 2>/dev/null`"
test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:18768: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:20058: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:18772: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:20062: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -18778,19 +20068,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -18809,7 +20099,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -18839,7 +20129,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -18869,19 +20159,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -18889,12 +20179,12 @@ LIBS="$cf_add_libs"
test -n "$verbose" && echo " ...before $LIBS" 1>&6
-echo "${as_me:-configure}:18892: testing ...before $LIBS ..." 1>&5
+echo "${as_me:-configure}:20182: testing ...before $LIBS ..." 1>&5
LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib $cf_pkgconfig_libs %" -e 's% % %g'`
test -n "$verbose" && echo " ...after $LIBS" 1>&6
-echo "${as_me:-configure}:18897: testing ...after $LIBS ..." 1>&5
+echo "${as_me:-configure}:20187: testing ...after $LIBS ..." 1>&5
else
cf_pkgconfig_incs=
@@ -18902,12 +20192,12 @@ else
test -n "$verbose" && echo " ...before $LIBS" 1>&6
-echo "${as_me:-configure}:18905: testing ...before $LIBS ..." 1>&5
+echo "${as_me:-configure}:20195: testing ...before $LIBS ..." 1>&5
LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%$cf_first_lib %$cf_first_lib -lXmu %" -e 's% % %g'`
test -n "$verbose" && echo " ...after $LIBS" 1>&6
-echo "${as_me:-configure}:18910: testing ...after $LIBS ..." 1>&5
+echo "${as_me:-configure}:20200: testing ...after $LIBS ..." 1>&5
fi
@@ -18918,7 +20208,7 @@ fi
LIBS=`echo "$LIBS " | sed -e 's/ / /g' -e 's%-l'"$cf_trim_lib"' %%' -e 's/ $//'`
test -n "$verbose" && echo " ..trimmed $LIBS" 1>&6
-echo "${as_me:-configure}:18921: testing ..trimmed $LIBS ..." 1>&5
+echo "${as_me:-configure}:20211: testing ..trimmed $LIBS ..." 1>&5
;;
esac
@@ -18940,20 +20230,20 @@ fi
if test -z "$cf_x_athena_lib" ; then
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists Xext; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "Xext"; then
test -n "$verbose" && echo " found package Xext" 1>&6
-echo "${as_me:-configure}:18946: testing found package Xext ..." 1>&5
+echo "${as_me:-configure}:20236: testing found package Xext ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags Xext 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs Xext 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "Xext" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "Xext" 2>/dev/null`"
test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:18952: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:20242: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:18956: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:20246: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -18962,19 +20252,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -18993,7 +20283,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -19023,7 +20313,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -19053,19 +20343,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -19074,15 +20364,15 @@ else
cf_pkgconfig_incs=
cf_pkgconfig_libs=
- echo "$as_me:19077: checking for XextCreateExtension in -lXext" >&5
+ echo "$as_me:20367: checking for XextCreateExtension in -lXext" >&5
echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lXext $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 19085 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 20375 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -19100,44 +20390,44 @@ XextCreateExtension ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:19104: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:20394: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:19107: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:19110: \"$ac_try\"") >&5
+ echo "$as_me:20397: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:20400: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:19113: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:20403: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_Xext_XextCreateExtension=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_Xext_XextCreateExtension=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:19124: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
+echo "$as_me:20414: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
-if test $ac_cv_lib_Xext_XextCreateExtension = yes; then
-
-cf_add_libs="-lXext"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+if test "$ac_cv_lib_Xext_XextCreateExtension" = yes; then
+
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lXext; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -19145,7 +20435,7 @@ fi
fi
-# OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new), and (and
+# OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new) (and
# in some cases has installed dummy files in the former, other cases replaced
# it with a link to the new location). This complicates the configure script.
# Check for that pitfall, and recover using pkg-config
@@ -19154,20 +20444,20 @@ fi
if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
then
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "x11"; then
test -n "$verbose" && echo " found package x11" 1>&6
-echo "${as_me:-configure}:19160: testing found package x11 ..." 1>&5
+echo "${as_me:-configure}:20450: testing found package x11 ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "x11" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "x11" 2>/dev/null`"
test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:19166: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:20456: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:19170: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:20460: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -19176,19 +20466,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -19207,7 +20497,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -19237,7 +20527,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -19267,19 +20557,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -19287,24 +20577,24 @@ LIBS="$cf_add_libs"
else
cf_pkgconfig_incs=
cf_pkgconfig_libs=
- { echo "$as_me:19290: WARNING: unable to find X11 library" >&5
+ { echo "$as_me:20580: WARNING: unable to find X11 library" >&5
echo "$as_me: WARNING: unable to find X11 library" >&2;}
fi
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "ice"; then
test -n "$verbose" && echo " found package ice" 1>&6
-echo "${as_me:-configure}:19297: testing found package ice ..." 1>&5
+echo "${as_me:-configure}:20587: testing found package ice ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "ice" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "ice" 2>/dev/null`"
test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:19303: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:20593: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:19307: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:20597: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -19313,19 +20603,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -19344,7 +20634,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -19374,7 +20664,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -19404,19 +20694,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -19424,24 +20714,24 @@ LIBS="$cf_add_libs"
else
cf_pkgconfig_incs=
cf_pkgconfig_libs=
- { echo "$as_me:19427: WARNING: unable to find ICE library" >&5
+ { echo "$as_me:20717: WARNING: unable to find ICE library" >&5
echo "$as_me: WARNING: unable to find ICE library" >&2;}
fi
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "sm"; then
test -n "$verbose" && echo " found package sm" 1>&6
-echo "${as_me:-configure}:19434: testing found package sm ..." 1>&5
+echo "${as_me:-configure}:20724: testing found package sm ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "sm" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "sm" 2>/dev/null`"
test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:19440: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:20730: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:19444: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:20734: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -19450,19 +20740,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -19481,7 +20771,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -19511,7 +20801,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -19541,19 +20831,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -19561,24 +20851,24 @@ LIBS="$cf_add_libs"
else
cf_pkgconfig_incs=
cf_pkgconfig_libs=
- { echo "$as_me:19564: WARNING: unable to find SM library" >&5
+ { echo "$as_me:20854: WARNING: unable to find SM library" >&5
echo "$as_me: WARNING: unable to find SM library" >&2;}
fi
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xt"; then
test -n "$verbose" && echo " found package xt" 1>&6
-echo "${as_me:-configure}:19571: testing found package xt ..." 1>&5
+echo "${as_me:-configure}:20861: testing found package xt ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xt" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "xt" 2>/dev/null`"
test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:19577: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:20867: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:19581: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:20871: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -19587,19 +20877,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -19618,7 +20908,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -19648,7 +20938,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -19678,19 +20968,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -19698,28 +20988,30 @@ LIBS="$cf_add_libs"
else
cf_pkgconfig_incs=
cf_pkgconfig_libs=
- { echo "$as_me:19701: WARNING: unable to find Xt library" >&5
+ { echo "$as_me:20991: WARNING: unable to find Xt library" >&5
echo "$as_me: WARNING: unable to find Xt library" >&2;}
fi
+else
+ LIBS="$X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
fi
cf_have_X_LIBS=no
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists xt; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xt"; then
test -n "$verbose" && echo " found package xt" 1>&6
-echo "${as_me:-configure}:19712: testing found package xt ..." 1>&5
+echo "${as_me:-configure}:21004: testing found package xt ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags xt 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs xt 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xt" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "xt" 2>/dev/null`"
test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:19718: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:21010: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:19722: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:21014: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -19728,19 +21020,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -19759,7 +21051,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -19789,7 +21081,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -19819,19 +21111,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -19840,14 +21132,14 @@ LIBS="$cf_add_libs"
;;
(*)
# we have an "xt" package, but it may omit Xt's dependency on X11
-echo "$as_me:19843: checking for usable X dependency" >&5
+echo "$as_me:21135: checking for usable X dependency" >&5
echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
if test "${cf_cv_xt_x11_compat+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-cat >conftest.$ac_ext <<_ACEOF
-#line 19850 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 21142 "configure"
#include "confdefs.h"
#include <X11/Xlib.h>
@@ -19865,50 +21157,50 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:19869: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:21161: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:19872: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:19875: \"$ac_try\"") >&5
+ echo "$as_me:21164: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:21167: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:19878: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:21170: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_xt_x11_compat=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_xt_x11_compat=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:19888: result: $cf_cv_xt_x11_compat" >&5
+echo "$as_me:21180: result: $cf_cv_xt_x11_compat" >&5
echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
if test "$cf_cv_xt_x11_compat" = no
then
test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
-echo "${as_me:-configure}:19894: testing work around broken X11 dependency ..." 1>&5
+echo "${as_me:-configure}:21186: testing work around broken X11 dependency ..." 1>&5
# 2010/11/19 - good enough until a working Xt on Xcb is delivered.
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists x11; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "x11"; then
test -n "$verbose" && echo " found package x11" 1>&6
-echo "${as_me:-configure}:19901: testing found package x11 ..." 1>&5
+echo "${as_me:-configure}:21193: testing found package x11 ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags x11 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs x11 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "x11" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "x11" 2>/dev/null`"
test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:19907: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:21199: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:19911: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:21203: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -19917,19 +21209,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -19948,7 +21240,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -19978,7 +21270,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -20008,19 +21300,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -20031,12 +21323,12 @@ else
test -n "$verbose" && echo " ...before $LIBS" 1>&6
-echo "${as_me:-configure}:20034: testing ...before $LIBS ..." 1>&5
+echo "${as_me:-configure}:21326: testing ...before $LIBS ..." 1>&5
LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt -lX11 %" -e 's% % %g'`
test -n "$verbose" && echo " ...after $LIBS" 1>&6
-echo "${as_me:-configure}:20039: testing ...after $LIBS ..." 1>&5
+echo "${as_me:-configure}:21331: testing ...after $LIBS ..." 1>&5
fi
@@ -20044,14 +21336,14 @@ fi
;;
esac
-echo "$as_me:20047: checking for usable X Toolkit package" >&5
+echo "$as_me:21339: checking for usable X Toolkit package" >&5
echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
if test "${cf_cv_xt_ice_compat+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-cat >conftest.$ac_ext <<_ACEOF
-#line 20054 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 21346 "configure"
#include "confdefs.h"
#include <X11/Shell.h>
@@ -20059,33 +21351,33 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-int num = IceConnectionNumber(0)
+int num = IceConnectionNumber(0); (void) num
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:20069: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:21361: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:20072: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:20075: \"$ac_try\"") >&5
+ echo "$as_me:21364: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:21367: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:20078: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:21370: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_xt_ice_compat=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_xt_ice_compat=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:20088: result: $cf_cv_xt_ice_compat" >&5
+echo "$as_me:21380: result: $cf_cv_xt_ice_compat" >&5
echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
if test "$cf_cv_xt_ice_compat" = no
@@ -20099,22 +21391,22 @@ echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
(*)
test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
-echo "${as_me:-configure}:20102: testing work around broken ICE dependency ..." 1>&5
+echo "${as_me:-configure}:21394: testing work around broken ICE dependency ..." 1>&5
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists ice; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "ice"; then
test -n "$verbose" && echo " found package ice" 1>&6
-echo "${as_me:-configure}:20107: testing found package ice ..." 1>&5
+echo "${as_me:-configure}:21399: testing found package ice ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags ice 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs ice 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "ice" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "ice" 2>/dev/null`"
test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:20113: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:21405: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:20117: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:21409: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -20123,19 +21415,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -20154,7 +21446,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -20184,7 +21476,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -20214,36 +21506,36 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
-if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists sm; then
+if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "sm"; then
test -n "$verbose" && echo " found package sm" 1>&6
-echo "${as_me:-configure}:20236: testing found package sm ..." 1>&5
+echo "${as_me:-configure}:21528: testing found package sm ..." 1>&5
- cf_pkgconfig_incs="`$PKG_CONFIG --cflags sm 2>/dev/null`"
- cf_pkgconfig_libs="`$PKG_CONFIG --libs sm 2>/dev/null`"
+ cf_pkgconfig_incs="`$PKG_CONFIG --cflags "sm" 2>/dev/null`"
+ cf_pkgconfig_libs="`$PKG_CONFIG --libs "sm" 2>/dev/null`"
test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
-echo "${as_me:-configure}:20242: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
+echo "${as_me:-configure}:21534: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
-echo "${as_me:-configure}:20246: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
+echo "${as_me:-configure}:21538: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
cf_fix_cppflags=no
cf_new_cflags=
@@ -20252,19 +21544,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $cf_pkgconfig_incs
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -20283,7 +21575,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -20313,7 +21605,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -20343,19 +21635,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="$cf_pkgconfig_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -20372,12 +21664,12 @@ else
test -n "$verbose" && echo " ...before $LIBS" 1>&6
-echo "${as_me:-configure}:20375: testing ...before $LIBS ..." 1>&5
+echo "${as_me:-configure}:21667: testing ...before $LIBS ..." 1>&5
LIBS=`echo "$LIBS" | sed -e "s/[ ][ ]*/ /g" -e "s%-lXt %-lXt $X_PRE_LIBS %" -e 's% % %g'`
test -n "$verbose" && echo " ...after $LIBS" 1>&6
-echo "${as_me:-configure}:20380: testing ...after $LIBS ..." 1>&5
+echo "${as_me:-configure}:21672: testing ...after $LIBS ..." 1>&5
fi
@@ -20397,7 +21689,7 @@ else
test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
-echo "${as_me:-configure}:20400: testing checking additions to CFLAGS ..." 1>&5
+echo "${as_me:-configure}:21692: testing checking additions to CFLAGS ..." 1>&5
cf_check_cflags="$CFLAGS"
cf_check_cppflags="$CPPFLAGS"
@@ -20409,19 +21701,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $X_CFLAGS
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -20440,7 +21732,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -20470,7 +21762,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -20482,7 +21774,7 @@ done
if test -n "$cf_new_cflags" ; then
test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
-echo "${as_me:-configure}:20485: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
+echo "${as_me:-configure}:21777: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
test -n "$CFLAGS" && CFLAGS="$CFLAGS "
CFLAGS="${CFLAGS}$cf_new_cflags"
@@ -20492,7 +21784,7 @@ fi
if test -n "$cf_new_cppflags" ; then
test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
-echo "${as_me:-configure}:20495: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
+echo "${as_me:-configure}:21787: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
@@ -20502,7 +21794,7 @@ fi
if test -n "$cf_new_extra_cppflags" ; then
test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
-echo "${as_me:-configure}:20505: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
+echo "${as_me:-configure}:21797: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
@@ -20510,8 +21802,8 @@ echo "${as_me:-configure}:20505: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_c
fi
if test "x$cf_check_cflags" != "x$CFLAGS" ; then
-cat >conftest.$ac_ext <<_ACEOF
-#line 20514 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 21806 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -20522,108 +21814,108 @@ printf("Hello world");
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:20526: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:21818: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:20529: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:20532: \"$ac_try\"") >&5
+ echo "$as_me:21821: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:21824: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:20535: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:21827: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
-echo "${as_me:-configure}:20543: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
+echo "${as_me:-configure}:21835: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
-echo "${as_me:-configure}:20548: testing but keeping change to \$CPPFLAGS ..." 1>&5
+echo "${as_me:-configure}:21840: testing but keeping change to \$CPPFLAGS ..." 1>&5
fi
- CFLAGS="$cf_check_flags"
+ CFLAGS="$cf_check_cflags"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
- echo "$as_me:20556: checking for XOpenDisplay" >&5
+ echo "$as_me:21848: checking for XOpenDisplay" >&5
echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
if test "${ac_cv_func_XOpenDisplay+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 20562 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 21854 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char XOpenDisplay (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define XOpenDisplay autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef XOpenDisplay
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char XOpenDisplay ();
-char (*f) ();
+char XOpenDisplay (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
-choke me
-#else
-f = XOpenDisplay; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for XOpenDisplay
#endif
+ return XOpenDisplay ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:20593: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:21885: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:20596: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:20599: \"$ac_try\"") >&5
+ echo "$as_me:21888: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:21891: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:20602: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:21894: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_XOpenDisplay=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_XOpenDisplay=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:20612: result: $ac_cv_func_XOpenDisplay" >&5
+echo "$as_me:21904: result: $ac_cv_func_XOpenDisplay" >&5
echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
-if test $ac_cv_func_XOpenDisplay = yes; then
+if test "$ac_cv_func_XOpenDisplay" = yes; then
:
else
- echo "$as_me:20618: checking for XOpenDisplay in -lX11" >&5
+ echo "$as_me:21910: checking for XOpenDisplay in -lX11" >&5
echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
-LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 20626 "configure"
+LIBS="-lX11 $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 21918 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -20641,44 +21933,44 @@ XOpenDisplay ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:20645: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:21937: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:20648: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:20651: \"$ac_try\"") >&5
+ echo "$as_me:21940: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:21943: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:20654: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:21946: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_X11_XOpenDisplay=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_X11_XOpenDisplay=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:20665: result: $ac_cv_lib_X11_XOpenDisplay" >&5
+echo "$as_me:21957: result: $ac_cv_lib_X11_XOpenDisplay" >&5
echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
-if test $ac_cv_lib_X11_XOpenDisplay = yes; then
-
-cf_add_libs="-lX11"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+if test "$ac_cv_lib_X11_XOpenDisplay" = yes; then
+
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -20686,77 +21978,77 @@ fi
fi
- echo "$as_me:20689: checking for XtAppInitialize" >&5
+ echo "$as_me:21981: checking for XtAppInitialize" >&5
echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
if test "${ac_cv_func_XtAppInitialize+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 20695 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 21987 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char XtAppInitialize (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define XtAppInitialize autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef XtAppInitialize
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char XtAppInitialize ();
-char (*f) ();
+char XtAppInitialize (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
-choke me
-#else
-f = XtAppInitialize; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for XtAppInitialize
#endif
+ return XtAppInitialize ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:20726: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:22018: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:20729: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:20732: \"$ac_try\"") >&5
+ echo "$as_me:22021: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:22024: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:20735: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:22027: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_XtAppInitialize=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_XtAppInitialize=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:20745: result: $ac_cv_func_XtAppInitialize" >&5
+echo "$as_me:22037: result: $ac_cv_func_XtAppInitialize" >&5
echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
-if test $ac_cv_func_XtAppInitialize = yes; then
+if test "$ac_cv_func_XtAppInitialize" = yes; then
:
else
- echo "$as_me:20751: checking for XtAppInitialize in -lXt" >&5
+ echo "$as_me:22043: checking for XtAppInitialize in -lXt" >&5
echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
-LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 20759 "configure"
+LIBS="-lXt $LIBS"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 22051 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -20774,45 +22066,45 @@ XtAppInitialize ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:20778: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:22070: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:20781: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:20784: \"$ac_try\"") >&5
+ echo "$as_me:22073: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:22076: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:20787: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:22079: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_Xt_XtAppInitialize=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_Xt_XtAppInitialize=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:20798: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
+echo "$as_me:22090: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
-if test $ac_cv_lib_Xt_XtAppInitialize = yes; then
+if test "$ac_cv_lib_Xt_XtAppInitialize" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_LIBXT 1
EOF
cf_have_X_LIBS=Xt
- LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
+ LIBS="-lXt $LIBS"
fi
fi
fi
-if test $cf_have_X_LIBS = no ; then
- { echo "$as_me:20815: WARNING: Unable to successfully link X Toolkit library (-lXt) with
+if test "$cf_have_X_LIBS" = no ; then
+ { echo "$as_me:22107: WARNING: Unable to successfully link X Toolkit library (-lXt) with
test program. You will have to check and add the proper libraries by hand
to makefile." >&5
echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
@@ -20830,22 +22122,37 @@ for cf_path in default \
/usr/local
do
if test -z "$cf_x_athena_inc" ; then
- cf_save="$CPPFLAGS"
+
+cf_save_LIBS_CF_X_ATHENA_CPPFLAGS="$LIBS"
+cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS="$CFLAGS"
+cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS="$CPPFLAGS"
+LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
+for cf_X_CFLAGS in $X_CFLAGS
+do
+ case "x$cf_X_CFLAGS" in
+ x-[IUD]*)
+ CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
+ ;;
+ *)
+ CFLAGS="$CFLAGS $cf_X_CFLAGS"
+ ;;
+ esac
+done
+
cf_test=X11/$cf_x_athena_root/SimpleMenu.h
- if test $cf_path != default ; then
- CPPFLAGS="$cf_save"
+ if test "$cf_path" != default ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}-I$cf_path/include"
- echo "$as_me:20841: checking for $cf_test in $cf_path" >&5
+ echo "$as_me:22148: checking for $cf_test in $cf_path" >&5
echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
else
- echo "$as_me:20844: checking for $cf_test" >&5
+ echo "$as_me:22151: checking for $cf_test" >&5
echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
fi
- cat >conftest.$ac_ext <<_ACEOF
-#line 20848 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 22155 "configure"
#include "confdefs.h"
#include <X11/Intrinsic.h>
@@ -20858,39 +22165,43 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:20862: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:22169: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:20865: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:20868: \"$ac_try\"") >&5
+ echo "$as_me:22172: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:22175: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:20871: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:22178: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_result=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_result=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- echo "$as_me:20880: result: $cf_result" >&5
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ echo "$as_me:22187: result: $cf_result" >&5
echo "${ECHO_T}$cf_result" >&6
+
+LIBS="$cf_save_LIBS_CF_X_ATHENA_CPPFLAGS"
+CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS"
+CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS"
+
if test "$cf_result" = yes ; then
- cf_x_athena_inc=$cf_path
+ test "$cf_path" = default && cf_x_athena_inc=default
+ test "$cf_path" != default && cf_x_athena_inc="$cf_path/include"
break
- else
- CPPFLAGS="$cf_save"
fi
fi
done
if test -z "$cf_x_athena_inc" ; then
- { echo "$as_me:20892: WARNING: Unable to successfully find Athena header files with test program" >&5
-echo "$as_me: WARNING: Unable to successfully find Athena header files with test program" >&2;}
+ { echo "$as_me:22203: WARNING: Unable to find Athena header files" >&5
+echo "$as_me: WARNING: Unable to find Athena header files" >&2;}
elif test "$cf_x_athena_inc" != default ; then
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
@@ -20917,52 +22228,47 @@ do
"-l$cf_lib -lXpm -lXmu" \
"-l${cf_lib}_s -lXmu_s"
do
- if test -z "$cf_x_athena_lib" ; then
- cf_save="$LIBS"
- cf_test=XawSimpleMenuAddGlobalActions
- if test $cf_path != default ; then
-
-cf_add_libs="-L$cf_path/lib $cf_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
+ test -n "$cf_x_athena_lib" && break
+
+cf_save_LIBS_CF_X_ATHENA_LIBS="$LIBS"
+cf_save_CFLAGS_CF_X_ATHENA_LIBS="$CFLAGS"
+cf_save_CPPFLAGS_CF_X_ATHENA_LIBS="$CPPFLAGS"
+LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
+for cf_X_CFLAGS in $X_CFLAGS
do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
- cf_add_1lib=
- break
- fi
- done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ case "x$cf_X_CFLAGS" in
+ x-[IUD]*)
+ CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
+ ;;
+ *)
+ CFLAGS="$CFLAGS $cf_X_CFLAGS"
+ ;;
+ esac
done
-LIBS="$cf_add_libs"
- echo "$as_me:20941: checking for $cf_libs in $cf_path" >&5
-echo $ECHO_N "checking for $cf_libs in $cf_path... $ECHO_C" >&6
- else
-
-cf_add_libs="$cf_libs"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+ cf_test=XawSimpleMenuAddGlobalActions
+ test "$cf_path" != default && cf_libs="-L$cf_path/lib $cf_libs"
+
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
- echo "$as_me:20961: checking for $cf_test in $cf_libs" >&5
+ echo "$as_me:22268: checking for $cf_test in $cf_libs" >&5
echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
- fi
- cat >conftest.$ac_ext <<_ACEOF
-#line 20965 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 22271 "configure"
#include "confdefs.h"
#include <X11/Intrinsic.h>
@@ -20977,32 +22283,35 @@ $cf_test((XtAppContext) 0)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:20981: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:22287: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:20984: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:20987: \"$ac_try\"") >&5
+ echo "$as_me:22290: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:22293: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:20990: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:22296: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_result=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_result=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
- echo "$as_me:20999: result: $cf_result" >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ echo "$as_me:22305: result: $cf_result" >&5
echo "${ECHO_T}$cf_result" >&6
- if test "$cf_result" = yes ; then
- cf_x_athena_lib="$cf_libs"
- break
- fi
- LIBS="$cf_save"
+
+LIBS="$cf_save_LIBS_CF_X_ATHENA_LIBS"
+CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_LIBS"
+CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_LIBS"
+
+ if test "$cf_result" = yes ; then
+ cf_x_athena_lib="$cf_libs"
+ break
fi
done # cf_libs
test -n "$cf_x_athena_lib" && break
@@ -21010,11 +22319,27 @@ echo "${ECHO_T}$cf_result" >&6
done
if test -z "$cf_x_athena_lib" ; then
- { { echo "$as_me:21013: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
+ { { echo "$as_me:22322: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
{ (exit 1); exit 1; }; }
fi
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in $cf_x_athena_lib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
+ cf_add_1lib=
+ break
+ fi
+ done
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
+done
+LIBS="$cf_add_libs"
+
cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
cat >>confdefs.h <<EOF
@@ -21028,7 +22353,7 @@ if test -n "$ac_tool_prefix"; then
do
# Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:21031: checking for $ac_word" >&5
+echo "$as_me:22356: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_XCURSES_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -21043,7 +22368,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_XCURSES_CONFIG="$ac_tool_prefix$ac_prog"
-echo "$as_me:21046: found $ac_dir/$ac_word" >&5
+echo "$as_me:22371: found $ac_dir/$ac_word" >&5
break
done
@@ -21051,10 +22376,10 @@ fi
fi
XCURSES_CONFIG=$ac_cv_prog_XCURSES_CONFIG
if test -n "$XCURSES_CONFIG"; then
- echo "$as_me:21054: result: $XCURSES_CONFIG" >&5
+ echo "$as_me:22379: result: $XCURSES_CONFIG" >&5
echo "${ECHO_T}$XCURSES_CONFIG" >&6
else
- echo "$as_me:21057: result: no" >&5
+ echo "$as_me:22382: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -21067,7 +22392,7 @@ if test -z "$XCURSES_CONFIG"; then
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:21070: checking for $ac_word" >&5
+echo "$as_me:22395: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_XCURSES_CONFIG+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -21082,7 +22407,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_XCURSES_CONFIG="$ac_prog"
-echo "$as_me:21085: found $ac_dir/$ac_word" >&5
+echo "$as_me:22410: found $ac_dir/$ac_word" >&5
break
done
@@ -21090,10 +22415,10 @@ fi
fi
ac_ct_XCURSES_CONFIG=$ac_cv_prog_ac_ct_XCURSES_CONFIG
if test -n "$ac_ct_XCURSES_CONFIG"; then
- echo "$as_me:21093: result: $ac_ct_XCURSES_CONFIG" >&5
+ echo "$as_me:22418: result: $ac_ct_XCURSES_CONFIG" >&5
echo "${ECHO_T}$ac_ct_XCURSES_CONFIG" >&6
else
- echo "$as_me:21096: result: no" >&5
+ echo "$as_me:22421: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -21113,19 +22438,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in `$XCURSES_CONFIG --cflags`
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -21144,7 +22469,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -21174,7 +22499,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -21204,19 +22529,19 @@ if test -n "$cf_new_extra_cppflags" ; then
fi
-cf_add_libs="`$XCURSES_CONFIG --libs`"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in `$XCURSES_CONFIG --libs`; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
@@ -21228,7 +22553,7 @@ LDFLAGS="$LDFLAGS $X_LIBS"
test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
-echo "${as_me:-configure}:21231: testing checking additions to CFLAGS ..." 1>&5
+echo "${as_me:-configure}:22556: testing checking additions to CFLAGS ..." 1>&5
cf_check_cflags="$CFLAGS"
cf_check_cppflags="$CPPFLAGS"
@@ -21240,19 +22565,19 @@ cf_new_extra_cppflags=
for cf_add_cflags in $X_CFLAGS
do
-case $cf_fix_cppflags in
+case "$cf_fix_cppflags" in
(no)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
&& cf_fix_cppflags=yes
- if test $cf_fix_cppflags = yes ; then
+ if test "$cf_fix_cppflags" = yes ; then
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
@@ -21271,7 +22596,7 @@ case $cf_fix_cppflags in
(*$cf_add_cflags)
;;
(*)
- case $cf_add_cflags in
+ case "$cf_add_cflags" in
(-D*)
cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
@@ -21301,7 +22626,7 @@ CPPFLAGS=`echo "$CPPFLAGS" | \
test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
- cf_tst_cflags=`echo ${cf_add_cflags} |sed -e 's/^[^"]*"'\''//'`
+ cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
&& test -z "${cf_tst_cflags}" \
@@ -21313,7 +22638,7 @@ done
if test -n "$cf_new_cflags" ; then
test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
-echo "${as_me:-configure}:21316: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
+echo "${as_me:-configure}:22641: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
test -n "$CFLAGS" && CFLAGS="$CFLAGS "
CFLAGS="${CFLAGS}$cf_new_cflags"
@@ -21323,7 +22648,7 @@ fi
if test -n "$cf_new_cppflags" ; then
test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
-echo "${as_me:-configure}:21326: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
+echo "${as_me:-configure}:22651: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
@@ -21333,7 +22658,7 @@ fi
if test -n "$cf_new_extra_cppflags" ; then
test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
-echo "${as_me:-configure}:21336: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
+echo "${as_me:-configure}:22661: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
@@ -21341,8 +22666,8 @@ echo "${as_me:-configure}:21336: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_c
fi
if test "x$cf_check_cflags" != "x$CFLAGS" ; then
-cat >conftest.$ac_ext <<_ACEOF
-#line 21345 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 22670 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -21353,46 +22678,46 @@ printf("Hello world");
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:21357: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:22682: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:21360: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:21363: \"$ac_try\"") >&5
+ echo "$as_me:22685: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:22688: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:21366: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:22691: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
-echo "${as_me:-configure}:21374: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
+echo "${as_me:-configure}:22699: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
-echo "${as_me:-configure}:21379: testing but keeping change to \$CPPFLAGS ..." 1>&5
+echo "${as_me:-configure}:22704: testing but keeping change to \$CPPFLAGS ..." 1>&5
fi
- CFLAGS="$cf_check_flags"
+ CFLAGS="$cf_check_cflags"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:21387: checking for XOpenDisplay in -lX11" >&5
+echo "$as_me:22712: checking for XOpenDisplay in -lX11" >&5
echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 21395 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 22720 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -21410,73 +22735,73 @@ XOpenDisplay ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:21414: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:22739: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:21417: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:21420: \"$ac_try\"") >&5
+ echo "$as_me:22742: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:22745: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:21423: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:22748: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_X11_XOpenDisplay=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_X11_XOpenDisplay=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:21434: result: $ac_cv_lib_X11_XOpenDisplay" >&5
+echo "$as_me:22759: result: $ac_cv_lib_X11_XOpenDisplay" >&5
echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
-if test $ac_cv_lib_X11_XOpenDisplay = yes; then
-
-cf_add_libs="-lX11"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+if test "$ac_cv_lib_X11_XOpenDisplay" = yes; then
+
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
fi
-echo "$as_me:21456: checking for XCurses library" >&5
+echo "$as_me:22781: checking for XCurses library" >&5
echo $ECHO_N "checking for XCurses library... $ECHO_C" >&6
if test "${cf_cv_lib_XCurses+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-cf_add_libs="-lXCurses"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lXCurses; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
-cat >conftest.$ac_ext <<_ACEOF
-#line 21479 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 22804 "configure"
#include "confdefs.h"
#include <xcurses.h>
@@ -21490,33 +22815,33 @@ XCursesExit();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:21494: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:22819: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:21497: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:21500: \"$ac_try\"") >&5
+ echo "$as_me:22822: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:22825: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:21503: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:22828: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_lib_XCurses=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_lib_XCurses=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:21514: result: $cf_cv_lib_XCurses" >&5
+echo "$as_me:22839: result: $cf_cv_lib_XCurses" >&5
echo "${ECHO_T}$cf_cv_lib_XCurses" >&6
fi
-if test $cf_cv_lib_XCurses = yes ; then
+if test "$cf_cv_lib_XCurses" = yes ; then
cat >>confdefs.h <<\EOF
#define UNIX 1
@@ -21526,24 +22851,24 @@ cat >>confdefs.h <<\EOF
#define XCURSES 1
EOF
- echo "$as_me:21529: checking for xcurses.h" >&5
+ echo "$as_me:22854: checking for xcurses.h" >&5
echo $ECHO_N "checking for xcurses.h... $ECHO_C" >&6
if test "${ac_cv_header_xcurses_h+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 21535 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 22860 "configure"
#include "confdefs.h"
#include <xcurses.h>
_ACEOF
-if { (eval echo "$as_me:21539: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:22864: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:21545: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:22870: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -21556,14 +22881,14 @@ if test -z "$ac_cpp_err"; then
ac_cv_header_xcurses_h=yes
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
ac_cv_header_xcurses_h=no
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:21564: result: $ac_cv_header_xcurses_h" >&5
+echo "$as_me:22889: result: $ac_cv_header_xcurses_h" >&5
echo "${ECHO_T}$ac_cv_header_xcurses_h" >&6
-if test $ac_cv_header_xcurses_h = yes; then
+if test "$ac_cv_header_xcurses_h" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_XCURSES 1
@@ -21572,14 +22897,14 @@ EOF
fi
else
- { { echo "$as_me:21575: error: Cannot link with XCurses" >&5
+ { { echo "$as_me:22900: error: Cannot link with XCurses" >&5
echo "$as_me: error: Cannot link with XCurses" >&2;}
{ (exit 1); exit 1; }; }
fi
;;
(*)
- { { echo "$as_me:21582: error: unexpected screen-value: $cf_cv_screen" >&5
+ { { echo "$as_me:22907: error: unexpected screen-value: $cf_cv_screen" >&5
echo "$as_me: error: unexpected screen-value: $cf_cv_screen" >&2;}
{ (exit 1); exit 1; }; }
;;
@@ -21587,15 +22912,15 @@ esac
: ${cf_nculib_root:=$cf_cv_screen}
as_ac_Lib=`echo "ac_cv_lib_$cf_nculib_root''__nc_init_pthreads" | $as_tr_sh`
-echo "$as_me:21590: checking for _nc_init_pthreads in -l$cf_nculib_root" >&5
+echo "$as_me:22915: checking for _nc_init_pthreads in -l$cf_nculib_root" >&5
echo $ECHO_N "checking for _nc_init_pthreads in -l$cf_nculib_root... $ECHO_C" >&6
if eval "test \"\${$as_ac_Lib+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-l$cf_nculib_root $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 21598 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 22923 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -21613,30 +22938,30 @@ _nc_init_pthreads ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:21617: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:22942: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:21620: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:21623: \"$ac_try\"") >&5
+ echo "$as_me:22945: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:22948: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:21626: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:22951: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_Lib=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_Lib=no"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:21637: result: `eval echo '${'$as_ac_Lib'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Lib'}'`" >&6
-if test `eval echo '${'$as_ac_Lib'}'` = yes; then
+echo "$as_me:22962: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
cf_cv_ncurses_pthreads=yes
else
cf_cv_ncurses_pthreads=no
@@ -21645,32 +22970,32 @@ fi
if test "$cf_cv_ncurses_pthreads" = yes
then
-cf_add_libs="-lpthread"
-# Filter out duplicates - this happens with badly-designed ".pc" files...
-for cf_add_1lib in $LIBS
-do
- for cf_add_2lib in $cf_add_libs
- do
- if test "x$cf_add_1lib" = "x$cf_add_2lib"
- then
+cf_add_libs="$LIBS"
+# reverse order
+cf_add_0lib=
+for cf_add_1lib in -lpthread; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
+# filter duplicates
+for cf_add_1lib in $cf_add_0lib; do
+ for cf_add_2lib in $cf_add_libs; do
+ if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
cf_add_1lib=
break
fi
done
- test -n "$cf_add_1lib" && cf_add_libs="$cf_add_libs $cf_add_1lib"
+ test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
done
LIBS="$cf_add_libs"
fi
-echo "$as_me:21666: checking if curses supports wide characters" >&5
+echo "$as_me:22991: checking if curses supports wide characters" >&5
echo $ECHO_N "checking if curses supports wide characters... $ECHO_C" >&6
if test "${cf_cv_widec_curses+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-cat >conftest.$ac_ext <<_ACEOF
-#line 21673 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 22998 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -21688,28 +23013,28 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:21692: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:23017: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:21695: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:21698: \"$ac_try\"") >&5
+ echo "$as_me:23020: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:23023: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:21701: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23026: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_widec_curses=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_widec_curses=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:21712: result: $cf_cv_widec_curses" >&5
+echo "$as_me:23037: result: $cf_cv_widec_curses" >&5
echo "${ECHO_T}$cf_cv_widec_curses" >&6
if test "$cf_cv_widec_curses" = yes ; then
@@ -21719,14 +23044,14 @@ cat >>confdefs.h <<\EOF
EOF
# This is needed on Tru64 5.0 to declare mbstate_t
- echo "$as_me:21722: checking if we must include wchar.h to declare mbstate_t" >&5
+ echo "$as_me:23047: checking if we must include wchar.h to declare mbstate_t" >&5
echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
if test "${cf_cv_widec_mbstate+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 21729 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23054 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -21734,29 +23059,29 @@ else
int
main (void)
{
-mbstate_t state
+mbstate_t state; (void)state
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:21743: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:23068: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:21746: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:21749: \"$ac_try\"") >&5
+ echo "$as_me:23071: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:23074: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:21752: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23077: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_widec_mbstate=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-cat >conftest.$ac_ext <<_ACEOF
-#line 21759 "configure"
+cat "conftest.$ac_ext" >&5
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 23084 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -21765,34 +23090,34 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-mbstate_t state
+mbstate_t state; (void)state
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:21774: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:23099: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:21777: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:21780: \"$ac_try\"") >&5
+ echo "$as_me:23102: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:23105: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:21783: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23108: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_widec_mbstate=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_widec_mbstate=unknown
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:21795: result: $cf_cv_widec_mbstate" >&5
+echo "$as_me:23120: result: $cf_cv_widec_mbstate" >&5
echo "${ECHO_T}$cf_cv_widec_mbstate" >&6
if test "$cf_cv_widec_mbstate" = yes ; then
@@ -21815,7 +23140,7 @@ fi
cf_all_widgets=yes
-echo "$as_me:21818: checking if you want extra dialogs" >&5
+echo "$as_me:23143: checking if you want extra dialogs" >&5
echo $ECHO_N "checking if you want extra dialogs... $ECHO_C" >&6
# Check whether --enable-extras or --disable-extras was given.
@@ -21825,7 +23150,7 @@ if test "${enable_extras+set}" = set; then
else
enableval=yes
fi;
-echo "$as_me:21828: result: $enableval" >&5
+echo "$as_me:23153: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
cf_all_widgets=yes
@@ -21833,7 +23158,9 @@ else
cf_all_widgets=no
fi
-echo "$as_me:21836: checking if you want config-file support" >&5
+cf_use_dialogrc=yes
+
+echo "$as_me:23163: checking if you want config-file support" >&5
echo $ECHO_N "checking if you want config-file support... $ECHO_C" >&6
# Check whether --enable-rc-file or --disable-rc-file was given.
@@ -21843,7 +23170,7 @@ if test "${enable_rc_file+set}" = set; then
else
enableval=$cf_all_widgets
fi;
-echo "$as_me:21846: result: $enableval" >&5
+echo "$as_me:23173: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS rc\$o"
@@ -21853,10 +23180,37 @@ cat >>confdefs.h <<\EOF
EOF
else
- :
+cf_use_dialogrc=no
fi
-echo "$as_me:21859: checking if you want Xdialog-style dialogs" >&5
+cf_use_dialogrc2=yes
+if test "$cf_use_dialogrc" = yes; then
+
+echo "$as_me:23189: checking if you want extra attributes in config-file" >&5
+echo $ECHO_N "checking if you want extra attributes in config-file... $ECHO_C" >&6
+
+# Check whether --enable-rc-file2 or --disable-rc-file2 was given.
+if test "${enable_rc_file2+set}" = set; then
+ enableval="$enable_rc_file2"
+
+else
+ enableval=$cf_all_widgets
+fi;
+echo "$as_me:23199: result: $enableval" >&5
+echo "${ECHO_T}$enableval" >&6
+if test "$enableval" != no ; then
+
+cat >>confdefs.h <<\EOF
+#define HAVE_RC_FILE2 1
+EOF
+
+else
+cf_use_dialogrc2=no
+fi
+
+fi
+
+echo "$as_me:23213: checking if you want Xdialog-style dialogs" >&5
echo $ECHO_N "checking if you want Xdialog-style dialogs... $ECHO_C" >&6
# Check whether --enable-Xdialog or --disable-Xdialog was given.
@@ -21866,7 +23220,7 @@ if test "${enable_Xdialog+set}" = set; then
else
enableval=$cf_all_widgets
fi;
-echo "$as_me:21869: result: $enableval" >&5
+echo "$as_me:23223: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS calendar\$o fselect\$o timebox\$o"
@@ -21879,7 +23233,7 @@ else
:
fi
-echo "$as_me:21882: checking if you want extra Xdialog-style dialogs (1.2)" >&5
+echo "$as_me:23236: checking if you want extra Xdialog-style dialogs (1.2)" >&5
echo $ECHO_N "checking if you want extra Xdialog-style dialogs (1.2)... $ECHO_C" >&6
# Check whether --enable-Xdialog2 or --disable-Xdialog2 was given.
@@ -21889,7 +23243,7 @@ if test "${enable_Xdialog2+set}" = set; then
else
enableval=$cf_all_widgets
fi;
-echo "$as_me:21892: result: $enableval" >&5
+echo "$as_me:23246: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS buildlist\$o rangebox\$o treeview\$o"
@@ -21902,7 +23256,7 @@ else
:
fi
-echo "$as_me:21905: checking if you want compatibility with whiptail options" >&5
+echo "$as_me:23259: checking if you want compatibility with whiptail options" >&5
echo $ECHO_N "checking if you want compatibility with whiptail options... $ECHO_C" >&6
# Check whether --enable-whiptail or --disable-whiptail was given.
@@ -21912,7 +23266,7 @@ if test "${enable_whiptail+set}" = set; then
else
enableval=$cf_all_widgets
fi;
-echo "$as_me:21915: result: $enableval" >&5
+echo "$as_me:23269: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
@@ -21924,7 +23278,7 @@ else
:
fi
-echo "$as_me:21927: checking if you want the form dialog" >&5
+echo "$as_me:23281: checking if you want the form dialog" >&5
echo $ECHO_N "checking if you want the form dialog... $ECHO_C" >&6
# Check whether --enable-form or --disable-form was given.
@@ -21934,7 +23288,7 @@ if test "${enable_form+set}" = set; then
else
enableval=$cf_all_widgets
fi;
-echo "$as_me:21937: result: $enableval" >&5
+echo "$as_me:23291: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS formbox\$o"
@@ -21947,7 +23301,7 @@ else
:
fi
-echo "$as_me:21950: checking if you want the gauge dialog" >&5
+echo "$as_me:23304: checking if you want the gauge dialog" >&5
echo $ECHO_N "checking if you want the gauge dialog... $ECHO_C" >&6
# Check whether --enable-gauge or --disable-gauge was given.
@@ -21957,7 +23311,7 @@ if test "${enable_gauge+set}" = set; then
else
enableval=$cf_all_widgets
fi;
-echo "$as_me:21960: result: $enableval" >&5
+echo "$as_me:23314: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS guage\$o pause\$o prgbox\$o progressbox\$o"
@@ -21970,7 +23324,7 @@ else
:
fi
-echo "$as_me:21973: checking if you want the tailbox dialog" >&5
+echo "$as_me:23327: checking if you want the tailbox dialog" >&5
echo $ECHO_N "checking if you want the tailbox dialog... $ECHO_C" >&6
# Check whether --enable-tailbox or --disable-tailbox was given.
@@ -21980,7 +23334,7 @@ if test "${enable_tailbox+set}" = set; then
else
enableval=$cf_all_widgets
fi;
-echo "$as_me:21983: result: $enableval" >&5
+echo "$as_me:23337: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS tailbox\$o"
@@ -21993,7 +23347,7 @@ else
:
fi
-echo "$as_me:21996: checking if you want the mixedform dialog" >&5
+echo "$as_me:23350: checking if you want the mixedform dialog" >&5
echo $ECHO_N "checking if you want the mixedform dialog... $ECHO_C" >&6
# Check whether --enable-mixedform or --disable-mixedform was given.
@@ -22003,7 +23357,7 @@ if test "${enable_mixedform+set}" = set; then
else
enableval=${enable_form:=$cf_all_widgets}
fi;
-echo "$as_me:22006: result: $enableval" >&5
+echo "$as_me:23360: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS mixedform\$o"
@@ -22016,7 +23370,7 @@ else
:
fi
-echo "$as_me:22019: checking if you want the mixedgauge dialog" >&5
+echo "$as_me:23373: checking if you want the mixedgauge dialog" >&5
echo $ECHO_N "checking if you want the mixedgauge dialog... $ECHO_C" >&6
# Check whether --enable-mixedgauge or --disable-mixedgauge was given.
@@ -22026,7 +23380,7 @@ if test "${enable_mixedgauge+set}" = set; then
else
enableval=$cf_all_widgets
fi;
-echo "$as_me:22029: result: $enableval" >&5
+echo "$as_me:23383: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
EXTRAOBJS="$EXTRAOBJS mixedgauge\$o"
@@ -22039,7 +23393,7 @@ else
:
fi
-echo "$as_me:22042: checking if you want the wide-curses features" >&5
+echo "$as_me:23396: checking if you want the wide-curses features" >&5
echo $ECHO_N "checking if you want the wide-curses features... $ECHO_C" >&6
# Check whether --enable-widec or --disable-widec was given.
@@ -22049,7 +23403,7 @@ if test "${enable_widec+set}" = set; then
else
enableval=$cf_cv_widec_curses
fi;
-echo "$as_me:22052: result: $enableval" >&5
+echo "$as_me:23406: result: $enableval" >&5
echo "${ECHO_T}$enableval" >&6
if test "$enableval" != no ; then
@@ -22061,13 +23415,13 @@ else
:
fi
-echo "$as_me:22064: checking for ANSI C header files" >&5
+echo "$as_me:23418: checking for ANSI C header files" >&5
echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
if test "${ac_cv_header_stdc+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 22070 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23424 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -22075,14 +23429,14 @@ else
#include <float.h>
_ACEOF
-if { (eval echo "$as_me:22078: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:23432: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:22084: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:23438: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -22095,21 +23449,21 @@ if test -z "$ac_cpp_err"; then
ac_cv_header_stdc=yes
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
ac_cv_header_stdc=no
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat >conftest.$ac_ext <<_ACEOF
-#line 22106 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23460 "configure"
#include "confdefs.h"
#include <string.h>
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "memchr" >/dev/null 2>&1; then
+ $EGREP "memchr" >/dev/null 2>&1; then
:
else
ac_cv_header_stdc=no
@@ -22120,14 +23474,14 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat >conftest.$ac_ext <<_ACEOF
-#line 22124 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23478 "configure"
#include "confdefs.h"
#include <stdlib.h>
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "free" >/dev/null 2>&1; then
+ $EGREP "free" >/dev/null 2>&1; then
:
else
ac_cv_header_stdc=no
@@ -22141,8 +23495,8 @@ if test $ac_cv_header_stdc = yes; then
if test "$cross_compiling" = yes; then
:
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 22145 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23499 "configure"
#include "confdefs.h"
#include <ctype.h>
#if ((' ' & 0x0FF) == 0x020)
@@ -22167,29 +23521,29 @@ main (void)
$ac_main_return (0);
}
_ACEOF
-rm -f conftest$ac_exeext
-if { (eval echo "$as_me:22171: \"$ac_link\"") >&5
+rm -f "conftest$ac_exeext"
+if { (eval echo "$as_me:23525: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:22174: \$? = $ac_status" >&5
- (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
- { (eval echo "$as_me:22176: \"$ac_try\"") >&5
+ echo "$as_me:23528: \$? = $ac_status" >&5
+ (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
+ { (eval echo "$as_me:23530: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22179: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23533: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
:
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_header_stdc=no
fi
-rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
fi
fi
fi
-echo "$as_me:22192: result: $ac_cv_header_stdc" >&5
+echo "$as_me:23546: result: $ac_cv_header_stdc" >&5
echo "${ECHO_T}$ac_cv_header_stdc" >&6
if test $ac_cv_header_stdc = yes; then
@@ -22199,13 +23553,13 @@ EOF
fi
-echo "$as_me:22202: checking whether time.h and sys/time.h may both be included" >&5
+echo "$as_me:23556: checking whether time.h and sys/time.h may both be included" >&5
echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
if test "${ac_cv_header_time+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 22208 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23562 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/time.h>
@@ -22220,27 +23574,27 @@ return 0;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:22224: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:23578: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:22227: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:22230: \"$ac_try\"") >&5
+ echo "$as_me:23581: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:23584: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22233: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23587: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_header_time=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_header_time=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:22243: result: $ac_cv_header_time" >&5
+echo "$as_me:23597: result: $ac_cv_header_time" >&5
echo "${ECHO_T}$ac_cv_header_time" >&6
if test $ac_cv_header_time = yes; then
@@ -22253,13 +23607,13 @@ fi
ac_header_dirent=no
for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
-echo "$as_me:22256: checking for $ac_hdr that defines DIR" >&5
+echo "$as_me:23610: checking for $ac_hdr that defines DIR" >&5
echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 22262 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23616 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <$ac_hdr>
@@ -22273,29 +23627,29 @@ return 0;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:22277: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:23631: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:22280: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:22283: \"$ac_try\"") >&5
+ echo "$as_me:23634: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:23637: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22286: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23640: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:22296: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:23650: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
EOF
@@ -22306,15 +23660,15 @@ fi
done
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
if test $ac_header_dirent = dirent.h; then
- echo "$as_me:22309: checking for opendir in -ldir" >&5
+ echo "$as_me:23663: checking for opendir in -ldir" >&5
echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
if test "${ac_cv_lib_dir_opendir+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldir $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 22317 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 23671 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -22332,43 +23686,43 @@ opendir ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:22336: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:23690: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:22339: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:22342: \"$ac_try\"") >&5
+ echo "$as_me:23693: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:23696: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22345: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23699: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_dir_opendir=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_dir_opendir=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:22356: result: $ac_cv_lib_dir_opendir" >&5
+echo "$as_me:23710: result: $ac_cv_lib_dir_opendir" >&5
echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
-if test $ac_cv_lib_dir_opendir = yes; then
+if test "$ac_cv_lib_dir_opendir" = yes; then
LIBS="$LIBS -ldir"
fi
else
- echo "$as_me:22363: checking for opendir in -lx" >&5
+ echo "$as_me:23717: checking for opendir in -lx" >&5
echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
if test "${ac_cv_lib_x_opendir+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lx $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#line 22371 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 23725 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
@@ -22386,56 +23740,56 @@ opendir ();
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:22390: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:23744: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:22393: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:22396: \"$ac_try\"") >&5
+ echo "$as_me:23747: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:23750: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22399: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23753: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_lib_x_opendir=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_lib_x_opendir=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
LIBS=$ac_check_lib_save_LIBS
fi
-echo "$as_me:22410: result: $ac_cv_lib_x_opendir" >&5
+echo "$as_me:23764: result: $ac_cv_lib_x_opendir" >&5
echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
-if test $ac_cv_lib_x_opendir = yes; then
+if test "$ac_cv_lib_x_opendir" = yes; then
LIBS="$LIBS -lx"
fi
fi
-for ac_header in search.h stdint.h unistd.h
+for ac_header in search.h stdint.h sys/param.h unistd.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:22421: checking for $ac_header" >&5
+echo "$as_me:23775: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 22427 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23781 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:22431: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:23785: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:22437: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:23791: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -22448,14 +23802,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:22456: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:23810: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -22463,7 +23817,7 @@ EOF
fi
done
-echo "$as_me:22466: checking for term.h" >&5
+echo "$as_me:23820: checking for term.h" >&5
echo $ECHO_N "checking for term.h... $ECHO_C" >&6
if test "${cf_cv_term_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -22474,17 +23828,17 @@ else
cf_header_list="term.h ncurses/term.h ncursesw/term.h"
-case ${cf_cv_ncurses_header:-curses.h} in
+case "${cf_cv_ncurses_header:-curses.h}" in
(*/*)
- cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
+ cf_header_item=`echo "${cf_cv_ncurses_header:-curses.h}" | sed -e 's%\..*%%' -e 's%/.*%/%'`term.h
cf_header_list="$cf_header_item $cf_header_list"
;;
esac
for cf_header in $cf_header_list
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 22487 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23841 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -22492,41 +23846,41 @@ do
int
main (void)
{
-WINDOW *x
+WINDOW *x; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:22501: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:23855: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:22504: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:22507: \"$ac_try\"") >&5
+ echo "$as_me:23858: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:23861: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22510: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23864: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_term_header=$cf_header
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_term_header=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(no)
# If curses is ncurses, some packagers still mess it up by trying to make
# us use GNU termcap. This handles the most common case.
for cf_header in ncurses/term.h ncursesw/term.h
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 22529 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23883 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -22538,40 +23892,40 @@ make an error
int
main (void)
{
-WINDOW *x
+WINDOW *x; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:22547: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:23901: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:22550: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:22553: \"$ac_try\"") >&5
+ echo "$as_me:23904: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:23907: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22556: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23910: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_term_header=$cf_header
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_term_header=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
;;
esac
fi
-echo "$as_me:22571: result: $cf_cv_term_header" >&5
+echo "$as_me:23925: result: $cf_cv_term_header" >&5
echo "${ECHO_T}$cf_cv_term_header" >&6
-case $cf_cv_term_header in
+case "$cf_cv_term_header" in
(term.h)
cat >>confdefs.h <<\EOF
@@ -22595,13 +23949,13 @@ EOF
;;
esac
-echo "$as_me:22598: checking return type of signal handlers" >&5
+echo "$as_me:23952: checking return type of signal handlers" >&5
echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
if test "${ac_cv_type_signal+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 22604 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 23958 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <signal.h>
@@ -22622,27 +23976,27 @@ int i;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:22626: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:23980: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:22629: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:22632: \"$ac_try\"") >&5
+ echo "$as_me:23983: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:23986: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22635: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:23989: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_type_signal=void
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_type_signal=int
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:22645: result: $ac_cv_type_signal" >&5
+echo "$as_me:23999: result: $ac_cv_type_signal" >&5
echo "${ECHO_T}$ac_cv_type_signal" >&6
cat >>confdefs.h <<EOF
@@ -22650,7 +24004,6 @@ cat >>confdefs.h <<EOF
EOF
for ac_func in \
-_nc_free_and_exit \
btowc \
mblen \
mbrlen \
@@ -22668,65 +24021,65 @@ mktime \
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:22671: checking for $ac_func" >&5
+echo "$as_me:24024: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 22677 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24030 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define $ac_func autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef $ac_func
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char $ac_func ();
-char (*f) ();
+char $ac_func (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-f = $ac_func; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for $ac_func
#endif
+ return $ac_func ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:22708: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24061: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:22711: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:22714: \"$ac_try\"") >&5
+ echo "$as_me:24064: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24067: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22717: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24070: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
eval "$as_ac_var=yes"
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
eval "$as_ac_var=no"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:22727: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
+echo "$as_me:24080: result: `eval echo '${'"$as_ac_var"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
+if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF
@@ -22734,15 +24087,15 @@ EOF
fi
done
-echo "$as_me:22737: checking definition to turn on extended curses functions" >&5
+echo "$as_me:24090: checking definition to turn on extended curses functions" >&5
echo $ECHO_N "checking definition to turn on extended curses functions... $ECHO_C" >&6
if test "${cf_cv_need_xopen_extension+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
cf_cv_need_xopen_extension=unknown
-cat >conftest.$ac_ext <<_ACEOF
-#line 22745 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 24098 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -22762,32 +24115,39 @@ main (void)
#endif
long x = winnstr(stdscr, "", 0);
int x1, y1;
- getbegyx(stdscr, y1, x1)
+#ifdef NCURSES_VERSION
+ (void)check2;
+#endif
+ getbegyx(stdscr, y1, x1);
+ (void)x;
+ (void)y1;
+ (void)x1;
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:22771: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24131: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:22774: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:22777: \"$ac_try\"") >&5
+ echo "$as_me:24134: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24137: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22780: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24140: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_need_xopen_extension=none
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
for cf_try_xopen_extension in _XOPEN_SOURCE_EXTENDED NCURSES_WIDECHAR
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 22790 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24150 "configure"
#include "confdefs.h"
#define $cf_try_xopen_extension 1
@@ -22803,39 +24163,46 @@ main (void)
#endif
long x = winnstr(stdscr, "", 0);
int x1, y1;
- getbegyx(stdscr, y1, x1)
+ getbegyx(stdscr, y1, x1);
+#ifdef NCURSES_VERSION
+ (void)check2;
+#endif
+ (void)x;
+ (void)y1;
+ (void)x1;
+
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:22812: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24179: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:22815: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:22818: \"$ac_try\"") >&5
+ echo "$as_me:24182: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24185: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22821: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24188: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_need_xopen_extension=$cf_try_xopen_extension; break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
done
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:22835: result: $cf_cv_need_xopen_extension" >&5
+echo "$as_me:24202: result: $cf_cv_need_xopen_extension" >&5
echo "${ECHO_T}$cf_cv_need_xopen_extension" >&6
-case $cf_cv_need_xopen_extension in
+case "$cf_cv_need_xopen_extension" in
(*_*)
test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
@@ -22844,7 +24211,7 @@ case $cf_cv_need_xopen_extension in
;;
esac
-echo "$as_me:22847: checking for unctrl.h" >&5
+echo "$as_me:24214: checking for unctrl.h" >&5
echo $ECHO_N "checking for unctrl.h... $ECHO_C" >&6
if test "${cf_cv_unctrl_header+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -22855,17 +24222,17 @@ else
cf_header_list="unctrl.h ncurses/unctrl.h ncursesw/unctrl.h"
-case ${cf_cv_ncurses_header:-curses.h} in
+case "${cf_cv_ncurses_header:-curses.h}" in
(*/*)
- cf_header_item=`echo ${cf_cv_ncurses_header:-curses.h} | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
+ cf_header_item=`echo "${cf_cv_ncurses_header:-curses.h}" | sed -e 's%\..*%%' -e 's%/.*%/%'`unctrl.h
cf_header_list="$cf_header_item $cf_header_list"
;;
esac
for cf_header in $cf_header_list
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 22868 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24235 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
@@ -22873,45 +24240,45 @@ do
int
main (void)
{
-WINDOW *x
+WINDOW *x; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:22882: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:24249: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:22885: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:22888: \"$ac_try\"") >&5
+ echo "$as_me:24252: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:24255: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:22891: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24258: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_unctrl_header=$cf_header
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_unctrl_header=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
done
fi
-echo "$as_me:22904: result: $cf_cv_unctrl_header" >&5
+echo "$as_me:24271: result: $cf_cv_unctrl_header" >&5
echo "${ECHO_T}$cf_cv_unctrl_header" >&6
-case $cf_cv_unctrl_header in
+case "$cf_cv_unctrl_header" in
(no)
- { echo "$as_me:22909: WARNING: unctrl.h header not found" >&5
+ { echo "$as_me:24276: WARNING: unctrl.h header not found" >&5
echo "$as_me: WARNING: unctrl.h header not found" >&2;}
;;
esac
-case $cf_cv_unctrl_header in
+case "$cf_cv_unctrl_header" in
(unctrl.h)
cat >>confdefs.h <<\EOF
@@ -22959,10 +24326,10 @@ do
cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
- echo "$as_me:22962: checking for ${cf_func}" >&5
+ echo "$as_me:24329: checking for ${cf_func}" >&5
echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
-echo "${as_me:-configure}:22965: testing ${cf_func} ..." 1>&5
+echo "${as_me:-configure}:24332: testing ${cf_func} ..." 1>&5
if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -22970,8 +24337,8 @@ else
eval cf_result='$ac_cv_func_'$cf_func
if test ".$cf_result" != ".no"; then
- cat >conftest.$ac_ext <<_ACEOF
-#line 22974 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24341 "configure"
#include "confdefs.h"
#ifdef HAVE_XCURSES
@@ -22994,7 +24361,7 @@ main (void)
#ifndef ${cf_func}
long foo = (long)(&${cf_func});
-fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
+fprintf(stderr, "testing linkage of $cf_func:%p\\n", (void *)foo);
if (foo + 1234L > 5678L)
${cf_cv_main_return:-return}(foo != 0);
#endif
@@ -23003,35 +24370,35 @@ if (foo + 1234L > 5678L)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:23007: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24374: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:23010: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:23013: \"$ac_try\"") >&5
+ echo "$as_me:24377: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24380: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23016: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24383: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_result=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_result=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
- eval 'cf_cv_func_'$cf_func'=$cf_result'
+ eval 'cf_cv_func_'$cf_func'="$cf_result"'
fi
# use the computed/retrieved cache-value:
eval 'cf_result=$cf_cv_func_'$cf_func
- echo "$as_me:23032: result: $cf_result" >&5
+ echo "$as_me:24399: result: $cf_result" >&5
echo "${ECHO_T}$cf_result" >&6
- if test $cf_result != no; then
+ if test "$cf_result" != no; then
cat >>confdefs.h <<EOF
#define HAVE_${cf_tr_func} 1
EOF
@@ -23039,65 +24406,153 @@ EOF
fi
done
-echo "$as_me:23042: checking for start_color" >&5
+for cf_func in \
+curses_exit \
+_nc_free_and_exit \
+
+do
+
+cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
+
+ echo "$as_me:24417: checking for ${cf_func}" >&5
+echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
+
+echo "${as_me:-configure}:24420: testing ${cf_func} ..." 1>&5
+
+ if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
+ eval cf_result='$ac_cv_func_'$cf_func
+ if test ".$cf_result" != ".no"; then
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24429 "configure"
+#include "confdefs.h"
+
+#ifdef HAVE_XCURSES
+#include <xcurses.h>
+char * XCursesProgramName = "test";
+#else
+#include <${cf_cv_ncurses_header:-curses.h}>
+#if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
+#include <ncursesw/term.h>
+#elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
+#include <ncurses/term.h>
+#elif defined(HAVE_TERM_H)
+#include <term.h>
+#endif
+#endif
+
+int
+main (void)
+{
+
+#ifndef ${cf_func}
+long foo = (long)(&${cf_func});
+fprintf(stderr, "testing linkage of $cf_func:%p\\n", (void *)foo);
+if (foo + 1234L > 5678L)
+ ${cf_cv_main_return:-return}(foo != 0);
+#endif
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24462: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:24465: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24468: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:24471: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ cf_result=yes
+else
+ echo "$as_me: failed program was:" >&5
+cat "conftest.$ac_ext" >&5
+cf_result=no
+fi
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
+ fi
+ eval 'cf_cv_func_'$cf_func'="$cf_result"'
+
+fi
+
+ # use the computed/retrieved cache-value:
+ eval 'cf_result=$cf_cv_func_'$cf_func
+ echo "$as_me:24487: result: $cf_result" >&5
+echo "${ECHO_T}$cf_result" >&6
+ if test "$cf_result" != no; then
+ cat >>confdefs.h <<EOF
+#define HAVE_${cf_tr_func} 1
+EOF
+
+ fi
+done
+
+echo "$as_me:24497: checking for start_color" >&5
echo $ECHO_N "checking for start_color... $ECHO_C" >&6
if test "${ac_cv_func_start_color+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23048 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24503 "configure"
#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char start_color (); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
+#define start_color autoconf_temporary
+#include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
+#undef start_color
+
#ifdef __cplusplus
extern "C"
#endif
+
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
-char start_color ();
-char (*f) ();
+char start_color (void);
int
main (void)
{
-/* The GNU C library defines this for functions which it implements
+
+/* The GNU C library defines stubs for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_start_color) || defined (__stub___start_color)
-choke me
-#else
-f = start_color; /* workaround for ICC 12.0.3 */ if (f == 0) return 1;
+#error found stub for start_color
#endif
+ return start_color ();
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:23079: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24534: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:23082: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:23085: \"$ac_try\"") >&5
+ echo "$as_me:24537: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24540: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23088: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24543: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
ac_cv_func_start_color=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
ac_cv_func_start_color=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:23098: result: $ac_cv_func_start_color" >&5
+echo "$as_me:24553: result: $ac_cv_func_start_color" >&5
echo "${ECHO_T}$ac_cv_func_start_color" >&6
-if test $ac_cv_func_start_color = yes; then
+if test "$ac_cv_func_start_color" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_COLOR 1
@@ -23105,93 +24560,93 @@ EOF
fi
-echo "$as_me:23108: checking for chtype typedef" >&5
+echo "$as_me:24563: checking for chtype typedef" >&5
echo $ECHO_N "checking for chtype typedef... $ECHO_C" >&6
if test "${cf_cv_chtype_decl+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23115 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24570 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
main (void)
{
-chtype foo
+chtype foo; (void)foo
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:23127: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:24582: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:23130: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:23133: \"$ac_try\"") >&5
+ echo "$as_me:24585: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:24588: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23136: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24591: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_chtype_decl=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_chtype_decl=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:23146: result: $cf_cv_chtype_decl" >&5
+echo "$as_me:24601: result: $cf_cv_chtype_decl" >&5
echo "${ECHO_T}$cf_cv_chtype_decl" >&6
-if test $cf_cv_chtype_decl = yes ; then
+if test "$cf_cv_chtype_decl" = yes ; then
cat >>confdefs.h <<\EOF
#define HAVE_TYPE_CHTYPE 1
EOF
- echo "$as_me:23154: checking if chtype is scalar or struct" >&5
+ echo "$as_me:24609: checking if chtype is scalar or struct" >&5
echo $ECHO_N "checking if chtype is scalar or struct... $ECHO_C" >&6
if test "${cf_cv_chtype_type+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23161 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24616 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
main (void)
{
-chtype foo; long x = foo
+static chtype foo; long x = foo; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:23173: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:24628: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:23176: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:23179: \"$ac_try\"") >&5
+ echo "$as_me:24631: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:24634: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23182: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24637: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_chtype_type=scalar
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_chtype_type=struct
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:23192: result: $cf_cv_chtype_type" >&5
+echo "$as_me:24647: result: $cf_cv_chtype_type" >&5
echo "${ECHO_T}$cf_cv_chtype_type" >&6
- if test $cf_cv_chtype_type = scalar ; then
+ if test "$cf_cv_chtype_type" = scalar ; then
cat >>confdefs.h <<\EOF
#define TYPE_CHTYPE_IS_SCALAR 1
@@ -23200,7 +24655,7 @@ EOF
fi
fi
-echo "$as_me:23203: checking for wide alternate character set array" >&5
+echo "$as_me:24658: checking for wide alternate character set array" >&5
echo $ECHO_N "checking for wide alternate character set array... $ECHO_C" >&6
if test "${cf_cv_curses_wacs_map+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -23209,8 +24664,8 @@ else
cf_cv_curses_wacs_map=unknown
for name in wacs_map _wacs_map __wacs_map _nc_wacs _wacs_char
do
- cat >conftest.$ac_ext <<_ACEOF
-#line 23213 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24668 "configure"
#include "confdefs.h"
#ifndef _XOPEN_SOURCE_EXTENDED
@@ -23220,33 +24675,33 @@ else
int
main (void)
{
-void *foo = &($name['k'])
+void *foo = &(${name}['k']); (void)foo
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:23229: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24684: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:23232: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:23235: \"$ac_try\"") >&5
+ echo "$as_me:24687: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24690: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23238: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24693: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_curses_wacs_map=$name
break
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
done
fi
-echo "$as_me:23249: result: $cf_cv_curses_wacs_map" >&5
+echo "$as_me:24704: result: $cf_cv_curses_wacs_map" >&5
echo "${ECHO_T}$cf_cv_curses_wacs_map" >&6
test "$cf_cv_curses_wacs_map" != unknown &&
@@ -23254,7 +24709,7 @@ cat >>confdefs.h <<EOF
#define CURSES_WACS_ARRAY $cf_cv_curses_wacs_map
EOF
-echo "$as_me:23257: checking for wide alternate character constants" >&5
+echo "$as_me:24712: checking for wide alternate character constants" >&5
echo $ECHO_N "checking for wide alternate character constants... $ECHO_C" >&6
if test "${cf_cv_curses_wacs_symbols+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -23263,8 +24718,8 @@ else
cf_cv_curses_wacs_symbols=no
if test "$cf_cv_curses_wacs_map" != unknown
then
- cat >conftest.$ac_ext <<_ACEOF
-#line 23267 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24722 "configure"
#include "confdefs.h"
#ifndef _XOPEN_SOURCE_EXTENDED
@@ -23275,32 +24730,32 @@ int
main (void)
{
cchar_t *foo = WACS_PLUS;
- $cf_cv_curses_wacs_map['k'] = *WACS_PLUS
+ ${cf_cv_curses_wacs_map}['k'] = *WACS_PLUS; (void)foo
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:23284: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24739: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:23287: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:23290: \"$ac_try\"") >&5
+ echo "$as_me:24742: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24745: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23293: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24748: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_curses_wacs_symbols=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23303 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24758 "configure"
#include "confdefs.h"
#ifndef _XOPEN_SOURCE_EXTENDED
@@ -23310,33 +24765,33 @@ else
int
main (void)
{
-cchar_t *foo = WACS_PLUS
+cchar_t *foo = WACS_PLUS; (void)foo
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:23319: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24774: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:23322: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:23325: \"$ac_try\"") >&5
+ echo "$as_me:24777: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24780: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23328: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24783: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_curses_wacs_symbols=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
fi
-echo "$as_me:23339: result: $cf_cv_curses_wacs_symbols" >&5
+echo "$as_me:24794: result: $cf_cv_curses_wacs_symbols" >&5
echo "${ECHO_T}$cf_cv_curses_wacs_symbols" >&6
test "$cf_cv_curses_wacs_symbols" != no &&
@@ -23349,10 +24804,10 @@ do
cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
- echo "$as_me:23352: checking for ${cf_func}" >&5
+ echo "$as_me:24807: checking for ${cf_func}" >&5
echo $ECHO_N "checking for ${cf_func}... $ECHO_C" >&6
-echo "${as_me:-configure}:23355: testing ${cf_func} ..." 1>&5
+echo "${as_me:-configure}:24810: testing ${cf_func} ..." 1>&5
if eval "test \"\${cf_cv_func_$cf_func+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -23360,8 +24815,8 @@ else
eval cf_result='$ac_cv_func_'$cf_func
if test ".$cf_result" != ".no"; then
- cat >conftest.$ac_ext <<_ACEOF
-#line 23364 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24819 "configure"
#include "confdefs.h"
#ifdef HAVE_XCURSES
@@ -23384,7 +24839,7 @@ main (void)
#ifndef ${cf_func}
long foo = (long)(&${cf_func});
-fprintf(stderr, "testing linkage of $cf_func:%p\n", (void *)foo);
+fprintf(stderr, "testing linkage of $cf_func:%p\\n", (void *)foo);
if (foo + 1234L > 5678L)
${cf_cv_main_return:-return}(foo != 0);
#endif
@@ -23393,35 +24848,35 @@ if (foo + 1234L > 5678L)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:23397: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:24852: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:23400: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:23403: \"$ac_try\"") >&5
+ echo "$as_me:24855: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:24858: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23406: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24861: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_result=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_result=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
- eval 'cf_cv_func_'$cf_func'=$cf_result'
+ eval 'cf_cv_func_'$cf_func'="$cf_result"'
fi
# use the computed/retrieved cache-value:
eval 'cf_result=$cf_cv_func_'$cf_func
- echo "$as_me:23422: result: $cf_result" >&5
+ echo "$as_me:24877: result: $cf_result" >&5
echo "${ECHO_T}$cf_result" >&6
- if test $cf_result != no; then
+ if test "$cf_result" != no; then
cat >>confdefs.h <<EOF
#define HAVE_${cf_tr_func} 1
EOF
@@ -23431,40 +24886,40 @@ done
if test "x$cf_cv_func_wgetparent" != xyes
then
- echo "$as_me:23434: checking if WINDOW has _parent member" >&5
+ echo "$as_me:24889: checking if WINDOW has _parent member" >&5
echo $ECHO_N "checking if WINDOW has _parent member... $ECHO_C" >&6
- cat >conftest.$ac_ext <<_ACEOF
-#line 23437 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24892 "configure"
#include "confdefs.h"
#include <${cf_cv_ncurses_header:-curses.h}>
int
main (void)
{
-WINDOW *p = stdscr->_parent
+WINDOW *p = stdscr->_parent; (void)p
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:23449: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:24904: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:23452: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:23455: \"$ac_try\"") >&5
+ echo "$as_me:24907: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:24910: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23458: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:24913: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_window__parent=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_window__parent=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- echo "$as_me:23467: result: $cf_window__parent" >&5
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ echo "$as_me:24922: result: $cf_window__parent" >&5
echo "${ECHO_T}$cf_window__parent" >&6
if test "$cf_window__parent" = yes
then
@@ -23479,24 +24934,24 @@ fi
for ac_header in sys/wait.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:23482: checking for $ac_header" >&5
+echo "$as_me:24937: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23488 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24943 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:23492: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:24947: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:23498: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:24953: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -23509,14 +24964,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:23517: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:24972: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -23526,7 +24981,7 @@ done
cf_wait_headers="#include <sys/types.h>
"
-if test $ac_cv_header_sys_wait_h = yes; then
+if test "$ac_cv_header_sys_wait_h" = yes; then
cf_wait_headers="$cf_wait_headers
#include <sys/wait.h>
"
@@ -23535,24 +24990,24 @@ else
for ac_header in wait.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:23538: checking for $ac_header" >&5
+echo "$as_me:24993: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23544 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 24999 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:23548: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:25003: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:23554: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:25009: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -23565,14 +25020,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:23573: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:25028: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -23583,24 +25038,24 @@ done
for ac_header in waitstatus.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:23586: checking for $ac_header" >&5
+echo "$as_me:25041: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23592 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25047 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:23596: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:25051: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:23602: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:25057: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -23613,14 +25068,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:23621: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:25076: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -23628,26 +25083,26 @@ EOF
fi
done
-if test $ac_cv_header_wait_h = yes; then
+if test "$ac_cv_header_wait_h" = yes; then
cf_wait_headers="$cf_wait_headers
#include <wait.h>
"
fi
-if test $ac_cv_header_waitstatus_h = yes; then
+if test "$ac_cv_header_waitstatus_h" = yes; then
cf_wait_headers="$cf_wait_headers
#include <waitstatus.h>
"
fi
fi
-echo "$as_me:23643: checking for union wait" >&5
+echo "$as_me:25098: checking for union wait" >&5
echo $ECHO_N "checking for union wait... $ECHO_C" >&6
if test "${cf_cv_type_unionwait+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23650 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25105 "configure"
#include "confdefs.h"
$cf_wait_headers
int
@@ -23657,32 +25112,35 @@ int x;
int y = WEXITSTATUS(x);
int z = WTERMSIG(x);
wait(&x);
+ (void)x;
+ (void)y;
+ (void)z;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:23666: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:25124: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:23669: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:23672: \"$ac_try\"") >&5
+ echo "$as_me:25127: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:25130: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23675: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25133: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_type_unionwait=no
echo compiles ok w/o union wait 1>&5
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
- cat >conftest.$ac_ext <<_ACEOF
-#line 23685 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25143 "configure"
#include "confdefs.h"
$cf_wait_headers
int
@@ -23696,53 +25154,60 @@ union wait x;
int z = WTERMSIG(x);
#endif
wait(&x);
+ (void)x;
+#ifdef WEXITSTATUS
+ (void)y;
+#endif
+#ifdef WTERMSIG
+ (void)z;
+#endif
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:23705: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:25170: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:23708: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:23711: \"$ac_try\"") >&5
+ echo "$as_me:25173: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:25176: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23714: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25179: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_type_unionwait=yes
echo compiles ok with union wait and possibly macros too 1>&5
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_type_unionwait=no
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
fi
-echo "$as_me:23729: result: $cf_cv_type_unionwait" >&5
+echo "$as_me:25194: result: $cf_cv_type_unionwait" >&5
echo "${ECHO_T}$cf_cv_type_unionwait" >&6
-test $cf_cv_type_unionwait = yes &&
+test "$cf_cv_type_unionwait" = yes &&
cat >>confdefs.h <<\EOF
#define HAVE_TYPE_UNIONWAIT 1
EOF
-if test $cf_cv_type_unionwait = yes; then
+if test "$cf_cv_type_unionwait" = yes; then
- echo "$as_me:23738: checking if union wait can be used as wait-arg" >&5
+ echo "$as_me:25203: checking if union wait can be used as wait-arg" >&5
echo $ECHO_N "checking if union wait can be used as wait-arg... $ECHO_C" >&6
if test "${cf_cv_arg_union_wait+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23745 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25210 "configure"
#include "confdefs.h"
$cf_wait_headers
int
@@ -23753,43 +25218,43 @@ union wait x; wait(&x)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:23757: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:25222: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:23760: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:23763: \"$ac_try\"") >&5
+ echo "$as_me:25225: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:25228: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23766: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25231: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_arg_union_wait=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_arg_union_wait=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
- echo "$as_me:23778: result: $cf_cv_arg_union_wait" >&5
+ echo "$as_me:25243: result: $cf_cv_arg_union_wait" >&5
echo "${ECHO_T}$cf_cv_arg_union_wait" >&6
- test $cf_cv_arg_union_wait = yes &&
+ test "$cf_cv_arg_union_wait" = yes &&
cat >>confdefs.h <<\EOF
#define WAIT_USES_UNION 1
EOF
- echo "$as_me:23785: checking if union wait can be used as waitpid-arg" >&5
+ echo "$as_me:25250: checking if union wait can be used as waitpid-arg" >&5
echo $ECHO_N "checking if union wait can be used as waitpid-arg... $ECHO_C" >&6
if test "${cf_cv_arg_union_waitpid+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23792 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25257 "configure"
#include "confdefs.h"
$cf_wait_headers
int
@@ -23800,45 +25265,45 @@ union wait x; waitpid(0, &x, 0)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:23804: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:25269: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:23807: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:23810: \"$ac_try\"") >&5
+ echo "$as_me:25272: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:25275: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23813: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25278: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_arg_union_waitpid=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_arg_union_waitpid=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
- echo "$as_me:23825: result: $cf_cv_arg_union_waitpid" >&5
+ echo "$as_me:25290: result: $cf_cv_arg_union_waitpid" >&5
echo "${ECHO_T}$cf_cv_arg_union_waitpid" >&6
- test $cf_cv_arg_union_waitpid = yes &&
+ test "$cf_cv_arg_union_waitpid" = yes &&
cat >>confdefs.h <<\EOF
#define WAITPID_USES_UNION 1
EOF
fi
-echo "$as_me:23834: checking if we must include wchar.h to declare mbstate_t" >&5
+echo "$as_me:25299: checking if we must include wchar.h to declare mbstate_t" >&5
echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
if test "${cf_cv_mbstate_t+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
-cat >conftest.$ac_ext <<_ACEOF
-#line 23841 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 25306 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -23849,29 +25314,29 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-mbstate_t state
+mbstate_t state; (void)state
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:23858: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:25323: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:23861: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:23864: \"$ac_try\"") >&5
+ echo "$as_me:25326: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:25329: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23867: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25332: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_mbstate_t=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
-cat >conftest.$ac_ext <<_ACEOF
-#line 23874 "configure"
+cat "conftest.$ac_ext" >&5
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 25339 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -23883,34 +25348,34 @@ cat >conftest.$ac_ext <<_ACEOF
int
main (void)
{
-mbstate_t value
+mbstate_t value; (void)value
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:23892: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:25357: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:23895: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:23898: \"$ac_try\"") >&5
+ echo "$as_me:25360: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:25363: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:23901: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25366: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_mbstate_t=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_mbstate_t=unknown
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:23913: result: $cf_cv_mbstate_t" >&5
+echo "$as_me:25378: result: $cf_cv_mbstate_t" >&5
echo "${ECHO_T}$cf_cv_mbstate_t" >&6
if test "$cf_cv_mbstate_t" = yes ; then
@@ -23938,24 +25403,24 @@ sys/termio.h \
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-echo "$as_me:23941: checking for $ac_header" >&5
+echo "$as_me:25406: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 23947 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25412 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
-if { (eval echo "$as_me:23951: \"$ac_cpp conftest.$ac_ext\"") >&5
- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+if { (eval echo "$as_me:25416: \"$ac_cpp "conftest.$ac_ext"\"") >&5
+ (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
ac_status=$?
- egrep -v '^ *\+' conftest.er1 >conftest.err
+ $EGREP -v '^ *\+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:23957: \$? = $ac_status" >&5
- (exit $ac_status); } >/dev/null; then
+ echo "$as_me:25422: \$? = $ac_status" >&5
+ (exit "$ac_status"); } >/dev/null; then
if test -s conftest.err; then
ac_cpp_err=$ac_c_preproc_warn_flag
else
@@ -23968,14 +25433,14 @@ if test -z "$ac_cpp_err"; then
eval "$as_ac_Header=yes"
else
echo "$as_me: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ cat "conftest.$ac_ext" >&5
eval "$as_ac_Header=no"
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err "conftest.$ac_ext"
fi
-echo "$as_me:23976: result: `eval echo '${'$as_ac_Header'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+echo "$as_me:25441: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
+echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
+if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF
@@ -23990,39 +25455,39 @@ if test "$ac_cv_header_termios_h" = yes ; then
(*) termios_bad=maybe ;;
esac
if test "$termios_bad" = maybe ; then
- echo "$as_me:23993: checking whether termios.h needs _POSIX_SOURCE" >&5
+ echo "$as_me:25458: checking whether termios.h needs _POSIX_SOURCE" >&5
echo $ECHO_N "checking whether termios.h needs _POSIX_SOURCE... $ECHO_C" >&6
- cat >conftest.$ac_ext <<_ACEOF
-#line 23996 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25461 "configure"
#include "confdefs.h"
#include <termios.h>
int
main (void)
{
-struct termios foo; int x = foo.c_iflag
+struct termios foo; int x = foo.c_iflag = 1; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:24008: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:25473: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:24011: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:24014: \"$ac_try\"") >&5
+ echo "$as_me:25476: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:25479: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:24017: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25482: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
termios_bad=no
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
- cat >conftest.$ac_ext <<_ACEOF
-#line 24025 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25490 "configure"
#include "confdefs.h"
#define _POSIX_SOURCE
@@ -24030,43 +25495,43 @@ cat conftest.$ac_ext >&5
int
main (void)
{
-struct termios foo; int x = foo.c_iflag
+struct termios foo; int x = foo.c_iflag = 2; (void)x
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:24039: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:25504: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:24042: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:24045: \"$ac_try\"") >&5
+ echo "$as_me:25507: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:25510: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:24048: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25513: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
termios_bad=unknown
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
termios_bad=yes
cat >>confdefs.h <<\EOF
#define _POSIX_SOURCE 1
EOF
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
- echo "$as_me:24064: result: $termios_bad" >&5
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
+ echo "$as_me:25529: result: $termios_bad" >&5
echo "${ECHO_T}$termios_bad" >&6
fi
fi
-echo "$as_me:24069: checking declaration of size-change" >&5
+echo "$as_me:25534: checking declaration of size-change" >&5
echo $ECHO_N "checking declaration of size-change... $ECHO_C" >&6
if test "${cf_cv_sizechange+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -24086,8 +25551,8 @@ do
CPPFLAGS="${CPPFLAGS}-D$cf_opts"
fi
- cat >conftest.$ac_ext <<_ACEOF
-#line 24090 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25555 "configure"
#include "confdefs.h"
#include <sys/types.h>
#ifdef HAVE_TERMIOS_H
@@ -24116,13 +25581,17 @@ main (void)
#ifdef TIOCGSIZE
struct ttysize win; /* SunOS 3.0... */
- int y = win.ts_lines;
- int x = win.ts_cols;
+ int y = win.ts_lines = 2;
+ int x = win.ts_cols = 1;
+ (void)y;
+ (void)x;
#else
#ifdef TIOCGWINSZ
struct winsize win; /* everything else */
- int y = win.ws_row;
- int x = win.ws_col;
+ int y = win.ws_row = 2;
+ int x = win.ws_col = 1;
+ (void)y;
+ (void)x;
#else
no TIOCGSIZE or TIOCGWINSZ
#endif /* TIOCGWINSZ */
@@ -24132,25 +25601,25 @@ main (void)
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:24136: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:25605: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:24139: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:24142: \"$ac_try\"") >&5
+ echo "$as_me:25608: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:25611: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:24145: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25614: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_cv_sizechange=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_cv_sizechange=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
CPPFLAGS="$cf_save_CPPFLAGS"
if test "$cf_cv_sizechange" = yes ; then
@@ -24161,7 +25630,7 @@ rm -f conftest.$ac_objext conftest.$ac_ext
done
fi
-echo "$as_me:24164: result: $cf_cv_sizechange" >&5
+echo "$as_me:25633: result: $cf_cv_sizechange" >&5
echo "${ECHO_T}$cf_cv_sizechange" >&6
if test "$cf_cv_sizechange" != no ; then
@@ -24169,7 +25638,7 @@ cat >>confdefs.h <<\EOF
#define HAVE_SIZECHANGE 1
EOF
- case $cf_cv_sizechange in
+ case "$cf_cv_sizechange" in
(NEED*)
cat >>confdefs.h <<EOF
#define $cf_cv_sizechange 1
@@ -24184,8 +25653,8 @@ PACKAGE_CONFIG=dlg_config.h
EXTRA_OUTPUT="$EXTRA_OUTPUT headers-sh:$srcdir/headers-sh.in"
-cat >conftest.$ac_ext <<_ACEOF
-#line 24188 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 25657 "configure"
#include "confdefs.h"
#include <locale.h>
int
@@ -24196,18 +25665,18 @@ setlocale(LC_ALL, "")
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:24200: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:25669: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:24203: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:24206: \"$ac_try\"") >&5
+ echo "$as_me:25672: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:25675: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:24209: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25678: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cat >>confdefs.h <<\EOF
#define HAVE_SETLOCALE 1
@@ -24215,18 +25684,18 @@ EOF
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
-echo "$as_me:24222: checking if runtime has nl_langinfo support for first weekday" >&5
+echo "$as_me:25691: checking if runtime has nl_langinfo support for first weekday" >&5
echo $ECHO_N "checking if runtime has nl_langinfo support for first weekday... $ECHO_C" >&6
if test "${cf_nl_langinfo_1stday+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat >conftest.$ac_ext <<_ACEOF
-#line 24229 "configure"
+ cat >"conftest.$ac_ext" <<_ACEOF
+#line 25698 "configure"
#include "confdefs.h"
#include <langinfo.h>
@@ -24238,41 +25707,53 @@ main (void)
int first_weekday = nl_langinfo (_NL_TIME_FIRST_WEEKDAY)[0];
long week_1stday_l = (long) nl_langinfo (_NL_TIME_WEEK_1STDAY);
+ (void) first_weekday;
+ (void) week_1stday_l;
;
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:24247: \"$ac_compile\"") >&5
+rm -f "conftest.$ac_objext"
+if { (eval echo "$as_me:25718: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
- echo "$as_me:24250: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest.$ac_objext'
- { (eval echo "$as_me:24253: \"$ac_try\"") >&5
+ echo "$as_me:25721: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest.$ac_objext"'
+ { (eval echo "$as_me:25724: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:24256: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
+ echo "$as_me:25727: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
cf_nl_langinfo_1stday=yes
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
cf_nl_langinfo_1stday=no
fi
-rm -f conftest.$ac_objext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest.$ac_ext"
fi
-echo "$as_me:24269: result: $cf_nl_langinfo_1stday" >&5
+echo "$as_me:25740: result: $cf_nl_langinfo_1stday" >&5
echo "${ECHO_T}$cf_nl_langinfo_1stday" >&6
-test "x$cf_nl_langinfo_1stday" = xyes && cat >>confdefs.h <<\EOF
+test "x$cf_nl_langinfo_1stday" = xyes &&
+cat >>confdefs.h <<\EOF
#define HAVE_NL_LANGINFO_1STDAY 1
EOF
-echo "$as_me:24275: checking if rpath-hack should be disabled" >&5
+if test "$GCC" = yes || test "$GXX" = yes
+then
+
+ test -n "$CFLAGS" && CFLAGS="$CFLAGS "
+ CFLAGS="${CFLAGS}$EXTRA_CFLAGS"
+
+ EXTRA_CFLAGS=
+fi
+
+echo "$as_me:25756: checking if rpath-hack should be disabled" >&5
echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
# Check whether --enable-rpath-hack or --disable-rpath-hack was given.
@@ -24280,30 +25761,32 @@ if test "${enable_rpath_hack+set}" = set; then
enableval="$enable_rpath_hack"
test "$enableval" != no && enableval=yes
if test "$enableval" != "yes" ; then
- cf_disable_rpath_hack=yes
+ enable_rpath_hack=no
else
- cf_disable_rpath_hack=no
+ enable_rpath_hack=yes
fi
else
enableval=yes
- cf_disable_rpath_hack=no
+ enable_rpath_hack=yes
fi;
-echo "$as_me:24292: result: $cf_disable_rpath_hack" >&5
+if test "x$enable_rpath_hack" = xno; then cf_disable_rpath_hack=yes; else cf_disable_rpath_hack=no; fi
+echo "$as_me:25774: result: $cf_disable_rpath_hack" >&5
echo "${ECHO_T}$cf_disable_rpath_hack" >&6
-if test "$cf_disable_rpath_hack" = no ; then
-echo "$as_me:24296: checking for updated LDFLAGS" >&5
+if test "$enable_rpath_hack" = yes ; then
+
+echo "$as_me:25779: checking for updated LDFLAGS" >&5
echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
if test -n "$LD_RPATH_OPT" ; then
- echo "$as_me:24299: result: maybe" >&5
+ echo "$as_me:25782: result: maybe" >&5
echo "${ECHO_T}maybe" >&6
for ac_prog in ldd
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-echo "$as_me:24306: checking for $ac_word" >&5
+echo "$as_me:25789: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -24318,7 +25801,7 @@ for ac_dir in $ac_dummy; do
test -z "$ac_dir" && ac_dir=.
$as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_cf_ldd_prog="$ac_prog"
-echo "$as_me:24321: found $ac_dir/$ac_word" >&5
+echo "$as_me:25804: found $ac_dir/$ac_word" >&5
break
done
@@ -24326,10 +25809,10 @@ fi
fi
cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
if test -n "$cf_ldd_prog"; then
- echo "$as_me:24329: result: $cf_ldd_prog" >&5
+ echo "$as_me:25812: result: $cf_ldd_prog" >&5
echo "${ECHO_T}$cf_ldd_prog" >&6
else
- echo "$as_me:24332: result: no" >&5
+ echo "$as_me:25815: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -24342,8 +25825,8 @@ test -n "$cf_ldd_prog" || cf_ldd_prog="no"
then
cf_rpath_oops=
-cat >conftest.$ac_ext <<_ACEOF
-#line 24346 "configure"
+cat >"conftest.$ac_ext" <<_ACEOF
+#line 25829 "configure"
#include "confdefs.h"
#include <stdio.h>
int
@@ -24354,25 +25837,25 @@ printf("Hello");
return 0;
}
_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:24358: \"$ac_link\"") >&5
+rm -f "conftest.$ac_objext" "conftest$ac_exeext"
+if { (eval echo "$as_me:25841: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
- echo "$as_me:24361: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:24364: \"$ac_try\"") >&5
+ echo "$as_me:25844: \$? = $ac_status" >&5
+ (exit "$ac_status"); } &&
+ { ac_try='test -s "conftest$ac_exeext"'
+ { (eval echo "$as_me:25847: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
- echo "$as_me:24367: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- cf_rpath_oops=`$cf_ldd_prog conftest$ac_exeext | fgrep ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
- cf_rpath_list=`$cf_ldd_prog conftest$ac_exeext | fgrep / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
+ echo "$as_me:25850: \$? = $ac_status" >&5
+ (exit "$ac_status"); }; }; then
+ cf_rpath_oops=`"$cf_ldd_prog" "conftest$ac_exeext" | ${FGREP-fgrep} ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
+ cf_rpath_list=`"$cf_ldd_prog" "conftest$ac_exeext" | ${FGREP-fgrep} / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
else
echo "$as_me: failed program was:" >&5
-cat conftest.$ac_ext >&5
+cat "conftest.$ac_ext" >&5
fi
-rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
# If we passed the link-test, but get a "not found" on a given library,
# this could be due to inept reconfiguration of gcc to make it only
@@ -24388,11 +25871,11 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
/usr/pkg \
/opt/sfw
do
- if test -f $cf_rpath_dir/lib/$cf_rpath_src
+ if test -f "$cf_rpath_dir/lib/$cf_rpath_src"
then
test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
-echo "${as_me:-configure}:24395: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
+echo "${as_me:-configure}:25878: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
break
@@ -24404,16 +25887,16 @@ echo "${as_me:-configure}:24395: testing ...adding -L$cf_rpath_dir/lib to LDFLAG
test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
-echo "${as_me:-configure}:24407: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
+echo "${as_me:-configure}:25890: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
-echo "${as_me:-configure}:24411: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
+echo "${as_me:-configure}:25894: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
cf_rpath_dst=
for cf_rpath_src in $LDFLAGS
do
- case $cf_rpath_src in
+ case "$cf_rpath_src" in
(-L*)
# check if this refers to a directory which we will ignore
@@ -24445,7 +25928,7 @@ do
then
test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
-echo "${as_me:-configure}:24448: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
+echo "${as_me:-configure}:25931: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
fi
@@ -24458,16 +25941,16 @@ LDFLAGS=$cf_rpath_dst
test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
-echo "${as_me:-configure}:24461: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
+echo "${as_me:-configure}:25944: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
-echo "${as_me:-configure}:24465: testing ...checking LIBS $LIBS ..." 1>&5
+echo "${as_me:-configure}:25948: testing ...checking LIBS $LIBS ..." 1>&5
cf_rpath_dst=
for cf_rpath_src in $LIBS
do
- case $cf_rpath_src in
+ case "$cf_rpath_src" in
(-L*)
# check if this refers to a directory which we will ignore
@@ -24499,7 +25982,7 @@ do
then
test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
-echo "${as_me:-configure}:24502: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
+echo "${as_me:-configure}:25985: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
fi
@@ -24512,14 +25995,14 @@ LIBS=$cf_rpath_dst
test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
-echo "${as_me:-configure}:24515: testing ...checked LIBS $LIBS ..." 1>&5
+echo "${as_me:-configure}:25998: testing ...checked LIBS $LIBS ..." 1>&5
test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
-echo "${as_me:-configure}:24519: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
+echo "${as_me:-configure}:26002: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
else
- echo "$as_me:24522: result: no" >&5
+ echo "$as_me:26005: result: no" >&5
echo "${ECHO_T}no" >&6
fi
@@ -24552,6 +26035,75 @@ LIB_TARGET = $LIB_TARGET\\
RM_SHARED_OPTS = $RM_SHARED_OPTS\\
# end CF__DEFINE_SHLIB_VARS"
+echo "$as_me:26038: checking for linker search path" >&5
+echo $ECHO_N "checking for linker search path... $ECHO_C" >&6
+if test "${cf_cv_ld_searchpath+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
+if test "$cross_compiling" != yes ; then
+
+# GNU binutils' ld does not involve permissions which may stop ldconfig.
+cf_pathlist=`ld --verbose 2>/dev/null | grep SEARCH_DIR | sed -e 's,SEARCH_DIR[("=][("=]*,,g' -e 's/"[)];//gp' | sort -u`
+
+# The -NX options tell newer versions of Linux ldconfig to not attempt to
+# update the cache, which makes it run faster.
+test -z "$cf_pathlist" && \
+ cf_pathlist=`ldconfig -NX -v 2>/dev/null | sed -e '/^[ ]/d' -e 's/:$//' | sort -u`
+
+test -z "$cf_pathlist" &&
+ cf_pathlist=`ldconfig -v 2>/dev/null | sed -n -e '/^[ ]/d' -e 's/:$//p' | sort -u`
+
+# This works with OpenBSD 6.5, which lists only filenames
+test -z "$cf_pathlist" &&
+ cf_pathlist=`ldconfig -v 2>/dev/null | sed -n -e 's,^Adding \(.*\)/.*$,\1,p' | sort -u`
+
+if test -z "$cf_pathlist"
+then
+ # dyld default path with MacOS
+ if test -f /usr/bin/otool && test "x`uname -s`" = xDarwin
+ then
+ # do this to bypass check
+ cf_cv_ld_searchpath='$HOME/lib'
+ cf_pathlist="/usr/local/lib /lib /usr/lib"
+ fi
+fi
+
+if test -z "$cf_pathlist"
+then
+ # Solaris is hardcoded
+ if test -d /opt/SUNWspro/lib
+ then
+ cf_pathlist="/opt/SUNWspro/lib /usr/ccs/lib /usr/lib"
+ elif test -d /usr/ccs/lib
+ then
+ cf_pathlist="/usr/ccs/lib /usr/lib"
+ fi
+fi
+
+fi
+
+# If nothing else, assume it is conventional
+test -z "$cf_pathlist" && cf_pathlist="/usr/lib /lib"
+
+# Finally, check that this is only directories
+for cf_path in $0 $cf_pathlist
+do
+ if test -d "$cf_path"; then
+ test -n "$cf_cv_ld_searchpath" && cf_cv_ld_searchpath="${cf_cv_ld_searchpath} "
+ cf_cv_ld_searchpath="${cf_cv_ld_searchpath}${cf_path}"
+ fi
+done
+
+# Ensure that it is nonempty
+test -z "$cf_cv_ld_searchpath" && cf_cv_ld_searchpath=/usr/lib
+
+fi
+echo "$as_me:26102: result: $cf_cv_ld_searchpath" >&5
+echo "${ECHO_T}$cf_cv_ld_searchpath" >&6
+
+LD_SEARCHPATH=`echo "$cf_cv_ld_searchpath"|sed -e 's/ /|/g'`
+
ac_config_files="$ac_config_files dialog-config makefile $EXTRA_OUTPUT $SUB_MAKEFILE"
ac_config_commands="$ac_config_commands default"
cat >confcache <<\_ACEOF
@@ -24630,12 +26182,12 @@ fi
DEFS=-DHAVE_CONFIG_H
-: ${CONFIG_STATUS=./config.status}
+: "${CONFIG_STATUS=./config.status}"
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:24636: creating $CONFIG_STATUS" >&5
+{ echo "$as_me:26188: creating $CONFIG_STATUS" >&5
echo "$as_me: creating $CONFIG_STATUS" >&6;}
-cat >$CONFIG_STATUS <<_ACEOF
+cat >"$CONFIG_STATUS" <<_ACEOF
#! $SHELL
# Generated automatically by configure.
# Run this file to recreate the current configuration.
@@ -24646,9 +26198,11 @@ debug=false
SHELL=\${CONFIG_SHELL-$SHELL}
ac_cs_invocation="\$0 \$@"
+CLICOLOR_FORCE= GREP_OPTIONS=
+unset CLICOLOR_FORCE GREP_OPTIONS
_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+cat >>"$CONFIG_STATUS" <<\_ACEOF
# Be Bourne compatible
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
emulate sh
@@ -24688,9 +26242,9 @@ as_executable_p="test -f"
# Support unset when possible.
if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
- as_unset=unset
+ as_unset="unset"
else
- as_unset=false
+ as_unset="false"
fi
# NLS nuisances.
@@ -24718,22 +26272,22 @@ _ACEOF
# Files that config.status was made for.
if test -n "$ac_config_files"; then
- echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
+ echo "config_files=\"$ac_config_files\"" >>"$CONFIG_STATUS"
fi
if test -n "$ac_config_headers"; then
- echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
+ echo "config_headers=\"$ac_config_headers\"" >>"$CONFIG_STATUS"
fi
if test -n "$ac_config_links"; then
- echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
+ echo "config_links=\"$ac_config_links\"" >>"$CONFIG_STATUS"
fi
if test -n "$ac_config_commands"; then
- echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
+ echo "config_commands=\"$ac_config_commands\"" >>"$CONFIG_STATUS"
fi
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
ac_cs_usage="\
\`$as_me' instantiates files from templates according to the
@@ -24762,21 +26316,22 @@ $config_commands
Report bugs to <dickey@invisible-island.net>."
EOF
-cat >>$CONFIG_STATUS <<EOF
+cat >>"$CONFIG_STATUS" <<EOF
ac_cs_version="\\
config.status
-configured by $0, generated by GNU Autoconf 2.52.20170501,
+configured by $0, generated by GNU Autoconf 2.52.20210105,
with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
+Copyright 2003-2020,2021 Thomas E. Dickey
Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
-srcdir=$srcdir
+srcdir="$srcdir"
INSTALL="$INSTALL"
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
# If no file are specified by the user, then we need to provide default
# value. By we need to know if files were specified by the user.
ac_need_defaults=:
@@ -24799,17 +26354,17 @@ do
case $1 in
# Handling of the options.
EOF
-cat >>$CONFIG_STATUS <<EOF
+cat >>"$CONFIG_STATUS" <<EOF
-recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
--version | --vers* | -V )
echo "$ac_cs_version"; exit 0 ;;
--he | --h)
# Conflict between --help and --header
- { { echo "$as_me:24812: error: ambiguous option: $1
+ { { echo "$as_me:26367: error: ambiguous option: $1
Try \`$0 --help' for more information." >&5
echo "$as_me: error: ambiguous option: $1
Try \`$0 --help' for more information." >&2;}
@@ -24828,7 +26383,7 @@ Try \`$0 --help' for more information." >&2;}
ac_need_defaults=false;;
# This is an error.
- -*) { { echo "$as_me:24831: error: unrecognized option: $1
+ -*) { { echo "$as_me:26386: error: unrecognized option: $1
Try \`$0 --help' for more information." >&5
echo "$as_me: error: unrecognized option: $1
Try \`$0 --help' for more information." >&2;}
@@ -24847,18 +26402,18 @@ cat >&5 << _ACEOF
## Running config.status. ##
## ----------------------- ##
-This file was extended by $as_me 2.52.20170501, executed with
+This file was extended by $as_me 2.52.20210105, executed with
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
CONFIG_LINKS = $CONFIG_LINKS
CONFIG_COMMANDS = $CONFIG_COMMANDS
- > $ac_cs_invocation
+ > "$ac_cs_invocation"
on `(hostname || uname -n) 2>/dev/null | sed 1q`
_ACEOF
EOF
-cat >>$CONFIG_STATUS <<EOF
+cat >>"$CONFIG_STATUS" <<EOF
#
# INIT-COMMANDS section.
#
@@ -24875,7 +26430,7 @@ cf_cv_shlib_version="$cf_cv_shlib_version"
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
for ac_config_target in $ac_config_targets
do
case "$ac_config_target" in
@@ -24887,7 +26442,7 @@ do
"default-1" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
"default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
"dlg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS dlg_config.h:config.hin" ;;
- *) { { echo "$as_me:24890: error: invalid argument: $ac_config_target" >&5
+ *) { { echo "$as_me:26445: error: invalid argument: $ac_config_target" >&5
echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
{ (exit 1); exit 1; }; };;
esac
@@ -24897,7 +26452,7 @@ done
# then the envvar interface is used. Set only those that are not.
# We use the long form for the default assignment because of an extremely
# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
+if "$ac_need_defaults"; then
test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
@@ -24927,7 +26482,7 @@ $debug ||
EOF
-cat >>$CONFIG_STATUS <<EOF
+cat >>"$CONFIG_STATUS" <<EOF
#
# CONFIG_FILES section.
@@ -24951,6 +26506,7 @@ s,@datadir@,$datadir,;t t
s,@sysconfdir@,$sysconfdir,;t t
s,@sharedstatedir@,$sharedstatedir,;t t
s,@localstatedir@,$localstatedir,;t t
+s,@runstatedir@,$runstatedir,;t t
s,@libdir@,$libdir,;t t
s,@includedir@,$includedir,;t t
s,@oldincludedir@,$oldincludedir,;t t
@@ -24978,8 +26534,18 @@ s,@CPPFLAGS@,$CPPFLAGS,;t t
s,@ac_ct_CC@,$ac_ct_CC,;t t
s,@EXEEXT@,$EXEEXT,;t t
s,@OBJEXT@,$OBJEXT,;t t
+s,@build@,$build,;t t
+s,@build_cpu@,$build_cpu,;t t
+s,@build_vendor@,$build_vendor,;t t
+s,@build_os@,$build_os,;t t
+s,@host@,$host,;t t
+s,@host_cpu@,$host_cpu,;t t
+s,@host_vendor@,$host_vendor,;t t
+s,@host_os@,$host_os,;t t
s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
s,@CPP@,$CPP,;t t
+s,@GREP@,$GREP,;t t
+s,@EGREP@,$EGREP,;t t
s,@SET_MAKE@,$SET_MAKE,;t t
s,@RANLIB@,$RANLIB,;t t
s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
@@ -24997,6 +26563,7 @@ s,@NROFF_NOTE@,$NROFF_NOTE,;t t
s,@AR@,$AR,;t t
s,@ac_ct_AR@,$ac_ct_AR,;t t
s,@ARFLAGS@,$ARFLAGS,;t t
+s,@FGREP@,$FGREP,;t t
s,@cf_cv_makeflags@,$cf_cv_makeflags,;t t
s,@CTAGS@,$CTAGS,;t t
s,@ETAGS@,$ETAGS,;t t
@@ -25007,16 +26574,12 @@ s,@ECHO_LD@,$ECHO_LD,;t t
s,@RULE_CC@,$RULE_CC,;t t
s,@SHOW_CC@,$SHOW_CC,;t t
s,@ECHO_CC@,$ECHO_CC,;t t
-s,@build@,$build,;t t
-s,@build_cpu@,$build_cpu,;t t
-s,@build_vendor@,$build_vendor,;t t
-s,@build_os@,$build_os,;t t
-s,@host@,$host,;t t
-s,@host_cpu@,$host_cpu,;t t
-s,@host_vendor@,$host_vendor,;t t
-s,@host_os@,$host_os,;t t
s,@PROG_EXT@,$PROG_EXT,;t t
s,@LIB_PREFIX@,$LIB_PREFIX,;t t
+s,@X_CFLAGS@,$X_CFLAGS,;t t
+s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
+s,@X_LIBS@,$X_LIBS,;t t
+s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
s,@PKG_CONFIG@,$PKG_CONFIG,;t t
s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
@@ -25107,10 +26670,6 @@ s,@MAKE_SHARED@,$MAKE_SHARED,;t t
s,@MAKE_STATIC@,$MAKE_STATIC,;t t
s,@NCURSES_CONFIG@,$NCURSES_CONFIG,;t t
s,@ac_ct_NCURSES_CONFIG@,$ac_ct_NCURSES_CONFIG,;t t
-s,@X_CFLAGS@,$X_CFLAGS,;t t
-s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
-s,@X_LIBS@,$X_LIBS,;t t
-s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
s,@XCURSES_CONFIG@,$XCURSES_CONFIG,;t t
s,@ac_ct_XCURSES_CONFIG@,$ac_ct_XCURSES_CONFIG,;t t
s,@EXTRAOBJS@,$EXTRAOBJS,;t t
@@ -25119,11 +26678,12 @@ s,@PACKAGE_CONFIG@,$PACKAGE_CONFIG,;t t
s,@cf_ldd_prog@,$cf_ldd_prog,;t t
s,@SET_SHLIB_VARS@,$SET_SHLIB_VARS,;t t
s,@LIB_TARGET@,$LIB_TARGET,;t t
+s,@LD_SEARCHPATH@,$LD_SEARCHPATH,;t t
CEOF
EOF
- cat >>$CONFIG_STATUS <<\EOF
+ cat >>"$CONFIG_STATUS" <<\EOF
# Split the substitutions into bite-sized pieces for seds with
# small command number limits, like on Digital OSF/1 and HP-UX.
ac_max_sed_lines=48
@@ -25132,8 +26692,8 @@ EOF
ac_end=$ac_max_sed_lines # Line after last line for current file.
ac_more_lines=:
ac_sed_cmds=
- while $ac_more_lines; do
- if test $ac_beg -gt 1; then
+ while "$ac_more_lines"; do
+ if test "$ac_beg" -gt 1; then
sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
else
sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
@@ -25150,15 +26710,15 @@ EOF
# It is possible to make a multiline substitution using escaped newlines.
# Ensure that we do not split the substitution between script fragments.
ac_BEG=$ac_end
- ac_END=`expr $ac_end + $ac_max_sed_lines`
+ ac_END=`expr "$ac_end" + "$ac_max_sed_lines"`
sed "1,${ac_BEG}d; ${ac_END}p; q" $tmp/subs.sed >$tmp/subs.next
if test -s $tmp/subs.next; then
grep '^s,@[^@,][^@,]*@,.*\\$' $tmp/subs.next >$tmp/subs.edit
if test ! -s $tmp/subs.edit; then
grep "^s,@[^@,][^@,]*@,.*,;t t$" $tmp/subs.next >$tmp/subs.edit
if test ! -s $tmp/subs.edit; then
- if test $ac_beg -gt 1; then
- ac_end=`expr $ac_end - 1`
+ if test "$ac_beg" -gt 1; then
+ ac_end=`expr "$ac_end" - 1`
continue
fi
fi
@@ -25170,9 +26730,9 @@ EOF
else
ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
fi
- ac_sed_frag=`expr $ac_sed_frag + 1`
+ ac_sed_frag=`expr "$ac_sed_frag" + 1`
ac_beg=$ac_end
- ac_end=`expr $ac_end + $ac_max_sed_lines`
+ ac_end=`expr "$ac_end" + "$ac_max_sed_lines"`
fi
done
if test -z "$ac_sed_cmds"; then
@@ -25181,10 +26741,10 @@ EOF
fi # test -n "$CONFIG_FILES"
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
# Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case $ac_file in
+ case "$ac_file" in
- | *:- | *:-:* ) # input from stdin
cat >$tmp/stdin
ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
@@ -25230,19 +26790,19 @@ done; }
ac_dir_suffix= ac_dots=
fi
- case $srcdir in
+ case "$srcdir" in
.) ac_srcdir=.
if test -z "$ac_dots"; then
ac_top_srcdir=.
else
- ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
+ ac_top_srcdir=`echo "$ac_dots" | sed 's,/$,,'`
fi ;;
[\\/]* | ?:[\\/]* )
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir ;;
+ ac_srcdir="$srcdir$ac_dir_suffix";
+ ac_top_srcdir="$srcdir" ;;
*) # Relative path.
- ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_dots$srcdir ;;
+ ac_srcdir="$ac_dots$srcdir$ac_dir_suffix"
+ ac_top_srcdir="$ac_dots$srcdir" ;;
esac
case $INSTALL in
@@ -25251,7 +26811,7 @@ done; }
esac
if test x"$ac_file" != x-; then
- { echo "$as_me:25254: creating $ac_file" >&5
+ { echo "$as_me:26814: creating $ac_file" >&5
echo "$as_me: creating $ac_file" >&6;}
rm -f "$ac_file"
fi
@@ -25269,7 +26829,7 @@ echo "$as_me: creating $ac_file" >&6;}
-) echo $tmp/stdin ;;
[\\/$]*)
# Absolute (can't be DOS-style, as IFS=:)
- test -f "$f" || { { echo "$as_me:25272: error: cannot find input file: $f" >&5
+ test -f "$f" || { { echo "$as_me:26832: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
{ (exit 1); exit 1; }; }
echo $f;;
@@ -25279,35 +26839,35 @@ echo "$as_me: error: cannot find input file: $f" >&2;}
echo $f
elif test -f "$srcdir/$f"; then
# Source tree
- echo $srcdir/$f
+ echo "$srcdir/$f"
else
# /dev/null tree
- { { echo "$as_me:25285: error: cannot find input file: $f" >&5
+ { { echo "$as_me:26845: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
{ (exit 1); exit 1; }; }
fi;;
esac
done` || { (exit 1); exit 1; }
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
ac_warn_datarootdir=no
if test x"$ac_file" != x-; then
for ac_item in $ac_file_inputs
do
- ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' $ac_item`
+ ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' "$ac_item"`
if test -n "$ac_seen"; then
- ac_used=`grep '@datarootdir@' $ac_item`
+ ac_used=`grep '@datarootdir@' "$ac_item"`
if test -z "$ac_used"; then
- { echo "$as_me:25301: WARNING: datarootdir was used implicitly but not set:
+ { echo "$as_me:26861: WARNING: datarootdir was used implicitly but not set:
$ac_seen" >&5
echo "$as_me: WARNING: datarootdir was used implicitly but not set:
$ac_seen" >&2;}
ac_warn_datarootdir=yes
fi
fi
- ac_seen=`grep '${datarootdir}' $ac_item`
+ ac_seen=`grep '${datarootdir}' "$ac_item"`
if test -n "$ac_seen"; then
- { echo "$as_me:25310: WARNING: datarootdir was used explicitly but not set:
+ { echo "$as_me:26870: WARNING: datarootdir was used explicitly but not set:
$ac_seen" >&5
echo "$as_me: WARNING: datarootdir was used explicitly but not set:
$ac_seen" >&2;}
@@ -25321,11 +26881,11 @@ if test "x$ac_warn_datarootdir" = xyes; then
fi
EOF
-cat >>$CONFIG_STATUS <<EOF
+cat >>"$CONFIG_STATUS" <<EOF
sed "$ac_vpsub
$extrasub
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
:t
/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
s,@configure_input@,$configure_input,;t t
@@ -25335,27 +26895,27 @@ s,@INSTALL@,$ac_INSTALL,;t t
" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
rm -f $tmp/stdin
if test x"$ac_file" != x-; then
- cp $tmp/out $ac_file
+ cp "$tmp/out" "$ac_file"
for ac_name in prefix exec_prefix datarootdir
do
- ac_seen=`fgrep -n '${'$ac_name'[:=].*}' $ac_file`
+ ac_seen=`${FGREP-fgrep} -n '${'$ac_name'[:=].*}' "$ac_file"`
if test -n "$ac_seen"; then
- ac_init=`egrep '[ ]*'$ac_name'[ ]*=' $ac_file`
+ ac_init=`${EGREP-egrep} '[ ]*'$ac_name'[ ]*=' "$ac_file"`
if test -z "$ac_init"; then
ac_seen=`echo "$ac_seen" |sed -e 's,^,'$ac_file':,'`
- { echo "$as_me:25347: WARNING: Variable $ac_name is used but was not set:
+ { echo "$as_me:26907: WARNING: Variable $ac_name is used but was not set:
$ac_seen" >&5
echo "$as_me: WARNING: Variable $ac_name is used but was not set:
$ac_seen" >&2;}
fi
fi
done
- egrep -n '@[a-z_][a-z_0-9]+@' $ac_file >$tmp/out
- egrep -n '@[A-Z_][A-Z_0-9]+@' $ac_file >>$tmp/out
+ ${EGREP-egrep} -n '@[a-z_][a-z_0-9]+@' "$ac_file" >$tmp/out
+ ${EGREP-egrep} -n '@[A-Z_][A-Z_0-9]+@' "$ac_file" >>$tmp/out
if test -s $tmp/out; then
ac_seen=`sed -e 's,^,'$ac_file':,' < $tmp/out`
- { echo "$as_me:25358: WARNING: Some variables may not be substituted:
+ { echo "$as_me:26918: WARNING: Some variables may not be substituted:
$ac_seen" >&5
echo "$as_me: WARNING: Some variables may not be substituted:
$ac_seen" >&2;}
@@ -25367,7 +26927,7 @@ $ac_seen" >&2;}
done
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
#
# CONFIG_HEADER section.
@@ -25394,7 +26954,7 @@ ac_uD=',;t'
for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
# Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case $ac_file in
+ case "$ac_file" in
- | *:- | *:-:* ) # input from stdin
cat >$tmp/stdin
ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
@@ -25404,7 +26964,7 @@ for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
* ) ac_file_in=$ac_file.in ;;
esac
- test x"$ac_file" != x- && { echo "$as_me:25407: creating $ac_file" >&5
+ test x"$ac_file" != x- && { echo "$as_me:26967: creating $ac_file" >&5
echo "$as_me: creating $ac_file" >&6;}
# First look for the input files in the build tree, otherwise in the
@@ -25415,7 +26975,7 @@ echo "$as_me: creating $ac_file" >&6;}
-) echo $tmp/stdin ;;
[\\/$]*)
# Absolute (can't be DOS-style, as IFS=:)
- test -f "$f" || { { echo "$as_me:25418: error: cannot find input file: $f" >&5
+ test -f "$f" || { { echo "$as_me:26978: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
{ (exit 1); exit 1; }; }
echo $f;;
@@ -25425,10 +26985,10 @@ echo "$as_me: error: cannot find input file: $f" >&2;}
echo $f
elif test -f "$srcdir/$f"; then
# Source tree
- echo $srcdir/$f
+ echo "$srcdir/$f"
else
# /dev/null tree
- { { echo "$as_me:25431: error: cannot find input file: $f" >&5
+ { { echo "$as_me:26991: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
{ (exit 1); exit 1; }; }
fi;;
@@ -25448,14 +27008,14 @@ sort -u confdefs.h | uniq >conftest.vals
# the size of here documents, and old seds have small limits too.
rm -f conftest.tail
-echo ' rm -f conftest.frag' >> $CONFIG_STATUS
+echo ' rm -f conftest.frag' >> "$CONFIG_STATUS"
while grep . conftest.vals >/dev/null
do
# Write chunks of a limited-size here document to conftest.frag.
- echo ' cat >> conftest.frag <<CEOF' >> $CONFIG_STATUS
- sed ${ac_max_here_lines}q conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> $CONFIG_STATUS
- echo 'CEOF' >> $CONFIG_STATUS
- sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
+ echo ' cat >> conftest.frag <<CEOF' >> "$CONFIG_STATUS"
+ sed "${ac_max_here_lines}q" conftest.vals | sed -e 's/#ifdef.*/#if 0/' >> "$CONFIG_STATUS"
+ echo 'CEOF' >> "$CONFIG_STATUS"
+ sed "1,${ac_max_here_lines}d" conftest.vals > conftest.tail
rm -f conftest.vals
mv conftest.tail conftest.vals
done
@@ -25471,9 +27031,9 @@ sed -f conftest.edit $tmp/in > $tmp/out
rm -f $tmp/in
mv $tmp/out $tmp/in
rm -f conftest.edit conftest.frag
-' >> $CONFIG_STATUS
+' >> "$CONFIG_STATUS"
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
# Let's still pretend it is `configure' which instantiates (i.e., don't
# use $as_me), people would be surprised to read:
# /* config.h. Generated automatically by config.status. */
@@ -25485,8 +27045,8 @@ cat >>$CONFIG_STATUS <<\EOF
cat $tmp/in >>$tmp/config.h
rm -f $tmp/in
if test x"$ac_file" != x-; then
- if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
- { echo "$as_me:25489: $ac_file is unchanged" >&5
+ if cmp -s "$ac_file" "$tmp/config.h" 2>/dev/null; then
+ { echo "$as_me:27049: $ac_file is unchanged" >&5
echo "$as_me: $ac_file is unchanged" >&6;}
else
ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
@@ -25518,8 +27078,8 @@ for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
done; }
fi
- rm -f $ac_file
- mv $tmp/config.h $ac_file
+ rm -f "$ac_file"
+ mv "$tmp/config.h" "$ac_file"
fi
else
cat $tmp/config.h
@@ -25527,7 +27087,7 @@ done; }
fi
done
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
#
# CONFIG_COMMANDS section.
#
@@ -25535,7 +27095,7 @@ for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
- case $ac_dest in
+ case "$ac_dest" in
default-1 ) for ac_file in $CONFIG_FILES; do
# Support "outfile[:infile[:infile...]]"
@@ -25547,10 +27107,10 @@ for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
case "$ac_file" in
(*/[Mm]akefile.in)
# Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
+ ac_dir="`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`"
ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- ac_base=`basename $ac_file .in`
+ ac_dots="`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`"
+ ac_base="`basename $ac_file .in`"
# In autoconf-2.13 it is called $ac_given_srcdir.
# In autoconf-2.50 it is called $srcdir.
test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
@@ -25697,11 +27257,11 @@ CF_EOF
done
EOF
-cat >>$CONFIG_STATUS <<\EOF
+cat >>"$CONFIG_STATUS" <<\EOF
{ (exit 0); exit 0; }
EOF
-chmod +x $CONFIG_STATUS
+chmod +x "$CONFIG_STATUS"
ac_clean_files=$ac_clean_files_save
# configure is writing to config.log, and then calls config.status.
@@ -25715,10 +27275,10 @@ ac_clean_files=$ac_clean_files_save
if test "$no_create" != yes; then
ac_cs_success=:
exec 5>/dev/null
- $SHELL $CONFIG_STATUS || ac_cs_success=false
+ $SHELL "$CONFIG_STATUS" || ac_cs_success=false
exec 5>>config.log
# Use ||, not &&, to avoid exiting from the if with $? = 1, which
# would make configure fail if this is the last instruction.
- $ac_cs_success || { (exit 1); exit 1; }
+ "$ac_cs_success" || { (exit 1); exit 1; }
fi
diff --git a/configure.in b/configure.in
index fb6633c1a11f..f81a47e8e376 100644
--- a/configure.in
+++ b/configure.in
@@ -1,7 +1,7 @@
-dnl $Id: configure.in,v 1.92 2018/06/18 08:59:49 tom Exp $
+dnl $Id: configure.in,v 1.101 2020/11/26 16:21:27 tom Exp $
dnl Process this file with autoconf to produce a configure script.
dnl ---------------------------------------------------------------------------
-dnl Copyright 1999-2016,2018 -- Thomas E. Dickey
+dnl Copyright 1999-2019,2020 -- Thomas E. Dickey
dnl
dnl Permission is hereby granted, free of charge, to any person obtaining a
dnl copy of this software and associated documentation files (the
@@ -27,7 +27,7 @@ dnl holders shall not be used in advertising or otherwise to promote the
dnl sale, use or other dealings in this Software without prior written
dnl authorization.
dnl ---------------------------------------------------------------------------
-AC_PREREQ(2.52.20170501)
+AC_PREREQ(2.52.20200802)
AC_INIT(dialog.h)
AC_CONFIG_HEADER(dlg_config.h:config.hin)
@@ -63,7 +63,8 @@ CF_XOPEN_SOURCE
CF_LARGEFILE
CF_WITH_INSTALL_PREFIX
-CF_WITH_WARNINGS
+CF_WITH_SCREEN_PDCURSES
+CF_ENABLE_WARNINGS(,yes)
CF_PKG_CONFIG
dnl
@@ -113,13 +114,12 @@ CF_ARG_MSG_ENABLE([if you want --trace option],
[EXTRAOBJS="$EXTRAOBJS trace\$o"
AC_DEFINE(HAVE_DLG_TRACE,1,[Define to 1 to support --trace option])],,yes)
+CF_ENABLE_RPATH
CF_LD_RPATH_OPT
CF_WITH_SHARED_OR_LIBTOOL(DIALOG,${VERSION_MAJOR}.${VERSION_MINOR},`echo "$VERSION" |sed -e 's/:/./g'`)
CF_WITH_CURSES_DIR
-CF_ENABLE_RPATH
-
CF_WITH_NCURSES_ETC
CF_WIDEC_CURSES
@@ -129,11 +129,20 @@ CF_ARG_MSG_ENABLE([if you want extra dialogs],
[ --disable-extras do not include extra dialogs],
[cf_all_widgets=yes],[cf_all_widgets=no],yes)
+cf_use_dialogrc=yes
CF_ARG_MSG_ENABLE([if you want config-file support],
rc-file,
[ --disable-rc-file do not include config-file support],
[EXTRAOBJS="$EXTRAOBJS rc\$o"
- AC_DEFINE(HAVE_RC_FILE,1,[Define to 1 to include config-file support])],,$cf_all_widgets)
+ AC_DEFINE(HAVE_RC_FILE,1,[Define to 1 to include config-file support])],cf_use_dialogrc=no,$cf_all_widgets)
+
+cf_use_dialogrc2=yes
+if test "$cf_use_dialogrc" = yes; then
+CF_ARG_MSG_ENABLE([if you want extra attributes in config-file],
+ rc-file2,
+ [ --disable-rc-file2 do not use extra attributes in config-file],
+ [AC_DEFINE(HAVE_RC_FILE2,1,[Define to 1 to use extra attributes in config-file])],cf_use_dialogrc2=no,$cf_all_widgets)
+fi
CF_ARG_MSG_ENABLE([if you want Xdialog-style dialogs],
Xdialog,
@@ -195,7 +204,7 @@ dnl
AC_HEADER_STDC
AC_HEADER_TIME
AC_HEADER_DIRENT
-AC_CHECK_HEADERS(search.h stdint.h unistd.h)
+AC_CHECK_HEADERS(search.h stdint.h sys/param.h unistd.h)
CF_CURSES_TERM_H
dnl
@@ -203,7 +212,6 @@ dnl Checks for library functions.
dnl
AC_TYPE_SIGNAL
AC_CHECK_FUNCS(\
-_nc_free_and_exit \
btowc \
mblen \
mbrlen \
@@ -241,6 +249,8 @@ wget_wch \
wsyncup \
)
+CF_CURSES_EXIT
+
AC_CHECK_FUNC(start_color,[AC_DEFINE(HAVE_COLOR,1,[Define to 1 if (n)curses has start_color function])])
CF_CURSES_CHTYPE
CF_CURSES_WACS_SYMBOLS
@@ -254,9 +264,11 @@ CF_HEADERS_SH(DLG,dlg_config.h)
AC_TRY_LINK([#include <locale.h>],[setlocale(LC_ALL, "")],[AC_DEFINE(HAVE_SETLOCALE,1,[Define to 1 if locale feature can be enabled])])
CF_NL_LANGINFO_1STDAY
+CF_MERGE_EXTRA_CFLAGS
CF_DISABLE_RPATH_HACK
CF__DEFINE_SHLIB_VARS
+CF_LD_SEARCHPATH
AC_OUTPUT(
dialog-config
diff --git a/dialog-config.in b/dialog-config.in
index 530551ba1e57..8bf1a591b451 100644
--- a/dialog-config.in
+++ b/dialog-config.in
@@ -1,7 +1,7 @@
#!@SHELL@
-# $Id: dialog-config.in,v 1.6 2012/10/06 14:29:45 tom Exp $
+# $Id: dialog-config.in,v 1.13 2019/09/26 00:50:46 tom Exp $
##############################################################################
-# Copyright (c) 2007-2011,2012 Thomas E. Dickey #
+# Copyright (c) 2007-2012,2019 Thomas E. Dickey #
# #
# Permission is hereby granted, free of charge, to any person obtaining a #
# copy of this software and associated documentation files (the "Software"), #
@@ -32,16 +32,79 @@ prefix="@prefix@"
exec_prefix="@exec_prefix@"
datarootdir="@datarootdir@"
-bindir="@bindir@"
-libdir="@libdir@"
-datadir="@datadir@"
-mandir="@mandir@"
+same_prefix=yes
+same_exec_prefix=yes
THIS="@PACKAGE@"
-test $# = 0 && exec @SHELL@ $0 --error
+test $# = 0 && exec @SHELL@ "$0" --error
while test $# -gt 0; do
+
+ # (re)evaluate symbols that may depend upon $prefix
+ if [ "x$same_prefix" != "xyes" ]
+ then
+ eval exec_prefix='@exec_prefix@'
+ eval datarootdir='@datarootdir@'
+ elif [ "x$same_exec_prefix" != "xyes" ]
+ then
+ eval datarootdir='@datarootdir@'
+ fi
+
+ eval bindir='"@bindir@"'
+ eval includedir='"@includedir@"'
+ eval libdir='"@libdir@"'
+ eval datadir='"@datadir@"'
+ eval mandir='"@mandir@"'
+
+ [ -z "$includedir" ] && includedir="${prefix}/include"
+
+ eval LDFLAGS='"@LDFLAGS@"'
+ eval LIBS='"@LIBS@"'
+ LIBS="-l${THIS} $LIBS"
+
+ # If the directory given by --libdir is not in the LDFLAGS+LIBS set,
+ # prepend it to LDFLAGS to help link this application's library.
+ found=no
+ for opt in $LDFLAGS $LIBS
+ do
+ if [ "x$-L${libdir}" = "x$opt" ]
+ then
+ found=yes
+ break
+ fi
+ done
+ if [ $found = no ]
+ then
+ [ -n "$LFLAGS" ] && LDFLAGS=" $LFDLAGS"
+ LDFLAGS="-L${libdir}$LDFLAGS"
+ fi
+ [ -z "$LDFLAGS" ] && LDFLAGS="-L${exec_prefix}/lib"
+
+ # Ignore -L options which do not correspond to an actual directory,
+ # or which are standard library directories (i.e., the linker is
+ # supposed to search those directories).
+ #
+ # There is no portable way to find the list of standard library
+ # directories. Require a POSIX shell anyway, to keep this simple.
+ lib_flags=
+ for opt in $LDFLAGS $LIBS
+ do
+ case $opt in
+ -L*)
+ [ -d ${opt##-L} ] || continue
+ case ${opt##-L} in
+ @LD_SEARCHPATH@) # skip standard libdir
+ continue
+ ;;
+ *)
+ ;;
+ esac
+ ;;
+ esac
+ lib_flags="$lib_flags $opt"
+ done
+
case "$1" in
-*=*)
ARG=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'`
@@ -56,30 +119,81 @@ while test $# -gt 0; do
--prefix=*)
prefix="$ARG"
test -z "$exec_prefix" && exec_prefix="$ARG"
+ same_prefix=no
;;
--prefix)
echo "$prefix"
;;
--exec-prefix=*)
exec_prefix="$ARG"
+ same_exec_prefix=no
;;
--exec-prefix)
echo "$exec_prefix"
;;
# compile/link
- --cflags)
+ --cflags|--cflags-only-I)
INCS=
- if test "${prefix}/include" != /usr/include ; then
- INCS="-I${prefix}/include"
+ if test "$includedir" != /usr/include ; then
+ INCS="-I$includedir"
fi
sed -e 's,^[ ]*,,' -e 's, [ ]*, ,g' -e 's,[ ]*$,,' <<-ENDECHO
$INCS
ENDECHO
;;
+ --cflags-only-other)
+ # no -D/-U options should be needed
+ echo
+ ;;
--libs)
- sed -e 's,^[ ]*,,' -e 's, [ ]*, ,g' -e 's,[ ]*$,,' <<-ENDECHO
- -L${exec_prefix}/lib -l${THIS} @LIBS@
-ENDECHO
+ OPTS=
+ for opt in $lib_flags
+ do
+ [ -n "$OPTS" ] && OPTS="$OPTS "
+ OPTS="${OPTS}${opt}"
+ done
+ printf "%s\n" "$OPTS"
+ ;;
+ --libs-only-L)
+ OPTS=
+ for opt in $lib_flags
+ do
+ case "x$opt" in
+ x-L*)
+ [ -n "$OPTS" ] && OPTS="$OPTS "
+ OPTS="${OPTS}${opt}"
+ ;;
+ esac
+ done
+ printf "%s\n" "$OPTS"
+ ;;
+ --libs-only-l)
+ OPTS=
+ for opt in $lib_flags
+ do
+ case "x$opt" in
+ x-l*)
+ [ -n "$OPTS" ] && OPTS="$OPTS "
+ OPTS="${OPTS}${opt}"
+ ;;
+ esac
+ done
+ printf "%s\n" "$OPTS"
+ ;;
+ --libs-only-other)
+ OPTS=
+ for opt in $lib_flags
+ do
+ case "x$opt" in
+ x-[lL]*)
+ ;;
+ *)
+ [ -n "$OPTS" ] && OPTS="$OPTS "
+ OPTS="${OPTS}${opt}"
+ ;;
+ esac
+ done
+ printf "%s\n" "$OPTS"
;;
# identification
--version)
@@ -115,19 +229,23 @@ Options:
--cflags echos the C compiler flags needed to compile with ${THIS}
--libs echos the libraries needed to link with ${THIS}
+ --libs-only-L echos -L linker options (search path) for ${THIS}
+ --libs-only-l echos -l linker options (libraries) for ${THIS}
+ --libs-only-other echos linker options other than -L/-l
+
--version echos the release+patchdate version of ${THIS}
--abi-version echos the ABI version of ${THIS}
--bindir echos the directory containing ${THIS} programs
--datadir echos the directory containing ${THIS} data
--libdir echos the directory containing ${THIS} libraries
- --mandir echos the directory containing ${THIS} manpages
+ --mandir echos the directory containing ${THIS} manual pages
--help prints this message
ENDHELP
;;
--error|*)
- @SHELL@ $0 --help 1>&2
+ @SHELL@ "$0" --help 1>&2
exit 1
;;
esac
diff --git a/dialog.1 b/dialog.1
index 49f304ba2131..6ff9293b8574 100644
--- a/dialog.1
+++ b/dialog.1
@@ -1,6 +1,6 @@
'\" t
-.\" $Id: dialog.1,v 1.205 2018/06/19 00:26:13 tom Exp $
-.\" Copyright 2005-2017,2018 Thomas E. Dickey
+.\" $Id: dialog.1,v 1.226 2021/01/17 17:25:01 tom Exp $
+.\" Copyright 2005-2020,2021 Thomas E. Dickey
.\"
.\" This program is free software; you can redistribute it and/or modify
.\" it under the terms of the GNU Lesser General Public License, version 2.1
@@ -48,15 +48,15 @@
.ie \n(.g .ds '' \(rq
.el .ds '' ''
.
-.TH \*D 1 "" "$Date: 2018/06/19 00:26:13 $"
+.TH \*D 1 "" "$Date: 2021/01/17 17:25:01 $"
.SH NAME
dialog \- display dialog boxes from shell scripts
.SH SYNOPSIS
-\fB\*p --clear\fP
+\fB\*p \-\-clear\fP
.br
-.BI "\*p --create-rc " file
+.BI "\*p \-\-create\-rc " file
.br
-\fB\*p --print-maxsize\fP
+\fB\*p \-\-print\-maxsize\fP
.br
\fB\*p\fP
\fIcommon-options\fP
@@ -101,12 +101,11 @@ These types of dialog boxes are implemented
.BR treeview ", and "
.BR yesno " (yes/no)."
.ad
-.hy
.RE
.PP
You can put more than one dialog box into a script:
.bP
-Use the "\fB--and-widget\fP" token to force \fB\*p\fP to proceed to the next
+Use the "\fB\-\-and\-widget\fP" token to force \fB\*p\fP to proceed to the next
dialog unless you have pressed ESC to cancel, or
.bP
Simply add the tokens for the next dialog box, making a chain.
@@ -115,29 +114,40 @@ e.g., Cancel or No (see DIAGNOSTICS).
.PP
Some widgets, e.g., checklist, will write text to \fB\*p\fP's output.
Normally that is the standard error, but there are options for
-changing this: "\fB--output-fd\fP", "\fB--stderr\fP" and "\fB--stdout\fP".
+changing this:
+\*(``\fB\-\-output\-fd\fP\*('',
+\*(``\fB\-\-stderr\fP\*('' and
+\*(``\fB\-\-stdout\fP\*(''.
No text is written if the Cancel button (or ESC) is pressed;
\fB\*p\fP exits immediately in that case.
.
.\" ************************************************************************
.SH OPTIONS
-All options begin with "\fB--\fP"
+All options begin with \*(``\fB--\fP\*(''
(two ASCII hyphens,
for the benefit of those using systems with deranged locale support).
.PP
-A "\fB--\fP" by itself is used as an escape,
+A \*(``\fB--\fP\*('' by itself is used as an escape,
i.e., the next token on the command-line is not treated as an option.
.RS
.B \*p --title -- --Not an option
.RE
.PP
-The "\fB--args\fP" option tells \fB\*p\fP to list the command-line
+When a common (e.g., non-widget) option is repeated,
+the last found is the one that is used.
+Boolean options are handled specially so they can be cancelled,
+by adding (or omitting) a \*(``no\*('' modifier
+after the leading \*(``\fB--\fP\*(''.
+For instance, \fB\-\-no-shadow\fP is documented here,
+but \fB\-\-shadow\fP also is accepted.
+.PP
+The \*(``\fB\-\-args\fP\*('' option tells \fB\*p\fP to list the command-line
parameters to the standard error.
This is useful when debugging complex scripts using
-the "\fB--\fP" and "\fB--file\fP",
+the \*(``\fB--\fP\*('' and \*(``\fB\-\-file\fP\*('',
since the command-line may be rewritten as these are expanded.
.PP
-The "\fB--file\fP" option tells \fB\*p\fP to read parameters from
+The \*(``\fB\-\-file\fP\*('' option tells \fB\*p\fP to read parameters from
the file named as its value.
.RS
.B \*p --file \fIparameterfile
@@ -146,9 +156,9 @@ the file named as its value.
Blanks not within double-quotes are discarded
(use backslashes to quote single characters).
The result is inserted into the command-line,
-replacing "\fB--file\fP" and its option value.
+replacing \*(``\fB\-\-file\fP\*('' and its option value.
Interpretation of the command-line resumes from that point.
-If \fIparameterfile\fP begins with "&", \fB\*p\fP
+If \fIparameterfile\fP begins with \*(``&\*('', \fB\*p\fP
interprets the following text as a file descriptor number
rather than a filename.
.PP
@@ -156,7 +166,7 @@ Most widgets accept \fIheight\fP and \fIwidth\fP parameters,
which can be used to automatically size the widget to accommodate
multi-line message \fIprompt\fP values:
.bP
-If the parameter is negative,
+If the parameter is negative,
\fB\*l\fP uses the screen's size.
.bP
If the parameter is zero,
@@ -170,8 +180,8 @@ Most of the common options are reset before processing each widget.
.
.IP "\fB--ascii-lines
Rather than draw graphics lines around boxes,
-draw ASCII "+" and "-" in the same place.
-See also "\fB--no-lines\fR".
+draw ASCII \*(``+\*('' and \*(``-\*('' in the same place.
+See also \*(``\fB\-\-no\-lines\fR\*(''.
.
.IP "\fB--aspect \fIratio"
This gives you some control over the box dimensions when using auto
@@ -192,10 +202,11 @@ Override the label used for \*(``Cancel\*('' buttons.
.
.IP "\fB--clear"
Clears the widget screen, keeping only the screen_color background.
-Use this when you combine widgets with "\fB--and-widget\fR" to erase the
+Use this when you combine widgets
+with \*(``\fB\-\-and\-widget\fR\*('' to erase the
contents of a previous widget on the screen, so it won't be seen
under the contents of a following widget.
-Understand this as the complement of "\fB--keep-window\fR".
+Understand this as the complement of \*(``\fB\-\-keep\-window\fR\*(''.
To compare the effects, use these:
.
.ES
@@ -237,9 +248,12 @@ First and third widget visible, staircase effect, ordered 3,1:
Note, if you want to restore original console colors and send your
cursor home after the dialog program has exited, use the \fBclear\fR\ (1)
command.
+Conversely, if you want to clear the screen and send your cursor to
+the lower left after the \fB\*p\fP program has exited, use the
+\fB\-\-erase\-on\-exit\fR\ option.
.
.IP "\fB--colors"
-Interpret embedded "\eZ" sequences in the dialog text
+Interpret embedded \*(``\eZ\*('' sequences in the dialog text
by the following character,
which tells \fB\*p\fP to set colors or video attributes:
.RS
@@ -260,10 +274,10 @@ Reverse is set by 'r', reset by 'R'.
.bP
Underline is set by 'u', reset by 'U'.
.bP
-The settings are cumulative, e.g., "\eZb\eZ1" makes the following text
+The settings are cumulative, e.g., \*(``\eZb\eZ1\*('' makes the following text
bold (perhaps bright) red.
.bP
-Restore normal settings with "\eZn".
+Restore normal settings with \*(``\eZn\*(''.
.RE
.
.IP "\fB--column-separator \fIstring"
@@ -281,13 +295,13 @@ Without cr-wrap, the layout of your text may be formatted to look nice
in the source code of your script without affecting the way it will
look in the dialog.
.IP
-The \fIcr-wrap\fP feature is implemented subject to these conditions:
+The \fIcr\-wrap\fP feature is implemented subject to these conditions:
.RS
.bP
-the string contains \*(``\en\*('' and the \fB--no-nl-expand\fP option is
+the string contains \*(``\en\*('' and the \fB\-\-no\-nl\-expand\fP option is
not used, or
.bP
-the \fB--trim\fP option is used.
+the \fB\-\-trim\fP option is used.
.RE
.IP
For more information, see \fBWhitespace Options\fP.
@@ -300,10 +314,16 @@ this can be used to dump a sample configuration file to the file specified
by
.IR file "."
.
+.IP "\fB--cursor-off-label"
+Place the terminal cursor at the end of a button instead of on the
+first character of the button label.
+This is useful to reduce visual confusion when the cursor coloration
+interacts poorly with the button-label text colors.
+.
.IP "\fB--date-format \fIformat"
If the host provides \fBstrftime\fP,
this option allows you to specify the format of the date printed for
-the \fB--calendar\fP widget.
+the \fB\-\-calendar\fP widget.
The time of day (hour, minute, second) are the current local time.
.
.IP "\fB--defaultno"
@@ -314,7 +334,7 @@ box a
Likewise, treat the default button of widgets that provide
\*(``OK\*('' and \*(``Cancel\*(''
as a \fICancel\fP.
-If "\fB--nocancel\fP" or "\fB--visit-items\fP" are given
+If \*(``\fB\-\-no\-cancel\fP\*('' or \*(``\fB\-\-visit\-items\fP\*('' are given
those options overrides this,
making the default button always \*(``Yes\*(''
(internally the same as \*(``OK\*('').
@@ -335,13 +355,19 @@ The option's value is the name of the button:
.IP
Normally the first button in each widget is the default.
The first button shown is determined by the widget
-together with the "\fB--nook\fP" and "\fB--nocancel\fP options.
+together with the \*(``\fB\-\-no\-ok\fP\*(''
+and \*(``\fB\-\-no\-cancel\fP\*('' options.
If this option is not given, there is no default button assigned.
.
.IP "\fB--default-item \fIstring"
Set the default item in a checklist, form or menu box.
Normally the first item in the box is the default.
.
+.IP "\fB--erase-on-exit"
+When \fB\*p\fP exits, remove the dialog widget, erasing the entire
+screen to its native background color, and place the terminal cursor
+at the lower left corner.
+.
.IP "\fB--exit-label \fIstring"
Override the label used for \*(``EXIT\*('' buttons.
.
@@ -358,24 +384,29 @@ The help message is also printed if no options are given,
or if an unrecognized option is given.
.
.IP "\fB--help-button"
-Show a help-button after \*(``OK\*('' and \*(``Cancel\*('' buttons,
-e.g., in checklist, radiolist and menu boxes,
-and other widgets which have an \*(``OK\*('' button,
-whether or not the \*(``Cancel\*('' button is used.
+Show a help-button after \*(``OK\*('' and \*(``Cancel\*('' buttons
+in boxes which have a list of tagged items
+(i.e., checklist, radiolist, menu, and treeview boxes).
.IP
-On exit, the return status will indicate that the Help button was pressed.
-\fB\*L\fP will also write a message to its output
+On exit, the return status indicates that the Help button was pressed.
+\fB\*L\fP also writes a message to its output
after the token \*(``HELP\*('':
.RS
.bP
-If "\fB--item-help\fR" is also given, the item-help text will be written.
+If "\fB\-\-item\-help\fR" is also given, the item-help text is written.
.bP
-Otherwise, the item's tag (the first field) will be written.
+Otherwise, the item's tag (the first field) is written.
.RE
.IP
.IP
-You can use the \fB--help-tags\fP option and/or set the DIALOG_ITEM_HELP
+You can use the \fB\-\-help\-tags\fP option and/or set the DIALOG_ITEM_HELP
environment variable to modify these messages and exit-status.
+.IP
+This option can be applied to other widgets,
+which have an \*(``OK\*('' button,
+whether or not the \*(``Cancel\*('' button is used.
+The return status and output are not treated specially for the other widgets;
+the help-button is just an extra button.
.
.IP "\fB--help-label \fIstring"
Override the label used for \*(``Help\*('' buttons.
@@ -388,7 +419,7 @@ This can be used to reconstruct the state of a checklist after processing
the help request.
.
.IP "\fB--help-tags"
-Modify the messages written on exit for \fB--help-button\fP
+Modify the messages written on exit for \fB\-\-help\-button\fP
by making them always just the item's tag.
This does not affect the exit status code.
.
@@ -400,7 +431,7 @@ Display the given string centered at the bottom of the widget.
.
.IP "\fB--ignore"
Ignore options that \fB\*p\fP does not recognize.
-Some well-known ones such as "\fB--icon\fP" are ignored anyway,
+Some well-known ones such as \*(``\fB\-\-icon\fP\*('' are ignored anyway,
but this is a better choice for compatibility with other implementations.
.
.IP "\fB--input-fd \fIfd"
@@ -418,7 +449,7 @@ by echoing asterisks for each character.
.
.IP "\fB--iso-week"
Set the starting point for the week-number
-shown in the "\fB--calendar\fP" option
+shown in the \*(``\fB\-\-calendar\fP\*('' option
according to ISO-8601, which starts numbering
with the first week which includes a Thursday in January.
.
@@ -439,18 +470,20 @@ Use this option to allow \fB\*p\fP to use those initialization strings.
.
.IP "\fB--keep-window"
Normally when \fB\*p\fR performs several \fBtailboxbg\fR widgets
-connected by "\fB--and-widget\fR",
+connected by \*(``\fB\-\-and\-widget\fR\*('',
it clears the old widget from the screen by painting over it.
Use this option to suppress that repainting.
.IP
At exit, \fB\*p\fR repaints all of the widgets which have been
-marked with "\fB--keep-window\fR", even if they are not \fBtailboxbg\fR widgets.
+marked with \*(``\fB\-\-keep\-window\fR\*('',
+even if they are not \fBtailboxbg\fR widgets.
That causes them to be repainted in reverse order.
-See the discussion of the "\fB--clear\fR" option for examples.
+See the discussion of the \*(``\fB\-\-clear\fR\*('' option for examples.
.
.IP "\fB--last-key"
At exit, report the last key which the user entered.
-This is the curses key code rather than a symbol or literal character.
+This is the curses key code rather than a symbol or literal character,
+and is only reported for keys which are bound to an action.
It can be used by scripts to distinguish between two keys which are
bound to the same action.
.
@@ -459,7 +492,6 @@ Limit input strings to the given size.
If not specified, the limit is 2048.
.
.IP "\fB--no-cancel"
-.IP "\fB--nocancel"
Suppress the \*(``Cancel\*('' button in checklist, inputbox and menu box modes.
A script can still test if the user pressed the ESC key to cancel to quit.
.
@@ -468,19 +500,31 @@ Normally \fB\*p\fR converts tabs to spaces and reduces multiple
spaces to a single space for text which is displayed in a message boxes, etc.
Use this option to disable that feature.
Note that \fB\*p\fR will still wrap text,
-subject to the "\fB--cr-wrap\fR" and "\fB--trim\fR" options.
+subject to the \*(``\fB\-\-cr\-wrap\fR\*(''
+and \*(``\fB\-\-trim\fR\*('' options.
.IP
-The \fIno-collapse\fP feature is implemented subject to these conditions:
+The \fIno\-collapse\fP feature is implemented subject to these conditions:
.RS
.bP
-the string contains \*(``\en\*('' and the \fB--no-nl-expand\fP option is
+the string contains \*(``\en\*('' and the \fB\-\-no\-nl\-expand\fP option is
not used, or
.bP
-the \fB--trim\fP option is not used.
+the \fB\-\-trim\fP option is not used.
.RE
.IP
For more information, see \fBWhitespace Options\fP.
.
+.IP "\fB\-\-no\-hot\-list"
+Tells
+\fB\*p\fP
+to suppress the hotkey feature for lists, e.g., the checkbox, menus.
+.IP
+Normally, the first uppercase character of a list entry will be highlighted,
+and typing that character will move the focus to that entry.
+This option suppresses both the highlighting and the movement.
+.IP
+Hotkeys for buttons (\*(``OK\*('' , \*(``Cancel\*('', etc.) are unaffected.
+.
.IP "\fB--no-items"
Some widgets (checklist, inputmenu, radiolist, menu) display a list
with two columns (a \*(``tag\*('' and \*(``item\*('',
@@ -489,7 +533,7 @@ This option tells \fB\*p\fP to read shorter rows,
omitting the \*(``item\*('' part of the list.
This is occasionally useful, e.g., if the tags provide enough information.
.IP
-See also \fB--no-tags\fP.
+See also \fB\-\-no\-tags\fP.
If both options are given, this one is ignored.
.
.IP "\fB--no-kill"
@@ -506,25 +550,42 @@ Override the label used for \*(``No\*('' buttons.
.
.IP "\fB--no-lines
Rather than draw lines around boxes, draw spaces in the same place.
-See also "\fB--ascii-lines\fR".
+See also \*(``\fB\-\-ascii\-lines\fR\*(''.
.
.IP "\fB--no-mouse
Do not enable the mouse.
.
.IP "\fB--no-nl-expand
-Do not convert "\en" substrings of the message/prompt text into
+Do not convert \*(``\en\*('' substrings of the message/prompt text into
literal newlines.
.IP
-The \fIno-nl-expand\fP feature is used only if
+The \fIno\-nl\-expand\fP feature is used only if
the string contains \*(``\en\*('' so that there is something to convert.
.IP
For more information, see \fBWhitespace Options\fP.
.
.IP "\fB--no-ok"
-.IP "\fB--nook"
-Suppress the \*(``OK\*('' button in checklist, inputbox and menu box modes.
+Suppress the \*(``OK\*('' button, so that it is not displayed.
A script can still test if the user pressed
-the \*(``Enter\*('' key to accept the data.
+the \*(``Enter\*('' key to accept the data:
+.RS
+.bP
+The \*(``Enter\*('' key is always handled as the \*(``OK\*('' button
+when the \fB\-\-no\-ok\fP option is used.
+That is, by default it is bound to the \fILEAVE\fP virtual key.
+.IP
+When \fB\-\-no\-ok\fP is not used,
+you can use the the \fITab\fP key to move the cursor through the
+fields and buttons on the widget.
+In that case, the \*(``Enter\*('' key activates the current button
+if the cursor is positioned on a button.
+.bP
+To provide for the case where you want to activate a button
+when using \fB\-\-no\-ok\fP,
+there is another virtual key \fILEAVE\fP,
+which activates the current button.
+By default, \fB^D\fP (EOF) is bound to that key.
+.RE
.
.IP "\fB--no-shadow"
Suppress shadows that would be drawn to the right and bottom of each dialog box.
@@ -533,9 +594,9 @@ Suppress shadows that would be drawn to the right and bottom of each dialog box.
Some widgets (checklist, inputmenu, radiolist, menu) display a list
with two columns (a \*(``tag\*('' and \*(``description\*('').
The tag is useful for scripting, but may not help the user.
-The \fB--no-tags\fP option (from Xdialog) may be used to suppress the
+The \fB\-\-no\-tags\fP option (from Xdialog) may be used to suppress the
column of tags from the display.
-Unlike the \fB--no-items\fP option,
+Unlike the \fB\-\-no\-items\fP option,
this does not affect the data which is read from the script.
.IP
Xdialog does not display the tag column for the analogous buildlist
@@ -543,7 +604,7 @@ and treeview widgets; \fB\*p\fP does the same.
.IP
Normally \fB\*p\fP allows you to quickly move to entries on the displayed list,
by matching a single character to the first character of the tag.
-When the \fB--no-tags\fP option is given, \fB\*p\fP matches against
+When the \fB\-\-no\-tags\fP option is given, \fB\*p\fP matches against
the first character of the description.
In either case, the matchable character is highlighted.
.
@@ -558,7 +619,7 @@ but error messages may also be written there, depending on your script.
.IP "\fB--separator \fIstring"
.IP "\fB--output-separator \fIstring"
Specify a string that will separate the output on \fB\*p\fP's output from
-checklists, rather than a newline (for \fB--separate-output\fP) or a space.
+checklists, rather than a newline (for \fB\-\-separate\-output\fP) or a space.
This applies to other widgets such as forms and editboxes which normally
use a newline.
.
@@ -592,12 +653,14 @@ if they are omitted, \fB\*p\fP autosizes according to the screen dimensions.
.IP "\fB--print-version"
Prints \fB\*p\fR's version to \fB\*p\fP's output.
This may be used alone, without other options.
-It does not cause \fBdialog\fP to exit by itself.
+It does not cause \fB\*l\fP to exit by itself.
.
.IP "\fB--quoted"
Normally \fB\*p\fP quotes the strings returned by checklist's
as well as the item-help text.
-Use this option to quote all string results.
+Use this option to quote all string results as needed
+(i.e., if the string contains whitespace or a single or double-quote character).
+.
.IP "\fB--reorder"
By default, the buildlist widget uses the same order for the output (right)
list as for the input (left).
@@ -621,15 +684,16 @@ This is used to simplify parsing the result of a dialog with several widgets.
If this option is not given,
the default separator string is a tab character.
.
-.IP "\fB--shadow"
-Draw a shadow to the right and bottom of each dialog box.
-.
.IP "\fB--single-quoted"
Use single-quoting as needed (and no quotes if unneeded) for the
output of checklist's as well as the item-help text.
-If this option is not set, \fB\*p\fP uses double quotes around each item.
+.IP
+If this option is not set, \fB\*p\fP may use double quotes around each item.
In either case,
\fB\*p\fP adds backslashes to make the output useful in shell scripts.
+.IP
+Single quotes would be needed if
+the string contains whitespace or a single or double-quote character.
.
.IP "\fB--size-err"
Check the resulting size of a dialog box before trying to use it,
@@ -657,27 +721,34 @@ Depending on the platform and your environment, that may fail.
Convert each tab character to one or more spaces
(for the \fBtextbox\fP widget; otherwise to a single space).
Otherwise, tabs are rendered according to the curses library's interpretation.
-The \fB--no-collapse\fP option disables tab expansion.
+The \fB\-\-no\-collapse\fP option disables tab expansion.
.
.IP "\fB--tab-len \fIn"
Specify the number of spaces that a tab character occupies if the
-"\fB--tab-correct\fP" option is given.
+\*(``\fB\-\-tab\-correct\fP\*('' option is given.
The default is 8.
This option is only effective for the \fBtextbox\fP widget.
.
.IP "\fB--time-format \fIformat"
If the host provides \fBstrftime\fP,
this option allows you to specify the format of the time printed for
-the \fB--timebox\fP widget.
+the \fB\-\-timebox\fP widget.
The day, month, year values in this case are for the current local time.
.
.IP "\fB--timeout \fIsecs"
-Timeout (exit with error code)
-if no user response within the given number of seconds.
+Timeout if no user response within the given number of seconds.
A timeout of zero seconds is ignored.
.IP
-This option is ignored by the "\fB--pause\fP" widget.
-It is also overridden if the background "\fB--tailboxbg\fP" option is used
+Normally a timeout causes an ESC character to be entered in the current widget,
+cancelling it.
+Other widgets may still be on the screen;
+these are not cancelled.
+Set the \fBDIALOG_TIMEOUT\fP environment variable to tell \fB\*l\fP to
+directly exit instead, i.e., cancelling all widgets on the screen.
+.IP
+This option is ignored by the \*(``\fB\-\-pause\fP\*('' widget.
+It is also overridden
+if the background \*(``\fB\-\-tailboxbg\fP\*('' option is used
to set up multiple concurrent widgets.
.
.IP "\fB--title \fItitle"
@@ -688,17 +759,18 @@ string to be displayed at the top of the dialog box.
.IP "\fB--trace \fIfilename"
logs the command-line parameters,
keystrokes and other information to the given file.
-If \fBdialog\fP reads a configure file, it is logged as well.
+If \fB\*l\fP reads a configure file, it is logged as well.
Piped input to the \fIgauge\fP widget is logged.
Use control/T to log a picture of the current dialog window.
.IP
The \fB\*p\fR program handles some command-line parameters specially,
and removes them from the parameter list as they are processed.
-For example, if the first option is \fB--trace\fP,
+For example, if the first option is \fB\-\-trace\fP,
then that is processed (and removed) before \fB\*p\fR initializes the display.
.
.IP "\fB--week-start \fIday"
-sets the starting day for the week, used in the "\fB--calendar\fP" option.
+sets the starting day for the week,
+used in the \*(``\fB\-\-calendar\fP\*('' option.
The \fIday\fP parameter can be
.RS
.bP
@@ -721,17 +793,18 @@ The \fItrim\fP feature is implemented subject to these conditions:
.bP
the string does not contain \*(``\en\*('' or
.bP
-the \fB--no-nl-expand\fP option is used.
+the \fB\-\-no\-nl\-expand\fP option is used.
.RE
.IP
For more information, see \fBWhitespace Options\fP.
.
.IP
-See also the "\fB--cr-wrap\fR" and "\fB--no-collapse\fR" options.
+See also the \*(``\fB\-\-cr\-wrap\fR\*(''
+and \*(``\fB\-\-no\-collapse\fR\*('' options.
.
.IP "\fB--version"
Prints \fB\*p\fR's version to the standard output, and exits.
-See also "\fB--print-version\fP".
+See also \*(``\fB\-\-print\-version\fP\*(''.
.
.IP "\fB--visit-items"
Modify the tab-traversal of checklist, radiolist, menubox and inputmenu
@@ -762,7 +835,7 @@ the width of the dialog box.
Other parameters depend on the box type.
.
.
-.IP "\fB--buildlist \fItext height width list-height \fR[ \fItag item status \fR] \fI..."
+.IP "\fB\-\-buildlist \fItext height width list-height \fR[ \fItag item status \fR] \fI..."
A \fBbuildlist\fP dialog displays two lists, side-by-side.
The list on the left shows unselected items.
The list on the right shows selected items.
@@ -775,31 +848,31 @@ The results are written using the order displayed in the selected-window.
The initial on/off state of each entry is specified by
.IR status "."
.IP
-The dialog behaves like a \fBmenu\fP, using the \fB--visit-items\fP
+The dialog behaves like a \fBmenu\fP, using the \fB\-\-visit\-items\fP
to control whether the cursor is allowed to visit the lists directly.
.RS
.bP
-If \fB--visit-items\fP is not given,
+If \fB\-\-visit\-items\fP is not given,
tab-traversal uses two states (OK/Cancel).
.bP
-If \fB--visit-items\fP is given,
+If \fB\-\-visit\-items\fP is given,
tab-traversal uses four states (Left/Right/OK/Cancel).
.RE
.IP
-Whether or not \fB--visit-items\fP is given,
+Whether or not \fB\-\-visit\-items\fP is given,
it is possible to move the highlight between the two lists using
-the default "^" (left-column) and "$" (right-column) keys.
+the default \*(``^\*('' (left-column) and \*(``$\*('' (right-column) keys.
.IP
On exit, a list of the \fItag\fP
strings of those entries that are turned on
will be printed on \fB\*p\fP's output.
.IP
-If the "\fB--separate-output\fP" option is not given,
+If the "\fB\-\-separate\-output\fP" option is not given,
the strings will be quoted as needed
to make it simple for scripts to separate them.
-By default, this uses double-quotes.
-See the "\fB--single-quoted\fP" option, which modifies the quoting behavior.
-.
+By default, this uses double-quotes, as needed.
+See the \*(``\fB\-\-single\-quoted\fP\*('' option,
+which modifies the quoting behavior.
.
.IP "\fB--calendar \fItext height width day month year"
A \fBcalendar\fP box displays
@@ -813,10 +886,9 @@ Use tab or backtab to move between windows.
If the year is given as zero, the current date is used as an initial value.
.IP
On exit, the date is printed in the form day/month/year.
-The format can be overridden using the \fB--date-format\fP option.
-.
+The format can be overridden using the \fB\-\-date\-format\fP option.
.
-.IP "\fB--checklist \fItext height width list-height \fR[ \fItag item status \fR] \fI..."
+.IP "\fB\-\-checklist \fItext height width list-height \fR[ \fItag item status \fR] \fI..."
A \fBchecklist\fP box is similar to a \fBmenu\fP box;
there are multiple entries presented in the form of a menu.
Another difference is
@@ -831,14 +903,14 @@ On exit, a list of the \fItag\fP
strings of those entries that are turned on
will be printed on \fB\*p\fP's output.
.IP
-If the "\fB--separate-output\fP" option is not given,
+If the \*(``\fB\-\-separate\-output\fP\*('' option is not given,
the strings will be quoted as needed
to make it simple for scripts to separate them.
-By default, this uses double-quotes.
-See the "\fB--single-quoted\fP" option, which modifies the quoting behavior.
+By default, this uses double-quotes (as needed).
+See the \*(``\fB\-\-single\-quoted\fP\*('' option,
+which modifies the quoting behavior.
.
-.
-.IP "\fB--dselect \fIfilepath height width\fR"
+.IP "\fB\-\-dselect \fIfilepath height width\fR"
The directory-selection dialog displays a text-entry window
in which you can type a directory,
and above that a windows with directory names.
@@ -865,13 +937,13 @@ in the text-entry window and exit.
On exit, the contents of the text-entry window are written
to \fB\*p\fP's output.
.
-.IP "\fB--editbox \fIfilepath height width\fR"
+.IP "\fB\-\-editbox \fIfilepath height width\fR"
The edit-box dialog displays a copy of the file.
You may edit it using
the \fIbackspace\fP, \fIdelete\fP and cursor keys
to correct typing errors.
It also recognizes pageup/pagedown.
-Unlike the \fB--inputbox\fP,
+Unlike the \fB\-\-inputbox\fP,
you must tab to the \*(``OK\*('' or \*(``Cancel\*('' buttons
to close the dialog.
Pressing the \*(``Enter\*('' key within the box will split
@@ -880,7 +952,7 @@ the corresponding line.
On exit, the contents of the edit window are written to \fB\*p\fP's output.
.
.nf
-.IP "\fB--form \fItext height width formheight \fR[ \fIlabel y x item y x flen ilen \fR] \fI..."
+.IP "\fB\-\-form \fItext height width formheight \fR[ \fIlabel y x item y x flen ilen \fR] \fI..."
.fi
The \fBform\fP dialog displays a form consisting of labels and fields,
which are positioned on a scrollable window by coordinates given in the script.
@@ -910,7 +982,7 @@ The text used to fill non-editable fields
is not written out.
.
.
-.IP "\fB--fselect \fIfilepath height width\fR"
+.IP "\fB\-\-fselect \fIfilepath height width\fR"
The \fBfselect\fP (file-selection) dialog displays a text-entry window
in which you can type a filename (or directory),
and above that two windows with directory names and filenames.
@@ -942,7 +1014,7 @@ On exit, the contents of the text-entry window are written
to \fB\*p\fP's output.
.
.
-.IP "\fB--gauge \fItext height width [percent]\fR"
+.IP "\fB\-\-gauge \fItext height width [percent]\fR"
A
\fBgauge\fP
box displays a meter along the bottom of the box.
@@ -994,7 +1066,7 @@ can fit in the dialog box, the input field will be scrolled.
On exit, the input string will be printed on \fB\*p\fP's output.
.
.
-.IP "\fB--inputmenu \fItext height width menu-height \fR[ \fItag item \fR] \fI..."
+.IP "\fB\-\-inputmenu \fItext height width menu-height \fR[ \fItag item \fR] \fI..."
An \fBinputmenu\fP box is very similar to an ordinary \fBmenu\fP box.
There are only a few differences between them:
.RS
@@ -1016,7 +1088,7 @@ RENAMED <tag> <item>
.RE
.
.
-.IP "\fB--menu \fItext height width menu-height \fR[ \fItag item \fR] \fI..."
+.IP "\fB\-\-menu \fItext height width menu-height \fR[ \fItag item \fR] \fI..."
As its name suggests, a
\fBmenu\fP
box is a dialog box that can be used to present a list of choices in
@@ -1036,14 +1108,14 @@ scrolled if there are more entries than that.
.IP
On exit the \fItag\fP
of the chosen menu entry will be printed on \fB\*p\fP's output.
-If the "\fB--help-button\fR" option is given, the corresponding help
+If the \*(``\fB\-\-help\-button\fR\*('' option is given, the corresponding help
text will be printed if the user selects the help button.
.
.nf
-.IP "\fB--mixedform \fItext height width formheight \fR[ \fIlabel y x item y x flen ilen itype \fR] \fI..."
+.IP "\fB\-\-mixedform \fItext height width formheight \fR[ \fIlabel y x item y x flen ilen itype \fR] \fI..."
.fi
The \fBmixedform\fP dialog displays a form consisting of labels and fields,
-much like the \fB--form\fP dialog.
+much like the \fB\-\-form\fP dialog.
It differs by adding a field-type parameter to each field's description.
Each bit in the type denotes an attribute of the field:
.RS
@@ -1055,7 +1127,7 @@ hidden, e.g., a password field.
readonly, e.g., a label.
.RE
.
-.IP "\fB--mixedgauge \fItext height width percent \fR[ \fItag1 item1 \fR] \fI..."
+.IP "\fB\-\-mixedgauge \fItext height width percent \fR[ \fItag1 item1 \fR] \fI..."
A \fBmixedgauge\fP box displays a meter along the bottom of the box.
The meter indicates the percentage.
.IP
@@ -1066,7 +1138,7 @@ See \*l(3) for the tag values.
The \fItext\fP is shown as a caption between the list and meter.
The \fIpercent\fR value denotes the initial percentage shown in the meter.
.IP
-No provision is made for reading data from the standard input as \fB--gauge\fP
+No provision is made for reading data from the standard input as \fB\-\-gauge\fP
does.
.IP
On exit, no text is written to \fB\*p\fP's output.
@@ -1089,7 +1161,7 @@ On exit, no text is written to \fB\*p\fP's output.
Only an \*(``OK\*('' button is provided for input,
but an ESC exit status may be returned.
.
-.IP "\fB--pause \fItext height width seconds\fR"
+.IP "\fB\-\-pause \fItext height width seconds\fR"
A
\fBpause\fP
box displays a meter along the bottom of the box.
@@ -1110,15 +1182,15 @@ Also, it
is very confusing to the user to provide them with a default password they
cannot see.
For these reasons, using \*(``init\*('' is highly discouraged.
-See "\fB--insecure\fP" if you do not care about your password.
+See \*(``\fB\-\-insecure\fP\*('' if you do not care about your password.
.IP
On exit, the input string will be printed on \fB\*p\fP's output.
.
.
.nf
-.IP "\fB--passwordform \fItext height width formheight \fR[ \fIlabel y x item y x flen ilen \fR] \fI..."
+.IP "\fB\-\-passwordform \fItext height width formheight \fR[ \fIlabel y x item y x flen ilen \fR] \fI..."
.fi
-This is identical to \fB--form\fP except that all text fields are
+This is identical to \fB\-\-form\fP except that all text fields are
treated as \fBpassword\fP widgets rather than \fBinputbox\fP widgets.
.
.
@@ -1130,11 +1202,11 @@ This dialog box is used to display the output of a command that is
specified as an argument to \fBprgbox\fP.
.IP
After the command completes, the user can press the \fIENTER\fP key so that
-\fBdialog\fP will exit and the calling shell script can continue its operation.
+\fB\*l\fP will exit and the calling shell script can continue its operation.
.IP
-If three parameters are given, it displays the text under the title,
+If four parameters are given, it displays the text under the title,
delineated from the scrolling file's contents.
-If only two parameters are given, this text is omitted.
+If only three parameters are given, this text is omitted.
.
.
.IP "\fB--programbox \fItext height width"
@@ -1146,7 +1218,7 @@ box is that a \fBprogram\fP box displays an \fBOK\fP button
.IP
This dialog box is used to display the piped output of a command.
After the command completes, the user can press the \fIENTER\fP key so that
-\fBdialog\fP will exit and the calling shell script can continue its operation.
+\fB\*l\fP will exit and the calling shell script can continue its operation.
.IP
If three parameters are given, it displays the text under the title,
delineated from the scrolling file's contents.
@@ -1171,7 +1243,7 @@ delineated from the scrolling file's contents.
If only two parameters are given, this text is omitted.
.
.
-.IP "\fB--radiolist \fItext height width list-height \fR [ \fItag item status \fR] \fI..."
+.IP "\fB\-\-radiolist \fItext height width list-height \fR [ \fItag item status \fR] \fI..."
A \fBradiolist\fP box is similar to a \fBmenu\fP box.
The only difference is
that you can indicate which entry is currently selected, by setting its
@@ -1180,16 +1252,6 @@ that you can indicate which entry is currently selected, by setting its
On exit, the tag of the selected item is written to \fB\*p\fP's output.
.
.
-.IP "\fB--tailbox \fIfile height width"
-Display text from a file in a dialog box, as in a "tail -f" command.
-Scroll left/right using vi-style 'h' and 'l', or arrow-keys.
-A '0' resets the scrolling.
-.IP
-On exit, no text is written to \fB\*p\fP's output.
-Only an \*(``OK\*('' button is provided for input,
-but an ESC exit status may be returned.
-.
-.
.nf
.IP "\fB--rangebox \fItext height width min-value max-value default-value"
.fi
@@ -1220,21 +1282,33 @@ increment the value so that the slider moves by one column
.RE
.
.
+.IP "\fB--tailbox \fIfile height width"
+Display text from a file in a dialog box,
+as in a \*(``tail -f\*('' command.
+Scroll left/right using vi-style 'h' and 'l', or arrow-keys.
+A '0' resets the scrolling.
+.IP
+On exit, no text is written to \fB\*p\fP's output.
+Only an \*(``OK\*('' button is provided for input,
+but an ESC exit status may be returned.
+.
+.
.IP "\fB--tailboxbg \fIfile height width"
Display text from a file in a dialog box as a background task,
-as in a "tail -f &" command.
+as in a \*(``tail -f &\*('' command.
Scroll left/right using vi-style 'h' and 'l', or arrow-keys.
A '0' resets the scrolling.
.IP
\*L treats the background task specially if there are other
-widgets (\fB--and-widget\fP) on the screen concurrently.
+widgets (\fB\-\-and\-widget\fP) on the screen concurrently.
Until those widgets are closed (e.g., an \*(``OK\*(''),
\fB\*p\fP will perform all of the tailboxbg widgets in the same process,
polling for updates.
You may use a tab to traverse between the widgets on the screen,
and close them individually, e.g., by pressing \fIENTER\fP.
-Once the non-tailboxbg widgets are closed, \fB\*p\fP forks a copy of itself
-into the background, and prints its process id if the "\fB--no-kill\fP" option
+Once the non-tailboxbg widgets are closed,
+\fB\*p\fP forks a copy of itself into the background,
+and prints its process id if the \*(``\fB\-\-no\-kill\fP\*('' option
is given.
.IP
On exit, no text is written to \fB\*p\fP's output.
@@ -1282,10 +1356,10 @@ left-, up-, right- and down-arrows.
Use tab or backtab to move between windows.
.IP
On exit, the result is printed in the form hour:minute:second.
-The format can be overridden using the \fB--time-format\fP option.
+The format can be overridden using the \fB\-\-time\-format\fP option.
.
.
-.IP "\fB--treeview \fItext height width list-height \fR[ \fItag item status depth \fR] \fI..."
+.IP "\fB\-\-treeview \fItext height width list-height \fR[ \fItag item status depth \fR] \fI..."
Display data organized as a tree.
Each group of data contains a tag,
the text to display for the item,
@@ -1357,46 +1431,47 @@ as dialog reads the script:
The options are not independent:
.bP
\fB\*L\fP checks if the script contains at least one \*(``\en\*(''
-and (unless \fB--no-nl-expand\fP is set) will ignore the
-\fB--no-collapse\fP and \fB--trim\fP options.
+and (unless \fB\-\-no\-nl\-expand\fP is set) will ignore the
+\fB\-\-no\-collapse\fP and \fB\-\-trim\fP options.
.bP
-After checking for \*(``\en\*('' and the \fB--no-nl-expand\fP option,
-\fB\*l\fP handles the \fB--trim\fP option.
+After checking for \*(``\en\*('' and the \fB\-\-no\-nl\-expand\fP option,
+\fB\*l\fP handles the \fB\-\-trim\fP option.
.IP
-If the \fB--trim\fP option takes effect,
-then \fB\*l\fP ignores \fB--no-collapse\fP.
+If the \fB\-\-trim\fP option takes effect,
+then \fB\*l\fP ignores \fB\-\-no\-collapse\fP.
It changes sequences of tabs, spaces
-(and newlines unless \fB-cr-wrap\fP is set) to a single space.
+(and newlines unless \fB\-cr\-wrap\fP is set) to a single space.
.bP
-If neither the \*(``\en\*('' or \fB--trim\fP cases apply,
-\fB\*l\fP checks \fB--no-collapse\fP to decide whether to reduce
+If neither the \*(``\en\*('' or \fB\-\-trim\fP cases apply,
+\fB\*l\fP checks \fB\-\-no\-collapse\fP to decide whether to reduce
sequences of tabs and spaces to a single space.
.IP
-In this case, \fB\*l\fP ignores \fB-cr-wrap\fP and does not modify newlines.
+In this case, \fB\*l\fP ignores \fB\-\-cr\-wrap\fP and does not modify newlines.
.PP
Taking those dependencies into account,
here is a table summarizing the behavior
for the various combinations of options.
The table assumes that the script contains at least one \*(``\en\*(''
-when the \fB--no-nl-expand\fP option is not set.
+when the \fB\-\-no\-nl\-expand\fP option is not set.
.na
+.RS 5
.TS
-center tab(/) ;
+tab(/) ;
lB lB lB lB lB
lB lB lB lB lB
_ _ _ _ _
-lw5 lw5 lw5 lw5 lw30.
+lw4 lw4 lw4 lw4 lw29.
cr-/no-/no-/trim/Result
wrap/collapse/nl-expand
no/no/no/no/T{
Convert tab to space.
Convert newline to space.
-Convert \*(``\en\*('' to newline.
+Convert \*(``\en\*('' to newline.
T}
no/no/no/yes/T{
Convert tab to space.
Convert newline to space.
-Convert \*(``\en\*('' to newline.
+Convert \*(``\en\*('' to newline.
T}
no/no/yes/no/T{
Convert tab to space.
@@ -1412,11 +1487,11 @@ Show \*(``\en\*('' literally.
T}
no/yes/no/no/T{
Convert newline to space.
-Convert \*(``\en\*('' to newline.
+Convert \*(``\en\*('' to newline.
T}
no/yes/no/yes/T{
Convert newline to space.
-Convert \*(``\en\*('' to newline.
+Convert \*(``\en\*('' to newline.
T}
no/yes/yes/no/T{
Do not convert newline to space.
@@ -1431,12 +1506,12 @@ T}
yes/no/no/no/T{
Convert tab to space.
Wrap on newline.
-Convert \*(``\en\*('' to newline.
+Convert \*(``\en\*('' to newline.
T}
yes/no/no/yes/T{
Convert tab to space.
Wrap on newline.
-Convert \*(``\en\*('' to newline.
+Convert \*(``\en\*('' to newline.
T}
yes/no/yes/no/T{
Convert tab to space.
@@ -1452,11 +1527,11 @@ Show \*(``\en\*('' literally.
T}
yes/yes/no/no/T{
Wrap on newline.
-Convert \*(``\en\*('' to newline.
+Convert \*(``\en\*('' to newline.
T}
yes/yes/no/yes/T{
Wrap on newline.
-Convert \*(``\en\*('' to newline.
+Convert \*(``\en\*('' to newline.
T}
yes/yes/yes/no/T{
Do not convert newline to space.
@@ -1469,6 +1544,7 @@ Wrap on newline.
Show \*(``\en\*('' literally.
T}
.TE
+.RE
.ad
.
.\" ************************************************************************
@@ -1478,7 +1554,7 @@ T}
Create a sample configuration file by typing:
.LP
.Ex
-\*p --create-rc \fIfile\fP
+\*p \-\-create\-rc \fIfile\fP
.Ee
.TP 4
2.
@@ -1519,16 +1595,43 @@ by adding to the configuration file.
bindkey \fIwidget\fP \fIcurses_key\fP \fIdialog_key\fP
.Ee
.PP
-The \fIwidget\fP name can be "*" (all widgets), or
+The \fIwidget\fP name can be \*(``*\*('' (all widgets), or
specific widgets such as \fBtextbox\fP.
-Specific widget bindings override the "*" bindings.
+Specific widget bindings override the \*(``*\*('' bindings.
User-defined bindings override the built-in bindings.
.PP
-The \fIcurses_key\fP can be any of the names derived from
+The \fIcurses_key\fP can be expressed in different forms:
+.bP
+It may be any of the names derived from
\fBcurses.h\fP, e.g., \*(``HELP\*('' from \*(``KEY_HELP\*(''.
-\fB\*L\fP also recognizes ANSI control characters such as "^A", "^?",
-as well as C1-controls such as "~A" and "~?".
-Finally, it allows any single character to be escaped with a backslash.
+.bP
+\fB\*L\fP also recognizes ANSI control characters
+such as \*(``^A\*('', \*(``^?\*('',
+as well as C1-controls such as \*(``~A\*('' and \*(``~?\*(''.
+.bP
+Finally, \fB\*l\fP allows backslash escapes as in C.
+Those can be octal character values such as \*(``\\033\*(''
+(the ASCII escape character),
+or the characters listed in this table:
+.RS 10
+.TS
+tab(/) ;
+lI lI
+_ _
+l l .
+Escaped/Actual
+\\b/backspace
+\\f/form feed
+\\n/new line (line feed)
+\\r/carriage return
+\\s/space
+\\t/tab
+\\^/\*(``^\*('' (caret)
+\\?/\*(``?\*('' (question mark)
+\\\\/\*(``\\\*('' (backslash)
+_
+.TE
+.RE
.PP
\fB\*L\fP's internal keycode names correspond to the
\fBDLG_KEYS_ENUM\fP type in
@@ -1539,8 +1642,9 @@ Some widgets (such as the formbox) have an area where fields can be edited.
Those are managed in a subwindow of the widget, and
may have separate keybindings from the main widget
because the subwindows are registered using a different name.
+.RS 5
.TS
-center tab(/) ;
+tab(/) ;
lI lI lI
_ _ _
l l l .
@@ -1562,12 +1666,14 @@ timebox/timebox
yesno/yesno
_
.TE
+.RE
.PP
Some widgets are actually other widgets,
using internal settings to modify the behavior.
Those use the same widget name as the actual widget:
+.RS 5
.TS
-center tab(/) ;
+tab(/) ;
lI lI
_ _
l l .
@@ -1583,10 +1689,11 @@ programbox/progressbox
tailboxbg/tailbox
_
.TE
+.RE
.SS Built-in Bindings
This manual page does not list the key bindings for each widget,
because that detailed information can be obtained by running \fB\*p\fP.
-If you have set the \fB--trace\fP option,
+If you have set the \fB\-\-trace\fP option,
\fB\*p\fP writes the key-binding information for each widget
as it is registered.
.SS Example
@@ -1622,10 +1729,10 @@ Define this variable to apply any of the common options to each widget.
Most of the common options are reset before processing each widget.
If you set the options in this environment variable,
they are applied to \fB\*p\fP's state after the reset.
-As in the "\fB--file\fP" option,
+As in the \*(``\fB\-\-file\fP\*('' option,
double-quotes and backslashes are interpreted.
.IP
-The "\fB--file\fP" option is not considered a common option
+The \*(``\fB\-\-file\fP\*('' option is not considered a common option
(so you cannot embed it within this environment variable).
.TP 15
\fBDIALOGRC\fP
@@ -1644,21 +1751,35 @@ to use.
.TP 15
\fBDIALOG_ITEM_HELP\fP
.TP 15
+\fBDIALOG_TIMEOUT\fP
+.TP 15
\fBDIALOG_OK\fP
Define any of these variables to change the exit code on
+.RS
+.bP
Cancel (1),
+.bP
error (\-1),
+.bP
ESC (255),
+.bP
Extra (3),
+.bP
Help (2),
-Help with \fB--item-help\fP (2),
-or OK (0).
+.bP
+Help with \fB\-\-item\-help\fP (2),
+.bP
+Timeout (5), or
+.bP
+OK (0).
+.RE
+.IP
Normally shell scripts cannot distinguish between \-1 and 255.
.TP 15
\fBDIALOG_TTY\fP
Set this variable to \*(``1\*('' to provide compatibility with older versions
of \fB\*p\fP which assumed that if the script redirects the standard output,
-that the "\fB--stdout\fP" option was given.
+that the \*(``\fB\-\-stdout\fP\*('' option was given.
.SH FILES
.TP 20
\fI$HOME/.dialogrc\fP
@@ -1697,7 +1818,7 @@ if the
.B Help
button is pressed,
.br
-and the \fB--item-help\fP option is set
+and the \fB\-\-item\-help\fP option is set
.br
and the DIALOG_ITEM_HELP environment variable is set to 4.
.IP
@@ -1707,6 +1828,9 @@ this special case was introduced in 2004 to simplify compatibility.
but unless the environment variable is also set,
it changes that to DIALOG_HELP(2) on exit.
.TP 5
+5
+if a timeout expires and the \fBDIALOG_TIMEOUT\fP variable is set to 5.
+.TP 5
\-1
if errors occur inside \fB\*p\fP (DIALOG_ERROR)
or \fB\*p\fP exits because the \fIESC\fP key (DIALOG_ESC) was pressed.
@@ -1719,7 +1843,7 @@ However, some implementations have deficiencies:
.bP
HPUX curses (and perhaps others) do not open the terminal properly for
the \fInewterm\fP function.
-This interferes with \fB\*p\fP's \fB--input-fd\fP option,
+This interferes with \fB\*p\fP's \fB\-\-input\-fd\fP option,
by preventing cursor-keys and similar escape sequences from being recognized.
.bP
NetBSD 5.1 curses has incomplete support for wide-characters.
@@ -1728,9 +1852,9 @@ NetBSD 5.1 curses has incomplete support for wide-characters.
.\" ************************************************************************
.SH COMPATIBILITY
You may want to write scripts which run with
-other \fBdialog\fP \*(``clones\*(''.
+other \fB\*l\fP \*(``clones\*(''.
.SS Original Dialog
-First, there is the \*(``original\*('' \fBdialog\fP program to consider
+First, there is the \*(``original\*('' \fB\*p\fP program to consider
(versions 0.3 to 0.9).
It had some misspelled (or inconsistent) options.
The \fB\*p\fP program maps those deprecated options to the preferred ones.
@@ -1742,15 +1866,15 @@ lI lI
_ _
l l.
Option/Treatment
-\fB--beep-after\fP/ignored
-\fB--guage\fP/mapped to \fB--gauge\fP
+\fB\-\-beep\-after\fP/ignored
+\fB\-\-guage\fP/mapped to \fB\-\-gauge\fP
_
.TE
.RE
.SS Xdialog
This is an X application, rather than a terminal program.
With some care, it is possible to write useful scripts that work
-with both \fBXdialog\fP and \fBdialog\fP.
+with both \fBXdialog\fP and \fB\*p\fP.
.PP
The \fB\*p\fP program ignores these options which are recognized
by \fBXdialog\fP:
@@ -1761,18 +1885,18 @@ lI lI
_ _
l l.
Option/Treatment
-\fB--allow-close\fP/ignored
-\fB--auto-placement\fP/ignored
-\fB--fixed-font\fP/ignored
-\fB--icon\fP/ignored
-\fB--keep-colors\fP/ignored
-\fB--no-close\fP/ignored
-\fB--no-cr-wrap\fP/ignored
-\fB--screen-center\fP/ignored
-\fB--separator\fP/mapped to \fB--separate-output\fP
-\fB--smooth\fP/ignored
-\fB--under-mouse\fP/ignored
-\fB--wmclass\fP/ignored
+\fB\-\-allow\-close\fP/ignored
+\fB\-\-auto\-placement\fP/ignored
+\fB\-\-fixed\-font\fP/ignored
+\fB\-\-icon\fP/ignored
+\fB\-\-keep\-colors\fP/ignored
+\fB\-\-no\-close\fP/ignored
+\fB\-\-no\-cr\-wrap\fP/ignored
+\fB\-\-screen\-center\fP/ignored
+\fB\-\-separator\fP/mapped to \fB\-\-separate\-output\fP
+\fB\-\-smooth\fP/ignored
+\fB\-\-under\-mouse\fP/ignored
+\fB\-\-wmclass\fP/ignored
_
.TE
.RE
@@ -1783,13 +1907,13 @@ There are some differences not shown in the manpage.
For example, the html documentation states
.RS
.PP
-Note: former Xdialog releases used the "\en" (line feed) as a
+Note: former Xdialog releases used the \*(``\en\*('' (line feed) as a
results separator for the checklist widget;
-this has been changed to "/" in Xdialog v1.5.0
+this has been changed to \*(``/\*('' in Xdialog v1.5.0
to make it compatible with (c)dialog.
In your old scripts using the Xdialog checklist, you
-will then have to add the \fB--separate-output\fP option before the
-\fB--checklist\fP one.
+will then have to add the \fB\-\-separate\-output\fP option before the
+\fB\-\-checklist\fP one.
.RE
.PP
\fB\*L\fP has not used a different separator;
@@ -1829,17 +1953,17 @@ but oddly cites only \fB\*p\fP versions up to 0.4 (1994) as a source.
That is, its manpage refers to features which
were borrowed from more recent versions of \fB\*p\fP, e.g.,
.bP
-\fB--gauge\fP (from 0.5)
+\fB\-\-gauge\fP (from 0.5)
.bP
-\fB--passwordbox\fP (from Debian changes in 1999),
+\fB\-\-passwordbox\fP (from Debian changes in 1999),
.bP
-\fB--default-item\fP (from \fB\*p\fP 2000/02/22),
+\fB\-\-default\-item\fP (from \fB\*p\fP 2000/02/22),
.bP
-\fB--output-fd\fP (from \fB\*p\fP 2002/08/14).
+\fB\-\-output\-fd\fP (from \fB\*p\fP 2002/08/14).
.PP
Somewhat humorously, one may note that the \fBpopt\fP feature
(undocumented in its manpage)
-of using a "--" as an escape was documented in \fB\*p\fP's manpage about
+of using a \*(``--\*('' as an escape was documented in \fB\*p\fP's manpage about
a year before it was mentioned in \fBwhiptail\fP's manpage.
\fBwhiptail\fP's manpage incorrectly attributes that to \fBgetopt\fP
(and is inaccurate anyway).
@@ -1855,17 +1979,17 @@ lI lI
_ _
l l.
Option/Treatment
-\fB--cancel-button\fP/mapped to \fB--cancel-label\fP
-\fB--fb\fP/ignored
-\fB--fullbutton\fP/ignored
-\fB--no-button\fP/mapped to \fB--no-label\fP
-\fB--nocancel\fP/mapped to \fB--no-cancel\fP
-\fB--noitem\fP/mapped to \fB--no-items\fP
-\fB--notags\fP/mapped to \fB--no-tags\fP
-\fB--ok-button\fP/mapped to \fB--ok-label\fP
-\fB--scrolltext\fP/mapped to \fB--scrollbar\fP
-\fB--topleft\fP/mapped to \fB--begin 0 0\fP
-\fB--yes-button\fP/mapped to \fB--yes-label\fP
+\fB\-\-cancel\-button\fP/mapped to \fB\-\-cancel\-label\fP
+\fB\-\-fb\fP/ignored
+\fB\-\-fullbutton\fP/ignored
+\fB\-\-no\-button\fP/mapped to \fB\-\-no\-label\fP
+\fB\-\-nocancel\fP/mapped to \fB\-\-no\-cancel\fP
+\fB\-\-noitem\fP/mapped to \fB\-\-no\-items\fP
+\fB\-\-notags\fP/mapped to \fB\-\-no\-tags\fP
+\fB\-\-ok\-button\fP/mapped to \fB\-\-ok\-label\fP
+\fB\-\-scrolltext\fP/mapped to \fB\-\-scrollbar\fP
+\fB\-\-topleft\fP/mapped to \fB\-\-begin 0 0\fP
+\fB\-\-yes\-button\fP/mapped to \fB\-\-yes\-label\fP
_
.TE
.RE
@@ -1875,7 +1999,8 @@ There are visual differences which are not addressed by command-line options:
\fB\*p\fP centers lists within the window.
\fBwhiptail\fP typically puts lists against the left margin.
.bP
-\fBwhiptail\fP uses angle brackets ("<" and ">") for marking buttons.
+\fBwhiptail\fP uses angle brackets (\*(``<\*('' and \*(``>\*('')
+for marking buttons.
\fB\*p\fP uses square brackets.
.bP
\fBwhiptail\fP marks the limits of subtitles with vertical bars.
diff --git a/dialog.3 b/dialog.3
index 80c0dd0c8f3b..efa45d0a9456 100644
--- a/dialog.3
+++ b/dialog.3
@@ -1,6 +1,6 @@
'\" t
-.\" $Id: dialog.3,v 1.121 2018/06/20 01:21:53 tom Exp $
-.\" Copyright 2005-2017,2018 Thomas E. Dickey
+.\" $Id: dialog.3,v 1.138 2021/01/17 18:02:44 tom Exp $
+.\" Copyright 2005-2020,2021 Thomas E. Dickey
.\"
.\" This program is free software; you can redistribute it and/or modify
.\" it under the terms of the GNU Lesser General Public License, version 2.1
@@ -47,15 +47,15 @@
.el .ds `` ``
.ie \n(.g .ds '' \(rq
.el .ds '' ''
-.TH \*D 3 "" "$Date: 2018/06/20 01:21:53 $"
+.TH \*D 3 "" "$Date: 2021/01/17 18:02:44 $"
.SH NAME
dialog \- widgets and utilities for the \*p program
.SH SYNOPSIS
-.B cc [ flag ... ] file ... -l\*l [ library ... ]
+.B cc [ flag ... ] file ... \-l\*l [ library ... ]
.br
\ \ \ or
.br
-.B cc $(\*p-config --cflags) file ... $(\*p-config --libs) ]
+.B cc $(\*p\-config \-\-cflags) file ... $(\*p\-config \-\-libs) ]
.sp
.B #include <\*l.h>
.PP
@@ -80,7 +80,7 @@ int main(void)
int status;
init_dialog(stdin, stdout);
status = dialog_yesno(
- "Hello, in dialog-format",
+ "Hello, in dialog\-format",
"Hello World!",
0, 0);
end_dialog();
@@ -112,7 +112,7 @@ to the widget functions.
Some of those parameters are single values,
but some of the widgets accept data as an array of values.
Those include checklist/radiobox, menubox and formbox.
-When the \fB--item-help\fP option is given, an extra column
+When the \fB\-\-item\-help\fP option is given, an extra column
of data is expected.
The USE_ITEM_HELP(), CHECKBOX_TAGS, MENUBOX_TAGS and FORMBOX_TAGS
macros are used to hide this difference from the calling application.
@@ -152,7 +152,7 @@ The \fBdlg_del_window\fP function uses this to locate windows which
may be redrawn after deleting a window.
.\" ---------------------------------------------------------------------------
.SS .aspect_ratio
-This corresponds to the command-line option "\fB--aspect-ratio\fP".
+This corresponds to the command-line option "\fB\-\-aspect\-ratio\fP".
The value gives the application
some control over the box dimensions when using auto
sizing (specifying 0 for height and width).
@@ -175,8 +175,14 @@ If the control window for \fIDIALOG_STATE.getc_callbacks\fP is
closed, the list is transferred to this variable.
Closing all windows causes the application to exit.
.\" ---------------------------------------------------------------------------
+.SS .had_resize
+This is set to TRUE
+in \fBdlg_will_resize\fP or \fBdlg_result_key\fP
+when \fBKEY_RESIZE\fP is read,
+to tell \fB\*p\fP to ignore subsequent \fBERR\fPs.
+.\" ---------------------------------------------------------------------------
.SS .no_mouse
-This corresponds to the command-line option "\fB--no-mouse\fP".
+This corresponds to the command-line option "\fB\-\-no\-mouse\fP".
If true, \fB\*p\fP will not initialize (and enable) the mouse in
\fIinit_dialog\fP.
.\" ---------------------------------------------------------------------------
@@ -187,7 +193,7 @@ Normally that is the standard error,
since the curses library prefers to write its data to the standard output.
Some scripts, trading portability for convenience,
prefer to write results to the standard output,
-e.g., by using the "\fB--stdout\fP" option.
+e.g., by using the "\fB\-\-stdout\fP" option.
.\" ---------------------------------------------------------------------------
.SS .output_count
This is incremented by \fBdlg_does_output\fP,
@@ -202,7 +208,7 @@ This is set in \fIinit_dialog\fP to a stream which can be used by the
\fBgauge\fP widget, which must be the application's standard input.
The \fB\*p\fP application calls \fIinit_dialog\fP normally with
\fIinput\fP set to the standard input, but optionally based on the
-"\fB--input-fd\fP" option.
+"\fB\-\-input\-fd\fP" option.
Since the application cannot read from
a pipe (standard input) and at the same time read
the curses input from the standard input,
@@ -211,6 +217,14 @@ a specific file descriptor,
or directly from the terminal.
The adjusted pipe stream value is stored in this variable.
.\" ---------------------------------------------------------------------------
+.SS .screen_height
+The text-formatting functions use this for the number of rows used for
+formatting a string.
+.LP
+It is used by \fB\*l\fP for the command-line options
+"\fB\-\-print\-text\-size\fP" and
+"\fB\-\-print\-text\-only\fP".
+.\" ---------------------------------------------------------------------------
.SS .screen_initialized
This is set in \fIinit_dialog\fP and
reset in \fIend_dialog\fP.
@@ -224,8 +238,16 @@ Normally that is the standard output,
unless that happens to not be a terminal (and if \fIinit_dialog\fP can
successfully open the terminal directly).
.\" ---------------------------------------------------------------------------
+.SS .screen_width
+The text-formatting functions use this for the number of columns used for
+formatting a string.
+.LP
+It is used by \fB\*l\fP for the command-line options
+"\fB\-\-print\-text\-size\fP" and
+"\fB\-\-print\-text\-only\fP".
+.\" ---------------------------------------------------------------------------
.SS .separate_str
-This corresponds to the command-line option "\fB--separate-widget\fP".
+This corresponds to the command-line option "\fB\-\-separate\-widget\fP".
The given string
specifies a string that will separate the output on \fB\*p\fP's output from
each widget.
@@ -234,22 +256,22 @@ If this option is not given,
the default separator string is a tab character.
.\" ---------------------------------------------------------------------------
.SS .tab_len
-This corresponds to the command-line option "\fB--tab-len\fP \fInumber\/\fP".
+This corresponds to the command-line option "\fB\-\-tab\-len\fP \fInumber\/\fP".
Specify the number of spaces that a tab character occupies if the
-"\fB--tab-correct\fP"
+"\fB\-\-tab\-correct\fP"
option is given.
The default is 8.
.\" ---------------------------------------------------------------------------
.SS .text_height
-This text-formatting functions set this to the number of lines used for
+The text-formatting functions set this to the number of lines used for
formatting a string.
.LP
It is used by \fB\*l\fP for the command-line options
-"\fB--print-text-size\fP" and
-"\fB--print-text-only\fP".
+"\fB\-\-print\-text\-size\fP" and
+"\fB\-\-print\-text\-only\fP".
.\" ---------------------------------------------------------------------------
.SS .text_only
-\fB\*L\fP uses this in the command-line option "\fB--print-text-only\fP".
+\fB\*L\fP uses this in the command-line option "\fB\-\-print\-text\-only\fP".
.LP
The text-formatting functions
(\fBdlg_print_text\fP,
@@ -263,33 +285,33 @@ Also,
\fBinit_dialog\fP is called.
.\" ---------------------------------------------------------------------------
.SS .text_width
-This text-formatting functions set this to the number of columns used for
+The text-formatting functions set this to the number of columns used for
formatting a string.
.LP
It is used by \fB\*l\fP for the command-line options
-"\fB--print-text-size\fP" and
-"\fB--print-text-only\fP".
+"\fB\-\-print\-text\-size\fP" and
+"\fB\-\-print\-text\-only\fP".
.\" ---------------------------------------------------------------------------
.SS .trace_output
-This corresponds to the command-line option "\fB--trace\fP \fIfile\fP".
+This corresponds to the command-line option "\fB\-\-trace\fP \fIfile\fP".
It is the file pointer to which trace messages are written.
.\" ---------------------------------------------------------------------------
.SS .use_colors
This is set in \fIinit_dialog\fP if the curses implementation supports color.
.\" ---------------------------------------------------------------------------
.SS .use_scrollbar
-This corresponds to the command-line option "\fB--scrollbar\fP".
+This corresponds to the command-line option "\fB\-\-scrollbar\fP".
If true,
draw a scrollbar to make windows holding scrolled data more readable.
.\" ---------------------------------------------------------------------------
.SS .use_shadow
-This corresponds to the command-line option "\fB--no-shadow\fP".
+This corresponds to the command-line option "\fB\-\-no\-shadow\fP".
This is set in \fIinit_dialog\fP if the curses implementation supports color.
If true,
suppress shadows that would be drawn to the right and bottom of each dialog box.
.\" ---------------------------------------------------------------------------
.SS .visit_items
-This corresponds to the command-line option "\fB--visit-items\fP".
+This corresponds to the command-line option "\fB\-\-visit\-items\fP".
Modify the tab-traversal of the list-oriented widgets
(buildlist, checklist, radiobox, menubox, inputmenu, and treeview)
to include the list of items as one of the states.
@@ -309,38 +331,38 @@ In contrast to \fBDIALOG_STATE\fP, the members of \fBDIALOG_VARS\fP
are set by command-line options in \fB\*p\fP.
.\" ---------------------------------------------------------------------------
.SS .ascii_lines
-This corresponds to the command-line option "\fB--ascii-lines\fP.
-It causes line-drawing to be done with ASCII characters, e.g., "+" and "-".
+This corresponds to the command-line option "\fB\-\-ascii\-lines\fP.
+It causes line-drawing to be done with ASCII characters, e.g., "+" and "\-".
See \fIDIALOG_VARS.no_lines\fP.
.\" ---------------------------------------------------------------------------
.SS .backtitle
This corresponds to the command-line option
-"\fB--backtitle\fP \fIbacktitle\/\fP".
+"\fB\-\-backtitle\fP \fIbacktitle\/\fP".
It specifies a
\fIbacktitle\fP
string to be displayed on the backdrop, at the top of the screen.
.\" ---------------------------------------------------------------------------
.SS .beep_after_signal
-This corresponds to the command-line option "\fB--beep-after\fP".
+This corresponds to the command-line option "\fB\-\-beep\-after\fP".
If true, beep after a user has completed a widget
by pressing one of the buttons.
.\" ---------------------------------------------------------------------------
.SS .beep_signal
-This corresponds to the command-line option "\fB--beep\fP".
+This corresponds to the command-line option "\fB\-\-beep\fP".
It is obsolete.
.\" ---------------------------------------------------------------------------
.SS .begin_set
-This is true if the command-line option "\fB--begin\fP \fIy x\/\fP" was used.
+This is true if the command-line option "\fB\-\-begin\fP \fIy x\/\fP" was used.
It specifies the position of the upper left corner
of a dialog box on the screen.
.\" ---------------------------------------------------------------------------
.SS .begin_x
This corresponds to the \fIx\fP value from
-the command-line option "\fB--begin\fP \fIy x\/\fP" (second value).
+the command-line option "\fB\-\-begin\fP \fIy x\/\fP" (second value).
.\" ---------------------------------------------------------------------------
.SS .begin_y
This corresponds to the \fIy\fP value from
-the command-line option "\fB--begin\fP \fIy x\/\fP" (first value).
+the command-line option "\fB\-\-begin\fP \fIy x\/\fP" (first value).
.\" ---------------------------------------------------------------------------
.SS .cancel_label
This corresponds to the command-line option
@@ -348,7 +370,7 @@ This corresponds to the command-line option
The given \fIstring\fP overrides the label used for \*(``Cancel\*('' buttons.
.\" ---------------------------------------------------------------------------
.SS .cant_kill
-This corresponds to the command-line option "\fB--no-kill\fP".
+This corresponds to the command-line option "\fB\-\-no\-kill\fP".
If true, this tells
\fB\*p\fP
to put the
@@ -358,7 +380,7 @@ printing its process id to \fB\*p\fP's output.
SIGHUP is disabled for the background process.
.\" ---------------------------------------------------------------------------
.SS .colors
-This corresponds to the command-line option "\fB--colors\fP".
+This corresponds to the command-line option "\fB\-\-colors\fP".
If true, interpret embedded "\eZ" sequences in the dialog text
by the following character,
which tells \fB\*p\fP to set colors or video attributes:
@@ -379,12 +401,12 @@ bright red.
Restore normal settings with "\eZn".
.\" ---------------------------------------------------------------------------
.SS .column_separator
-This corresponds to the command-line option "\fB--column-separator\fP".
+This corresponds to the command-line option "\fB\-\-column\-separator\fP".
\fB\*L\fP splits data for radio/checkboxes and menus on the
occurrences of the given string, and aligns the split data into columns.
.\" ---------------------------------------------------------------------------
.SS .cr_wrap
-This corresponds to the command-line option "\fB--cr-wrap\fP".
+This corresponds to the command-line option "\fB\-\-cr\-wrap\fP".
If true,
interpret embedded newlines in the dialog text as a newline on the screen.
Otherwise, \fB\*p\fR will only wrap lines where needed
@@ -395,25 +417,32 @@ Without cr-wrap, the layout of your text may be formatted to look nice
in the source code of your script without affecting the way it will
look in the dialog.
.\" ---------------------------------------------------------------------------
+.SS .cursor_off_label
+This corresponds to the command-line option "\fB\-\-cursor\-off\-label\fP".
+If true, place the terminal cursor at the end of a button instead of
+on the first character of the button label.
+This is useful to reduce visual confusion when the cursor coloration
+interacts poorly with the button-label text colors.
+.\" ---------------------------------------------------------------------------
.SS .date_format
This corresponds to the command-line option
-"\fB--date-format\fP \fIstring\/\fP".
+"\fB\-\-date\-format\fP \fIstring\/\fP".
If the host provides \fBstrftime\fP, and the value is nonnull,
the calendar widget uses this to format its output.
.\" ---------------------------------------------------------------------------
.SS .default_button
-This is set by the command-line option "\fB--default-button\fP.
+This is set by the command-line option "\fB\-\-default\-button\fP.
It is used by \fBdlg_default_button\fP.
.\" ---------------------------------------------------------------------------
.SS .default_item
This corresponds to the command-line option
-"\fB--default-item\fP \fIstring\/\fP".
+"\fB\-\-default\-item\fP \fIstring\/\fP".
The given string is used as
the default item in a checklist, form or menu box.
Normally the first item in the box is the default.
.\" ---------------------------------------------------------------------------
.SS .defaultno
-This corresponds to the command-line option "\fB--defaultno\fP".
+This corresponds to the command-line option "\fB\-\-defaultno\fP".
If true,
make the default value of the
\fByes/no\fP
@@ -422,43 +451,53 @@ box a
Likewise, treat the default button of widgets that provide
\*(``OK\*('' and \*(``Cancel\*(''
as a \fICancel\fP.
-If \fB--nocancel\fP was given that option overrides this,
+If \fB\-\-no\-cancel\fP was given that option overrides this,
making the default button always \*(``Yes\*(''
(internally the same as \*(``OK\*('').
.\" ---------------------------------------------------------------------------
.SS .dlg_clear_screen
-This corresponds to the command-line option "\fB--clear\fP".
+This corresponds to the command-line option "\fB\-\-clear\fP".
This option is implemented in the main program, not the library.
If true,
the screen will be cleared on exit.
This may be used alone, without other options.
.\" ---------------------------------------------------------------------------
+.SS .erase_on_exit
+This corresponds to the command-line option "\fB\-\-erase\-on\-exit\fP".
+If true, remove the dialog widget on program exit, erasing the entire
+screen to its native background color, and place the terminal cursor
+at the lower left corner of the screen.
+This is useful for making the window contents invisible at the end of
+a series of dialog boxes.
+But it can also be used at earlier stages of a series of invocations
+of \fB\*p\fP, if the series may be aborted before it is fully completed.
+.\" ---------------------------------------------------------------------------
.SS .exit_label
-This corresponds to the command-line option "\fB--exit-label string\fP".
+This corresponds to the command-line option "\fB\-\-exit\-label string\fP".
The given string overrides the label used for \*(``EXIT\*('' buttons.
.\" ---------------------------------------------------------------------------
.SS .extra_button
-This corresponds to the command-line option "\fB--extra-button\fP".
+This corresponds to the command-line option "\fB\-\-extra\-button\fP".
If true, some widgets show an extra button,
between \*(``OK\*('' and \*(``Cancel\*('' buttons.
.\" ---------------------------------------------------------------------------
.SS .extra_label
This corresponds to the command-line option
-"\fB--extra-label\fP \fIstring\/\fP".
+"\fB\-\-extra\-label\fP \fIstring\/\fP".
The given string overrides the label used for \*(``Extra\*('' buttons.
Note: for inputmenu widgets, this defaults to \*(``Rename\*(''.
.\" ---------------------------------------------------------------------------
.SS .formitem_type
-This is set by the command-line option "\fB--passwordform\fP"
+This is set by the command-line option "\fB\-\-passwordform\fP"
to tell the form widget that its text fields should be treated like
password widgets.
.\" ---------------------------------------------------------------------------
.SS .help_button
-This corresponds to the command-line option "\fB--help-button\fP".
+This corresponds to the command-line option "\fB\-\-help\-button\fP".
If true, some widgets show a help-button after
\*(``OK\*('' and \*(``Cancel\*('' buttons,
i.e., in checklist, radiolist and menu boxes.
-If \fB--item-help\fR is also given, on exit
+If \fB\-\-item\-help\fR is also given, on exit
the return status will be the same as for the \*(``OK\*('' button,
and the item-help text will be written to \fB\*p\fP's output
after the token \*(``HELP\*(''.
@@ -466,21 +505,22 @@ Otherwise, the return status will indicate that the Help button was pressed,
and no message printed.
.\" ---------------------------------------------------------------------------
.SS .help_file
-This corresponds to the command-line option "\fB--hfile\fP \fIstring\/\fP".
+This corresponds to the command-line option "\fB\-\-hfile\fP \fIstring\/\fP".
The given filename is passed to \fBdialog_helpfile\fP when the user
presses F1.
.\" ---------------------------------------------------------------------------
.SS .help_label
-This corresponds to the command-line option "\fB--help-label\fP \fIstring\/\fP".
+This corresponds to the
+command-line option "\fB\-\-help\-label\fP \fIstring\/\fP".
The given string overrides the label used for \*(``Help\*('' buttons.
.\" ---------------------------------------------------------------------------
.SS .help_line
-This corresponds to the command-line option "\fB--hline\fP \fIstring\/\fP".
+This corresponds to the command-line option "\fB\-\-hline\fP \fIstring\/\fP".
The given string is displayed in the bottom of dialog windows,
like a subtitle.
.\" ---------------------------------------------------------------------------
.SS .help_status
-This corresponds to the command-line option "\fB--help-status\fP".
+This corresponds to the command-line option "\fB\-\-help\-status\fP".
If true, and the the help-button is selected,
writes the checklist or radiolist information
after the item-help \*(``HELP\*('' information.
@@ -488,7 +528,7 @@ This can be used to reconstruct the state of a checklist after processing
the help request.
.\" ---------------------------------------------------------------------------
.SS .help_tags
-This corresponds to the command-line option "\fB--help-tags\fP".
+This corresponds to the command-line option "\fB\-\-help\-tags\fP".
If true,
\fBdlg_add_help_formitem\fP and
\fBdlg_add_help_listitem\fP use the item's tag value consistently
@@ -524,7 +564,7 @@ and sets \fIDIALOG_VARS.input_length\fP.
Callers should check for this case if they have supplied their own buffer.
.\" ---------------------------------------------------------------------------
.SS .insecure
-This corresponds to the command-line option "\fB--insecure\fP".
+This corresponds to the command-line option "\fB\-\-insecure\fP".
If true, make the password widget friendlier but less secure,
by echoing asterisks for each character.
.\" ---------------------------------------------------------------------------
@@ -533,7 +573,7 @@ This variable is used to prevent \fBdialog_helpfile\fP from showing
anything, e.g., if F1 were pressed within a help-file display.
.\" ---------------------------------------------------------------------------
.SS .iso_week
-This corresponds to the command-line option "\fB--iso-week\fP".
+This corresponds to the command-line option "\fB\-\-iso\-week\fP".
It is used in the calendar widget to tell how
to compute the starting week for the year:
.bP
@@ -545,14 +585,14 @@ a Thursday in the current year.
January 1 may be in the \fIprevious\fP year.
.\" ---------------------------------------------------------------------------
.SS .item_help
-This corresponds to the command-line option "\fB--item-help\fP".
+This corresponds to the command-line option "\fB\-\-item\-help\fP".
If true,
interpret the tags data for checklist, radiolist and menu boxes
adding a column whose text is displayed in the bottom line of the
screen, for the currently selected item.
.\" ---------------------------------------------------------------------------
.SS .keep_tite
-This is set by the command-line option "\fB--keep-tite\fP"
+This is set by the command-line option "\fB\-\-keep\-tite\fP"
to tell \fB\*p\fP to not attempt to cancel the terminal initialization
(termcap \fIti\/\fP/\,\fIte\/\fP) sequences
which correspond to xterm's alternate-screen switching.
@@ -560,22 +600,38 @@ Normally \fB\*p\fP does this to avoid flickering when run several times
in a script.
.\" ---------------------------------------------------------------------------
.SS .keep_window
-This corresponds to the command-line option "\fB--keep-window\fP".
+This corresponds to the command-line option "\fB\-\-keep\-window\fP".
If true, do not remove/repaint the window on exit.
This is useful for keeping the window contents visible when several
widgets are run in the same process.
Note that curses will clear the screen when starting a new process.
.\" ---------------------------------------------------------------------------
.SS .last_key
-This corresponds to the command-line option "\fB--last-key\fP".
+This corresponds to the command-line option "\fB\-\-last\-key\fP".
.\" ---------------------------------------------------------------------------
.SS .max_input
-This corresponds to the command-line option "\fB--max-input\fP \fIsize\/\fP".
+This corresponds to the command-line option "\fB\-\-max\-input\fP \fIsize\/\fP".
Limit input strings to the given size.
If not specified, the limit is 2048.
.\" ---------------------------------------------------------------------------
+.SS .no_hot_key
+This corresponds to the command-line option "\fB\-\-no\-hot\-list\fP".
+.LP
+Some widgets
+(buildlist,
+checklist,
+inputmenu,
+menu,
+radiolist,
+treeview)
+display a list
+for which the leading capital letter in each entry is accepted as a hot-key,
+to quickly move the focus to that entry.
+.LP
+Setting this variable to TRUE disables the feature.
+.\" ---------------------------------------------------------------------------
.SS .no_items
-This corresponds to the command-line option "\fB--no-items\fP".
+This corresponds to the command-line option "\fB\-\-no\-items\fP".
Some widgets (checklist, inputmenu, radiolist, menu) display a list
with two columns (a \*(``tag\*('' and \*(``item\*('',
i.e., \*(``description\*('').
@@ -583,31 +639,32 @@ This tells \fB\*p\fP to read shorter rows from data,
omitting the \*(``list\*(''.
.\" ---------------------------------------------------------------------------
.SS .no_label
-This corresponds to the command-line option "\fB--no-label\fP \fIstring\/\fP".
+This corresponds to the command-line
+option "\fB\-\-no\-label\fP \fIstring\/\fP".
The given string overrides the label used for \*(``No\*('' buttons.
.\" ---------------------------------------------------------------------------
.SS .no_lines
-This corresponds to the command-line option "\fB--no-lines\fP.
+This corresponds to the command-line option "\fB\-\-no\-lines\fP.
It suppresses line-drawing.
See \fIDIALOG_VARS.ascii_lines\fP.
.\" ---------------------------------------------------------------------------
.SS .no_nl_expand
-This corresponds to the command-line option "\fB--no-nl-expand\fP".
+This corresponds to the command-line option "\fB\-\-no\-nl\-expand\fP".
If false, \fBdlg_trim_string\fP converts literal "\en" substrings
in a message into newlines.
.\" ---------------------------------------------------------------------------
.SS .no_tags
-This corresponds to the command-line option "\fB--no-tags\fP".
+This corresponds to the command-line option "\fB\-\-no\-tags\fP".
Some widgets (checklist, inputmenu, radiolist, menu) display a list
with two columns (a \*(``tag\*('' and \*(``item\*('',
also known as \*(``description\*('').
The tag is useful for scripting, but may not help the user.
-The \fB--no-tags\fP option (from Xdialog) may be used to suppress the
+The \fB\-\-no\-tags\fP option (from Xdialog) may be used to suppress the
column of tags from the display.
.LP
Normally \fB\*p\fP allows you to quickly move to entries on the displayed list,
by matching a single character to the first character of the tag.
-When the \fB--no-tags\fP option is given, \fB\*p\fP matches against
+When the \fB\-\-no\-tags\fP option is given, \fB\*p\fP matches against
the first character of the description.
In either case, the matchable character is highlighted.
.LP
@@ -653,54 +710,59 @@ However the library interface defaults to displaying the tag column.
Your application can enable or disable the tag column as needed for each widget.
.\" ---------------------------------------------------------------------------
.SS .nocancel
-This corresponds to the command-line option "\fB--no-cancel\fP".
+This corresponds to the command-line option "\fB\-\-no\-cancel\fP".
If true,
suppress the \*(``Cancel\*('' button in checklist, inputbox and menu box modes.
A script can still test if the user pressed the ESC key to cancel to quit.
.\" ---------------------------------------------------------------------------
.SS .nocollapse
-This corresponds to the command-line option "\fB--no-collapse\fP".
+This corresponds to the command-line option "\fB\-\-no\-collapse\fP".
Normally \fB\*p\fR converts tabs to spaces and reduces multiple
spaces to a single space for text which is displayed in a message boxes, etc.
It true, that feature is disabled.
-Note that \fB\*p\fR will still wrap text, subject to the \fB--cr-wrap\fR
+Note that \fB\*p\fR will still wrap text, subject to the \fB\-\-cr\-wrap\fR
option.
.\" ---------------------------------------------------------------------------
.SS .nook
-This corresponds to the command-line option "\fB--nook\fP.
+This corresponds to the command-line option "\fB\-\-no\-ok\fP.
\fB\*L\fP will suppress the \*(``ok\*('' (or \*(``yes\*('') button
from the widget.
.\" ---------------------------------------------------------------------------
.SS .ok_label
-This corresponds to the command-line option "\fB--ok-label\fP \fIstring\/\fP".
+This corresponds to the command-line
+option "\fB\-\-ok\-label\fP \fIstring\/\fP".
The given string overrides the label used for \*(``OK\*('' buttons.
.\" ---------------------------------------------------------------------------
+.SS .pause_secs
+When set, force \fBdlg_set_timeout\fP to use 10 milliseconds
+rather than using the \fIDIALOG_VARS.timeout_secs\fP value.
+.\" ---------------------------------------------------------------------------
.SS .print_siz
-This corresponds to the command-line option "\fB--print-size\fP".
+This corresponds to the command-line option "\fB\-\-print\-size\fP".
If true,
each widget prints its size to \fB\*p\fP's output when it is invoked.
.\" ---------------------------------------------------------------------------
.SS .quoted
-This corresponds to the command-line option "\fB--quoted\fP.
+This corresponds to the command-line option "\fB\-\-quoted\fP.
Normally \fB\*p\fP quotes the strings returned by checklist's
as well as the item-help text.
If true, \fB\*p\fP will quote all string results.
.\" ---------------------------------------------------------------------------
.SS .reorder
-This corresponds to the command-line option "\fB--reorder\fP.
+This corresponds to the command-line option "\fB\-\-reorder\fP.
By default, the buildlist widget uses the same order for the output (right)
list as for the input (left).
If true, \fB\*p\fP will use the order in which a user adds selections
to the output list.
.\" ---------------------------------------------------------------------------
.SS .separate_output
-This corresponds to the command-line option "\fB--separate-output\fP".
+This corresponds to the command-line option "\fB\-\-separate\-output\fP".
If true,
checklist widgets output result one line at a time, with no quoting.
This facilitates parsing by another program.
.\" ---------------------------------------------------------------------------
.SS .single_quoted
-This corresponds to the command-line option "\fB--single-quoted\fP".
+This corresponds to the command-line option "\fB\-\-single\-quoted\fP".
If true,
use single-quoting as needed (and no quotes if unneeded) for the
output of checklist's as well as the item-help text.
@@ -709,47 +771,47 @@ The latter requires occasional use of backslashes to make the output useful in
shell scripts.
.\" ---------------------------------------------------------------------------
.SS .size_err
-This corresponds to the command-line option "\fB--size-err\fP".
+This corresponds to the command-line option "\fB\-\-size\-err\fP".
If true,
check the resulting size of a dialog box before trying to use it,
printing the resulting size if it is larger than the screen.
(This option is obsolete, since all new-window calls are checked).
.\" ---------------------------------------------------------------------------
.SS .sleep_secs
-This corresponds to the command-line option "\fB--sleep\fP \fIsecs\/\fP".
+This corresponds to the command-line option "\fB\-\-sleep\fP \fIsecs\/\fP".
This option is implemented in the main program, not the library.
If nonzero, this is the number of seconds after to delay
after processing a dialog box.
.\" ---------------------------------------------------------------------------
.SS .tab_correct
-This corresponds to the command-line option "\fB--tab-correct\fP".
+This corresponds to the command-line option "\fB\-\-tab-correct\fP".
If true, convert each tab character of the text to one or more spaces.
Otherwise, tabs are rendered according to the curses library's interpretation.
.\" ---------------------------------------------------------------------------
.SS .time_format
This corresponds to the command-line option
-"\fB--time-format\fP \fIstring\/\fP".
+"\fB\-\-time\-format\fP \fIstring\/\fP".
If the host provides \fBstrftime\fP, and the value is nonnull,
the timebox widget uses this to format its output.
.\" ---------------------------------------------------------------------------
.SS .timeout_secs
-This corresponds to the command-line option "\fB--timeout\fP \fIsecs\/\fP".
+This corresponds to the command-line option "\fB\-\-timeout\fP \fIsecs\/\fP".
If nonzero, timeout input requests (exit with error code)
if no user response within the given number of seconds.
.\" ---------------------------------------------------------------------------
.SS .title
-This corresponds to the command-line option "\fB--title\fP \fItitle\/\fP".
+This corresponds to the command-line option "\fB\-\-title\fP \fItitle\/\fP".
Specifies a
\fItitle\fP
string to be displayed at the top of the dialog box.
.\" ---------------------------------------------------------------------------
.SS .trim_whitespace
-This corresponds to the command-line option "\fB--trim\fP".
+This corresponds to the command-line option "\fB\-\-trim\fP".
If true, eliminate leading blanks,
trim literal newlines and repeated blanks from message text.
.\" ---------------------------------------------------------------------------
.SS .week_start
-This corresponds to the command-line option "\fB--week-start\fP".
+This corresponds to the command-line option "\fB\-\-week\-start\fP".
It is used in the calendar widget to set the starting day for the week.
The string value can be
.bP
@@ -763,7 +825,8 @@ a string matching one of the abbreviations for the day of the week
shown in the \fBcalendar\fP widget, e.g., \*(``Mo\*('' for \*(``Monday\*(''.
.\" ---------------------------------------------------------------------------
.SS .yes_label
-This corresponds to the command-line option "\fB--yes-label\fP \fIstring\/\fP".
+This corresponds to the command-line
+option "\fB\-\-yes\-label\fP \fIstring\/\fP".
The given string overrides the label used for \*(``Yes\*('' buttons.
.
.\" ************************************************************************
@@ -789,7 +852,7 @@ Other parameters depend on the box type.
.
.\" ************************************************************************
.SS dialog_buildlist
-implements the "\fB--buildlist\fP" option.
+implements the "\fB\-\-buildlist\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -830,7 +893,7 @@ is reserved for future enhancements
.
.\" ************************************************************************
.SS dialog_calendar
-implements the "\fB--calendar\fP" option.
+implements the "\fB\-\-calendar\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -860,7 +923,7 @@ is the initial year shown.
If the value is negative, the current year is used.
.\" ************************************************************************
.SS dialog_checklist
-implements the "\fB--checklist\fP" and "\fB--radiolist\fP" options
+implements the "\fB\-\-checklist\fP" and "\fB\-\-radiolist\fP" options
depending on the \fIflag\fP parameter.
.TP 5
.B const char * \fItitle
@@ -901,7 +964,7 @@ is either \fIFLAG_CHECK\fP, for checklists,
or \fIFLAG_RADIO\fP for radiolists.
.\" ************************************************************************
.SS dialog_dselect
-implements the "\fB--dselect\fP" option.
+implements the "\fB\-\-dselect\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -919,7 +982,7 @@ is the desired width of the box.
If zero, the height is based on the screen size.
.\" ************************************************************************
.SS dialog_editbox
-implements the "\fB--editbox\fP" option.
+implements the "\fB\-\-editbox\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -936,7 +999,7 @@ is the desired width of the box.
If zero, the height is adjusted to use the available screen size.
.\" ************************************************************************
.SS dialog_form
-implements the "\fB--form\fP" option.
+implements the "\fB\-\-form\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -973,7 +1036,7 @@ or
depending on whether \fBdialog_vars.item_help\fP is set.
.\" ************************************************************************
.SS dialog_fselect
-implements the "\fB--fselect\fP" option.
+implements the "\fB\-\-fselect\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -991,7 +1054,7 @@ is the desired width of the box.
If zero, the height is based on the screen size.
.\" ************************************************************************
.SS dialog_gauge
-implements the "\fB--gauge\fP" option.
+implements the "\fB\-\-gauge\fP" option.
Alternatively, a simpler or customized gauge widget can be
set up using
\fBdlg_allocate_gauge\fP,
@@ -1017,8 +1080,8 @@ If zero, the height is based on the screen size.
is the percentage to show in the progress bar.
.\" ************************************************************************
.SS dialog_inputbox
-implements the "\fB--inputbox\fP" or
-"\fB--password\fP" option, depending on the value of \fIpassword\fP.
+implements the "\fB\-\-inputbox\fP" or
+"\fB\-\-password\fP" option, depending on the value of \fIpassword\fP.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1042,7 +1105,7 @@ when auto-sizing the width of the dialog box.
if true, causes typed input to be echoed as asterisks.
.\" ************************************************************************
.SS dialog_helpfile
-implements the "\fB--hfile\fP" option.
+implements the "\fB\-\-hfile\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1051,7 +1114,7 @@ is the title on the top of the widget.
is the name of a file containing the text to display.
This function is internally bound to F1 (function key \*(``1\*(''),
passing \fBdialog_vars.help_file\fP as a parameter.
-The \fBdialog\fP program sets that variable when the \fB--hfile\fP option
+The \fB\*p\fP program sets that variable when the \fB\-\-hfile\fP option
is given.
.TP 5
.B int \fIheight
@@ -1063,7 +1126,7 @@ is the desired width of the box.
If zero, the height is based on the screen size.
.\" ************************************************************************
.SS dialog_menu
-implements the "\fB--menu\fP" or "\fB--inputmenu\fP" option
+implements the "\fB\-\-menu\fP" or "\fB\-\-inputmenu\fP" option
depending on whether \fBdialog_vars.input_menu\fP is set.
.TP 5
.B const char * \fItitle
@@ -1101,7 +1164,7 @@ or
depending on whether \fBdialog_vars.item_help\fP is set.
.\" ************************************************************************
.SS dialog_mixedform
-implements the "\fB--mixedform\fP" option.
+implements the "\fB\-\-mixedform\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1138,7 +1201,7 @@ or
depending on whether \fBdialog_vars.item_help\fP is set.
.\" ************************************************************************
.SS dialog_mixedgauge
-implements the "\fB--mixedgauge\fP" option
+implements the "\fB\-\-mixedgauge\fP" option
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1196,7 +1259,7 @@ For example, "-75" is displayed as "75%".
Other strings are displayed as is.
.\" ************************************************************************
.SS dialog_msgbox
-implements the "\fB--msgbox\fP" or "\fB--infobox\fP" option
+implements the "\fB\-\-msgbox\fP" or "\fB\-\-infobox\fP" option
depending on whether \fIpauseopt\fP is set.
.TP 5
.B const char * \fItitle
@@ -1220,7 +1283,7 @@ With an \*(``OK\*('' button, it is denoted a \*(``msgbox\*('',
without an \*(``OK\*('' button, it is denoted an \*(``infobox\*(''.
.\" ************************************************************************
.SS dialog_pause
-implements the "\fB--pause\fP" option.
+implements the "\fB\-\-pause\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1237,7 +1300,7 @@ If zero, the height is based on the screen size.
is the timeout to use for the progress bar.
.\" ************************************************************************
.SS dialog_prgbox
-implements the "\fB--prgbox\fP" option.
+implements the "\fB\-\-prgbox\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1262,7 +1325,7 @@ if true, an \*(``OK\*('' button will be shown,
and the dialog will wait for it to complete.
.\" ************************************************************************
.SS dialog_progressbox
-implements the "\fB--progressbox\fP" option.
+implements the "\fB\-\-progressbox\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1280,7 +1343,7 @@ is the desired width of the box.
If zero, the height is based on the screen size.
.\" ************************************************************************
.SS dialog_rangebox
-implements the "\fB--rangebox\fP" option.
+implements the "\fB\-\-rangebox\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1307,7 +1370,7 @@ is the maximum value to allow.
is the default value, if no change is made.
.\" ************************************************************************
.SS dialog_tailbox
-implements the "\fB--tailbox\fP" or "\fB--tailboxbg\fP" option
+implements the "\fB\-\-tailbox\fP" or "\fB\-\-tailboxbg\fP" option
depending on whether \fIbg_task\fP is set.
.TP 5
.B const char * \fItitle
@@ -1332,7 +1395,7 @@ Otherwise an \*(``OK\*('' button is added to the window,
and it will be closed when the button is activated.
.\" ************************************************************************
.SS dialog_textbox
-implements the "\fB--textbox\fP" option.
+implements the "\fB\-\-textbox\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1349,7 +1412,7 @@ is the desired width of the box.
If zero, the height is based on the screen size.
.\" ************************************************************************
.SS dialog_timebox
-implements the "\fB--timebox\fP" option.
+implements the "\fB\-\-timebox\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1381,7 +1444,7 @@ If the value is negative, the current second is used.
Returns DLG_EXIT_ERROR if the value specified is greater than or equal to 60.
.\" ************************************************************************
.SS dialog_treeview
-implements the "\fB--treeview\fP" option.
+implements the "\fB\-\-treeview\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1415,7 +1478,7 @@ is either \fIFLAG_CHECK\fP, for checklists (multiple selections),
or \fIFLAG_RADIO\fP for radiolists (a single selection).
.\" ************************************************************************
.SS dialog_yesno
-implements the "\fB--yesno\fP" option.
+implements the "\fB\-\-yesno\fP" option.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -1442,6 +1505,10 @@ display and end it are named \fIinit_dialog\fP and \fIend_dialog\fP.
The only non-widget function whose name begins with "\fIdialog_\fP"
is \fBdialog_version\fP, which returns the version number of the
library as a string.
+.PP
+A few functions are prefixed "\fI_dlg_\fP",
+because they are required for internal use,
+but not intended as part of the library application programming interface.
.
.PP
Here is a brief summary of the utility functions and their parameters:
@@ -1494,7 +1561,7 @@ contains the list item to use for tag- or help-text.
.\" ---------------------------------------------------------------------------
.SS dlg_add_last_key
Report the last key entered by the user.
-This implements the \fB--last-key\fP command-line option,
+This implements the \fB\-\-last\-key\fP command-line option,
using \fBdialog_vars.last_key\fP.
.TP 5
.B int \fImode
@@ -1649,7 +1716,7 @@ if the value is zero,
\fB\*l\fP updates it to the required height of the window,
taking into account a (possibly) multi-line \fIprompt\fP.
.bP
-if the value is greater than zero,
+if the value is greater than zero,
\fB\*l\fP uses it internally, but restores the value on return.
.RE
.TP 5
@@ -1669,7 +1736,7 @@ if the value is zero,
\fB\*l\fP updates it to the required width of the window,
taking into account a (possibly) multi-line \fIprompt\fP.
.bP
-if the value is greater than zero,
+if the value is greater than zero,
\fB\*l\fP uses it internally, but restores the value on return.
.RE
.TP 5
@@ -1808,6 +1875,14 @@ Count the buttons in the list.
.B const char ** \fIlabels
is a list of (pointers to) button labels terminated by a null pointer.
.\" ---------------------------------------------------------------------------
+.SS dlg_button_key
+If a key was bound to one of the button-codes in \fBdlg_result_key\fP, fake
+a button-value and an \*(``Cancel\*('' key
+to cause the calling widget to return the corresponding status.
+.PP
+See \fBdlg_ok_buttoncode\fP, which maps settings for ok/extra/help and button
+number into exit-code.
+.\" ---------------------------------------------------------------------------
.SS dlg_button_layout
Make sure there is enough space for the buttons by
computing the width required for their labels,
@@ -1937,7 +2012,7 @@ is the character to find.
is a list of (pointers to) button labels terminated by a null pointer.
.\" ---------------------------------------------------------------------------
.SS dlg_checklist
-This entrypoint provides the \fB--checklist\fP or \fB--radiolist\fP
+This entrypoint provides the \fB\-\-checklist\fP or \fB\-\-radiolist\fP
functionality without the limitations of \fB\*p\fP's command-line syntax
(compare to \fBdialog_checklist\fP).
.TP 5
@@ -2127,6 +2202,24 @@ Remove a window, repainting everything else.
.B WINDOW * \fIwin
is the window to remove.
.\" ---------------------------------------------------------------------------
+.SS dlg_der_window
+create a derived window, e.g., for an input area of a widget
+.TP 5
+.B WINDOW * \fIwin
+is the parent window
+.TP 5
+.B int \fIheight
+is the subwindow's height
+.TP 5
+.B int \fIwidth
+is the subwindow's width
+.TP 5
+.B int \fIy
+is the subwindow's top-row
+.TP 5
+.B int \fIx
+is the subwindow's left-column
+.\" ---------------------------------------------------------------------------
.SS dlg_does_output
This is called each time a widget is invoked which may do output.
It increments \fBdialog_state.output_count\fP,
@@ -2381,7 +2474,7 @@ is the window to update.
is the title string to display at the top of the widget.
.\" ---------------------------------------------------------------------------
.SS dlg_dummy_menutext
-This is a utility function which supports the \fB--inputmenu\fP option of
+This is a utility function which supports the \fB\-\-inputmenu\fP option of
the \fB\*p\fP program.
If \fBdialog_vars.input_menu\fP is set, \fBdialog_menu\fP passes this
pointer to \fBdlg_menu\fP as the \fIrename_menutext\fP parameter.
@@ -2449,7 +2542,7 @@ e.g., the window's size.
Updates the string and character-offset, given various editing characters
or literal characters which are inserted at the character-offset.
Returns true if an editing change was made (and the display should
-be updated), and false if the key was something like KEY_ENTER,
+be updated), and false if the key was something like \fBKEY_ENTER\fP,
which is a non-editing action outside this function.
.TP 5
.B char * \fIstring
@@ -2482,6 +2575,21 @@ The \fB\*p\fP program uses this function
to allow shell scripts to remap the exit codes so they can distinguish ESC
from ERROR.
.\" ---------------------------------------------------------------------------
+.SS dlg_exitcode2s
+Returns the name of an exit-code, e.g.,
+\*(``OK\*('' for \fBDLG_EXIT_OK\fP.
+.TP 5
+.B int \fIcode
+is an exit-code for \fB\*p\fP as defined in \fB<\*p.h>\fP.
+.\" ---------------------------------------------------------------------------
+.SS dlg_exitname2n
+Returns an exit-code as the reverse of \fBdlg_exitcode2n\fP, e.g.,
+0 (\fBDLG_EXIT_OK\fP) for the \*(``OK\*('' string.
+.TP 5
+.B const char * \fIname
+is the name of an exit-code for \fB\*p\fP as defined in \fB<\*p.h>\fP
+but omitting the \*(``DLG_EXIT_\*('' prefix.
+.\" ---------------------------------------------------------------------------
.SS dlg_exit_buttoncode
Map the given button index for \fBdlg_exit_label\fP into \fB\*p\fP's exit-code.
.TP 5
@@ -2533,7 +2641,7 @@ some of the caching is used for editable input-fields.
Cancel the local data saved by \fBdlg_last_getc\fP.
.\" ---------------------------------------------------------------------------
.SS dlg_editbox
-This entrypoint provides the \fB--editbox\fP
+This entrypoint provides the \fB\-\-editbox\fP
functionality without the limitations of \fB\*p\fP's command-line syntax
(compare to \fBdialog_editbox\fP).
.TP 5
@@ -2560,7 +2668,7 @@ is the desired width of the box.
If zero, the height is adjusted to use the available screen size.
.\" ---------------------------------------------------------------------------
.SS dlg_form
-This entrypoint provides the \fB--form\fP
+This entrypoint provides the \fB\-\-form\fP
functionality without the limitations of \fB\*p\fP's command-line syntax
(compare to \fBdialog_form\fP).
.TP 5
@@ -2632,6 +2740,29 @@ is the window within which to read.
.B int * \fIfkey
as a side-effect, set this to true if the key-code is really a function-key.
.\" ---------------------------------------------------------------------------
+.SS dlg_getenv_num
+Get a number from the environment:
+.bP
+If the caller provides a pointer in the second parameter, return
+success/failure for the function return, and the actual value via the pointer.
+Use this for decoding arbitrary numbers, e.g., negative or zero.
+.bP
+If the caller does not provide a pointer, return the decoded value for
+the function-return.
+Use this when only values greater than zero are useful.
+.TP 5
+.B char * \fIname
+is the name of the environment-variable to retrieve.
+.TP 5
+.B int * \fIvalue
+is the optional pointer to a return-value.
+.\" ---------------------------------------------------------------------------
+.SS dlg_getenv_str
+Get a string from the environment, rejecting those which are entirely blank.
+.TP 5
+.B char * \fIname
+is the name of the environment-variable to retrieve.
+.\" ---------------------------------------------------------------------------
.SS dlg_get_attrs
extract the video attributes from the given window.
.TP 5
@@ -2675,6 +2806,17 @@ Draw the string for the \fBdialog_vars.item_help\fP feature.
.B const char * \fItxt
is the help-message
.\" ---------------------------------------------------------------------------
+.SS dlg_keep_tite
+This performs the check and modifications
+for the command-line option "\fB\-\-keep\-tite\fP",
+used in \fBinit_dialog\fP as well as for
+the command-line option \fB\-\-erase\-on\-exit\fP.
+.TP 5
+.B FILE * \fIoutput
+is the output stream used for displaying widgets.
+It is either \fIstdout\fP or \fIstderr\fP,
+depending on the \fB\-\-stdout\fP option.
+.\" ---------------------------------------------------------------------------
.SS dlg_killall_bg
If \fB\*p\fP has callbacks active,
purge the list of all that are not marked
@@ -2736,7 +2878,7 @@ is the character to check
is the string to search
.\" ---------------------------------------------------------------------------
.SS dlg_menu
-This entrypoint provides the \fB--menu\fP
+This entrypoint provides the \fB\-\-menu\fP
functionality without the limitations of \fB\*p\fP's command-line syntax
(compare to \fBdialog_menu\fP).
.TP 5
@@ -2984,6 +3126,10 @@ into \fB\*p\fP's exit-code.
is the button-index (which is not necessarily the same as the index
in the list of labels).
.\" ---------------------------------------------------------------------------
+.SS dlg_ok_button_key
+Calls \fBdlg_button_key\fP with the \*(``Cancel\*('' button disabled,
+e.g., for the textbox widget.
+.\" ---------------------------------------------------------------------------
.SS dlg_ok_label
Returns a list with the \*(``Ok\*('' label,
and if \fBdialog_vars.help_button\fP is true, the \*(``Help\*('' label as well.
@@ -3163,7 +3309,7 @@ holds the starting attributes, and is updated to reflect the final attributes
applied to the string.
.\" ---------------------------------------------------------------------------
.SS dlg_progressbox
-implements the "\fB--prgbox\fP" and "\fB--progressbox\fP" options.
+implements the "\fB\-\-prgbox\fP" and "\fB\-\-progressbox\fP" options.
.TP 5
.B const char * \fItitle
is the title on the top of the widget.
@@ -3255,7 +3401,7 @@ Remove a callback.
contains the callback information.
.\" ---------------------------------------------------------------------------
.SS dlg_renamed_menutext
-This is a utility function which supports the \fB--inputmenu\fP option of
+This is a utility function which supports the \fB\-\-inputmenu\fP option of
the \fB\*p\fP program.
If \fBdialog_vars.input_menu\fP is set, \fBdialog_menu\fP passes this
pointer to \fBdlg_menu\fP as the \fIrename_menutext\fP parameter.
@@ -3275,6 +3421,10 @@ is the index of the currently-selected item
.B char * \fInewtext
is the updated text for the menu item
.\" ---------------------------------------------------------------------------
+.SS dlg_reset_timeout
+Calls \fBwtimeout\fP with the value saved for a window in the
+last call to \fBdlg_set_timeout\fP.
+.\" ---------------------------------------------------------------------------
.SS dlg_restore_vars
Restore \fB\*p\fP's variables from the given variable
(see \fBdialog_save_vars\fP).
@@ -3326,6 +3476,22 @@ Setup a fixed-buffer for the result in \fBdialog_vars.input_result\fP
.B const char * \fIstring
is the new contents for the result
.\" ---------------------------------------------------------------------------
+.SS dlg_set_timeout
+Calls \fBwtimeout\fP to establish a preferred timeout for nonblocking
+reads, e.g., to allow the gauge widget to handle window-resizing events.
+The \fBdlg_may_resize\fP function temporarily overrides this value,
+to allow it to skip over the error codes returned while the ncurses
+library processes window-resizing events.
+It restores the value established in this call
+by calling \fBdlg_restore_timeout\fP.
+.TP 5
+.B WINDOW * \fIwin
+is the window whose input-timeout should be set
+.TP 5
+.B bool \fIwill_getc
+is true if the widget is expected to read keyboard characters.
+Some (such as the gauge widget) do not.
+.\" ---------------------------------------------------------------------------
.SS dlg_show_string
Displays the string, shifted as necessary, to fit within the box and show
the current character-offset.
@@ -3432,7 +3598,7 @@ is the name to log in the comment.
.B int \fIvalue
is the value to log in the comment.
.\" ---------------------------------------------------------------------------
-.SS dlg_trace_2n
+.SS dlg_trace_2s
logs a string value as a comment.
If the value contains embedded newlines,
the comment is continued with \*(``#+\*('' markers.
@@ -3473,6 +3639,25 @@ parameters, e.g.,
DLG_TRACE(("this is dialog version %s\en", dialog_version()));
.Ee
.\" ---------------------------------------------------------------------------
+.SS dlg_trace_va_msg
+Write a formatted message to the trace file.
+.TP 5
+.B const char *\fIfmt
+is the format of the \fBprintf\fP-like message to write.
+.TP 5
+.B va_list \fIap
+are the variables to apply to the \fIfmt\fP format.
+.LP
+This is used in \fBdlg_exiterr\fP to capture error messages in the trace file:
+.Ex
+va_start(ap, fmt);
+dlg_trace_msg("## Error: ");
+dlg_trace_va_msg(fmt, ap);
+va_end(ap);
+.Ee
+.LP
+Unlike \fBdlg_trace_msg\fP, an extra macro is not needed.
+.\" ---------------------------------------------------------------------------
.SS dlg_ttysize
Returns the screensize without using curses.
That allows the function to be used before initializing the screen.
@@ -3535,7 +3720,7 @@ The widget sets the referenced location to the index of the current display
item (cursor) when it returns.
.\" ---------------------------------------------------------------------------
.SS dlg_trim_string
-The \fBdialog\fP program uses this in each widget to adjust the
+The \fB\*p\fP program uses this in each widget to adjust the
message string,
which may contain the newline character (referred to as '\en')
and/or the special substring "\en"
@@ -3622,12 +3807,12 @@ Do some initialization for \fB\*p\fP.
.B FILE *\fIinput
is the real tty input of \fB\*p\fP.
Usually it is the standard input, but if
-\fB--input-fd\fP option is used, it may be anything.
+\fB\-\-input\-fd\fP option is used, it may be anything.
.TP 5
.B FILE *\fIoutput
is where \fB\*p\fP will send its result.
Usually it is the standard error, but
-if \fB--stdout\fP or \fB--output-fd\fP is used, it may be anything.
+if \fB\-\-stdout\fP or \fB\-\-output\-fd\fP is used, it may be anything.
.
.\" ************************************************************************
.SH SEE ALSO
diff --git a/dialog.c b/dialog.c
index bab78a8a018e..510baeb97add 100644
--- a/dialog.c
+++ b/dialog.c
@@ -1,9 +1,9 @@
/*
- * $Id: dialog.c,v 1.268 2018/06/21 09:16:05 tom Exp $
+ * $Id: dialog.c,v 1.281 2021/01/17 16:52:18 tom Exp $
*
* cdialog - Display simple dialog boxes from shell scripts
*
- * Copyright 2000-2017,2018 Thomas E. Dickey
+ * Copyright 2000-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -25,6 +25,7 @@
*/
#include <dialog.h>
+
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
@@ -33,6 +34,8 @@
#include <locale.h>
#endif
+#include <dlg_internals.h>
+
#define PASSARGS t, av, offset_add
#define CALLARGS const char *t, char *av[], int *offset_add
typedef int (callerFn) (CALLARGS);
@@ -42,23 +45,25 @@ typedef enum {
,o_allow_close
,o_and_widget
,o_ascii_lines
- ,o_aspect
+ ,o_aspect_ratio
,o_auto_placement
,o_backtitle
- ,o_beep
- ,o_beep_after
- ,o_begin
+ ,o_beep_signal
+ ,o_beep_after_signal
+ ,o_begin_set
,o_cancel_label
,o_checklist
- ,o_clear
+ ,o_dlg_clear_screen
,o_colors
,o_column_separator
,o_cr_wrap
,o_create_rc
+ ,o_cursor_off_label
,o_date_format
,o_default_button
,o_default_item
,o_defaultno
+ ,o_erase_on_exit
,o_exit_label
,o_extra_button
,o_extra_label
@@ -90,14 +95,15 @@ typedef enum {
,o_mixedgauge
,o_msgbox
,o_no_close
- ,o_no_collapse
+ ,o_nocollapse
,o_no_cr_wrap
- ,o_no_kill
+ ,o_cant_kill
+ ,o_no_hot_list
,o_no_label
,o_no_lines
,o_no_mouse
,o_no_nl_expand
- ,o_no_shadow
+ ,o_use_shadow
,o_nocancel
,o_nook
,o_ok_label
@@ -108,8 +114,8 @@ typedef enum {
,o_pause
,o_prgbox
,o_print_maxsize
- ,o_print_size
- ,o_print_text_only
+ ,o_print_siz
+ ,o_text_only
,o_print_text_size
,o_print_version
,o_programbox
@@ -117,26 +123,24 @@ typedef enum {
,o_quoted
,o_radiolist
,o_screen_center
- ,o_scrollbar
+ ,o_use_scrollbar
,o_separate_output
- ,o_separate_widget
- ,o_separator
- ,o_shadow
+ ,o_separate_str
,o_single_quoted
,o_size_err
- ,o_sleep
+ ,o_sleep_secs
,o_smooth
- ,o_stderr
- ,o_stdout
+ ,o_output_stderr
+ ,o_output_stdout
,o_tab_correct
,o_tab_len
,o_tailbox
,o_tailboxbg
,o_textbox
,o_time_format
- ,o_timeout
+ ,o_timeout_secs
,o_title
- ,o_trim
+ ,o_trim_whitespace
,o_under_mouse
,o_version
,o_visit_items
@@ -171,6 +175,14 @@ typedef enum {
,o_iso_week
} eOptions;
+typedef enum {
+ tUnknown
+ ,tFalse
+ ,tTrue
+ ,tNumber
+ ,tString
+} tOptions;
+
/*
* The bits in 'pass' are used to decide which options are applicable at
* different stages in the program:
@@ -181,6 +193,9 @@ typedef enum {
typedef struct {
const char *name;
eOptions code;
+ int vars; /* 0=none, 1=state, 2=vars */
+ tOptions type; /* type for bool(true/false), number, string */
+ unsigned offset;
int pass; /* 1,2,4 or combination */
const char *help; /* NULL to suppress, non-empty to display params */
} Options;
@@ -191,6 +206,30 @@ typedef struct {
callerFn *jumper;
} Mode;
+/* use these macros for simple options in DIALOG_STATE */
+#define ssF(name) o_##name, 1, tFalse, offsetof(DIALOG_STATE,name)
+#define ssT(name) o_##name, 1, tTrue, offsetof(DIALOG_STATE,name)
+#define ssN(name) o_##name, 1, tNumber, offsetof(DIALOG_STATE,name)
+#define ssS(name) o_##name, 1, tString, offsetof(DIALOG_STATE,name)
+
+/* use these macros for simple options in DIALOG_VARS */
+#define svF(name) o_##name, 2, tFalse, offsetof(DIALOG_VARS,name)
+#define svT(name) o_##name, 2, tTrue, offsetof(DIALOG_VARS,name)
+#define svN(name) o_##name, 2, tNumber, offsetof(DIALOG_VARS,name)
+#define svS(name) o_##name, 2, tString, offsetof(DIALOG_VARS,name)
+
+/* use these macros for ignored options */
+#define xxF(name) o_##name, 0, tFalse, 0
+#define xxT(name) o_##name, 0, tTrue, 0
+#define xxN(name) o_##name, 0, tNumber, 0
+#define xxS(name) o_##name, 0, tString, 0
+
+/* use this macro for widget options */
+#define opW(name) o_##name, 0, 0, 0
+
+/* use this macro for other options */
+#define opO(name) o_##name, 0, 0, 0
+
static int known_opts = 0;
static const char **dialog_opts;
static char **dialog_argv;
@@ -214,149 +253,153 @@ static AllBlobs *all_blobs;
/*
* The options[] table is organized this way to make it simple to maintain
* a sorted list of options for the help-message.
+ *
+ * Because Boolean options correspond to "true", --shadow is listed here while
+ * --no-shadow is not. The findOption and optionBool functions handle the
+ * cases where "no" is added or removed from the option name to derive an
+ * opposite setting.
*/
/* *INDENT-OFF* */
static const Options options[] = {
- { "allow-close", o_allow_close, 1, NULL },
- { "and-widget", o_and_widget, 4, NULL },
- { "ascii-lines", o_ascii_lines, 1, "" },
- { "aspect", o_aspect, 1, "<ratio>" },
- { "auto-placement", o_auto_placement, 1, NULL },
- { "backtitle", o_backtitle, 1, "<backtitle>" },
- { "beep", o_beep, 1, "" },
- { "beep-after", o_beep_after, 1, "" },
- { "begin", o_begin, 1, "<y> <x>" },
- { "cancel-label", o_cancel_label, 1, "<str>" },
- { "checklist", o_checklist, 2, "<text> <height> <width> <list height> <tag1> <item1> <status1>..." },
- { "clear", o_clear, 1, "" },
- { "colors", o_colors, 1, "" },
- { "column-separator",o_column_separator, 1, "<str>" },
- { "cr-wrap", o_cr_wrap, 1, "" },
- { "create-rc", o_create_rc, 1, NULL },
- { "date-format", o_date_format, 1, "<str>" },
- { "default-button", o_default_button, 1, "<str>" },
- { "default-item", o_default_item, 1, "<str>" },
- { "defaultno", o_defaultno, 1, "" },
- { "exit-label", o_exit_label, 1, "<str>" },
- { "extra-button", o_extra_button, 1, "" },
- { "extra-label", o_extra_label, 1, "<str>" },
- { "fixed-font", o_fixed_font, 1, NULL },
- { "form", o_form, 2, "<text> <height> <width> <form height> <label1> <l_y1> <l_x1> <item1> <i_y1> <i_x1> <flen1> <ilen1>..." },
- { "gauge", o_gauge, 2, "<text> <height> <width> [<percent>]" },
- { "guage", o_gauge, 2, NULL },
- { "help", o_help, 4, "" },
- { "help-button", o_help_button, 1, "" },
- { "help-label", o_help_label, 1, "<str>" },
- { "help-status", o_help_status, 1, "" },
- { "help-tags", o_help_tags, 1, "" },
- { "hfile", o_help_file, 1, "<str>" },
- { "hline", o_help_line, 1, "<str>" },
- { "icon", o_icon, 1, NULL },
- { "ignore", o_ignore, 1, "" },
- { "infobox", o_infobox, 2, "<text> <height> <width>" },
- { "input-fd", o_input_fd, 1, "<fd>" },
- { "inputbox", o_inputbox, 2, "<text> <height> <width> [<init>]" },
- { "inputmenu", o_inputmenu, 2, "<text> <height> <width> <menu height> <tag1> <item1>..." },
- { "insecure", o_insecure, 1, "" },
- { "item-help", o_item_help, 1, "" },
- { "keep-colors", o_keep_colors, 1, NULL },
- { "keep-tite", o_keep_tite, 1, "" },
- { "keep-window", o_keep_window, 1, "" },
- { "last-key", o_last_key, 1, "" },
- { "max-input", o_max_input, 1, "<n>" },
- { "menu", o_menu, 2, "<text> <height> <width> <menu height> <tag1> <item1>..." },
- { "mixedform", o_mixedform, 2, "<text> <height> <width> <form height> <label1> <l_y1> <l_x1> <item1> <i_y1> <i_x1> <flen1> <ilen1> <itype>..." },
- { "mixedgauge", o_mixedgauge, 2, "<text> <height> <width> <percent> <tag1> <item1>..." },
- { "msgbox", o_msgbox, 2, "<text> <height> <width>" },
- { "no-cancel", o_nocancel, 1, "" },
- { "no-close", o_no_close, 1, NULL },
- { "no-collapse", o_no_collapse, 1, "" },
- { "no-cr-wrap", o_no_cr_wrap, 1, "" },
- { "no-kill", o_no_kill, 1, "" },
- { "no-label", o_no_label, 1, "<str>" },
- { "no-lines", o_no_lines, 1, "" },
- { "no-mouse", o_no_mouse, 1, "" },
- { "no-nl-expand", o_no_nl_expand, 1, "" },
- { "no-ok", o_nook, 1, "" },
- { "no-shadow", o_no_shadow, 1, "" },
- { "nocancel", o_nocancel, 1, NULL }, /* see --no-cancel */
- { "nook", o_nook, 1, "" }, /* See no-ok */
- { "ok-label", o_ok_label, 1, "<str>" },
- { "output-fd", o_output_fd, 1, "<fd>" },
- { "output-separator",o_output_separator, 1, "<str>" },
- { "passwordbox", o_passwordbox, 2, "<text> <height> <width> [<init>]" },
- { "passwordform", o_passwordform, 2, "<text> <height> <width> <form height> <label1> <l_y1> <l_x1> <item1> <i_y1> <i_x1> <flen1> <ilen1>..." },
- { "pause", o_pause, 2, "<text> <height> <width> <seconds>" },
- { "prgbox", o_prgbox, 2, "<text> <command> <height> <width>" },
- { "print-maxsize", o_print_maxsize, 1, "" },
- { "print-size", o_print_size, 1, "" },
- { "print-text-only",o_print_text_only, 5, "<text> <height> <width>" },
- { "print-text-size",o_print_text_size, 5, "<text> <height> <width>" },
- { "print-version", o_print_version, 5, "" },
- { "programbox", o_programbox, 2, "<text> <height> <width>" },
- { "progressbox", o_progressbox, 2, "<text> <height> <width>" },
- { "quoted", o_quoted, 1, "" },
- { "radiolist", o_radiolist, 2, "<text> <height> <width> <list height> <tag1> <item1> <status1>..." },
- { "screen-center", o_screen_center, 1, NULL },
- { "scrollbar", o_scrollbar, 1, "" },
- { "separate-output",o_separate_output, 1, "" },
- { "separate-widget",o_separate_widget, 1, "<str>" },
- { "separator", o_separator, 1, NULL },
- { "shadow", o_shadow, 1, "" },
- { "single-quoted", o_single_quoted, 1, "" },
- { "size-err", o_size_err, 1, "" },
- { "sleep", o_sleep, 1, "<secs>" },
- { "smooth", o_smooth, 1, NULL },
- { "stderr", o_stderr, 1, "" },
- { "stdout", o_stdout, 1, "" },
- { "tab-correct", o_tab_correct, 1, "" },
- { "tab-len", o_tab_len, 1, "<n>" },
- { "tailbox", o_tailbox, 2, "<file> <height> <width>" },
- { "tailboxbg", o_tailboxbg, 2, "<file> <height> <width>" },
- { "textbox", o_textbox, 2, "<file> <height> <width>" },
- { "time-format", o_time_format, 1, "<str>" },
- { "timeout", o_timeout, 1, "<secs>" },
- { "title", o_title, 1, "<title>" },
- { "trim", o_trim, 1, "" },
- { "under-mouse", o_under_mouse, 1, NULL },
- { "version", o_version, 5, "" },
- { "visit-items", o_visit_items, 1, "" },
- { "wmclass", o_wmclass, 1, NULL },
- { "yes-label", o_yes_label, 1, "<str>" },
- { "yesno", o_yesno, 2, "<text> <height> <width>" },
+ { "allow-close", xxT(allow_close), 1, NULL },
+ { "and-widget", opO(and_widget), 4, NULL },
+ { "ascii-lines", svT(ascii_lines), 1, "" },
+ { "aspect", ssN(aspect_ratio), 1, "<ratio>" },
+ { "auto-placement", xxT(auto_placement), 1, NULL },
+ { "backtitle", svS(backtitle), 1, "<backtitle>" },
+ { "beep", svT(beep_signal), 1, "" },
+ { "beep-after", svT(beep_after_signal), 1, "" },
+ { "begin", svT(begin_set), 1, "<y> <x>" },
+ { "cancel-label", svS(cancel_label), 1, "<str>" },
+ { "checklist", opW(checklist), 2, "<text> <height> <width> <list height> <tag1> <item1> <status1>..." },
+ { "clear", svT(dlg_clear_screen), 1, "" },
+ { "colors", svT(colors), 1, "" },
+ { "column-separator",svS(column_separator), 1, "<str>" },
+ { "cr-wrap", svT(cr_wrap), 1, "" },
+ { "create-rc", opO(create_rc), 1, NULL },
+ { "cursor-off-label",svT(cursor_off_label), 1, "" },
+ { "date-format", svS(date_format), 1, "<str>" },
+ { "default-button", xxS(default_button), 1, "<str>" },
+ { "default-item", svS(default_item), 1, "<str>" },
+ { "defaultno", svT(defaultno), 1, "" },
+ { "erase-on-exit", svT(erase_on_exit), 1, "" },
+ { "exit-label", svS(exit_label), 1, "<str>" },
+ { "extra-button", svT(extra_button), 1, "" },
+ { "extra-label", svS(extra_label), 1, "<str>" },
+ { "fixed-font", xxT(fixed_font), 1, NULL },
+ { "form", opW(form), 2, "<text> <height> <width> <form height> <label1> <l_y1> <l_x1> <item1> <i_y1> <i_x1> <flen1> <ilen1>..." },
+ { "gauge", opW(gauge), 2, "<text> <height> <width> [<percent>]" },
+ { "guage", opW(gauge), 2, NULL },
+ { "help", opO(help), 4, "" },
+ { "help-button", svT(help_button), 1, "" },
+ { "help-label", svS(help_label), 1, "<str>" },
+ { "help-status", svT(help_status), 1, "" },
+ { "help-tags", svT(help_tags), 1, "" },
+ { "hfile", svS(help_file), 1, "<str>" },
+ { "hline", svS(help_line), 1, "<str>" },
+ { "icon", xxS(icon), 1, NULL },
+ { "ignore", opO(ignore), 1, "" },
+ { "infobox", opW(infobox), 2, "<text> <height> <width>" },
+ { "input-fd", opO(input_fd), 1, "<fd>" },
+ { "inputbox", opW(inputbox), 2, "<text> <height> <width> [<init>]" },
+ { "inputmenu", opW(inputmenu), 2, "<text> <height> <width> <menu height> <tag1> <item1>..." },
+ { "insecure", svT(insecure), 1, "" },
+ { "item-help", svT(item_help), 1, "" },
+ { "keep-colors", xxT(keep_colors), 1, NULL },
+ { "keep-tite", svT(keep_tite), 1, "" },
+ { "keep-window", svT(keep_window), 1, "" },
+ { "last-key", svT(last_key), 1, "" },
+ { "max-input", svN(max_input), 1, "<n>" },
+ { "menu", opW(menu), 2, "<text> <height> <width> <menu height> <tag1> <item1>..." },
+ { "mixedform", opW(mixedform), 2, "<text> <height> <width> <form height> <label1> <l_y1> <l_x1> <item1> <i_y1> <i_x1> <flen1> <ilen1> <itype>..." },
+ { "mixedgauge", opW(mixedgauge), 2, "<text> <height> <width> <percent> <tag1> <item1>..." },
+ { "msgbox", opW(msgbox), 2, "<text> <height> <width>" },
+ { "no-cancel", svT(nocancel), 1, "" },
+ { "no-close", xxT(no_close), 1, NULL },
+ { "no-collapse", svT(nocollapse), 1, "" },
+ { "no-hot-list", svT(no_hot_list), 1, "" },
+ { "no-kill", svT(cant_kill), 1, "" },
+ { "no-label", svS(no_label), 1, "<str>" },
+ { "no-lines", svT(no_lines), 1, "" },
+ { "no-mouse", ssT(no_mouse), 1, "" },
+ { "no-nl-expand", svT(no_nl_expand), 1, "" },
+ { "no-ok", svT(nook), 1, "" },
+ { "no-shadow", ssF(use_shadow), 1, "" },
+ { "ok-label", svS(ok_label), 1, "<str>" },
+ { "output-fd", opO(output_fd), 1, "<fd>" },
+ { "output-separator",svS(output_separator), 1, "<str>" },
+ { "passwordbox", opW(passwordbox), 2, "<text> <height> <width> [<init>]" },
+ { "passwordform", opW(passwordform), 2, "<text> <height> <width> <form height> <label1> <l_y1> <l_x1> <item1> <i_y1> <i_x1> <flen1> <ilen1>..." },
+ { "pause", opW(pause), 2, "<text> <height> <width> <seconds>" },
+ { "prgbox", opW(prgbox), 2, "<text> <command> <height> <width>" },
+ { "print-maxsize", opO(print_maxsize), 1, "" },
+ { "print-size", svT(print_siz), 1, "" },
+ { "print-text-only",ssT(text_only), 5, "<text> <height> <width>" },
+ { "print-text-size",opO(print_text_size), 5, "<text> <height> <width>" },
+ { "print-version", opO(print_version), 5, "" },
+ { "programbox", opW(programbox), 2, "<text> <height> <width>" },
+ { "progressbox", opW(progressbox), 2, "<text> <height> <width>" },
+ { "quoted", svT(quoted), 1, "" },
+ { "radiolist", opW(radiolist), 2, "<text> <height> <width> <list height> <tag1> <item1> <status1>..." },
+ { "screen-center", xxT(screen_center), 1, NULL },
+ { "scrollbar", ssT(use_scrollbar), 1, "" },
+ { "separate-output",svT(separate_output), 1, "" },
+ { "separate-widget",ssS(separate_str), 1, "<str>" },
+ { "separator", svS(output_separator), 1, NULL },
+ { "single-quoted", svT(single_quoted), 1, "" },
+ { "size-err", svT(size_err), 1, "" },
+ { "sleep", svN(sleep_secs), 1, "<secs>" },
+ { "smooth", xxT(smooth), 1, NULL },
+ { "stderr", opO(output_stderr), 1, "" },
+ { "stdout", opO(output_stdout), 1, "" },
+ { "tab-correct", svT(tab_correct), 1, "" },
+ { "tab-len", ssN(tab_len), 1, "<n>" },
+ { "tailbox", opW(tailbox), 2, "<file> <height> <width>" },
+ { "tailboxbg", opW(tailboxbg), 2, "<file> <height> <width>" },
+ { "textbox", opW(textbox), 2, "<file> <height> <width>" },
+ { "time-format", svS(time_format), 1, "<str>" },
+ { "timeout", svN(timeout_secs), 1, "<secs>" },
+ { "title", svS(title), 1, "<title>" },
+ { "trim", svT(trim_whitespace), 1, "" },
+ { "under-mouse", xxT(under_mouse), 1, NULL },
+ { "version", opO(version), 5, "" },
+ { "visit-items", ssT(visit_items), 1, "" },
+ { "wmclass", xxS(wmclass), 1, NULL },
+ { "yes-label", svS(yes_label), 1, "<str>" },
+ { "yesno", opW(yesno), 2, "<text> <height> <width>" },
#ifdef HAVE_WHIPTAIL
- { "cancel-button", o_cancel_label, 1, NULL },
- { "fb", o_fullbutton, 1, NULL },
- { "fullbutton", o_fullbutton, 1, NULL },
- { "no-button", o_no_label, 1, NULL },
- { "ok-button", o_ok_label, 1, NULL },
- { "scrolltext", o_scrollbar, 1, NULL },
- { "topleft", o_topleft, 1, NULL },
- { "yes-button", o_yes_label, 1, NULL },
+ { "cancel-button", svS(cancel_label), 1, NULL },
+ { "fb", xxT(fullbutton), 1, NULL },
+ { "fullbutton", xxT(fullbutton), 1, NULL },
+ { "no-button", svS(no_label), 1, NULL },
+ { "ok-button", svS(ok_label), 1, NULL },
+ { "scrolltext", ssT(use_scrollbar), 1, NULL },
+ { "topleft", svT(begin_set), 1, NULL },
+ { "yes-button", svS(yes_label), 1, NULL },
#endif
#ifdef HAVE_XDIALOG
- { "calendar", o_calendar, 2, "<text> <height> <width> <day> <month> <year>" },
- { "dselect", o_dselect, 2, "<directory> <height> <width>" },
- { "editbox", o_editbox, 2, "<file> <height> <width>" },
- { "fselect", o_fselect, 2, "<filepath> <height> <width>" },
- { "timebox", o_timebox, 2, "<text> <height> <width> <hour> <minute> <second>" },
- { "week-start", o_week_start, 1, "<str>" },
- { "iso-week", o_iso_week, 1, NULL },
+ { "calendar", opW(calendar), 2, "<text> <height> <width> <day> <month> <year>" },
+ { "dselect", opW(dselect), 2, "<directory> <height> <width>" },
+ { "editbox", opW(editbox), 2, "<file> <height> <width>" },
+ { "fselect", opW(fselect), 2, "<filepath> <height> <width>" },
+ { "timebox", opW(timebox), 2, "<text> <height> <width> <hour> <minute> <second>" },
+ { "week-start", svS(week_start), 1, "<str>" },
+ { "iso-week", svT(iso_week), 1, NULL },
#endif
#ifdef HAVE_XDIALOG2
- { "buildlist", o_buildlist, 2, "<text> <height> <width> <list-height> <tag1> <item1> <status1>..." },
- { "no-items", o_no_items, 1, "" },
- { "no-tags", o_no_tags, 1, "" },
- { "rangebox", o_rangebox, 2, "<text> <height> <width> <min-value> <max-value> <default-value>" },
- { "reorder", o_reorder, 1, "" },
- { "treeview", o_treeview, 2, "<text> <height> <width> <list-height> <tag1> <item1> <status1> <depth1>..." },
+ { "buildlist", opW(buildlist), 2, "<text> <height> <width> <list-height> <tag1> <item1> <status1>..." },
+ { "no-items", svT(no_items), 1, "" },
+ { "no-tags", svT(no_tags), 1, "" },
+ { "rangebox", opW(rangebox), 2, "<text> <height> <width> <min-value> <max-value> <default-value>" },
+ { "reorder", svT(reorder), 1, "" },
+ { "treeview", opW(treeview), 2, "<text> <height> <width> <list-height> <tag1> <item1> <status1> <depth1>..." },
#endif
#if defined(HAVE_XDIALOG2) || defined(HAVE_WHIPTAIL)
- { "noitem", o_no_items, 1, NULL },
- { "notags", o_no_tags, 1, NULL },
+ { "noitem", svT(no_items), 1, NULL },
+ { "notags", svT(no_tags), 1, NULL },
#endif
#ifdef HAVE_DLG_TRACE
- { "trace", o_trace, 1, "<file>" },
+ { "trace", opO(trace), 1, "<file>" },
#endif
};
/* *INDENT-ON* */
@@ -499,11 +542,6 @@ unescape_argv(int *argcp, char ***argvp)
if ((filename = (*argvp)[j + 1]) != 0) {
FILE *fp;
char **list;
- char *blob;
- int added;
- size_t bytes_read;
- size_t length;
- int n;
if (*filename == '&') {
fp = fdopen(atoi(filename + sizeof(char)), "r");
@@ -512,6 +550,12 @@ unescape_argv(int *argcp, char ***argvp)
}
if (fp) {
+ char *blob;
+ int added;
+ size_t bytes_read;
+ size_t length;
+ int n;
+
DLG_TRACE(("# opened --file %s ..\n", filename));
blob = NULL;
length = 0;
@@ -609,21 +653,52 @@ unescape_argv(int *argcp, char ***argvp)
dialog_argv = (*argvp);
}
-static eOptions
-lookupOption(const char *name, int pass)
+static const Options *
+findOption(const char *name, int pass, bool recur)
{
- unsigned n;
- eOptions result = o_unknown;
+ const Options *result = NULL;
- if (isOption(name)) {
- name += 2;
- for (n = 0; n < sizeof(options) / sizeof(options[0]); n++) {
+ if (!strncmp(name, "--", 2) && isalpha(UCH(name[2]))) {
+ unsigned n;
+
+ name += 2; /* skip the "--" */
+ for (n = 0; n < TableSize(options); n++) {
if ((pass & options[n].pass) != 0
&& !strcmp(name, options[n].name)) {
- result = options[n].code;
+ result = &options[n];
break;
}
}
+ if (result == NULL && !recur) {
+ char *temp = malloc(8 + strlen(name));
+ if (temp != NULL) {
+ if (!strncmp(name, "no", 2)) {
+ int skip = !strncmp(name, "no-", 3) ? 3 : 2;
+ sprintf(temp, "--no-%s", name + skip);
+ result = findOption(temp, pass, TRUE);
+ if (result == NULL) {
+ sprintf(temp, "--%s", name + skip);
+ result = findOption(temp, pass, TRUE);
+ }
+ }
+ if (result == NULL && strncmp(name, "no", 2)) {
+ sprintf(temp, "--no-%s", name);
+ result = findOption(temp, pass, TRUE);
+ }
+ free(temp);
+ }
+ }
+ }
+ return result;
+}
+
+static eOptions
+lookupOption(const char *name, int pass)
+{
+ eOptions result = o_unknown;
+ const Options *data = findOption(name, pass, FALSE);
+ if (data != NULL) {
+ result = data->code;
}
return result;
}
@@ -632,7 +707,7 @@ static void
Usage(const char *msg)
{
handle_leaks();
- dlg_exiterr("Error: %s.\nUse --help to list options.\n\n", msg);
+ dlg_exiterr("%s.\nUse --help to list options.\n\n", msg);
}
/*
@@ -658,10 +733,11 @@ static int
howmany_tags(char *argv[], int group)
{
int result = 0;
- int have;
char temp[80];
while (argv[0] != 0) {
+ int have;
+
if (isOption(argv[0]))
break;
if ((have = arg_rest(argv)) < group) {
@@ -687,11 +763,12 @@ numeric_arg(char **av, int n)
int result = 0;
if (n < dlg_count_argv(av)) {
- char msg[80];
char *last = 0;
result = (int) strtol(av[n], &last, 10);
if (last == 0 || *last != 0) {
+ char msg[80];
+
sprintf(msg, "Expected a number for token %d of %.20s", n, av[0]);
Usage(msg);
}
@@ -1289,6 +1366,24 @@ optionValue(char **argv, int *num)
return result;
}
+/*
+ * In findOption, we made provision for adding/removing a "no" prefix from
+ * any boolean option. This function determines the actual true/false result.
+ */
+static bool
+optionBool(const char *actual, const Options * data)
+{
+ bool normal = (data->type == tTrue) ? TRUE : FALSE;
+ bool result = !strcmp(actual + 2, data->name) ? normal : !normal;
+ if (result != normal) {
+ int want_no = (strncmp(actual + 2, "no", 2) == 0);
+ int have_no = (strncmp(data->name, "no", 2) == 0);
+ if (have_no == want_no)
+ result = normal;
+ }
+ return result;
+}
+
/* Return exit-code for a named button */
static int
button_code(const char *name)
@@ -1310,7 +1405,7 @@ button_code(const char *name)
int code = DLG_EXIT_ERROR;
size_t i;
- for (i = 0; i < (sizeof(table) / sizeof(table[0])); i++) {
+ for (i = 0; i < TableSize(table); i++) {
if (!dlg_strcmp(name, table[i].name)) {
code = table[i].code;
break;
@@ -1351,8 +1446,11 @@ PrintTextOnly(char **argv, int *offset, eOptions code)
int width2 = 0;
int next = arg_rest(argv + *offset);
- if (LINES <= 0 && COLS <= 0)
- dlg_ttysize(fileno(dialog_state.input), &LINES, &COLS);
+ if (LINES <= 0 && COLS <= 0) {
+ dlg_ttysize(fileno(dialog_state.input),
+ &dialog_state.screen_height,
+ &dialog_state.screen_width);
+ }
text = strdup(optionString(argv, offset));
IgnoreNonScreen(argv, *offset);
@@ -1369,7 +1467,7 @@ PrintTextOnly(char **argv, int *offset, eOptions code)
dlg_auto_size(NULL, text, &height2, &width2, height, width);
switch (code) {
- case o_print_text_only:
+ case o_text_only:
dialog_state.text_only = TRUE;
dlg_print_autowrap(stdscr, text, height2, width2);
dialog_state.text_only = FALSE;
@@ -1412,7 +1510,7 @@ lookupMode(eOptions code)
const Mode *modePtr = 0;
unsigned n;
- for (n = 0; n < sizeof(modes) / sizeof(modes[0]); n++) {
+ for (n = 0; n < TableSize(modes); n++) {
if (modes[n].code == code) {
modePtr = &modes[n];
break;
@@ -1447,7 +1545,7 @@ Help(void)
static const char *const tbl_1[] =
{
"cdialog (ComeOn Dialog!) version %s",
- "Copyright 2000-2017,2018 Thomas E. Dickey",
+ "Copyright 2000-2020,2021 Thomas E. Dickey",
"This is free software; see the source for copying conditions. There is NO",
"warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.",
"",
@@ -1468,7 +1566,7 @@ Help(void)
"Global-auto-size if also menu_height/list_height = 0.",
0
};
- size_t limit = sizeof(options) / sizeof(options[0]);
+ size_t limit = TableSize(options);
size_t j, k;
const Options **opts;
@@ -1545,121 +1643,92 @@ process_trace_option(char **argv, int *offset)
* output stream.
*/
static int
-process_common_options(int argc, char **argv, int offset, bool output)
+process_common_options(int argc, char **argv, int offset, int output)
{
+ const Options *data = NULL;
bool done = FALSE;
- eOptions code;
- DLG_TRACE(("# process_common_options, offset %d\n", offset));
+ DLG_TRACE(("# process_common_options, offset %d:%d\n", offset, argc));
+
+ while (!done && offset < argc) {
+ static char empty[] = "";
+ eOptions code = o_unknown;
+ char *sval = empty;
+ bool bval;
+ int nval;
+ char *target;
- while (offset < argc && !done) { /* Common options */
DLG_TRACE(("#\targv[%d] = %s\n", offset, argv[offset]));
- switch (code = lookupOption(argv[offset], 1)) {
- case o_title:
- dialog_vars.title = optionString(argv, &offset);
- break;
- case o_backtitle:
- dialog_vars.backtitle = optionString(argv, &offset);
- break;
- case o_separate_widget:
- dialog_state.separate_str = optionString(argv, &offset);
- break;
- case o_separate_output:
- dialog_vars.separate_output = TRUE;
- break;
- case o_colors:
- dialog_vars.colors = TRUE;
- break;
- case o_cr_wrap:
- dialog_vars.cr_wrap = TRUE;
- break;
- case o_no_nl_expand:
- dialog_vars.no_nl_expand = TRUE;
- break;
- case o_no_collapse:
- dialog_vars.nocollapse = TRUE;
- break;
- case o_no_kill:
- dialog_vars.cant_kill = TRUE;
- break;
- case o_nocancel:
- dialog_vars.nocancel = TRUE;
- break;
- case o_nook:
- dialog_vars.nook = TRUE;
- break;
- case o_quoted:
- dialog_vars.quoted = TRUE;
+ if ((data = findOption(argv[offset], 1, FALSE)) == NULL) {
+ done = TRUE;
+ continue;
+ }
+
+ switch (data->vars) {
+ default:
+ target = NULL;
break;
- case o_single_quoted:
- dialog_vars.single_quoted = TRUE;
+ case 1:
+ target = (char *) &dialog_state;
break;
- case o_size_err:
- dialog_vars.size_err = TRUE;
+ case 2:
+ target = (char *) &dialog_vars;
break;
- case o_beep:
- dialog_vars.beep_signal = TRUE;
+ }
+
+#define TraceTarget \
+ ((target == (char *) &dialog_state) \
+ ? "dialog_state" \
+ : "dialog_vars")
+#define TraceBVal (bval ? "TRUE" : "FALSE")
+#define TraceDone(fmt,value) \
+ DLG_TRACE(("#\t.. set %s.%s = %"fmt"\n", TraceTarget, data->name, value))
+#define TraceLate(fmt,value) \
+ DLG_TRACE(("#\t.. defer setting %s = %"fmt"\n", data->name, value))
+
+ code = data->code;
+ switch (data->type) {
+ default:
break;
- case o_beep_after:
- dialog_vars.beep_after_signal = TRUE;
+ case tFalse:
+ case tTrue:
+ bval = optionBool(argv[offset], data);
+ if (target != NULL) {
+ *(bool *) (target + data->offset) = bval;
+ TraceDone("s", TraceBVal);
+ } else {
+ TraceLate("s", TraceBVal);
+ }
break;
- case o_scrollbar:
- dialog_state.use_scrollbar = TRUE;
+ case tNumber:
+ nval = optionValue(argv, &offset);
+ if (target != NULL) {
+ *(int *) (void *) (target + data->offset) = nval;
+ TraceDone("d", nval);
+ } else {
+ TraceLate("d", nval);
+ }
break;
- case o_shadow:
- dialog_state.use_shadow = TRUE;
+ case tString:
+ sval = optionString(argv, &offset);
+ if (target != NULL) {
+ *(char **) (void *) (target + data->offset) = sval;
+ TraceDone("s", sval);
+ } else {
+ TraceLate("s", sval);
+ }
break;
+ }
+
+ switch (code) {
case o_defaultno:
- dialog_vars.defaultno = TRUE;
dialog_vars.default_button = DLG_EXIT_CANCEL;
break;
case o_default_button:
- dialog_vars.default_button = button_code(optionString(argv, &offset));
+ dialog_vars.default_button = button_code(sval);
dialog_vars.defaultno = dialog_vars.default_button == DLG_EXIT_CANCEL;
break;
- case o_default_item:
- dialog_vars.default_item = optionString(argv, &offset);
- break;
- case o_insecure:
- dialog_vars.insecure = TRUE;
- break;
- case o_item_help:
- dialog_vars.item_help = TRUE;
- break;
- case o_help_line:
- dialog_vars.help_line = optionString(argv, &offset);
- break;
- case o_help_file:
- dialog_vars.help_file = optionString(argv, &offset);
- break;
- case o_help_button:
- dialog_vars.help_button = TRUE;
- break;
- case o_help_status:
- dialog_vars.help_status = TRUE;
- break;
- case o_help_tags:
- dialog_vars.help_tags = TRUE;
- break;
- case o_extra_button:
- dialog_vars.extra_button = TRUE;
- break;
- case o_ignore:
- ignore_unknown = TRUE;
- break;
- case o_keep_window:
- dialog_vars.keep_window = TRUE;
- break;
- case o_last_key:
- dialog_vars.last_key = TRUE;
- break;
- case o_no_shadow:
- dialog_state.use_shadow = FALSE;
- break;
- case o_print_size:
- dialog_vars.print_siz = TRUE;
- break;
- case o_print_text_only:
+ case o_text_only:
case o_print_text_size:
PrintTextOnly(argv, &offset, code);
break;
@@ -1675,145 +1744,40 @@ process_common_options(int argc, char **argv, int offset, bool output)
PrintVersion(dialog_state.output);
}
break;
- case o_separator:
- case o_output_separator:
- dialog_vars.output_separator = optionString(argv, &offset);
- break;
- case o_column_separator:
- dialog_vars.column_separator = optionString(argv, &offset);
- break;
- case o_tab_correct:
- dialog_vars.tab_correct = TRUE;
- break;
- case o_sleep:
- dialog_vars.sleep_secs = optionValue(argv, &offset);
- break;
- case o_timeout:
- dialog_vars.timeout_secs = optionValue(argv, &offset);
- break;
- case o_max_input:
- dialog_vars.max_input = optionValue(argv, &offset);
- break;
- case o_tab_len:
- dialog_state.tab_len = optionValue(argv, &offset);
- break;
- case o_trim:
- dialog_vars.trim_whitespace = TRUE;
- break;
case o_visit_items:
- dialog_state.visit_items = TRUE;
dialog_state.visit_cols = 1;
break;
- case o_aspect:
- dialog_state.aspect_ratio = optionValue(argv, &offset);
- break;
- case o_begin:
- dialog_vars.begin_set = TRUE;
- dialog_vars.begin_y = optionValue(argv, &offset);
- dialog_vars.begin_x = optionValue(argv, &offset);
- break;
- case o_clear:
- dialog_vars.dlg_clear_screen = TRUE;
- break;
- case o_yes_label:
- dialog_vars.yes_label = optionString(argv, &offset);
- break;
- case o_no_label:
- dialog_vars.no_label = optionString(argv, &offset);
- break;
- case o_ok_label:
- dialog_vars.ok_label = optionString(argv, &offset);
- break;
- case o_cancel_label:
- dialog_vars.cancel_label = optionString(argv, &offset);
- break;
- case o_extra_label:
- dialog_vars.extra_label = optionString(argv, &offset);
- break;
- case o_exit_label:
- dialog_vars.exit_label = optionString(argv, &offset);
- break;
- case o_help_label:
- dialog_vars.help_label = optionString(argv, &offset);
- break;
- case o_date_format:
- dialog_vars.date_format = optionString(argv, &offset);
- break;
- case o_time_format:
- dialog_vars.time_format = optionString(argv, &offset);
- break;
- case o_keep_tite:
- dialog_vars.keep_tite = TRUE;
+ case o_begin_set:
+#ifdef HAVE_WHIPTAIL
+ if (!strcmp(argv[offset], "--topleft")) {
+ dialog_vars.begin_y = 0;
+ dialog_vars.begin_x = 0;
+ } else
+#endif
+ {
+ dialog_vars.begin_y = optionValue(argv, &offset);
+ dialog_vars.begin_x = optionValue(argv, &offset);
+ }
break;
case o_ascii_lines:
- dialog_vars.ascii_lines = TRUE;
dialog_vars.no_lines = FALSE;
break;
case o_no_lines:
- dialog_vars.no_lines = TRUE;
dialog_vars.ascii_lines = FALSE;
break;
case o_no_mouse:
- dialog_state.no_mouse = TRUE;
mouse_close();
break;
-#ifdef HAVE_WHIPTAIL
- case o_topleft:
- dialog_vars.begin_set = TRUE;
- dialog_vars.begin_y = 0;
- dialog_vars.begin_x = 0;
- break;
- case o_fullbutton:
- /* ignore */
- break;
-#endif
- /* options of Xdialog which we ignore */
- case o_icon:
- case o_wmclass:
- (void) optionString(argv, &offset);
- /* FALLTHRU */
- case o_allow_close:
- case o_auto_placement:
- case o_fixed_font:
- case o_keep_colors:
- case o_no_close:
- case o_no_cr_wrap:
- case o_screen_center:
- case o_smooth:
- case o_under_mouse:
- break;
case o_unknown:
- if (ignore_unknown)
- break;
- /* FALLTHRU */
- default: /* no more common options */
- done = TRUE;
+ done = !ignore_unknown;
+ default:
break;
#ifdef HAVE_DLG_TRACE
case o_trace:
process_trace_option(argv, &offset);
break;
#endif
-#if defined(HAVE_XDIALOG2) || defined(HAVE_WHIPTAIL)
- case o_no_items:
- dialog_vars.no_items = TRUE;
- break;
- case o_no_tags:
- dialog_vars.no_tags = TRUE;
- break;
-#endif
-#ifdef HAVE_XDIALOG2
- case o_reorder:
- dialog_vars.reorder = TRUE;
- break;
-#endif
-#ifdef HAVE_XDIALOG
- case o_week_start:
- dialog_vars.week_start = optionString(argv, &offset);
- break;
-#endif
case o_iso_week:
- dialog_vars.iso_week = TRUE;
if (dialog_vars.week_start == 0) { /* Monday is implied */
static char default_1st[] = "1";
dialog_vars.week_start = default_1st;
@@ -1854,7 +1818,7 @@ init_result(char *buffer)
* environment variable.
*/
if (first) {
- char *env = getenv("DIALOGOPTS");
+ char *env = dlg_getenv_str("DIALOGOPTS");
if (env != 0)
env = dlg_strclone(env);
if (env != 0) {
@@ -1875,13 +1839,12 @@ main(int argc, char *argv[])
char temp[256];
bool esc_pressed = FALSE;
bool keep_tite = FALSE;
- bool first_time = TRUE;
+ int initial = 1;
int offset = 1;
- int offset_add;
+ int offset_add = 0;
int retval = DLG_EXIT_OK;
- int j, have;
+ int j;
eOptions code;
- const Mode *modePtr;
char my_buffer[MAX_LEN + 1];
memset(&dialog_state, 0, sizeof(dialog_state));
@@ -1914,10 +1877,10 @@ main(int argc, char *argv[])
while (offset < argc) {
int base = offset;
switch (lookupOption(argv[offset], 7)) {
- case o_stdout:
+ case o_output_stdout:
dialog_state.output = stdout;
break;
- case o_stderr:
+ case o_output_stderr:
dialog_state.output = stderr;
break;
case o_input_fd:
@@ -1975,7 +1938,7 @@ main(int argc, char *argv[])
}
offset = 1;
init_result(my_buffer);
- dialog_vars.keep_tite = keep_tite; /* init_result() cleared global */
+ dialog_vars.keep_tite |= keep_tite; /* init_result() cleared global */
/*
* Dialog's output may be redirected (see above). Handle the special
@@ -1992,9 +1955,10 @@ main(int argc, char *argv[])
case o_print_version:
PrintVersion(dialog_state.output);
break;
- case o_clear:
+ case o_dlg_clear_screen:
initscr();
refresh();
+ dlg_keep_tite((dialog_state.output == stdout) ? stderr : stdout);
endwin();
break;
case o_ignore:
@@ -2027,20 +1991,19 @@ main(int argc, char *argv[])
* which can be done before involving curses, in case we can exit
* without initializing curses (and writing to the terminal).
*/
- offset = process_common_options(argc, argv, offset, TRUE);
- if (offset >= argc)
+ initial = process_common_options(argc, argv, offset, TRUE);
+ if (initial >= argc)
dlg_exit(DLG_EXIT_OK);
}
init_dialog(dialog_state.input, dialog_state.output);
while (offset < argc && !esc_pressed) {
- if (first_time) {
- first_time = FALSE;
- } else {
- init_result(my_buffer);
- offset = process_common_options(argc, argv, offset, TRUE);
- }
+ int have;
+ const Mode *modePtr;
+
+ init_result(my_buffer);
+ offset = process_common_options(argc, argv, offset, offset > initial);
if (argv[offset] == NULL) {
if (ignore_unknown)
diff --git a/dialog.h b/dialog.h
index 2746cd03328d..4ac3a4248ce5 100644
--- a/dialog.h
+++ b/dialog.h
@@ -1,9 +1,9 @@
/*
- * $Id: dialog.h,v 1.283 2018/06/19 22:52:11 tom Exp $
+ * $Id: dialog.h,v 1.304 2021/01/17 16:58:22 tom Exp $
*
* dialog.h -- common declarations for all dialog modules
*
- * Copyright 2000-2017,2018 Thomas E. Dickey
+ * Copyright 2000-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -126,14 +126,27 @@
#define USE_SHADOW TRUE
#define USE_COLORS TRUE
+/*
+ * These allow using the print-formatting code before curses is initialized.
+ */
+#define DLG_COLS (COLS ? COLS : dialog_state.screen_width)
+#define DLG_LINES (LINES ? LINES : dialog_state.screen_height)
+
+/*
+ * Define the usable size of a window, discounting the area needed for shadow.
+ */
#ifdef HAVE_COLOR
-#define SCOLS (COLS - (dialog_state.use_shadow ? SHADOW_COLS : 0))
-#define SLINES (LINES - (dialog_state.use_shadow ? SHADOW_ROWS : 0))
+#define SCOLS (DLG_COLS - (dialog_state.use_shadow ? SHADOW_COLS : 0))
+#define SLINES (DLG_LINES - (dialog_state.use_shadow ? SHADOW_ROWS : 0))
#else
#define SCOLS COLS
#define SLINES LINES
#endif
+/*
+ * These are the default values for exit-codes, which can be overridden by
+ * environment variables, e.g., $DIALOG_CANCEL for DLG_EXIT_CANCEL.
+ */
#define DLG_EXIT_ESC 255
#define DLG_EXIT_UNKNOWN -2 /* never return this (internal use) */
#define DLG_EXIT_ERROR -1 /* the shell sees this as 255 */
@@ -142,19 +155,21 @@
#define DLG_EXIT_HELP 2
#define DLG_EXIT_EXTRA 3
#define DLG_EXIT_ITEM_HELP 4 /* actually DLG_EXIT_HELP */
+#define DLG_EXIT_TIMEOUT 5
#define DLG_CTRL(n) ((n) & 0x1f) /* CTRL is preferred, but conflicts */
+#define CHR_LEAVE DLG_CTRL('D')
#define CHR_HELP DLG_CTRL('E')
#define CHR_BACKSPACE DLG_CTRL('H')
#define CHR_REPAINT DLG_CTRL('L')
-#define CHR_KILL DLG_CTRL('U')
-#define CHR_LITERAL DLG_CTRL('V')
-#define CHR_DELETE 127
#define CHR_NEXT DLG_CTRL('N')
#define CHR_PREVIOUS DLG_CTRL('P')
+#define CHR_KILL DLG_CTRL('U')
#define CHR_TRACE DLG_CTRL('T')
+#define CHR_LITERAL DLG_CTRL('V')
#define CHR_SPACE ' '
+#define CHR_DELETE 127
#define ESC 27
#define TAB DLG_CTRL('I')
@@ -179,6 +194,7 @@
/* how many spaces is a tab long (default)? */
#define TAB_LEN 8
#define WTIMEOUT_VAL 10 /* minimum amount of time needed for curses */
+#define WTIMEOUT_OFF -1 /* value to disable timeout */
#ifndef A_CHARTEXT
#define A_CHARTEXT 0xff
@@ -429,6 +445,7 @@ typedef struct _dlg_windows {
struct _dlg_windows *next;
WINDOW *normal;
WINDOW *shadow;
+ int getc_timeout;
} DIALOG_WINDOWS;
/*
@@ -467,6 +484,13 @@ typedef struct {
bool text_only; /* option "--print-text-only", etc. */
int text_height;
int text_width;
+ /* 1.3-20190211 */
+ int screen_height;
+ int screen_width;
+#ifdef KEY_RESIZE
+ /* 1.3-20190724 */
+ bool had_resize; /* ERR may follow KEY_RESIZE when polling */
+#endif
} DIALOG_STATE;
extern DIALOG_STATE dialog_state;
@@ -552,6 +576,13 @@ typedef struct {
bool iso_week; /* option "--iso-week" */
/* 1.3-20170131 */
bool reorder; /* option "--reorder" */
+ /* 1.3-20201117 */
+ int pause_secs; /* used by pause widget */
+ /* 1.3-20201126 */
+ bool erase_on_exit; /* option "--erase-on-exit" */
+ bool cursor_off_label; /* option "--cursor-off-label" */
+ /* 1.3-20210117 */
+ bool no_hot_list; /* option "--no-hot-list" */
} DIALOG_VARS;
#define USE_ITEM_HELP(s) (dialog_vars.item_help && (s) != 0)
@@ -595,12 +626,16 @@ extern DIALOG_VARS dialog_vars;
* Table for attribute- and color-values.
*/
typedef struct {
- chtype atr;
+ chtype atr; /* attribute corresponding to fg, bg, etc */
#ifdef HAVE_COLOR
- int fg;
- int bg;
- int hilite;
-#endif
+ int fg; /* foreground color-number */
+ int bg; /* background color-number */
+ int hilite; /* true if bold */
+#ifdef HAVE_RC_FILE2
+ int ul; /* true if underline */
+ int rv; /* true if reverse */
+#endif /* HAVE_RC_FILE2 */
+#endif /* HAVE_COLOR */
#ifdef HAVE_RC_FILE
const char *name;
const char *comment;
@@ -768,16 +803,20 @@ extern void dlg_remove_callback(DIALOG_CALLBACK * /*p*/);
extern void dlg_killall_bg(int *retval);
/* util.c */
+extern DIALOG_WINDOWS * _dlg_find_window(WINDOW * /* win */);
+extern WINDOW * dlg_der_window(WINDOW * /*win*/, int /*height*/, int /*width*/, int /*y*/, int /*x*/);
extern WINDOW * dlg_new_modal_window(WINDOW * /*parent*/, int /*height*/, int /*width*/, int /*y*/, int /*x*/);
extern WINDOW * dlg_new_window(int /*height*/, int /*width*/, int /*y*/, int /*x*/);
extern WINDOW * dlg_sub_window(WINDOW * /*win*/, int /*height*/, int /*width*/, int /*y*/, int /*x*/);
extern bool dlg_need_separator(void);
+extern char * dlg_getenv_str(const char * /*name*/);
extern char * dlg_set_result(const char * /*string*/);
extern char * dlg_strclone(const char * /*cprompt*/);
extern char * dlg_strempty(void);
extern chtype dlg_asciibox(chtype /*ch*/);
extern chtype dlg_boxchar(chtype /*ch*/);
extern chtype dlg_get_attrs(WINDOW * /*win*/);
+extern const char * dlg_exitcode2s(int /*code*/);
extern const char * dlg_print_line(WINDOW * /*win*/, chtype * /*attr*/, const char * /*prompt*/, int /*lm*/, int /*rm*/, int * /*x*/);
extern int dlg_box_x_ordinate(int /*width*/);
extern int dlg_box_y_ordinate(int /*height*/);
@@ -789,8 +828,11 @@ extern int dlg_default_item(char ** /*items*/, int /*llen*/);
extern int dlg_default_listitem(DIALOG_LISTITEM * /*items*/);
extern int dlg_defaultno_button(void);
extern int dlg_default_button(void);
+extern int dlg_exitname2n(const char * /*name*/);
+extern int dlg_getenv_num(const char * /*name*/, int * /* value */);
extern int dlg_max_input(int /*max_len*/);
extern int dlg_print_scrolled(WINDOW * /* win */, const char * /* prompt */, int /* offset */, int /* height */, int /* width */, int /* pauseopt */);
+extern int dlg_set_timeout(WINDOW * /* win */, bool /* will_getc */);
extern void dlg_add_help_formitem(int * /* result */, char ** /* tag */, DIALOG_FORMITEM * /* item */);
extern void dlg_add_help_listitem(int * /* result */, char ** /* tag */, DIALOG_LISTITEM * /* item */);
extern void dlg_add_quoted(char * /*string*/);
@@ -814,11 +856,13 @@ extern void dlg_draw_box2(WINDOW * /*win*/, int /*y*/, int /*x*/, int /*height*/
extern void dlg_draw_title(WINDOW *win, const char *title);
extern void dlg_exit(int /*code*/) GCC_NORETURN;
extern void dlg_item_help(const char * /*txt*/);
+extern void dlg_keep_tite(FILE * /*output */);
extern void dlg_print_autowrap(WINDOW * /*win*/, const char * /*prompt*/, int /*height*/, int /*width*/);
extern void dlg_print_listitem(WINDOW * /*win*/, const char * /*text*/, int /*climit*/, bool /*first*/, int /*selected*/);
extern void dlg_print_size(int /*height*/, int /*width*/);
extern void dlg_print_text(WINDOW * /*win*/, const char * /*txt*/, int /*len*/, chtype * /*attr*/);
extern void dlg_put_backtitle(void);
+extern void dlg_reset_timeout(WINDOW * /* win */);
extern void dlg_restore_vars(DIALOG_VARS * /* save */);
extern void dlg_save_vars(DIALOG_VARS * /* save */);
extern void dlg_set_focus(WINDOW * /*parent*/, WINDOW * /*win*/);
@@ -845,6 +889,7 @@ extern int dlg_strcmp(const char * /*a*/, const char * /*b*/);
#ifdef HAVE_DLG_TRACE
#define DLG_TRACE(params) dlg_trace_msg params
extern void dlg_trace_msg(const char *fmt, ...) GCC_PRINTFLIKE(1,2);
+extern void dlg_trace_va_msg(const char *fmt, va_list ap);
#define DLG_TRACE2S(name,value) dlg_trace_2s (name,value)
#define DLG_TRACE2N(name,value) dlg_trace_2n (name,value)
extern void dlg_trace_2s(const char * /*name*/, const char * /*value*/);
@@ -856,12 +901,14 @@ extern void dlg_trace(const char * /*fname*/);
#define DLG_TRACE(params) /* nothing */
#define DLG_TRACE2S(name,value) /* nothing */
#define DLG_TRACE2N(name,value) /* nothing */
+#define dlg_trace_va_msg(fmt, ap) /* nothing */
#define dlg_trace_win(win) /* nothing */
#define dlg_trace_chr(ch,fkey) /* nothing */
#define dlg_trace(fname) /* nothing */
#endif
#ifdef KEY_RESIZE
+extern void _dlg_resize_cleanup(WINDOW * /*win*/);
extern void dlg_move_window(WINDOW * /*win*/, int /*height*/, int /*width*/, int /*y*/, int /*x*/);
extern void dlg_will_resize(WINDOW * /*win*/);
#endif
@@ -937,10 +984,15 @@ extern int dlg_mouse_wgetch_nowait (WINDOW * /*win*/, int * /*fkey*/);
*/
#ifdef NO_LEAKS
extern void _dlg_inputstr_leaks(void);
-#if defined(NCURSES_VERSION) && defined(HAVE__NC_FREE_AND_EXIT)
+#if defined(NCURSES_VERSION)
+#if defined(HAVE_CURSES_EXIT)
+/* just use curses_exit() */
+#elif defined(HAVE__NC_FREE_AND_EXIT)
extern void _nc_free_and_exit(int); /* nc_alloc.h normally not installed */
+#define curses_exit(code) _nc_free_and_exit(code)
#endif
-#endif
+#endif /* NCURSES_VERSION */
+#endif /* NO_LEAKS */
#ifdef __cplusplus
}
diff --git a/dlg_colors.h b/dlg_colors.h
index c047f721cb7a..de91627afaa5 100644
--- a/dlg_colors.h
+++ b/dlg_colors.h
@@ -1,9 +1,9 @@
/*
- * $Id: dlg_colors.h,v 1.17 2011/10/14 21:19:59 tom Exp $
+ * $Id: dlg_colors.h,v 1.18 2019/09/23 09:14:30 tom Exp $
*
* colors.h -- color attribute definitions
*
- * Copyright 2000-2007,2011 Thomas E. Dickey
+ * Copyright 2000-2011,2019 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -35,158 +35,236 @@
* DLGC_FG_xxx = foreground for "xxx"
* DLGC_BG_xxx = background for "xxx"
* DLGC_HL_xxx = highlight for "xxx"
+ * DLGC_UL_xxx = underline for "xxx"
+ * DLGC_RV_xxx = reverse for "xxx"
*/
#define DLGC_FG_SCREEN COLOR_CYAN
#define DLGC_BG_SCREEN COLOR_BLUE
#define DLGC_HL_SCREEN TRUE
+#define DLGC_UL_SCREEN FALSE
+#define DLGC_RV_SCREEN FALSE
#define DLGC_FG_SHADOW COLOR_BLACK
#define DLGC_BG_SHADOW COLOR_BLACK
#define DLGC_HL_SHADOW TRUE
+#define DLGC_UL_SHADOW FALSE
+#define DLGC_RV_SHADOW FALSE
#define DLGC_FG_DIALOG COLOR_BLACK
#define DLGC_BG_DIALOG COLOR_WHITE
#define DLGC_HL_DIALOG FALSE
+#define DLGC_UL_DIALOG FALSE
+#define DLGC_RV_DIALOG FALSE
#define DLGC_FG_TITLE COLOR_BLUE
#define DLGC_BG_TITLE COLOR_WHITE
#define DLGC_HL_TITLE TRUE
+#define DLGC_UL_TITLE FALSE
+#define DLGC_RV_TITLE FALSE
#define DLGC_FG_BORDER COLOR_WHITE
#define DLGC_BG_BORDER COLOR_WHITE
#define DLGC_HL_BORDER TRUE
+#define DLGC_UL_BORDER FALSE
+#define DLGC_RV_BORDER FALSE
#define DLGC_FG_BORDER2 DLGC_FG_DIALOG
#define DLGC_BG_BORDER2 DLGC_BG_DIALOG
#define DLGC_HL_BORDER2 DLGC_HL_DIALOG
+#define DLGC_UL_BORDER2 FALSE
+#define DLGC_RV_BORDER2 FALSE
#define DLGC_FG_BUTTON_ACTIVE COLOR_WHITE
#define DLGC_BG_BUTTON_ACTIVE COLOR_BLUE
#define DLGC_HL_BUTTON_ACTIVE TRUE
+#define DLGC_UL_BUTTON_ACTIVE FALSE
+#define DLGC_RV_BUTTON_ACTIVE FALSE
#define DLGC_FG_BUTTON_INACTIVE COLOR_BLACK
#define DLGC_BG_BUTTON_INACTIVE COLOR_WHITE
#define DLGC_HL_BUTTON_INACTIVE FALSE
+#define DLGC_UL_BUTTON_INACTIVE FALSE
+#define DLGC_RV_BUTTON_INACTIVE FALSE
#define DLGC_FG_BUTTON_KEY_ACTIVE COLOR_WHITE
#define DLGC_BG_BUTTON_KEY_ACTIVE COLOR_BLUE
#define DLGC_HL_BUTTON_KEY_ACTIVE TRUE
+#define DLGC_UL_BUTTON_KEY_ACTIVE FALSE
+#define DLGC_RV_BUTTON_KEY_ACTIVE FALSE
#define DLGC_FG_BUTTON_KEY_INACTIVE COLOR_RED
#define DLGC_BG_BUTTON_KEY_INACTIVE COLOR_WHITE
#define DLGC_HL_BUTTON_KEY_INACTIVE FALSE
+#define DLGC_UL_BUTTON_KEY_INACTIVE FALSE
+#define DLGC_RV_BUTTON_KEY_INACTIVE FALSE
#define DLGC_FG_BUTTON_LABEL_ACTIVE COLOR_YELLOW
#define DLGC_BG_BUTTON_LABEL_ACTIVE COLOR_BLUE
#define DLGC_HL_BUTTON_LABEL_ACTIVE TRUE
+#define DLGC_UL_BUTTON_LABEL_ACTIVE FALSE
+#define DLGC_RV_BUTTON_LABEL_ACTIVE FALSE
#define DLGC_FG_BUTTON_LABEL_INACTIVE COLOR_BLACK
#define DLGC_BG_BUTTON_LABEL_INACTIVE COLOR_WHITE
#define DLGC_HL_BUTTON_LABEL_INACTIVE TRUE
+#define DLGC_UL_BUTTON_LABEL_INACTIVE FALSE
+#define DLGC_RV_BUTTON_LABEL_INACTIVE FALSE
#define DLGC_FG_FORM_ITEM_READONLY COLOR_CYAN
#define DLGC_BG_FORM_ITEM_READONLY COLOR_WHITE
#define DLGC_HL_FORM_ITEM_READONLY TRUE
+#define DLGC_UL_FORM_ITEM_READONLY FALSE
+#define DLGC_RV_FORM_ITEM_READONLY FALSE
#define DLGC_FG_INPUTBOX COLOR_BLACK
#define DLGC_BG_INPUTBOX COLOR_WHITE
#define DLGC_HL_INPUTBOX FALSE
+#define DLGC_UL_INPUTBOX FALSE
+#define DLGC_RV_INPUTBOX FALSE
#define DLGC_FG_INPUTBOX_BORDER COLOR_BLACK
#define DLGC_BG_INPUTBOX_BORDER COLOR_WHITE
#define DLGC_HL_INPUTBOX_BORDER FALSE
+#define DLGC_UL_INPUTBOX_BORDER FALSE
+#define DLGC_RV_INPUTBOX_BORDER FALSE
#define DLGC_FG_INPUTBOX_BORDER2 DLGC_FG_INPUTBOX
#define DLGC_BG_INPUTBOX_BORDER2 DLGC_BG_INPUTBOX
#define DLGC_HL_INPUTBOX_BORDER2 DLGC_HL_INPUTBOX
+#define DLGC_UL_INPUTBOX_BORDER2 FALSE
+#define DLGC_RV_INPUTBOX_BORDER2 FALSE
#define DLGC_FG_SEARCHBOX COLOR_BLACK
#define DLGC_BG_SEARCHBOX COLOR_WHITE
#define DLGC_HL_SEARCHBOX FALSE
+#define DLGC_UL_SEARCHBOX FALSE
+#define DLGC_RV_SEARCHBOX FALSE
#define DLGC_FG_SEARCHBOX_TITLE COLOR_BLUE
#define DLGC_BG_SEARCHBOX_TITLE COLOR_WHITE
#define DLGC_HL_SEARCHBOX_TITLE TRUE
+#define DLGC_UL_SEARCHBOX_TITLE FALSE
+#define DLGC_RV_SEARCHBOX_TITLE FALSE
#define DLGC_FG_SEARCHBOX_BORDER COLOR_WHITE
#define DLGC_BG_SEARCHBOX_BORDER COLOR_WHITE
#define DLGC_HL_SEARCHBOX_BORDER TRUE
+#define DLGC_UL_SEARCHBOX_BORDER FALSE
+#define DLGC_RV_SEARCHBOX_BORDER FALSE
#define DLGC_FG_SEARCHBOX_BORDER2 DLGC_FG_SEARCHBOX
#define DLGC_BG_SEARCHBOX_BORDER2 DLGC_BG_SEARCHBOX
#define DLGC_HL_SEARCHBOX_BORDER2 DLGC_HL_SEARCHBOX
+#define DLGC_UL_SEARCHBOX_BORDER2 FALSE
+#define DLGC_RV_SEARCHBOX_BORDER2 FALSE
#define DLGC_FG_POSITION_INDICATOR COLOR_BLUE
#define DLGC_BG_POSITION_INDICATOR COLOR_WHITE
#define DLGC_HL_POSITION_INDICATOR TRUE
+#define DLGC_UL_POSITION_INDICATOR FALSE
+#define DLGC_RV_POSITION_INDICATOR FALSE
#define DLGC_FG_MENUBOX COLOR_BLACK
#define DLGC_BG_MENUBOX COLOR_WHITE
#define DLGC_HL_MENUBOX FALSE
+#define DLGC_UL_MENUBOX FALSE
+#define DLGC_RV_MENUBOX FALSE
#define DLGC_FG_MENUBOX_BORDER COLOR_WHITE
#define DLGC_BG_MENUBOX_BORDER COLOR_WHITE
#define DLGC_HL_MENUBOX_BORDER TRUE
+#define DLGC_UL_MENUBOX_BORDER FALSE
+#define DLGC_RV_MENUBOX_BORDER FALSE
#define DLGC_FG_MENUBOX_BORDER2 DLGC_FG_MENUBOX
#define DLGC_BG_MENUBOX_BORDER2 DLGC_BG_MENUBOX
#define DLGC_HL_MENUBOX_BORDER2 DLGC_HL_MENUBOX
+#define DLGC_UL_MENUBOX_BORDER2 FALSE
+#define DLGC_RV_MENUBOX_BORDER2 FALSE
#define DLGC_FG_ITEM COLOR_BLACK
#define DLGC_BG_ITEM COLOR_WHITE
#define DLGC_HL_ITEM FALSE
+#define DLGC_UL_ITEM FALSE
+#define DLGC_RV_ITEM FALSE
#define DLGC_FG_ITEM_SELECTED COLOR_WHITE
#define DLGC_BG_ITEM_SELECTED COLOR_BLUE
#define DLGC_HL_ITEM_SELECTED TRUE
+#define DLGC_UL_ITEM_SELECTED FALSE
+#define DLGC_RV_ITEM_SELECTED FALSE
#define DLGC_FG_TAG COLOR_BLUE
#define DLGC_BG_TAG COLOR_WHITE
#define DLGC_HL_TAG TRUE
+#define DLGC_UL_TAG FALSE
+#define DLGC_RV_TAG FALSE
#define DLGC_FG_TAG_SELECTED COLOR_YELLOW
#define DLGC_BG_TAG_SELECTED COLOR_BLUE
#define DLGC_HL_TAG_SELECTED TRUE
+#define DLGC_UL_TAG_SELECTED FALSE
+#define DLGC_RV_TAG_SELECTED FALSE
#define DLGC_FG_TAG_KEY COLOR_RED
#define DLGC_BG_TAG_KEY COLOR_WHITE
#define DLGC_HL_TAG_KEY FALSE
+#define DLGC_UL_TAG_KEY FALSE
+#define DLGC_RV_TAG_KEY FALSE
#define DLGC_FG_TAG_KEY_SELECTED COLOR_RED
#define DLGC_BG_TAG_KEY_SELECTED COLOR_BLUE
#define DLGC_HL_TAG_KEY_SELECTED TRUE
+#define DLGC_UL_TAG_KEY_SELECTED FALSE
+#define DLGC_RV_TAG_KEY_SELECTED FALSE
#define DLGC_FG_CHECK COLOR_BLACK
#define DLGC_BG_CHECK COLOR_WHITE
#define DLGC_HL_CHECK FALSE
+#define DLGC_UL_CHECK FALSE
+#define DLGC_RV_CHECK FALSE
#define DLGC_FG_CHECK_SELECTED COLOR_WHITE
#define DLGC_BG_CHECK_SELECTED COLOR_BLUE
#define DLGC_HL_CHECK_SELECTED TRUE
+#define DLGC_UL_CHECK_SELECTED FALSE
+#define DLGC_RV_CHECK_SELECTED FALSE
#define DLGC_FG_UARROW COLOR_GREEN
#define DLGC_BG_UARROW COLOR_WHITE
#define DLGC_HL_UARROW TRUE
+#define DLGC_UL_UARROW FALSE
+#define DLGC_RV_UARROW FALSE
#define DLGC_FG_DARROW COLOR_GREEN
#define DLGC_BG_DARROW COLOR_WHITE
#define DLGC_HL_DARROW TRUE
+#define DLGC_UL_DARROW FALSE
+#define DLGC_RV_DARROW FALSE
#define DLGC_FG_ITEMHELP COLOR_WHITE
#define DLGC_BG_ITEMHELP COLOR_BLACK
#define DLGC_HL_ITEMHELP FALSE
+#define DLGC_UL_ITEMHELP FALSE
+#define DLGC_RV_ITEMHELP FALSE
#define DLGC_FG_FORM_ACTIVE_TEXT COLOR_WHITE
#define DLGC_BG_FORM_ACTIVE_TEXT COLOR_BLUE
#define DLGC_HL_FORM_ACTIVE_TEXT TRUE
+#define DLGC_UL_FORM_ACTIVE_TEXT FALSE
+#define DLGC_RV_FORM_ACTIVE_TEXT FALSE
#define DLGC_FG_FORM_TEXT COLOR_WHITE
#define DLGC_BG_FORM_TEXT COLOR_CYAN
#define DLGC_HL_FORM_TEXT TRUE
+#define DLGC_UL_FORM_TEXT FALSE
+#define DLGC_RV_FORM_TEXT FALSE
#define DLGC_FG_GAUGE COLOR_BLUE
#define DLGC_BG_GAUGE COLOR_WHITE
#define DLGC_HL_GAUGE TRUE
+#define DLGC_UL_GAUGE FALSE
+#define DLGC_RV_GAUGE FALSE
/* End of default color definitions */
diff --git a/dlg_internals.h b/dlg_internals.h
new file mode 100644
index 000000000000..4c6fb9e09615
--- /dev/null
+++ b/dlg_internals.h
@@ -0,0 +1,47 @@
+/*
+ * $Id: dlg_internals.h,v 1.3 2019/08/08 21:29:41 tom Exp $
+ *
+ * dlg_internals.h -- runtime binding support for dialog
+ *
+ * Copyright 2019 Thomas E. Dickey
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License, version 2.1
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this program; if not, write to
+ * Free Software Foundation, Inc.
+ * 51 Franklin St., Fifth Floor
+ * Boston, MA 02110, USA.
+ */
+
+#ifndef DLG_INTERNALS_H_included
+#define DLG_INTERNALS_H_included 1
+
+#include <dialog.h>
+
+#define TableSize(name) (sizeof(name)/sizeof((name)[0]))
+
+/* *INDENT-OFF* */
+#define resizeit(name, NAME) \
+ name = ((NAME >= old_##NAME) \
+ ? (NAME - (old_##NAME - old_##name)) \
+ : old_##name)
+
+#define AddLastKey() \
+ if (dialog_vars.last_key) { \
+ if (dlg_need_separator()) \
+ dlg_add_separator(); \
+ dlg_add_last_key(-1); \
+ }
+
+
+/* *INDENT-ON* */
+
+#endif /* DLG_INTERNALS_H_included */
diff --git a/dlg_keys.c b/dlg_keys.c
index cb8af7c62719..e2706568fc61 100644
--- a/dlg_keys.c
+++ b/dlg_keys.c
@@ -1,9 +1,9 @@
/*
- * $Id: dlg_keys.c,v 1.45 2018/05/28 17:27:10 tom Exp $
+ * $Id: dlg_keys.c,v 1.58 2020/11/26 17:11:56 Glenn.Herteg Exp $
*
* dlg_keys.c -- runtime binding support for dialog
*
- * Copyright 2006-2017,2018 Thomas E. Dickey
+ * Copyright 2006-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -23,12 +23,12 @@
#include <dialog.h>
#include <dlg_keys.h>
+#include <dlg_internals.h>
#define LIST_BINDINGS struct _list_bindings
#define CHR_BACKSLASH '\\'
#define IsOctal(ch) ((ch) >= '0' && (ch) <= '7')
-#define TableSize(name) (sizeof(name)/sizeof(name[0]))
LIST_BINDINGS {
LIST_BINDINGS *link;
@@ -129,6 +129,10 @@ dlg_register_buttons(WINDOW *win, const char *name, const char **buttons)
for (n = 0; buttons[n] != 0; ++n) {
int curses_key = dlg_button_to_char(buttons[n]);
+ /* ignore binding if there is no key to bind */
+ if (curses_key < 0)
+ continue;
+
/* ignore multibyte characters */
if (curses_key >= KEY_MIN)
continue;
@@ -274,12 +278,26 @@ dlg_result_key(int dialog_key, int fkey GCC_UNUSED, int *resultp)
{
int done = FALSE;
+ DLG_TRACE(("# dlg_result_key(dialog_key=%d, fkey=%d)\n", dialog_key, fkey));
+#ifdef KEY_RESIZE
+ if (dialog_state.had_resize) {
+ if (dialog_key == ERR) {
+ dialog_key = 0;
+ } else {
+ dialog_state.had_resize = FALSE;
+ }
+ } else if (fkey && dialog_key == KEY_RESIZE) {
+ dialog_state.had_resize = TRUE;
+ }
+#endif
#ifdef HAVE_RC_FILE
if (fkey) {
switch ((DLG_KEYS_ENUM) dialog_key) {
case DLGK_OK:
- *resultp = DLG_EXIT_OK;
- done = TRUE;
+ if (!dialog_vars.nook) {
+ *resultp = DLG_EXIT_OK;
+ done = TRUE;
+ }
break;
case DLGK_CANCEL:
if (!dialog_vars.nocancel) {
@@ -319,6 +337,70 @@ dlg_result_key(int dialog_key, int fkey GCC_UNUSED, int *resultp)
return done;
}
+/*
+ * If a key was bound to one of the button-codes in dlg_result_key(), fake
+ * a button-value and an "Enter" key to cause the calling widget to return
+ * the corresponding status.
+ *
+ * See dlg_ok_buttoncode(), which maps settings for ok/extra/help and button
+ * number into exit-code.
+ */
+int
+dlg_button_key(int exit_code, int *button, int *dialog_key, int *fkey)
+{
+ int changed = FALSE;
+ switch (exit_code) {
+ case DLG_EXIT_OK:
+ if (!dialog_vars.nook) {
+ *button = 0;
+ changed = TRUE;
+ }
+ break;
+ case DLG_EXIT_EXTRA:
+ if (dialog_vars.extra_button) {
+ *button = dialog_vars.nook ? 0 : 1;
+ changed = TRUE;
+ }
+ break;
+ case DLG_EXIT_CANCEL:
+ if (!dialog_vars.nocancel) {
+ *button = dialog_vars.nook ? 1 : 2;
+ changed = TRUE;
+ }
+ break;
+ case DLG_EXIT_HELP:
+ if (dialog_vars.help_button) {
+ int cancel = dialog_vars.nocancel ? 0 : 1;
+ int extra = dialog_vars.extra_button ? 1 : 0;
+ int okay = dialog_vars.nook ? 0 : 1;
+ *button = okay + extra + cancel;
+ changed = TRUE;
+ }
+ break;
+ }
+ if (changed) {
+ DLG_TRACE(("# dlg_button_key(%d:%s) button %d\n",
+ exit_code, dlg_exitcode2s(exit_code), *button));
+ *dialog_key = *fkey = DLGK_ENTER;
+ }
+ return changed;
+}
+
+int
+dlg_ok_button_key(int exit_code, int *button, int *dialog_key, int *fkey)
+{
+ int result;
+ DIALOG_VARS save;
+
+ dlg_save_vars(&save);
+ dialog_vars.nocancel = TRUE;
+
+ result = dlg_button_key(exit_code, button, dialog_key, fkey);
+
+ dlg_restore_vars(&save);
+ return result;
+}
+
#ifdef HAVE_RC_FILE
typedef struct {
const char *name;
@@ -463,7 +545,8 @@ static const CODENAME dialog_names[] =
DIALOG_NAME(SELECT),
DIALOG_NAME(HELPFILE),
DIALOG_NAME(TRACE),
- DIALOG_NAME(TOGGLE)
+ DIALOG_NAME(TOGGLE),
+ DIALOG_NAME(LEAVE)
};
#define MAP2(letter,actual) { letter, actual }
@@ -563,13 +646,13 @@ make_binding(char *widget, int curses_key, int is_function, int dialog_key)
LIST_BINDINGS *entry = 0;
DLG_KEYS_BINDING *data = 0;
char *name;
- LIST_BINDINGS *p, *q;
DLG_KEYS_BINDING *result = find_binding(widget, curses_key);
if (result == 0
&& (entry = dlg_calloc(LIST_BINDINGS, 1)) != 0
&& (data = dlg_calloc(DLG_KEYS_BINDING, 2)) != 0
&& (name = dlg_strclone(widget)) != 0) {
+ LIST_BINDINGS *p, *q;
entry->name = name;
entry->binding = data;
@@ -606,7 +689,6 @@ make_binding(char *widget, int curses_key, int is_function, int dialog_key)
static int
decode_escaped(char **string)
{
- unsigned n;
int result = 0;
if (IsOctal(**string)) {
@@ -617,6 +699,8 @@ decode_escaped(char **string)
result = (result << 3) | (ch - '0');
}
} else {
+ unsigned n;
+
for (n = 0; n < TableSize(escaped_letters); ++n) {
if (**string == escaped_letters[n].letter) {
*string += 1;
@@ -663,13 +747,8 @@ int
dlg_parse_bindkey(char *params)
{
char *p = skip_white(params);
- char *q;
- bool escaped = FALSE;
- int modified = 0;
int result = FALSE;
- unsigned xx;
char *widget;
- int is_function = FALSE;
int curses_key;
int dialog_key;
@@ -679,6 +758,12 @@ dlg_parse_bindkey(char *params)
p = skip_black(p);
if (p != widget && *p != '\0') {
+ char *q;
+ unsigned xx;
+ bool escaped = FALSE;
+ int modified = 0;
+ int is_function = FALSE;
+
*p++ = '\0';
p = skip_white(p);
q = p;
@@ -715,7 +800,7 @@ dlg_parse_bindkey(char *params)
char fprefix[2];
char check[2];
int keynumber;
- if (sscanf(q, "%[Ff]%d%c", fprefix, &keynumber, check) == 2) {
+ if (sscanf(q, "%1[Ff]%d%c", fprefix, &keynumber, check) == 2) {
curses_key = KEY_F(keynumber);
is_function = TRUE;
} else {
diff --git a/dlg_keys.h b/dlg_keys.h
index 737db28fdab6..1179b0e99ecc 100644
--- a/dlg_keys.h
+++ b/dlg_keys.h
@@ -1,9 +1,9 @@
/*
- * $Id: dlg_keys.h,v 1.36 2016/08/28 21:23:17 tom Exp $
+ * $Id: dlg_keys.h,v 1.39 2020/11/22 23:19:24 tom Exp $
*
* dlg_keys.h -- runtime binding support for dialog
*
- * Copyright 2005-2012,2016 Thomas E. Dickey
+ * Copyright 2005-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -97,7 +97,8 @@ typedef enum {
DLGK_SELECT,
DLGK_HELPFILE,
DLGK_TRACE,
- DLGK_TOGGLE
+ DLGK_TOGGLE,
+ DLGK_LEAVE
} DLG_KEYS_ENUM;
#define is_DLGK_MOUSE(code) ((code) >= M_EVENT)
@@ -111,7 +112,8 @@ typedef enum {
#define ENTERKEY_BINDINGS \
DLG_KEYS_DATA( DLGK_ENTER, '\n' ), \
DLG_KEYS_DATA( DLGK_ENTER, '\r' ), \
- DLG_KEYS_DATA( DLGK_ENTER, KEY_ENTER )
+ DLG_KEYS_DATA( DLGK_ENTER, KEY_ENTER ), \
+ DLG_KEYS_DATA( DLGK_LEAVE, CHR_LEAVE )
/* ^U == 21 */
#define INPUTSTR_BINDINGS \
@@ -158,7 +160,9 @@ typedef enum {
#define TOGGLEKEY_BINDINGS \
DLG_KEYS_DATA( DLGK_TOGGLE, CHR_SPACE )
+extern int dlg_button_key(int /*exit_code*/, int * /*button*/, int * /*dialog_key*/, int * /*fkey*/);
extern int dlg_lookup_key(WINDOW * /*win*/, int /*curses_key*/, int * /*dialog_key*/);
+extern int dlg_ok_button_key(int /*exit_code*/, int * /*button*/, int * /*dialog_key*/, int * /*fkey*/);
extern int dlg_result_key(int /*dialog_key*/, int /*fkey*/, int * /*resultp*/);
extern void dlg_register_buttons(WINDOW * /*win*/, const char * /*name*/, const char ** /*buttons*/);
extern void dlg_register_window(WINDOW * /*win*/, const char * /*name*/, DLG_KEYS_BINDING * /*binding*/);
diff --git a/editbox.c b/editbox.c
index db0620d8f94b..1ea80dd6384a 100644
--- a/editbox.c
+++ b/editbox.c
@@ -1,12 +1,13 @@
/*
- * $Id: editbox.c,v 1.70 2018/06/19 22:57:01 tom Exp $
+ * $Id: editbox.c,v 1.80 2020/11/23 00:27:21 tom Exp $
*
* editbox.c -- implements the edit box
*
- * Copyright 2007-2016,2018 Thomas E. Dickey
+ * Copyright 2007-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
+ * as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -54,11 +55,8 @@ grow_list(char ***list, int *have, int want)
static void
load_list(const char *file, char ***list, int *rows)
{
- FILE *fp;
char *blob = 0;
struct stat sb;
- unsigned n, pass;
- unsigned need;
size_t size;
*list = 0;
@@ -72,6 +70,9 @@ load_list(const char *file, char ***list, int *rows)
if ((blob = dlg_malloc(char, size + 2)) == 0) {
fail_list();
} else {
+ FILE *fp;
+ unsigned n, pass;
+
blob[size] = '\0';
if ((fp = fopen(file, "r")) == 0)
@@ -89,7 +90,8 @@ load_list(const char *file, char ***list, int *rows)
for (pass = 0; pass < 2; ++pass) {
int first = TRUE;
- need = 0;
+ unsigned need = 0;
+
for (n = 0; n < size; ++n) {
if (first && pass) {
(*list)[need] = blob + n;
@@ -273,7 +275,8 @@ col_to_chr_offset(const char *text, int col)
return result;
}
-#define SCROLL_TO(target) show_all = scroll_to(pagesize, listsize, &base_row, &thisrow, target)
+#define Scroll_To(target) scroll_to(pagesize, listsize, &base_row, &thisrow, target)
+#define SCROLL_TO(target) show_all = Scroll_To(target)
#define PREV_ROW (*list)[thisrow - 1]
#define THIS_ROW (*list)[thisrow]
@@ -285,9 +288,10 @@ static int
widest_line(char **list)
{
int result = MAX_LEN;
- char *value;
if (list != 0) {
+ char *value;
+
while ((value = *list++) != 0) {
int check = (int) strlen(value);
if (check > result)
@@ -355,8 +359,8 @@ dlg_editbox(const char *title,
int result = DLG_EXIT_UNKNOWN;
int state;
size_t max_len = (size_t) dlg_max_input(widest_line(*list));
- char *input, *buffer;
- bool show_all, show_one, was_mouse;
+ char *buffer;
+ bool show_all, show_one;
bool first_trace = TRUE;
WINDOW *dialog;
WINDOW *editing;
@@ -436,7 +440,8 @@ dlg_editbox(const char *title,
pagesize = getmaxy(editing);
while (result == DLG_EXIT_UNKNOWN) {
- int edit = 0;
+ bool was_mouse;
+ char *input;
if (show_all) {
display_all(editing, *list, thisrow, base_row, listsize, chr_offset);
@@ -510,8 +515,10 @@ dlg_editbox(const char *title,
break;
}
if (state != sTEXT) {
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &code, &key, &fkey))
+ break;
+ }
}
was_mouse = (fkey && is_DLGK_MOUSE(key));
@@ -552,6 +559,8 @@ dlg_editbox(const char *title,
}
if (state == sTEXT) { /* editing box selected */
+ int edit = 0;
+
/*
* Intercept scrolling keys that dlg_edit_string() does not
* understand.
@@ -608,7 +617,7 @@ dlg_editbox(const char *title,
}
--listsize;
--thisrow;
- SCROLL_TO(thisrow);
+ (void) Scroll_To(thisrow);
show_all = TRUE;
}
@@ -687,24 +696,26 @@ dlg_editbox(const char *title,
chr_offset = 0;
col_offset = 0;
THIS_ROW = tmp;
- SCROLL_TO(thisrow);
+ (void) Scroll_To(thisrow);
show_all = TRUE;
} else {
- result = dlg_ok_buttoncode(state);
+ result = dlg_enter_buttoncode(state);
}
break;
+ case DLGK_LEAVE:
+ if (state >= 0)
+ result = dlg_ok_buttoncode(state);
+ break;
#ifdef KEY_RESIZE
case KEY_RESIZE:
dlg_will_resize(dialog);
/* reset data */
height = old_height;
width = old_width;
- dlg_clear();
- dlg_unregister_window(editing);
- dlg_del_window(editing);
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
/* repaint */
+ dlg_del_window(editing);
+ dlg_unregister_window(editing);
+ _dlg_resize_cleanup(dialog);
goto retry;
#endif
case DLGK_TOGGLE:
@@ -718,7 +729,7 @@ dlg_editbox(const char *title,
beep();
break;
}
- } else {
+ } else if (key > 0) {
beep();
}
}
diff --git a/formbox.c b/formbox.c
index a5de87668d22..1a4faae06625 100644
--- a/formbox.c
+++ b/formbox.c
@@ -1,9 +1,9 @@
/*
- * $Id: formbox.c,v 1.95 2018/06/21 08:23:31 tom Exp $
+ * $Id: formbox.c,v 1.103 2021/01/17 22:19:05 tom Exp $
*
* formbox.c -- implements the form (i.e., some pairs label/editbox)
*
- * Copyright 2003-2016,2018 Thomas E. Dickey
+ * Copyright 2003-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -151,12 +151,13 @@ static int
set_choice(DIALOG_FORMITEM item[], int choice, int item_no, bool * noneditable)
{
int result = -1;
- int i;
*noneditable = FALSE;
if (!is_readonly(&item[choice])) {
result = choice;
} else {
+ int i;
+
for (i = 0; i < item_no; i++) {
if (!is_readonly(&(item[i]))) {
result = i;
@@ -292,7 +293,6 @@ scroll_next(WINDOW *win, DIALOG_FORMITEM item[], int stepsize, int *choice, int
int old_scroll = *scrollamt;
int old_row = MIN(item[old_choice].text_y, item[old_choice].name_y);
int target = old_scroll + stepsize;
- int n;
if (stepsize < 0) {
if (old_row != old_scroll)
@@ -309,6 +309,8 @@ scroll_next(WINDOW *win, DIALOG_FORMITEM item[], int stepsize, int *choice, int
}
if (result) {
+ int n;
+
for (n = 0; item[n].name != 0; ++n) {
if (item[n].text_flen > 0) {
int new_row = MIN(item[n].text_y, item[n].name_y);
@@ -392,7 +394,6 @@ make_FORM_ELTs(DIALOG_FORMITEM * item,
sprintf(item[i].text, "%.*s", item[i].text_ilen, old_text);
if (item[i].text_free) {
- item[i].text_free = FALSE;
free(old_text);
}
item[i].text_free = TRUE;
@@ -500,7 +501,6 @@ dlg_form(const char *title,
: sTEXT);
int x, y, cur_x, cur_y, box_x, box_y;
int code;
- int key = 0;
int fkey;
int choice = dlg_default_formitem(items);
int new_choice, new_scroll;
@@ -608,6 +608,7 @@ dlg_form(const char *title,
while (result == DLG_EXIT_UNKNOWN) {
int edit = FALSE;
+ int key;
if (scroll_changed) {
print_form(form, items, item_no, scrollamt, choice);
@@ -658,8 +659,9 @@ dlg_form(const char *title,
}
key = dlg_mouse_wgetch((state == sTEXT) ? form : dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
+ if (dlg_result_key(key, fkey, &result)) {
break;
+ }
/* handle non-functionkeys */
if (!fkey) {
@@ -697,6 +699,10 @@ dlg_form(const char *title,
dlg_del_window(dialog);
result = (state >= 0) ? dlg_enter_buttoncode(state) : DLG_EXIT_OK;
continue;
+ case DLGK_LEAVE:
+ if (state >= 0)
+ result = dlg_ok_buttoncode(state);
+ break;
case DLGK_GRID_LEFT:
if (state == sTEXT)
@@ -780,10 +786,8 @@ dlg_form(const char *title,
height = old_height;
width = old_width;
free(prompt);
- dlg_clear();
+ _dlg_resize_cleanup(dialog);
dlg_unregister_window(form);
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
/* repaint */
goto retry;
#endif
diff --git a/fselect.c b/fselect.c
index a8e5d7eb926b..753805b27286 100644
--- a/fselect.c
+++ b/fselect.c
@@ -1,9 +1,9 @@
/*
- * $Id: fselect.c,v 1.102 2018/06/21 23:28:04 tom Exp $
+ * $Id: fselect.c,v 1.115 2021/01/16 17:19:15 tom Exp $
*
* fselect.c -- implements the file-selector box
*
- * Copyright 2000-2017,2018 Thomas E. Dickey
+ * Copyright 2000-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -21,7 +21,7 @@
* Boston, MA 02110, USA.
*/
-#include <dialog.h>
+#include <dlg_internals.h>
#include <dlg_keys.h>
#include <sys/types.h>
@@ -125,9 +125,9 @@ data_of(LIST * list)
static void
free_list(LIST * list, int reinit)
{
- int n;
-
if (list->data != 0) {
+ int n;
+
for (n = 0; list->data[n] != 0; n++)
free(list->data[n]);
free(list->data);
@@ -173,13 +173,14 @@ keep_visible(LIST * list)
static int
find_choice(char *target, LIST * list)
{
- int n;
int choice = list->choice;
- int len_1, len_2, cmp_1, cmp_2;
if (*target == 0) {
list->choice = 0;
} else {
+ int n;
+ int len_1, cmp_1;
+
/* find the match with the longest length. If more than one has the
* same length, choose the one with the closest match of the final
* character.
@@ -189,6 +190,7 @@ find_choice(char *target, LIST * list)
for (n = 0; n < list->length; n++) {
char *a = target;
char *b = list->data[n];
+ int len_2, cmp_2;
len_2 = 0;
while ((*a != 0) && (*b != 0) && (*a == *b)) {
@@ -216,13 +218,13 @@ find_choice(char *target, LIST * list)
static void
display_list(LIST * list)
{
- int n;
- int x;
- int y;
- int top;
- int bottom;
-
if (list->win != 0) {
+ int n;
+ int x;
+ int y;
+ int top;
+ int bottom;
+
dlg_attr_clear(list->win, getmaxy(list->win), getmaxx(list->win), item_attr);
for (n = list->offset; n < list->length && list->data[n]; n++) {
y = n - list->offset;
@@ -264,16 +266,17 @@ display_list(LIST * list)
* that is really required is that they're distinct, so we can put them in a
* switch statement.
*/
+#if USE_MOUSE
static void
fix_arrows(LIST * list)
{
- int x;
- int y;
- int top;
- int right;
- int bottom;
-
if (list->win != 0) {
+ int x;
+ int y;
+ int top;
+ int right;
+ int bottom;
+
getparyx(list->win, y, x);
top = y - 1;
right = getmaxx(list->win);
@@ -290,6 +293,10 @@ fix_arrows(LIST * list)
}
}
+#else
+#define fix_arrows(list) /* nothing */
+#endif
+
static bool
show_list(char *target, LIST * list, bool keep)
{
@@ -356,18 +363,29 @@ match(char *name, LIST * d_list, LIST * f_list, MATCH * match_list)
size_t test_len = strlen(test);
char **matches = dlg_malloc(char *, (size_t) (d_list->length + f_list->length));
size_t data_len = 0;
- int i;
- for (i = 2; i < d_list->length; i++) {
- if (strncmp(test, d_list->data[i], test_len) == 0) {
- matches[data_len++] = d_list->data[i];
+
+ if (matches != 0) {
+ int i;
+ char **new_ptr;
+
+ for (i = 2; i < d_list->length; i++) {
+ if (strncmp(test, d_list->data[i], test_len) == 0) {
+ matches[data_len++] = d_list->data[i];
+ }
}
- }
- for (i = 0; i < f_list->length; i++) {
- if (strncmp(test, f_list->data[i], test_len) == 0) {
- matches[data_len++] = f_list->data[i];
+ for (i = 0; i < f_list->length; i++) {
+ if (strncmp(test, f_list->data[i], test_len) == 0) {
+ matches[data_len++] = f_list->data[i];
+ }
+ }
+ if ((new_ptr = dlg_realloc(char *, data_len + 1, matches)) != 0) {
+ matches = new_ptr;
+ } else {
+ free(matches);
+ matches = 0;
+ data_len = 0;
}
}
- matches = dlg_realloc(char *, data_len + 1, matches);
match_list->data = matches;
match_list->length = (int) data_len;
}
@@ -386,11 +404,11 @@ complete(char *name, LIST * d_list, LIST * f_list, char **buff_ptr)
char *test;
size_t test_len;
size_t i;
- int j;
char *buff;
match(name, d_list, f_list, &match_list);
if (match_list.length == 0) {
+ free(match_list.data);
*buff_ptr = NULL;
return 0;
}
@@ -406,6 +424,8 @@ complete(char *name, LIST * d_list, LIST * f_list, char **buff_ptr)
i++;
}
} else {
+ int j;
+
for (i = 0; i < test_len; i++) {
char test_char = test[i];
if (test_char == '\0')
@@ -433,12 +453,9 @@ fill_lists(char *current, char *input, LIST * d_list, LIST * f_list, bool keep)
{
bool result = TRUE;
bool rescan = FALSE;
- DIR *dp;
- DIRENT *de;
struct stat sb;
int n;
char path[MAX_LEN + 1];
- char *leaf;
/* check if we've updated the lists */
for (n = 0; current[n] && input[n]; n++) {
@@ -457,7 +474,9 @@ fill_lists(char *current, char *input, LIST * d_list, LIST * f_list, bool keep)
}
if (rescan) {
+ DIR *dp;
size_t have = strlen(input);
+ char *leaf;
if (have > MAX_LEN)
have = MAX_LEN;
@@ -477,6 +496,8 @@ fill_lists(char *current, char *input, LIST * d_list, LIST * f_list, bool keep)
}
DLG_TRACE(("opendir '%s'\n", path));
if ((dp = opendir(path)) != 0) {
+ DIRENT *de;
+
while ((de = readdir(dp)) != 0) {
size_t len = NAMLEN(de);
if (len == 0 || (len + have + 2) >= MAX_LEN)
@@ -624,10 +645,8 @@ dlg_fselect(const char *title, const char *path, int height, int width, int dsel
#ifdef KEY_RESIZE
retry:
#endif
- dlg_auto_size(title, (char *) 0, &height, &width, 6, 25);
- height += MIN_HIGH + min_items;
- if (width < min_wide)
- width = min_wide;
+ dlg_auto_size(title, "", &height, &width, MIN_HIGH + min_items, min_wide);
+
dlg_print_size(height, width);
dlg_ctl_size(height, width);
@@ -651,13 +670,12 @@ dlg_fselect(const char *title, const char *path, int height, int width, int dsel
tbox_y = height - (BTN_HIGH * 2) + MARGIN;
tbox_x = (width - tbox_width) / 2;
- w_text = derwin(dialog, tbox_height, tbox_width, tbox_y, tbox_x);
+ w_text = dlg_der_window(dialog, tbox_height, tbox_width, tbox_y, tbox_x);
if (w_text == 0) {
result = DLG_EXIT_ERROR;
goto finish;
}
- (void) keypad(w_text, TRUE);
dlg_draw_box(dialog, tbox_y - MARGIN, tbox_x - MARGIN,
(2 * MARGIN + 1), tbox_width + (MARGIN + EXT_WIDE),
menubox_border_attr, menubox_border2_attr);
@@ -678,13 +696,12 @@ dlg_fselect(const char *title, const char *path, int height, int width, int dsel
dbox_y = (2 * MARGIN + 1);
dbox_x = tbox_x;
- w_work = derwin(dialog, dbox_height, dbox_width, dbox_y, dbox_x);
+ w_work = dlg_der_window(dialog, dbox_height, dbox_width, dbox_y, dbox_x);
if (w_work == 0) {
result = DLG_EXIT_ERROR;
goto finish;
}
- (void) keypad(w_work, TRUE);
(void) mvwaddstr(dialog, dbox_y - (MARGIN + 1), dbox_x - MARGIN, d_label);
dlg_draw_box(dialog,
dbox_y - MARGIN, dbox_x - MARGIN,
@@ -699,13 +716,12 @@ dlg_fselect(const char *title, const char *path, int height, int width, int dsel
fbox_y = dbox_y;
fbox_x = tbox_x + dbox_width + (2 * MARGIN);
- w_work = derwin(dialog, fbox_height, fbox_width, fbox_y, fbox_x);
+ w_work = dlg_der_window(dialog, fbox_height, fbox_width, fbox_y, fbox_x);
if (w_work == 0) {
result = DLG_EXIT_ERROR;
goto finish;
}
- (void) keypad(w_work, TRUE);
(void) mvwaddstr(dialog, fbox_y - (MARGIN + 1), fbox_x - MARGIN, f_label);
dlg_draw_box(dialog,
fbox_y - MARGIN, fbox_x - MARGIN,
@@ -763,8 +779,10 @@ dlg_fselect(const char *title, const char *path, int height, int width, int dsel
fix_arrows(&d_list);
fix_arrows(&f_list);
key = dlg_mouse_wgetch((state == sTEXT) ? w_text : dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
}
if (key == DLGK_TOGGLE) {
@@ -851,6 +869,10 @@ dlg_fselect(const char *title, const char *path, int height, int width, int dsel
case DLGK_ENTER:
result = (state > 0) ? dlg_enter_buttoncode(state) : DLG_EXIT_OK;
continue;
+ case DLGK_LEAVE:
+ if (state >= 0)
+ result = dlg_ok_buttoncode(state);
+ break;
#ifdef KEY_RESIZE
case KEY_RESIZE:
dlg_will_resize(dialog);
@@ -861,10 +883,9 @@ dlg_fselect(const char *title, const char *path, int height, int width, int dsel
*current = 0;
resized = TRUE;
/* repaint */
- dlg_clear();
- dlg_del_window(dialog);
- refresh();
- dlg_mouse_free_regions();
+ free_list(&d_list, FALSE);
+ free_list(&f_list, FALSE);
+ _dlg_resize_cleanup(dialog);
goto retry;
#endif
default:
@@ -903,12 +924,12 @@ dlg_fselect(const char *title, const char *path, int height, int width, int dsel
first = FALSE;
state = sTEXT;
}
- } else if (state >= 0 &&
- (code = dlg_char_to_button(key, buttons)) >= 0) {
+ } else if ((code = dlg_char_to_button(key, buttons)) >= 0) {
result = dlg_ok_buttoncode(code);
break;
}
}
+ AddLastKey();
dlg_unregister_window(w_text);
dlg_del_window(dialog);
diff --git a/guage.c b/guage.c
index 95664b06b956..5895330c6d56 100644
--- a/guage.c
+++ b/guage.c
@@ -1,9 +1,9 @@
/*
- * $Id: guage.c,v 1.76 2018/06/21 08:23:43 tom Exp $
+ * $Id: guage.c,v 1.83 2020/03/27 20:54:43 tom Exp $
*
* guage.c -- implements the gauge dialog
*
- * Copyright 2000-2015,2018 Thomas E. Dickey
+ * Copyright 2000-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -119,9 +119,10 @@ static void
repaint_text(MY_OBJ * obj)
{
WINDOW *dialog = obj->obj.win;
- int i, x;
if (dialog != 0) {
+ int i, x;
+
(void) werase(dialog);
dlg_draw_box2(dialog, 0, 0, obj->height, obj->width, dialog_attr,
border_attr, border2_attr);
@@ -301,7 +302,7 @@ dlg_reallocate_gauge(void *objptr,
int percent)
{
char *prompt = dlg_strclone(cprompt);
- MY_OBJ *obj = objptr;
+ MY_OBJ *obj;
bool save_finish_string = dialog_state.finish_string;
dialog_state.finish_string = TRUE;
@@ -377,6 +378,10 @@ dlg_free_gauge(void *objptr)
MY_OBJ *obj = (MY_OBJ *) objptr;
if (valid(obj)) {
+ if (obj->title)
+ free(obj->title);
+ if (obj->prompt)
+ free(obj->prompt);
obj->obj.keep_win = FALSE;
dlg_remove_callback(&(obj->obj));
delink(obj);
@@ -422,7 +427,6 @@ dialog_gauge(const char *title,
MY_OBJ *oldobj = obj;
dlg_will_resize(obj->obj.win);
- dlg_mouse_free_regions();
obj = dlg_allocate_gauge(title,
cprompt,
@@ -436,9 +440,8 @@ dialog_gauge(const char *title,
oldobj->obj.keep_win = FALSE;
/* remove the old version of the gauge */
- dlg_clear();
+ _dlg_resize_cleanup(oldobj->obj.win);
dlg_remove_callback(&(oldobj->obj));
- refresh();
dlg_add_callback_ref((DIALOG_CALLBACK **) & obj, my_cleanup);
dlg_update_gauge(obj, obj->percent);
diff --git a/inputbox.c b/inputbox.c
index a627e7ad3bde..1199a5c8be7f 100644
--- a/inputbox.c
+++ b/inputbox.c
@@ -1,9 +1,9 @@
/*
- * $Id: inputbox.c,v 1.84 2018/06/21 23:29:35 tom Exp $
+ * $Id: inputbox.c,v 1.93 2021/01/17 16:36:37 tom Exp $
*
* inputbox.c -- implements the input box
*
- * Copyright 2000-2016,2018 Thomas E. Dickey
+ * Copyright 2000-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -24,7 +24,7 @@
* Savio Lam (lam836@cs.cuhk.hk)
*/
-#include <dialog.h>
+#include <dlg_internals.h>
#include <dlg_keys.h>
#define sTEXT -1
@@ -37,6 +37,11 @@
DLG_KEYS_DATA( DLGK_FIELD_PREV, KEY_LEFT ), \
DLG_KEYS_DATA( DLGK_FIELD_PREV, KEY_UP )
+#define BTN_HIGH 1
+#define HDR_HIGH 1
+#define MIN_HIGH (HDR_HIGH + (MARGIN * 2 + 1) + (BTN_HIGH + MARGIN * 2))
+#define MIN_WIDE 26
+
/*
* Display a dialog box for entering a string
*/
@@ -107,13 +112,13 @@ dialog_inputbox(const char *title, const char *cprompt, int height, int width,
key = fkey = 0;
if (init != NULL) {
- dlg_auto_size(title, prompt, &height, &width, 5,
- MIN(MAX(dlg_count_columns(init) + 7, 26),
+ dlg_auto_size(title, prompt, &height, &width, MIN_HIGH,
+ MIN(MAX(dlg_count_columns(init) + 7, MIN_WIDE),
SCOLS - (dialog_vars.begin_set ?
dialog_vars.begin_x : 0)));
chr_offset = (int) strlen(init);
} else {
- dlg_auto_size(title, prompt, &height, &width, 5, 26);
+ dlg_auto_size(title, prompt, &height, &width, MIN_HIGH, MIN_WIDE);
}
dlg_button_layout(buttons, &width);
dlg_print_size(height, width);
@@ -156,9 +161,8 @@ dialog_inputbox(const char *title, const char *cprompt, int height, int width,
wsyncup(editor);
wcursyncup(editor);
}
- while (result == DLG_EXIT_UNKNOWN) {
- int edit = 0;
+ while (result == DLG_EXIT_UNKNOWN) {
/*
* The last field drawn determines where the cursor is shown:
*/
@@ -178,8 +182,10 @@ dialog_inputbox(const char *title, const char *cprompt, int height, int width,
wcursyncup(editor);
}
key = dlg_mouse_wgetch((state == sTEXT) ? editor : dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &code, &key, &fkey))
+ break;
+ }
}
/*
@@ -194,7 +200,7 @@ dialog_inputbox(const char *title, const char *cprompt, int height, int width,
}
if (state == sTEXT) { /* Input box selected */
- edit = dlg_edit_string(input, &chr_offset, key, fkey, first);
+ int edit = dlg_edit_string(input, &chr_offset, key, fkey, first);
if (edit) {
dlg_show_string(editor, input, chr_offset, inputbox_attr,
@@ -236,6 +242,10 @@ dialog_inputbox(const char *title, const char *cprompt, int height, int width,
dlg_del_window(dialog);
result = (state >= 0) ? dlg_enter_buttoncode(state) : DLG_EXIT_OK;
break;
+ case DLGK_LEAVE:
+ if (state >= 0)
+ result = dlg_ok_buttoncode(state);
+ break;
#ifdef KEY_RESIZE
case KEY_RESIZE:
dlg_will_resize(dialog);
@@ -243,20 +253,18 @@ dialog_inputbox(const char *title, const char *cprompt, int height, int width,
height = old_height;
width = old_width;
/* repaint */
- dlg_clear();
- dlg_del_window(dialog);
- refresh();
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
goto retry;
#endif
default:
beep();
break;
}
- } else {
+ } else if (key > 0) {
beep();
}
}
+ AddLastKey();
dlg_unregister_window(editor);
dlg_del_window(dialog);
diff --git a/inputstr.c b/inputstr.c
index 78255fd32fa9..2c7bb7d0f4db 100644
--- a/inputstr.c
+++ b/inputstr.c
@@ -1,9 +1,9 @@
/*
- * $Id: inputstr.c,v 1.88 2018/06/18 22:10:54 tom Exp $
+ * $Id: inputstr.c,v 1.91 2021/01/17 22:19:05 tom Exp $
*
* inputstr.c -- functions for input/display of a string
*
- * Copyright 2000-2017,2018 Thomas E. Dickey
+ * Copyright 2000-2019,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -204,7 +204,6 @@ static CACHE my_cache;
static bool
same_cache2(CACHE * cache, const char *string, unsigned i_len)
{
- unsigned need;
size_t s_len = strlen(string);
bool result = TRUE;
@@ -212,8 +211,8 @@ same_cache2(CACHE * cache, const char *string, unsigned i_len)
|| cache->s_len < s_len
|| cache->list == 0
|| !SAME_CACHE(cache, string, (size_t) s_len)) {
+ unsigned need = (i_len + 1);
- need = (i_len + 1);
if (cache->list == 0) {
cache->list = dlg_malloc(int, need);
} else if (cache->i_len < i_len) {
@@ -322,10 +321,11 @@ dlg_count_wchars(const char *string)
mbstate_t state;
int part = dlg_count_wcbytes(cache->string, len);
char save = cache->string[part];
- size_t code;
wchar_t *temp = dlg_calloc(wchar_t, len + 1);
if (temp != 0) {
+ size_t code;
+
cache->string[part] = '\0';
memset(&state, 0, sizeof(state));
code = mbsrtowcs(temp, &src, (size_t) part, &state);
@@ -353,11 +353,11 @@ const int *
dlg_index_wchars(const char *string)
{
unsigned len = (unsigned) dlg_count_wchars(string);
- unsigned inx;
CACHE *cache = load_cache(cInxWideChars, string);
if (!same_cache2(cache, string, len)) {
const char *current = string;
+ unsigned inx;
cache->list[0] = 0;
for (inx = 1; inx <= len; ++inx) {
@@ -407,25 +407,27 @@ const int *
dlg_index_columns(const char *string)
{
unsigned len = (unsigned) dlg_count_wchars(string);
- unsigned inx;
CACHE *cache = load_cache(cInxCols, string);
if (!same_cache2(cache, string, len)) {
+
cache->list[0] = 0;
#ifdef USE_WIDE_CURSES
if (have_locale()) {
+ unsigned inx;
size_t num_bytes = strlen(string);
const int *inx_wchars = dlg_index_wchars(string);
mbstate_t state;
for (inx = 0; inx < len; ++inx) {
- wchar_t temp[2];
- size_t check;
int result;
if (string[inx_wchars[inx]] == TAB) {
result = ((cache->list[inx] | 7) + 1) - cache->list[inx];
} else {
+ wchar_t temp[2];
+ size_t check;
+
memset(&state, 0, sizeof(state));
memset(temp, 0, sizeof(temp));
check = mbrtowc(temp,
@@ -452,6 +454,8 @@ dlg_index_columns(const char *string)
} else
#endif /* USE_WIDE_CURSES */
{
+ unsigned inx;
+
for (inx = 0; inx < len; ++inx) {
chtype ch = UCH(string[inx]);
diff --git a/makefile.in b/makefile.in
index 34d2619abfdc..f87ff176dfa9 100644
--- a/makefile.in
+++ b/makefile.in
@@ -1,7 +1,7 @@
-# $Id: makefile.in,v 1.97 2018/06/09 01:05:18 tom Exp $
+# $Id: makefile.in,v 1.103 2021/01/11 09:03:36 tom Exp $
# template makefile for DIALOG
##############################################################################
-# Copyright (c) 1999-2017,2018 Thomas E. Dickey #
+# Copyright (c) 1999-2020,2021 Thomas E. Dickey #
# #
# Permission is hereby granted, free of charge, to any person obtaining a #
# copy of this software and associated documentation files (the "Software"), #
@@ -102,6 +102,7 @@ LINT_OPTS = @LINT_OPTS@
CTAGS = @CTAGS@
ETAGS = @ETAGS@
+RPATH_LIST = @RPATH_LIST@
LIBTOOL = @LIBTOOL@ @ECHO_LT@
LIBTOOL_OPTS = @LIBTOOL_OPTS@
LIBTOOL_CLEAN = @LIB_CLEAN@
@@ -141,7 +142,7 @@ PROG = @PACKAGE@$x
@ECHO_CC@$(LIBTOOL_COMPILE) $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CPPFLAGS) -c $<
@NROFF_NOTE@.1.txt :
-@NROFF_NOTE@ GROFF_NO_SGR=stupid $(SHELL) -c "tbl $< | nroff -Tascii -man | col -bx" >$@
+@NROFF_NOTE@ GROFF_NO_SGR=stupid $(SHELL) -c "tbl $< | nroff -rHY=0 -Tascii -man | col -bx" >$@
@MAN2HTML_NOTE@.1.html :
@MAN2HTML_NOTE@ ./@MAN2HTML_TEMP@ $* 1 man >$@
@@ -203,7 +204,7 @@ all :: $(ALL)
dialog$o \
$(OBJECTS) : $(srcdir)/dialog.h $(srcdir)/dlg_keys.h dlg_config.h VERSION
-$(PROG)$x : $(LIB) dialog$o @INTLDIR_MAKE@ @INTLLIBS@
+$(PROG) : $(LIB) dialog$o @INTLDIR_MAKE@ @INTLLIBS@
$(LINK) -o $@ dialog$o -L. -l@PACKAGE@ $(CFLAGS) $(LDFLAGS) $(LIBS)
clean \
@@ -232,6 +233,10 @@ distclean :: clean
$(RM) man2html.*
$(RM) dialog-config
+check :
+ @echo "Verify that create-rc works"
+ $(SHELL) -c "DIALOG=./$(PROG) ./run_test.sh $(srcdir)/samples"
+
install :: install-bin install-man
@echo "made $@"
diff --git a/menubox.c b/menubox.c
index abbe11c23362..c2fda7694cc3 100644
--- a/menubox.c
+++ b/menubox.c
@@ -1,9 +1,9 @@
/*
- * $Id: menubox.c,v 1.159 2018/06/21 23:28:56 tom Exp $
+ * $Id: menubox.c,v 1.171 2020/11/23 21:03:11 tom Exp $
*
* menubox.c -- implements the menu box
*
- * Copyright 2000-2016,2018 Thomas E. Dickey
+ * Copyright 2000-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public Licens, version 2.1e
@@ -24,7 +24,7 @@
* Savio Lam (lam836@cs.cuhk.hk)
*/
-#include <dialog.h>
+#include <dlg_internals.h>
#include <dlg_keys.h>
typedef enum {
@@ -68,7 +68,6 @@ print_item(ALL_DATA * data,
bool is_inputmenu)
{
chtype save = dlg_get_attrs(win);
- int n;
int climit = (data->item_x - data->tag_x - GUTTER);
int my_width = data->menu_width;
int my_x = data->item_x;
@@ -95,6 +94,8 @@ print_item(ALL_DATA * data,
/* Clear 'residue' of last item and mark current current item */
if (is_inputmenu) {
+ int n;
+
dlg_attrset(win, (selected != Unselected) ? item_selected_attr : item_attr);
for (n = my_y - 1; n < my_y + INPUT_ROWS - 1; n++) {
wmove(win, n, 0);
@@ -165,8 +166,18 @@ input_menu_edit(ALL_DATA * data,
/* taken out of inputbox.c - but somewhat modified */
for (;;) {
- if (!first)
+ if (!first) {
+ int check = DLG_EXIT_UNKNOWN;
key = dlg_mouse_wgetch(data->menu, &fkey);
+ if (dlg_result_key(key, fkey, &check)) {
+ if (check == DLG_EXIT_CANCEL) {
+ code = FALSE;
+ break;
+ } else {
+ flash();
+ }
+ }
+ }
if (dlg_edit_string(result, &offset, key, fkey, first)) {
dlg_show_string(data->menu, result, offset, inputbox_attr,
y,
@@ -203,6 +214,7 @@ handle_button(int code, DIALOG_LISTITEM * items, int choice)
dlg_add_string(help_result);
break;
}
+ AddLastKey();
return code;
}
@@ -215,6 +227,7 @@ dlg_renamed_menutext(DIALOG_LISTITEM * items, int current, char *newtext)
dlg_add_string(items[current].name);
dlg_add_result(" ");
dlg_add_string(newtext);
+ AddLastKey();
return DLG_EXIT_EXTRA;
}
@@ -338,13 +351,12 @@ dlg_menu(const char *title,
#endif
ALL_DATA all;
int i, j, x, y, cur_x, cur_y;
- int key = 0, fkey;
+ int fkey;
int button = dialog_state.visit_items ? -1 : dlg_default_button();
int choice = dlg_default_listitem(items);
int result = DLG_EXIT_UNKNOWN;
int scrollamt = 0;
int max_choice;
- int found;
int use_width, name_width, text_width, list_width;
WINDOW *dialog, *menu;
char *prompt = 0;
@@ -360,7 +372,6 @@ dlg_menu(const char *title,
DLG_TRACE2N("lheight", menu_height);
DLG_TRACE2N("llength", item_no);
/* FIXME dump the items[][] too */
- DLG_TRACE2N("current", *current_item);
DLG_TRACE2N("rename", rename_menutext != 0);
dialog_state.plain_buttons = TRUE;
@@ -420,8 +431,7 @@ dlg_menu(const char *title,
* After displaying the prompt, we know how much space we really have.
* Limit the list to avoid overwriting the ok-button.
*/
- if (all.menu_height + MIN_HIGH > height - cur_y)
- all.menu_height = height - MIN_HIGH - cur_y;
+ all.menu_height = height - MIN_HIGH - cur_y;
if (all.menu_height <= 0)
all.menu_height = 1;
@@ -510,15 +520,20 @@ dlg_menu(const char *title,
dlg_draw_buttons(dialog, height - 2, 0, buttons, button, FALSE, width);
dlg_trace_win(dialog);
+
while (result == DLG_EXIT_UNKNOWN) {
+ int key, found;
+
if (button < 0) /* --visit-items */
wmove(dialog,
all.box_y + ItemToRow(choice) + 1,
all.box_x + all.tag_x + 1);
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
found = FALSE;
if (fkey) {
@@ -654,17 +669,19 @@ dlg_menu(const char *title,
dlg_draw_buttons(dialog, height - 2, 0, buttons, button,
FALSE, width);
break;
+
case DLGK_FIELD_NEXT:
button = dlg_next_button(buttons, button);
dlg_draw_buttons(dialog, height - 2, 0, buttons, button,
FALSE, width);
break;
+
case DLGK_TOGGLE:
case DLGK_ENTER:
- if (is_inputmenu)
- result = dlg_ok_buttoncode(button);
- else
- result = dlg_enter_buttoncode(button);
+ case DLGK_LEAVE:
+ result = ((key == DLGK_LEAVE)
+ ? dlg_ok_buttoncode(button)
+ : dlg_enter_buttoncode(button));
/*
* If dlg_menu() is called from dialog_menu(), we want to
@@ -723,16 +740,10 @@ dlg_menu(const char *title,
case KEY_RESIZE:
dlg_will_resize(dialog);
/* reset data */
-#define resizeit(name, NAME) \
- name = ((NAME >= old_##NAME) \
- ? (NAME - (old_##NAME - old_##name)) \
- : old_##name)
resizeit(height, LINES);
resizeit(width, COLS);
free(prompt);
- dlg_clear();
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
/* repaint */
goto retry;
#endif
@@ -749,6 +760,8 @@ dlg_menu(const char *title,
free(prompt);
*current_item = scrollamt + choice;
+
+ DLG_TRACE2N("current", *current_item);
return result;
}
diff --git a/mixedgauge.c b/mixedgauge.c
index 30f0b69a1219..a08659fe2989 100644
--- a/mixedgauge.c
+++ b/mixedgauge.c
@@ -1,9 +1,9 @@
/*
- * $Id: mixedgauge.c,v 1.34 2018/06/18 22:09:31 tom Exp $
+ * $Id: mixedgauge.c,v 1.37 2021/01/16 17:19:15 tom Exp $
*
* mixedgauge.c -- implements the mixedgauge dialog
*
- * Copyright 2007-2012,2018 Thomas E. Dickey
+ * Copyright 2007-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -110,7 +110,6 @@ myprint_status(DIALOG_MIXEDGAUGE * dlg)
int limit_y = dlg->height;
int limit_x = dlg->width;
- int y = MARGIN;
int item;
int cells = dlg->len_text - 2;
int lm = limit_x - dlg->len_text - 1;
@@ -118,21 +117,23 @@ myprint_status(DIALOG_MIXEDGAUGE * dlg)
int last_y = 0, last_x = 0;
int j, xxx;
float percent;
- const char *status = "";
char *freeMe = 0;
bm -= (2 * MARGIN);
getyx(win, last_y, last_x);
for (item = 0; item < dlg->item_no; ++item) {
+ const char *status = "";
chtype attr = A_NORMAL;
+ int y = item + MARGIN + 1;
- y = item + MARGIN + 1;
if (y > bm)
break;
status = status_string(dlg->list[item].text, &freeMe);
- if (status == 0 || *status == 0)
+ if (status == 0 || *status == 0) {
+ free(freeMe);
continue;
+ }
(void) wmove(win, y, 2 * MARGIN);
dlg_attrset(win, dialog_attr);
@@ -266,9 +267,11 @@ dlg_begin_mixedgauge(DIALOG_MIXEDGAUGE * dlg,
int aItemNo,
char **items)
{
- int n, y, x;
+ int y, x;
if (!*began) {
+ int n;
+
curs_set(0);
memset(dlg, 0, sizeof(*dlg));
@@ -367,6 +370,8 @@ dlg_finish_mixedgauge(DIALOG_MIXEDGAUGE * dlg, int status)
#endif
curs_set(1);
dlg_del_window(dlg->dialog);
+ free(dlg->prompt);
+ free(dlg->list);
return status;
}
diff --git a/mousewget.c b/mousewget.c
index 6702a79e6e56..fc85a7106237 100644
--- a/mousewget.c
+++ b/mousewget.c
@@ -1,9 +1,9 @@
/*
- * $Id: mousewget.c,v 1.24 2017/01/31 00:27:21 tom Exp $
+ * $Id: mousewget.c,v 1.25 2019/07/25 00:06:38 tom Exp $
*
- * mousewget.c -- mouse/wgetch support for dialog
+ * mousewget.c -- mouse/wgetch support for dialog
*
- * Copyright 2000-2016,2017 Thomas E. Dickey
+ * Copyright 2000-2017,2019 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -39,9 +39,10 @@ mouse_wgetch(WINDOW *win, int *fkey, bool ignore_errs)
mouse_err = FALSE;
if (key == KEY_MOUSE) {
MEVENT event;
- mseRegion *p;
if (getmouse(&event) != ERR) {
+ mseRegion *p;
+
DLG_TRACE(("# mouse-click abs %d,%d (rel %d,%d)\n",
event.y, event.x,
event.y - getbegy(win),
diff --git a/msgbox.c b/msgbox.c
index d9a2eb1c9065..5264368b67dc 100644
--- a/msgbox.c
+++ b/msgbox.c
@@ -1,9 +1,9 @@
/*
- * $Id: msgbox.c,v 1.81 2018/06/21 23:29:59 tom Exp $
+ * $Id: msgbox.c,v 1.89 2020/11/23 00:32:02 tom Exp $
*
* msgbox.c -- implements the message box and info box
*
- * Copyright 2000-2012,2018 Thomas E. Dickey
+ * Copyright 2000-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -45,15 +45,14 @@ dialog_msgbox(const char *title, const char *cprompt, int height, int width,
};
/* *INDENT-ON* */
- int x, y, last = 0, page;
+ int x, y, page;
int button;
- int key = 0, fkey;
+ int key, fkey;
int result = DLG_EXIT_UNKNOWN;
WINDOW *dialog = 0;
char *prompt;
const char **buttons = dlg_ok_label();
int offset = 0;
- int check;
bool show = TRUE;
int min_width = (pauseopt == 1 ? 12 : 0);
bool save_nocancel = dialog_vars.nocancel;
@@ -91,16 +90,10 @@ dialog_msgbox(const char *title, const char *cprompt, int height, int width,
x = dlg_box_x_ordinate(width);
y = dlg_box_y_ordinate(height);
-#ifdef KEY_RESIZE
- if (dialog != 0)
- dlg_move_window(dialog, height, width, y, x);
- else
-#endif
- {
- dialog = dlg_new_window(height, width, y, x);
- dlg_register_window(dialog, "msgbox", binding);
- dlg_register_buttons(dialog, "msgbox", buttons);
- }
+ dialog = dlg_new_window(height, width, y, x);
+ dlg_register_window(dialog, "msgbox", binding);
+ dlg_register_buttons(dialog, "msgbox", buttons);
+
page = height - (1 + 3 * MARGIN);
dlg_mouse_setbase(x, y);
@@ -111,12 +104,16 @@ dialog_msgbox(const char *title, const char *cprompt, int height, int width,
dlg_attrset(dialog, dialog_attr);
if (pauseopt) {
+ int last = 0;
+
dlg_draw_bottom_box2(dialog, border_attr, border2_attr, dialog_attr);
mouse_mkbutton(height - 2, width / 2 - 4, 6, '\n');
dlg_draw_buttons(dialog, height - 2, 0, buttons, button, FALSE, width);
dlg_draw_helpline(dialog, FALSE);
while (result == DLG_EXIT_UNKNOWN) {
+ int check;
+
if (show) {
last = dlg_print_scrolled(dialog, prompt, offset,
page, width, pauseopt);
@@ -124,9 +121,10 @@ dialog_msgbox(const char *title, const char *cprompt, int height, int width,
show = FALSE;
}
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
-
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
if (!fkey && (check = dlg_char_to_button(key, buttons)) >= 0) {
result = dlg_ok_buttoncode(check);
break;
@@ -137,11 +135,11 @@ dialog_msgbox(const char *title, const char *cprompt, int height, int width,
#ifdef KEY_RESIZE
case KEY_RESIZE:
dlg_will_resize(dialog);
- dlg_clear();
free(prompt);
height = req_high;
width = req_wide;
show = TRUE;
+ _dlg_resize_cleanup(dialog);
goto restart;
#endif
case DLGK_FIELD_NEXT:
@@ -163,6 +161,9 @@ dialog_msgbox(const char *title, const char *cprompt, int height, int width,
FALSE, width);
break;
case DLGK_ENTER:
+ result = dlg_enter_buttoncode(button);
+ break;
+ case DLGK_LEAVE:
result = dlg_ok_buttoncode(button);
break;
default:
@@ -180,7 +181,7 @@ dialog_msgbox(const char *title, const char *cprompt, int height, int width,
}
break;
}
- } else {
+ } else if (key > 0) {
beep();
}
}
@@ -191,6 +192,7 @@ dialog_msgbox(const char *title, const char *cprompt, int height, int width,
dlg_trace_win(dialog);
result = DLG_EXIT_OK;
}
+ dlg_add_last_key(-1);
dlg_del_window(dialog);
dlg_mouse_free_regions();
diff --git a/package/debian/changelog b/package/debian/changelog
index 29bfa1d9c5d8..2bef7f287f2c 100644
--- a/package/debian/changelog
+++ b/package/debian/changelog
@@ -1,3 +1,111 @@
+cdialog (20210117) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Wed, 13 Jan 2021 19:58:21 -0500
+
+cdialog (20210112) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Mon, 11 Jan 2021 03:53:05 -0500
+
+cdialog (20201126) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Sun, 26 Jul 2020 11:17:16 -0400
+
+cdialog (20200327) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Thu, 19 Mar 2020 05:02:12 -0400
+
+cdialog (20200228) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Fri, 28 Feb 2020 20:31:15 -0500
+
+cdialog (20191231) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Tue, 31 Dec 2019 15:37:41 -0500
+
+cdialog (20191210) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Tue, 10 Dec 2019 17:19:19 -0500
+
+cdialog (20191209) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Mon, 09 Dec 2019 04:14:47 -0500
+
+cdialog (20191110) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Sun, 10 Nov 2019 17:48:23 -0500
+
+cdialog (20190926) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Wed, 25 Sep 2019 04:37:53 -0400
+
+cdialog (20190924) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Mon, 23 Sep 2019 05:13:54 -0400
+
+cdialog (20190808) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Thu, 08 Aug 2019 16:54:08 -0400
+
+cdialog (20190806) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Thu, 01 Aug 2019 20:16:04 -0400
+
+cdialog (20190728) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Sun, 28 Jul 2019 18:04:47 -0400
+
+cdialog (20190724) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Mon, 22 Jul 2019 19:20:18 -0400
+
+cdialog (20190211) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Mon, 11 Feb 2019 15:47:42 -0500
+
+cdialog (20181107) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Wed, 07 Nov 2018 20:38:14 -0500
+
+cdialog (20181022) unstable; urgency=low
+
+ * maintenance updates
+
+ -- Thomas E. Dickey <dickey@invisible-island.net> Sun, 28 Oct 2018 10:53:29 -0400
+
cdialog (20180621) unstable; urgency=low
* maintenance updates
diff --git a/package/debian/compat b/package/debian/compat
index 7ed6ff82de6b..f599e28b8ab0 100644
--- a/package/debian/compat
+++ b/package/debian/compat
@@ -1 +1 @@
-5
+10
diff --git a/package/debian/control b/package/debian/control
index c42f663275e4..8df5923fe94c 100644
--- a/package/debian/control
+++ b/package/debian/control
@@ -22,3 +22,12 @@ Description: dialog - display dialog boxes from shell scripts
tailboxbg, textbox, timebox, treeview, and yesno (yes/no).
.
This package installs as "cdialog" to avoid conflict with other packages.
+
+Package: cdialog-dev
+Architecture: any
+Depends: libc6 (>= 2.11), libncursesw5 (>= 5.3)
+Description: dialog - display dialog boxes from shell scripts
+ Dialog is a program that will let you present a variety of questions or
+ display messages using dialog boxes from a shell script. These types
+ This package provides headers and documentation for the library used
+ by "cdialog".
diff --git a/package/debian/copyright b/package/debian/copyright
index 7921d2524622..e9614740c905 100644
--- a/package/debian/copyright
+++ b/package/debian/copyright
@@ -4,7 +4,7 @@ Current dialog upstream maintainer: Thomas Dickey <dickey@invisible-island.net>
-------------------------------------------------------------------------------
Files: *.c *.h
- Copyright 2000-2017,2018 Thomas E. Dickey
+ Copyright 2000-2020,2021 Thomas E. Dickey
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License, version 2.1
@@ -27,7 +27,7 @@ Files: *.c *.h
Files: aclocal.m4
Licence: other-BSD
-Copyright: 1999-2017,2018 by Thomas E. Dickey
+Copyright: 1999-2020,2021 by Thomas E. Dickey
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
@@ -88,7 +88,7 @@ Licence: other-BSD
shared with many OS's install programs.
Files: debian/*
-Copyright: 2010-2012,2013 Thomas E. Dickey
+Copyright: 2010-2020,2021 Thomas E. Dickey
Licence: other-BSD
Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted,
diff --git a/package/debian/rules b/package/debian/rules
index d8ab2cd9cb5d..4f03a22819bf 100755
--- a/package/debian/rules
+++ b/package/debian/rules
@@ -1,4 +1,5 @@
#!/usr/bin/make -f
+# $Id: rules,v 1.11 2019/07/24 00:53:35 tom Exp $
# Made with the aid of dh_make, by Craig Small
# Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess.
# Some lines taken from debmake, by Cristoph Lameter.
@@ -15,7 +16,16 @@ CPPFLAGS := $(shell dpkg-buildflags --get CPPFLAGS)
CFLAGS := $(shell dpkg-buildflags --get CFLAGS)
LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS)
+TMP = $(CURDIR)/debian/tmp
+
ACTUAL_PROG = cdialog
+DEV_PACKAGE = $(ACTUAL_PROG)-dev
+
+BINDIR = /usr/bin
+LIBDIR = /usr/lib
+LOCALE = /usr/share/locale
+MANDIR = /usr/share/man
+HEADER = /usr/include
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
@@ -77,7 +87,31 @@ install-stamp: build-stamp
dh_clean -k
dh_installdirs
- $(MAKE) install DESTDIR=$(CURDIR)/debian/${ACTUAL_PROG}
+ $(MAKE) install-full DESTDIR=$(TMP)
+
+ dh_install -p${ACTUAL_PROG} $(BINDIR)/$(ACTUAL_PROG)
+ dh_install -p${ACTUAL_PROG} $(LIBDIR)
+ dh_install -p${ACTUAL_PROG} $(LOCALE)
+ dh_install -p${ACTUAL_PROG} $(MANDIR)/man1
+ dh_install -p${DEV_PACKAGE} $(BINDIR)/$(ACTUAL_PROG)-config
+ dh_install -p${DEV_PACKAGE} $(MANDIR)/man3
+ dh_install -p${DEV_PACKAGE} $(HEADER)
+
+ echo FIXME
+ for P in lib${ACTUAL_PROG}.so*; \
+ do \
+ [ -L "$$P" ] || continue; \
+ case "$$P" in \
+ *.so) \
+ echo "DEV: $$P"; \
+ dh_link -p${DEV_PACKAGE} $(LIBDIR)/`readlink $$P` $(LIBDIR)/$$P ; \
+ ;; \
+ *) \
+ echo "BIN: $$P"; \
+ dh_link -p${ACTUAL_PROG} $(LIBDIR)/`readlink $$P` $(LIBDIR)/$$P ; \
+ ;; \
+ esac; \
+ done
touch install-stamp
diff --git a/package/dialog.map b/package/dialog.map
index c8a733230033..cb3aff61c217 100644
--- a/package/dialog.map
+++ b/package/dialog.map
@@ -1,4 +1,4 @@
-# $Id: dialog.map,v 1.7 2018/06/21 00:32:55 tom Exp $
+# $Id: dialog.map,v 1.13 2020/11/26 18:09:52 tom Exp $
# script for shared library symbol-versioning using ld
#
# This file was generated by ncu-mapsyms
@@ -17,6 +17,18 @@
# Configure options (1.3.20180620)
# --disable-leaks --enable-trace
# --disable-leaks --enable-trace --enable-widec
+# Configure options (1.3.20190806)
+# --disable-leaks --enable-trace
+# --disable-leaks --enable-trace --enable-widec
+# Configure options (1.3.20191209)
+# --disable-leaks --enable-trace
+# --disable-leaks --enable-trace --enable-widec
+# Configure options (1.3.20200326)
+# --disable-leaks --enable-trace
+# --disable-leaks --enable-trace --enable-widec
+# Configure options (1.3.20201126)
+# --disable-leaks --enable-trace
+# --disable-leaks --enable-trace --enable-widec
DIALOG_1.0.20040721 {
global:
@@ -220,3 +232,32 @@ DIALOG_1.3.20180620 {
dlg_ttysize;
dlg_will_resize;
} DIALOG_1.3.20160126;
+
+DIALOG_1.3.20190806 {
+ global:
+ dlg_button_key;
+ dlg_exitcode2s;
+ dlg_exitname2n;
+ dlg_ok_button_key;
+} DIALOG_1.3.20180620;
+
+DIALOG_1.3.20191209 {
+ global:
+ dlg_trace_va_msg;
+} DIALOG_1.3.20190806;
+
+DIALOG_1.3.20200326 {
+ global:
+ dlg_reset_timeout;
+ dlg_set_timeout;
+} DIALOG_1.3.20191209;
+
+DIALOG_1.3.20201126 {
+ global:
+ dlg_der_window;
+ dlg_getenv_num;
+ dlg_getenv_str;
+ dlg_keep_tite;
+ local:
+ _*;
+} DIALOG_1.3.20200326;
diff --git a/package/dialog.spec b/package/dialog.spec
index c5f6b77aeb2d..2a000011a880 100644
--- a/package/dialog.spec
+++ b/package/dialog.spec
@@ -1,9 +1,9 @@
Summary: dialog - display dialog boxes from shell scripts
%define AppProgram dialog
%define AppVersion 1.3
-%define AppRelease 20180621
+%define AppRelease 20210117
%define ActualProg c%{AppProgram}
-# $XTermId: dialog.spec,v 1.108 2018/06/21 09:19:45 tom Exp $
+# $XTermId: dialog.spec,v 1.146 2021/01/16 16:21:23 tom Exp $
Name: %{ActualProg}
Version: %{AppVersion}
Release: %{AppRelease}
@@ -13,6 +13,10 @@ URL: ftp://ftp.invisible-island.net/%{AppProgram}
Source0: %{AppProgram}-%{AppVersion}-%{AppRelease}.tgz
Packager: Thomas Dickey <dickey@invisible-island.net>
+%package devel
+Summary: Development headers/library for the dialog package.
+Requires: %{ActualProg}, ncurses-devel
+
%description
Dialog is a program that will let you present a variety of questions or
display messages using dialog boxes from a shell script. These types
@@ -26,6 +30,10 @@ into dialog):
tailboxbg, textbox, timebox, treeview, and yesno (yes/no).
This package installs as "cdialog" to avoid conflict with other packages.
+
+%description devel
+This is the development package "cdialog", which includes the header files,
+the linkage information and library documentation.
%prep
%define debug_package %{nil}
@@ -38,27 +46,27 @@ cp -v package/dialog.map package/%{ActualProg}.map
INSTALL_PROGRAM='${INSTALL}' \
%configure \
- --target %{_target_platform} \
- --prefix=%{_prefix} \
- --bindir=%{_bindir} \
- --libdir=%{_libdir} \
- --mandir=%{_mandir} \
- --with-package=%{ActualProg} \
- --enable-header-subdir \
- --enable-nls \
- --enable-widec \
- --with-shared \
- --with-ncursesw \
- --with-versioned-syms \
- --disable-rpath-hack
+ --target %{_target_platform} \
+ --prefix=%{_prefix} \
+ --bindir=%{_bindir} \
+ --libdir=%{_libdir} \
+ --mandir=%{_mandir} \
+ --with-package=%{ActualProg} \
+ --enable-header-subdir \
+ --enable-nls \
+ --enable-widec \
+ --with-shared \
+ --with-ncursesw \
+ --with-versioned-syms \
+ --disable-rpath-hack
make
%install
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
-make install DESTDIR=$RPM_BUILD_ROOT
-make install-full DESTDIR=$RPM_BUILD_ROOT
+make install DESTDIR=$RPM_BUILD_ROOT
+make install-full DESTDIR=$RPM_BUILD_ROOT
strip $RPM_BUILD_ROOT%{_bindir}/%{ActualProg}
chmod 755 $RPM_BUILD_ROOT%{_libdir}/lib%{ActualProg}.so.*
@@ -69,19 +77,26 @@ chmod 755 $RPM_BUILD_ROOT%{_libdir}/lib%{ActualProg}.so.*
%files
%defattr(-,root,root)
%{_bindir}/%{ActualProg}
-%{_bindir}/%{ActualProg}-config
%{_mandir}/man1/%{ActualProg}.*
-%{_mandir}/man3/%{ActualProg}.*
+%{_libdir}/lib%{ActualProg}.so.*
+%{_datadir}/locale/*/LC_MESSAGES/%{ActualProg}.mo
+
+%files devel
+%defattr(-,root,root)
+%{_bindir}/%{ActualProg}-config
%{_includedir}/%{ActualProg}.h
%{_includedir}/%{ActualProg}/dlg_colors.h
%{_includedir}/%{ActualProg}/dlg_config.h
%{_includedir}/%{ActualProg}/dlg_keys.h
-%{_libdir}/lib%{ActualProg}.*
-%{_datadir}/locale/*/LC_MESSAGES/%{ActualProg}.mo
+%{_libdir}/lib%{ActualProg}.so
+%{_mandir}/man3/%{ActualProg}.*
%changelog
# each patch should add its ChangeLog entries here
+* Wed Jul 24 2019 Thomas Dickey
+- split-out "-devel" package
+
* Sat Dec 09 2017 Thomas Dickey
- update ftp url
diff --git a/package/dialog.sym b/package/dialog.sym
index d628b35ef5b6..99bc2e1ecacb 100644
--- a/package/dialog.sym
+++ b/package/dialog.sym
@@ -1,4 +1,4 @@
-# $Id: dialog.sym,v 1.7 2018/06/21 00:32:55 tom Exp $
+# $Id: dialog.sym,v 1.12 2020/11/26 18:08:18 tom Exp $
# script for shared library symbol-visibility using libtool
#
# This file was generated by ncu-mapsyms
@@ -17,6 +17,18 @@
# Configure options (1.3.20180620)
# --disable-leaks --enable-trace
# --disable-leaks --enable-trace --enable-widec
+# Configure options (1.3.20190806)
+# --disable-leaks --enable-trace
+# --disable-leaks --enable-trace --enable-widec
+# Configure options (1.3.20191209)
+# --disable-leaks --enable-trace
+# --disable-leaks --enable-trace --enable-widec
+# Configure options (1.3.20200326)
+# --disable-leaks --enable-trace
+# --disable-leaks --enable-trace --enable-widec
+# Configure options (1.3.20201126)
+# --disable-leaks --enable-trace
+# --disable-leaks --enable-trace --enable-widec
dialog_buildlist
dialog_calendar
dialog_checklist
@@ -64,6 +76,7 @@ dlg_box_y_ordinate
dlg_boxchar
dlg_buildlist
dlg_button_count
+dlg_button_key
dlg_button_layout
dlg_button_sizes
dlg_button_to_char
@@ -92,6 +105,7 @@ dlg_default_item
dlg_default_listitem
dlg_defaultno_button
dlg_del_window
+dlg_der_window
dlg_does_output
dlg_draw_arrows
dlg_draw_arrows2
@@ -114,7 +128,9 @@ dlg_editbox
dlg_exit
dlg_exit_buttoncode
dlg_exit_label
+dlg_exitcode2s
dlg_exiterr
+dlg_exitname2n
dlg_find_index
dlg_finish_string
dlg_flush_getc
@@ -125,9 +141,12 @@ dlg_free_gauge
dlg_get_attrs
dlg_getc
dlg_getc_callbacks
+dlg_getenv_num
+dlg_getenv_str
dlg_index_columns
dlg_index_wchars
dlg_item_help
+dlg_keep_tite
dlg_killall_bg
dlg_last_getc
dlg_limit_columns
@@ -150,6 +169,7 @@ dlg_new_modal_window
dlg_new_window
dlg_next_button
dlg_next_ok_buttonindex
+dlg_ok_button_key
dlg_ok_buttoncode
dlg_ok_label
dlg_ok_labels
@@ -172,11 +192,13 @@ dlg_register_buttons
dlg_register_window
dlg_remove_callback
dlg_renamed_menutext
+dlg_reset_timeout
dlg_restore_vars
dlg_result_key
dlg_save_vars
dlg_set_focus
dlg_set_result
+dlg_set_timeout
dlg_show_string
dlg_strclone
dlg_strempty
@@ -188,6 +210,7 @@ dlg_trace_2n
dlg_trace_2s
dlg_trace_chr
dlg_trace_msg
+dlg_trace_va_msg
dlg_trace_win
dlg_treeview
dlg_trim_string
diff --git a/package/freebsd/Makefile b/package/freebsd/Makefile
index b2c063899249..814daa74af0d 100644
--- a/package/freebsd/Makefile
+++ b/package/freebsd/Makefile
@@ -7,7 +7,7 @@
#
PORTNAME= cdialog
-PORTVERSION= 1.3.20180621
+PORTVERSION= 1.3.20210117
PORTEPOCH= 1
CATEGORIES= devel
MASTER_SITES= ftp://ftp.invisible-island.net/${PORTNAME:S|^c||}/
diff --git a/pause.c b/pause.c
index eeff0fe7be72..eafb28f1e140 100644
--- a/pause.c
+++ b/pause.c
@@ -1,9 +1,9 @@
/*
- * $Id: pause.c,v 1.39 2018/06/19 22:57:01 tom Exp $
+ * $Id: pause.c,v 1.48 2020/11/23 00:38:19 tom Exp $
*
* pause.c -- implements the pause dialog
*
- * Copyright 2004-2012,2018 Thomas E. Dickey
+ * Copyright 2004-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -72,7 +72,7 @@ dialog_pause(const char *title,
const char **buttons = dlg_ok_labels();
bool have_buttons = (dlg_button_count(buttons) != 0);
bool first;
- int key = 0, fkey;
+ int key, fkey;
int result = DLG_EXIT_UNKNOWN;
int button_high = (have_buttons ? BTN_HIGH : MARGIN);
int gauge_y;
@@ -88,8 +88,9 @@ dialog_pause(const char *title,
curs_set(0);
- dialog_vars.timeout_secs = 0;
seconds_orig = (seconds > 0) ? seconds : 1;
+ dialog_vars.pause_secs = seconds_orig;
+ dialog_vars.timeout_secs = 0;
#ifdef KEY_RESIZE
retry:
@@ -194,8 +195,8 @@ dialog_pause(const char *title,
key = dlg_mouse_wgetch_nowait(dialog, &fkey);
if (key == ERR) {
; /* ignore errors in nodelay mode */
- } else {
- if (dlg_result_key(key, fkey, &result))
+ } else if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
break;
}
@@ -203,12 +204,10 @@ dialog_pause(const char *title,
#ifdef KEY_RESIZE
case KEY_RESIZE:
dlg_will_resize(dialog);
- dlg_clear(); /* fill the background */
- dlg_del_window(dialog); /* delete this window */
height = old_height;
width = old_width;
free(prompt);
- refresh(); /* get it all onto the terminal */
+ _dlg_resize_cleanup(dialog);
goto retry;
#endif
case DLGK_FIELD_NEXT:
@@ -232,6 +231,9 @@ dialog_pause(const char *title,
case DLGK_ENTER:
result = dlg_enter_buttoncode(button);
break;
+ case DLGK_LEAVE:
+ result = dlg_ok_buttoncode(button);
+ break;
case ERR:
break;
default:
@@ -244,6 +246,7 @@ dialog_pause(const char *title,
}
}
} while ((result == DLG_EXIT_UNKNOWN) && (seconds-- > 0));
+ dlg_add_last_key(-1);
curs_set(1);
dlg_mouse_free_regions();
diff --git a/po/ast.po b/po/ast.po
new file mode 100644
index 000000000000..29f8d3440297
--- /dev/null
+++ b/po/ast.po
@@ -0,0 +1,115 @@
+# Asturian translation for dialog
+# Dialog
+# This file is distributed under the same license as the dialog package.
+# Copyright 2003-2007,2008 # Thomas Dickey
+#
+# enolp <enolp@softastur.org>, 2018.
+msgid ""
+msgstr ""
+"Project-Id-Version: dialog 1.1.20080819\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2008-06-18 18:26-0400\n"
+"PO-Revision-Date: 2018-07-16 01:09+0100\n"
+"Last-Translator: enolp <enolp@softastur.org>\n"
+"Language-Team: Asturian <ubuntu-l10n-ast@lists.ubuntu.com>\n"
+"Language: ast\n"
+"X-Bugs: Report translation errors to the Language-Team address.\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=2; plural=n != 1;\n"
+"X-Generator: Lokalize 2.0\n"
+
+#: buttons.c:385
+msgid "Yes"
+msgstr "Sí"
+
+#: buttons.c:393
+msgid "No"
+msgstr "Non"
+
+#: buttons.c:401
+msgid "OK"
+msgstr "Aceutar"
+
+#: buttons.c:409
+msgid "Cancel"
+msgstr "Encaboxar"
+
+#: buttons.c:417
+msgid "EXIT"
+msgstr "COLAR"
+
+#: buttons.c:425
+msgid "Extra"
+msgstr "Adicional"
+
+#: buttons.c:433
+msgid "Help"
+msgstr "Ayuda"
+
+#. Headline "Month"
+#: calendar.c:273
+msgid "Month"
+msgstr "Mes"
+
+#. Headline "Year"
+#: calendar.c:293
+msgid "Year"
+msgstr "Añu"
+
+#: dialog.c:741
+msgid "Rename"
+msgstr "Renomar"
+
+#: fselect.c:550
+msgid "Directories"
+msgstr "Direutorios"
+
+#: fselect.c:551
+msgid "Files"
+msgstr "Ficheros"
+
+#: mixedgauge.c:58
+msgid "Succeeded"
+msgstr "Tuvo ésitu"
+
+#: mixedgauge.c:61
+msgid "Failed"
+msgstr "Falló"
+
+#: mixedgauge.c:64
+msgid "Passed"
+msgstr "Posóse"
+
+#: mixedgauge.c:67
+msgid "Completed"
+msgstr "Completóse"
+
+#: mixedgauge.c:70
+msgid "Checked"
+msgstr "Conseñóse"
+
+#: mixedgauge.c:73
+msgid "Done"
+msgstr "Fecho"
+
+#: mixedgauge.c:76
+msgid "Skipped"
+msgstr "Saltóse"
+
+#: mixedgauge.c:79
+msgid "In Progress"
+msgstr "En cursu"
+
+#: mixedgauge.c:85
+msgid "N/A"
+msgstr "N/D"
+
+#: mixedgauge.c:193
+msgid "Overall Progress"
+msgstr "Progresu xeneral"
+
+#: textbox.c:489
+msgid "Search"
+msgstr "Guetar"
diff --git a/po/dialog.pot b/po/dialog.pot
index beda1d598bdc..5d981f870062 100644
--- a/po/dialog.pot
+++ b/po/dialog.pot
@@ -1,12 +1,12 @@
# Dialog
-# Copyright 2003-2014,2015 # Thomas Dickey
+# Copyright 2003-2020,2021 # Thomas Dickey
#
#, fuzzy
msgid ""
msgstr ""
-"Project-Id-Version: dialog 1.2.20150510\n"
+"Project-Id-Version: dialog 1.3.20210117\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2015-05-10 21:00-0400\n"
+"POT-Creation-Date: 2021-01-17 15:18-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -15,53 +15,63 @@ msgstr ""
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"
-#: buttons.c:480
+#: buttons.c:500
msgid "Yes"
msgstr ""
-#: buttons.c:488
+#: buttons.c:508
msgid "No"
msgstr ""
-#: buttons.c:496
+#: buttons.c:516
msgid "OK"
msgstr ""
-#: buttons.c:504
+#: buttons.c:524
msgid "Cancel"
msgstr ""
-#: buttons.c:512
+#: buttons.c:532
msgid "EXIT"
msgstr ""
-#: buttons.c:520
+#: buttons.c:540
msgid "Extra"
msgstr ""
-#: buttons.c:528
+#: buttons.c:548
msgid "Help"
msgstr ""
#. Headline "Month"
-#: calendar.c:300
+#: calendar.c:463
msgid "Month"
msgstr ""
#. Headline "Year"
-#: calendar.c:322
+#: calendar.c:485
msgid "Year"
msgstr ""
-#: dialog.c:728
+#: dialog.c:744
+#, c-format
+msgid "Expected %d arguments, found only %d"
+msgstr ""
+
+#: dialog.c:748
+#, c-format
+msgid "Expected %d arguments, found extra %d"
+msgstr ""
+
+#: dialog.c:907
msgid "Rename"
msgstr ""
-#: fselect.c:596
+#: fselect.c:623
msgid "Directories"
msgstr ""
-#: fselect.c:597
+#: fselect.c:624
msgid "Files"
msgstr ""
@@ -101,10 +111,10 @@ msgstr ""
msgid "N/A"
msgstr ""
-#: mixedgauge.c:190
+#: mixedgauge.c:193
msgid "Overall Progress"
msgstr ""
-#: textbox.c:502
+#: textbox.c:515
msgid "Search"
msgstr ""
diff --git a/po/hi.po b/po/hi.po
index 57459fe9cd36..482feb2fc26f 100644
--- a/po/hi.po
+++ b/po/hi.po
@@ -9,6 +9,7 @@ msgstr ""
"PO-Revision-Date: 2007-07-18 11:06+0200\n"
"Last-Translator: Deepika Mangla <deepika.mangla@gmail.com>\n"
"Language-Team: <elinks@knopper.net>\n"
+"Language: hi\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
@@ -19,94 +20,94 @@ msgstr ""
#: buttons.c:385
msgid "Yes"
-msgstr "à€¹à€Ÿà€Â"
+msgstr "हाà¤"
#: buttons.c:393
msgid "No"
-msgstr "à€šà€¹à¥€à€‚"
+msgstr "नहीं"
#: buttons.c:401
msgid "OK"
-msgstr "à€ à¥€à€•"
+msgstr "ठीक"
#: buttons.c:409
msgid "Cancel"
-msgstr "à€°à€Šà¥Âà€Š à€•à€°à¥‡à€‚"
+msgstr "रदà¥à¤¦ करें"
#: buttons.c:417
msgid "EXIT"
-msgstr "à€šà€¿à€°à¥Âà€—à€®"
+msgstr "निरà¥à¤—म"
#: buttons.c:425
msgid "Extra"
-msgstr "à€…à€€à€¿à€°à€¿à€•à¥Âà€€"
+msgstr "अतिरिकà¥à¤¤"
#: buttons.c:433
msgid "Help"
-msgstr "à€®à€Šà€Š"
+msgstr "मदद"
#. Headline "Month"
#: calendar.c:273
msgid "Month"
-msgstr "à€®à€¹à¥€à€šà€Ÿ"
+msgstr "महीना"
#. Headline "Year"
#: calendar.c:293
msgid "Year"
-msgstr "à€µà€°à¥Âà€·"
+msgstr "वरà¥à¤·"
#: dialog.c:741
msgid "Rename"
-msgstr "à€ªà¥Âà€šà€ƒà€šà€Ÿà€®à€•à€°à€£"
+msgstr "पà¥à¤¨à¤ƒà¤¨à¤¾à¤®à¤•à¤°à¤£"
#: fselect.c:550
msgid "Directories"
-msgstr "à€šà€¿à€°à¥Âà€Šà¥‡à€¶à€¿à€•à€Ÿ"
+msgstr "निरà¥à¤¦à¥‡à¤¶à¤¿à¤•à¤¾"
#: fselect.c:551
msgid "Files"
-msgstr "à€žà€‚à€šà€¿à€•à€Ÿ"
+msgstr "संचिका"
#: mixedgauge.c:58
msgid "Succeeded"
-msgstr "à€žà€«à€²"
+msgstr "सफल"
#: mixedgauge.c:61
msgid "Failed"
-msgstr "à€žà€«à€²"
+msgstr "सफल"
#: mixedgauge.c:64
msgid "Passed"
-msgstr "à€ªà€Ÿà€ž"
+msgstr "पास"
#: mixedgauge.c:67
msgid "Completed"
-msgstr "à€žà€®à¥Âà€ªà¥‚à€°à€¿à€€"
+msgstr "समà¥à¤ªà¥‚रित"
#: mixedgauge.c:70
msgid "Checked"
-msgstr "à€…à€µà€°à¥Âà€Šà¥Âà€§"
+msgstr "अवरà¥à¤¦à¥à¤§"
#: mixedgauge.c:73
msgid "Done"
-msgstr "à€žà€«à€² "
+msgstr "सफल "
#: mixedgauge.c:76
msgid "Skipped"
-msgstr "à€›à¥‹à€¡à€Œ à€Šà€¿à€¯à€Ÿ"
+msgstr "छोड़ दिया"
#: mixedgauge.c:79
msgid "In Progress"
-msgstr "à€ªà¥Âà€°à€—à€€à€¿ à€®à¥‡à€‚ à€¹à¥ˆ"
+msgstr "पà¥à¤°à¤—ति में है"
#: mixedgauge.c:85
msgid "N/A"
-msgstr "à€²à€Ÿà€—à¥‚ à€šà€¹à¥€à€‚"
+msgstr "लागू नहीं"
#: mixedgauge.c:193
msgid "Overall Progress"
-msgstr "à€žà€®à€—à¥Âà€° à€ªà¥Âà€°à€—à€€à€¿"
+msgstr "समगà¥à¤° पà¥à¤°à¤—ति"
#: textbox.c:489
msgid "Search"
-msgstr "à€…à€šà¥Âà€žà€šà¥Âà€§à€Ÿà€š"
+msgstr "अनà¥à¤¸à¤¨à¥à¤§à¤¾à¤¨"
diff --git a/po/ja.po b/po/ja.po
index 366ca2825d2a..a69174addaec 100644
--- a/po/ja.po
+++ b/po/ja.po
@@ -14,99 +14,99 @@ msgstr ""
"Language-Team: Japanese <translation-team-ja@lists.sourceforge.net>\n"
"Language: ja\n"
"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=EUC-JP\n"
+"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: buttons.c:387
msgid "Yes"
-msgstr "¤Ï¤¤"
+msgstr "ã¯ã„"
#: buttons.c:395
msgid "No"
-msgstr "¤¤¤¤¤¨"
+msgstr "ã„ã„ãˆ"
#: buttons.c:403
msgid "OK"
-msgstr "λ²ò"
+msgstr "了解"
#: buttons.c:411
msgid "Cancel"
-msgstr "¼è¾Ã"
+msgstr "å–消"
#: buttons.c:419
msgid "EXIT"
-msgstr "½ªÎ»"
+msgstr "終了"
#: buttons.c:427
msgid "Extra"
-msgstr "³ÈÄ¥"
+msgstr "æ‹¡å¼µ"
#: buttons.c:435
msgid "Help"
-msgstr "¥Ø¥ë¥×"
+msgstr "ヘルプ"
#. Headline "Month"
#: calendar.c:298
msgid "Month"
-msgstr "·î"
+msgstr "月"
#. Headline "Year"
#: calendar.c:318
msgid "Year"
-msgstr "ǯ"
+msgstr "å¹´"
#: dialog.c:756
msgid "Rename"
-msgstr "̾Á°Êѹ¹"
+msgstr "åå‰å¤‰æ›´"
#: fselect.c:571
msgid "Directories"
-msgstr "¥Ç¥£¥ì¥¯¥È¥ê"
+msgstr "ディレクトリ"
#: fselect.c:572
msgid "Files"
-msgstr "¥Õ¥¡¥¤¥ë"
+msgstr "ファイル"
#: mixedgauge.c:58
msgid "Succeeded"
-msgstr "À®¸ù"
+msgstr "æˆåŠŸ"
#: mixedgauge.c:61
msgid "Failed"
-msgstr "¼ºÇÔ"
+msgstr "失敗"
#: mixedgauge.c:64
msgid "Passed"
-msgstr "¥Ñ¥¹"
+msgstr "パス"
#: mixedgauge.c:67
msgid "Completed"
-msgstr "´°Î»"
+msgstr "完了"
#: mixedgauge.c:70
msgid "Checked"
-msgstr "³Îǧ½ªÎ»"
+msgstr "確èªçµ‚了"
#: mixedgauge.c:73
msgid "Done"
-msgstr "½ªÎ»"
+msgstr "終了"
#: mixedgauge.c:76
msgid "Skipped"
-msgstr "¥¹¥­¥Ã¥×"
+msgstr "スキップ"
#: mixedgauge.c:79
msgid "In Progress"
-msgstr "½èÍýÃæ"
+msgstr "処ç†ä¸­"
#: mixedgauge.c:85
msgid "N/A"
-msgstr "̵¸ú"
+msgstr "無効"
#: mixedgauge.c:193
msgid "Overall Progress"
-msgstr "Á´ÂΤοʹԾõ¶·"
+msgstr "全体ã®é€²è¡ŒçŠ¶æ³"
#: textbox.c:468
msgid "Search"
-msgstr "Ä´ºº"
+msgstr "調査"
diff --git a/po/pt.po b/po/pt.po
index 4a06e012edad..8e599c0ff0cc 100644
--- a/po/pt.po
+++ b/po/pt.po
@@ -1,18 +1,23 @@
-# Portuguese translation of Dialog.
-# Copyright (C) 2001 Thomas Dickey.
-# Frédéric L. W. Meunier <0 @ pervalidus.net>, 2001.
+# Portuguese (Portugal) Translation for the dialog Package
+# This file is distributed under the same license as the dialog package.
+# Copyright 2003-2007,2008 Thomas Dickey
+# This file is distributed under the same license as the dialog package.
+# Pedro Albuquerque <palbuquerque73@gmail.com>, 2019.
#
msgid ""
msgstr ""
-"Project-Id-Version: Dialog 0.9a-20020814\n"
+"Project-Id-Version: dialog 1.1.20080819\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2008-06-18 18:26-0400\n"
-"PO-Revision-Date: 2002-09-04 19:12-0300\n"
-"Last-Translator: Frédéric L. W. Meunier <0 @ pervalidus.net>\n"
-"Language-Team: Portuguese <pt @ li.org>\n"
+"PO-Revision-Date: 2019-09-25 07:33+0100\n"
+"Last-Translator: Pedro Albuquerque <palbuquerque73@gmail.com>\n"
+"Language-Team: Portuguese <translation-team-pt@lists.sourceforge.net>\n"
+"Language: pt\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8-bit\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Bugs: Report translation errors to the Language-Team address.\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#: buttons.c:385
msgid "Yes"
@@ -32,11 +37,11 @@ msgstr "Cancelar"
#: buttons.c:417
msgid "EXIT"
-msgstr "Sair"
+msgstr "SAIR"
#: buttons.c:425
msgid "Extra"
-msgstr ""
+msgstr "Extra"
#: buttons.c:433
msgid "Help"
@@ -54,11 +59,11 @@ msgstr "Ano"
#: dialog.c:741
msgid "Rename"
-msgstr ""
+msgstr "Renomear"
#: fselect.c:550
msgid "Directories"
-msgstr "Directorias"
+msgstr "Pastas"
#: fselect.c:551
msgid "Files"
@@ -66,46 +71,44 @@ msgstr "Ficheiros"
#: mixedgauge.c:58
msgid "Succeeded"
-msgstr ""
+msgstr "Sucesso"
#: mixedgauge.c:61
-#, fuzzy
msgid "Failed"
-msgstr "Ficheiros"
+msgstr "Falha"
#: mixedgauge.c:64
msgid "Passed"
-msgstr ""
+msgstr "Passou"
#: mixedgauge.c:67
msgid "Completed"
-msgstr ""
+msgstr "Concluído"
#: mixedgauge.c:70
msgid "Checked"
-msgstr ""
+msgstr "Verificado"
#: mixedgauge.c:73
msgid "Done"
-msgstr ""
+msgstr "Feito"
#: mixedgauge.c:76
msgid "Skipped"
-msgstr ""
+msgstr "Ignorado"
#: mixedgauge.c:79
msgid "In Progress"
-msgstr ""
+msgstr "Em Curso"
#: mixedgauge.c:85
msgid "N/A"
-msgstr ""
+msgstr "N/D"
#: mixedgauge.c:193
msgid "Overall Progress"
-msgstr ""
+msgstr "Progresso geral"
#: textbox.c:489
-#, fuzzy
msgid "Search"
-msgstr "Busca"
+msgstr "Procurar"
diff --git a/po/ro.po b/po/ro.po
index b53898b4fef9..ba2250dc53df 100644
--- a/po/ro.po
+++ b/po/ro.po
@@ -14,7 +14,6 @@ msgstr ""
"Last-Translator: Mihai Cristescu <mihai.cristescu@archlinux.info>\n"
"Language-Team: Romanian <translation-team-ro@lists.sourceforge.net>\n"
"Language: ro\n"
-"X-Bugs: Report translation errors to the Language-Team address.\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
diff --git a/po/sq.po b/po/sq.po
index 592d4a11ffa4..1d5022131ec9 100644
--- a/po/sq.po
+++ b/po/sq.po
@@ -1,111 +1,113 @@
-# Albanian translation of Dialog.
+# Translation of dialog to Albanian
# This file is distributed under the same license as the dialog package.
-# Copyright (C) 2005 Thomas Dickey.
-# Elian Myftiu <elian@lycos.com>, 2004.
-#
+# Copyright 2003-2007,2008 # Thomas Dickey
+# Besnik Bleta <besnik@programeshqip.org>, 2004,2008,2015, 2019, 2020.
msgid ""
msgstr ""
-"Project-Id-Version: Dialog 1.0-20050116\n"
+"Project-Id-Version: dialog-1.1.20080819\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2011-01-16 17:57-0500\n"
-"PO-Revision-Date: 2004-11-18 02:28+0100\n"
-"Last-Translator: Elian Myftiu <elian@lycos.com>\n"
-"Language-Team: Albanian <gnome-albanian-perkthyesit@lists.sourceforge.net>\n"
+"POT-Creation-Date: 2008-06-18 18:26-0400\n"
+"PO-Revision-Date: 2020-04-01 15:04+0300\n"
+"Last-Translator: Besnik Bleta <besnik@programeshqip.org>\n"
+"Language-Team: Albanian <translation-team-sq@lists.sourceforge.net>\n"
"Language: sq\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
+"X-Bugs: Report translation errors to the Language-Team address.\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+"X-Generator: Poedit 2.2\n"
-#: buttons.c:387
+#: buttons.c:385
msgid "Yes"
msgstr "Po"
-#: buttons.c:395
+#: buttons.c:393
msgid "No"
msgstr "Jo"
-#: buttons.c:403
+#: buttons.c:401
msgid "OK"
-msgstr "mirë"
+msgstr "OK"
-#: buttons.c:411
+#: buttons.c:409
msgid "Cancel"
-msgstr "Anullo"
+msgstr "Anuloje"
-#: buttons.c:419
+#: buttons.c:417
msgid "EXIT"
-msgstr "Dal"
+msgstr "DALJE"
-#: buttons.c:427
+#: buttons.c:425
msgid "Extra"
-msgstr ""
+msgstr "Ekstra"
-#: buttons.c:435
+#: buttons.c:433
msgid "Help"
-msgstr ""
+msgstr "Ndihmë"
#. Headline "Month"
-#: calendar.c:298
+#: calendar.c:273
msgid "Month"
-msgstr ""
+msgstr "Muaj"
#. Headline "Year"
-#: calendar.c:318
+#: calendar.c:293
msgid "Year"
-msgstr ""
+msgstr "Vit"
-#: dialog.c:756
+#: dialog.c:741
msgid "Rename"
-msgstr ""
+msgstr "Riemërtoje"
-#: fselect.c:571
+#: fselect.c:550
msgid "Directories"
-msgstr ""
+msgstr "Drejtori"
-#: fselect.c:572
+#: fselect.c:551
msgid "Files"
-msgstr ""
+msgstr "Kartela"
#: mixedgauge.c:58
msgid "Succeeded"
-msgstr ""
+msgstr "Doli me sukses"
#: mixedgauge.c:61
msgid "Failed"
-msgstr ""
+msgstr "Dështoi"
#: mixedgauge.c:64
msgid "Passed"
-msgstr ""
+msgstr "Kaloi"
#: mixedgauge.c:67
msgid "Completed"
-msgstr ""
+msgstr "U plotësua"
#: mixedgauge.c:70
msgid "Checked"
-msgstr ""
+msgstr "U kontrollua"
#: mixedgauge.c:73
msgid "Done"
-msgstr ""
+msgstr "U bë"
#: mixedgauge.c:76
msgid "Skipped"
-msgstr ""
+msgstr "U anashkalua"
#: mixedgauge.c:79
msgid "In Progress"
-msgstr ""
+msgstr "Në ecuri e sipër"
#: mixedgauge.c:85
msgid "N/A"
-msgstr ""
+msgstr "N/A"
#: mixedgauge.c:193
msgid "Overall Progress"
-msgstr ""
+msgstr "Ecuri Gjithsej"
-#: textbox.c:468
+#: textbox.c:489
msgid "Search"
-msgstr ""
+msgstr "KÄ“rko"
diff --git a/prgbox.c b/prgbox.c
index d095935a358d..089cb552628d 100644
--- a/prgbox.c
+++ b/prgbox.c
@@ -1,9 +1,9 @@
/*
- * $Id: prgbox.c,v 1.13 2016/01/27 01:37:26 tom Exp $
+ * $Id: prgbox.c,v 1.14 2019/07/25 00:07:15 tom Exp $
*
* prgbox.c -- implements the prg box
*
- * Copyright 2011-2014,2016 Thomas E. Dickey
+ * Copyright 2011-2016,2019 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -37,10 +37,10 @@ dlg_popen(const char *command, const char *type)
{
FILE *result = 0;
int fd[2];
- char *blob;
- char **argv;
- if ((*type == 'r' || *type != 'w') && pipe(fd) == 0) {
+ if ((*type == 'r' || *type == 'w') && pipe(fd) == 0) {
+ char *blob;
+
switch (fork()) {
case -1: /* Error. */
(void) close(fd[0]);
@@ -68,6 +68,7 @@ dlg_popen(const char *command, const char *type)
* tokens.
*/
if ((blob = malloc(10 + strlen(command))) != 0) {
+ char **argv;
sprintf(blob, "sh -c \"%s\"", command);
argv = dlg_string_to_argv(blob);
execvp("sh", argv);
diff --git a/progressbox.c b/progressbox.c
index bbac47e52969..9ad731b09100 100644
--- a/progressbox.c
+++ b/progressbox.c
@@ -1,15 +1,14 @@
/*
- * $Id: progressbox.c,v 1.47 2018/06/21 09:14:47 tom Exp $
+ * $Id: progressbox.c,v 1.54 2020/11/22 15:48:27 tom Exp $
*
* progressbox.c -- implements the progress box
*
- * Copyright 2006-2014,2018 Thomas E. Dickey
+ * Copyright 2006-2019,2020 Thomas E. Dickey
* Copyright 2005 Valery Reznic
*
* This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the
- * License, or (at your option) any later version.
+ * it under the terms of the GNU Lesser General Public License, version 2.1
+ * as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -69,6 +68,7 @@ free_obj(MY_OBJ * obj)
free(obj);
}
+#ifdef KEY_RESIZE
static void
restart_obj(MY_OBJ * obj)
{
@@ -78,12 +78,12 @@ restart_obj(MY_OBJ * obj)
dlg_clear();
dlg_del_window(obj->obj.win);
}
+#endif
static void
start_obj(MY_OBJ * obj, const char *title, const char *cprompt)
{
int y, x, thigh;
- int i;
obj->prompt = dlg_strclone(cprompt);
dlg_tab_correct_str(obj->prompt);
@@ -108,6 +108,7 @@ start_obj(MY_OBJ * obj, const char *title, const char *cprompt)
dlg_draw_helpline(obj->obj.win, FALSE);
if (obj->prompt[0] != '\0') {
+ int i;
int y2, x2;
dlg_attrset(obj->obj.win, dialog_attr);
@@ -145,12 +146,12 @@ get_line(MY_OBJ * obj, int *restart)
{
FILE *fp = obj->obj.input;
int col = 0;
- int j, tmpint, ch;
+ int j, tmpint;
char *result = obj->line;
*restart = 0;
for (;;) {
- ch = getc(fp);
+ int ch = getc(fp);
#ifdef KEY_RESIZE
/* SIGWINCH may have interrupted this - try to ignore if resizable */
if (ferror(fp)) {
@@ -207,7 +208,7 @@ get_line(MY_OBJ * obj, int *restart)
}
nodelay(win, TRUE);
- if ((ch = wgetch(win)) == KEY_RESIZE) {
+ if (wgetch(win) == KEY_RESIZE) {
*restart = 1;
}
nodelay(win, FALSE);
@@ -227,7 +228,9 @@ print_line(MY_OBJ * obj, const char *line, int row)
(void) wmove(obj->text, row, 0); /* move cursor to correct line */
wprintw(obj->text, " %.*s", limit, line);
- wclrtoeol(obj->text);
+ while (++limit < width) {
+ waddch(obj->text, ' ');
+ }
}
#ifdef KEY_RESIZE
@@ -284,13 +287,15 @@ pause_for_ok(MY_OBJ * obj, const char *title, const char *cprompt)
/* *INDENT-ON* */
int button;
- int key = 0, fkey;
+ int key, fkey;
int result = DLG_EXIT_UNKNOWN;
const char **buttons = dlg_ok_label();
- int check;
bool save_nocancel = dialog_vars.nocancel;
bool redraw = TRUE;
+ (void) title;
+ (void) cprompt;
+
dialog_vars.nocancel = TRUE;
button = dlg_default_button();
@@ -304,6 +309,8 @@ pause_for_ok(MY_OBJ * obj, const char *title, const char *cprompt)
dlg_draw_bottom_box2(obj->obj.win, border_attr, border2_attr, dialog_attr);
while (result == DLG_EXIT_UNKNOWN) {
+ int check;
+
if (redraw) {
redraw = FALSE;
if (button < 0)
@@ -315,8 +322,10 @@ pause_for_ok(MY_OBJ * obj, const char *title, const char *cprompt)
}
key = dlg_mouse_wgetch(obj->obj.win, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
if (!fkey && (check = dlg_char_to_button(key, buttons)) >= 0) {
result = dlg_ok_buttoncode(check);
@@ -356,10 +365,12 @@ pause_for_ok(MY_OBJ * obj, const char *title, const char *cprompt)
break;
}
- } else {
+ } else if (key > 0) {
beep();
}
}
+ dlg_add_last_key(-1);
+
dlg_mouse_free_regions();
dlg_unregister_window(obj->obj.win);
diff --git a/rangebox.c b/rangebox.c
index a5fa2520814a..bc99d4a72cd8 100644
--- a/rangebox.c
+++ b/rangebox.c
@@ -1,9 +1,9 @@
/*
- * $Id: rangebox.c,v 1.24 2018/06/19 22:57:01 tom Exp $
+ * $Id: rangebox.c,v 1.32 2020/11/22 23:25:09 tom Exp $
*
* rangebox.c -- implements the rangebox dialog
*
- * Copyright 2012-2017,2018 Thomas E. Dickey
+ * Copyright 2012-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -21,7 +21,7 @@
* Boston, MA 02110, USA.
*/
-#include <dialog.h>
+#include <dlg_internals.h>
#include <dlg_keys.h>
#define ONE_HIGH 1
@@ -29,19 +29,6 @@
#define MIN_HIGH (ONE_HIGH + 1 + (4 * MARGIN))
#define MIN_WIDE (10 + 2 + (2 * MARGIN))
-struct _box;
-
-typedef struct _box {
- WINDOW *parent;
- WINDOW *window;
- int x;
- int y;
- int width;
- int height;
- int period;
- int value;
-} BOX;
-
typedef struct {
/* window in which the value and slider are drawn */
WINDOW *window;
@@ -209,7 +196,7 @@ dialog_rangebox(const char *title,
int old_width = width;
#endif
VALUE data;
- int key = 0, key2, fkey;
+ int key, fkey;
int button;
int result = DLG_EXIT_UNKNOWN;
WINDOW *dialog;
@@ -245,11 +232,8 @@ dialog_rangebox(const char *title,
#endif
prompt = dlg_strclone(cprompt);
- dlg_auto_size(title, prompt, &height, &width, 0, 0);
+ dlg_auto_size(title, prompt, &height, &width, MIN_HIGH, MIN_WIDE);
- height += MIN_HIGH;
- if (width < MIN_WIDE)
- width = MIN_WIDE;
dlg_button_layout(buttons, &width);
dlg_print_size(height, width);
dlg_ctl_size(height, width);
@@ -313,7 +297,10 @@ dialog_rangebox(const char *title,
dlg_print_autowrap(dialog, prompt, height, width);
dlg_trace_win(dialog);
+
while (result == DLG_EXIT_UNKNOWN) {
+ int key2;
+
draw_value(&data, cur_value);
button = (state < 0) ? 0 : state;
dlg_draw_buttons(dialog, height - 2, 0, buttons, button, FALSE, width);
@@ -323,8 +310,10 @@ dialog_rangebox(const char *title,
}
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
if ((key2 = dlg_char_to_button(key, buttons)) >= 0) {
result = key2;
@@ -334,6 +323,9 @@ dialog_rangebox(const char *title,
switch (key) {
case DLGK_TOGGLE:
case DLGK_ENTER:
+ result = dlg_enter_buttoncode(button);
+ break;
+ case DLGK_LEAVE:
result = dlg_ok_buttoncode(button);
break;
case DLGK_FIELD_PREV:
@@ -392,9 +384,7 @@ dialog_rangebox(const char *title,
width = old_width;
/* repaint */
free(prompt);
- dlg_clear();
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
goto retry;
#endif
case DLGK_MOUSE('i'):
@@ -421,8 +411,7 @@ dialog_rangebox(const char *title,
sprintf(buffer, "%d", cur_value);
dlg_add_result(buffer);
- dlg_add_separator();
- dlg_add_last_key(-1);
+ AddLastKey();
dlg_del_window(dialog);
dlg_mouse_free_regions();
diff --git a/rc.c b/rc.c
index fa57f5d256fd..84d7f63495e9 100644
--- a/rc.c
+++ b/rc.c
@@ -1,9 +1,9 @@
/*
- * $Id: rc.c,v 1.53 2018/05/31 20:32:15 tom Exp $
+ * $Id: rc.c,v 1.60 2020/11/25 00:06:40 tom Exp $
*
* rc.c -- routines for processing the configuration file
*
- * Copyright 2000-2012,2018 Thomas E. Dickey
+ * Copyright 2000-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -30,6 +30,19 @@
#ifdef HAVE_COLOR
#include <dlg_colors.h>
+#include <dlg_internals.h>
+
+#define L_PAREN '('
+#define R_PAREN ')'
+
+#define MIN_TOKEN 3
+#ifdef HAVE_RC_FILE2
+#define MAX_TOKEN 5
+#else
+#define MAX_TOKEN MIN_TOKEN
+#endif
+
+#define UNKNOWN_COLOR -2
/*
* For matching color names with color values
@@ -48,7 +61,7 @@ static const color_names_st color_names[] =
{"CYAN", COLOR_CYAN},
{"WHITE", COLOR_WHITE},
}; /* color names */
-#define COLOR_COUNT (sizeof(color_names) / sizeof(color_names[0]))
+#define COLOR_COUNT TableSize(color_names)
#endif /* HAVE_COLOR */
#define GLOBALRC "/etc/dialogrc"
@@ -67,7 +80,7 @@ typedef enum {
} PARSE_LINE;
/* number of configuration variables */
-#define VAR_COUNT (sizeof(vars) / sizeof(vars_st))
+#define VAR_COUNT TableSize(vars)
/* check if character is string quoting characters */
#define isquote(c) ((c) == '"' || (c) == '\'')
@@ -140,6 +153,52 @@ skip_keyword(char *str, int n)
return n;
}
+static void
+trim_token(char **tok)
+{
+ char *tmp = *tok + skip_whitespace(*tok, 0);
+
+ *tok = tmp;
+
+ while (*tmp != '\0' && !isblank(UCH(*tmp)))
+ tmp++;
+
+ *tmp = '\0';
+}
+
+static int
+from_boolean(const char *str)
+{
+ int code = -1;
+
+ if (str != NULL && *str != '\0') {
+ if (!dlg_strcmp(str, "ON")) {
+ code = 1;
+ } else if (!dlg_strcmp(str, "OFF")) {
+ code = 0;
+ }
+ }
+ return code;
+}
+
+static int
+from_color_name(const char *str)
+{
+ int code = UNKNOWN_COLOR;
+
+ if (str != NULL && *str != '\0') {
+ size_t i;
+
+ for (i = 0; i < COLOR_COUNT; ++i) {
+ if (!dlg_strcmp(str, color_names[i].name)) {
+ code = color_names[i].value;
+ break;
+ }
+ }
+ }
+ return code;
+}
+
static int
find_vars(char *name)
{
@@ -172,55 +231,58 @@ find_color(char *name)
return result;
}
-/*
- * Convert an attribute to a string representation like this:
- *
- * "(foreground,background,highlight)"
- */
-static char *
-attr_to_str(char *str, int fg, int bg, int hl)
+static const char *
+to_color_name(int code)
{
- int i;
-
- strcpy(str, "(");
- /* foreground */
- for (i = 0; fg != color_names[i].value; i++) ;
- strcat(str, color_names[i].name);
- strcat(str, ",");
-
- /* background */
- for (i = 0; bg != color_names[i].value; i++) ;
- strcat(str, color_names[i].name);
-
- /* highlight */
- strcat(str, hl ? ",ON)" : ",OFF)");
+ const char *result = "?";
+ size_t n;
+ for (n = 0; n < TableSize(color_names); ++n) {
+ if (code == color_names[n].value) {
+ result = color_names[n].name;
+ break;
+ }
+ }
+ return result;
+}
- return str;
+static const char *
+to_boolean(int code)
+{
+ return code ? "ON" : "OFF";
}
/*
* Extract the foreground, background and highlight values from an attribute
- * represented as a string in one of two forms:
+ * represented as a string in one of these forms:
*
+ * "(foreground,background,highlight,underline,reverse)"
+ * "(foreground,background,highlight,underline)"
* "(foreground,background,highlight)"
- " "xxxx_color"
+ * "xxxx_color"
*/
static int
-str_to_attr(char *str, int *fg, int *bg, int *hl)
+str_to_attr(char *str, DIALOG_COLORS * result)
{
- int i = 0, get_fg = 1;
- unsigned j;
- char tempstr[MAX_LEN + 1], *part;
+ char *tokens[MAX_TOKEN + 1];
+ char tempstr[MAX_LEN + 1];
size_t have;
+ size_t i = 0;
+ size_t tok_count = 0;
- if (str[0] != '(' || lastch(str) != ')') {
- if ((i = find_color(str)) >= 0) {
- *fg = dlg_color_table[i].fg;
- *bg = dlg_color_table[i].bg;
- *hl = dlg_color_table[i].hilite;
+ memset(result, 0, sizeof(*result));
+ result->fg = -1;
+ result->bg = -1;
+ result->hilite = -1;
+
+ if (str[0] != L_PAREN || lastch(str) != R_PAREN) {
+ int ret;
+
+ if ((ret = find_color(str)) >= 0) {
+ *result = dlg_color_table[ret];
return 0;
}
- return -1; /* invalid representation */
+ /* invalid representation */
+ return -1;
}
/* remove the parenthesis */
@@ -233,64 +295,41 @@ str_to_attr(char *str, int *fg, int *bg, int *hl)
memcpy(tempstr, str + 1, have);
tempstr[have] = '\0';
- /* get foreground and background */
+ /* parse comma-separated tokens, allow up to
+ * one more than max tokens to detect extras */
+ while (tok_count < TableSize(tokens)) {
- while (1) {
- /* skip white space before fg/bg string */
- i = skip_whitespace(tempstr, i);
- if (tempstr[i] == '\0')
- return -1; /* invalid representation */
- part = tempstr + i; /* set 'part' to start of fg/bg string */
+ tokens[tok_count++] = &tempstr[i];
- /* find end of fg/bg string */
- while (!isblank(UCH(tempstr[i])) && tempstr[i] != ','
- && tempstr[i] != '\0')
+ while (tempstr[i] != '\0' && tempstr[i] != ',')
i++;
if (tempstr[i] == '\0')
- return -1; /* invalid representation */
- else if (isblank(UCH(tempstr[i]))) { /* not yet ',' */
- tempstr[i++] = '\0';
-
- /* skip white space before ',' */
- i = skip_whitespace(tempstr, i);
- if (tempstr[i] != ',')
- return -1; /* invalid representation */
- }
- tempstr[i++] = '\0'; /* skip the ',' */
- for (j = 0; j < COLOR_COUNT && dlg_strcmp(part, color_names[j].name);
- j++) ;
- if (j == COLOR_COUNT) /* invalid color name */
- return -1;
- if (get_fg) {
- *fg = color_names[j].value;
- get_fg = 0; /* next we have to get the background */
- } else {
- *bg = color_names[j].value;
break;
- }
- } /* got foreground and background */
- /* get highlight */
-
- /* skip white space before highlight string */
- i = skip_whitespace(tempstr, i);
- if (tempstr[i] == '\0')
- return -1; /* invalid representation */
- part = tempstr + i; /* set 'part' to start of highlight string */
+ tempstr[i++] = '\0';
+ }
- /* trim trailing white space from highlight string */
- i = (int) strlen(part) - 1;
- while (isblank(UCH(part[i])) && i > 0)
- i--;
- part[i + 1] = '\0';
+ if (tok_count < MIN_TOKEN || tok_count > MAX_TOKEN) {
+ /* invalid representation */
+ return -1;
+ }
- if (!dlg_strcmp(part, "ON"))
- *hl = TRUE;
- else if (!dlg_strcmp(part, "OFF"))
- *hl = FALSE;
- else
- return -1; /* invalid highlight value */
+ for (i = 0; i < tok_count; ++i)
+ trim_token(&tokens[i]);
+
+ /* validate */
+ if (UNKNOWN_COLOR == (result->fg = from_color_name(tokens[0]))
+ || UNKNOWN_COLOR == (result->bg = from_color_name(tokens[1]))
+ || UNKNOWN_COLOR == (result->hilite = from_boolean(tokens[2]))
+#ifdef HAVE_RC_FILE2
+ || (tok_count >= 4 && (result->ul = from_boolean(tokens[3])) == -1)
+ || (tok_count >= 5 && (result->rv = from_boolean(tokens[4])) == -1)
+#endif /* HAVE_RC_FILE2 */
+ ) {
+ /* invalid representation */
+ return -1;
+ }
return 0;
}
@@ -410,9 +449,14 @@ dlg_create_rc(const char *filename)
# String - \"string\"\n\
# Boolean - <ON|OFF>\n"
#ifdef HAVE_COLOR
+#ifdef HAVE_RC_FILE2
+ "\
+# Attribute - (foreground,background,highlight?,underline?,reverse?)\n"
+#else /* HAVE_RC_FILE2 */
"\
# Attribute - (foreground,background,highlight?)\n"
-#endif
+#endif /* HAVE_RC_FILE2 */
+#endif /* HAVE_COLOR */
);
/* Print an entry for each configuration variable */
@@ -435,7 +479,6 @@ dlg_create_rc(const char *filename)
}
#ifdef HAVE_COLOR
for (i = 0; i < (unsigned) dlg_color_count(); ++i) {
- char buffer[MAX_LEN + 1];
unsigned j;
bool repeat = FALSE;
@@ -453,11 +496,17 @@ dlg_create_rc(const char *filename)
}
if (!repeat) {
- fprintf(rc_file, "%s = %s\n", dlg_color_table[i].name,
- attr_to_str(buffer,
- dlg_color_table[i].fg,
- dlg_color_table[i].bg,
- dlg_color_table[i].hilite));
+ fprintf(rc_file, "%s = %c", dlg_color_table[i].name, L_PAREN);
+ fprintf(rc_file, "%s", to_color_name(dlg_color_table[i].fg));
+ fprintf(rc_file, ",%s", to_color_name(dlg_color_table[i].bg));
+ fprintf(rc_file, ",%s", to_boolean(dlg_color_table[i].hilite));
+#ifdef HAVE_RC_FILE2
+ if (dlg_color_table[i].ul || dlg_color_table[i].rv)
+ fprintf(rc_file, ",%s", to_boolean(dlg_color_table[i].ul));
+ if (dlg_color_table[i].rv)
+ fprintf(rc_file, ",%s", to_boolean(dlg_color_table[i].rv));
+#endif /* HAVE_RC_FILE2 */
+ fprintf(rc_file, "%c\n", R_PAREN);
}
}
#endif /* HAVE_COLOR */
@@ -466,6 +515,13 @@ dlg_create_rc(const char *filename)
(void) fclose(rc_file);
}
+static void
+report_error(const char *filename, int line_no, const char *msg)
+{
+ fprintf(stderr, "%s:%d: %s\n", filename, line_no, msg);
+ dlg_trace_msg("%s:%d: %s\n", filename, line_no, msg);
+}
+
/*
* Parse the configuration file and set up variables
*/
@@ -478,7 +534,7 @@ dlg_parse_rc(void)
char str[MAX_LEN + 1];
char *var;
char *value;
- char *tempptr;
+ char *filename;
int result = 0;
FILE *rc_file = 0;
char *params;
@@ -499,36 +555,35 @@ dlg_parse_rc(void)
*/
/* try step (a) */
- if ((tempptr = getenv("DIALOGRC")) != NULL)
- rc_file = fopen(tempptr, "rt");
+ if ((filename = dlg_getenv_str("DIALOGRC")) != NULL)
+ rc_file = fopen(filename, "rt");
if (rc_file == NULL) { /* step (a) failed? */
/* try step (b) */
- if ((tempptr = getenv("HOME")) != NULL
- && strlen(tempptr) < MAX_LEN - (sizeof(DIALOGRC) + 3)) {
- if (tempptr[0] == '\0' || lastch(tempptr) == '/')
- sprintf(str, "%s%s", tempptr, DIALOGRC);
+ if ((filename = dlg_getenv_str("HOME")) != NULL
+ && strlen(filename) < MAX_LEN - (sizeof(DIALOGRC) + 3)) {
+ if (filename[0] == '\0' || lastch(filename) == '/')
+ sprintf(str, "%s%s", filename, DIALOGRC);
else
- sprintf(str, "%s/%s", tempptr, DIALOGRC);
- rc_file = fopen(tempptr = str, "rt");
+ sprintf(str, "%s/%s", filename, DIALOGRC);
+ rc_file = fopen(filename = str, "rt");
}
}
if (rc_file == NULL) { /* step (b) failed? */
/* try step (c) */
strcpy(str, GLOBALRC);
- if ((rc_file = fopen(tempptr = str, "rt")) == NULL)
+ if ((rc_file = fopen(filename = str, "rt")) == NULL)
return 0; /* step (c) failed, use default values */
}
- DLG_TRACE(("# opened rc file \"%s\"\n", tempptr));
+ DLG_TRACE(("# opened rc file \"%s\"\n", filename));
/* Scan each line and set variables */
while ((result == 0) && (fgets(str, MAX_LEN, rc_file) != NULL)) {
DLG_TRACE(("#\t%s", str));
if (*str == '\0' || lastch(str) != '\n') {
/* ignore rest of file if line too long */
- fprintf(stderr, "\nParse error: line %d of configuration"
- " file too long.\n", l);
+ report_error(filename, l, "line too long");
result = -1; /* parse aborted */
break;
}
@@ -536,7 +591,7 @@ dlg_parse_rc(void)
lastch(str) = '\0';
if (begins_with(str, "bindkey", &params)) {
if (!dlg_parse_bindkey(params)) {
- fprintf(stderr, "\nParse error: line %d of configuration\n", l);
+ report_error(filename, l, "invalid bindkey");
result = -1;
}
continue;
@@ -556,9 +611,7 @@ dlg_parse_rc(void)
case VAL_STR:
if (!isquote(value[0]) || !isquote(lastch(value))
|| strlen(value) < 2) {
- fprintf(stderr, "\nParse error: string value "
- "expected at line %d of configuration "
- "file.\n", l);
+ report_error(filename, l, "expected string value");
result = -1; /* parse aborted */
} else {
/* remove the (") quotes */
@@ -573,38 +626,34 @@ dlg_parse_rc(void)
else if (!dlg_strcmp(value, "OFF"))
*((bool *) vars[i].var) = FALSE;
else {
- fprintf(stderr, "\nParse error: boolean value "
- "expected at line %d of configuration "
- "file (found %s).\n", l, value);
+ report_error(filename, l, "expected boolean value");
result = -1; /* parse aborted */
}
break;
}
#ifdef HAVE_COLOR
} else if ((i = find_color(var)) >= 0) {
- int fg = 0;
- int bg = 0;
- int hl = 0;
- if (str_to_attr(value, &fg, &bg, &hl) == -1) {
- fprintf(stderr, "\nParse error: attribute "
- "value expected at line %d of configuration "
- "file.\n", l);
+ DIALOG_COLORS temp;
+ if (str_to_attr(value, &temp) == -1) {
+ report_error(filename, l, "expected attribute value");
result = -1; /* parse aborted */
} else {
- dlg_color_table[i].fg = fg;
- dlg_color_table[i].bg = bg;
- dlg_color_table[i].hilite = hl;
+ dlg_color_table[i].fg = temp.fg;
+ dlg_color_table[i].bg = temp.bg;
+ dlg_color_table[i].hilite = temp.hilite;
+#ifdef HAVE_RC_FILE2
+ dlg_color_table[i].ul = temp.ul;
+ dlg_color_table[i].rv = temp.rv;
+#endif /* HAVE_RC_FILE2 */
}
} else {
#endif /* HAVE_COLOR */
- fprintf(stderr, "\nParse error: unknown variable "
- "at line %d of configuration file:\n\t%s\n", l, var);
+ report_error(filename, l, "unknown variable");
result = -1; /* parse aborted */
}
break;
case LINE_ERROR:
- fprintf(stderr, "\nParse error: syntax error at line %d of "
- "configuration file.\n", l);
+ report_error(filename, l, "syntax error");
result = -1; /* parse aborted */
break;
}
diff --git a/headers.sh b/run_test.sh
index ec2839afbb2f..036b44dddfe4 100755
--- a/headers.sh
+++ b/run_test.sh
@@ -1,7 +1,7 @@
-#! /bin/sh
-# $Id: headers.sh,v 1.3 2007/02/25 20:37:56 tom Exp $
+#!/bin/sh
+# $Id: run_test.sh,v 1.1 2020/03/20 12:08:00 tom Exp $
##############################################################################
-# Copyright (c) 2004,2007 Thomas E. Dickey #
+# Copyright (c) 2020 Thomas E. Dickey #
# #
# Permission is hereby granted, free of charge, to any person obtaining a #
# copy of this software and associated documentation files (the "Software"), #
@@ -27,77 +27,32 @@
# use or other dealings in this Software without prior written #
# authorization. #
##############################################################################
-#
-# Adjust includes for header files that reside in a subdirectory of
-# /usr/include, etc.
-#
-# Parameters (the first case creates the sed script):
-# $1 is the target directory
-# $2 is the source directory
-# or (the second case does the install, using the sed script):
-# $1 is the script to use for installing
-# $2 is the target directory
-# $3 is the source directory
-# $4 is the file to install, editing source/target/etc.
-PACKAGE=DIALOG
-PKGNAME=DLG
-CONFIGH=dlg_config.h
-
-TMPSED=headers.sed
-
-if test $# = 2 ; then
- rm -f $TMPSED
- DST=$1
- REF=$2
- LEAF=`basename $DST`
- case $DST in
- /*/include/$LEAF)
- END=`basename $DST`
- for i in $REF/*.h
- do
- NAME=`basename $i`
- echo "s/<$NAME>/<$END\/$NAME>/g" >> $TMPSED
- done
- ;;
- *)
- echo "" >> $TMPSED
- ;;
- esac
- for name in `
- egrep '^#define[ ][ ]*[_ABCDEFGHIJKLMNOPQRSTUVWXYZ]' $REF/$CONFIGH \
- | sed -e 's/^#define[ ][ ]*//' \
- -e 's/[ ].*//' \
- | egrep -v "^${PACKAGE}_" \
- | sort -u \
- | egrep -v "^${PKGNAME}_"`
- do
- echo "s/\\<$name\\>/${PKGNAME}_$name/g" >>$TMPSED
- done
-else
- PRG=""
- while test $# != 3
- do
- PRG="$PRG $1"; shift
- done
-
- DST=$1
- REF=$2
- SRC=$3
-
- SHOW=`basename $SRC`
- TMPSRC=${TMPDIR-/tmp}/${SHOW}$$
-
- echo " ... $SHOW"
- test -f $REF/$SRC && SRC="$REF/$SRC"
-
- rm -f $TMPSRC
- sed -f $TMPSED $SRC > $TMPSRC
- NAME=`basename $SRC`
-
- # Just in case someone gzip'd manpages, remove the conflicting copy.
- test -f $DST/$NAME.gz && rm -f $DST/$NAME.gz
-
- eval $PRG $TMPSRC $DST/$NAME
- rm -f $TMPSRC
-fi
+failed() {
+ echo "? $*" >&2
+ exit 1
+}
+
+: ${DIALOG=./dialog}
+CONFIG=samples
+INPUTS=inputs.rc
+OUTPUT=output.rc
+
+[ $# != 0 ] && CONFIG="$1"
+
+[ -f "$DIALOG" ] || failed "no such file: $DIALOG"
+[ -d "$CONFIG" ] || failed "no such directory: $CONFIG"
+
+for rcfile in $CONFIG/*.rc
+do
+ echo "** $rcfile"
+ DIALOGRC="$rcfile" $DIALOG --create-rc $OUTPUT
+ sed -e '/^#/d' "$OUTPUT" >"$INPUTS"
+ mv -f $INPUTS $OUTPUT
+ sed -e '/^#/d' "$rcfile" >"$INPUTS"
+ diff -u $INPUTS $OUTPUT | \
+ sed -e "s,$INPUTS,$rcfile," \
+ -e "s,$OUTPUT,$rcfile-test,"
+done
+
+rm -f $INPUTS $OUTPUT
diff --git a/samples/buildlist b/samples/buildlist
index 72d871f7a149..8e4a70b0c846 100755
--- a/samples/buildlist
+++ b/samples/buildlist
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: buildlist,v 1.2 2012/12/04 11:45:21 tom Exp $
+# $Id: buildlist,v 1.3 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -15,6 +15,6 @@ $DIALOG --title "BUILDLIST DEMO" --backtitle "A user-built list" \
"5" "Item number 5" "off" \
"6" "Item number 6" "on" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/buildlist2 b/samples/buildlist2
index d5cbfb7d25e9..1b4dd335060a 100755
--- a/samples/buildlist2
+++ b/samples/buildlist2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: buildlist2,v 1.6 2012/12/23 22:28:12 tom Exp $
+# $Id: buildlist2,v 1.8 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -23,10 +23,10 @@ do
esac
case "x$DIALOGOPTS" in
*--no-items*|*--noitem*)
- echo $filename $state >>$input
+ echo "$filename $state" >>$input
;;
*)
- echo $count $filename $state >>$input
+ echo "$count $filename $state" >>$input
;;
esac
count=`expr $count + 1`
@@ -34,9 +34,9 @@ done
$DIALOG --title "BUILDLIST DEMO" --backtitle "A user-built list" \
--visit-items --scrollbar --separator "|" \
- --buildlist "hello, this is a --buildlist..." 0 0 10 `cat $input` 2> $output
+ --buildlist "hello, this is a --buildlist..." 0 0 10 `cat "$input"` 2> $output
-retval=$?
+returncode=$?
tempfile=$output
. ./report-tempfile
diff --git a/samples/buildlist4 b/samples/buildlist4
new file mode 100755
index 000000000000..6bfa98708017
--- /dev/null
+++ b/samples/buildlist4
@@ -0,0 +1,22 @@
+#!/bin/sh
+# $Id: buildlist4,v 1.2 2020/11/26 00:03:58 tom Exp $
+
+. ./setup-vars
+
+. ./setup-tempfile
+
+$DIALOG --title "BUILDLIST DEMO" --backtitle "A user-built list" \
+ --separator "|" \
+ --help-button \
+ --item-help \
+ --buildlist "hello, this is a --buildlist..." 0 0 0 \
+ "1" "Item number 1" "on" first \
+ "2" "Item number 2" "off" second \
+ "3" "Item number 3" "on" third \
+ "4" "Item number 4" "on" fourth \
+ "5" "Item number 5" "off" fifth \
+ "6" "Item number 6" "on" sixth 2> $tempfile
+
+returncode=$?
+
+. ./report-tempfile
diff --git a/samples/calendar b/samples/calendar
index e984bcea1867..f9eb602fe0d9 100755
--- a/samples/calendar
+++ b/samples/calendar
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: calendar,v 1.9 2010/01/13 10:20:33 tom Exp $
+# $Id: calendar,v 1.11 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 7 7 1981 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 7 7 1981 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/calendar-stdout b/samples/calendar-stdout
index 5dbbbce9d052..107a8e365161 100755
--- a/samples/calendar-stdout
+++ b/samples/calendar-stdout
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: calendar-stdout,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: calendar-stdout,v 1.8 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
-RESULT=`$DIALOG --stdout --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 7 7 1981`
-retval=$?
+returntext=`$DIALOG --stdout --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 7 7 1981`
+returncode=$?
. ./report-string
diff --git a/samples/calendar2 b/samples/calendar2
index f6214ce662cd..70aba16349df 100755
--- a/samples/calendar2
+++ b/samples/calendar2
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: calendar2,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: calendar2,v 1.10 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/calendar2-stdout b/samples/calendar2-stdout
index af731d9d2265..34b370f7ee0e 100755
--- a/samples/calendar2-stdout
+++ b/samples/calendar2-stdout
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: calendar2-stdout,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: calendar2-stdout,v 1.8 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
-RESULT=`$DIALOG --stdout --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0`
-retval=$?
+returntext=`$DIALOG --stdout --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0`
+returncode=$?
. ./report-string
diff --git a/samples/calendar3 b/samples/calendar3
index aece69ceb4fe..a6efd575eb53 100755
--- a/samples/calendar3
+++ b/samples/calendar3
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: calendar3,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: calendar3,v 1.11 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --extra-button --extra-label "Hold" --help-button --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 7 7 1981 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --extra-button --extra-label "Hold" --help-button --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 7 7 1981 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/calendar3-stdout b/samples/calendar3-stdout
index 4b7ecdbeafb6..7e15920400e4 100755
--- a/samples/calendar3-stdout
+++ b/samples/calendar3-stdout
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: calendar3-stdout,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: calendar3-stdout,v 1.8 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
-RESULT=`$DIALOG --extra-button --extra-label "Hold" --help-button --stdout --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 7 7 1981`
-retval=$?
+returntext=`$DIALOG --extra-button --extra-label "Hold" --help-button --stdout --title "CALENDAR" "$@" --calendar "Please choose a date..." 0 0 7 7 1981`
+returncode=$?
. ./report-string
diff --git a/samples/checklist b/samples/checklist
index be3c8c69304c..2e687d613e16 100755
--- a/samples/checklist
+++ b/samples/checklist
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist,v 1.14 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist,v 1.15 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -23,6 +23,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." On \
"Lemon" "You know how it tastes." on 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist-8bit b/samples/checklist-8bit
index 20b23f13c274..756bf5b6b9c3 100755
--- a/samples/checklist-8bit
+++ b/samples/checklist-8bit
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist-8bit,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist-8bit,v 1.10 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -17,14 +17,14 @@ UP/DOWN arrow keys, the first letter of the choice as a \n\
hot key, or the number keys 1-9 to choose an option. \n\
Press SPACE to toggle an option on/off. \n\n\
Which of the following are fruits?" 20 61 5 \
- "`./rotated-data 0 $SAMPLE`" "It's an `./rotated-data 0 $SAMPLE`." off \
- "`./rotated-data 1 $SAMPLE`" "No, that's not my `./rotated-data 1 $SAMPLE`." ON \
- "`./rotated-data 2 $SAMPLE`" "Yeah, that's `./rotated-data 2 $SAMPLE`." off \
- "`./rotated-data 3 $SAMPLE`" "Normally not a `./rotated-data 3 $SAMPLE`." off \
- "`./rotated-data 4 $SAMPLE`" "No, never put a `./rotated-data 4 $SAMPLE` there!" oN \
- "`./rotated-data 5 $SAMPLE`" "Cats like `./rotated-data 5 $SAMPLE`." On \
- "`./rotated-data 6 $SAMPLE`" "You `./rotated-data 6 $SAMPLE` how it is." on 2> $tempfile
+ "`./rotated-data 0 "$SAMPLE"`" "It's an `./rotated-data 0 "$SAMPLE"`." off \
+ "`./rotated-data 1 "$SAMPLE"`" "No, that's not my `./rotated-data 1 "$SAMPLE"`." ON \
+ "`./rotated-data 2 "$SAMPLE"`" "Yeah, that's `./rotated-data 2 "$SAMPLE"`." off \
+ "`./rotated-data 3 "$SAMPLE"`" "Normally not a `./rotated-data 3 "$SAMPLE"`." off \
+ "`./rotated-data 4 "$SAMPLE"`" "No, never put a `./rotated-data 4 "$SAMPLE"` there!" oN \
+ "`./rotated-data 5 "$SAMPLE"`" "Cats like `./rotated-data 5 "$SAMPLE"`." On \
+ "`./rotated-data 6 "$SAMPLE"`" "You `./rotated-data 6 "$SAMPLE"` how it is." on 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist-utf8 b/samples/checklist-utf8
index 12ed7239502a..b3f24ad2db7a 100755
--- a/samples/checklist-utf8
+++ b/samples/checklist-utf8
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist-utf8,v 1.12 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist-utf8,v 1.13 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -25,6 +25,6 @@ Press SPACE to toggle an option on/off. \n\n\
"FISH" "Cats like FISH." On \
"LEMON" "You KNOW how it TASTES." on 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist1 b/samples/checklist1
index a0e19b6c81d5..3c08feae8dc2 100755
--- a/samples/checklist1
+++ b/samples/checklist1
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist1,v 1.10 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist1,v 1.11 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -23,6 +23,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." On \
"Lemon" "You know how it tastes." on 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist10 b/samples/checklist10
index 2ebd5575a8c5..82fdf77b3efe 100755
--- a/samples/checklist10
+++ b/samples/checklist10
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist10,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist10,v 1.10 2020/11/26 00:03:58 tom Exp $
# zero-width column
. ./setup-vars
@@ -25,6 +25,6 @@ Press SPACE to toggle an option on/off. \n\n\
Noninteractive "" on \
2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist11 b/samples/checklist11
index 85e234991f8c..3e8620e5b418 100755
--- a/samples/checklist11
+++ b/samples/checklist11
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist11,v 1.1 2010/01/17 23:04:01 tom Exp $
+# $Id: checklist11,v 1.2 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -28,6 +28,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." On \
"Lemon" "You know how it tastes." on 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist12 b/samples/checklist12
index e23f88b9072b..68c70ae1b9b3 100755
--- a/samples/checklist12
+++ b/samples/checklist12
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist12,v 1.3 2012/12/23 22:27:51 tom Exp $
+# $Id: checklist12,v 1.5 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -23,7 +23,7 @@ $CUT >$input <<-EOF
Fish:Cats like fish.:On
Lemon:You know how it tastes.:on
EOF
-cat $input | sed -e 's/^/"/' -e 's/:/" "/g' -e 's/$/"/' >$output
+sed -e 's/^/"/' -e 's/:/" "/g' -e 's/$/"/' <$input >$output
cat $output >$input
$DIALOG --backtitle "No Such Organization" \
@@ -38,7 +38,7 @@ Press SPACE to toggle an option on/off. \n\n\
Which of the following are fruits?" 20 61 5 \
--file $input 2> $output
-retval=$?
+returncode=$?
tempfile=$output
. ./report-tempfile
diff --git a/samples/checklist2 b/samples/checklist2
index c672a682e1b5..e0d41d86a1e1 100755
--- a/samples/checklist2
+++ b/samples/checklist2
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist2,v 1.11 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist2,v 1.12 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -23,6 +23,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." On "not a fruit" \
"Lemon" "You know how it tastes." on "the only one you wouldn't eat" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist3 b/samples/checklist3
index ce713d4546be..34471e628cd6 100755
--- a/samples/checklist3
+++ b/samples/checklist3
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist3,v 1.11 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist3,v 1.12 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -23,6 +23,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" On "not a fruit" \
"Lemon" "You know how it tastes. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" on "the only one you wouldn't eat" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist4 b/samples/checklist4
index 53adeedf95ad..eb6eac6d02e6 100755
--- a/samples/checklist4
+++ b/samples/checklist4
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist4,v 1.12 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist4,v 1.13 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -23,6 +23,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" On "not a fruit" \
"Lemon" "You know how it tastes. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" on "the only one you wouldn't eat" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist5 b/samples/checklist5
index 3890c85e09da..a4ccbbc810f7 100755
--- a/samples/checklist5
+++ b/samples/checklist5
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist5,v 1.11 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist5,v 1.12 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -24,6 +24,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" On "not a fruit" \
"Lemon" "You know how it tastes. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" on "the only one you wouldn't eat" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist6 b/samples/checklist6
index 1a05d06e3d84..6e75856eb6c2 100755
--- a/samples/checklist6
+++ b/samples/checklist6
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist6,v 1.11 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist6,v 1.12 2020/11/26 00:03:58 tom Exp $
# example showing the --colors option
. ./setup-vars
@@ -25,6 +25,6 @@ Press \Zb\ZrSPACE\Zn to toggle an option on/off. \n\n\
"Fish" "Cats like \Z4fish\Zn. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" On "not a fruit" \
"Lemon" "You know how it \Zr\Zb\Z3tastes\Zn. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" on "the only one you wouldn't eat" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist7 b/samples/checklist7
index 1080b7eee86b..6ff9f7be4c7c 100755
--- a/samples/checklist7
+++ b/samples/checklist7
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist7,v 1.11 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist7,v 1.12 2020/11/26 00:03:58 tom Exp $
# "checklist6" with --separate-output
. ./setup-vars
@@ -29,6 +29,6 @@ Press \Zb\ZrSPACE\Zn to toggle an option on/off. \n\n\
"Fish" "Cats like \Z4fish\Zn. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" On "not a fruit" \
"Lemon" "You know how it \Zr\Zb\Z3tastes\Zn. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" on "the only one you wouldn't eat" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist8 b/samples/checklist8
index 2ec1bbde6209..d87b35fe42ea 100755
--- a/samples/checklist8
+++ b/samples/checklist8
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist8,v 1.10 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist8,v 1.11 2020/11/26 00:03:58 tom Exp $
# "checklist7" without --item-help
. ./setup-vars
@@ -28,6 +28,6 @@ Press \Zb\ZrSPACE\Zn to toggle an option on/off. \n\n\
"Fish" "Cats like \Z4fish\Zn. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" On \
"Lemon" "You know how it \Zr\Zb\Z3tastes\Zn. xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" on 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/checklist9 b/samples/checklist9
index e8d913fdada6..9e980706d855 100755
--- a/samples/checklist9
+++ b/samples/checklist9
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: checklist9,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: checklist9,v 1.9 2020/11/26 00:03:58 tom Exp $
# "checklist8" using --file
. ./setup-vars
@@ -8,6 +8,6 @@
$DIALOG "$@" --file checklist9.txt 2>$tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/copifuncs/copi.ifmcfg2 b/samples/copifuncs/copi.ifmcfg2
index c8a8c03d664a..4d726f387116 100755
--- a/samples/copifuncs/copi.ifmcfg2
+++ b/samples/copifuncs/copi.ifmcfg2
@@ -17,7 +17,7 @@ packer /usr/bin/zip $F $P
# Maximum arcmail file size, will start new arcmail file if exceeds
maxfsize 65000
-# Maximum packet size, ifmail/ifnews will start new packet if exeeds.
+# Maximum packet size, ifmail/ifnews will start new packet if exceeds.
# .out files are NOT created if nonzero specified, you must run ifpack
# to make packets out. (unimplemented)
maxpsize 65000
@@ -60,7 +60,7 @@ msgidbm /tmp/ifmsgids
# \D untranslated telephone no. (send strings only)
# ModemPort present a blank-separated list of ports with possible speed
-# extention (separated by colon); if speed is prefixed with 'L', it is
+# extension (separated by colon); if speed is prefixed with 'L', it is
# a "locked" port speed, otherwise it is a maximum speed to be set, while
# actual speed is taken from the nodelist. If speed is omitted (or set
# to zero), previous port speed is not changed.
diff --git a/samples/copifuncs/copi.ifmcfg4 b/samples/copifuncs/copi.ifmcfg4
index 4cb7a75b1fca..57ff9fc6ad11 100755
--- a/samples/copifuncs/copi.ifmcfg4
+++ b/samples/copifuncs/copi.ifmcfg4
@@ -7,13 +7,13 @@ ModemError NO\sDIAL
ModemError RING\r
ModemError ERROR
-# Call options (time, address and nodelist flag dependant)
+# Call options (time, address and nodelist flag dependent)
# All matching are applied in the order they are specified.
# Possible options are "[No]Call", "[No]Hold", "[No]PUA", "[No]EMSI",
# "[No]WaZOO", "[No]Freqs", "[No]Zmodem", "[No]ZedZap", "[No]Janus",
# "[No]Hydra". Here, WaZOO stands for YooHoo/2U2 handshake, not for
# the transfer scheme. FTS-0001 handshake and DietIFNA scheme cannot
-# be disallowed (because they are mandatory by standart). "Hold"
+# be disallowed (because they are mandatory by standard). "Hold"
# means really hold "hold" type packets and files: do not send them
# if our system initiated the session, "NoHold" means send "hold"
# packets when our system initiated the session. "NoPUA" stands for
diff --git a/samples/dialog.py b/samples/dialog.py
index 5286b41f1db2..ef6e8626b3c0 100644
--- a/samples/dialog.py
+++ b/samples/dialog.py
@@ -1,5 +1,5 @@
#!/usr/bin/python
-# $Id: dialog.py,v 1.4 2012/06/29 09:33:18 tom Exp $
+# $Id: dialog.py,v 1.5 2019/12/10 22:52:52 tom Exp $
# Module: dialog.py
# Copyright (c) 2000 Robb Shecter <robb@acm.org>
# All rights reserved.
@@ -252,11 +252,11 @@ class Dialog:
def gauge_start(self, perc=0, text='', height=8, width=54, title=''):
"""
Display gauge output window.
- Gauge normal usage (assuming that there is an instace of 'Dialog'
+ Gauge normal usage (assuming that there is an instance of 'Dialog'
class named 'd'):
d.gauge_start()
# do something
- d.gauge_iterate(10) # passed throgh 10%
+ d.gauge_iterate(10) # passed through 10%
# ...
d.gauge_iterate(100, 'any text here') # work is done
d.stop_gauge() # clean-up actions
diff --git a/samples/dselect b/samples/dselect
index 9da035dab95d..24ea94022715 100755
--- a/samples/dselect
+++ b/samples/dselect
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: dselect,v 1.7 2016/01/26 22:52:53 tom Exp $
+# $Id: dselect,v 1.10 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "Please choose a file" "$@" --dselect $HOME/ 14 48 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "Please choose a file" "$@" --dselect "$HOME/" 14 48 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/editbox b/samples/editbox
index 8ae4c63721d9..f59d344c4b3a 100755
--- a/samples/editbox
+++ b/samples/editbox
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: editbox,v 1.13 2010/01/13 10:20:03 tom Exp $
+# $Id: editbox,v 1.14 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -40,6 +40,6 @@ EOF
$DIALOG --title "EDIT BOX" \
--fixed-font "$@" --editbox $input 0 0 2>$output
-retval=$?
+returncode=$?
. ./report-edit
diff --git a/samples/editbox-utf8 b/samples/editbox-utf8
index 94f2fab69d20..aac84714566c 100755
--- a/samples/editbox-utf8
+++ b/samples/editbox-utf8
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: editbox-utf8,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: editbox-utf8,v 1.10 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -30,6 +30,6 @@ EOF
$DIALOG --title "EDIT BOX" \
--fixed-font "$@" --editbox $input 0 0 2>$output
-retval=$?
+returncode=$?
. ./report-edit
diff --git a/samples/editbox2 b/samples/editbox2
index 66623948751b..e483c2d36e85 100755
--- a/samples/editbox2
+++ b/samples/editbox2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: editbox2,v 1.7 2010/01/13 10:20:03 tom Exp $
+# $Id: editbox2,v 1.8 2020/11/26 00:03:58 tom Exp $
# example with extra- and help-buttons
. ./setup-vars
@@ -40,6 +40,6 @@ $DIALOG --title "EDIT BOX" \
--extra-button \
--help-button \
--fixed-font "$@" --editbox $input 0 0 2>$output
-retval=$?
+returncode=$?
. ./report-edit
diff --git a/samples/editbox3 b/samples/editbox3
index aba30bd6f71e..6e96ff5d1885 100755
--- a/samples/editbox3
+++ b/samples/editbox3
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: editbox3,v 1.7 2010/01/13 10:20:03 tom Exp $
+# $Id: editbox3,v 1.8 2020/11/26 00:03:58 tom Exp $
# example with extra- and help-buttons
. ./setup-vars
@@ -13,6 +13,6 @@ $DIALOG --title "EDIT BOX" \
--extra-button \
--help-button \
--fixed-font "$@" --editbox $input 0 0 2>$output
-retval=$?
+returncode=$?
. ./report-edit
diff --git a/samples/editbox4 b/samples/editbox4
index 8153facf1e83..68daf836c64e 100755
--- a/samples/editbox4
+++ b/samples/editbox4
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: editbox4,v 1.1 2010/01/17 22:29:50 tom Exp $
+# $Id: editbox4,v 1.2 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -40,6 +40,6 @@ EOF
$DIALOG --title "EDIT BOX" \
--fixed-font "$@" --editbox $input 20 40 2>$output
-retval=$?
+returncode=$?
. ./report-edit
diff --git a/samples/form1 b/samples/form1
index 38e23649a591..b739196187bc 100755
--- a/samples/form1
+++ b/samples/form1
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form1,v 1.15 2011/10/04 23:36:53 tom Exp $
+# $Id: form1,v 1.18 2020/11/26 00:34:39 tom Exp $
. ./setup-vars
@@ -19,7 +19,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--backtitle "$backtitle" "$@" \
--form "Here is a possible piece of a configuration program." \
20 50 0 \
@@ -31,7 +31,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -63,16 +63,8 @@ $show" 10 40
echo "Button 3 (Extra) pressed."
exit
;;
- $DIALOG_ERROR)
- echo "ERROR!$value"
- exit
- ;;
- $DIALOG_ESC)
- echo "ESC pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form1-both b/samples/form1-both
index f571830fc454..36aa560e36bb 100755
--- a/samples/form1-both
+++ b/samples/form1-both
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form1-both,v 1.5 2010/01/13 10:47:35 tom Exp $
+# $Id: form1-both,v 1.8 2020/11/26 00:34:22 tom Exp $
. ./setup-vars
@@ -16,7 +16,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--extra-button --help-button \
--backtitle "$backtitle" "$@" \
--form "Here is a possible piece of a configuration program." \
@@ -29,7 +29,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -53,16 +53,8 @@ show=`echo "$value" |sed -e 's/^/ /'`
--msgbox "Resulting data:\n\
$show" 10 40
;;
- $DIALOG_HELP)
- echo "Button 2 (Help) pressed."
- exit
- ;;
- $DIALOG_EXTRA)
- echo "Button 3 (Extra) pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form1-extra b/samples/form1-extra
index ca180a96ec1a..46018f808996 100755
--- a/samples/form1-extra
+++ b/samples/form1-extra
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form1-extra,v 1.5 2010/01/13 10:47:35 tom Exp $
+# $Id: form1-extra,v 1.8 2020/11/26 00:34:05 tom Exp $
. ./setup-vars
@@ -16,7 +16,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--extra-button \
--backtitle "$backtitle" "$@" \
--form "Here is a possible piece of a configuration program." \
@@ -29,7 +29,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -53,16 +53,8 @@ show=`echo "$value" |sed -e 's/^/ /'`
--msgbox "Resulting data:\n\
$show" 10 40
;;
- $DIALOG_HELP)
- echo "Button 2 (Help) pressed."
- exit
- ;;
- $DIALOG_EXTRA)
- echo "Button 3 (Extra) pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form1-help b/samples/form1-help
index 44c5543f60e3..9dcd3ca66de6 100755
--- a/samples/form1-help
+++ b/samples/form1-help
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form1-help,v 1.5 2010/01/13 10:47:35 tom Exp $
+# $Id: form1-help,v 1.8 2020/11/26 00:33:42 tom Exp $
. ./setup-vars
@@ -16,7 +16,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--help-button \
--backtitle "$backtitle" "$@" \
--form "Here is a possible piece of a configuration program." \
@@ -29,7 +29,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -53,16 +53,8 @@ show=`echo "$value" |sed -e 's/^/ /'`
--msgbox "Resulting data:\n\
$show" 10 40
;;
- $DIALOG_HELP)
- echo "Button 2 (Help) pressed."
- exit
- ;;
- $DIALOG_EXTRA)
- echo "Button 3 (Extra) pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form1-utf8 b/samples/form1-utf8
index a2be4a6cf15e..21d655d61ae4 100755
--- a/samples/form1-utf8
+++ b/samples/form1-utf8
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form1-utf8,v 1.7 2010/01/13 10:47:35 tom Exp $
+# $Id: form1-utf8,v 1.10 2020/11/26 00:33:23 tom Exp $
. ./setup-vars
@@ -18,7 +18,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--backtitle "$backtitle" \
--insecure "$@" \
--form "Here is a possible piece of a configuration program." \
@@ -31,7 +31,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -55,16 +55,8 @@ show=`echo "$value" |sed -e 's/^/ /'`
--msgbox "Resulting data:\n\
$show" 10 40
;;
- $DIALOG_HELP)
- echo "Button 2 (Help) pressed."
- exit
- ;;
- $DIALOG_EXTRA)
- echo "Button 3 (Extra) pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form2 b/samples/form2
index a005be3c2bf1..ab2fe430501a 100755
--- a/samples/form2
+++ b/samples/form2
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form2,v 1.9 2010/01/13 10:53:11 tom Exp $
+# $Id: form2,v 1.12 2020/11/26 00:33:02 tom Exp $
. ./setup-vars
@@ -16,7 +16,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--backtitle "$backtitle" "$@" \
--form "Here is a possible piece of a configuration program." \
0 0 10 \
@@ -52,7 +52,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -77,7 +77,7 @@ show=`echo "$value" |sed -e 's/^/ /'`
$show" 0 0
;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form3 b/samples/form3
index c3ac6d5306e5..9a6b256b363f 100755
--- a/samples/form3
+++ b/samples/form3
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form3,v 1.6 2010/01/13 10:49:52 tom Exp $
+# $Id: form3,v 1.9 2020/11/26 00:32:45 tom Exp $
# form1 with --help-button
. ./setup-vars
@@ -17,7 +17,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--help-button \
--backtitle "$backtitle" "$@" \
--form "Here is a possible piece of a configuration program." \
@@ -30,7 +30,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -62,7 +62,7 @@ $show" 10 40
$show" 10 40
;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form4 b/samples/form4
index a733865015c6..1e5d5b0e7f3c 100755
--- a/samples/form4
+++ b/samples/form4
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form4,v 1.6 2010/01/13 10:49:52 tom Exp $
+# $Id: form4,v 1.9 2020/11/26 00:32:31 tom Exp $
# form3 with --item-help
. ./setup-vars
@@ -17,7 +17,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--help-button \
--item-help \
--backtitle "$backtitle" "$@" \
@@ -31,7 +31,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -63,7 +63,7 @@ $show" 10 40
$show" 10 40
;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form5 b/samples/form5
index 649c3872d12b..253434110b5e 100755
--- a/samples/form5
+++ b/samples/form5
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form5,v 1.6 2010/01/13 10:49:52 tom Exp $
+# $Id: form5,v 1.9 2020/11/26 00:32:17 tom Exp $
# form4 with --help-status
. ./setup-vars
@@ -17,7 +17,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--help-status \
--help-button \
--item-help \
@@ -32,7 +32,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -64,7 +64,7 @@ $show" 10 40
$show" 10 40
;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/form6 b/samples/form6
index 8b5483f4f4c1..29195b9f8322 100755
--- a/samples/form6
+++ b/samples/form6
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: form6,v 1.5 2010/01/13 10:49:52 tom Exp $
+# $Id: form6,v 1.8 2020/11/26 00:31:55 tom Exp $
# form4 with --help-status
. ./setup-vars
@@ -17,7 +17,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--help-status \
--help-button \
--item-help \
@@ -32,7 +32,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -64,7 +64,7 @@ $show" 10 40
$show" 10 40
;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/fselect b/samples/fselect
index 20b8304331a1..45bb68da4874 100755
--- a/samples/fselect
+++ b/samples/fselect
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: fselect,v 1.11 2010/01/13 10:20:03 tom Exp $
+# $Id: fselect,v 1.14 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "Please choose a file" "$@" --fselect $HOME/ 14 48 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "Please choose a file" "$@" --fselect "$HOME/" 14 48 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/fselect-stdout b/samples/fselect-stdout
index 02eefdb7b34c..0f2f5cbf21cf 100755
--- a/samples/fselect-stdout
+++ b/samples/fselect-stdout
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: fselect-stdout,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: fselect-stdout,v 1.9 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
-RESULT=`$DIALOG --stdout --title "Please choose a file" "$@" --fselect $HOME/ 14 48`
-retval=$?
+returntext=`$DIALOG --stdout --title "Please choose a file" "$@" --fselect "$HOME/" 14 48`
+returncode=$?
. ./report-string
diff --git a/samples/fselect0 b/samples/fselect0
index 3bd5b6d962a8..49249b43a071 100755
--- a/samples/fselect0
+++ b/samples/fselect0
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: fselect0,v 1.1 2011/10/14 08:32:48 tom Exp $
+# $Id: fselect0,v 1.3 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "Please choose a file" "$@" --fselect '' 14 48 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "Please choose a file" "$@" --fselect '' 14 48 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/fselect1 b/samples/fselect1
index 591379417176..4b312673c497 100755
--- a/samples/fselect1
+++ b/samples/fselect1
@@ -1,20 +1,20 @@
#!/bin/sh
-# $Id: fselect1,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: fselect1,v 1.12 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
FILE=$HOME
for n in .cshrc .profile .bashrc
do
- if test -f $HOME/$n ; then
+ if test -f "$HOME/$n" ; then
FILE=$HOME/$n
break
fi
done
exec 3>&1
-RESULT=`$DIALOG --title "Please choose a file" "$@" --fselect $FILE 14 48 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "Please choose a file" "$@" --fselect "$FILE" 14 48 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/fselect1-stdout b/samples/fselect1-stdout
index 01d1135622f7..b1406837ffee 100755
--- a/samples/fselect1-stdout
+++ b/samples/fselect1-stdout
@@ -1,18 +1,18 @@
#!/bin/sh
-# $Id: fselect1-stdout,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: fselect1-stdout,v 1.9 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
FILE=$HOME
for n in .cshrc .profile .bashrc
do
- if test -f $HOME/$n ; then
+ if test -f "$HOME/$n" ; then
FILE=$HOME/$n
break
fi
done
-RESULT=`$DIALOG --stdout --title "Please choose a file" "$@" --fselect $FILE 14 48`
-retval=$?
+returntext=`$DIALOG --stdout --title "Please choose a file" "$@" --fselect "$FILE" 14 48`
+returncode=$?
. ./report-string
diff --git a/samples/fselect2 b/samples/fselect2
index 6480c753bb10..63526dce5a26 100755
--- a/samples/fselect2
+++ b/samples/fselect2
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: fselect2,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: fselect2,v 1.11 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "Please choose a file" "$@" --fselect $HOME/ 0 0 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "Please choose a file" "$@" --fselect "$HOME/" 0 0 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/fselect2-stdout b/samples/fselect2-stdout
index 644fb2a5bf7d..c2c188ac6584 100755
--- a/samples/fselect2-stdout
+++ b/samples/fselect2-stdout
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: fselect2-stdout,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: fselect2-stdout,v 1.9 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
-RESULT=`$DIALOG --stdout --title "Please choose a file" "$@" --fselect $HOME/ 0 0`
-retval=$?
+returntext=`$DIALOG --stdout --title "Please choose a file" "$@" --fselect "$HOME/" 0 0`
+returncode=$?
. ./report-string
diff --git a/samples/gauge2 b/samples/gauge2
index 10455d144c62..f791410673af 100755
--- a/samples/gauge2
+++ b/samples/gauge2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: gauge2,v 1.8 2010/01/13 10:26:52 tom Exp $
+# $Id: gauge2,v 1.9 2019/12/10 23:37:10 tom Exp $
# The original dialog program assumed the first line after the first "XXX"
# was a percentage value (compare with "gauge" script).
@@ -22,7 +22,7 @@ echo "100") | \
$DIALOG --title "GAUGE" "$@" --gauge "Hi, this is a gauge widget" 10 40 0
-if [ "$?" = $DIALOG_ESC ] ; then
+if [ "$?" = "$DIALOG_ESC" ] ; then
echo ""
echo "Box closed !"
fi
diff --git a/samples/infobox b/samples/infobox
index 91dd5dd9e055..9f2da62c4a55 100755
--- a/samples/infobox
+++ b/samples/infobox
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: infobox,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: infobox,v 1.9 2019/12/10 23:37:10 tom Exp $
. ./setup-vars
@@ -17,5 +17,5 @@ the message. The pause here is only introduced
by the sleep command within dialog.
You have $left $unit to read this..." 10 52
left=`expr $left - 1`
-test $left = 1 && unit="second"
+test "$left" = 1 && unit="second"
done
diff --git a/samples/infobox1 b/samples/infobox1
index 4ee6c9ff7993..3cc7f27ce350 100755
--- a/samples/infobox1
+++ b/samples/infobox1
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: infobox1,v 1.4 2010/01/13 10:20:03 tom Exp $
+# $Id: infobox1,v 1.5 2019/12/10 23:37:10 tom Exp $
. ./setup-vars
@@ -17,5 +17,5 @@ the message. The pause here is only introduced
by a sleep command in the shell script.
You have $left $unit to read this..." 10 52
left=`expr $left - 1`
-test $left = 1 && unit="second"
+test "$left" = 1 && unit="second"
done
diff --git a/samples/infobox2 b/samples/infobox2
index fdf64caa85f6..08deb71901ba 100755
--- a/samples/infobox2
+++ b/samples/infobox2
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: infobox2,v 1.5 2010/01/13 10:20:03 tom Exp $
+# $Id: infobox2,v 1.6 2019/12/10 23:37:10 tom Exp $
. ./setup-vars
@@ -17,5 +17,5 @@ the message. The pause here is only introduced
by the sleep command within dialog.
You have $left $unit to read this..." 0 0
left=`expr $left - 1`
-test $left = 1 && unit="second"
+test "$left" = 1 && unit="second"
done
diff --git a/samples/infobox3 b/samples/infobox3
index edba1dfd98f4..3c773b8f69af 100755
--- a/samples/infobox3
+++ b/samples/infobox3
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: infobox3,v 1.5 2010/01/13 10:20:03 tom Exp $
+# $Id: infobox3,v 1.6 2019/12/10 23:37:10 tom Exp $
. ./setup-vars
@@ -18,5 +18,5 @@ the message. The pause here is only introduced
by the sleep command within dialog.
You have $left $unit to read this..." 0 0
left=`expr $left - 1`
-test $left = 1 && unit="second"
+test "$left" = 1 && unit="second"
done
diff --git a/samples/infobox4 b/samples/infobox4
index 7c96d6b4e46d..816b8417a0d6 100755
--- a/samples/infobox4
+++ b/samples/infobox4
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: infobox4,v 1.5 2010/01/13 10:20:03 tom Exp $
+# $Id: infobox4,v 1.6 2019/12/10 23:37:10 tom Exp $
. ./setup-vars
@@ -18,5 +18,5 @@ the message. The pause here is only introduced
by the sleep command within dialog.
You have $left $unit to read this..." 0 0
left=`expr $left - 1`
-test $left = 1 && unit="second"
+test "$left" = 1 && unit="second"
done
diff --git a/samples/infobox5 b/samples/infobox5
index 58512c90e572..b93e1de8b13b 100755
--- a/samples/infobox5
+++ b/samples/infobox5
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: infobox5,v 1.7 2011/01/18 09:19:09 tom Exp $
+# $Id: infobox5,v 1.8 2019/12/10 23:38:49 tom Exp $
# get rid of all flickering by constructing a script unroll the loop, leaving
# us in curses-mode until we're done counting.
@@ -31,7 +31,7 @@ You have $left $unit to read this..." 0 0 $last
EOF
left=`expr $left - 1`
-test $left = 1 && unit="second"
+test "$left" = 1 && unit="second"
done
echo >>$tempfile
diff --git a/samples/infobox6 b/samples/infobox6
index a3a06cef2829..c81232d6e216 100755
--- a/samples/infobox6
+++ b/samples/infobox6
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: infobox6,v 1.7 2011/01/18 09:20:59 tom Exp $
+# $Id: infobox6,v 1.8 2019/12/10 23:38:49 tom Exp $
# get rid of all flickering by constructing a script unroll the loop, leaving
# us in curses-mode until we're done counting.
#
@@ -33,7 +33,7 @@ You have $left $unit to read this..." 0 0 $last
EOF
left=`expr $left - 1`
-test $left = 1 && unit="second"
+test "$left" = 1 && unit="second"
done
echo >>$tempfile
diff --git a/samples/inputbox b/samples/inputbox
index 9975d441d75b..d249e83687f2 100755
--- a/samples/inputbox
+++ b/samples/inputbox
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox,v 1.11 2010/01/13 10:06:01 tom Exp $
+# $Id: inputbox,v 1.12 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -15,6 +15,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox-both b/samples/inputbox-both
index 4103ccf811cf..2f8681be6398 100755
--- a/samples/inputbox-both
+++ b/samples/inputbox-both
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox-both,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox-both,v 1.7 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -17,6 +17,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox-extra b/samples/inputbox-extra
index 9f2277c940a1..a297392bb505 100755
--- a/samples/inputbox-extra
+++ b/samples/inputbox-extra
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox-extra,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox-extra,v 1.7 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -16,6 +16,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox-help b/samples/inputbox-help
index 0dfe7c81462f..9aa0517a969c 100755
--- a/samples/inputbox-help
+++ b/samples/inputbox-help
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox-help,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox-help,v 1.7 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -16,6 +16,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox1 b/samples/inputbox1
index 487aa8c5edf9..44f408028b30 100755
--- a/samples/inputbox1
+++ b/samples/inputbox1
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox1,v 1.13 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox1,v 1.14 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -18,6 +18,6 @@ You can use BACKSPACE to correct errors.
Try entering your name below:" 0 0 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox2 b/samples/inputbox2
index f7b4b5f7df60..baa6605e33dd 100755
--- a/samples/inputbox2
+++ b/samples/inputbox2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox2,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox2,v 1.10 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -15,6 +15,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox3 b/samples/inputbox3
index d343e0a64cc3..2f6623b61c03 100755
--- a/samples/inputbox3
+++ b/samples/inputbox3
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox3,v 1.7 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox3,v 1.8 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -16,6 +16,6 @@ input field will be automatically scrolled. \n\
You can use BACKSPACE to correct errors. \n\n\
Try entering your name below:" 16 51 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox4 b/samples/inputbox4
index 416bf86a8603..76bd8ae77f8f 100755
--- a/samples/inputbox4
+++ b/samples/inputbox4
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: inputbox4,v 1.7 2010/01/13 10:28:12 tom Exp $
+# $Id: inputbox4,v 1.9 2020/11/26 00:09:12 tom Exp $
# An example which does not use temporary files, as suggested by Cary Evans:
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "INPUT BOX" --clear "$@" \
+returntext=`$DIALOG --title "INPUT BOX" --clear "$@" \
--inputbox "Hi, this is an input dialog box. You can use \n
this to ask questions that require the user \n
to input a string as the answer. You can \n
@@ -14,7 +14,7 @@ width of the input box, in that case, the \n
input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 2>&1 1>&3`
-retval=$?
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/inputbox5 b/samples/inputbox5
index ad7262341692..2c87f6944165 100755
--- a/samples/inputbox5
+++ b/samples/inputbox5
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox5,v 1.7 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox5,v 1.8 2020/11/26 00:03:58 tom Exp $
# use --output-fd to write to a different output than stderr
. ./setup-vars
@@ -16,6 +16,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 4> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox6-8bit b/samples/inputbox6-8bit
index b7692e8826aa..15e084ae3f9c 100755
--- a/samples/inputbox6-8bit
+++ b/samples/inputbox6-8bit
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox6-8bit,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox6-8bit,v 1.8 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -8,10 +8,10 @@
. ./testdata-8bit
$DIALOG \
---title `printf "$SAMPLE"` "$@" \
---inputbox `printf "$SAMPLE"` \
-10 40 `printf "$SAMPLE"` 2>$tempfile
+--title "`printf '%s' "$SAMPLE"`" "$@" \
+--inputbox "`printf '%s' "$SAMPLE"`" \
+10 40 "`printf '%s' "$SAMPLE"`" 2>$tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox6-utf8 b/samples/inputbox6-utf8
index 056757ed77e9..b2ccd34766f2 100755
--- a/samples/inputbox6-utf8
+++ b/samples/inputbox6-utf8
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox6-utf8,v 1.9 2013/09/24 00:06:02 tom Exp $
+# $Id: inputbox6-utf8,v 1.10 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -13,6 +13,6 @@ $DIALOG \
--title "$TITLE" "$@" \
--inputbox "$TITLE" 10 20 "D.O.G" 2>$tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/inputbox7 b/samples/inputbox7
index e79d9cc584b2..ed608cb927f1 100755
--- a/samples/inputbox7
+++ b/samples/inputbox7
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: inputbox7,v 1.7 2010/01/13 10:20:03 tom Exp $
+# $Id: inputbox7,v 1.9 2020/11/26 00:09:12 tom Exp $
# An example which produces two widget outputs.
. ./setup-vars
@@ -18,12 +18,12 @@ SEP='
'
exec 3>&1
-RESULT=`$DIALOG --title "INPUT BOX" --clear --separate-widget "$SEP" "$@" \
+returntext=`$DIALOG --title "INPUT BOX" --clear --separate-widget "$SEP" "$@" \
--inputbox "$MSG" 16 51 \
--title "ANOTHER INPUT BOX" \
--inputbox "$MSG" 16 51 \
2>&1 1>&3`
-retval=$?
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/inputmenu b/samples/inputmenu
index 3c808111dc13..9f6d818ac2e1 100755
--- a/samples/inputmenu
+++ b/samples/inputmenu
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: inputmenu,v 1.15 2012/07/06 18:11:21 tom Exp $
+# $Id: inputmenu,v 1.19 2020/11/26 00:30:23 tom Exp $
# 2002 - written by Tobias Rittweiler <tobrit@freebits.de>
. ./setup-vars
@@ -9,9 +9,9 @@ uid=`id|sed -e 's/^uid=//' -e 's/(.*//'`
gid=`id|sed -e 's/^.*gid=//' -e 's/(.*//'`
home="$HOME"
-while [ ${returncode:-99} -ne 1 -a ${returncode:-99} -ne 250 ]; do
+while [ "${returncode:-99}" -ne 1 ] && [ "${returncode:-99}" -ne 250 ]; do
exec 3>&1
- value=`$DIALOG \
+ returntext=`$DIALOG \
--clear --ok-label "Create" \
--backtitle "An Example for the use of --inputmenu:" "$@" \
--inputmenu "Originally I designed --inputmenu for a \
@@ -44,7 +44,7 @@ configuration purpose. Here is a possible piece of a configuration program. \
$user" 10 40
;;
$DIALOG_EXTRA)
- value=`echo "$value" | sed -e 's/^RENAMED //'`
+ value=`echo "$returntext" | sed -e 's/^RENAMED //'`
tag=`echo "$value" | sed -e 's/:.*//'`
item=`echo "$value" | sed -e 's/^[^:]*:[ ][ ]*//'`
@@ -56,8 +56,8 @@ configuration purpose. Here is a possible piece of a configuration program. \
esac
;;
- $DIALOG_ESC)
- echo "ESC pressed."
+ *)
+ . ./report-button
break
;;
diff --git a/samples/inputmenu-stdout b/samples/inputmenu-stdout
index a778226b486d..35384d34f167 100755
--- a/samples/inputmenu-stdout
+++ b/samples/inputmenu-stdout
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: inputmenu-stdout,v 1.13 2012/07/06 18:11:12 tom Exp $
+# $Id: inputmenu-stdout,v 1.17 2020/11/26 00:30:01 tom Exp $
# 2002 - written by Tobias Rittweiler <tobrit@freebits.de>
. ./setup-vars
@@ -9,8 +9,8 @@ uid=`id|sed -e 's/^uid=//' -e 's/(.*//'`
gid=`id|sed -e 's/^.*gid=//' -e 's/(.*//'`
home="$HOME"
-while [ ${returncode:-99} -ne 1 -a ${returncode:-99} -ne 250 ]; do
- value=`$DIALOG \
+while [ "${returncode:-99}" -ne 1 ] && [ "${returncode:-99}" -ne 250 ]; do
+ returntext=`$DIALOG \
--stdout --clear --ok-label "Create" \
--backtitle "An Example for the use of --inputmenu:" "$@" \
--inputmenu "Originally I designed --inputmenu for a \
@@ -42,7 +42,7 @@ configuration purpose. Here is a possible piece of a configuration program. \
$user" 10 40
;;
$DIALOG_EXTRA)
- value=`echo "$value" | sed -e 's/^RENAMED //'`
+ value=`echo "$returntext" | sed -e 's/^RENAMED //'`
tag=`echo "$value" | sed -e 's/:.*//'`
item=`echo "$value" | sed -e 's/^[^:]*:[ ][ ]*//'`
@@ -54,8 +54,8 @@ configuration purpose. Here is a possible piece of a configuration program. \
esac
;;
- $DIALOG_ESC)
- echo "ESC pressed."
+ *)
+ . ./report-button
break
;;
diff --git a/samples/inputmenu1 b/samples/inputmenu1
index 905c29226191..1d044c80bed6 100755
--- a/samples/inputmenu1
+++ b/samples/inputmenu1
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: inputmenu1,v 1.9 2012/07/01 00:59:54 tom Exp $
+# $Id: inputmenu1,v 1.12 2020/11/26 00:29:41 tom Exp $
#
# "inputmenu" rewritten into Bourne shell.
@@ -18,7 +18,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --clear --ok-label "Create" \
+returntext=`$DIALOG --clear --ok-label "Create" \
--backtitle "$backtitle" "$@" \
--inputmenu "Originally I designed --inputmenu for a \
configuration purpose. Here is a possible piece of a configuration program." \
@@ -57,8 +57,8 @@ exec 3>&-
$user" 10 40
;;
$DIALOG_EXTRA)
- tag=`echo "$value" |sed -e 's/^RENAMED //' -e 's/:.*//'`
- item=`echo "$value" |sed -e 's/^[^:]*:[ ]*//' -e 's/[ ]*$//'`
+ tag=`echo "$returntext" |sed -e 's/^RENAMED //' -e 's/:.*//'`
+ item=`echo "$returntext" |sed -e 's/^[^:]*:[ ]*//' -e 's/[ ]*$//'`
case "$tag" in
Username)
@@ -76,8 +76,8 @@ exec 3>&-
esac
;;
- $DIALOG_ESC)
- echo "ESC pressed."
+ *)
+ . ./report-button
break
;;
diff --git a/samples/inputmenu2 b/samples/inputmenu2
index ecef6742cbaa..1cb519d1c6c3 100755
--- a/samples/inputmenu2
+++ b/samples/inputmenu2
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: inputmenu2,v 1.9 2012/07/01 01:00:34 tom Exp $
+# $Id: inputmenu2,v 1.12 2020/11/26 00:29:26 tom Exp $
#
# "inputmenu1" with defaultitem, help-button.
@@ -19,7 +19,7 @@ defaultitem="Username:"
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --clear --ok-label "Create" \
+returntext=`$DIALOG --clear --ok-label "Create" \
--backtitle "$backtitle" \
--help-button \
--help-label "Script" \
@@ -65,8 +65,8 @@ exec 3>&-
$user" 10 40
;;
$DIALOG_EXTRA)
- tag=`echo "$value" |sed -e 's/^RENAMED //' -e 's/:.*/:/'`
- item=`echo "$value" |sed -e 's/^[^:]*:[ ]*//' -e 's/[ ]*$//'`
+ tag=`echo "$returntext" |sed -e 's/^RENAMED //' -e 's/:.*/:/'`
+ item=`echo "$returntext" |sed -e 's/^[^:]*:[ ]*//' -e 's/[ ]*$//'`
case "$tag" in
Username:)
@@ -88,8 +88,8 @@ exec 3>&-
test -n "$tag" && defaultitem="$tag"
;;
- $DIALOG_ESC)
- echo "ESC pressed."
+ *)
+ . ./report-button
break
;;
diff --git a/samples/inputmenu3 b/samples/inputmenu3
index 4b9d5229e1d2..58a3079a162c 100755
--- a/samples/inputmenu3
+++ b/samples/inputmenu3
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: inputmenu3,v 1.11 2012/07/01 01:00:34 tom Exp $
+# $Id: inputmenu3,v 1.14 2020/11/26 00:28:52 tom Exp $
#
# "inputmenu1" with defaultitem, help-button and item-help.
@@ -19,7 +19,7 @@ defaultitem="Username:"
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --clear --ok-label "Create" \
+returntext=`$DIALOG --clear --ok-label "Create" \
--backtitle "$backtitle" \
--help-button \
--help-label "Script" \
@@ -52,7 +52,7 @@ exec 3>&-
esac
;;
$DIALOG_OK)
- case $value in
+ case $returntext in
HELP*)
"$DIALOG" \
--textbox "$0" 0 0
@@ -74,8 +74,8 @@ exec 3>&-
--textbox "$0" 0 0
;;
$DIALOG_EXTRA)
- tag=`echo "$value" |sed -e 's/^RENAMED //' -e 's/:.*/:/'`
- item=`echo "$value" |sed -e 's/^[^:]*:[ ]*//' -e 's/[ ]*$//'`
+ tag=`echo "$returntext" |sed -e 's/^RENAMED //' -e 's/:.*/:/'`
+ item=`echo "$returntext" |sed -e 's/^[^:]*:[ ]*//' -e 's/[ ]*$//'`
case "$tag" in
Username:)
@@ -97,8 +97,8 @@ exec 3>&-
test -n "$tag" && defaultitem="$tag"
;;
- $DIALOG_ESC)
- echo "ESC pressed."
+ *)
+ . ./report-button
break
;;
diff --git a/samples/inputmenu4 b/samples/inputmenu4
index 6688c9ccfc0d..876e7f647fdf 100755
--- a/samples/inputmenu4
+++ b/samples/inputmenu4
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: inputmenu4,v 1.9 2012/07/01 01:00:34 tom Exp $
+# $Id: inputmenu4,v 1.12 2020/11/26 00:28:24 tom Exp $
#
# "inputmenu1" with a different label for the extra-button
@@ -18,7 +18,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --clear --ok-label "Create" \
+returntext=`$DIALOG --clear --ok-label "Create" \
--extra-label "Edit" \
--backtitle "$backtitle" "$@" \
--inputmenu "Originally I designed --inputmenu for a \
@@ -58,8 +58,8 @@ exec 3>&-
$user" 10 40
;;
$DIALOG_EXTRA)
- tag=`echo "$value" |sed -e 's/^RENAMED //' -e 's/:.*//'`
- item=`echo "$value" |sed -e 's/^[^:]*:[ ]*//' -e 's/[ ]*$//'`
+ tag=`echo "$returntext" |sed -e 's/^RENAMED //' -e 's/:.*//'`
+ item=`echo "$returntext" |sed -e 's/^[^:]*:[ ]*//' -e 's/[ ]*$//'`
case "$tag" in
Username)
@@ -77,8 +77,8 @@ exec 3>&-
esac
;;
- $DIALOG_ESC)
- echo "ESC pressed."
+ *)
+ . ./report-button
break
;;
diff --git a/samples/install/setup.c b/samples/install/setup.c
index ae569813e865..517255ab8e2a 100644
--- a/samples/install/setup.c
+++ b/samples/install/setup.c
@@ -2,7 +2,7 @@
/* Who wants to help coding? I don't like doing this... */
/* You can just start setup as normal user and see how far it is coded
- right now. This will do a fake installation and won't actually chnage
+ right now. This will do a fake installation and won't actually change
any data on your computer. */
/* TODO: write a good package selection code
diff --git a/samples/install/setup.help b/samples/install/setup.help
index 7ac8369d4e6e..614fef41ed82 100644
--- a/samples/install/setup.help
+++ b/samples/install/setup.help
@@ -30,7 +30,7 @@ your local harddisk or via network (NFS).
setup will install a very basic system.
At the end, you can install lilo, the Linux Loader.
Rebooting your computer with this little linux system
-and then runing the setup-program on it, will give
+and then running the setup-program on it, will give
the possibility to install more packages.
Creating a Linux-partition:
diff --git a/samples/killall b/samples/killall
index 7030fe22bf29..f8d573babdb6 100755
--- a/samples/killall
+++ b/samples/killall
@@ -1,16 +1,16 @@
#! /bin/sh
-# $Id: killall,v 1.3 2012/06/29 09:39:19 tom Exp $
+# $Id: killall,v 1.4 2019/12/10 23:48:58 tom Exp $
# Linux has a program that does this correctly.
. ./setup-vars
-for prog in $*
+for prog in "$@"
do
- pid=`ps -a |fgrep $prog |fgrep -v fgrep|sed -e 's/^[ ]*//' -e 's/ .*//' `
+ pid=`ps -a |fgrep "$prog" |fgrep -v fgrep|sed -e 's/^[ ]*//' -e 's/ .*//' `
if test -n "$pid" ; then
- echo killing pid=$pid, $prog
- kill -$SIG_HUP $pid || \
- kill -$SIG_TERM $pid || \
- kill -$SIG_KILL $pid
+ echo "killing pid=$pid, $prog"
+ kill "-$SIG_HUP" "$pid" || \
+ kill "-$SIG_TERM" "$pid" || \
+ kill "-$SIG_KILL" "$pid"
fi
done
diff --git a/samples/menubox b/samples/menubox
index 0cea3bb00006..4a0118dc13f6 100755
--- a/samples/menubox
+++ b/samples/menubox
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox,v 1.11 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox,v 1.13 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -19,9 +19,9 @@ Try it now!\n\n\
"NetBSD" "Another free Unix Clone for 386/486" \
"OS/2" "IBM OS/2" \
"WIN NT" "Microsoft Windows NT" \
- "PCDOS" "IBM PC DOS" \
- "MSDOS" "Microsoft DOS" 2> $tempfile
+ "PC-DOS" "IBM PC DOS" \
+ "MS-DOS" "Microsoft DOS" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox-8bit b/samples/menubox-8bit
index 91faa5cfea22..69b6bc712a52 100755
--- a/samples/menubox-8bit
+++ b/samples/menubox-8bit
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox-8bit,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox-8bit,v 1.8 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -17,13 +17,13 @@ letter of the choice as a hot key, or the \n\
number keys 1-9 to choose an option.\n\
Try it now!\n\n\
Choose the OS you like:" 20 51 4 \
- "`./rotated-data 0 $SAMPLE`" "The Great Unix Clone for 386/486" \
- "`./rotated-data 1 $SAMPLE`" "Another free Unix Clone for 386/486" \
- "`./rotated-data 2 $SAMPLE`" "IBM OS/2" \
- "`./rotated-data 3 $SAMPLE`" "Microsoft Windows NT" \
- "`./rotated-data 4 $SAMPLE`" "IBM PC DOS" \
- "`./rotated-data 5 $SAMPLE`" "Microsoft DOS" 2> $tempfile
+ "`./rotated-data 0 "$SAMPLE"`" "The Great Unix Clone for 386/486" \
+ "`./rotated-data 1 "$SAMPLE"`" "Another free Unix Clone for 386/486" \
+ "`./rotated-data 2 "$SAMPLE"`" "IBM OS/2" \
+ "`./rotated-data 3 "$SAMPLE"`" "Microsoft Windows NT" \
+ "`./rotated-data 4 "$SAMPLE"`" "IBM PC DOS" \
+ "`./rotated-data 5 "$SAMPLE"`" "Microsoft DOS" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox-utf8 b/samples/menubox-utf8
index cd6e429c2c34..4c7f45a34b9e 100755
--- a/samples/menubox-utf8
+++ b/samples/menubox-utf8
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox-utf8,v 1.10 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox-utf8,v 1.11 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -24,6 +24,6 @@ Try it now!\n\n\
"PCDOS" "IBM PC DOS" \
"MSDOS" "Microsoft DOS" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox1 b/samples/menubox1
index dc40d027e756..9df5ca3c0ec5 100755
--- a/samples/menubox1
+++ b/samples/menubox1
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox1,v 1.7 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox1,v 1.9 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -19,9 +19,9 @@ Try it now!\n\n\
"NetBSD" "Another free Unix Clone for 386/486" \
"OS/2" "IBM OS/2" \
"WIN NT" "Microsoft Windows NT" \
- "PCDOS" "IBM PC DOS" \
- "MSDOS" "Microsoft DOS" 2> $tempfile
+ "PC-DOS" "IBM PC DOS" \
+ "MS-DOS" "Microsoft DOS" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox10 b/samples/menubox10
index 86069342199c..1152223c4ccf 100755
--- a/samples/menubox10
+++ b/samples/menubox10
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: menubox10,v 1.5 2010/01/13 10:34:12 tom Exp $
+# $Id: menubox10,v 1.7 2020/11/26 00:09:12 tom Exp $
# zero-width column
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --backtitle "Debian Configuration" \
+returntext=`$DIALOG --backtitle "Debian Configuration" \
--title "Configuring debconf" \
--default-item Dialog "$@" \
--menu "Packages that use debconf for co" 19 50 6 \
@@ -16,7 +16,7 @@ RESULT=`$DIALOG --backtitle "Debian Configuration" \
Editor "" \
Noninteractive "" \
2>&1 1>&3`
-retval=$?
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/menubox11 b/samples/menubox11
index 4f275226b4b4..9bd7960582c1 100755
--- a/samples/menubox11
+++ b/samples/menubox11
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: menubox11,v 1.2 2018/06/13 21:59:21 tom Exp $
+# $Id: menubox11,v 1.4 2020/11/26 00:09:12 tom Exp $
# zero-width column
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --backtitle "Debian Configuration" \
+returntext=`$DIALOG --backtitle "Debian Configuration" \
--title "Configuring debconf" \
--default-item Dialog "$@" \
--menu "Packages that use debconf for configuration share a common look and feel. You can
@@ -25,7 +25,7 @@ Interface to use:" 0 0 6 \
Editor "" \
Noninteractive "" \
2>&1 1>&3`
-retval=$?
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/menubox12 b/samples/menubox12
index ee4b4747dd18..6723c0574425 100755
--- a/samples/menubox12
+++ b/samples/menubox12
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox12,v 1.3 2012/12/23 22:28:26 tom Exp $
+# $Id: menubox12,v 1.6 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -19,10 +19,10 @@ $CUT >$input <<-EOF
NetBSD:Another free Unix Clone for 386/486
OS/2:IBM OS/2
WIN NT:Microsoft Windows NT
- PCDOS:IBM PC DOS
- MSDOS:Microsoft DOS
+ PC-DOS:IBM PC DOS
+ MS-DOS:Microsoft DOS
EOF
-cat $input | sed -e 's/^/"/' -e 's/:/" "/g' -e 's/$/"/' >$output
+sed -e 's/^/"/' -e 's/:/" "/g' -e 's/$/"/' <$input >$output
cat $output >$input
$DIALOG --clear --title "MENU BOX" "$@" \
@@ -37,7 +37,7 @@ Try it now!\n\n\
Choose the OS you like:" 20 51 4 \
--file $input 2> $output
-retval=$?
+returncode=$?
tempfile=$output
. ./report-tempfile
diff --git a/samples/menubox2 b/samples/menubox2
index d81ba792a76a..5ab68cca3d3a 100755
--- a/samples/menubox2
+++ b/samples/menubox2
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: menubox2,v 1.7 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox2,v 1.9 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
. ./setup-tempfile
-$DIALOG --default-item "MSDOS" --clear --title "MENU BOX" "$@" \
+$DIALOG --default-item "MS-DOS" --clear --title "MENU BOX" "$@" \
--menu "Hi, this is a menu box. You can use this to \n\
present a list of choices for the user to \n\
choose. If there are more items than can fit \n\
@@ -17,11 +17,11 @@ Try it now!\n\n\
Choose the OS you like:" 20 51 4 \
"Linux" "The Great Unix Clone for 386/486" \
"NetBSD" "Another free Unix Clone for 386/486" \
- "OS/2" "IBM OS/2" \
+ "OS/2" "IBM OS/2" \
"WIN NT" "Microsoft Windows NT" \
- "PCDOS" "IBM PC DOS" \
- "MSDOS" "Microsoft DOS" 2> $tempfile
+ "PC-DOS" "IBM PC DOS" \
+ "MS-DOS" "Microsoft DOS" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox3 b/samples/menubox3
index d33b5d6fdef9..2f03505b5c2e 100755
--- a/samples/menubox3
+++ b/samples/menubox3
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox3,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox3,v 1.10 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -19,9 +19,9 @@ Try it now!\n\n\
"NetBSD" "Another free Unix Clone for 386/486" "Or NetBSD?" \
"OS/2" "IBM OS/2" "aka \"Warp\"" \
"WIN NT" "Microsoft Windows NT" "hmm" \
- "PCDOS" "IBM PC DOS" "clone of a clone" \
- "MSDOS" "Microsoft DOS" "DOS: Disk Operating System, originally for an IBM contract, hence using the same jargon" 2> $tempfile
+ "PC-DOS" "IBM PC DOS" "clone of a clone" \
+ "MS-DOS" "Microsoft DOS" "DOS: Disk Operating System, originally for an IBM contract, hence using the same jargon" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox4 b/samples/menubox4
index e95342de9d8e..a0b2f6bab682 100755
--- a/samples/menubox4
+++ b/samples/menubox4
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox4,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox4,v 1.10 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -19,9 +19,9 @@ Try it now!\n\n\
"NetBSD" "Another free Unix Clone for 386/486 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "Or NetBSD?" \
"OS/2" "IBM OS/2 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "aka \"Warp\"" \
"WIN NT" "Microsoft Windows NT xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "hmm" \
- "PCDOS" "IBM PC DOS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "clone of a clone" \
- "MSDOS" "Microsoft DOS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "DOS: Disk Operating System, originally for an IBM contract, hence using the same jargon" 2> $tempfile
+ "PC-DOS" "IBM PC DOS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "clone of a clone" \
+ "MS-DOS" "Microsoft DOS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "DOS: Disk Operating System, originally for an IBM contract, hence using the same jargon" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox5 b/samples/menubox5
index c89be3a0e74a..0ee6bd414d9a 100755
--- a/samples/menubox5
+++ b/samples/menubox5
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox5,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox5,v 1.11 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -21,10 +21,10 @@ Try it now!\n\n\
"WIN NT" "Microsoft Windows NT xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "hmm" \
"WIN 2K" "Microsoft Windows 2000 xxxxxxxxxxxxxxxxxxxxxxxxxxxx" "hmm" \
"WIN XP" "Microsoft Windows XP (son of Windows 95) xxxxxxxxxx" "hmm" \
- "WIN 95" "Microsoft Windows 95 (son of MSDOS) xxxxxxxxxxxxxxx" "hmm" \
- "PCDOS" "IBM PC DOS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "clone of a clone" \
- "MSDOS" "Microsoft DOS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "DOS: Disk Operating System, originally for an IBM contract, hence using the same jargon" 2> $tempfile
+ "WIN 95" "Microsoft Windows 95 (son of MS-DOS) xxxxxxxxxxxxxx" "hmm" \
+ "PC-DOS" "IBM PC DOS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "clone of a clone" \
+ "MS-DOS" "Microsoft DOS xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" "DOS: Disk Operating System, originally for an IBM contract, hence using the same jargon" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox6 b/samples/menubox6
index afcc90de2b08..a1b43d61bcb8 100755
--- a/samples/menubox6
+++ b/samples/menubox6
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox6,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox6,v 1.10 2020/11/26 00:03:58 tom Exp $
# example showing the --colors option
. ./setup-vars
@@ -20,9 +20,9 @@ Try it now!\n\n\
"NetBSD" "Another free Unix Clone for \Zu386/486" "Or \ZbNetBSD?" \
"OS/2" "IBM OS/2" "aka \"Warp\"" \
"WIN NT" "Microsoft Windows NT" "hmm" \
- "PCDOS" "IBM PC \ZrDOS" "clone of a clone" \
- "MSDOS" "Microsoft \ZrDOS" "\ZbDOS\Zn: \Zb\Z3D\Znisk \Zb\Z3O\Znperating \Zb\Z3S\Znystem, originally for an IBM contract, hence using the same jargon" 2> $tempfile
+ "PC-DOS" "IBM PC \ZrDOS" "clone of a clone" \
+ "MS-DOS" "Microsoft \ZrDOS" "\ZbDOS\Zn: \Zb\Z3D\Znisk \Zb\Z3O\Znperating \Zb\Z3S\Znystem, originally for an IBM contract, hence using the same jargon" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox7 b/samples/menubox7
index 2e85b435608f..421943bfcf80 100755
--- a/samples/menubox7
+++ b/samples/menubox7
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: menubox7,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox7,v 1.11 2020/11/26 00:03:58 tom Exp $
# example with --extra-button
. ./setup-vars
@@ -21,9 +21,9 @@ Try it now!\n\n\
"NetBSD" "Another free Unix Clone for 386/486" "Or NetBSD?" \
"OS/2" "IBM OS/2" "aka \"Warp\"" \
"WIN NT" "Microsoft Windows NT" "hmm" \
- "PCDOS" "IBM PC DOS" "clone of a clone" \
- "MSDOS" "Microsoft DOS" "DOS: Disk Operating System, originally for an IBM contract, hence using the same jargon" 2> $tempfile
+ "PC-DOS" "IBM PC DOS" "clone of a clone" \
+ "MS-DOS" "Microsoft DOS" "DOS: Disk Operating System, originally for an IBM contract, hence using the same jargon" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/menubox8 b/samples/menubox8
index 85448d058418..eb90de0c8f9c 100755
--- a/samples/menubox8
+++ b/samples/menubox8
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: menubox8,v 1.7 2010/01/13 10:34:32 tom Exp $
+# $Id: menubox8,v 1.10 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --help-button \
- --default-item "MSDOS" \
+returntext=`$DIALOG --help-button \
+ --default-item "MS-DOS" \
--clear \
--title "MENU BOX" "$@" \
--menu "Hi, this is a menu box. You can use this to \n\
@@ -21,10 +21,10 @@ Try it now!\n\n\
"NetBSD" "Another free Unix Clone for 386/486" \
"OS/2" "IBM OS/2" \
"WIN NT" "Microsoft Windows NT" \
- "PCDOS" "IBM PC DOS" \
- "MSDOS" "Microsoft DOS" \
+ "PC-DOS" "IBM PC DOS" \
+ "MS-DOS" "Microsoft DOS" \
2>&1 1>&3`
-retval=$?
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/menubox9 b/samples/menubox9
index 837393951893..5f0c8e9104ec 100755
--- a/samples/menubox9
+++ b/samples/menubox9
@@ -1,10 +1,10 @@
#!/bin/sh
-# $Id: menubox9,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: menubox9,v 1.8 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --help-button \
+returntext=`$DIALOG --help-button \
--clear \
--title "Select Linux installation partition:" "$@" \
--menu \
@@ -20,7 +20,7 @@ root (/) Linux partition." 13 70 5 \
"---" "(add none, continue with setup)" \
"---" "(add none, continue with setup)" \
2>&1 1>&3`
-retval=$?
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/mixedform b/samples/mixedform
index 617847682ceb..ac4d625e5992 100755
--- a/samples/mixedform
+++ b/samples/mixedform
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: mixedform,v 1.6 2010/01/13 10:47:35 tom Exp $
+# $Id: mixedform,v 1.9 2020/11/26 00:27:07 tom Exp $
. ./setup-vars
@@ -9,7 +9,7 @@ while test $returncode != 1 && test $returncode != 250
do
returncode=$?
exec 3>&1
-value=`$DIALOG --title "Mixed form demonstration" --ok-label "Submit" \
+returntext=`$DIALOG --title "Mixed form demonstration" --ok-label "Submit" \
--backtitle "$backtitle" \
--insecure "$@" \
--mixedform "Here is a possible piece of a configuration program." \
@@ -21,7 +21,7 @@ value=`$DIALOG --title "Mixed form demonstration" --ok-label "Submit" \
2>&1 1>&3`
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -45,16 +45,8 @@ show=`echo "$value" |sed -e 's/^/ /'`
--msgbox "Resulting data:\n\
$show" 10 40
;;
- $DIALOG_HELP)
- echo "Button 2 (Help) pressed."
- exit
- ;;
- $DIALOG_EXTRA)
- echo "Button 3 (Extra) pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/mixedform2 b/samples/mixedform2
index 07f1d664617c..6a8f554c5dda 100755
--- a/samples/mixedform2
+++ b/samples/mixedform2
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: mixedform2,v 1.5 2010/01/13 10:47:35 tom Exp $
+# $Id: mixedform2,v 1.8 2020/11/26 00:26:50 tom Exp $
. ./setup-vars
@@ -9,7 +9,7 @@ while test $returncode != 1 && test $returncode != 250
do
returncode=$?
exec 3>&1
-value=`$DIALOG --title "Mixed form demonstration" --ok-label "Submit" \
+returntext=`$DIALOG --title "Mixed form demonstration" --ok-label "Submit" \
--backtitle "$backtitle" \
--insecure "$@" \
--mixedform "Here is a possible piece of a configuration program." \
@@ -21,7 +21,7 @@ value=`$DIALOG --title "Mixed form demonstration" --ok-label "Submit" \
2>&1 1>&3`
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -45,16 +45,8 @@ show=`echo "$value" |sed -e 's/^/ /'`
--msgbox "Resulting data:\n\
$show" 10 40
;;
- $DIALOG_HELP)
- echo "Button 2 (Help) pressed."
- exit
- ;;
- $DIALOG_EXTRA)
- echo "Button 3 (Extra) pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/msgbox b/samples/msgbox
index adc204e11f73..7196e334166d 100755
--- a/samples/msgbox
+++ b/samples/msgbox
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox,v 1.7 2010/01/13 10:35:13 tom Exp $
+# $Id: msgbox,v 1.8 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -8,6 +8,6 @@ $DIALOG --title "MESSAGE BOX" --clear "$@" \
display any message you like. The box will remain until \
you press the ENTER key." 10 41
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/msgbox-help b/samples/msgbox-help
index 3825f6b9819f..8f46b7ca7a4a 100755
--- a/samples/msgbox-help
+++ b/samples/msgbox-help
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox-help,v 1.6 2010/01/13 10:53:11 tom Exp $
+# $Id: msgbox-help,v 1.7 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -9,6 +9,6 @@ $DIALOG --title "MESSAGE BOX" --clear \
display any message you like. The box will remain until \
you press the ENTER key." 10 41
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/msgbox-utf8 b/samples/msgbox-utf8
index e7331502ad9b..df3af7f7b1bd 100755
--- a/samples/msgbox-utf8
+++ b/samples/msgbox-utf8
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox-utf8,v 1.1 2011/01/18 00:25:30 tom Exp $
+# $Id: msgbox-utf8,v 1.2 2020/11/26 00:03:58 tom Exp $
# from Debian #570634
. ./setup-vars
@@ -9,6 +9,6 @@
${DIALOG-dialog} "$@" \
--title "ทดสอบวรรณยุà¸à¸•à¹Œ" \
--msgbox "วรรณยุà¸à¸•à¹Œà¸­à¸¢à¸¹à¹ˆà¸—้ายบรรทัดได้หรือไม่" 8 23
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/msgbox1 b/samples/msgbox1
index b7ef8244bef9..adc811f7b10e 100755
--- a/samples/msgbox1
+++ b/samples/msgbox1
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox1,v 1.9 2010/01/13 10:26:52 tom Exp $
+# $Id: msgbox1,v 1.11 2019/12/11 01:56:43 tom Exp $
. ./setup-vars
@@ -8,27 +8,27 @@ $DIALOG --title "MESSAGE BOX" --clear "$@" \
display any message you like. The box will remain until
you press the ENTER key. This box is being displayed
with dialogs default aspect ratio of 9." 0 0
-test $? = $DIALOG_ESC && exit
+test $? = "$DIALOG_ESC" && exit
$DIALOG --aspect 12 --title "MESSAGE BOX aspect=12" --clear "$@" \
--msgbox "Hi, this is a simple message box. You can use this to
display any message you like. The box will remain until
you press the ENTER key. This box is being displayed
with an aspect ratio of 12." 0 0
-test $? = $DIALOG_ESC && exit
+test $? = "$DIALOG_ESC" && exit
$DIALOG --aspect 6 --title "MESSAGE BOX aspect=6" --clear "$@" \
--msgbox "Hi, this is a simple message box. You can use this to
display any message you like. The box will remain until
you press the ENTER key. This box is being displayed
with an aspect ratio of 6." 0 0
-test $? = $DIALOG_ESC && exit
+test $? = "$DIALOG_ESC" && exit
$DIALOG --aspect 6 --cr-wrap --title "MESSAGE BOX aspect=6 with --cr-wrap" \
- --clear --msgbox " "$@" \
+ --clear "$@" --msgbox " \
Hi, this is a simple
message box. You can
use this to display any
message you like.
The box will remain until you press the ENTER key. This box is being displayed with an aspect ratio of 6, and using --cr-wrap.\n" 0 0
-test $? = $DIALOG_ESC && exit
+test $? = "$DIALOG_ESC" && exit
diff --git a/samples/msgbox2 b/samples/msgbox2
index b39f65a634d3..f3bbb0410aa1 100755
--- a/samples/msgbox2
+++ b/samples/msgbox2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox2,v 1.7 2010/01/13 10:26:52 tom Exp $
+# $Id: msgbox2,v 1.9 2019/12/11 01:56:17 tom Exp $
. ./setup-vars
@@ -8,27 +8,27 @@ $DIALOG --title "MESSAGE BOX" --trim "$@" \
display any message you like. The box will remain until
you press the ENTER key. This box is being displayed
with dialogs default aspect ratio of 9." 0 0
-test $? = $DIALOG_ESC && exit
+test $? = "$DIALOG_ESC" && exit
$DIALOG --aspect 12 --title "MESSAGE BOX aspect=12" --trim "$@" \
--msgbox "Hi, this is a simple message box. You can use this to
display any message you like. The box will remain until
you press the ENTER key. This box is being displayed
with an aspect ratio of 12." 0 0
-test $? = $DIALOG_ESC && exit
+test $? = "$DIALOG_ESC" && exit
$DIALOG --aspect 6 --title "MESSAGE BOX aspect=6" --trim "$@" \
--msgbox "Hi, this is a simple message box. You can use this to
display any message you like. The box will remain until
you press the ENTER key. This box is being displayed
with an aspect ratio of 6." 0 0
-test $? = $DIALOG_ESC && exit
+test $? = "$DIALOG_ESC" && exit
$DIALOG --aspect 6 --cr-wrap --title "MESSAGE BOX aspect=6 with --cr-wrap" \
- --trim --msgbox " "$@" \
+ --trim "$@" --msgbox " \
Hi, this is a simple
message box. You can
use this to display any
message you like.
The box will remain until you press the ENTER key. This box is being displayed with an aspect ratio of 6, and using --cr-wrap.\n" 0 0
-test $? = $DIALOG_ESC && exit
+test $? = "$DIALOG_ESC" && exit
diff --git a/samples/msgbox3 b/samples/msgbox3
index d1ea1080f885..0157b1e14568 100755
--- a/samples/msgbox3
+++ b/samples/msgbox3
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox3,v 1.7 2010/01/13 10:26:52 tom Exp $
+# $Id: msgbox3,v 1.8 2019/12/11 00:03:44 tom Exp $
. ./setup-vars
@@ -17,6 +17,6 @@ $DIALOG --title "MESSAGE BOX (width $width)" --clear --no-collapse "$@" \
Hi, this is a simple message box. You can use this to \
display any message you like. The box will remain until \
you press the ENTER key." 15 $width
-test $? = $DIALOG_ESC && break
+test $? = "$DIALOG_ESC" && break
width=`expr $width + 1`
done
diff --git a/samples/msgbox4-8bit b/samples/msgbox4-8bit
index 216ac8eccb50..ba703c6134b6 100755
--- a/samples/msgbox4-8bit
+++ b/samples/msgbox4-8bit
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox4-8bit,v 1.4 2010/01/13 10:20:03 tom Exp $
+# $Id: msgbox4-8bit,v 1.8 2020/11/26 00:26:09 tom Exp $
. ./setup-vars
@@ -12,18 +12,20 @@ $DIALOG --title "MESSAGE BOX (width $width)" --no-collapse --colors "$@" \
--msgbox "\
This sample uses characters which are non-printing in POSIX locale.
-\Z1`./rotated-data 0 $SAMPLE` \Z2`./rotated-data 1 $SAMPLE` \Z3`./rotated-data 2 $SAMPLE` \Z4`./rotated-data 3 $SAMPLE`\Zn
+\Z1`./rotated-data 0 "$SAMPLE"` \Z2`./rotated-data 1 "$SAMPLE"` \Z3`./rotated-data 2 "$SAMPLE"` \Z4`./rotated-data 3 "$SAMPLE"`\Zn
Hi, this is a simple message box. You can use this to \
display any message you like. The box will remain until \
you press the ENTER key." 22 $width
-retval=$?
-
-case $retval in
- $DIALOG_CANCEL)
- echo "Cancel pressed.";exit;;
- $DIALOG_ESC)
- echo "ESC pressed.";exit;;
+returncode=$?
+
+case $returncode in
+ $DIALOG_OK)
+ ;;
+ *)
+ . ./report-button;
+ exit
+ ;;
esac
width=`expr $width + 1`
diff --git a/samples/msgbox4-utf8 b/samples/msgbox4-utf8
index acbbebe5eabb..00ac0698ff8b 100755
--- a/samples/msgbox4-utf8
+++ b/samples/msgbox4-utf8
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox4-utf8,v 1.10 2010/01/13 10:20:03 tom Exp $
+# $Id: msgbox4-utf8,v 1.13 2020/11/26 00:25:37 tom Exp $
. ./setup-vars
@@ -23,13 +23,15 @@ There are several checking points:
Hi, this is a simple message box. You can use this to \
display any message you like. The box will remain until \
you press the ENTER key." 22 $width
-retval=$?
-
-case $retval in
- $DIALOG_CANCEL)
- echo "Cancel pressed.";exit;;
- $DIALOG_ESC)
- echo "ESC pressed.";exit;;
+returncode=$?
+
+case $returncode in
+ $DIALOG_OK)
+ ;;
+ *)
+ . ./report-button;
+ exit
+ ;;
esac
width=`expr $width + 1`
diff --git a/samples/msgbox5 b/samples/msgbox5
index f5d942725d5c..e91dbe87f9c3 100755
--- a/samples/msgbox5
+++ b/samples/msgbox5
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox5,v 1.5 2010/01/13 10:26:52 tom Exp $
+# $Id: msgbox5,v 1.6 2019/12/11 00:03:34 tom Exp $
# this differs from msgbox3 by making a window small enough to force scrolling.
. ./setup-vars
@@ -18,6 +18,6 @@ $DIALOG --title "MESSAGE BOX (width $width)" --clear --no-collapse "$@" \
Hi, this is a simple message box. You can use this to \
display any message you like. The box will remain until \
you press the ENTER key." 10 $width
-test $? = $DIALOG_ESC && break
+test $? = "$DIALOG_ESC" && break
width=`expr $width + 1`
done
diff --git a/samples/msgbox6 b/samples/msgbox6
index 1d30f021897d..e2f22cb7d731 100755
--- a/samples/msgbox6
+++ b/samples/msgbox6
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox6,v 1.5 2010/01/13 10:26:52 tom Exp $
+# $Id: msgbox6,v 1.6 2019/12/11 00:03:24 tom Exp $
# this differs from msgbox3 by making a window small enough to force scrolling.
. ./setup-vars
@@ -12,6 +12,6 @@ $DIALOG --title "MESSAGE BOX (width $width)" --clear "$@" \
a b c d e f g h j i j k l m n o p q r s t u v w x y z
A B C D E F G H J I J K L M N O P Q R S T U V W X Y Z
" 10 $width
-test $? = $DIALOG_ESC && break
+test $? = "$DIALOG_ESC" && break
width=`expr $width + 1`
done
diff --git a/samples/msgbox6a b/samples/msgbox6a
index e84edbf5f759..cbbfb6034ccf 100755
--- a/samples/msgbox6a
+++ b/samples/msgbox6a
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: msgbox6a,v 1.5 2010/01/13 10:26:52 tom Exp $
+# $Id: msgbox6a,v 1.6 2019/12/11 00:03:14 tom Exp $
# this differs from msgbox3 by making a window small enough to force scrolling.
. ./setup-vars
@@ -12,6 +12,6 @@ $DIALOG --title "MESSAGE BOX (width $width)" --clear "$@" \
.a .b .c .d .e .f .g .h .j .i .j .k .l .m .n .o .p .q .r .s .t .u .v .w .x .y .z
.A .B .C .D .E .F .G .H .J .I .J .K .L .M .N .O .P .Q .R .S .T .U .V .W .X .Y .Z
" 10 $width
-test $? = $DIALOG_ESC && break
+test $? = "$DIALOG_ESC" && break
width=`expr $width + 1`
done
diff --git a/samples/password b/samples/password
index 4517043ac288..57b73bc04683 100755
--- a/samples/password
+++ b/samples/password
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: password,v 1.7 2010/01/13 10:20:03 tom Exp $
+# $Id: password,v 1.8 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -15,6 +15,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/password1 b/samples/password1
index adeabc09b1fe..c173e82384dc 100755
--- a/samples/password1
+++ b/samples/password1
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: password1,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: password1,v 1.7 2020/11/26 00:03:58 tom Exp $
. ./setup-vars
@@ -16,6 +16,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/password2 b/samples/password2
index 91a7e455fb3e..07a8c00afa2a 100755
--- a/samples/password2
+++ b/samples/password2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: password2,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: password2,v 1.7 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -16,6 +16,6 @@ input field will be automatically scrolled. \n
You can use BACKSPACE to correct errors. \n\n
Try entering your name below:" 16 51 stupid 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/passwordform1 b/samples/passwordform1
index 7c3c1f03928a..07422e139d84 100755
--- a/samples/passwordform1
+++ b/samples/passwordform1
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: passwordform1,v 1.5 2010/01/13 10:47:35 tom Exp $
+# $Id: passwordform1,v 1.8 2020/11/26 00:23:09 tom Exp $
. ./setup-vars
@@ -16,7 +16,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--backtitle "$backtitle" \
--insecure "$@" \
--passwordform "Here is a possible piece of a configuration program." \
@@ -29,7 +29,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -53,16 +53,8 @@ show=`echo "$value" |sed -e 's/^/ /'`
--msgbox "Resulting data:\n\
$show" 10 40
;;
- $DIALOG_HELP)
- echo "Button 2 (Help) pressed."
- exit
- ;;
- $DIALOG_EXTRA)
- echo "Button 3 (Extra) pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/passwordform1-utf8 b/samples/passwordform1-utf8
index 3dda34c0e62e..b1cfb59de083 100755
--- a/samples/passwordform1-utf8
+++ b/samples/passwordform1-utf8
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: passwordform1-utf8,v 1.7 2010/01/13 10:47:35 tom Exp $
+# $Id: passwordform1-utf8,v 1.10 2020/11/26 00:22:47 tom Exp $
. ./setup-vars
@@ -18,7 +18,7 @@ returncode=0
while test $returncode != 1 && test $returncode != 250
do
exec 3>&1
-value=`$DIALOG --ok-label "Submit" \
+returntext=`$DIALOG --ok-label "Submit" \
--backtitle "$backtitle" \
--insecure "$@" \
--passwordform "Here is a possible piece of a configuration program." \
@@ -31,7 +31,7 @@ value=`$DIALOG --ok-label "Submit" \
returncode=$?
exec 3>&-
-show=`echo "$value" |sed -e 's/^/ /'`
+show=`echo "$returntext" |sed -e 's/^/ /'`
case $returncode in
$DIALOG_CANCEL)
@@ -55,16 +55,8 @@ show=`echo "$value" |sed -e 's/^/ /'`
--msgbox "Resulting data:\n\
$show" 10 40
;;
- $DIALOG_HELP)
- echo "Button 2 (Help) pressed."
- exit
- ;;
- $DIALOG_EXTRA)
- echo "Button 3 (Extra) pressed."
- exit
- ;;
*)
- echo "Return code was $returncode"
+ . ./report-button
exit
;;
esac
diff --git a/samples/pause b/samples/pause
index 64e211b7f693..c524244843c4 100755
--- a/samples/pause
+++ b/samples/pause
@@ -1,10 +1,10 @@
#!/bin/sh
-# $Id: pause,v 1.5 2010/01/14 00:27:23 tom Exp $
+# $Id: pause,v 1.6 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
$DIALOG --title "PAUSE" "$@" --pause "Hi, this is a pause widget" 20 70 10
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/pause-both b/samples/pause-both
index aa729361497a..5e7564f58578 100755
--- a/samples/pause-both
+++ b/samples/pause-both
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: pause-both,v 1.1 2011/01/18 09:49:24 tom Exp $
+# $Id: pause-both,v 1.2 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -8,7 +8,7 @@ $DIALOG --title "PAUSE" \
--extra-button "$@" \
--pause "Hi, this is a pause widget" 20 70 10
-retval=$?
-echo return $retval
+returncode=$?
+echo return $returncode
. ./report-button
diff --git a/samples/pause-extra b/samples/pause-extra
index 846e10880799..a5e366d79d93 100755
--- a/samples/pause-extra
+++ b/samples/pause-extra
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: pause-extra,v 1.1 2011/01/18 09:49:07 tom Exp $
+# $Id: pause-extra,v 1.2 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -7,7 +7,7 @@ $DIALOG --title "PAUSE" \
--extra-button "$@" \
--pause "Hi, this is a pause widget" 20 70 10
-retval=$?
-echo return $retval
+returncode=$?
+echo return $returncode
. ./report-button
diff --git a/samples/pause-help b/samples/pause-help
index 2d3656e71963..6d45753da520 100755
--- a/samples/pause-help
+++ b/samples/pause-help
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: pause-help,v 1.5 2010/01/13 10:36:00 tom Exp $
+# $Id: pause-help,v 1.6 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -7,6 +7,6 @@ $DIALOG --title "PAUSE" \
--help-button "$@" \
--pause "Hi, this is a pause widget" 20 70 10
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/prgbox b/samples/prgbox
index c06a6301c7a4..d830e79e878a 100755
--- a/samples/prgbox
+++ b/samples/prgbox
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: prgbox,v 1.2 2012/07/02 09:46:24 tom Exp $
+# $Id: prgbox,v 1.3 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
$DIALOG --title "PRGBOX" "$@" --prgbox "./shortlist" 20 70
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/prgbox2 b/samples/prgbox2
index ba94622cd556..12239ce2ae0d 100755
--- a/samples/prgbox2
+++ b/samples/prgbox2
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: prgbox2,v 1.2 2012/07/02 09:46:24 tom Exp $
+# $Id: prgbox2,v 1.3 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
$DIALOG --title "PRGBOX" "$@" --prgbox "./shortlist 3" 20 70
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/programbox b/samples/programbox
index afa29e1b3f9a..bc6421bf19e2 100755
--- a/samples/programbox
+++ b/samples/programbox
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: programbox,v 1.3 2018/06/17 20:45:25 tom Exp $
+# $Id: programbox,v 1.4 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -18,5 +18,5 @@ done <$tempfile
$DIALOG --title "PROGRAMBOX" "$@" --programbox 20 70
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/programbox2 b/samples/programbox2
index d55c497b64c1..fe1c826e0f05 100755
--- a/samples/programbox2
+++ b/samples/programbox2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: programbox2,v 1.3 2018/06/17 20:45:25 tom Exp $
+# $Id: programbox2,v 1.4 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -18,5 +18,5 @@ done <$tempfile
$DIALOG --title "PROGRAMBOX" "$@" --programbox "ProgramBox" 20 70
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/programbox3 b/samples/programbox3
new file mode 100755
index 000000000000..1dc020c3d222
--- /dev/null
+++ b/samples/programbox3
@@ -0,0 +1,22 @@
+#!/bin/sh
+# $Id: programbox3,v 1.2 2020/11/26 00:05:11 tom Exp $
+
+. ./setup-vars
+
+. ./setup-tempfile
+
+ls -1 >$tempfile
+(
+while true
+do
+read text
+test -z "$text" && break
+ls -ld "$text" || break
+sleep 0.1
+done <$tempfile
+) |
+
+$DIALOG --title "PROGRAMBOX" "$@" --programbox -1 -1
+
+returncode=$?
+. ./report-button
diff --git a/samples/progress b/samples/progress
index a416909cce35..e2bbe1752397 100755
--- a/samples/progress
+++ b/samples/progress
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: progress,v 1.7 2018/06/17 20:45:25 tom Exp $
+# $Id: progress,v 1.8 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -18,5 +18,5 @@ done <$tempfile
$DIALOG --title "PROGRESS" "$@" --progressbox 20 70
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/progress2 b/samples/progress2
index f4bdb3cae80b..f5d9e782bab0 100755
--- a/samples/progress2
+++ b/samples/progress2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: progress2,v 1.7 2018/06/17 20:45:25 tom Exp $
+# $Id: progress2,v 1.8 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -18,5 +18,5 @@ done <$tempfile
$DIALOG --title "PROGRESS" "$@" --progressbox "This is a detailed description\nof the progress-box." 20 70
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/radiolist b/samples/radiolist
index 602ad82044ac..93068d166700 100755
--- a/samples/radiolist
+++ b/samples/radiolist
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: radiolist,v 1.13 2010/01/13 10:20:03 tom Exp $
+# $Id: radiolist,v 1.14 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -23,6 +23,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." off \
"Lemon" "You know how it tastes." off 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/radiolist1 b/samples/radiolist1
index 77defa52ced0..da7ad8b56631 100755
--- a/samples/radiolist1
+++ b/samples/radiolist1
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: radiolist1,v 1.1 2010/01/17 23:05:14 tom Exp $
+# $Id: radiolist1,v 1.2 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -28,6 +28,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." off \
"Lemon" "You know how it tastes." off 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/radiolist10 b/samples/radiolist10
index 2953871c5f82..8e8f0d3463d9 100755
--- a/samples/radiolist10
+++ b/samples/radiolist10
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: radiolist10,v 1.6 2010/01/13 10:20:03 tom Exp $
+# $Id: radiolist10,v 1.7 2020/11/26 00:05:11 tom Exp $
# zero-width column
. ./setup-vars
@@ -25,6 +25,6 @@ Press SPACE to toggle an option on/off. \n\n\
Noninteractive "" on \
2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/radiolist2 b/samples/radiolist2
index e2965eac1eed..7ab31af59c9c 100755
--- a/samples/radiolist2
+++ b/samples/radiolist2
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: radiolist2,v 1.8 2010/01/13 10:20:03 tom Exp $
+# $Id: radiolist2,v 1.9 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -25,6 +25,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." off \
"Lemon" "You know how it tastes." off 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/radiolist3 b/samples/radiolist3
index 6c695e7197ce..a1fd02e45f5b 100755
--- a/samples/radiolist3
+++ b/samples/radiolist3
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: radiolist3,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: radiolist3,v 1.10 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -25,6 +25,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." off "Hint: usually not close to cats" \
"Lemon" "You know how it tastes." off "Hint: like an orange" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/radiolist4 b/samples/radiolist4
index 67d920f32941..c2c47dca251b 100755
--- a/samples/radiolist4
+++ b/samples/radiolist4
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: radiolist4,v 1.9 2010/01/13 10:20:03 tom Exp $
+# $Id: radiolist4,v 1.10 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -25,6 +25,6 @@ Press SPACE to toggle an option on/off. \n\n\
"Fish" "Cats like fish." off "Hint: usually not close to cats" \
"Lemon" "You know how it tastes." off "Hint: like an orange" 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/rangebox b/samples/rangebox
index d864026eb967..962607d26c19 100755
--- a/samples/rangebox
+++ b/samples/rangebox
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: rangebox,v 1.3 2012/12/05 10:07:54 tom Exp $
+# $Id: rangebox,v 1.5 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "RANGE BOX" --rangebox "Please set the volume..." 0 60 0 123 5 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "RANGE BOX" --rangebox "Please set the volume..." 0 60 0 123 5 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/rangebox2 b/samples/rangebox2
index f67f02be254e..8a88dc05135a 100755
--- a/samples/rangebox2
+++ b/samples/rangebox2
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: rangebox2,v 1.1 2012/12/05 10:28:58 tom Exp $
+# $Id: rangebox2,v 1.3 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "RANGE BOX" --rangebox "Please set the volume..." 0 60 0 6 5 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "RANGE BOX" --rangebox "Please set the volume..." 0 60 0 6 5 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/rangebox3 b/samples/rangebox3
index 19dad64ad990..b854d9fb0993 100755
--- a/samples/rangebox3
+++ b/samples/rangebox3
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: rangebox3,v 1.1 2012/12/05 10:19:42 tom Exp $
+# $Id: rangebox3,v 1.3 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "RANGE BOX" --rangebox "Please set the volume..." 0 60 -48 55 5 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "RANGE BOX" --rangebox "Please set the volume..." 0 60 -48 55 5 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/rangebox4 b/samples/rangebox4
index b8b68c2c661c..0e05e9210f4b 100755
--- a/samples/rangebox4
+++ b/samples/rangebox4
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: rangebox4,v 1.1 2012/12/05 11:54:04 tom Exp $
+# $Id: rangebox4,v 1.3 2020/11/26 00:09:12 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "RANGE BOX" --rangebox "Please set the volume..." 0 60 10 100 5 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "RANGE BOX" --rangebox "Please set the volume..." 0 60 10 100 5 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/report-button b/samples/report-button
index c6a173094573..0976c96a9d83 100644
--- a/samples/report-button
+++ b/samples/report-button
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: report-button,v 1.3 2012/06/29 09:29:36 tom Exp $
-# Report button-only, no $RESULT
+# $Id: report-button,v 1.8 2020/11/26 00:17:40 tom Exp $
+# Report button-only, no $returntext
# vile:shmode
-case $retval in
+case ${returncode:-0} in
$DIALOG_OK)
echo "OK";;
$DIALOG_CANCEL)
@@ -14,8 +14,12 @@ case $retval in
echo "Extra button pressed.";;
$DIALOG_ITEM_HELP)
echo "Item-help button pressed.";;
+ $DIALOG_TIMEOUT)
+ echo "Timeout expired.";;
$DIALOG_ERROR)
echo "ERROR!";;
$DIALOG_ESC)
echo "ESC pressed.";;
+ *)
+ echo "Return code was $returncode";;
esac
diff --git a/samples/report-edit b/samples/report-edit
index 37e3eb088570..d2343b9ff52a 100644
--- a/samples/report-edit
+++ b/samples/report-edit
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: report-edit,v 1.4 2012/06/29 09:29:41 tom Exp $
+# $Id: report-edit,v 1.8 2020/11/26 00:18:32 tom Exp $
# Report results from editing.
# vile:shmode
-case $retval in
+case ${returncode:-0} in
$DIALOG_OK)
- diff -c $input $output
+ diff -c "${input:-input}" "${output:-output}"
echo "OK"
;;
$DIALOG_CANCEL)
@@ -16,8 +16,12 @@ case $retval in
echo "Extra pressed";;
$DIALOG_ITEM_HELP)
echo "Item-help button pressed.";;
+ $DIALOG_TIMEOUT)
+ echo "Timeout expired.";;
$DIALOG_ERROR)
echo "ERROR!";;
$DIALOG_ESC)
echo "ESC pressed.";;
+ *)
+ echo "Return code was $returncode";;
esac
diff --git a/samples/report-string b/samples/report-string
index dc96c2fab2e2..e6ccb6433d2f 100644
--- a/samples/report-string
+++ b/samples/report-string
@@ -1,24 +1,28 @@
#!/bin/sh
-# $Id: report-string,v 1.3 2012/06/29 09:32:17 tom Exp $
-# Report result passed in a string $RESULT
+# $Id: report-string,v 1.8 2020/11/26 00:18:32 tom Exp $
+# Report result passed in a string $returntext
# vile:shmode
-case $retval in
+case ${returncode:-0} in
$DIALOG_OK)
- echo "Result is $RESULT";;
+ echo "Result is $returntext";;
$DIALOG_CANCEL)
echo "Cancel pressed.";;
$DIALOG_HELP)
- echo "Help pressed ($RESULT).";;
+ echo "Help pressed ($returntext).";;
$DIALOG_EXTRA)
echo "Extra button pressed.";;
$DIALOG_ITEM_HELP)
echo "Item-help button pressed.";;
+ $DIALOG_TIMEOUT)
+ echo "Timeout expired.";;
$DIALOG_ESC)
- if test -n "$RESULT" ; then
- echo "$RESULT"
+ if test -n "$returntext" ; then
+ echo "$returntext"
else
echo "ESC pressed."
fi
;;
+ *)
+ echo "Return code was $returncode";;
esac
diff --git a/samples/report-tempfile b/samples/report-tempfile
index 4c5f0994e8a6..c6f08c164523 100644
--- a/samples/report-tempfile
+++ b/samples/report-tempfile
@@ -1,24 +1,28 @@
#!/bin/sh
-# $Id: report-tempfile,v 1.5 2013/09/02 18:03:13 tom Exp $
+# $Id: report-tempfile,v 1.9 2020/11/26 00:18:32 tom Exp $
# Report results in a temporary-file.
# vile:shmode
-case $retval in
+case "${returncode:-0}" in
$DIALOG_OK)
- echo "Result: `cat $tempfile`";;
+ echo "Result: `cat "$tempfile"`";;
$DIALOG_CANCEL)
echo "Cancel pressed.";;
$DIALOG_HELP)
- echo "Help pressed: `cat $tempfile`";;
+ echo "Help pressed: `cat "$tempfile"`";;
$DIALOG_EXTRA)
echo "Extra button pressed.";;
$DIALOG_ITEM_HELP)
- echo "Item-help button pressed: `cat $tempfile`";;
+ echo "Item-help button pressed: `cat "$tempfile"`";;
+ $DIALOG_TIMEOUT)
+ echo "Timeout expired.";;
$DIALOG_ESC)
- if test -s $tempfile ; then
- cat $tempfile
+ if test -s "$tempfile" ; then
+ cat "$tempfile"
else
echo "ESC pressed."
fi
;;
+ *)
+ echo "Return code was $returncode";;
esac
diff --git a/samples/report-yesno b/samples/report-yesno
index d22ebe4194e2..cf15458e5782 100644
--- a/samples/report-yesno
+++ b/samples/report-yesno
@@ -1,9 +1,9 @@
#!/bin/sh
-# $Id: report-yesno,v 1.2 2012/06/29 09:32:12 tom Exp $
-# Report button-only, no $RESULT
+# $Id: report-yesno,v 1.7 2020/11/26 00:18:32 tom Exp $
+# Report button-only, no $returntext
# vile:shmode
-case $retval in
+case ${returncode:-0} in
$DIALOG_OK)
echo "YES";;
$DIALOG_CANCEL)
@@ -14,8 +14,12 @@ case $retval in
echo "Extra button pressed.";;
$DIALOG_ITEM_HELP)
echo "Item-help button pressed.";;
+ $DIALOG_TIMEOUT)
+ echo "Timeout expired.";;
$DIALOG_ERROR)
echo "ERROR!";;
$DIALOG_ESC)
echo "ESC pressed.";;
+ *)
+ echo "Return code was $returncode";;
esac
diff --git a/samples/rotated-data b/samples/rotated-data
index dc407144e7e3..28e3f650f753 100755
--- a/samples/rotated-data
+++ b/samples/rotated-data
@@ -1,12 +1,12 @@
#!/bin/sh
-# $Id: rotated-data,v 1.1 2004/12/19 16:43:47 tom Exp $
+# $Id: rotated-data,v 1.2 2019/12/10 23:59:24 tom Exp $
# Rotate the second parameter's data by the given shift count.
if test $# != 0
then
case $1 in
[1-9]*)
left=$1
- next=`expr $left + 1`
+ next=`expr "$left" + 1`
shift 1
;;
*)
@@ -17,7 +17,7 @@ then
char=`echo "$@" | cut -b -${left}`
data=`echo "$@" | cut -b ${next}-`
- printf "%s%s\n" $data $char
+ printf "%s%s\n" "$data" "$char"
else
echo
fi
diff --git a/samples/run_test.sh b/samples/run_test.sh
index ea9da2935293..2576d3e91f29 100755
--- a/samples/run_test.sh
+++ b/samples/run_test.sh
@@ -1,7 +1,7 @@
#!/bin/sh
-# $Id: run_test.sh,v 1.4 2017/02/01 01:50:09 tom Exp $
+# $Id: run_test.sh,v 1.5 2019/12/10 23:54:52 tom Exp $
# vile:ts=4 sw=4
-THIS=`basename $0`
+THIS=`basename "$0"`
if [ -z "$DIALOG" ]
then
@@ -43,14 +43,14 @@ do
[ -f "$name" ] || continue
[ -x "$name" ] || continue
# skip this script and known utility-scripts
- case `basename $name` in
+ case `basename "$name"` in
$THIS|dft-*|killall|listing|rotated-data|shortlist|with-*)
echo "** skipping $name" >>$mylog
continue
;;
esac
- rm -f trace $want.log $name.log
+ rm -f trace "$want.log" "$name.log"
echo "** running $name" >>$mylog
$name
- [ -f $want.log ] && cp $want.log $name.log
+ [ -f "$want.log" ] && cp "$want.log" "$name.log"
done
diff --git a/samples/setup-vars b/samples/setup-vars
index f0ea779c132e..6a6134b15ec7 100644
--- a/samples/setup-vars
+++ b/samples/setup-vars
@@ -1,23 +1,24 @@
#!/bin/sh
-# $Id: setup-vars,v 1.3 2012/06/29 09:52:26 tom Exp $
+# $Id: setup-vars,v 1.5 2020/11/25 23:06:52 tom Exp $
# vile:shmode
# These symbols are defined to use in the sample shell scripts to make them
# more readable. But they are (intentionally) not exported. If they were
# exported, they would also be visible in the dialog program (a subprocess).
-: ${DIALOG=dialog}
+: "${DIALOG=dialog}"
-: ${DIALOG_OK=0}
-: ${DIALOG_CANCEL=1}
-: ${DIALOG_HELP=2}
-: ${DIALOG_EXTRA=3}
-: ${DIALOG_ITEM_HELP=4}
-: ${DIALOG_ESC=255}
+: "${DIALOG_OK=0}"
+: "${DIALOG_CANCEL=1}"
+: "${DIALOG_HELP=2}"
+: "${DIALOG_EXTRA=3}"
+: "${DIALOG_ITEM_HELP=4}"
+: "${DIALOG_TIMEOUT=5}"
+: "${DIALOG_ESC=255}"
-: ${SIG_NONE=0}
-: ${SIG_HUP=1}
-: ${SIG_INT=2}
-: ${SIG_QUIT=3}
-: ${SIG_KILL=9}
-: ${SIG_TERM=15}
+: "${SIG_NONE=0}"
+: "${SIG_HUP=1}"
+: "${SIG_INT=2}"
+: "${SIG_QUIT=3}"
+: "${SIG_KILL=9}"
+: "${SIG_TERM=15}"
diff --git a/samples/tailbox b/samples/tailbox
index 227104e2fcfb..e67c30c08156 100755
--- a/samples/tailbox
+++ b/samples/tailbox
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: tailbox,v 1.7 2010/01/13 10:36:18 tom Exp $
+# $Id: tailbox,v 1.8 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -9,7 +9,7 @@
$DIALOG --title "TAIL BOX" "$@" \
--tailbox listing.out 24 70
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/tailboxbg b/samples/tailboxbg
index bcc3434d3473..dff1becf80a9 100755
--- a/samples/tailboxbg
+++ b/samples/tailboxbg
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: tailboxbg,v 1.10 2012/06/29 09:48:28 tom Exp $
+# $Id: tailboxbg,v 1.11 2019/12/11 01:21:36 tom Exp $
. ./setup-vars
@@ -16,7 +16,7 @@ $DIALOG --title "TAIL BOX" \
sleep 10
# now kill it
-kill -$SIG_QUIT `cat $tempfile` 2>&1 >/dev/null 2>/dev/null
+kill "-$SIG_QUIT" "`cat "$tempfile"`" 2>&1 >/dev/null 2>/dev/null
# ...and the process that is making the listing
./killall listing
diff --git a/samples/tailboxbg1 b/samples/tailboxbg1
index f04567a92f6d..456e720969e5 100755
--- a/samples/tailboxbg1
+++ b/samples/tailboxbg1
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: tailboxbg1,v 1.10 2012/06/29 09:51:46 tom Exp $
+# $Id: tailboxbg1,v 1.11 2019/12/11 00:12:27 tom Exp $
. ./setup-vars
@@ -18,13 +18,13 @@ $DIALOG --title "TAIL BOXES" \
# The --and-widget causes a tab to be emitted, but our example will only
# write one number to stderr.
-pid=`cat $tempfile |sed -e 's/ //g'`
+pid=`sed -e 's/ //g' $tempfile`
if test -n "$pid" ; then
# wait a while for the background process to run
sleep 10
# now kill it
-kill -$SIG_QUIT $pid 2>&1 >/dev/null 2>/dev/null
+kill "-$SIG_QUIT" "$pid "2>&1 >/dev/null 2>/dev/null
echo "killed [$pid]"
fi
diff --git a/samples/tailboxbg2 b/samples/tailboxbg2
index 628cb0571540..b71a6c6c42fe 100755
--- a/samples/tailboxbg2
+++ b/samples/tailboxbg2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: tailboxbg2,v 1.10 2012/06/29 09:51:11 tom Exp $
+# $Id: tailboxbg2,v 1.11 2019/12/11 00:11:51 tom Exp $
. ./setup-vars
@@ -19,13 +19,13 @@ $DIALOG --title "TAIL BOXES" \
# The --and-widget causes a tab to be emitted, but our example will only
# write one number to stderr.
-pid=`cat $tempfile |sed -e 's/ //g'`
+pid=`sed -e 's/ //g' $tempfile`
if test -n "$pid" ; then
# wait a while for the background process to run
sleep 10
# now kill it
-kill -$SIG_QUIT $pid 2>&1 >/dev/null 2>/dev/null
+kill "-$SIG_QUIT" "$pid" 2>&1 >/dev/null 2>/dev/null
echo "killed [$pid]"
fi
diff --git a/samples/testdata-8bit b/samples/testdata-8bit
index f09021dc19db..f09021dc19db 100755..100644
--- a/samples/testdata-8bit
+++ b/samples/testdata-8bit
diff --git a/samples/textbox b/samples/textbox
index d3c7698c85ee..136fb7f51ebf 100755
--- a/samples/textbox
+++ b/samples/textbox
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: textbox,v 1.12 2010/01/13 10:36:35 tom Exp $
+# $Id: textbox,v 1.14 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -35,10 +35,10 @@ EOF
TEXT=/usr/share/common-licenses/GPL
test -f $TEXT || TEXT=../COPYING
-cat $TEXT | expand >> $tempfile
+expand < $TEXT >> $tempfile
$DIALOG --clear --title "TEXT BOX" "$@" --textbox "$tempfile" 22 77
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/textbox-both b/samples/textbox-both
index 787515312037..d84faf9e4977 100755
--- a/samples/textbox-both
+++ b/samples/textbox-both
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: textbox-both,v 1.1 2011/01/18 09:59:47 tom Exp $
+# $Id: textbox-both,v 1.3 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -8,14 +8,14 @@
TEXT=/usr/share/common-licenses/GPL
test -f $TEXT || TEXT=../COPYING
-cat textbox.txt | expand > $tempfile
-cat $TEXT | expand >> $tempfile
+expand < textbox.txt > $tempfile
+expand < $TEXT >> $tempfile
$DIALOG --clear --title "TEXT BOX" \
--help-button \
--extra-button "$@" \
--textbox "$tempfile" 22 77
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/textbox-help b/samples/textbox-help
index cb30253111b8..450c728c2c51 100755
--- a/samples/textbox-help
+++ b/samples/textbox-help
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: textbox-help,v 1.1 2011/01/18 09:59:20 tom Exp $
+# $Id: textbox-help,v 1.3 2020/11/26 00:05:11 tom Exp $
. ./setup-vars
@@ -8,13 +8,13 @@
TEXT=/usr/share/common-licenses/GPL
test -f $TEXT || TEXT=../COPYING
-cat textbox.txt | expand > $tempfile
-cat $TEXT | expand >> $tempfile
+expand < textbox.txt > $tempfile
+expand < $TEXT >> $tempfile
$DIALOG --clear --title "TEXT BOX" \
--help-button "$@" \
--textbox "$tempfile" 22 77
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/textbox2 b/samples/textbox2
index 7c97de8cb38a..d4149b3c6095 100755
--- a/samples/textbox2
+++ b/samples/textbox2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: textbox2,v 1.8 2010/01/13 10:36:49 tom Exp $
+# $Id: textbox2,v 1.10 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -35,10 +35,10 @@ EOF
TEXT=/usr/share/common-licenses/GPL
test -f $TEXT || TEXT=../COPYING
-cat $TEXT | expand >> $tempfile
+expand < $TEXT >> $tempfile
$DIALOG --clear --title "TEXT BOX" "$@" --textbox "$tempfile" 0 0
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/textbox3 b/samples/textbox3
index 2c076e955563..f3d6f8249849 100755
--- a/samples/textbox3
+++ b/samples/textbox3
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: textbox3,v 1.6 2010/01/13 10:37:01 tom Exp $
+# $Id: textbox3,v 1.8 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -8,13 +8,13 @@
TEXT=/usr/share/common-licenses/GPL
test -f $TEXT || TEXT=../COPYING
-cat textbox.txt | expand > $tempfile
-cat $TEXT | expand >> $tempfile
+expand < textbox.txt > $tempfile
+expand < $TEXT >> $tempfile
$DIALOG --clear --title "TEXT BOX" \
--extra-button "$@" \
--textbox "$tempfile" 22 77
-retval=$?
+returncode=$?
. ./report-button
diff --git a/samples/timebox b/samples/timebox
index cb6bf5c6f4f1..de5b4377a7dd 100755
--- a/samples/timebox
+++ b/samples/timebox
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: timebox,v 1.9 2010/01/13 10:23:10 tom Exp $
+# $Id: timebox,v 1.11 2020/11/26 00:09:31 tom Exp $
. ./setup-vars
@@ -7,8 +7,8 @@ DIALOG_ERROR=254
export DIALOG_ERROR
exec 3>&1
-RESULT=`$DIALOG --title "TIMEBOX" "$@" --timebox "Please set the time..." 0 0 12 34 56 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "TIMEBOX" "$@" --timebox "Please set the time..." 0 0 12 34 56 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/timebox-stdout b/samples/timebox-stdout
index 10a00262bbd4..4ed0d9a23da7 100755
--- a/samples/timebox-stdout
+++ b/samples/timebox-stdout
@@ -1,10 +1,10 @@
#!/bin/sh
-# $Id: timebox-stdout,v 1.5 2010/01/13 10:37:19 tom Exp $
+# $Id: timebox-stdout,v 1.7 2020/11/26 00:09:31 tom Exp $
. ./setup-vars
-RESULT=`$DIALOG --stdout --title "TIMEBOX" "$@" --timebox "Please set the time..." 0 0 12 34 56`
+returntext=`$DIALOG --stdout --title "TIMEBOX" "$@" --timebox "Please set the time..." 0 0 12 34 56`
-retval=$?
+returncode=$?
. ./report-string
diff --git a/samples/timebox2 b/samples/timebox2
index 088acdff39b8..f734421b1cc4 100755
--- a/samples/timebox2
+++ b/samples/timebox2
@@ -1,11 +1,11 @@
#!/bin/sh
-# $Id: timebox2,v 1.7 2010/01/13 10:37:35 tom Exp $
+# $Id: timebox2,v 1.9 2020/11/26 00:09:31 tom Exp $
. ./setup-vars
exec 3>&1
-RESULT=`$DIALOG --title "TIMEBOX" "$@" --timebox "Please set the time..." 0 0 2>&1 1>&3`
-retval=$?
+returntext=`$DIALOG --title "TIMEBOX" "$@" --timebox "Please set the time..." 0 0 2>&1 1>&3`
+returncode=$?
exec 3>&-
. ./report-string
diff --git a/samples/timebox2-stdout b/samples/timebox2-stdout
index 922921fc2e2a..71a4fa443814 100755
--- a/samples/timebox2-stdout
+++ b/samples/timebox2-stdout
@@ -1,10 +1,10 @@
#!/bin/sh
-# $Id: timebox2-stdout,v 1.5 2010/01/13 10:37:55 tom Exp $
+# $Id: timebox2-stdout,v 1.7 2020/11/26 00:09:31 tom Exp $
. ./setup-vars
-RESULT=`$DIALOG --stdout --title "TIMEBOX" "$@" --timebox "Please set the time..." 0 0`
+returntext=`$DIALOG --stdout --title "TIMEBOX" "$@" --timebox "Please set the time..." 0 0`
-retval=$?
+returncode=$?
. ./report-string
diff --git a/samples/treeview b/samples/treeview
index 34212184d4de..fec3cddf9f69 100755
--- a/samples/treeview
+++ b/samples/treeview
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: treeview,v 1.2 2012/12/04 10:53:09 tom Exp $
+# $Id: treeview,v 1.3 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -17,6 +17,6 @@ $DIALOG --title "TREE VIEW DIALOG" \
tag8 eight off 4 \
tag9 nine off 1 2> $tempfile
-retval=$?
+returncode=$?
. ./report-tempfile
diff --git a/samples/treeview2 b/samples/treeview2
index b3dde4159483..ba5e948f5fa2 100755
--- a/samples/treeview2
+++ b/samples/treeview2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: treeview2,v 1.3 2012/12/23 22:28:00 tom Exp $
+# $Id: treeview2,v 1.5 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -44,9 +44,9 @@ EOF
$DIALOG --title "TREE VIEW DIALOG" \
--scrollbar \
- --treeview "TreeView demo" 0 0 10 `cat $input | sed -e 's/:/ /g'` 2> $output
+ --treeview "TreeView demo" 0 0 10 `sed -e 's/:/ /g' "$input"` 2> $output
-retval=$?
+returncode=$?
tempfile=$output
. ./report-tempfile
diff --git a/samples/treeview4 b/samples/treeview4
new file mode 100755
index 000000000000..4b1f65eef457
--- /dev/null
+++ b/samples/treeview4
@@ -0,0 +1,24 @@
+#!/bin/sh
+# $Id: treeview4,v 1.3 2020/11/26 00:05:52 tom Exp $
+
+. ./setup-vars
+
+. ./setup-tempfile
+
+$DIALOG --title "TREE VIEW DIALOG" \
+ --help-button \
+ --item-help \
+ --treeview "TreeView demo" 0 0 0 \
+ tag1 one off 0 first \
+ tag2 two off 1 second \
+ tag3 three on 2 third \
+ tag4 four off 1 fourth \
+ tag5 five off 2 fifth \
+ tag6 six off 3 sixth \
+ tag7 seven off 3 seventh \
+ tag8 eight off 4 eighth \
+ tag9 nine off 1 ninth 2> $tempfile
+
+returncode=$?
+
+. ./report-tempfile
diff --git a/samples/wheel b/samples/wheel
index 4adef26e8e09..13e084a405fc 100755
--- a/samples/wheel
+++ b/samples/wheel
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: wheel,v 1.8 2012/06/29 09:59:40 tom Exp $
+# $Id: wheel,v 1.10 2019/12/11 01:43:03 tom Exp $
. ./setup-vars
@@ -8,57 +8,58 @@
TITLE="This screen was taken from ComeOn Point Installer! v0.9 by ComeOn Linux!"
$DIALOG --print-maxsize 2>$tempfile
-ROWS="`cut $tempfile -f1 -d, | cut -f2 -d:`"
-COLS="`cut $tempfile -f2 -d,`"
+ROWS="`sed -e 's/^[^:]*:[ ]*//' -e 's/,.*//' $tempfile`"
+COLS="`sed -e 's/^[^,]*,[ ]*//' $tempfile`"
rm $tempfile
# account for widest labels
-COLS=`expr $COLS - 30`
+COLS=`expr "$COLS" - 30`
# Takes an integer, multiplies it for COLS, divides for 132
scalex() {
- expr $1 \* $COLS / 132
+ expr "$1" \* "$COLS" / 132
}
scaley() {
- expr $1 \* $ROWS / 60
+ expr "$1" \* "$ROWS" / 60
}
$DIALOG --backtitle "$TITLE" --no-shadow \
---begin `scaley 27` `scalex 98` --infobox "pushd /var/log >/dev/null" 0 0 --and-widget \
---begin `scaley 35` `scalex 95` --infobox "mkdir -p news -m 755" 0 0 --and-widget \
---begin `scaley 45` `scalex 86` --infobox "chown news.news news" 0 0 --and-widget \
---begin `scaley 48` `scalex 78` --infobox "cd /var/log/news" 0 0 --and-widget \
---begin `scaley 51` `scalex 61` --infobox "mkdir -p OLD -m 755" 0 0 --and-widget \
---begin `scaley 52` `scalex 47` --infobox "chown news.news OLD" 0 0 --and-widget \
---begin `scaley 51` `scalex 40` --infobox "cd /var/spool" 0 0 --and-widget \
---begin `scaley 48` `scalex 25` --infobox "mkdir -p news -m 775" 0 0 --and-widget \
---begin `scaley 42` `scalex 13` --infobox "chown news.news news" 0 0 --and-widget \
---begin `scaley 35` `scalex 4` --infobox "cd /var/spool/news" 0 0 --and-widget \
---begin `scaley 27` `scalex 2` --infobox "CURMASK=`umask`" 0 0 --and-widget \
---begin `scaley 19` `scalex 4` --infobox "umask 02" 0 0 --and-widget \
---begin `scaley 11` `scalex 13` --infobox "mkdir -p out.going control junk in.coming" 0 0 --and-widget \
---begin `scaley 5` `scalex 25` --infobox "chown news.news out.going control junk in.coming" 0 0 --and-widget \
---begin `scaley 2` `scalex 37` --infobox "cd in.coming" 0 0 --and-widget \
---begin `scaley 1` `scalex 46` --infobox "mkdir -p bad tmp" 0 0 --and-widget \
---begin `scaley 2` `scalex 61` --infobox "chown news.news bad tmp" 0 0 --and-widget \
---begin `scaley 5` `scalex 76` --infobox "umask $CURMASK" 0 0 --and-widget \
---begin `scaley 11` `scalex 87` --infobox "ln -sf ~news /usr/local/lib/" 0 0 --and-widget \
---begin `scaley 18` `scalex 95` --infobox "ln -sf ~news/inews /usr/bin/" 0 0 --and-widget \
---begin `scaley 26` `scalex 97` --infobox "chmod 1777 /var/tmp" 0 0 --and-widget \
---begin `scaley 34` `scalex 95` --infobox "cd ~news" 0 0 --and-widget \
---begin `scaley 42` `scalex 87` --infobox "touch history history.dir history.pag errlog log" 0 0 --and-widget \
---begin `scaley 47` `scalex 76` --infobox "chown news.news history* log errlog" 0 0 --and-widget \
+--begin "`scaley 27`" "`scalex 98`" --infobox "pushd /var/log >/dev/null" 0 0 --and-widget \
+--begin "`scaley 35`" "`scalex 95`" --infobox "mkdir -p news -m 755" 0 0 --and-widget \
+--begin "`scaley 45`" "`scalex 86`" --infobox "chown news.news news" 0 0 --and-widget \
+--begin "`scaley 48`" "`scalex 78`" --infobox "cd /var/log/news" 0 0 --and-widget \
+--begin "`scaley 51`" "`scalex 61`" --infobox "mkdir -p OLD -m 755" 0 0 --and-widget \
+--begin "`scaley 52`" "`scalex 47`" --infobox "chown news.news OLD" 0 0 --and-widget \
+--begin "`scaley 51`" "`scalex 40`" --infobox "cd /var/spool" 0 0 --and-widget \
+--begin "`scaley 48`" "`scalex 25`" --infobox "mkdir -p news -m 775" 0 0 --and-widget \
+--begin "`scaley 42`" "`scalex 13`" --infobox "chown news.news news" 0 0 --and-widget \
+--begin "`scaley 35`" "`scalex 4`" --infobox "cd /var/spool/news" 0 0 --and-widget \
+--begin "`scaley 27`" "`scalex 2`" --infobox "CURMASK=`umask`" 0 0 --and-widget \
+--begin "`scaley 19`" "`scalex 4`" --infobox "umask 02" 0 0 --and-widget \
+--begin "`scaley 11`" "`scalex 13`" --infobox "mkdir -p out.going control junk in.coming" 0 0 --and-widget \
+--begin "`scaley 5`" "`scalex 25`" --infobox "chown news.news out.going control junk in.coming" 0 0 --and-widget \
+--begin "`scaley 2`" "`scalex 37`" --infobox "cd in.coming" 0 0 --and-widget \
+--begin "`scaley 1`" "`scalex 46`" --infobox "mkdir -p bad tmp" 0 0 --and-widget \
+--begin "`scaley 2`" "`scalex 61`" --infobox "chown news.news bad tmp" 0 0 --and-widget \
+--begin "`scaley 5`" "`scalex 76`" --infobox "umask $CURMASK" 0 0 --and-widget \
+--begin "`scaley 11`" "`scalex 87`" --infobox "ln -sf ~news /usr/local/lib/" 0 0 --and-widget \
+--begin "`scaley 18`" "`scalex 95`" --infobox "ln -sf ~news/inews /usr/bin/" 0 0 --and-widget \
+--begin "`scaley 26`" "`scalex 97`" --infobox "chmod 1777 /var/tmp" 0 0 --and-widget \
+--begin "`scaley 34`" "`scalex 95`" --infobox "cd ~news" 0 0 --and-widget \
+--begin "`scaley 42`" "`scalex 87`" --infobox "touch history history.dir history.pag errlog log" 0 0 --and-widget \
+--begin "`scaley 47`" "`scalex 76`" --infobox "chown news.news history* log errlog" 0 0 --and-widget \
--infobox "Creating spooling and logging directories and files..." 0 0 --and-widget \
---begin `scaley 51` `scalex 78` --infobox "chmod 664 history* log errlog" 0 0 --and-widget \
---begin `scaley 52` `scalex 60` --infobox "echo \"control 0000000000 0000000001 y\" > active" 0 0 --and-widget \
---begin `scaley 51` `scalex 42` --infobox "echo \"junk 0000000000 0000000001 y\" >> active" 0 0 --and-widget \
---begin `scaley 48` `scalex 26` --infobox "chown news.news active" 0 0 --and-widget \
---begin `scaley 42` `scalex 13` --infobox "echo \"control 814573260 usenet\" > active.times" 0 0 --and-widget \
---begin `scaley 35` `scalex 4` --infobox "echo \"junk 814573260 usenet\" >> active.times" 0 0 --and-widget \
---begin `scaley 27` `scalex 2` --infobox "chown news.news active.times" 0 0 --and-widget \
---begin `scaley 19` `scalex 4` --infobox ":>newsgroups" 0 0 --and-widget \
---begin `scaley 11` `scalex 12` --infobox "chown news.news newsgroups" 0 0 --and-widget \
---sleep 2 --begin `scaley 6` `scalex 25` --infobox "popd >/dev/null" 0 0 --and-widget \
+--begin "`scaley 51`" "`scalex 78`" --infobox "chmod 664 history* log errlog" 0 0 --and-widget \
+--begin "`scaley 52`" "`scalex 60`" --infobox "echo \"control 0000000000 0000000001 y\" > active" 0 0 --and-widget \
+--begin "`scaley 51`" "`scalex 42`" --infobox "echo \"junk 0000000000 0000000001 y\" >> active" 0 0 --and-widget \
+--begin "`scaley 48`" "`scalex 26`" --infobox "chown news.news active" 0 0 --and-widget \
+--begin "`scaley 42`" "`scalex 13`" --infobox "echo \"control 814573260 usenet\" > active.times" 0 0 --and-widget \
+--begin "`scaley 35`" "`scalex 4`" --infobox "echo \"junk 814573260 usenet\" >> active.times" 0 0 --and-widget \
+--begin "`scaley 27`" "`scalex 2`" --infobox "chown news.news active.times" 0 0 --and-widget \
+--begin "`scaley 19`" "`scalex 4`" --infobox ":>newsgroups" 0 0 --and-widget \
+--begin "`scaley 11`" "`scalex 12`" --infobox "chown news.news newsgroups" 0 0 --and-widget \
+--sleep 2 \
+--begin "`scaley 6`" "`scalex 25`" --infobox "popd >/dev/null" 0 0 --and-widget \
--beep --msgbox "ComeOn Linux! :-)" 0 0 --and-widget \
--begin 2 0 --title "/var/adm/debug. This is running while that down runs also" --tailboxbg /var/adm/debug 6 80 --and-widget \
--begin 8 0 --title "/var/adm/messages. It tails the file in multitasking with /var/adm/debug" --tailbox /var/adm/messages -1 -1
diff --git a/samples/yesno b/samples/yesno
index fa1ea444ce4b..917c0ae3d30c 100755
--- a/samples/yesno
+++ b/samples/yesno
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: yesno,v 1.9 2010/01/14 01:11:11 tom Exp $
+# $Id: yesno,v 1.10 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -16,6 +16,6 @@ $DIALOG --title "YES/NO BOX" --clear "$@" \
auto wrap around will be disabled and you will have to \
control line breaking yourself." 15 61
-retval=$?
+returncode=$?
. ./report-yesno
diff --git a/samples/yesno-both b/samples/yesno-both
index a408bdba4b54..b2cb504167ef 100755
--- a/samples/yesno-both
+++ b/samples/yesno-both
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: yesno-both,v 1.5 2010/01/13 10:40:39 tom Exp $
+# $Id: yesno-both,v 1.6 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -19,6 +19,6 @@ $DIALOG --title "YES/NO/MAYBE BOX" \
auto wrap around will be disabled and you will have to \
control line breaking yourself." 15 61
-retval=$?
+returncode=$?
. ./report-yesno
diff --git a/samples/yesno-extra b/samples/yesno-extra
index ce31b8107941..d01b74a16182 100755
--- a/samples/yesno-extra
+++ b/samples/yesno-extra
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: yesno-extra,v 1.5 2010/01/13 10:40:39 tom Exp $
+# $Id: yesno-extra,v 1.6 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -18,6 +18,6 @@ $DIALOG --title "YES/NO/MAYBE BOX" \
auto wrap around will be disabled and you will have to \
control line breaking yourself." 15 61
-retval=$?
+returncode=$?
. ./report-yesno
diff --git a/samples/yesno-help b/samples/yesno-help
index 1333f1cbc09e..1b0a816df940 100755
--- a/samples/yesno-help
+++ b/samples/yesno-help
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: yesno-help,v 1.5 2010/01/13 10:40:39 tom Exp $
+# $Id: yesno-help,v 1.6 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -13,6 +13,6 @@ $DIALOG --title "YES/NO BOX" --clear --help-button "$@" \
auto wrap around will be disabled and you will have to \
control line breaking yourself." 15 61
-retval=$?
+returncode=$?
. ./report-yesno
diff --git a/samples/yesno-utf8 b/samples/yesno-utf8
index 4a6be30eb801..a10eba7605bc 100755
--- a/samples/yesno-utf8
+++ b/samples/yesno-utf8
@@ -1,5 +1,5 @@
#! /bin/sh
-# $Id: yesno-utf8,v 1.7 2010/01/14 01:11:23 tom Exp $
+# $Id: yesno-utf8,v 1.8 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -9,6 +9,6 @@ DIALOG_ERROR=254
export DIALOG_ERROR
$DIALOG "$@" --yesno "Are you a DOG?" 0 0
-retval=$?
+returncode=$?
. ./report-yesno
diff --git a/samples/yesno2 b/samples/yesno2
index d022352e6308..ba4e7f4e0fc2 100755
--- a/samples/yesno2
+++ b/samples/yesno2
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: yesno2,v 1.7 2010/01/13 10:40:39 tom Exp $
+# $Id: yesno2,v 1.8 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -13,6 +13,6 @@ also control line breaking explicitly by inserting \
auto wrap around will be disabled and you will have to \
control line breaking yourself." 0 0
-retval=$?
+returncode=$?
. ./report-yesno
diff --git a/samples/yesno3 b/samples/yesno3
index f67fb85b600f..336c41c90670 100755
--- a/samples/yesno3
+++ b/samples/yesno3
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: yesno3,v 1.6 2010/01/13 10:40:39 tom Exp $
+# $Id: yesno3,v 1.7 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -13,6 +13,6 @@ also control line breaking explicitly by inserting \
auto wrap around will be disabled and you will have to \
control line breaking yourself." 0 0
-retval=$?
+returncode=$?
. ./report-yesno
diff --git a/samples/yesno4 b/samples/yesno4
index 99f65e86125e..4c54160d0043 100755
--- a/samples/yesno4
+++ b/samples/yesno4
@@ -1,5 +1,5 @@
#!/bin/sh
-# $Id: yesno4,v 1.1 2010/01/14 10:26:40 tom Exp $
+# $Id: yesno4,v 1.2 2020/11/26 00:05:52 tom Exp $
. ./setup-vars
@@ -13,6 +13,6 @@ also control line breaking explicitly by inserting \
auto wrap around will be disabled and you will have to \
control line breaking yourself." 6 30
-retval=$?
+returncode=$?
. ./report-yesno
diff --git a/tailbox.c b/tailbox.c
index 137355b252ef..a6a505f6a332 100644
--- a/tailbox.c
+++ b/tailbox.c
@@ -1,9 +1,9 @@
/*
- * $Id: tailbox.c,v 1.72 2018/06/19 22:57:01 tom Exp $
+ * $Id: tailbox.c,v 1.79 2020/11/21 21:31:49 tom Exp $
*
* tailbox.c -- implements the tail box
*
- * Copyright 2000-2012,2018 Thomas E. Dickey
+ * Copyright 2000-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -104,12 +104,6 @@ static void
last_lines(MY_OBJ * obj, int target)
{
FILE *fp = obj->obj.input;
- size_t inx;
- int count = 0;
- char buf[BUFSIZ + 1];
- size_t size_to_read;
- size_t size_as_read;
- long offset = 0;
long fpos = 0;
if (fseek(fp, 0L, SEEK_END) == -1
@@ -117,8 +111,16 @@ last_lines(MY_OBJ * obj, int target)
dlg_exiterr("Error moving file pointer in last_lines().");
if (fpos != 0) {
+ long offset = 0;
+
++target;
for (;;) {
+ size_t inx;
+ size_t size_to_read;
+ size_t size_as_read;
+ int count = 0;
+ char buf[BUFSIZ + 1];
+
if (fpos >= BUFSIZ) {
size_to_read = BUFSIZ;
} else {
@@ -261,7 +263,16 @@ handle_my_getc(DIALOG_CALLBACK * cb, int ch, int fkey, int *result)
obj->hscroll += 1;
break;
default:
- beep();
+ if (is_DLGK_MOUSE(ch)) {
+ *result = dlg_ok_buttoncode(ch - M_EVENT);
+ if (*result != DLG_EXIT_ERROR) {
+ done = TRUE;
+ } else {
+ beep();
+ }
+ } else {
+ beep();
+ }
break;
}
if ((obj->hscroll != obj->old_hscroll))
@@ -320,7 +331,7 @@ dialog_tailbox(const char *title,
int old_width = width;
#endif
int fkey;
- int x, y, result, thigh;
+ int x, y, result = DLG_EXIT_UNKNOWN, thigh;
WINDOW *dialog, *text;
const char **buttons = 0;
MY_OBJ *obj;
@@ -383,7 +394,7 @@ dialog_tailbox(const char *title,
obj->obj.handle_getc = handle_my_getc;
obj->obj.handle_input = bg_task ? handle_input : 0;
obj->obj.keep_bg = bg_task && dialog_vars.cant_kill;
- obj->obj.bg_task = bg_task;
+ obj->obj.bg_task = (bool) bg_task;
obj->text = text;
obj->buttons = buttons;
dlg_add_callback(&(obj->obj));
@@ -401,7 +412,7 @@ dialog_tailbox(const char *title,
} else {
int ch;
do {
- ch = dlg_getc(dialog, &fkey);
+ ch = dlg_mouse_wgetch(dialog, &fkey);
#ifdef KEY_RESIZE
if (fkey && ch == KEY_RESIZE) {
dlg_will_resize(dialog);
@@ -409,10 +420,7 @@ dialog_tailbox(const char *title,
height = old_height;
width = old_width;
/* repaint */
- dlg_clear();
- dlg_del_window(dialog);
- refresh();
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
dlg_button_layout(buttons, &min_width);
goto retry;
}
diff --git a/textbox.c b/textbox.c
index eb06eecf3721..ed1405097e74 100644
--- a/textbox.c
+++ b/textbox.c
@@ -1,9 +1,9 @@
/*
- * $Id: textbox.c,v 1.117 2018/06/19 22:57:01 tom Exp $
+ * $Id: textbox.c,v 1.127 2021/01/17 22:19:19 tom Exp $
*
* textbox.c -- implements the text box
*
- * Copyright 2000-2017,2018 Thomas E. Dickey
+ * Copyright 2000-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -127,14 +127,14 @@ xalloc(size_t size)
static void
read_high(MY_OBJ * obj, size_t size_read)
{
- char *buftab, ch;
- int i = 0, j, n, tmpint;
- long begin_line;
+ char *buftab;
/* Allocate space for read buffer */
buftab = xalloc(size_read + 1);
if ((obj->fd_bytes_read = read(obj->fd, buftab, size_read)) != -1) {
+ int j;
+ long begin_line;
buftab[obj->fd_bytes_read] = '\0'; /* mark end of valid data */
@@ -179,19 +179,28 @@ read_high(MY_OBJ * obj, size_t size_read)
j = 0;
begin_line = 0;
- while (j < obj->fd_bytes_read)
- if (((ch = buftab[j++]) == TAB) && (dialog_vars.tab_correct != 0)) {
- tmpint = (dialog_state.tab_len
- - ((int) ((long) i - begin_line) % dialog_state.tab_len));
- for (n = 0; n < tmpint; n++)
- obj->buf[i++] = ' ';
- } else {
- if (ch == '\n')
- begin_line = i + 1;
- obj->buf[i++] = ch;
+ if (obj->buf != NULL) {
+ int i = 0;
+
+ while (j < obj->fd_bytes_read) {
+ char ch;
+
+ if (((ch = buftab[j++]) == TAB)
+ && (dialog_vars.tab_correct != 0)) {
+ int n;
+ int tmpint = (dialog_state.tab_len
+ - ((int) ((long) i - begin_line) % dialog_state.tab_len));
+ for (n = 0; n < tmpint; n++)
+ obj->buf[i++] = ' ';
+ } else {
+ if (ch == '\n')
+ begin_line = i + 1;
+ obj->buf[i++] = ch;
+ }
}
- obj->buf[i] = '\0'; /* mark end of valid data */
+ obj->buf[i] = '\0'; /* mark end of valid data */
+ }
}
if (obj->bytes_read == -1)
@@ -202,17 +211,19 @@ read_high(MY_OBJ * obj, size_t size_read)
static long
find_first(MY_OBJ * obj, char *buffer, long length)
{
- long recount = obj->page_length;
long result = 0;
- while (length > 0) {
- if (buffer[length] == '\n') {
- if (--recount < 0) {
- result = length;
- break;
+ if (buffer != NULL) {
+ long recount = obj->page_length;
+ while (length > 0) {
+ if (buffer[length] == '\n') {
+ if (--recount < 0) {
+ result = length;
+ break;
+ }
}
+ --length;
}
- --length;
}
return result;
}
@@ -269,30 +280,31 @@ static char *
get_line(MY_OBJ * obj)
{
int i = 0;
- long fpos;
obj->end_reached = FALSE;
- while (obj->buf[obj->in_buf] != '\n') {
- if (obj->buf[obj->in_buf] == '\0') { /* Either end of file or end of buffer reached */
- fpos = ftell_obj(obj);
-
- if (fpos < obj->file_size) { /* Not end of file yet */
- /* We've reached end of buffer, but not end of file yet, so
- * read next part of file into buffer
- */
- read_high(obj, BUF_SIZE);
- obj->in_buf = 0;
- } else {
- if (!obj->end_reached)
- obj->end_reached = TRUE;
- break;
+ if (obj->buf != NULL) {
+ while (obj->buf[obj->in_buf] != '\n') {
+ if (obj->buf[obj->in_buf] == '\0') { /* Either end of file or end of buffer reached */
+ long fpos = ftell_obj(obj);
+
+ if (fpos < obj->file_size) { /* Not end of file yet */
+ /* We've reached end of buffer, but not end of file yet, so
+ * read next part of file into buffer
+ */
+ read_high(obj, BUF_SIZE);
+ obj->in_buf = 0;
+ } else {
+ if (!obj->end_reached)
+ obj->end_reached = TRUE;
+ break;
+ }
+ } else if (i < MAX_LEN)
+ obj->line[i++] = obj->buf[obj->in_buf++];
+ else {
+ if (i == MAX_LEN) /* Truncate lines longer than MAX_LEN characters */
+ obj->line[i++] = '\0';
+ obj->in_buf++;
}
- } else if (i < MAX_LEN)
- obj->line[i++] = obj->buf[obj->in_buf++];
- else {
- if (i == MAX_LEN) /* Truncate lines longer than MAX_LEN characters */
- obj->line[i++] = '\0';
- obj->in_buf++;
}
}
if (i <= MAX_LEN)
@@ -357,7 +369,10 @@ back_lines(MY_OBJ * obj, long n)
}
}
obj->in_buf--;
- if (obj->buf[obj->in_buf] != '\n')
+ if (obj->buf == NULL
+ || obj->in_buf < 0
+ || obj->in_buf >= obj->bytes_read
+ || obj->buf[obj->in_buf] != '\n')
/* Something's wrong... */
dlg_exiterr("Internal error in back_lines().");
}
@@ -571,16 +586,17 @@ static bool
perform_search(MY_OBJ * obj, int height, int width, int key, char *search_term)
{
int dir;
- long tempinx;
- long fpos;
- int result;
- bool found;
- bool temp, temp1;
bool moved = FALSE;
/* set search direction */
dir = (key == '/' || key == 'n') ? 1 : 0;
if (dir ? !obj->end_reached : !obj->begin_reached) {
+ long tempinx;
+ long fpos;
+ int result;
+ bool found;
+ bool temp, temp1;
+
if (key == 'n' || key == 'N') {
if (search_term[0] == '\0') { /* No search term yet */
(void) beep();
@@ -597,6 +613,8 @@ perform_search(MY_OBJ * obj, int height, int width, int key, char *search_term)
ungetch(KEY_RESIZE);
/* FALLTHRU */
}
+#else
+ (void) result;
#endif
/* ESC pressed, or no search term, reprint page to clear box */
dlg_attrset(obj->text, dialog_attr);
@@ -698,9 +716,9 @@ dialog_textbox(const char *title, const char *filename, int height, int width)
#endif
long fpos;
int x, y, cur_x, cur_y;
- int key = 0, fkey;
+ int key, fkey;
int next = 0;
- int i, code, passed_end;
+ int i, passed_end;
char search_term[MAX_LEN + 1];
MY_OBJ obj;
WINDOW *dialog;
@@ -773,6 +791,7 @@ dialog_textbox(const char *title, const char *filename, int height, int width)
dlg_attr_clear(obj.text, PAGE_LENGTH, PAGE_WIDTH, dialog_attr);
while (result == DLG_EXIT_UNKNOWN) {
+ int code;
/*
* Update the screen according to whether we shifted up/down by a line
@@ -820,8 +839,10 @@ dialog_textbox(const char *title, const char *filename, int height, int width)
next = 0; /* ...but not scroll by a line */
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_ok_button_key(result, &button, &key, &fkey))
+ break;
+ }
if (!fkey && (code = dlg_char_to_button(key, obj.buttons)) >= 0) {
result = dlg_ok_buttoncode(code);
@@ -858,10 +879,10 @@ dialog_textbox(const char *title, const char *filename, int height, int width)
FALSE, width);
break;
case DLGK_ENTER:
- if (dialog_vars.nook)
- result = DLG_EXIT_OK;
- else
- result = dlg_exit_buttoncode(button);
+ result = dlg_enter_buttoncode(button);
+ break;
+ case DLGK_LEAVE:
+ result = dlg_ok_buttoncode(button);
break;
case DLGK_PAGE_FIRST:
if (!obj.begin_reached) {
@@ -954,9 +975,7 @@ dialog_textbox(const char *title, const char *filename, int height, int width)
width = old_width;
back_lines(&obj, obj.page_length);
/* repaint */
- dlg_clear();
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
goto retry;
#endif
}
@@ -975,6 +994,7 @@ dialog_textbox(const char *title, const char *filename, int height, int width)
}
}
}
+ dlg_add_last_key(-1);
dlg_del_window(dialog);
free(obj.buf);
diff --git a/timebox.c b/timebox.c
index 288e76735d24..73b057ada815 100644
--- a/timebox.c
+++ b/timebox.c
@@ -1,9 +1,9 @@
/*
- * $Id: timebox.c,v 1.59 2018/06/19 22:57:01 tom Exp $
+ * $Id: timebox.c,v 1.69 2020/11/23 09:04:00 tom Exp $
*
* timebox.c -- implements the timebox dialog
*
- * Copyright 2001-2016,2018 Thomas E. Dickey
+ * Copyright 2001-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -21,7 +21,7 @@
* Boston, MA 02110, USA.
*/
-#include <dialog.h>
+#include <dlg_internals.h>
#include <dlg_keys.h>
#include <time.h>
@@ -105,12 +105,11 @@ init_object(BOX * data,
data->period = period;
data->value = value % period;
- data->window = derwin(data->parent,
- data->height, data->width,
- data->y, data->x);
+ data->window = dlg_der_window(data->parent,
+ data->height, data->width,
+ data->y, data->x);
if (data->window == 0)
return -1;
- (void) keypad(data->window, TRUE);
dlg_mouse_setbase(getbegx(parent), getbegy(parent));
dlg_mouse_mkregion(y, x, height, width, code);
@@ -176,11 +175,11 @@ dialog_timebox(const char *title,
int old_width = width;
#endif
BOX hr_box, mn_box, sc_box;
- int key = 0, key2, fkey;
+ int key, fkey;
int button;
int result = DLG_EXIT_UNKNOWN;
WINDOW *dialog;
- time_t now_time = time((time_t *) 0);
+ time_t now_time;
struct tm current;
int state = dlg_default_button();
const char **buttons = dlg_ok_labels();
@@ -210,11 +209,8 @@ dialog_timebox(const char *title,
#endif
prompt = dlg_strclone(subtitle);
- dlg_auto_size(title, prompt, &height, &width, 0, 0);
+ dlg_auto_size(title, prompt, &height, &width, MIN_HIGH, MIN_WIDE);
- height += MIN_HIGH;
- if (width < MIN_WIDE)
- width = MIN_WIDE;
dlg_button_layout(buttons, &width);
dlg_print_size(height, width);
dlg_ctl_size(height, width);
@@ -289,6 +285,7 @@ dialog_timebox(const char *title,
BOX *obj = (state == sHR ? &hr_box
: (state == sMN ? &mn_box :
(state == sSC ? &sc_box : 0)));
+ int key2;
button = (state < 0) ? 0 : state;
dlg_draw_buttons(dialog, height - 2, 0, buttons, button, FALSE, width);
@@ -296,8 +293,10 @@ dialog_timebox(const char *title,
dlg_set_focus(dialog, obj->window);
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
if ((key2 = dlg_char_to_button(key, buttons)) >= 0) {
result = key2;
@@ -316,6 +315,9 @@ dialog_timebox(const char *title,
break;
case DLGK_TOGGLE:
case DLGK_ENTER:
+ result = dlg_enter_buttoncode(button);
+ break;
+ case DLGK_LEAVE:
result = dlg_ok_buttoncode(button);
break;
case DLGK_FIELD_PREV:
@@ -361,9 +363,7 @@ dialog_timebox(const char *title,
second = sc_box.value;
/* repaint */
free(prompt);
- dlg_clear();
- dlg_del_window(dialog);
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
goto retry;
#endif
default:
@@ -394,7 +394,7 @@ dialog_timebox(const char *title,
beep();
}
}
- } else {
+ } else if (key > 0) {
beep();
}
}
@@ -424,8 +424,7 @@ dialog_timebox(const char *title,
DefaultFormat(buffer, hr_box);
dlg_add_result(buffer);
- dlg_add_separator();
- dlg_add_last_key(-1);
+ AddLastKey();
return CleanupResult(result, dialog, prompt, &save_vars);
}
diff --git a/trace.c b/trace.c
index 067288e775b5..e564d58b327f 100644
--- a/trace.c
+++ b/trace.c
@@ -1,12 +1,13 @@
/*
- * $Id: trace.c,v 1.26 2018/06/13 00:06:48 tom Exp $
+ * $Id: trace.c,v 1.33 2020/11/23 23:32:43 tom Exp $
*
* trace.c -- implements screen-dump and keystroke-logging
*
- * Copyright 2007-2017,2018 Thomas E. Dickey
+ * Copyright 2007-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
+ * as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -41,7 +42,7 @@ dlg_trace_time(const char *tag)
}
void
-dlg_trace_msg(const char *fmt,...)
+dlg_trace_msg(const char *fmt, ...)
{
if (myFP != 0) {
va_list ap;
@@ -53,16 +54,26 @@ dlg_trace_msg(const char *fmt,...)
}
void
+dlg_trace_va_msg(const char *fmt, va_list ap)
+{
+ if (myFP != 0) {
+ vfprintf(myFP, fmt, ap);
+ fflush(myFP);
+ }
+}
+
+void
dlg_trace_2s(const char *name, const char *value)
{
bool first = TRUE;
- const char *next;
int left, right = 0;
if (value == 0)
value = "<NULL>";
while (value[right] != '\0') {
+ const char *next;
+
value += right;
if ((next = strchr(value, '\n')) != 0) {
left = (int) (next - value);
@@ -73,9 +84,9 @@ dlg_trace_2s(const char *name, const char *value)
}
if (first) {
first = FALSE;
- dlg_trace_msg("#%14s=%.*s\n", name, left, value);
+ dlg_trace_msg("#%14s = %.*s\n", name, left, value);
} else {
- dlg_trace_msg("#+\t\t%.*s\n", left, value);
+ dlg_trace_msg("#+%13s%.*s\n", " ", left, value);
}
}
}
@@ -83,15 +94,13 @@ dlg_trace_2s(const char *name, const char *value)
void
dlg_trace_2n(const char *name, int value)
{
- dlg_trace_msg("#\t%7s=%d\n", name, value);
+ dlg_trace_msg("#%14s = %d\n", name, value);
}
void
dlg_trace_win(WINDOW *win)
{
if (myFP != 0) {
- int y, x;
- int j, k;
WINDOW *top = wgetparent(win);
while (top != 0 && top != stdscr) {
@@ -103,6 +112,8 @@ dlg_trace_win(WINDOW *win)
int rc = getmaxy(win);
int cc = getmaxx(win);
chtype ch, c2;
+ int y, x;
+ int j, k;
fprintf(myFP, "window %dx%d at %d,%d\n",
rc, cc, getbegy(win), getbegx(win));
@@ -124,7 +135,7 @@ dlg_trace_win(WINDOW *win)
buffer[1] = '\0';
} else {
cchar_t cch;
- wchar_t *uc;
+ const wchar_t *uc;
if (win_wch(win, &cch) == ERR
|| (uc = wunctrl((&cch))) == 0
@@ -220,6 +231,7 @@ dlg_trace_chr(int ch, int fkey)
CASE(DLGK_HELPFILE);
CASE(DLGK_TRACE);
CASE(DLGK_TOGGLE);
+ CASE(DLGK_LEAVE);
}
}
} else if (ch == ERR) {
diff --git a/treeview.c b/treeview.c
index 934761ee2049..9853a16f539a 100644
--- a/treeview.c
+++ b/treeview.c
@@ -1,9 +1,9 @@
/*
- * $Id: treeview.c,v 1.32 2018/06/19 22:57:01 tom Exp $
+ * $Id: treeview.c,v 1.43 2020/11/23 00:38:31 tom Exp $
*
* treeview.c -- implements the treeview dialog
*
- * Copyright 2012-2016,2018 Thomas E. Dickey
+ * Copyright 2012-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -21,7 +21,7 @@
* Boston, MA 02110, USA.
*/
-#include <dialog.h>
+#include <dlg_internals.h>
#include <dlg_keys.h>
#define INDENT 3
@@ -196,12 +196,11 @@ dlg_treeview(const char *title,
#endif
ALL_DATA all;
int i, j, key2, found, x, y, cur_y, box_x, box_y;
- int key = 0, fkey;
+ int key, fkey;
int button = dialog_state.visit_items ? -1 : dlg_default_button();
int choice = dlg_default_listitem(items);
int scrollamt = 0;
int max_choice;
- int was_mouse;
int use_height;
int use_width, name_width, text_width, tree_width;
int result = DLG_EXIT_UNKNOWN;
@@ -291,8 +290,7 @@ dlg_treeview(const char *title,
* After displaying the prompt, we know how much space we really have.
* Limit the list to avoid overwriting the ok-button.
*/
- if (use_height + MIN_HIGH > height - cur_y)
- use_height = height - MIN_HIGH - cur_y;
+ use_height = height - MIN_HIGH - cur_y;
if (use_height <= 0)
use_height = 1;
@@ -357,13 +355,18 @@ dlg_treeview(const char *title,
dlg_draw_buttons(dialog, height - 2, 0, buttons, button, FALSE, width);
dlg_trace_win(dialog);
+
while (result == DLG_EXIT_UNKNOWN) {
+ int was_mouse;
+
if (button < 0) /* --visit-items */
wmove(dialog, box_y + choice + 1, box_x + all.check_x + 2);
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
was_mouse = (fkey && is_DLGK_MOUSE(key));
if (was_mouse)
@@ -520,6 +523,9 @@ dlg_treeview(const char *title,
case DLGK_ENTER:
result = dlg_enter_buttoncode(button);
break;
+ case DLGK_LEAVE:
+ result = dlg_ok_buttoncode(button);
+ break;
case DLGK_FIELD_PREV:
button = dlg_prev_button(buttons, button);
dlg_draw_buttons(dialog, height - 2, 0, buttons, button,
@@ -537,10 +543,7 @@ dlg_treeview(const char *title,
height = old_height;
width = old_width;
/* repaint */
- dlg_clear();
- dlg_del_window(dialog);
- refresh();
- dlg_mouse_free_regions();
+ _dlg_resize_cleanup(dialog);
goto retry;
#endif
default:
@@ -552,7 +555,7 @@ dlg_treeview(const char *title,
beep();
}
}
- } else {
+ } else if (key > 0) {
beep();
}
}
@@ -649,12 +652,11 @@ dialog_treeview(const char *title,
if (show_status) {
for (i = 0; i < item_no; i++) {
if (listitems[i].state) {
+ if (dlg_need_separator())
+ dlg_add_separator();
if (dialog_vars.separate_output) {
dlg_add_string(listitems[i].name);
- dlg_add_separator();
} else {
- if (dlg_need_separator())
- dlg_add_separator();
if (flag == FLAG_CHECK)
dlg_add_quoted(listitems[i].name);
else
@@ -662,7 +664,7 @@ dialog_treeview(const char *title,
}
}
}
- dlg_add_last_key(-1);
+ AddLastKey();
}
dlg_free_columns(&listitems[0].text, (int) sizeof(DIALOG_LISTITEM), item_no);
diff --git a/ttysize.c b/ttysize.c
index f38708908ed8..fd9a97227187 100644
--- a/ttysize.c
+++ b/ttysize.c
@@ -1,9 +1,9 @@
/*
- * $Id: ttysize.c,v 1.1 2018/06/09 02:03:03 tom Exp $
+ * $Id: ttysize.c,v 1.2 2019/07/25 00:07:15 tom Exp $
*
* ttysize.c -- obtain terminal-size for dialog
*
- * Copyright 2018 Thomas E. Dickey
+ * Copyright 2018,2019 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -80,8 +80,8 @@ dlg_ttysize(int fd, int *high, int *wide)
}
}
#else
- high = 24;
- wide = 80;
+ *high = 24;
+ *wide = 80;
#endif /* HAVE_SIZECHANGE */
return rc;
}
diff --git a/ui_getc.c b/ui_getc.c
index 9d3c76df530d..5be01b88626b 100644
--- a/ui_getc.c
+++ b/ui_getc.c
@@ -1,9 +1,9 @@
/*
- * $Id: ui_getc.c,v 1.70 2018/06/14 00:05:05 tom Exp $
+ * $Id: ui_getc.c,v 1.80 2020/11/25 01:08:30 tom Exp $
*
* ui_getc.c - user interface glue for getc()
*
- * Copyright 2001-2013,2018 Thomas E. Dickey
+ * Copyright 2001-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -23,6 +23,7 @@
#include <dialog.h>
#include <dlg_keys.h>
+#include <dlg_internals.h>
#ifdef NEED_WCHAR_H
#include <wchar.h>
@@ -68,7 +69,7 @@ dlg_add_callback(DIALOG_CALLBACK * p)
{
p->next = dialog_state.getc_callbacks;
dialog_state.getc_callbacks = p;
- wtimeout(p->win, WTIMEOUT_VAL);
+ dlg_set_timeout(p->win, TRUE);
}
/*
@@ -150,9 +151,11 @@ handle_inputs(WINDOW *win)
}
}
}
- if (result) {
+ if (result && _dlg_find_window(win)) {
(void) wmove(win, cur_y, cur_x); /* Restore cursor position */
wrefresh(win);
+ } else {
+ result = FALSE;
}
if (state != ERR)
curs_set(state);
@@ -187,15 +190,17 @@ check_inputs(void)
DIALOG_CALLBACK *p;
fd_set read_fds;
struct timeval test;
- int last_fd = -1;
- int fd;
- int found;
int result = -1;
if ((p = dialog_state.getc_callbacks) != 0) {
+ int last_fd = -1;
+ int found;
+ int fd;
+
FD_ZERO(&read_fds);
while (p != 0) {
+
p->input_ready = FALSE;
if (p->input != 0 && (fd = fileno(p->input)) >= 0) {
FD_SET(fd, &read_fds);
@@ -252,10 +257,12 @@ dlg_getc_callbacks(int ch, int fkey, int *result)
static void
dlg_raise_window(WINDOW *win)
{
- touchwin(win);
- wmove(win, getcury(win), getcurx(win));
- wnoutrefresh(win);
- doupdate();
+ if (_dlg_find_window(win)) {
+ touchwin(win);
+ wmove(win, getcury(win), getcurx(win));
+ wnoutrefresh(win);
+ doupdate();
+ }
}
/*
@@ -313,6 +320,7 @@ dlg_add_last_key(int mode)
} else {
char temp[80];
sprintf(temp, "%d", last_getc);
+ DLG_TRACE(("# dlg_add_last_key(%s)\n", temp));
dlg_add_string(temp);
if (mode == -1)
dlg_add_separator();
@@ -343,9 +351,7 @@ really_getch(WINDOW *win, int *fkey)
{
int ch;
#ifdef USE_WIDE_CURSES
- int code;
mbstate_t state;
- wchar_t my_wchar;
wint_t my_wint;
/*
@@ -353,6 +359,9 @@ really_getch(WINDOW *win, int *fkey)
* having to change the rest of the code to use wide-characters.
*/
if (used_last_getc >= have_last_getc) {
+ int code;
+ wchar_t my_wchar;
+
used_last_getc = 0;
have_last_getc = 0;
ch = ERR;
@@ -441,18 +450,16 @@ dlg_getc(WINDOW *win, int *fkey)
bool done = FALSE;
bool literal = FALSE;
DIALOG_CALLBACK *p = 0;
- int interval = (dialog_vars.timeout_secs * 1000);
+ int interval = dlg_set_timeout(win, may_handle_inputs());
time_t expired = time((time_t *) 0) + dialog_vars.timeout_secs;
time_t current;
- if (may_handle_inputs())
- wtimeout(win, WTIMEOUT_VAL);
- else if (interval > 0)
- wtimeout(win, interval);
-
while (!done) {
bool handle_others = FALSE;
+ if (_dlg_find_window(win) == NULL)
+ break;
+
/*
* If there was no pending file-input, check the keyboard.
*/
@@ -481,13 +488,19 @@ dlg_getc(WINDOW *win, int *fkey)
keypad(win, FALSE);
continue;
case CHR_REPAINT:
- (void) touchwin(win);
- (void) wrefresh(curscr);
+ if (_dlg_find_window(win)) {
+ (void) touchwin(win);
+ (void) wrefresh(curscr);
+ }
break;
case ERR: /* wtimeout() in effect; check for file I/O */
if (interval > 0
&& current >= expired) {
+ int status;
DLG_TRACE(("# dlg_getc: timeout expired\n"));
+ if (dlg_getenv_num("DIALOG_TIMEOUT", &status)) {
+ dlg_exiterr("timeout");
+ }
ch = ESC;
done = TRUE;
} else if (!valid_file(stdin)
@@ -496,7 +509,7 @@ dlg_getc(WINDOW *win, int *fkey)
ch = ESC;
done = TRUE;
} else if (check_inputs()) {
- if (handle_inputs(win))
+ if (_dlg_find_window(win) && handle_inputs(win))
dlg_raise_window(win);
else
done = TRUE;
@@ -505,7 +518,7 @@ dlg_getc(WINDOW *win, int *fkey)
}
break;
case DLGK_HELPFILE:
- if (dialog_vars.help_file) {
+ if (dialog_vars.help_file && _dlg_find_window(win)) {
int yold, xold;
getyx(win, yold, xold);
dialog_helpfile("HELP", dialog_vars.help_file, 0, 0);
@@ -575,7 +588,7 @@ dlg_getc(WINDOW *win, int *fkey)
}
}
}
- if (literal)
+ if (literal && _dlg_find_window(win))
keypad(win, TRUE);
return ch;
}
@@ -596,7 +609,6 @@ void
dlg_killall_bg(int *retval)
{
DIALOG_CALLBACK *cb;
- int pid;
#ifdef HAVE_TYPE_UNIONWAIT
union wait wstatus;
#else
@@ -613,6 +625,7 @@ dlg_killall_bg(int *retval)
}
}
if (dialog_state.getc_callbacks != 0) {
+ int pid;
refresh();
fflush(stdout);
@@ -620,7 +633,7 @@ dlg_killall_bg(int *retval)
reset_shell_mode();
if ((pid = fork()) != 0) {
_exit(pid > 0 ? DLG_EXIT_OK : DLG_EXIT_ERROR);
- } else if (pid == 0) { /* child */
+ } else { /* child, pid==0 */
if ((pid = fork()) != 0) {
/*
* Echo the process-id of the grandchild so a shell script
@@ -650,7 +663,7 @@ dlg_killall_bg(int *retval)
;
#endif
_exit(WEXITSTATUS(wstatus));
- } else if (pid == 0) {
+ } else { /* child, pid==0 */
if (!dialog_vars.cant_kill)
(void) signal(SIGHUP, finish_bg);
(void) signal(SIGINT, finish_bg);
diff --git a/util.c b/util.c
index 5b0efb74fcb1..992be3f433f5 100644
--- a/util.c
+++ b/util.c
@@ -1,9 +1,9 @@
/*
- * $Id: util.c,v 1.272 2018/06/21 23:47:10 tom Exp $
+ * $Id: util.c,v 1.300 2021/01/17 22:10:56 tom Exp $
*
* util.c -- miscellaneous utilities for dialog
*
- * Copyright 2000-2016,2018 Thomas E. Dickey
+ * Copyright 2000-2020,2021 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -26,6 +26,9 @@
#include <dialog.h>
#include <dlg_keys.h>
+#include <dlg_internals.h>
+
+#include <sys/time.h>
#ifdef HAVE_SETLOCALE
#include <locale.h>
@@ -35,10 +38,22 @@
#include <wchar.h>
#endif
-#ifdef NCURSES_VERSION
-#if defined(HAVE_NCURSESW_TERM_H)
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+
+#if defined(NCURSES_VERSION)
+#define CAN_KEEP_TITE 1
+#elif defined(__NetBSD_Version__) && (__NetBSD_Version__ >= 800000000)
+#define CAN_KEEP_TITE 1
+#else
+#define CAN_KEEP_TITE 0
+#endif
+
+#if CAN_KEEP_TITE
+#if defined(NCURSES_VERSION) && defined(HAVE_NCURSESW_TERM_H)
#include <ncursesw/term.h>
-#elif defined(HAVE_NCURSES_TERM_H)
+#elif defined(NCURSES_VERSION) && defined(HAVE_NCURSES_TERM_H)
#include <ncurses/term.h>
#else
#include <term.h>
@@ -79,15 +94,22 @@ DIALOG_VARS dialog_vars;
#ifdef HAVE_COLOR
#include <dlg_colors.h>
+#ifdef HAVE_RC_FILE2
+#define COLOR_DATA(upr) , \
+ concat(DLGC_FG_,upr), \
+ concat(DLGC_BG_,upr), \
+ concat(DLGC_HL_,upr), \
+ concat(DLGC_UL_,upr), \
+ concat(DLGC_RV_,upr)
+#else /* HAVE_RC_FILE2 */
#define COLOR_DATA(upr) , \
concat(DLGC_FG_,upr), \
concat(DLGC_BG_,upr), \
concat(DLGC_HL_,upr)
-#else
+#endif /* HAVE_RC_FILE2 */
+#else /* HAVE_COLOR */
#define COLOR_DATA(upr) /*nothing */
-#endif
-
-#define DATA(atr,upr,lwr,cmt) { atr COLOR_DATA(upr) RC_DATA(lwr,cmt) }
+#endif /* HAVE_COLOR */
#define UseShadow(dw) ((dw) != 0 && (dw)->normal != 0 && (dw)->shadow != 0)
@@ -95,6 +117,7 @@ DIALOG_VARS dialog_vars;
* Table of color and attribute values, default is for mono display.
* The order matches the DIALOG_ATR() values.
*/
+#define DATA(atr,upr,lwr,cmt) { atr COLOR_DATA(upr) RC_DATA(lwr,cmt) }
/* *INDENT-OFF* */
DIALOG_COLORS dlg_color_table[] =
{
@@ -137,6 +160,7 @@ DIALOG_COLORS dlg_color_table[] =
DATA(A_REVERSE, SEARCHBOX_BORDER2, searchbox_border2, "Search box border2"),
DATA(A_REVERSE, MENUBOX_BORDER2, menubox_border2, "Menu box border2")
};
+#undef DATA
/* *INDENT-ON* */
/*
@@ -151,6 +175,7 @@ add_subwindow(WINDOW *parent, WINDOW *child)
if (p != 0) {
p->normal = parent;
p->shadow = child;
+ p->getc_timeout = WTIMEOUT_OFF;
p->next = dialog_state.all_subwindows;
dialog_state.all_subwindows = p;
}
@@ -187,11 +212,11 @@ del_subwindows(WINDOW *parent)
void
dlg_put_backtitle(void)
{
- int i;
if (dialog_vars.backtitle != NULL) {
chtype attr = A_NORMAL;
int backwidth = dlg_count_columns(dialog_vars.backtitle);
+ int i;
dlg_attrset(stdscr, screen_attr);
(void) wmove(stdscr, 0, 1);
@@ -230,6 +255,17 @@ dlg_clear(void)
dlg_attr_clear(stdscr, LINES, COLS, screen_attr);
}
+#ifdef KEY_RESIZE
+void
+_dlg_resize_cleanup(WINDOW *w)
+{
+ dlg_clear();
+ dlg_put_backtitle();
+ dlg_del_window(w);
+ dlg_mouse_free_regions();
+}
+#endif /* KEY_RESIZE */
+
#define isprivate(s) ((s) != 0 && strstr(s, "\033[?") != 0)
#define TTY_DEVICE "/dev/tty"
@@ -240,14 +276,7 @@ dlg_clear(void)
* option to be given, but some scripts were written making use of the
* behavior of dialog which tried opening the terminal anyway.
*/
-static char *
-dialog_tty(void)
-{
- char *result = getenv("DIALOG_TTY");
- if (result != 0 && atoi(result) == 0)
- result = 0;
- return result;
-}
+#define dialog_tty() (dlg_getenv_num("DIALOG_TTY", (int *)0) > 0)
/*
* Open the terminal directly. If one of stdin, stdout or stderr really points
@@ -271,7 +300,7 @@ open_terminal(char **result, int mode)
return open(device, mode);
}
-#ifdef NCURSES_VERSION
+#if CAN_KEEP_TITE
static int
my_putc(int ch)
{
@@ -302,8 +331,10 @@ init_dialog(FILE *input, FILE *output)
setlocale(LC_ALL, "");
dialog_state.output = output;
- dialog_state.tab_len = TAB_LEN;
- dialog_state.aspect_ratio = DEFAULT_ASPECT_RATIO;
+ if (dialog_state.tab_len == 0)
+ dialog_state.tab_len = TAB_LEN;
+ if (dialog_state.aspect_ratio == 0)
+ dialog_state.aspect_ratio = DEFAULT_ASPECT_RATIO;
#ifdef HAVE_COLOR
dialog_state.use_colors = USE_COLORS; /* use colors by default? */
dialog_state.use_shadow = USE_SHADOW; /* shadow dialog boxes by default? */
@@ -384,40 +415,7 @@ init_dialog(FILE *input, FILE *output)
dialog_state.screen_output = stdout;
(void) initscr();
}
-#ifdef NCURSES_VERSION
- /*
- * Cancel xterm's alternate-screen mode.
- */
- if (!dialog_vars.keep_tite
- && (fileno(dialog_state.screen_output) != fileno(stdout)
- || isatty(fileno(dialog_state.screen_output)))
- && key_mouse != 0 /* xterm and kindred */
- && isprivate(enter_ca_mode)
- && isprivate(exit_ca_mode)) {
- /*
- * initscr() or newterm() already wrote enter_ca_mode as a side
- * effect of initializing the screen. It would be nice to not even
- * do that, but we do not really have access to the correct copy of
- * the terminfo description until those functions have been invoked.
- */
- (void) refresh();
- (void) tputs(exit_ca_mode, 0, my_putc);
- (void) tputs(clear_screen, 0, my_putc);
- /*
- * Prevent ncurses from switching "back" to the normal screen when
- * exiting from dialog. That would move the cursor to the original
- * location saved in xterm. Normally curses sets the cursor position
- * to the first line after the display, but the alternate screen
- * switching is done after that point.
- *
- * Cancelling the strings altogether also works around the buggy
- * implementation of alternate-screen in rxvt, etc., which clear
- * more of the display than they should.
- */
- enter_ca_mode = 0;
- exit_ca_mode = 0;
- }
-#endif
+ dlg_keep_tite(dialog_state.screen_output);
#ifdef HAVE_FLUSHINP
(void) flushinp();
#endif
@@ -440,6 +438,60 @@ init_dialog(FILE *input, FILE *output)
dlg_clear();
}
+void
+dlg_keep_tite(FILE *output)
+{
+ if (!dialog_vars.keep_tite) {
+#if CAN_KEEP_TITE
+ /*
+ * Cancel xterm's alternate-screen mode.
+ */
+ if ((fileno(output) != fileno(stdout)
+ || isatty(fileno(output)))
+ && key_mouse != 0 /* xterm and kindred */
+ && isprivate(enter_ca_mode)
+ && isprivate(exit_ca_mode)) {
+ FILE *save = dialog_state.screen_output;
+
+ /*
+ * initscr() or newterm() already wrote enter_ca_mode as a side
+ * effect of initializing the screen. It would be nice to not even
+ * do that, but we do not really have access to the correct copy of
+ * the terminfo description until those functions have been
+ * invoked.
+ */
+ (void) refresh();
+ dialog_state.screen_output = output;
+ (void) tputs(exit_ca_mode, 0, my_putc);
+ (void) tputs(clear_screen, 0, my_putc);
+ dialog_state.screen_output = save;
+
+ /*
+ * Prevent ncurses from switching "back" to the normal screen when
+ * exiting from dialog. That would move the cursor to the original
+ * location saved in xterm. Normally curses sets the cursor
+ * position to the first line after the display, but the alternate
+ * screen switching is done after that point.
+ *
+ * Cancelling the strings altogether also works around the buggy
+ * implementation of alternate-screen in rxvt, etc., which clear
+ * more of the display than they should.
+ */
+ enter_ca_mode = 0;
+ exit_ca_mode = 0;
+ }
+#else
+ /*
+ * For other implementations, there are no useful answers:
+ * + SVr4 curses "could" support a similar approach, but the clue about
+ * xterm is absent from its terminal database.
+ * + PDCurses does not provide terminfo.
+ */
+ (void) output;
+#endif
+ }
+}
+
#ifdef HAVE_COLOR
static int defined_colors = 1; /* pair-0 is reserved */
/*
@@ -448,9 +500,9 @@ static int defined_colors = 1; /* pair-0 is reserved */
void
dlg_color_setup(void)
{
- unsigned i;
-
if (has_colors()) { /* Terminal supports color? */
+ unsigned i;
+
(void) start_color();
#if defined(HAVE_USE_DEFAULT_COLORS)
@@ -477,14 +529,16 @@ dlg_color_setup(void)
sizeof(dlg_color_table[0]); i++) {
/* Initialize color pairs */
- chtype color = dlg_color_pair(dlg_color_table[i].fg,
- dlg_color_table[i].bg);
+ chtype atr = dlg_color_pair(dlg_color_table[i].fg,
+ dlg_color_table[i].bg);
- /* Setup color attributes */
- dlg_color_table[i].atr = ((dlg_color_table[i].hilite
- ? A_BOLD
- : 0)
- | color);
+ atr |= (dlg_color_table[i].hilite ? A_BOLD : 0);
+#ifdef HAVE_RC_FILE2
+ atr |= (dlg_color_table[i].ul ? A_UNDERLINE : 0);
+ atr |= (dlg_color_table[i].rv ? A_REVERSE : 0);
+#endif /* HAVE_RC_FILE2 */
+
+ dlg_color_table[i].atr = atr;
}
#endif
} else {
@@ -496,7 +550,7 @@ dlg_color_setup(void)
int
dlg_color_count(void)
{
- return sizeof(dlg_color_table) / sizeof(dlg_color_table[0]);
+ return TableSize(dlg_color_table);
}
/*
@@ -555,12 +609,12 @@ dlg_color_pair(int foreground, int background)
static chtype
define_color(WINDOW *win, int foreground)
{
- int pair;
short fg, bg, background;
if (dialog_state.text_only) {
background = COLOR_BLACK;
} else {
chtype attrs = dlg_get_attrs(win);
+ int pair;
if ((pair = PAIR_NUMBER(attrs)) != 0
&& pair_content((short) pair, &fg, &bg) != ERR) {
@@ -581,6 +635,14 @@ end_dialog(void)
{
if (dialog_state.screen_initialized) {
dialog_state.screen_initialized = FALSE;
+ if (dialog_vars.erase_on_exit) {
+ /*
+ * Clear the screen to the native background color, and leave the
+ * terminal cursor at the lower-left corner of the screen.
+ */
+ werase(stdscr);
+ wrefresh(stdscr);
+ }
mouse_close();
(void) endwin();
(void) fflush(stdout);
@@ -665,13 +727,12 @@ dlg_print_listitem(WINDOW *win,
{
chtype attr = A_NORMAL;
int limit;
- const int *cols;
chtype attrs[4];
if (text == 0)
text = "";
- if (first) {
+ if (first && !dialog_vars.no_hot_list) {
const int *indx = dlg_index_wchars(text);
attrs[3] = tag_key_selected_attr;
attrs[2] = tag_key_attr;
@@ -679,18 +740,22 @@ dlg_print_listitem(WINDOW *win,
attrs[0] = tag_attr;
dlg_attrset(win, selected ? attrs[3] : attrs[2]);
- (void) waddnstr(win, text, indx[1]);
-
- if ((int) strlen(text) > indx[1]) {
- limit = dlg_limit_columns(text, climit, 1);
- if (limit > 1) {
- dlg_attrset(win, selected ? attrs[1] : attrs[0]);
- (void) waddnstr(win,
- text + indx[1],
- indx[limit] - indx[1]);
+ if (*text != '\0') {
+ (void) waddnstr(win, text, indx[1]);
+
+ if ((int) strlen(text) > indx[1]) {
+ limit = dlg_limit_columns(text, climit, 1);
+ if (limit > 1) {
+ dlg_attrset(win, selected ? attrs[1] : attrs[0]);
+ (void) waddnstr(win,
+ text + indx[1],
+ indx[limit] - indx[1]);
+ }
}
}
} else {
+ const int *cols;
+
attrs[1] = item_selected_attr;
attrs[0] = item_attr;
@@ -715,9 +780,7 @@ dlg_print_text(WINDOW *win, const char *txt, int cols, chtype *attr)
int y_before, x_before = 0;
int y_after, x_after;
int tabbed = 0;
- bool thisTab;
bool ended = FALSE;
- chtype useattr;
#ifdef USE_WIDE_CURSES
int combined = 0;
#endif
@@ -726,9 +789,14 @@ dlg_print_text(WINDOW *win, const char *txt, int cols, chtype *attr)
y_origin = y_after = 0;
x_origin = x_after = 0;
} else {
+ y_after = 0;
+ x_after = 0;
getyx(win, y_origin, x_origin);
}
while (cols > 0 && (*txt != '\0')) {
+ bool thisTab;
+ chtype useattr;
+
if (dialog_vars.colors) {
while (isOurEscape(txt)) {
int code;
@@ -769,6 +837,8 @@ dlg_print_text(WINDOW *win, const char *txt, int cols, chtype *attr)
case 'n':
*attr = A_NORMAL;
break;
+ default:
+ break;
}
++txt;
}
@@ -802,7 +872,6 @@ dlg_print_text(WINDOW *win, const char *txt, int cols, chtype *attr)
*/
thisTab = (CharOf(*txt) == TAB);
if (dialog_state.text_only) {
- y_before = y_after;
x_before = x_after;
} else {
if (thisTab) {
@@ -971,7 +1040,7 @@ justify_text(WINDOW *win,
int *high, int *wide)
{
chtype attr = A_NORMAL;
- int x = (2 * MARGIN);
+ int x;
int y = MARGIN;
int max_x = 2;
int lm = (2 * MARGIN); /* left margin (box-border plus a space) */
@@ -1068,11 +1137,8 @@ dlg_print_scrolled(WINDOW *win,
if (pauseopt) {
int wide = width - (2 * MARGIN);
int high = LINES;
- int y, x;
int len;
- int percent;
WINDOW *dummy;
- char buffer[5];
#if defined(NCURSES_VERSION_PATCH) && NCURSES_VERSION_PATCH >= 20040417
/*
@@ -1088,6 +1154,8 @@ dlg_print_scrolled(WINDOW *win,
dlg_print_autowrap(win, prompt, height + 1 + (3 * MARGIN), width);
last = 0;
} else {
+ int y, x;
+
wbkgdset(dummy, dialog_attr | ' ');
dlg_attrset(dummy, dialog_attr);
werase(dummy);
@@ -1109,12 +1177,16 @@ dlg_print_scrolled(WINDOW *win,
/* if the text is incomplete, or we have scrolled, show the percentage */
if (y > 0 && wide > 4) {
- percent = (int) ((height + offset) * 100.0 / y);
+ int percent = (int) ((height + offset) * 100.0 / y);
+
if (percent < 0)
percent = 0;
if (percent > 100)
percent = 100;
+
if (offset != 0 || percent != 100) {
+ char buffer[5];
+
dlg_attrset(win, position_indicator_attr);
(void) wmove(win, MARGIN + height, wide - 4);
(void) sprintf(buffer, "%d%%", percent);
@@ -1205,7 +1277,6 @@ auto_size_preformatted(const char *prompt, int *height, int *width)
{
int high = 0, wide = 0;
float car; /* Calculated Aspect Ratio */
- float diff;
int max_y = SLINES - 1;
int max_x = SCOLS - 2;
int max_width = max_x;
@@ -1220,7 +1291,7 @@ auto_size_preformatted(const char *prompt, int *height, int *width)
* width proportionately.
*/
if (car > ar) {
- diff = car / (float) ar;
+ float diff = car / (float) ar;
max_x = (int) ((float) wide / diff + 4);
justify_text((WINDOW *) 0, prompt, max_y, max_x, &high, &wide);
car = (float) wide / (float) high;
@@ -1249,10 +1320,10 @@ auto_size_preformatted(const char *prompt, int *height, int *width)
static int
longest_word(const char *string)
{
- int length, result = 0;
+ int result = 0;
while (*string != '\0') {
- length = 0;
+ int length = 0;
while (*string != '\0' && !isspace(UCH(*string))) {
length++;
string++;
@@ -1278,7 +1349,6 @@ real_auto_size(const char *title,
int y = (dialog_vars.begin_set ? dialog_vars.begin_y : 1);
int title_length = title ? dlg_count_columns(title) : 0;
int high;
- int wide;
int save_high = *height;
int save_wide = *width;
int max_high;
@@ -1301,6 +1371,8 @@ real_auto_size(const char *title,
}
if (*width <= 0) {
+ int wide;
+
if (prompt != 0) {
wide = MAX(title_length, mincols);
if (strchr(prompt, '\n') == 0) {
@@ -1393,8 +1465,6 @@ dlg_auto_sizefile(const char *title,
int len = title ? dlg_count_columns(title) : 0;
int nc = 4;
int numlines = 2;
- long offset;
- int ch;
FILE *fd;
/* Open input file for reading */
@@ -1415,8 +1485,12 @@ dlg_auto_sizefile(const char *title,
}
while (!feof(fd)) {
+ int ch;
+ long offset;
+
if (ferror(fd))
break;
+
offset = 0;
while (((ch = getc(fd)) != '\n') && !feof(fd)) {
if ((ch == TAB) && (dialog_vars.tab_correct)) {
@@ -1499,14 +1573,26 @@ dlg_draw_box(WINDOW *win, int y, int x, int height, int width,
dlg_draw_box2(win, y, x, height, width, boxchar, borderchar, boxchar);
}
+/*
+ * Search the given 'list' for the given window 'win'. Typically 'win' is an
+ * input-window, i.e., a window where we might use wgetch.
+ *
+ * The all-windows list has normal- and shadow-windows. Since we never use the
+ * shadow as an input window, normally we just look for the normal-window.
+ *
+ * However, the all-subwindows list stores parent/child windows rather than
+ * normal/shadow windows. When searching that list, we look for the child
+ * window (in the .shadow field).
+ */
static DIALOG_WINDOWS *
-find_window(WINDOW *win)
+find_window(DIALOG_WINDOWS * list, WINDOW *win, bool normal)
{
DIALOG_WINDOWS *result = 0;
DIALOG_WINDOWS *p;
- for (p = dialog_state.all_windows; p != 0; p = p->next) {
- if (p->normal == win) {
+ for (p = list; p != 0; p = p->next) {
+ WINDOW *check = normal ? p->normal : p->shadow;
+ if (check == win) {
result = p;
break;
}
@@ -1514,6 +1600,25 @@ find_window(WINDOW *win)
return result;
}
+#define SearchTopWindows(win) find_window(dialog_state.all_windows, win, TRUE)
+#define SearchSubWindows(win) find_window(dialog_state.all_subwindows, win, FALSE)
+
+/*
+ * Check for the existence of a window, e.g., when used for input or updating
+ * the display. This is used in dlg_getc() and related functions, to guard
+ * against an asynchronous window-deletion that might invalidate the input
+ * window used in dlg_getc().
+ */
+DIALOG_WINDOWS *
+_dlg_find_window(WINDOW *win)
+{
+ DIALOG_WINDOWS *result = 0;
+
+ if ((result = SearchTopWindows(win)) == NULL)
+ result = SearchSubWindows(win);
+ return result;
+}
+
#ifdef HAVE_COLOR
/*
* If we have wchgat(), use that for updating shadow attributes, to work with
@@ -1647,9 +1752,9 @@ repaint_cell(DIALOG_WINDOWS * dw, bool draw, int y, int x)
static void
repaint_shadow(DIALOG_WINDOWS * dw, bool draw, int y, int x, int height, int width)
{
- int i, j;
-
if (UseShadow(dw)) {
+ int i, j;
+
#if !USE_WCHGAT
chtype save = dlg_get_attrs(dw->shadow);
dlg_attrset(dw->shadow, draw ? shadow_attr : screen_attr);
@@ -1712,7 +1817,7 @@ erase_childs_shadow(DIALOG_WINDOWS * dw)
void
dlg_draw_shadow(WINDOW *win, int y, int x, int height, int width)
{
- repaint_shadow(find_window(win), TRUE, y, x, height, width);
+ repaint_shadow(SearchTopWindows(win), TRUE, y, x, height, width);
}
#endif /* HAVE_COLOR */
@@ -1735,24 +1840,18 @@ dlg_exit(int code)
{ DLG_EXIT_HELP, "DIALOG_HELP" },
{ DLG_EXIT_OK, "DIALOG_OK" },
{ DLG_EXIT_ITEM_HELP, "DIALOG_ITEM_HELP" },
+ { DLG_EXIT_TIMEOUT, "DIALOG_TIMEOUT" },
};
/* *INDENT-ON* */
unsigned n;
- char *name;
- char *temp;
- long value;
bool overridden = FALSE;
retry:
- for (n = 0; n < sizeof(table) / sizeof(table[0]); n++) {
+ for (n = 0; n < TableSize(table); n++) {
if (table[n].code == code) {
- if ((name = getenv(table[n].name)) != 0) {
- value = strtol(name, &temp, 0);
- if (temp != 0 && temp != name && *temp == '\0') {
- code = (int) value;
- overridden = TRUE;
- }
+ if (dlg_getenv_num(table[n].name, &code)) {
+ overridden = TRUE;
}
break;
}
@@ -1773,8 +1872,8 @@ dlg_exit(int code)
#ifdef NO_LEAKS
_dlg_inputstr_leaks();
-#if defined(NCURSES_VERSION) && defined(HAVE__NC_FREE_AND_EXIT)
- _nc_free_and_exit(code);
+#if defined(NCURSES_VERSION) && (defined(HAVE_CURSES_EXIT) || defined(HAVE__NC_FREE_AND_EXIT))
+ curses_exit(code);
#endif
#endif
@@ -1799,9 +1898,57 @@ dlg_exit(int code)
}
}
+#define DATA(name) { DLG_EXIT_ ## name, #name }
+/* *INDENT-OFF* */
+static struct {
+ int code;
+ const char *name;
+} exit_codenames[] = {
+ DATA(ESC),
+ DATA(UNKNOWN),
+ DATA(ERROR),
+ DATA(OK),
+ DATA(CANCEL),
+ DATA(HELP),
+ DATA(EXTRA),
+ DATA(ITEM_HELP),
+};
+#undef DATA
+/* *INDENT-ON* */
+
+const char *
+dlg_exitcode2s(int code)
+{
+ const char *result = "?";
+ size_t n;
+
+ for (n = 0; n < TableSize(exit_codenames); ++n) {
+ if (exit_codenames[n].code == code) {
+ result = exit_codenames[n].name;
+ break;
+ }
+ }
+ return result;
+}
+
+int
+dlg_exitname2n(const char *name)
+{
+ int result = DLG_EXIT_UNKNOWN;
+ size_t n;
+
+ for (n = 0; n < TableSize(exit_codenames); ++n) {
+ if (!dlg_strcmp(exit_codenames[n].name, name)) {
+ result = exit_codenames[n].code;
+ break;
+ }
+ }
+ return result;
+}
+
/* quit program killing all tailbg */
void
-dlg_exiterr(const char *fmt,...)
+dlg_exiterr(const char *fmt, ...)
{
int retval;
va_list ap;
@@ -1814,11 +1961,62 @@ dlg_exiterr(const char *fmt,...)
va_end(ap);
(void) fputc('\n', stderr);
+#ifdef HAVE_DLG_TRACE
+ va_start(ap, fmt);
+ dlg_trace_msg("## Error: ");
+ dlg_trace_va_msg(fmt, ap);
+ va_end(ap);
+#endif
+
dlg_killall_bg(&retval);
(void) fflush(stderr);
(void) fflush(stdout);
- dlg_exit(DLG_EXIT_ERROR);
+ dlg_exit(strcmp(fmt, "timeout") == 0 ? DLG_EXIT_TIMEOUT : DLG_EXIT_ERROR);
+}
+
+/*
+ * Get a string from the environment, rejecting those which are entirely blank.
+ */
+char *
+dlg_getenv_str(const char *name)
+{
+ char *result = getenv(name);
+ if (result != NULL) {
+ while (*result != '\0' && isspace(UCH(*result)))
+ ++result;
+ if (*result == '\0')
+ result = NULL;
+ }
+ return result;
+}
+
+/*
+ * Get a number from the environment:
+ * + If the caller provides a pointer in the second parameter, return
+ * success/failure for the function return, and the actual value via the
+ * pointer. Use this for decoding arbitrary numbers, e.g., negative or zero.
+ * + If the caller does not provide a pointer, return the decoded value for
+ * the function-return. Use this when only values greater than zero are
+ * useful.
+ */
+int
+dlg_getenv_num(const char *name, int *value)
+{
+ int result = 0;
+ char *data = getenv(name);
+ if (data != NULL) {
+ char *temp = NULL;
+ long check = strtol(data, &temp, 0);
+ if (temp != 0 && temp != data && *temp == '\0') {
+ result = (int) check;
+ if (value != NULL) {
+ *value = result;
+ result = 1;
+ }
+ }
+ }
+ return result;
}
void
@@ -1896,8 +2094,11 @@ dlg_calc_listh(int *height, int *list_height, int item_no)
int
dlg_calc_listw(int item_no, char **items, int group)
{
- int n, i, len1 = 0, len2 = 0;
+ int i, len1 = 0, len2 = 0;
+
for (i = 0; i < (item_no * group); i += group) {
+ int n;
+
if ((n = dlg_count_columns(items[i])) > len1)
len1 = n;
if ((n = dlg_count_columns(items[i + 1])) > len2)
@@ -2146,6 +2347,7 @@ dlg_new_modal_window(WINDOW *parent, int height, int width, int y, int x)
}
p->next = dialog_state.all_windows;
p->normal = win;
+ p->getc_timeout = WTIMEOUT_OFF;
dialog_state.all_windows = p;
#ifdef HAVE_COLOR
if (dialog_state.use_shadow) {
@@ -2159,18 +2361,61 @@ dlg_new_modal_window(WINDOW *parent, int height, int width, int y, int x)
}
/*
+ * dlg_getc() uses the return-value to determine how to handle an ERR return
+ * from a non-blocking read:
+ * a) if greater than zero, there was an expired timeout (blocking for a short
+ * time), or
+ * b) if zero, it was a non-blocking read, or
+ * c) if negative, an error occurred on a blocking read.
+ */
+int
+dlg_set_timeout(WINDOW *win, bool will_getc)
+{
+ DIALOG_WINDOWS *p;
+ int result = 0;
+
+ if ((p = SearchTopWindows(win)) != NULL) {
+ int interval = (dialog_vars.timeout_secs * 1000);
+
+ if (will_getc || dialog_vars.pause_secs) {
+ interval = WTIMEOUT_VAL;
+ } else {
+ result = interval;
+ if (interval <= 0) {
+ interval = WTIMEOUT_OFF;
+ }
+ }
+ wtimeout(win, interval);
+ p->getc_timeout = interval;
+ }
+ return result;
+}
+
+void
+dlg_reset_timeout(WINDOW *win)
+{
+ DIALOG_WINDOWS *p;
+
+ if ((p = SearchTopWindows(win)) != NULL) {
+ wtimeout(win, p->getc_timeout);
+ } else {
+ wtimeout(win, WTIMEOUT_OFF);
+ }
+}
+
+/*
* Move/Resize a window, optionally with a shadow.
*/
#ifdef KEY_RESIZE
void
dlg_move_window(WINDOW *win, int height, int width, int y, int x)
{
- DIALOG_WINDOWS *p;
-
if (win != 0) {
+ DIALOG_WINDOWS *p;
+
dlg_ctl_size(height, width);
- if ((p = find_window(win)) != 0) {
+ if ((p = SearchTopWindows(win)) != 0) {
(void) wresize(win, height, width);
(void) mvwin(win, y, x);
#ifdef HAVE_COLOR
@@ -2198,29 +2443,49 @@ dlg_move_window(WINDOW *win, int height, int width, int y, int x)
void
dlg_will_resize(WINDOW *win)
{
- int n, ch, base;
+ int n, base;
int caught = 0;
+ dialog_state.had_resize = TRUE;
dlg_trace_win(win);
- wtimeout(win, 20);
+ wtimeout(win, WTIMEOUT_VAL * 5);
+
for (n = base = 0; n < base + 10; ++n) {
+ int ch;
+
if ((ch = wgetch(win)) != ERR) {
if (ch == KEY_RESIZE) {
base = n;
++caught;
- } else {
+ } else if (ch != ERR) {
ungetch(ch);
break;
}
}
}
- dlg_trace_msg("# caught %d KEY_RESIZE key%s\n",
- 1 + caught,
- caught == 1 ? "" : "s");
+ dlg_reset_timeout(win);
+ DLG_TRACE(("# caught %d KEY_RESIZE key%s\n",
+ 1 + caught,
+ caught == 1 ? "" : "s"));
}
#endif /* KEY_RESIZE */
WINDOW *
+dlg_der_window(WINDOW *parent, int height, int width, int y, int x)
+{
+ WINDOW *win;
+
+ /* existing uses of derwin are (almost) guaranteed to succeed, and the
+ * caller has to allow for failure.
+ */
+ if ((win = derwin(parent, height, width, y, x)) != 0) {
+ add_subwindow(parent, win);
+ (void) keypad(win, TRUE);
+ }
+ return win;
+}
+
+WINDOW *
dlg_sub_window(WINDOW *parent, int height, int width, int y, int x)
{
WINDOW *win;
@@ -2282,14 +2547,15 @@ dlg_item_help(const char *txt)
{
if (USE_ITEM_HELP(txt)) {
chtype attr = A_NORMAL;
- int y, x;
dlg_attrset(stdscr, itemhelp_attr);
(void) wmove(stdscr, LINES - 1, 0);
(void) wclrtoeol(stdscr);
(void) addch(' ');
dlg_print_text(stdscr, txt, COLS - 1, &attr);
+
if (itemhelp_attr & A_COLOR) {
+ int y, x;
/* fill the remainder of the line with the window's attributes */
getyx(stdscr, y, x);
(void) y;
@@ -2330,7 +2596,7 @@ dlg_strcmp(const char *a, const char *b)
static bool
trim_blank(char *base, char *dst)
{
- int count = isblank(UCH(*dst));
+ int count = !!isblank(UCH(*dst));
while (dst-- != base) {
if (*dst == '\n') {
diff --git a/yesno.c b/yesno.c
index 3605f67aee45..58acc8ae763d 100644
--- a/yesno.c
+++ b/yesno.c
@@ -1,9 +1,9 @@
/*
- * $Id: yesno.c,v 1.62 2018/06/19 22:57:01 tom Exp $
+ * $Id: yesno.c,v 1.71 2020/11/23 00:48:08 tom Exp $
*
* yesno.c -- implements the yes/no box
*
- * Copyright 1999-2012,2018 Thomas E. Dickey
+ * Copyright 1999-2019,2020 Thomas E. Dickey
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License, version 2.1
@@ -44,8 +44,7 @@ dialog_yesno(const char *title, const char *cprompt, int height, int width)
/* *INDENT-ON* */
int x, y;
- int key = 0, fkey;
- int code;
+ int key, fkey;
int button = dlg_default_button();
WINDOW *dialog = 0;
int result = DLG_EXIT_UNKNOWN;
@@ -79,16 +78,9 @@ dialog_yesno(const char *title, const char *cprompt, int height, int width)
x = dlg_box_x_ordinate(width);
y = dlg_box_y_ordinate(height);
-#ifdef KEY_RESIZE
- if (dialog != 0)
- dlg_move_window(dialog, height, width, y, x);
- else
-#endif
- {
- dialog = dlg_new_window(height, width, y, x);
- dlg_register_window(dialog, "yesno", binding);
- dlg_register_buttons(dialog, "yesno", buttons);
- }
+ dialog = dlg_new_window(height, width, y, x);
+ dlg_register_window(dialog, "yesno", binding);
+ dlg_register_buttons(dialog, "yesno", buttons);
dlg_draw_box2(dialog, 0, 0, height, width, dialog_attr, border_attr, border2_attr);
dlg_draw_bottom_box2(dialog, border_attr, border2_attr, dialog_attr);
@@ -103,6 +95,8 @@ dialog_yesno(const char *title, const char *cprompt, int height, int width)
buttons, button, FALSE, width);
while (result == DLG_EXIT_UNKNOWN) {
+ int code;
+
if (show) {
last = dlg_print_scrolled(dialog, prompt, offset,
page, width, TRUE);
@@ -110,8 +104,10 @@ dialog_yesno(const char *title, const char *cprompt, int height, int width)
show = FALSE;
}
key = dlg_mouse_wgetch(dialog, &fkey);
- if (dlg_result_key(key, fkey, &result))
- break;
+ if (dlg_result_key(key, fkey, &result)) {
+ if (!dlg_button_key(result, &button, &key, &fkey))
+ break;
+ }
if ((code = dlg_char_to_button(key, buttons)) >= 0) {
result = dlg_ok_buttoncode(code);
break;
@@ -138,16 +134,17 @@ dialog_yesno(const char *title, const char *cprompt, int height, int width)
FALSE, width);
break;
case DLGK_ENTER:
+ case DLGK_LEAVE:
result = dlg_yes_buttoncode(button);
break;
#ifdef KEY_RESIZE
case KEY_RESIZE:
dlg_will_resize(dialog);
- dlg_clear();
- free(prompt);
height = req_high;
width = req_wide;
show = TRUE;
+ free(prompt);
+ _dlg_resize_cleanup(dialog);
goto restart;
#endif
default:
@@ -161,10 +158,11 @@ dialog_yesno(const char *title, const char *cprompt, int height, int width)
}
break;
}
- } else {
+ } else if (key > 0) {
beep();
}
}
+ dlg_add_last_key(-1);
dlg_del_window(dialog);
dlg_mouse_free_regions();