Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Import version 458 of "less". Changes since version 444:

* Allow backslash escaping of metacharacters in LESS environment variable
  after the --use-backslash option.
* Don't quit if syntax errors are found in command line options.
* Increase sizes of some internal buffers.
* Fix configure bug with --with-regex=none.
* Fix crash with "stty rows 0".
* Fix display bug when using up/down arrow on the command line.
* Add ESC-F command to keep reading data until a pattern is found.
* Use exit code of LESSOPEN script if LESSOPEN starts with "||".
* When up/down arrow is used on the command line immediately after
  typing text, the next command starting with that text is found.
* Add support for GNU regex.
* Add configure option --with-regex=none and fix compile errors
  when compiling with no regex library.
* Fix possible crashes caused by malformed LESSOPEN or
  LESSCLOSE variables.
* Fix bug highlighting text which is discontiguous in the file
  due to backspace processing.
* Fix bug in displaying status column when scrolling backwards
  with -J and -S in effect.
  • Loading branch information...
commit 913567a0c759cf791bf6fd2defe46f0fe96ef756 1 parent 2ef89a3
tron authored
Showing with 1,160 additions and 712 deletions.
  1. +1 −1  external/bsd/less/dist/LICENSE
  2. +2 −3 external/bsd/less/dist/Makefile.aut
  3. +47 −2 external/bsd/less/dist/NEWS
  4. +7 −6 external/bsd/less/dist/README
  5. +3 −4 external/bsd/less/dist/brac.c
  6. +16 −4 external/bsd/less/dist/ch.c
  7. +3 −4 external/bsd/less/dist/charset.c
  8. +3 −4 external/bsd/less/dist/charset.h
  9. +6 −6 external/bsd/less/dist/cmd.h
  10. +56 −21 external/bsd/less/dist/cmdbuf.c
  11. +53 −24 external/bsd/less/dist/command.c
  12. +236 −229 external/bsd/less/dist/configure
  13. +49 −17 external/bsd/less/dist/configure.ac
  14. +13 −19 external/bsd/less/dist/cvt.c
  15. +4 −4 external/bsd/less/dist/decode.c
  16. +17 −3 external/bsd/less/dist/defines.ds
  17. +16 −10 external/bsd/less/dist/defines.h
  18. +15 −9 external/bsd/less/dist/defines.h.in
  19. +14 −3 external/bsd/less/dist/defines.o2
  20. +14 −3 external/bsd/less/dist/defines.o9
  21. +14 −3 external/bsd/less/dist/defines.wn
  22. +7 −4 external/bsd/less/dist/edit.c
  23. +47 −8 external/bsd/less/dist/filename.c
  24. +3 −4 external/bsd/less/dist/forwback.c
  25. +2 −1  external/bsd/less/dist/funcs.h
  26. +14 −15 external/bsd/less/dist/help.c
  27. +3 −4 external/bsd/less/dist/ifile.c
  28. +4 −5 external/bsd/less/dist/input.c
  29. +3 −4 external/bsd/less/dist/jump.c
  30. +62 −18 external/bsd/less/dist/less.1
  31. +6 −4 external/bsd/less/dist/less.h
  32. +13 −14 external/bsd/less/dist/less.hlp
  33. +12 −7 external/bsd/less/dist/lessecho.1
  34. +4 −5 external/bsd/less/dist/lessecho.c
  35. +5 −5 external/bsd/less/dist/lesskey.1
  36. +5 −5 external/bsd/less/dist/lesskey.c
  37. +3 −4 external/bsd/less/dist/lesskey.h
  38. +3 −4 external/bsd/less/dist/lglob.h
  39. +9 −4 external/bsd/less/dist/line.c
  40. +3 −4 external/bsd/less/dist/linenum.c
  41. +3 −4 external/bsd/less/dist/lsystem.c
  42. +4 −4 external/bsd/less/dist/main.c
  43. +3 −4 external/bsd/less/dist/mark.c
  44. +3 −4 external/bsd/less/dist/mkhelp.c
  45. +27 −5 external/bsd/less/dist/optfunc.c
  46. +30 −27 external/bsd/less/dist/option.c
  47. +3 −4 external/bsd/less/dist/option.h
  48. +13 −4 external/bsd/less/dist/opttbl.c
  49. +3 −4 external/bsd/less/dist/os.c
  50. +23 −10 external/bsd/less/dist/output.c
  51. +110 −68 external/bsd/less/dist/pattern.c
  52. +14 −4 external/bsd/less/dist/pattern.h
  53. +3 −4 external/bsd/less/dist/pckeys.h
  54. +4 −5 external/bsd/less/dist/position.c
  55. +3 −4 external/bsd/less/dist/position.h
  56. +9 −10 external/bsd/less/dist/prompt.c
  57. +1 −1  external/bsd/less/dist/regexp.c
  58. +1 −1  external/bsd/less/dist/regexp.h
  59. +5 −6 external/bsd/less/dist/screen.c
  60. +3 −4 external/bsd/less/dist/scrsize.c
  61. +64 −19 external/bsd/less/dist/search.c
  62. +3 −4 external/bsd/less/dist/signal.c
  63. +3 −4 external/bsd/less/dist/tags.c
  64. +3 −4 external/bsd/less/dist/ttyin.c
  65. +25 −6 external/bsd/less/dist/version.c
View
2  external/bsd/less/dist/LICENSE
@@ -2,7 +2,7 @@
------------
Less
-Copyright (C) 1984-2011 Mark Nudelman
+Copyright (C) 1984-2012 Mark Nudelman
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
View
5 external/bsd/less/dist/Makefile.aut
@@ -1,6 +1,6 @@
# Makefile for authoring less.
-EMAIL = markn@greenwoodsoftware.com
+EMAIL = bug-less@gnu.org
HOMEPAGE = http://www.greenwoodsoftware.com/less
SHELL = /bin/sh
RCS = rcs
@@ -112,8 +112,7 @@ dist: ${DISTFILES}
echo "Preparing $$REL"; \
rm -rf $$REL; mkdir $$REL; \
for file in ${DISTFILES}; do \
- cp -p $$file $$REL; \
- chmod -w $$REL/$$file; \
+ ./add_copyright $$file $$REL; \
done; \
cd $$REL; chmod +w ${DISTFILES_W}; cd ..; \
echo "Creating release/$$REL/$$REL.tar.gz"; \
View
49 external/bsd/less/dist/NEWS
@@ -7,8 +7,53 @@
http://www.greenwoodsoftware.com/less
You can also download the latest version of less from there.
- To report bugs, suggestions or comments, send email to
- bug-less@gnu.org or markn@greenwoodsoftware.com.
+ To report bugs, suggestions or comments, send email to bug-less@gnu.org.
+
+======================================================================
+
+ Major changes between "less" versions 451 and 458
+
+* Allow backslash escaping of metacharacters in LESS environment variable
+ after the --use-backslash option.
+
+* Don't quit if syntax errors are found in command line options.
+
+* Increase sizes of some internal buffers.
+
+* Fix configure bug with --with-regex=none.
+
+* Fix crash with "stty rows 0".
+
+* Fix Win32 attribute display bug.
+
+* Fix display bug when using up/down arrow on the command line.
+
+======================================================================
+
+ Major changes between "less" versions 444 and 451
+
+* Add ESC-F command to keep reading data until a pattern is found.
+
+* Use exit code of LESSOPEN script if LESSOPEN starts with "||".
+
+* When up/down arrow is used on the command line immediately after
+ typing text, the next command starting with that text is found.
+
+* Add support for GNU regex.
+
+* Add configure option --with-regex=none and fix compile errors
+ when compiling with no regex library.
+
+* Fix bugs handling SGR sequences in Win32.
+
+* Fix possible crashes caused by malformed LESSOPEN or
+ LESSCLOSE variables.
+
+* Fix bug highlighting text which is discontiguous in the file
+ due to backspace processing.
+
+* Fix bug in displaying status column when scrolling backwards
+ with -J and -S in effect.
======================================================================
View
13 external/bsd/less/dist/README
@@ -1,7 +1,7 @@
- Less, version 444
+ Less, version 458
- This is the distribution of less, version 444, released 09 Jun 2011.
+ This is the distribution of less, version 458, released 04 Apr 2013.
This program is part of the GNU project (http://www.gnu.org).
This program is free software. You may redistribute it and/or
@@ -13,7 +13,7 @@
or
2. The Less License, in the file LICENSE.
- Please report any problems to bug-less@gnu.org or markn@greenwoodsoftware.com.
+ Please report any problems to bug-less@gnu.org.
See http://www.greenwoodsoftware.com/less for the latest info.
=========================================================================
@@ -52,10 +52,11 @@ INSTALLATION (Unix systems only):
regcomp Use the V8-compatible regcomp.
regcomp-local Use Henry Spencer's V8-compatible regcomp
(source is supplied with less).
+ none No regular expressions, only simple string matching.
--with-secure
Builds a "secure" version of less, with some features disabled
- to prevent users from viewing other files, accessing shell
- commands, etc.
+ to prevent users from viewing other files, accessing shell
+ commands, etc.
3. It is a good idea to look over the generated Makefile and defines.h
@@ -88,7 +89,7 @@ INSTALLATION (Unix systems only):
bindir and/or mandir to the appropriate directories.
If you have any problems building or running "less", suggestions,
-complaints, etc., you may mail to the author at markn@greenwoodsoftware.com.
+complaints, etc., you may mail to bug-less@gnu.org.
Note to hackers: comments noting possible improvements are enclosed
in double curly brackets {{ like this }}.
View
7 external/bsd/less/dist/brac.c
@@ -1,13 +1,12 @@
-/* $NetBSD */
+/* $NetBSD: brac.c,v 1.1.1.2 2013/09/04 19:35:03 tron Exp $ */
/*
- * Copyright (C) 1984-2011 Mark Nudelman
+ * Copyright (C) 1984-2012 Mark Nudelman
*
* You may distribute under the terms of either the GNU General Public
* License or the Less License, as specified in the README file.
*
- * For more information about less, or for information on how to
- * contact the author, see the README file.
+ * For more information, see the README file.
*/
View
20 external/bsd/less/dist/ch.c
@@ -1,13 +1,12 @@
-/* $NetBSD */
+/* $NetBSD: ch.c,v 1.1.1.2 2013/09/04 19:35:03 tron Exp $ */
/*
- * Copyright (C) 1984-2011 Mark Nudelman
+ * Copyright (C) 1984-2012 Mark Nudelman
*
* You may distribute under the terms of either the GNU General Public
* License or the Less License, as specified in the README file.
*
- * For more information about less, or for information on how to
- * contact the author, see the README file.
+ * For more information, see the README file.
*/
@@ -584,6 +583,8 @@ ch_length()
return (NULL_POSITION);
if (ch_flags & CH_HELPFILE)
return (size_helpdata);
+ if (ch_flags & CH_NODATA)
+ return (0);
return (ch_fsize);
}
@@ -808,6 +809,17 @@ seekable(f)
}
/*
+ * Force EOF to be at the current read position.
+ * This is used after an ignore_eof read, during which the EOF may change.
+ */
+ public void
+ch_set_eof()
+{
+ ch_fsize = ch_fpos;
+}
+
+
+/*
* Initialize file state for a new file.
*/
public void
View
7 external/bsd/less/dist/charset.c
@@ -1,13 +1,12 @@
-/* $NetBSD */
+/* $NetBSD: charset.c,v 1.1.1.2 2013/09/04 19:35:03 tron Exp $ */
/*
- * Copyright (C) 1984-2011 Mark Nudelman
+ * Copyright (C) 1984-2012 Mark Nudelman
*
* You may distribute under the terms of either the GNU General Public
* License or the Less License, as specified in the README file.
*
- * For more information about less, or for information on how to
- * contact the author, see the README file.
+ * For more information, see the README file.
*/
View
7 external/bsd/less/dist/charset.h
@@ -1,13 +1,12 @@
-/* $NetBSD */
+/* $NetBSD: charset.h,v 1.1.1.2 2013/09/04 19:35:03 tron Exp $ */
/*
- * Copyright (C) 2005-2011 Mark Nudelman
+ * Copyright (C) 1984-2012 Mark Nudelman
*
* You may distribute under the terms of either the GNU General Public
* License or the Less License, as specified in the README file.
*
- * For more information about less, or for information on how to
- * contact the author, see the README file.
+ * For more information, see the README file.
*/
#define IS_ASCII_OCTET(c) (((c) & 0x80) == 0)
View
12 external/bsd/less/dist/cmd.h
@@ -1,17 +1,16 @@
-/* $NetBSD */
+/* $NetBSD: cmd.h,v 1.1.1.2 2013/09/04 19:35:03 tron Exp $ */
/*
- * Copyright (C) 1984-2011 Mark Nudelman
+ * Copyright (C) 1984-2012 Mark Nudelman
*
* You may distribute under the terms of either the GNU General Public
* License or the Less License, as specified in the README file.
*
- * For more information about less, or for information on how to
- * contact the author, see the README file.
+ * For more information, see the README file.
*/
-#define MAX_USERCMD 500
+#define MAX_USERCMD 1000
#define MAX_CMDLEN 16
#define A_B_LINE 2
@@ -68,6 +67,7 @@
#define A_NEXT_TAG 53
#define A_PREV_TAG 54
#define A_FILTER 55
+#define A_F_UNTIL_HILITE 56
#define A_INVALID 100
#define A_NOACTION 101
@@ -80,7 +80,7 @@
#define A_EXTRA 0200
-/* Line editting characters */
+/* Line editing characters */
#define EC_BACKSPACE 1
#define EC_LINEKILL 2
View
77 external/bsd/less/dist/cmdbuf.c
@@ -1,13 +1,12 @@
-/* $NetBSD */
+/* $NetBSD: cmdbuf.c,v 1.1.1.2 2013/09/04 19:35:03 tron Exp $ */
/*
- * Copyright (C) 1984-2011 Mark Nudelman
+ * Copyright (C) 1984-2012 Mark Nudelman
*
* You may distribute under the terms of either the GNU General Public
* License or the Less License, as specified in the README file.
*
- * For more information about less, or for information on how to
- * contact the author, see the README file.
+ * For more information, see the README file.
*/
@@ -32,6 +31,7 @@ static int prompt_col; /* Column of cursor just after prompt */
static char *cp; /* Pointer into cmdbuf */
static int cmd_offset; /* Index into cmdbuf of first displayed char */
static int literal; /* Next input char should not be interpreted */
+static int updown_match = -1; /* Prefix length in up/down movement */
#if TAB_COMPLETE_FILENAME
static int cmd_complete();
@@ -124,6 +124,7 @@ cmd_reset()
cmd_offset = 0;
literal = 0;
cmd_mbc_buf_len = 0;
+ updown_match = -1;
}
/*
@@ -134,6 +135,7 @@ clear_cmd()
{
cmd_col = prompt_col = 0;
cmd_mbc_buf_len = 0;
+ updown_match = -1;
}
/*
@@ -506,6 +508,7 @@ cmd_ichar(cs, clen)
/*
* Reprint the tail of the line from the inserted char.
*/
+ updown_match = -1;
cmd_repaint(cp);
cmd_right();
return (CC_OK);
@@ -549,6 +552,7 @@ cmd_erase()
/*
* Repaint the buffer after the erased char.
*/
+ updown_match = -1;
cmd_repaint(cp);
/*
@@ -645,6 +649,7 @@ cmd_kill()
cmd_offset = 0;
cmd_home();
*cp = '\0';
+ updown_match = -1;
cmd_repaint(cp);
/*
@@ -677,12 +682,15 @@ set_mlist(mlist, cmdflags)
#if CMD_HISTORY
/*
* Move up or down in the currently selected command history list.
+ * Only consider entries whose first updown_match chars are equal to
+ * cmdbuf's corresponding chars.
*/
static int
cmd_updown(action)
int action;
{
char *s;
+ struct mlist *ml;
if (curr_mlist == NULL)
{
@@ -692,24 +700,47 @@ cmd_updown(action)
bell();
return (CC_OK);
}
- cmd_home();
- clear_eol();
+
+ if (updown_match < 0)
+ {
+ updown_match = cp - cmdbuf;
+ }
+
/*
- * Move curr_mp to the next/prev entry.
+ * Find the next history entry which matches.
*/
- if (action == EC_UP)
- curr_mlist->curr_mp = curr_mlist->curr_mp->prev;
- else
- curr_mlist->curr_mp = curr_mlist->curr_mp->next;
+ for (ml = curr_mlist->curr_mp;;)
+ {
+ ml = (action == EC_UP) ? ml->prev : ml->next;
+ if (ml == curr_mlist)
+ {
+ /*
+ * We reached the end (or beginning) of the list.
+ */
+ break;
+ }
+ if (strncmp(cmdbuf, ml->string, updown_match) == 0)
+ {
+ /*
+ * This entry matches; stop here.
+ * Copy the entry into cmdbuf and echo it on the screen.
+ */
+ curr_mlist->curr_mp = ml;
+ s = ml->string;
+ if (s == NULL)
+ s = "";
+ cmd_home();
+ clear_eol();
+ strcpy(cmdbuf, s);
+ for (cp = cmdbuf; *cp != '\0'; )
+ cmd_right();
+ return (CC_OK);
+ }
+ }
/*
- * Copy the entry into cmdbuf and echo it on the screen.
+ * We didn't find a history entry that matches.
*/
- s = curr_mlist->curr_mp->string;
- if (s == NULL)
- s = "";
- strcpy(cmdbuf, s);
- for (cp = cmdbuf; *cp != '\0'; )
- cmd_right();
+ bell();
return (CC_OK);
}
#endif
@@ -1058,7 +1089,11 @@ init_compl()
tk_text = fcomplete(word);
} else
{
+#if MSDOS_COMPILER
+ char *qword = NULL;
+#else
char *qword = shell_quote(word+1);
+#endif
if (qword == NULL)
tk_text = fcomplete(word+1);
else
@@ -1459,9 +1494,6 @@ save_cmdhist()
FILE *f;
int modified = 0;
- filename = histfile_name();
- if (filename == NULL)
- return;
if (mlist_search.modified)
modified = 1;
#if SHELL_ESCAPE || PIPEC
@@ -1470,6 +1502,9 @@ save_cmdhist()
#endif
if (!modified)
return;
+ filename = histfile_name();
+ if (filename == NULL)
+ return;
f = fopen(filename, "w");
free(filename);
if (f == NULL)
View
77 external/bsd/less/dist/command.c
@@ -1,13 +1,12 @@
-/* $NetBSD */
+/* $NetBSD: command.c,v 1.1.1.2 2013/09/04 19:35:03 tron Exp $ */
/*
- * Copyright (C) 1984-2011 Mark Nudelman
+ * Copyright (C) 1984-2012 Mark Nudelman
*
* You may distribute under the terms of either the GNU General Public
* License or the Less License, as specified in the README file.
*
- * For more information about less, or for information on how to
- * contact the author, see the README file.
+ * For more information, see the README file.
*/
@@ -38,6 +37,7 @@ extern int ignore_eoi;
extern int secure;
extern int hshift;
extern int show_attn;
+extern POSITION highest_hilite;
extern char *every_first_cmd;
extern char *curr_altfilename;
extern char version[];
@@ -104,8 +104,8 @@ cmd_exec()
static void
start_mca(action, prompt, mlist, cmdflags)
int action;
- char *prompt;
- void *mlist;
+ constant char *prompt;
+ constant void *mlist;
int cmdflags;
{
mca = action;
@@ -682,7 +682,7 @@ make_display()
static void
prompt()
{
- register char *p;
+ register constant char *p;
if (ungot != NULL)
{
@@ -958,6 +958,46 @@ multi_search(pattern, n)
}
/*
+ * Forward forever, or until a highlighted line appears.
+ */
+ static int
+forw_loop(until_hilite)
+ int until_hilite;
+{
+ POSITION curr_len;
+
+ if (ch_getflags() & CH_HELPFILE)
+ return (A_NOACTION);
+
+ cmd_exec();
+ jump_forw();
+ curr_len = ch_length();
+ highest_hilite = until_hilite ? curr_len : NULL_POSITION;
+ ignore_eoi = 1;
+ while (!sigs)
+ {
+ if (until_hilite && highest_hilite > curr_len)
+ {
+ bell();
+ break;
+ }
+ make_display();
+ forward(1, 0, 0);
+ }
+ ignore_eoi = 0;
+ ch_set_eof();
+
+ /*
+ * This gets us back in "F mode" after processing
+ * a non-abort signal (e.g. window-change).
+ */
+ if (sigs && !ABORT_SIGS())
+ return (until_hilite ? A_F_UNTIL_HILITE : A_F_FOREVER);
+
+ return (A_NOACTION);
+}
+
+/*
* Main command processor.
* Accept and execute commands until a quit command.
*/
@@ -975,6 +1015,7 @@ commands()
IFILE old_ifile;
IFILE new_ifile;
char *tagfile;
+ int until_hilite = 0;
search_type = SRCH_FORW;
wscroll = (sc_height + 1) / 2;
@@ -1202,23 +1243,11 @@ commands()
/*
* Forward forever, ignoring EOF.
*/
- if (ch_getflags() & CH_HELPFILE)
- break;
- cmd_exec();
- jump_forw();
- ignore_eoi = 1;
- while (!sigs)
- {
- make_display();
- forward(1, 0, 0);
- }
- ignore_eoi = 0;
- /*
- * This gets us back in "F mode" after processing
- * a non-abort signal (e.g. window-change).
- */
- if (sigs && !ABORT_SIGS())
- newaction = A_F_FOREVER;
+ newaction = forw_loop(0);
+ break;
+
+ case A_F_UNTIL_HILITE:
+ newaction = forw_loop(1);
break;
case A_F_SCROLL:
View
465 external/bsd/less/dist/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.67 for less 1.
+# Generated by GNU Autoconf 2.68 for less 1.
#
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -89,6 +89,7 @@ fi
IFS=" "" $as_nl"
# Find who we are. Look in the path if we contain no directory separator.
+as_myself=
case $0 in #((
*[\\/]* ) as_myself=$0 ;;
*) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -214,11 +215,18 @@ IFS=$as_save_IFS
# We cannot yet assume a decent shell, so we have to provide a
# neutralization value for shells without unset; and this also
# works around shells that cannot unset nonexistent variables.
+ # Preserve -v and -x to the replacement shell.
BASH_ENV=/dev/null
ENV=/dev/null
(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
export CONFIG_SHELL
- exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
+ case $- in # ((((
+ *v*x* | *x*v* ) as_opts=-vx ;;
+ *v* ) as_opts=-v ;;
+ *x* ) as_opts=-x ;;
+ * ) as_opts= ;;
+ esac
+ exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"}
fi
if test x$as_have_required = xno; then :
@@ -1067,7 +1075,7 @@ Try \`$0 --help' for more information"
$as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
$as_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
@@ -1281,7 +1289,7 @@ Optional Packages:
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
--with-secure Compile in secure mode
--with-no-float Do not use floating point
- --with-regex={auto,pcre,posix,regcmp,re_comp,regcomp,regcomp-local} Select a regular expression library auto
+ --with-regex={auto,gnu,pcre,posix,regcmp,re_comp,regcomp,regcomp-local,none} Select a regular expression library auto
--with-editor=PROGRAM use PROGRAM as the default editor vi
Some influential environment variables:
@@ -1361,7 +1369,7 @@ test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
less configure 1
-generated by GNU Autoconf 2.67
+generated by GNU Autoconf 2.68
Copyright (C) 2010 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
@@ -1407,7 +1415,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_retval=1
fi
- eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
as_fn_set_status $ac_retval
} # ac_fn_c_try_compile
@@ -1453,7 +1461,7 @@ fi
# interfere with the next link command; also delete a directory that is
# left behind by Apple's compiler. We do this before executing the actions.
rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
as_fn_set_status $ac_retval
} # ac_fn_c_try_link
@@ -1490,7 +1498,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_retval=1
fi
- eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
as_fn_set_status $ac_retval
} # ac_fn_c_try_cpp
@@ -1532,7 +1540,7 @@ sed 's/^/| /' conftest.$ac_ext >&5
ac_retval=$ac_status
fi
rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
as_fn_set_status $ac_retval
} # ac_fn_c_try_run
@@ -1545,10 +1553,10 @@ fi
ac_fn_c_check_header_mongrel ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval "test \"\${$3+set}\"" = set; then :
+ if eval \${$3+:} false; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if eval "test \"\${$3+set}\"" = set; then :
+if eval \${$3+:} false; then :
$as_echo_n "(cached) " >&6
fi
eval ac_res=\$$3
@@ -1611,7 +1619,7 @@ $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
esac
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if eval "test \"\${$3+set}\"" = set; then :
+if eval \${$3+:} false; then :
$as_echo_n "(cached) " >&6
else
eval "$3=\$ac_header_compiler"
@@ -1620,7 +1628,7 @@ eval ac_res=\$$3
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
fi
- eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_check_header_mongrel
@@ -1633,7 +1641,7 @@ ac_fn_c_check_header_compile ()
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if eval "test \"\${$3+set}\"" = set; then :
+if eval \${$3+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -1651,7 +1659,7 @@ fi
eval ac_res=\$$3
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_check_header_compile
@@ -1664,7 +1672,7 @@ ac_fn_c_check_type ()
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if eval "test \"\${$3+set}\"" = set; then :
+if eval \${$3+:} false; then :
$as_echo_n "(cached) " >&6
else
eval "$3=no"
@@ -1705,7 +1713,7 @@ fi
eval ac_res=\$$3
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_check_type
@@ -1717,7 +1725,7 @@ ac_fn_c_check_func ()
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if eval "test \"\${$3+set}\"" = set; then :
+if eval \${$3+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -1772,7 +1780,7 @@ fi
eval ac_res=\$$3
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
} # ac_fn_c_check_func
cat >config.log <<_ACEOF
@@ -1780,7 +1788,7 @@ This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by less $as_me 1, which was
-generated by GNU Autoconf 2.67. Invocation command line was
+generated by GNU Autoconf 2.68. Invocation command line was
$ $0 $@
@@ -2142,7 +2150,7 @@ if test -n "$ac_tool_prefix"; then
set dummy ${ac_tool_prefix}gcc; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then :
+if ${ac_cv_prog_CC+:} false; then :
$as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
@@ -2182,7 +2190,7 @@ if test -z "$ac_cv_prog_CC"; then
set dummy gcc; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
+if ${ac_cv_prog_ac_ct_CC+:} false; then :
$as_echo_n "(cached) " >&6
else
if test -n "$ac_ct_CC"; then
@@ -2235,7 +2243,7 @@ if test -z "$CC"; then
set dummy ${ac_tool_prefix}cc; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then :
+if ${ac_cv_prog_CC+:} false; then :
$as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
@@ -2275,7 +2283,7 @@ if test -z "$CC"; then
set dummy cc; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then :
+if ${ac_cv_prog_CC+:} false; then :
$as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
@@ -2334,7 +2342,7 @@ if test -z "$CC"; then
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_CC+set}" = set; then :
+if ${ac_cv_prog_CC+:} false; then :
$as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
@@ -2378,7 +2386,7 @@ do
set dummy $ac_prog; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
+if ${ac_cv_prog_ac_ct_CC+:} false; then :
$as_echo_n "(cached) " >&6
else
if test -n "$ac_ct_CC"; then
@@ -2661,7 +2669,7 @@ rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
ac_clean_files=$ac_clean_files_save
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
$as_echo_n "checking for suffix of object files... " >&6; }
-if test "${ac_cv_objext+set}" = set; then :
+if ${ac_cv_objext+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -2712,7 +2720,7 @@ OBJEXT=$ac_cv_objext
ac_objext=$OBJEXT
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if test "${ac_cv_c_compiler_gnu+set}" = set; then :
+if ${ac_cv_c_compiler_gnu+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -2749,7 +2757,7 @@ ac_test_CFLAGS=${CFLAGS+set}
ac_save_CFLAGS=$CFLAGS
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if test "${ac_cv_prog_cc_g+set}" = set; then :
+if ${ac_cv_prog_cc_g+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_save_c_werror_flag=$ac_c_werror_flag
@@ -2827,7 +2835,7 @@ else
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if test "${ac_cv_prog_cc_c89+set}" = set; then :
+if ${ac_cv_prog_cc_c89+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_cv_prog_cc_c89=no
@@ -2925,7 +2933,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5
$as_echo_n "checking for library containing strerror... " >&6; }
-if test "${ac_cv_search_strerror+set}" = set; then :
+if ${ac_cv_search_strerror+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_func_search_save_LIBS=$LIBS
@@ -2959,11 +2967,11 @@ for ac_lib in '' cposix; do
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext
- if test "${ac_cv_search_strerror+set}" = set; then :
+ if ${ac_cv_search_strerror+:} false; then :
break
fi
done
-if test "${ac_cv_search_strerror+set}" = set; then :
+if ${ac_cv_search_strerror+:} false; then :
else
ac_cv_search_strerror=no
@@ -2991,7 +2999,7 @@ if test -n "$CPP" && test -d "$CPP"; then
CPP=
fi
if test -z "$CPP"; then
- if test "${ac_cv_prog_CPP+set}" = set; then :
+ if ${ac_cv_prog_CPP+:} false; then :
$as_echo_n "(cached) " >&6
else
# Double quotes because CPP needs to be expanded
@@ -3119,7 +3127,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if test "${ac_cv_path_GREP+set}" = set; then :
+if ${ac_cv_path_GREP+:} false; then :
$as_echo_n "(cached) " >&6
else
if test -z "$GREP"; then
@@ -3182,7 +3190,7 @@ $as_echo "$ac_cv_path_GREP" >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
$as_echo_n "checking for egrep... " >&6; }
-if test "${ac_cv_path_EGREP+set}" = set; then :
+if ${ac_cv_path_EGREP+:} false; then :
$as_echo_n "(cached) " >&6
else
if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
@@ -3250,7 +3258,7 @@ $as_echo "$ac_cv_path_EGREP" >&6; }
if test $ac_cv_c_compiler_gnu = yes; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5
$as_echo_n "checking whether $CC needs -traditional... " >&6; }
-if test "${ac_cv_prog_gcc_traditional+set}" = set; then :
+if ${ac_cv_prog_gcc_traditional+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_pattern="Autoconf.*'x'"
@@ -3335,7 +3343,7 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
$as_echo_n "checking for a BSD-compatible install... " >&6; }
if test -z "$INSTALL"; then
-if test "${ac_cv_path_install+set}" = set; then :
+if ${ac_cv_path_install+:} false; then :
$as_echo_n "(cached) " >&6
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3422,7 +3430,7 @@ if test "$enable_largefile" != no; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
-if test "${ac_cv_sys_largefile_CC+set}" = set; then :
+if ${ac_cv_sys_largefile_CC+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_cv_sys_largefile_CC=no
@@ -3473,7 +3481,7 @@ $as_echo "$ac_cv_sys_largefile_CC" >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
-if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
+if ${ac_cv_sys_file_offset_bits+:} false; then :
$as_echo_n "(cached) " >&6
else
while :; do
@@ -3542,7 +3550,7 @@ rm -rf conftest*
if test $ac_cv_sys_file_offset_bits = unknown; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
-if test "${ac_cv_sys_large_files+set}" = set; then :
+if ${ac_cv_sys_large_files+:} false; then :
$as_echo_n "(cached) " >&6
else
while :; do
@@ -3615,7 +3623,7 @@ fi
# Checks for general libraries.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgoto in -ltinfo" >&5
$as_echo_n "checking for tgoto in -ltinfo... " >&6; }
-if test "${ac_cv_lib_tinfo_tgoto+set}" = set; then :
+if ${ac_cv_lib_tinfo_tgoto+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -3649,7 +3657,7 @@ LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgoto" >&5
$as_echo "$ac_cv_lib_tinfo_tgoto" >&6; }
-if test "x$ac_cv_lib_tinfo_tgoto" = x""yes; then :
+if test "x$ac_cv_lib_tinfo_tgoto" = xyes; then :
have_tinfo=yes
else
have_tinfo=no
@@ -3657,7 +3665,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lxcurses" >&5
$as_echo_n "checking for initscr in -lxcurses... " >&6; }
-if test "${ac_cv_lib_xcurses_initscr+set}" = set; then :
+if ${ac_cv_lib_xcurses_initscr+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -3691,7 +3699,7 @@ LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xcurses_initscr" >&5
$as_echo "$ac_cv_lib_xcurses_initscr" >&6; }
-if test "x$ac_cv_lib_xcurses_initscr" = x""yes; then :
+if test "x$ac_cv_lib_xcurses_initscr" = xyes; then :
have_xcurses=yes
else
have_xcurses=no
@@ -3699,7 +3707,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lncursesw" >&5
$as_echo_n "checking for initscr in -lncursesw... " >&6; }
-if test "${ac_cv_lib_ncursesw_initscr+set}" = set; then :
+if ${ac_cv_lib_ncursesw_initscr+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -3733,7 +3741,7 @@ LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncursesw_initscr" >&5
$as_echo "$ac_cv_lib_ncursesw_initscr" >&6; }
-if test "x$ac_cv_lib_ncursesw_initscr" = x""yes; then :
+if test "x$ac_cv_lib_ncursesw_initscr" = xyes; then :
have_ncursesw=yes
else
have_ncursesw=no
@@ -3741,7 +3749,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lncurses" >&5
$as_echo_n "checking for initscr in -lncurses... " >&6; }
-if test "${ac_cv_lib_ncurses_initscr+set}" = set; then :
+if ${ac_cv_lib_ncurses_initscr+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -3775,7 +3783,7 @@ LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_initscr" >&5
$as_echo "$ac_cv_lib_ncurses_initscr" >&6; }
-if test "x$ac_cv_lib_ncurses_initscr" = x""yes; then :
+if test "x$ac_cv_lib_ncurses_initscr" = xyes; then :
have_ncurses=yes
else
have_ncurses=no
@@ -3783,7 +3791,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lcurses" >&5
$as_echo_n "checking for initscr in -lcurses... " >&6; }
-if test "${ac_cv_lib_curses_initscr+set}" = set; then :
+if ${ac_cv_lib_curses_initscr+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -3817,7 +3825,7 @@ LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_initscr" >&5
$as_echo "$ac_cv_lib_curses_initscr" >&6; }
-if test "x$ac_cv_lib_curses_initscr" = x""yes; then :
+if test "x$ac_cv_lib_curses_initscr" = xyes; then :
have_curses=yes
else
have_curses=no
@@ -3825,7 +3833,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5
$as_echo_n "checking for tgetent in -ltermcap... " >&6; }
-if test "${ac_cv_lib_termcap_tgetent+set}" = set; then :
+if ${ac_cv_lib_termcap_tgetent+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -3859,7 +3867,7 @@ LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5
$as_echo "$ac_cv_lib_termcap_tgetent" >&6; }
-if test "x$ac_cv_lib_termcap_tgetent" = x""yes; then :
+if test "x$ac_cv_lib_termcap_tgetent" = xyes; then :
have_termcap=yes
else
have_termcap=no
@@ -3867,7 +3875,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermlib" >&5
$as_echo_n "checking for tgetent in -ltermlib... " >&6; }
-if test "${ac_cv_lib_termlib_tgetent+set}" = set; then :
+if ${ac_cv_lib_termlib_tgetent+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -3901,66 +3909,20 @@ LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termlib_tgetent" >&5
$as_echo "$ac_cv_lib_termlib_tgetent" >&6; }
-if test "x$ac_cv_lib_termlib_tgetent" = x""yes; then :
+if test "x$ac_cv_lib_termlib_tgetent" = xyes; then :
have_termlib=yes
else
have_termlib=no
fi
-# Regular expressions (regcmp) are in -lgen on Solaris 2,
-# and in -lintl on SCO Unix.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for regcmp in -lgen" >&5
-$as_echo_n "checking for regcmp in -lgen... " >&6; }
-if test "${ac_cv_lib_gen_regcmp+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lgen $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char regcmp ();
-int
-main ()
-{
-return regcmp ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_gen_regcmp=yes
-else
- ac_cv_lib_gen_regcmp=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_regcmp" >&5
-$as_echo "$ac_cv_lib_gen_regcmp" >&6; }
-if test "x$ac_cv_lib_gen_regcmp" = x""yes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBGEN 1
-_ACEOF
-
- LIBS="-lgen $LIBS"
-
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for regcmp in -lintl" >&5
-$as_echo_n "checking for regcmp in -lintl... " >&6; }
-if test "${ac_cv_lib_intl_regcmp+set}" = set; then :
+# Regular expressions (regcmp) are in -lgen on Solaris 2, (but in libc
+# at least on Solaris 10 (2.10)) and in -lintl on SCO Unix.
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing regcmp" >&5
+$as_echo_n "checking for library containing regcmp... " >&6; }
+if ${ac_cv_search_regcmp+:} false; then :
$as_echo_n "(cached) " >&6
else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lintl $LIBS"
+ ac_func_search_save_LIBS=$LIBS
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -3979,68 +3941,35 @@ return regcmp ();
return 0;
}
_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_intl_regcmp=yes
-else
- ac_cv_lib_intl_regcmp=no
+for ac_lib in '' gen intl PW; do
+ if test -z "$ac_lib"; then
+ ac_res="none required"
+ else
+ ac_res=-l$ac_lib
+ LIBS="-l$ac_lib $ac_func_search_save_LIBS"
+ fi
+ if ac_fn_c_try_link "$LINENO"; then :
+ ac_cv_search_regcmp=$ac_res
fi
rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_regcmp" >&5
-$as_echo "$ac_cv_lib_intl_regcmp" >&6; }
-if test "x$ac_cv_lib_intl_regcmp" = x""yes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBINTL 1
-_ACEOF
-
- LIBS="-lintl $LIBS"
-
+ conftest$ac_exeext
+ if ${ac_cv_search_regcmp+:} false; then :
+ break
fi
+done
+if ${ac_cv_search_regcmp+:} false; then :
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for regcmp in -lPW" >&5
-$as_echo_n "checking for regcmp in -lPW... " >&6; }
-if test "${ac_cv_lib_PW_regcmp+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lPW $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char regcmp ();
-int
-main ()
-{
-return regcmp ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_PW_regcmp=yes
else
- ac_cv_lib_PW_regcmp=no
+ ac_cv_search_regcmp=no
fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+rm conftest.$ac_ext
+LIBS=$ac_func_search_save_LIBS
fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_PW_regcmp" >&5
-$as_echo "$ac_cv_lib_PW_regcmp" >&6; }
-if test "x$ac_cv_lib_PW_regcmp" = x""yes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBPW 1
-_ACEOF
-
- LIBS="-lPW $LIBS"
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_regcmp" >&5
+$as_echo "$ac_cv_search_regcmp" >&6; }
+ac_res=$ac_cv_search_regcmp
+if test "$ac_res" != no; then :
+ test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
fi
@@ -4310,7 +4239,7 @@ LIBS="$LIBS $TERMLIBS"
# Checks for header files.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
$as_echo_n "checking for ANSI C header files... " >&6; }
-if test "${ac_cv_header_stdc+set}" = set; then :
+if ${ac_cv_header_stdc+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4454,7 +4383,7 @@ done
# Checks for typedefs, structures, and compiler characteristics.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
$as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
-if test "${ac_cv_header_stat_broken+set}" = set; then :
+if ${ac_cv_header_stat_broken+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4496,7 +4425,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
-if test "${ac_cv_c_const+set}" = set; then :
+if ${ac_cv_c_const+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4575,7 +4504,7 @@ $as_echo "#define const /**/" >>confdefs.h
fi
ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
-if test "x$ac_cv_type_off_t" = x""yes; then :
+if test "x$ac_cv_type_off_t" = xyes; then :
else
@@ -4586,7 +4515,7 @@ _ACEOF
fi
ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
-if test "x$ac_cv_type_size_t" = x""yes; then :
+if test "x$ac_cv_type_size_t" = xyes; then :
else
@@ -4598,7 +4527,7 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
-if test "${ac_cv_header_time+set}" = set; then :
+if ${ac_cv_header_time+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4661,9 +4590,10 @@ fi
+
# Checks for identifiers.
ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
-if test "x$ac_cv_type_off_t" = x""yes; then :
+if test "x$ac_cv_type_off_t" = xyes; then :
else
@@ -4766,7 +4696,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
# Checks for library functions.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
$as_echo_n "checking return type of signal handlers... " >&6; }
-if test "${ac_cv_type_signal+set}" = set; then :
+if ${ac_cv_type_signal+:} false; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4894,7 +4824,7 @@ rm -f core conftest.err conftest.$ac_objext \
# Some systems have termios.h but not the corresponding functions.
ac_fn_c_check_func "$LINENO" "tcgetattr" "ac_cv_func_tcgetattr"
-if test "x$ac_cv_func_tcgetattr" = x""yes; then :
+if test "x$ac_cv_func_tcgetattr" = xyes; then :
$as_echo "#define HAVE_TERMIOS_FUNCS 1" >>confdefs.h
fi
@@ -4986,7 +4916,7 @@ rm -f core conftest.err conftest.$ac_objext \
ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "#include <signal.h>
"
-if test "x$ac_cv_type_sigset_t" = x""yes; then :
+if test "x$ac_cv_type_sigset_t" = xyes; then :
cat >>confdefs.h <<_ACEOF
#define HAVE_SIGSET_T 1
@@ -5258,8 +5188,7 @@ fi
# Checks for regular expression functions.
have_regex=no
have_posix_regex=unknown
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for regcomp" >&5
-$as_echo_n "checking for regcomp... " >&6; }
+supported_regex=""
# Select a regular expression library.
WANT_REGEX=auto
@@ -5274,6 +5203,8 @@ if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = posix; then
# Some versions of Solaris have a regcomp() function, but it doesn't work!
# So we run a test program. If we're cross-compiling, do it the old way.
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for POSIX regcomp" >&5
+$as_echo_n "checking for POSIX regcomp... " >&6; }
if test "$cross_compiling" = yes; then :
have_posix_regex=unknown
else
@@ -5302,10 +5233,10 @@ rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
fi
if test $have_posix_regex = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: using POSIX regcomp" >&5
-$as_echo "using POSIX regcomp" >&6; }
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
$as_echo "#define HAVE_POSIX_REGCOMP 1" >>confdefs.h
-
+ supported_regex="$supported_regex posix"
have_regex=yes
elif test $have_posix_regex = unknown; then
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -5322,10 +5253,10 @@ regex_t *r; regfree(r);
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: using POSIX regcomp" >&5
-$as_echo "using POSIX regcomp" >&6; }
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
$as_echo "#define HAVE_POSIX_REGCOMP 1" >>confdefs.h
- have_regex=yes
+ have_regex=yes; supported_regex="$supported_regex posix"
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
@@ -5340,7 +5271,7 @@ if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = pcre; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pcre_compile in -lpcre" >&5
$as_echo_n "checking for pcre_compile in -lpcre... " >&6; }
-if test "${ac_cv_lib_pcre_pcre_compile+set}" = set; then :
+if ${ac_cv_lib_pcre_pcre_compile+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
@@ -5374,10 +5305,55 @@ LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pcre_pcre_compile" >&5
$as_echo "$ac_cv_lib_pcre_pcre_compile" >&6; }
-if test "x$ac_cv_lib_pcre_pcre_compile" = x""yes; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: using pcre" >&5
-$as_echo "using pcre" >&6; }; $as_echo "#define HAVE_PCRE 1" >>confdefs.h
- LIBS="$LIBS -lpcre" have_regex=yes
+if test "x$ac_cv_lib_pcre_pcre_compile" = xyes; then :
+ $as_echo "#define HAVE_PCRE 1" >>confdefs.h
+ LIBS="$LIBS -lpcre" have_regex=yes; supported_regex="$supported_regex pcre"
+fi
+
+fi
+fi
+
+if test $have_regex = no; then
+if test $WANT_REGEX = auto -o $WANT_REGEX = gnu; then
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for re_compile_pattern in -lc" >&5
+$as_echo_n "checking for re_compile_pattern in -lc... " >&6; }
+if ${ac_cv_lib_c_re_compile_pattern+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lc $LIBS"
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
+#ifdef __cplusplus
+extern "C"
+#endif
+char re_compile_pattern ();
+int
+main ()
+{
+return re_compile_pattern ();
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ ac_cv_lib_c_re_compile_pattern=yes
+else
+ ac_cv_lib_c_re_compile_pattern=no
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_re_compile_pattern" >&5
+$as_echo "$ac_cv_lib_c_re_compile_pattern" >&6; }
+if test "x$ac_cv_lib_c_re_compile_pattern" = xyes; then :
+ $as_echo "#define HAVE_GNU_REGEX 1" >>confdefs.h
+ have_regex=yes; supported_regex="$supported_regex gnu"
fi
fi
@@ -5386,10 +5362,9 @@ fi
if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = regcmp; then
ac_fn_c_check_func "$LINENO" "regcmp" "ac_cv_func_regcmp"
-if test "x$ac_cv_func_regcmp" = x""yes; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: using regcmp" >&5
-$as_echo "using regcmp" >&6; }; $as_echo "#define HAVE_REGCMP 1" >>confdefs.h
- have_regex=yes
+if test "x$ac_cv_func_regcmp" = xyes; then :
+ $as_echo "#define HAVE_REGCMP 1" >>confdefs.h
+ have_regex=yes; supported_regex="$supported_regex regcmp"
fi
fi
@@ -5397,6 +5372,8 @@ fi
if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = regcomp; then
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for V8 regcomp" >&5
+$as_echo_n "checking for V8 regcomp... " >&6; }
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -5410,9 +5387,12 @@ regcomp("");
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: using V8 regcomp" >&5
-$as_echo "using V8 regcomp" >&6; }; $as_echo "#define HAVE_V8_REGCOMP 1" >>confdefs.h
- have_regex=yes
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }; $as_echo "#define HAVE_V8_REGCOMP 1" >>confdefs.h
+ have_regex=yes; supported_regex="$supported_regex regcomp"
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
@@ -5423,29 +5403,41 @@ if test $have_regex = no && test -f ${srcdir}/regexp.c; then
if test $WANT_REGEX = auto -o $WANT_REGEX = regcomp-local; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: using V8 regcomp -- local source" >&5
$as_echo "using V8 regcomp -- local source" >&6; }; $as_echo "#define HAVE_V8_REGCOMP 1" >>confdefs.h
- $as_echo "#define HAVE_REGEXEC2 1" >>confdefs.h
+
+supported_regex="$supported_regex regcomp-local"
+$as_echo "#define HAVE_REGEXEC2 1" >>confdefs.h
REGEX_O='regexp.$(O)' have_regex=yes
fi
fi
if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = re_comp; then
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: using re_comp" >&5
-$as_echo "using re_comp" >&6; }; ac_fn_c_check_func "$LINENO" "re_comp" "ac_cv_func_re_comp"
-if test "x$ac_cv_func_re_comp" = x""yes; then :
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for re_comp" >&5
+$as_echo_n "checking for re_comp... " >&6; }
+ac_fn_c_check_func "$LINENO" "re_comp" "ac_cv_func_re_comp"
+if test "x$ac_cv_func_re_comp" = xyes; then :
$as_echo "#define HAVE_RE_COMP 1" >>confdefs.h
- have_regex=yes
+ have_regex=yes; supported_regex="$supported_regex re_comp"
fi
fi
fi
if test $have_regex = no; then
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot find regular expression library" >&5
-$as_echo "cannot find regular expression library" >&6; }; $as_echo "#define NO_REGEX 1" >>confdefs.h
-
+if test $WANT_REGEX = auto -o $WANT_REGEX = none; then
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: using no regex" >&5
+$as_echo "using no regex" >&6; }
+else
+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find regular expression library" >&5
+$as_echo "$as_me: WARNING: cannot find regular expression library" >&2;}
+fi
+$as_echo "#define NO_REGEX 1" >>confdefs.h
+ supported_regex="$supported_regex none"
fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: regular expression library: $supported_regex" >&5
+$as_echo "regular expression library: $supported_regex" >&6; }
+
# Check whether --with-editor was given.
if test "${with_editor+set}" = set; then :
@@ -5527,10 +5519,21 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
:end' >>confcache
if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
if test -w "$cache_file"; then
- test "x$cache_file" != "x/dev/null" &&
+ if test "x$cache_file" != "x/dev/null"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
$as_echo "$as_me: updating cache $cache_file" >&6;}
- cat confcache >$cache_file
+ if test ! -f "$cache_file" || test -h "$cache_file"; then
+ cat confcache >"$cache_file"
+ else
+ case $cache_file in #(
+ */* | ?:*)
+ mv -f confcache "$cache_file"$$ &&
+ mv -f "$cache_file"$$ "$cache_file" ;; #(
+ *)
+ mv -f confcache "$cache_file" ;;
+ esac
+ fi
+ fi
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
@@ -5562,7 +5565,7 @@ LTLIBOBJS=$ac_ltlibobjs
-: ${CONFIG_STATUS=./config.status}
+: "${CONFIG_STATUS=./config.status}"
ac_write_fail=0
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files $CONFIG_STATUS"
@@ -5663,6 +5666,7 @@ fi
IFS=" "" $as_nl"
# Find who we are. Look in the path if we contain no directory separator.
+as_myself=
case $0 in #((
*[\\/]* ) as_myself=$0 ;;
*) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -5970,7 +5974,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# values after options handling.
ac_log="
This file was extended by less $as_me 1, which was
-generated by GNU Autoconf 2.67. Invocation command line was
+generated by GNU Autoconf 2.68. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@@ -6032,7 +6036,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
less config.status 1
-configured by $0, generated by GNU Autoconf 2.67,
+configured by $0, generated by GNU Autoconf 2.68,
with options \\"\$ac_cs_config\\"
Copyright (C) 2010 Free Software Foundation, Inc.
@@ -6178,9 +6182,10 @@ fi
# after its creation but before its name has been assigned to `$tmp'.
$debug ||
{
- tmp=
+ tmp= ac_tmp=
trap 'exit_status=$?
- { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
+ : "${ac_tmp:=$tmp}"
+ { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
' 0
trap 'as_fn_exit 1' 1 2 13 15
}
@@ -6188,12 +6193,13 @@ $debug ||
{
tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -n "$tmp" && test -d "$tmp"
+ test -d "$tmp"
} ||
{
tmp=./conf$$-$RANDOM
(umask 077 && mkdir "$tmp")
} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
+ac_tmp=$tmp
# Set up the scripts for CONFIG_FILES section.
# No need to generate them if there are no CONFIG_FILES.
@@ -6215,7 +6221,7 @@ else
ac_cs_awk_cr=$ac_cr
fi
-echo 'BEGIN {' >"$tmp/subs1.awk" &&
+echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
_ACEOF
@@ -6243,7 +6249,7 @@ done
rm -f conf$$subs.sh
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
+cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
_ACEOF
sed -n '
h
@@ -6291,7 +6297,7 @@ t delim
rm -f conf$$subs.awk
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
_ACAWK
-cat >>"\$tmp/subs1.awk" <<_ACAWK &&
+cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
for (key in S) S_is_set[key] = 1
FS = ""
@@ -6323,7 +6329,7 @@ if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
else
cat
-fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
+fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
|| as_fn_error $? "could not setup config files machinery" "$LINENO" 5
_ACEOF
@@ -6357,7 +6363,7 @@ fi # test -n "$CONFIG_FILES"
# No need to generate them if there are no CONFIG_HEADERS.
# This happens for instance with `./config.status Makefile'.
if test -n "$CONFIG_HEADERS"; then
-cat >"$tmp/defines.awk" <<\_ACAWK ||
+cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
BEGIN {
_ACEOF
@@ -6369,8 +6375,8 @@ _ACEOF
# handling of long lines.
ac_delim='%!_!# '
for ac_last_try in false false :; do
- ac_t=`sed -n "/$ac_delim/p" confdefs.h`
- if test -z "$ac_t"; then
+ ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
+ if test -z "$ac_tt"; then
break
elif $ac_last_try; then
as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
@@ -6490,7 +6496,7 @@ do
for ac_f
do
case $ac_f in
- -) ac_f="$tmp/stdin";;
+ -) ac_f="$ac_tmp/stdin";;
*) # Look for the file first in the build tree, then in the source tree
# (if the path is not absolute). The absolute path cannot be DOS-style,
# because $ac_f cannot contain `:'.
@@ -6525,7 +6531,7 @@ $as_echo "$as_me: creating $ac_file" >&6;}
esac
case $ac_tag in
- *:-:* | *:-) cat >"$tmp/stdin" \
+ *:-:* | *:-) cat >"$ac_tmp/stdin" \
|| as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
esac
;;
@@ -6656,21 +6662,22 @@ s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
s&@INSTALL@&$ac_INSTALL&;t t
$ac_datarootdir_hack
"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
+eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
+ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
+ { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
+ { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
+ "$ac_tmp/out"`; test -z "$ac_out"; } &&
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined. Please make sure it is defined" >&5
$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined. Please make sure it is defined" >&2;}
- rm -f "$tmp/stdin"
+ rm -f "$ac_tmp/stdin"
case $ac_file in
- -) cat "$tmp/out" && rm -f "$tmp/out";;
- *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
+ -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
+ *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
esac \
|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
;;
@@ -6681,20 +6688,20 @@ which seems to be undefined. Please make sure it is defined" >&2;}
if test x"$ac_file" != x-; then
{
$as_echo "/* $configure_input */" \
- && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
- } >"$tmp/config.h" \
+ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
+ } >"$ac_tmp/config.h" \
|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
- if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
+ if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
$as_echo "$as_me: $ac_file is unchanged" >&6;}
else
rm -f "$ac_file"
- mv "$tmp/config.h" "$ac_file" \
+ mv "$ac_tmp/config.h" "$ac_file" \
|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
fi
else
$as_echo "/* $configure_input */" \
- && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
+ && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
|| as_fn_error $? "could not create -" "$LINENO" 5
fi
;;
View
66 external/bsd/less/dist/configure.ac
@@ -30,11 +30,9 @@ AC_CHECK_LIB(ncurses, initscr, [have_ncurses=yes], [have_ncurses=no])
AC_CHECK_LIB(curses, initscr, [have_curses=yes], [have_curses=no])
AC_CHECK_LIB(termcap, tgetent, [have_termcap=yes], [have_termcap=no])
AC_CHECK_LIB(termlib, tgetent, [have_termlib=yes], [have_termlib=no])
-# Regular expressions (regcmp) are in -lgen on Solaris 2,
-# and in -lintl on SCO Unix.
-AC_CHECK_LIB(gen, regcmp)
-AC_CHECK_LIB(intl, regcmp)
-AC_CHECK_LIB(PW, regcmp)
+# Regular expressions (regcmp) are in -lgen on Solaris 2, (but in libc
+# at least on Solaris 10 (2.10)) and in -lintl on SCO Unix.
+AC_SEARCH_LIBS([regcmp], [gen intl PW])
# Checks for terminal libraries
AC_MSG_CHECKING([for working terminal libraries])
@@ -179,6 +177,8 @@ AC_TYPE_SIZE_T
AC_HEADER_TIME
# Autoheader templates for symbols defined later by AC_DEFINE.
+AH_TEMPLATE([HAVE_GNU_REGEX],
+ [GNU regex library])
AH_TEMPLATE([HAVE_POSIX_REGCOMP],
[POSIX regcomp() and regex.h])
AH_TEMPLATE([HAVE_PCRE],
@@ -383,18 +383,19 @@ fi
# Checks for regular expression functions.
have_regex=no
have_posix_regex=unknown
-AC_MSG_CHECKING(for regcomp)
+supported_regex=""
# Select a regular expression library.
WANT_REGEX=auto
AC_ARG_WITH(regex,
- [ --with-regex={auto,pcre,posix,regcmp,re_comp,regcomp,regcomp-local} Select a regular expression library [auto]],
+ [ --with-regex={auto,gnu,pcre,posix,regcmp,re_comp,regcomp,regcomp-local,none} Select a regular expression library [auto]],
WANT_REGEX="$withval")
if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = posix; then
# Some versions of Solaris have a regcomp() function, but it doesn't work!
# So we run a test program. If we're cross-compiling, do it the old way.
+AC_MSG_CHECKING(for POSIX regcomp)
AC_TRY_RUN([
#include <sys/types.h>
#include <regex.h>
@@ -409,16 +410,16 @@ if (rm.rm_sp != text + 1) exit(1); /* check for correct offset */
exit(0); }],
have_posix_regex=yes, have_posix_regex=no, have_posix_regex=unknown)
if test $have_posix_regex = yes; then
- AC_MSG_RESULT(using POSIX regcomp)
- AC_DEFINE(HAVE_POSIX_REGCOMP)
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_POSIX_REGCOMP) supported_regex="$supported_regex posix"
have_regex=yes
elif test $have_posix_regex = unknown; then
AC_TRY_LINK([
#include <sys/types.h>
#include <regex.h>],
[regex_t *r; regfree(r);],
- AC_MSG_RESULT(using POSIX regcomp)
- AC_DEFINE(HAVE_POSIX_REGCOMP) have_regex=yes)
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_POSIX_REGCOMP) have_regex=yes; supported_regex="$supported_regex posix")
else
AC_MSG_RESULT(no)
fi
@@ -428,41 +429,60 @@ fi
if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = pcre; then
AC_CHECK_LIB(pcre, pcre_compile,
-[AC_MSG_RESULT(using pcre); AC_DEFINE(HAVE_PCRE) LIBS="$LIBS -lpcre" have_regex=yes], [])
+[AC_DEFINE(HAVE_PCRE) LIBS="$LIBS -lpcre" have_regex=yes; supported_regex="$supported_regex pcre"], [])
+fi
+fi
+
+if test $have_regex = no; then
+if test $WANT_REGEX = auto -o $WANT_REGEX = gnu; then
+AC_CHECK_LIB(c, re_compile_pattern,
+[AC_DEFINE(HAVE_GNU_REGEX) have_regex=yes; supported_regex="$supported_regex gnu"], [])
fi
fi
if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = regcmp; then
AC_CHECK_FUNC(regcmp,
-AC_MSG_RESULT(using regcmp); AC_DEFINE(HAVE_REGCMP) have_regex=yes)
+[AC_DEFINE(HAVE_REGCMP) have_regex=yes; supported_regex="$supported_regex regcmp"],[])
fi
fi
if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = regcomp; then
+AC_MSG_CHECKING(for V8 regcomp)
AC_TRY_LINK([
#include "regexp.h"], [regcomp("");],
-AC_MSG_RESULT(using V8 regcomp); AC_DEFINE(HAVE_V8_REGCOMP) have_regex=yes)
+[AC_MSG_RESULT(yes); AC_DEFINE(HAVE_V8_REGCOMP) have_regex=yes; supported_regex="$supported_regex regcomp"],[AC_MSG_RESULT(no)])
fi
fi
if test $have_regex = no && test -f ${srcdir}/regexp.c; then
if test $WANT_REGEX = auto -o $WANT_REGEX = regcomp-local; then
-AC_MSG_RESULT(using V8 regcomp -- local source); AC_DEFINE(HAVE_V8_REGCOMP) AC_DEFINE(HAVE_REGEXEC2) REGEX_O='regexp.$(O)' AC_SUBST(REGEX_O) have_regex=yes
+AC_MSG_RESULT(using V8 regcomp -- local source); AC_DEFINE(HAVE_V8_REGCOMP)
+supported_regex="$supported_regex regcomp-local"
+AC_DEFINE(HAVE_REGEXEC2) REGEX_O='regexp.$(O)' AC_SUBST(REGEX_O) have_regex=yes
fi
fi
if test $have_regex = no; then
if test $WANT_REGEX = auto -o $WANT_REGEX = re_comp; then
-AC_MSG_RESULT(using re_comp); AC_CHECK_FUNC(re_comp, AC_DEFINE(HAVE_RE_COMP) have_regex=yes)
+AC_MSG_CHECKING(for re_comp)
+AC_CHECK_FUNC(re_comp,
+[AC_DEFINE(HAVE_RE_COMP) have_regex=yes; supported_regex="$supported_regex re_comp"],[])
fi
fi
if test $have_regex = no; then
-AC_MSG_RESULT(cannot find regular expression library); AC_DEFINE(NO_REGEX)
+if test $WANT_REGEX = auto -o $WANT_REGEX = none; then
+AC_MSG_RESULT(using no regex)
+else
+AC_MSG_WARN(cannot find regular expression library)
+fi
+AC_DEFINE(NO_REGEX) supported_regex="$supported_regex none"
fi
+AC_MSG_RESULT(regular expression library: $supported_regex)
+
AC_ARG_WITH(editor,
[ --with-editor=PROGRAM use PROGRAM as the default editor [vi]],
AC_DEFINE_UNQUOTED(EDIT_PGM, "$withval"), AC_DEFINE(EDIT_PGM, "vi"))
@@ -649,6 +669,7 @@ AH_TOP([
/*
* Sizes of various buffers.
*/
+#if 0 /* old sizes for small memory machines */
#define CMDBUF_SIZE 512 /* Buffer for multichar commands */
#define UNGOT_SIZE 100 /* Max chars to unget() */
#define LINEBUF_SIZE 1024 /* Max size of line in input file */
@@ -658,6 +679,17 @@ AH_TOP([
#define TERMSBUF_SIZE 1024 /* Buffer to hold termcap strings */
#define TAGLINE_SIZE 512 /* Max size of line in tags file */
#define TABSTOP_MAX 32 /* Max number of custom tab stops */
+#else /* more reasonable sizes for modern machines */
+#define CMDBUF_SIZE 2048 /* Buffer for multichar commands */
+#define UNGOT_SIZE 200 /* Max chars to unget() */
+#define LINEBUF_SIZE 1024 /* Initial max size of line in input file */
+#define OUTBUF_SIZE 1024 /* Output buffer */
+#define PROMPT_SIZE 2048 /* Max size of prompt string */
+#define TERMBUF_SIZE 2048 /* Termcap buffer for tgetent */
+#define TERMSBUF_SIZE 1024 /* Buffer to hold termcap strings */
+#define TAGLINE_SIZE 1024 /* Max size of line in tags file */
+#define TABSTOP_MAX 128 /* Max number of custom tab stops */
+#endif
/* Settings automatically determined by configure. */
])
View
32 external/bsd/less/dist/cvt.c
@@ -1,13 +1,12 @@
-/* $NetBSD */
+/* $NetBSD: cvt.c,v 1.1.1.2 2013/09/04 19:35:03 tron Exp $ */
/*
- * Copyright (C) 1984-2011 Mark Nudelman
+ * Copyright (C) 1984-2012 Mark Nudelman
*
* You may distribute under the terms of either the GNU General Public
* License or the Less License, as specified in the README file.
*
- * For more information about less, or for information on how to
- * contact the author, see the README file.
+ * For more information, see the README file.
*/
/*
@@ -66,6 +65,7 @@ cvt_text(odst, osrc, chpos, lenp, ops)
int ops;
{
char *dst;
+ char *edst = odst;
char *src;
register char *src_end;
LWCHAR ch;
@@ -100,23 +100,17 @@ cvt_text(odst, osrc, chpos, lenp, ops)
if ((ops & CVT_TO_LC) && IS_UPPER(ch))
ch = TO_LOWER(ch);
put_wchar(&dst, ch);
- /*
- * Record the original position of the char.
- * But if we've already recorded a position
- * for this char (due to a backspace), leave
- * it alone; if multiple source chars map to
- * one destination char, we want the position
- * of the first one.
- */
- if (chpos != NULL && chpos[dst_pos] < 0)
+ /* Record the original position of the char. */
+ if (chpos != NULL)
chpos[dst_pos] = src_pos;
}
+ if (dst > edst)
+ edst = dst;
}
- if ((ops & CVT_CRLF) && dst > odst && dst[-1] == '\r')
- dst--;
- *dst = '\0';
+ if ((ops & CVT_CRLF) && edst > odst && edst[-1] == '\r')
+ edst--;
+ *edst = '\0';