From: tomo Date: Thu, 11 Nov 1999 11:30:54 +0000 (+0000) Subject: Sync with r21-2-20. X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=87934618a1a25411f05bf0d13a9e8ecfecac6d0b;p=chise%2Fxemacs-chise.git- Sync with r21-2-20. --- diff --git a/.cvsignore b/.cvsignore index 42e5786..4c21e36 100644 --- a/.cvsignore +++ b/.cvsignore @@ -7,3 +7,6 @@ config.status GNUmakefile Makefile.in so_locations +xemacs-packages +mule-packages +site-packages diff --git a/CHANGES-beta b/CHANGES-beta index 5f58f45..c400359 100644 --- a/CHANGES-beta +++ b/CHANGES-beta @@ -1,4 +1,29 @@ -*- indented-text -*- +to 21.2.20 "Yoko" +-- UTF-8 & file-coding magic cookie fix from MORIOKA Tomohiko +-- bug fixes from Adrian Aichner, Sean MacLennan, and Jeff Miller +-- glyph widget support under X/Athena from Andy Piper +-- tab widget support under X (all variants) from Andy Piper +-- many gutter, redisplay & widget fixes from Andy Piper +-- mswindows mousewheel support from Mike Woolley +-- combo box support under X/Motif from Andy Piper +-- buffer tab grouping from Andy Piper +-- layout widget support from Andy Piper +-- partial display line scrolling support from Andy Piper +-- cleanup patches from Gleb Arshinov +-- hash table FSF API sync from Martin Buchholz +-- widget cleanup from Martin Buchholz +-- process-environment fix for nt from Julian Back +-- widget to frame fix from Jan Vroonhof +-- animated glyph support from Andy Piper +-- glyph redisplay improvements from Andy Piper +-- color cells allocation fix from Lee Kindness +-- recover file fix for windows nt +-- mingw install fix from Craig Lanning +-- recognize keypad keys under MS-Windows from Jonathan Harris +-- Switch gui dialogs to native widgets from Andy Piper +-- fixes from Yoshiki Hayashi and Norbert Koch + to 21.2.19 "Shinjuku" -- various fixes from Gunnar Evermann -- XIM fixes from Kazuyuki IENAGA diff --git a/ChangeLog b/ChangeLog index 883c60b..54f6037 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,91 @@ +1999-11-10 XEmacs Build Bot + + * XEmacs 21.2.20 is released + +1999-09-21 Martin Buchholz + * configure.in: Autodetect Unix98 PTY + +1999-08-30 Robert Pluim + + * README.packages: Add description of package-get-provider + +1999-10-22 Vin Shelton + + * INSTALL: Added more information about README.packages, and + re-numbered some bullets. + +1999-10-24 Jan Vroonhof + + * INSTALL: Update disk requirements. Refer to README.packages + +1999-10-21 Andy Piper + + * configure.in (all_widgets): Only use xaw3d if we really have it. + +1999-10-06 Andy Piper + + * Makefile.in.in: use WINDOWSNT for mingw install. + +1999-08-01 Adrian Aichner + + * etc/DISTRIB: Update IP address of ftp.xemacs.org. + * etc/NEWS: Fix typo + +1999-09-25 Andy Piper + + * configure.in: check for Xaw3d and use in preference to Xaw + +1999-09-21 Martin Buchholz + + * Makefile.in.in: All Makefiles should #include config.h + +1999-09-19 Michael Sperber [Mr. Preprocessor] + + * configure.in (EMACS_CONFIGURATION): Use $configuration, not + $canonical, so that installation paths and dynamic path setup will + stay in synch. + +1999-09-20 Andy Piper + + * Makefile.in.in: use __CYGWIN32__ and __MINGW32__ to predicate + installation linkage. + +1999-08-29 Andreas Jaeger + + * configure.in (machine): Recognize MIPS/Linux. + +1999-08-27 Jan Vroonhof + + * modules/zlib/Makefile (distclean): + * modules/ldap/Makefile (distclean): + * modules/sample/Makefile (distclean): + * modules/base64/Makefile (distclean): new target + + * Makefile.in.in (top_distclean): Add package directories + (SUBDIR_DISTCLEAN): New variable, add module directories + +1999-09-01 Martin Buchholz + + * configure.in: Warn, but otherwise ignore, obsolete arguments. + +1999-08-20 Olivier Galibert + + * configure.in: Add --pdump option. + * configure.usage: Ditto. + +1999-08-04 Andy Piper + + * configure.in: report widget usage correctly. beef up setting. + + * Makefile.in.in: fix install-arch-dep for mingw32. + +1999-07-28 Andy Piper + + * config.h.in: add new LWLIB defines. + + * configure.in: fix definitions of widget defines with various + toolkit options. + 1999-07-30 XEmacs Build Bot * XEmacs 21.2.19 is released @@ -1876,7 +1964,7 @@ Sun November 01 12:00:00 1997 1997-10-18 SL Baur - * XEmacs 20.3-beta91 is released. + * XEmacs 20.3-beta91 is released. 1997-10-16 Hrvoje Niksic @@ -3198,7 +3286,7 @@ Sat Mar 22 16:47:08 1997 Steven L Baur Sat Mar 22 21:27:41 1997 Tomasz J. Cholewo - * configure.in: Echo only current configuration using 'tee -a'. + * configure.in: Echo only current configuration using 'tee -a'. Fri Mar 21 21:26:01 1997 Steven L Baur diff --git a/INSTALL b/INSTALL index 82dda47..e795ec5 100644 --- a/INSTALL +++ b/INSTALL @@ -1,6 +1,6 @@ XEmacs Installation Guide Copyright (c) 1994, 1995, 1996 Board of Trustees, University of Illinois -Copyright (c) 1994 Free Software Foundation, Inc. +Copyright (c) 1994-1999 Free Software Foundation, Inc. Synched up with: FSF 19.30. @@ -23,20 +23,22 @@ for instructions on building under Microsoft Windows): 1) Make sure your system has enough swapping space allocated to handle a program whose pure code is 900k bytes and whose data area is at - least 400k and can reach 8Mb or more. If the swapping space is + least 400k and can reach 8Mb or more. Note that a typical XEmacs + build is much bigger. If the swapping space is insufficient, you will get an error in the command `temacs -batch -l loadup dump', found in `./src/Makefile.in.in', or possibly when running the final dumped XEmacs. -Building XEmacs requires about 41 Mb of disk space (including the -XEmacs sources). Once installed, XEmacs occupies about 16 Mb in the -file system where it is installed; this includes the executable files, -Lisp libraries, miscellaneous data files, and on-line documentation. -The amount of storage of the Lisp directories may be reduced by -compressing the .el files. If the building and installation take place -in different directories, then the installation procedure temporarily -requires 41+16 Mb. Adjust this value upwards depending upon what -additional Lisp support is installed. + Verify that your users have a high enough stack limit. On some + systems such as OpenBSD and OSF/Tru64 the default is 2MB which is + too low. See 'PROBLEMS' for details. + +Building XEmacs requires about 100 Mb of disk space (including the +XEmacs sources). Once installed, XEmacs occupies between 20 and 100 Mb +in the file system where it is installed; this includes the executable files, +Lisp libraries, miscellaneous data files, and on-line documentation. The +exact amount depends greatly on the number of extra lisp packages that are +installed XEmacs requires an ANSI C compiler, such as GCC. If you wish to build the documentation yourself, you will need at least version 1.68 of @@ -65,20 +67,34 @@ Use the --site-includes and --site-libraries options when building XEmacs to allow configure to find the external software packages. If you link with dynamic (``.so'') external package libraries, which is not recommended, you will also need to add the library directories -to the --site-runtime-libraries option. +to the --site-runtime-libraries option. For your convenience these can +be set together by using the --with-site-prefix command. This will set +these variables as needed assuming your libraries are organised as a +typical /usr tree. +3) [N.B. Most of this section can be done during or after the +compilation of the core source code, but is present early to catch +your attention.] -3) Decide what Initial Lisp you need with XEmacs. XEmacs is -distributed separately from most of its runtime environment. This is +Decide what Initial Lisp you need with XEmacs. XEmacs is +distributed separately from most of its runtime environment. This is done to make it easier for administrators to tune an installation for -what the local users need. See the file etc/PACKAGES for an overview -of what is available and which packages need to be installed prior to -building XEmacs. At this point you only need a minimum to get started -at which point you may install what you wish without further changes -to the XEmacs binary. A sample minimum configuration for a Linux -system using Mule and Wnn6 from OMRON corporation would be the -packages `mule-base' and `egg-its'. By default, packages will be -searched for in the path +what the local users need. Note that while XEmacs will compile and +install without any packages present at least some additional lisp +packages are needed to bring XEmacs up to "normal" editor +functionality. Installation and upgrading of the packages can be done +almost automatically when from inside XEmacs when it has been compiled +and installed. + +More information and suggestions for which packages to install see the +file README.packages. + +IMPORTANT! The file README.packages contain information vital to have +a fully working XEmacs. This information was not included in this file +only because it is too large for this terse INSTALL. Please read +README.packages now! + +By default, packages will be searched for in the path ~/.xemacs::$prefix/lib/xemacs-${version}/mule-packages:$prefix/lib/xemacs/mule-packages:$prefix/lib/xemacs-${version}/xemacs-packages:$prefix/lib/xemacs/xemacs-packages @@ -380,7 +396,7 @@ creates a shell script `config.status' which, when run, recreates the same configuration. If `configure' exits with an error after disturbing the status quo, it removes `config.status'. -4) Look at `./lisp/paths.el'; if some of those values are not right +5) Look at `./lisp/paths.el'; if some of those values are not right for your system, set up the file `./lisp/site-init.el' with XEmacs Lisp code to override them; it is not a good idea to edit paths.el itself. YOU MUST USE THE LISP FUNCTION `setq' TO ASSIGN VALUES, @@ -403,7 +419,7 @@ configured. If you have an unusual automounter configuration that XEmacs cannot detect, you may need to change the value of `directory-abbrev-alist'. -5) Put into `./lisp/site-init.el' or `./lisp/site-load.el' any Emacs +6) Put into `./lisp/site-init.el' or `./lisp/site-load.el' any Emacs Lisp code you want XEmacs to load before it is dumped out. Use site-load.el for additional libraries if you arrange for their documentation strings to be in the lib-src/DOC file (see @@ -422,12 +438,12 @@ See `./PROBLEMS' for more details on which systems this affects. The `site-*.el' files are nonexistent in the distribution. You do not need to create them if you have nothing to put in them. -6) Refer to the file `./etc/TERMS' for information on fields you may +7) Refer to the file `./etc/TERMS' for information on fields you may wish to add to various termcap entries. The files `./etc/termcap.ucb' and `./etc/termcap.dat' may already contain appropriately-modified entries. -7) Run `make' in the top directory of the XEmacs distribution to finish +8) Run `make' in the top directory of the XEmacs distribution to finish building XEmacs in the standard way. The final executable file is named `src/emacs'. You can execute this file "in place" without copying it, if you wish; then it automatically uses the sibling @@ -505,18 +521,18 @@ information on this. Using GNU Make allows for simultaneous builds with and without the --srcdir option. -8) If your system uses lock files to interlock access to mailer inbox files, -then you might need to make the movemail program setuid or setgid -to enable it to write the lock files. We believe this is safe. +9) If your system uses lock files to interlock access to mailer inbox +files, then you might need to make the movemail program setuid or +setgid to enable it to write the lock files. We believe this is safe. The setuid/setgid bits need not be set on any other XEmacs-related executables. -9) You are done with the hard part! You can remove executables and +10) You are done with the hard part! You can remove executables and object files from the build directory by typing `make clean'. To also remove the files that `configure' created (so you can compile XEmacs for a different configuration), type `make distclean'. -10) You should now go to the XEmacs web page at http://www.xemacs.org/ +11) You should now go to the XEmacs web page at http://www.xemacs.org/ and decide what additional Lisp support you wish to have. MAKE VARIABLES @@ -670,13 +686,13 @@ see which operating system and architecture description files from `src/config.h', and change the two `#include' directives to include the appropriate system and architecture description files. -2) Edit `./src/config.h' to set the right options for your system. If +3) Edit `./src/config.h' to set the right options for your system. If you need to override any of the definitions in the s/*.h and m/*.h files for your system and machine, do so by editing config.h, not by changing the s/*.h and m/*.h files. Occasionally you may need to redefine parameters used in `./lib-src/movemail.c'. -3) If you're going to use the make utility to build XEmacs, you will +4) If you're going to use the make utility to build XEmacs, you will still need to run `configure' first, giving the appropriate values for the variables in the sections entitled "Things `configure' Might Edit" and "Where To Install Things." Note that you may only need to change @@ -776,6 +792,10 @@ debugging. PROBLEMS +The most likely problem is that you forgot to read and follow the +directions in README.packages. You can not have a working XEmacs +without downloading some additional packages. + See the file PROBLEMS in this directory for a list of various problems sometimes encountered, and what to do about them. diff --git a/Makefile.in.in b/Makefile.in.in index e8205ae..95f1a21 100644 --- a/Makefile.in.in +++ b/Makefile.in.in @@ -49,6 +49,9 @@ ## make extraclean ## Still more severe - delete backup and autosave files, too. +#define NOT_C_CODE +#include "src/config.h" + #ifdef USE_GNU_MAKE RECURSIVE_MAKE=$(MAKE) #else @@ -199,7 +202,7 @@ etcdir=@etcdir@ ## currently being edited. lockdir=@lockdir@ -# Where to put the DOC file. +## Where to put the DOC file. docdir=@docdir@ ## Where to put executables to be run by XEmacs rather than @@ -224,7 +227,10 @@ INSTALL_DATA = @INSTALL_DATA@ MAKE_SUBDIR = @MAKE_SUBDIR@ ## Subdirectories that can be made recursively. -SUBDIR = ${MAKE_SUBDIR} man +SUBDIR = ${MAKE_SUBDIR} man + +## Subdirectories that must be cleaned on distclean +SUBDIR_DISTCLEAN = ${SUBDIR} modules/sample modules/ldap modules/zlib modules/base64 ## The makefiles of the directories in ${MAKE_SUBDIR}. SUBDIR_MAKEFILES = @SUBDIR_MAKEFILES@ @@ -409,9 +415,18 @@ install-arch-dep: mkdir for subdir in `find ${archlibdir} -type d ! -name RCS ! -name SCCS ! -name CVS -print` ; \ do (cd $${subdir} && $(RM) -r RCS CVS SCCS \#* *~) ; done ; \ else true; fi +#ifdef WINDOWSNT + ${INSTALL_PROGRAM} src/${PROGNAME} ${bindir}/${PROGNAME} + -chmod 0755 ${bindir}/${PROGNAME} +#else ${INSTALL_PROGRAM} src/${PROGNAME} ${bindir}/${PROGNAME}-${version} -chmod 0755 ${bindir}/${PROGNAME}-${version} +# ifdef __CYGWIN32__ + cd ${bindir} && $(RM) ./${PROGNAME} && ${LN_S} ${PROGNAME}-${version}.exe ./${PROGNAME} +# else cd ${bindir} && $(RM) ./${PROGNAME} && ${LN_S} ${PROGNAME}-${version} ./${PROGNAME} +# endif /* __CYGWIN32__ */ +#endif /* WINDOWSNT */ if test "${prefix}" != "${exec_prefix}"; then \ for dir in \ lib/${inststaticdir} \ @@ -552,10 +567,10 @@ top_distclean=\ $(RM) config.status config.log confdefs.h config-tmp-* build-install Installation ; \ $(RM) core .sbinit lock/* GNUmakefile Makefile Makefile.in ; \ $(RM) lisp/finder-inf.el* Installation.el Installation.elc ; \ - $(RM) packages mule-packages site-lisp + $(RM) -r site-packages xemacs-packages mule-packages site-lisp distclean: FRC.distclean - for d in $(SUBDIR); do (cd ./$$d && $(RECURSIVE_MAKE) $@); done + for d in $(SUBDIR_DISTCLEAN); do (cd ./$$d && $(RECURSIVE_MAKE) $@); done -${top_distclean} ## `realclean' diff --git a/PROBLEMS b/PROBLEMS index 3f57bc4..42225f4 100644 --- a/PROBLEMS +++ b/PROBLEMS @@ -391,8 +391,8 @@ Marcus Thiessel Marcus Thiessel - Unfortunately, XEmacs releases <21.0 don't work with Motif2.1. It - will compile but you will get excessive X11 errors like + Unfortunately, XEmacs releases prior to 21.0 don't work with + Motif2.1. It will compile but you will get excessive X11 errors like xemacs: X Error of failed request: BadGC (invalid GC parameter) @@ -542,17 +542,23 @@ shell. *** You type Control-H (Backspace) expecting to delete characters. Emacs has traditionally used Control-H for help; unfortunately this -interferes with its use as Backspace on TTY's. One way to solve this -problem is to put this in your .emacs: +interferes with its use as Backspace on TTY's. As of XEmacs 21, +XEmacs looks at the "erase" setting of TTY structures and maps C-h to +backspace when erase is set to C-h. This is sort of a special hack, +but it makes it possible for you to use the standard: - (when (eq tty-erase-char ?\C-h) - (keyboard-translate ?\C-h ?\C-?) - (global-set-key "\M-?" 'help-command)) + stty erase ^H -This checks whether the TTY erase char is C-h, and if it is, makes -Control-H (Backspace) work sensibly, and moves help to Meta-? (ESC ?). +to get your backspace key to erase characters. The erase setting is +recorded in the Lisp variable `tty-erase-char', which you can use to +tune the settings in your .emacs. -Note that you can probably also access help using F1. +A major drawback of this is that when C-h becomes backspace, it no +longer invokes help. In that case, you need to use f1 for help, or +bind another key. An example of the latter is the following code, +which moves help to Meta-? (ESC ?): + + (global-set-key "\M-?" 'help-command) *** Mail agents (VM, Gnus, rmail) cannot get new mail diff --git a/README b/README index 3715e1c..b85267e 100644 --- a/README +++ b/README @@ -16,6 +16,9 @@ occur in building, installing and running XEmacs. See the file `nt/README' for instructions on building XEmacs for Microsoft Windows. +The file 'README.packages' will guide you in the installation of +(essential) add on packages. + Reports of bugs in XEmacs should be posted to the newsgroup comp.emacs.xemacs or sent to the mailing list xemacs@xemacs.org. See the "Bugs" section of the XEmacs manual for more information on how to diff --git a/README.packages b/README.packages index 4ac2cfa..dbbc6c5 100644 --- a/README.packages +++ b/README.packages @@ -224,3 +224,13 @@ The site-packages hierarchy replaces the old 'site-lisp' directory. XEmacs no longer looks into a 'site-lisp' directly by default. A good place to put 'site-start.el' would be in $prefix/lib/xemacs/site-packages/lisp/ + +Finding the right packages +-------------------------- + +If you want to find out which package contains the functionality you +are looking for, use M-x package-get-package-provider, and give it a +symbol that is likely to be in that package. eg, if some code you +want to use has a (require 'thingatpt) in it, try doing +M-x package-get-package-provider RET thingatpt , which will return +something like: (fsf-compat "1.06"). diff --git a/configure b/configure index be3c8d0..e19107a 100755 --- a/configure +++ b/configure @@ -263,6 +263,7 @@ with_toolbars="" with_tty="" use_union_type="no" with_dnet="" +pdump="no" @@ -359,6 +360,7 @@ while test $# != 0; do const_is_losing | \ usage_tracking | \ use_union_type | \ + pdump | \ debug | \ use_assertions | \ memory_usage_stats | \ @@ -699,7 +701,9 @@ echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; eval "$opt=\"$val\"" ;; - "run_in_place" | \ + "use_minimal_tagbits" | \ + "use_indexed_lrecord_implementation" | \ + "run_in_place" | \ "with_gnu_make" ) echo "configure: warning: Obsolete option \`--$optname' ignored." 1>&2 ;; @@ -792,7 +796,7 @@ echo " Use \`$progname --help' to show usage.") >&2 && exit 1 fi echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 -echo "configure:796: checking whether ln -s works" >&5 +echo "configure:800: checking whether ln -s works" >&5 rm -f conftestdata if ln -s X conftestdata 2>/dev/null @@ -1037,7 +1041,7 @@ EOF echo $ac_n "checking "host system type"""... $ac_c" 1>&6 -echo "configure:1041: checking "host system type"" >&5 +echo "configure:1045: checking "host system type"" >&5 internal_configuration=`echo $configuration | sed 's/-\(workshop\)//'` canonical=`${CONFIG_SHELL-/bin/sh} $srcdir/config.sub "$internal_configuration"` configuration=`echo "$configuration" | sed 's/^\([^-][^-]*-[^-][^-]*-[^-][^-]*\)-.*$/\1/'` @@ -1056,6 +1060,7 @@ case "$canonical" in vax-*-* ) machine=vax ;; mips-dec-* ) machine=pmax ;; mips-sgi-* ) machine=iris4d ;; + mips*-linux ) machine=mips ;; romp-ibm-* ) machine=ibmrt ;; rs6000-ibm-aix* ) machine=ibmrs6000 ;; powerpc-ibm-aix* ) machine=ibmrs6000 ;; @@ -1530,7 +1535,7 @@ xe_save_CFLAGS="$CFLAGS" # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1534: checking for $ac_word" >&5 +echo "configure:1539: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -1557,7 +1562,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1561: checking for $ac_word" >&5 +echo "configure:1566: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -1605,7 +1610,7 @@ fi # Extract the first word of "cl", so it can be a program name with args. set dummy cl; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1609: checking for $ac_word" >&5 +echo "configure:1614: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -1634,7 +1639,7 @@ fi fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:1638: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:1643: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' @@ -1647,12 +1652,12 @@ cross_compiling=no cat > conftest.$ac_ext << EOF -#line 1651 "configure" +#line 1656 "configure" #include "confdefs.h" main(){return(0);} EOF -if { (eval echo configure:1656: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ac_cv_prog_cc_works=yes # If we can't run a trivial program, we are probably using a cross compiler. if (./conftest; exit) 2>/dev/null; then @@ -1680,19 +1685,19 @@ if test $ac_cv_prog_cc_works = no; then { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 -echo "configure:1684: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:1689: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 cross_compiling=$ac_cv_prog_cc_cross echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:1689: checking whether we are using GNU C" >&5 +echo "configure:1694: checking whether we are using GNU C" >&5 cat > conftest.c <&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1701: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then ac_cv_prog_gcc=yes else ac_cv_prog_gcc=no @@ -1710,7 +1715,7 @@ ac_test_CFLAGS="${CFLAGS+set}" ac_save_CFLAGS="$CFLAGS" CFLAGS= echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 -echo "configure:1714: checking whether ${CC-cc} accepts -g" >&5 +echo "configure:1719: checking whether ${CC-cc} accepts -g" >&5 echo 'void f(){}' > conftest.c if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then @@ -1743,7 +1748,7 @@ if test "$with_gcc" = "no" -a "$GCC" = "yes"; then # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1747: checking for $ac_word" >&5 +echo "configure:1752: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -1770,7 +1775,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1774: checking for $ac_word" >&5 +echo "configure:1779: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -1818,7 +1823,7 @@ fi # Extract the first word of "cl", so it can be a program name with args. set dummy cl; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1822: checking for $ac_word" >&5 +echo "configure:1827: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -1847,7 +1852,7 @@ fi fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:1851: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:1856: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' @@ -1860,12 +1865,12 @@ cross_compiling=no cat > conftest.$ac_ext << EOF -#line 1864 "configure" +#line 1869 "configure" #include "confdefs.h" main(){return(0);} EOF -if { (eval echo configure:1869: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ac_cv_prog_cc_works=yes # If we can't run a trivial program, we are probably using a cross compiler. if (./conftest; exit) 2>/dev/null; then @@ -1893,19 +1898,19 @@ if test $ac_cv_prog_cc_works = no; then { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 -echo "configure:1897: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:1902: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 cross_compiling=$ac_cv_prog_cc_cross echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:1902: checking whether we are using GNU C" >&5 +echo "configure:1907: checking whether we are using GNU C" >&5 cat > conftest.c <&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1914: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then ac_cv_prog_gcc=yes else ac_cv_prog_gcc=no @@ -1923,7 +1928,7 @@ ac_test_CFLAGS="${CFLAGS+set}" ac_save_CFLAGS="$CFLAGS" CFLAGS= echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 -echo "configure:1927: checking whether ${CC-cc} accepts -g" >&5 +echo "configure:1932: checking whether ${CC-cc} accepts -g" >&5 echo 'void f(){}' > conftest.c if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then @@ -1956,7 +1961,7 @@ elif test "$with_gcc" = "yes" -a "$GCC" != "yes" ; then # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1960: checking for $ac_word" >&5 +echo "configure:1965: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -1983,7 +1988,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1987: checking for $ac_word" >&5 +echo "configure:1992: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -2031,7 +2036,7 @@ fi # Extract the first word of "cl", so it can be a program name with args. set dummy cl; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2035: checking for $ac_word" >&5 +echo "configure:2040: checking for $ac_word" >&5 if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -2060,7 +2065,7 @@ fi fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 -echo "configure:2064: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:2069: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' @@ -2073,12 +2078,12 @@ cross_compiling=no cat > conftest.$ac_ext << EOF -#line 2077 "configure" +#line 2082 "configure" #include "confdefs.h" main(){return(0);} EOF -if { (eval echo configure:2082: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2087: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ac_cv_prog_cc_works=yes # If we can't run a trivial program, we are probably using a cross compiler. if (./conftest; exit) 2>/dev/null; then @@ -2106,19 +2111,19 @@ if test $ac_cv_prog_cc_works = no; then { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } fi echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 -echo "configure:2110: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:2115: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 cross_compiling=$ac_cv_prog_cc_cross echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:2115: checking whether we are using GNU C" >&5 +echo "configure:2120: checking whether we are using GNU C" >&5 cat > conftest.c <&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2127: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then ac_cv_prog_gcc=yes else ac_cv_prog_gcc=no @@ -2136,7 +2141,7 @@ ac_test_CFLAGS="${CFLAGS+set}" ac_save_CFLAGS="$CFLAGS" CFLAGS= echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 -echo "configure:2140: checking whether ${CC-cc} accepts -g" >&5 +echo "configure:2145: checking whether ${CC-cc} accepts -g" >&5 echo 'void f(){}' > conftest.c if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then @@ -2173,7 +2178,7 @@ test -n "$CPP" -a -d "$CPP" && CPP= test -n "$NON_GNU_CPP" -a "$GCC" != "yes" -a -z "$CPP" && CPP="$NON_GNU_CPP" echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:2177: checking how to run the C preprocessor" >&5 +echo "configure:2182: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -2186,13 +2191,13 @@ if test -z "$CPP"; then # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2196: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2201: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -2203,13 +2208,13 @@ else rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2213: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2218: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -2220,13 +2225,13 @@ else rm -rf conftest* CPP="${CC-cc} -nologo -E" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2230: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2235: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -2251,9 +2256,9 @@ echo "$ac_t""$CPP" 1>&6 echo $ac_n "checking for AIX""... $ac_c" 1>&6 -echo "configure:2255: checking for AIX" >&5 +echo "configure:2260: checking for AIX" >&5 cat > conftest.$ac_ext <&6 -echo "configure:2284: checking for GNU libc" >&5 +echo "configure:2289: checking for GNU libc" >&5 cat > conftest.$ac_ext < int main() { @@ -2294,7 +2299,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:2298: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2303: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* have_glibc=yes else @@ -2316,7 +2321,7 @@ EOF cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:2337: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then : else @@ -2602,7 +2607,7 @@ test -n "$unexec" && extra_objs="$extra_objs $unexec" && if test "$ext fi echo $ac_n "checking for dynodump""... $ac_c" 1>&6 -echo "configure:2606: checking for dynodump" >&5 +echo "configure:2611: checking for dynodump" >&5 if test "$unexec" != "unexsol2.o"; then echo "$ac_t""no" 1>&6 else @@ -2640,12 +2645,12 @@ if test "$unexec" = "unexaix.o"; then done echo $ac_n "checking for terminateAndUnload in -lC""... $ac_c" 1>&6 -echo "configure:2644: checking for terminateAndUnload in -lC" >&5 +echo "configure:2649: checking for terminateAndUnload in -lC" >&5 ac_lib_var=`echo C'_'terminateAndUnload | sed 'y%./+-%__p_%'` xe_check_libs=" -lC " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2665: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -2760,7 +2765,7 @@ fi if test "$add_runtime_path" = "yes"; then echo $ac_n "checking "for runtime libraries flag"""... $ac_c" 1>&6 -echo "configure:2764: checking "for runtime libraries flag"" >&5 +echo "configure:2769: checking "for runtime libraries flag"" >&5 case "$opsys" in sol2 ) dash_r="-R" ;; decosf* | linux* | irix*) dash_r="-rpath " ;; @@ -2782,14 +2787,14 @@ if test "$GCC" = "yes"; then done fi cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2798: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* dash_r="$try_dash_r" else @@ -2891,10 +2896,10 @@ else fi after_morecore_hook_exists=yes echo $ac_n "checking for malloc_get_state""... $ac_c" 1>&6 -echo "configure:2895: checking for malloc_get_state" >&5 +echo "configure:2900: checking for malloc_get_state" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2926: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_malloc_get_state=yes" else @@ -2937,10 +2942,10 @@ doug_lea_malloc=no fi echo $ac_n "checking for malloc_set_state""... $ac_c" 1>&6 -echo "configure:2941: checking for malloc_set_state" >&5 +echo "configure:2946: checking for malloc_set_state" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2972: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_malloc_set_state=yes" else @@ -2983,16 +2988,16 @@ doug_lea_malloc=no fi echo $ac_n "checking whether __after_morecore_hook exists""... $ac_c" 1>&6 -echo "configure:2987: checking whether __after_morecore_hook exists" >&5 +echo "configure:2992: checking whether __after_morecore_hook exists" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3001: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* echo "$ac_t""yes" 1>&6 else @@ -3051,7 +3056,7 @@ fi # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:3055: checking for $ac_word" >&5 +echo "configure:3060: checking for $ac_word" >&5 if test -n "$RANLIB"; then ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. @@ -3106,7 +3111,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # ./install, which can be erroneously created by make from ./install.sh. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 -echo "configure:3110: checking for a BSD compatible install" >&5 +echo "configure:3115: checking for a BSD compatible install" >&5 if test -z "$INSTALL"; then IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" @@ -3160,7 +3165,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:3164: checking for $ac_word" >&5 +echo "configure:3169: checking for $ac_word" >&5 if test -n "$YACC"; then ac_cv_prog_YACC="$YACC" # Let the user override the test. @@ -3192,15 +3197,15 @@ for ac_hdr in mach/mach.h sys/stropts.h sys/timeb.h sys/time.h unistd.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3196: checking for $ac_hdr" >&5 +echo "configure:3201: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3204: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3209: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -3233,15 +3238,15 @@ for ac_hdr in utime.h locale.h libgen.h fcntl.h ulimit.h cygwin/version.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3237: checking for $ac_hdr" >&5 +echo "configure:3242: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3245: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3250: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -3274,15 +3279,15 @@ for ac_hdr in kstat.h sys/pstat.h inttypes.h sys/un.h a.out.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3278: checking for $ac_hdr" >&5 +echo "configure:3283: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3286: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3291: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -3312,10 +3317,10 @@ fi done echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 -echo "configure:3316: checking for sys/wait.h that is POSIX.1 compatible" >&5 +echo "configure:3321: checking for sys/wait.h that is POSIX.1 compatible" >&5 cat > conftest.$ac_ext < #include @@ -3331,7 +3336,7 @@ wait (&s); s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; ; return 0; } EOF -if { (eval echo configure:3335: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3340: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_sys_wait_h=yes else @@ -3355,10 +3360,10 @@ EOF fi echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 -echo "configure:3359: checking for ANSI C header files" >&5 +echo "configure:3364: checking for ANSI C header files" >&5 cat > conftest.$ac_ext < #include @@ -3366,7 +3371,7 @@ cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3370: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3375: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -3383,7 +3388,7 @@ rm -f conftest* if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat > conftest.$ac_ext < EOF @@ -3401,7 +3406,7 @@ 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 < EOF @@ -3419,7 +3424,7 @@ fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. cat > conftest.$ac_ext < #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') @@ -3430,7 +3435,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); exit (0); } EOF -if { (eval echo configure:3434: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:3439: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then : else @@ -3456,10 +3461,10 @@ EOF fi echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 -echo "configure:3460: checking whether time.h and sys/time.h may both be included" >&5 +echo "configure:3465: checking whether time.h and sys/time.h may both be included" >&5 cat > conftest.$ac_ext < #include @@ -3468,7 +3473,7 @@ int main() { struct tm *tp; ; return 0; } EOF -if { (eval echo configure:3472: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3477: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_time=yes else @@ -3492,10 +3497,10 @@ EOF fi echo $ac_n "checking for sys_siglist declaration in signal.h or unistd.h""... $ac_c" 1>&6 -echo "configure:3496: checking for sys_siglist declaration in signal.h or unistd.h" >&5 +echo "configure:3501: checking for sys_siglist declaration in signal.h or unistd.h" >&5 cat > conftest.$ac_ext < #include @@ -3507,7 +3512,7 @@ int main() { char *msg = *(sys_siglist + 1); ; return 0; } EOF -if { (eval echo configure:3511: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3516: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_decl_sys_siglist=yes else @@ -3532,9 +3537,9 @@ fi echo $ac_n "checking for struct utimbuf""... $ac_c" 1>&6 -echo "configure:3536: checking for struct utimbuf" >&5 +echo "configure:3541: checking for struct utimbuf" >&5 cat > conftest.$ac_ext < @@ -3553,7 +3558,7 @@ int main() { static struct utimbuf x; x.actime = x.modtime; ; return 0; } EOF -if { (eval echo configure:3557: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3562: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 { test "$extra_verbose" = "yes" && cat << \EOF @@ -3573,10 +3578,10 @@ fi rm -f conftest* echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 -echo "configure:3577: checking return type of signal handlers" >&5 +echo "configure:3582: checking return type of signal handlers" >&5 cat > conftest.$ac_ext < #include @@ -3593,7 +3598,7 @@ int main() { int i; ; return 0; } EOF -if { (eval echo configure:3597: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3602: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_type_signal=void else @@ -3615,10 +3620,10 @@ EOF echo $ac_n "checking for size_t""... $ac_c" 1>&6 -echo "configure:3619: checking for size_t" >&5 +echo "configure:3624: checking for size_t" >&5 cat > conftest.$ac_ext < #if STDC_HEADERS @@ -3649,10 +3654,10 @@ EOF fi echo $ac_n "checking for pid_t""... $ac_c" 1>&6 -echo "configure:3653: checking for pid_t" >&5 +echo "configure:3658: checking for pid_t" >&5 cat > conftest.$ac_ext < #if STDC_HEADERS @@ -3683,10 +3688,10 @@ EOF fi echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 -echo "configure:3687: checking for uid_t in sys/types.h" >&5 +echo "configure:3692: checking for uid_t in sys/types.h" >&5 cat > conftest.$ac_ext < EOF @@ -3722,10 +3727,10 @@ EOF fi echo $ac_n "checking for mode_t""... $ac_c" 1>&6 -echo "configure:3726: checking for mode_t" >&5 +echo "configure:3731: checking for mode_t" >&5 cat > conftest.$ac_ext < #if STDC_HEADERS @@ -3756,10 +3761,10 @@ EOF fi echo $ac_n "checking for off_t""... $ac_c" 1>&6 -echo "configure:3760: checking for off_t" >&5 +echo "configure:3765: checking for off_t" >&5 cat > conftest.$ac_ext < #if STDC_HEADERS @@ -3791,9 +3796,9 @@ fi echo $ac_n "checking for struct timeval""... $ac_c" 1>&6 -echo "configure:3795: checking for struct timeval" >&5 +echo "configure:3800: checking for struct timeval" >&5 cat > conftest.$ac_ext < @@ -3809,7 +3814,7 @@ int main() { static struct timeval x; x.tv_sec = x.tv_usec; ; return 0; } EOF -if { (eval echo configure:3813: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3818: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 HAVE_TIMEVAL=yes @@ -3831,10 +3836,10 @@ fi rm -f conftest* echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 -echo "configure:3835: checking whether struct tm is in sys/time.h or time.h" >&5 +echo "configure:3840: checking whether struct tm is in sys/time.h or time.h" >&5 cat > conftest.$ac_ext < #include @@ -3842,7 +3847,7 @@ int main() { struct tm *tp; tp->tm_sec; ; return 0; } EOF -if { (eval echo configure:3846: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3851: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm=time.h else @@ -3866,10 +3871,10 @@ EOF fi echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 -echo "configure:3870: checking for tm_zone in struct tm" >&5 +echo "configure:3875: checking for tm_zone in struct tm" >&5 cat > conftest.$ac_ext < #include <$ac_cv_struct_tm> @@ -3877,7 +3882,7 @@ int main() { struct tm tm; tm.tm_zone; ; return 0; } EOF -if { (eval echo configure:3881: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3886: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm_zone=yes else @@ -3900,10 +3905,10 @@ EOF else echo $ac_n "checking for tzname""... $ac_c" 1>&6 -echo "configure:3904: checking for tzname" >&5 +echo "configure:3909: checking for tzname" >&5 cat > conftest.$ac_ext < #ifndef tzname /* For SGI. */ @@ -3913,7 +3918,7 @@ int main() { atoi(*tzname); ; return 0; } EOF -if { (eval echo configure:3917: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3922: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_var_tzname=yes else @@ -3939,10 +3944,10 @@ fi echo $ac_n "checking for working const""... $ac_c" 1>&6 -echo "configure:3943: checking for working const" >&5 +echo "configure:3948: checking for working const" >&5 cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4000: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_const=yes else @@ -4016,7 +4021,7 @@ fi echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 -echo "configure:4020: checking whether ${MAKE-make} sets \${MAKE}" >&5 +echo "configure:4025: checking whether ${MAKE-make} sets \${MAKE}" >&5 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` cat > conftestmake <<\EOF @@ -4041,12 +4046,12 @@ fi echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 -echo "configure:4045: checking whether byte ordering is bigendian" >&5 +echo "configure:4050: checking whether byte ordering is bigendian" >&5 ac_cv_c_bigendian=unknown # See if sys/param.h defines the BYTE_ORDER macro. cat > conftest.$ac_ext < #include @@ -4057,11 +4062,11 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:4061: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4066: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* # It does; now see whether it defined to BIG_ENDIAN or not. cat > conftest.$ac_ext < #include @@ -4072,7 +4077,7 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:4076: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:4081: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_bigendian=yes else @@ -4089,7 +4094,7 @@ fi rm -f conftest* if test $ac_cv_c_bigendian = unknown; then cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:4111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_c_bigendian=no else @@ -4129,10 +4134,10 @@ fi echo $ac_n "checking size of short""... $ac_c" 1>&6 -echo "configure:4133: checking size of short" >&5 +echo "configure:4138: checking size of short" >&5 cat > conftest.$ac_ext < main() @@ -4143,7 +4148,7 @@ main() exit(0); } EOF -if { (eval echo configure:4147: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:4152: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_short=`cat conftestval` else @@ -4171,10 +4176,10 @@ if test "$ac_cv_sizeof_short" = 0; then exit 1 fi echo $ac_n "checking size of int""... $ac_c" 1>&6 -echo "configure:4175: checking size of int" >&5 +echo "configure:4180: checking size of int" >&5 cat > conftest.$ac_ext < main() @@ -4185,7 +4190,7 @@ main() exit(0); } EOF -if { (eval echo configure:4189: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:4194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_int=`cat conftestval` else @@ -4207,10 +4212,10 @@ EOF echo $ac_n "checking size of long""... $ac_c" 1>&6 -echo "configure:4211: checking size of long" >&5 +echo "configure:4216: checking size of long" >&5 cat > conftest.$ac_ext < main() @@ -4221,7 +4226,7 @@ main() exit(0); } EOF -if { (eval echo configure:4225: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:4230: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_long=`cat conftestval` else @@ -4243,10 +4248,10 @@ EOF echo $ac_n "checking size of long long""... $ac_c" 1>&6 -echo "configure:4247: checking size of long long" >&5 +echo "configure:4252: checking size of long long" >&5 cat > conftest.$ac_ext < main() @@ -4257,7 +4262,7 @@ main() exit(0); } EOF -if { (eval echo configure:4261: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:4266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_long_long=`cat conftestval` else @@ -4279,10 +4284,10 @@ EOF echo $ac_n "checking size of void *""... $ac_c" 1>&6 -echo "configure:4283: checking size of void *" >&5 +echo "configure:4288: checking size of void *" >&5 cat > conftest.$ac_ext < main() @@ -4293,7 +4298,7 @@ main() exit(0); } EOF -if { (eval echo configure:4297: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:4302: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_void_p=`cat conftestval` else @@ -4316,7 +4321,7 @@ EOF echo $ac_n "checking for long file names""... $ac_c" 1>&6 -echo "configure:4320: checking for long file names" >&5 +echo "configure:4325: checking for long file names" >&5 ac_cv_sys_long_file_names=yes # Test for long file names in all the places we know might matter: @@ -4362,10 +4367,10 @@ fi echo $ac_n "checking for sin""... $ac_c" 1>&6 -echo "configure:4366: checking for sin" >&5 +echo "configure:4371: checking for sin" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4397: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_sin=yes" else @@ -4406,12 +4411,12 @@ else echo "$ac_t""no" 1>&6 echo $ac_n "checking for sin in -lm""... $ac_c" 1>&6 -echo "configure:4410: checking for sin in -lm" >&5 +echo "configure:4415: checking for sin in -lm" >&5 ac_lib_var=`echo m'_'sin | sed 'y%./+-%__p_%'` xe_check_libs=" -lm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4431: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4466,14 +4471,14 @@ EOF cat > conftest.$ac_ext < int main() { return atanh(1.0) + asinh(1.0) + acosh(1.0); ; return 0; } EOF -if { (eval echo configure:4477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4482: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_INVERSE_HYPERBOLIC @@ -4490,7 +4495,7 @@ fi rm -f conftest* echo "checking type of mail spool file locking" 1>&6 -echo "configure:4494: checking type of mail spool file locking" >&5 +echo "configure:4499: checking type of mail spool file locking" >&5 test -z "$mail_locking" -a "$mail_use_flock" = "yes" && mail_locking=flock test -z "$mail_locking" -a "$mail_use_lockf" = "yes" && mail_locking=lockf if test "$mail_locking" = "lockf"; then { test "$extra_verbose" = "yes" && cat << \EOF @@ -4515,12 +4520,12 @@ fi case "$opsys" in decosf*) echo $ac_n "checking for cma_open in -lpthreads""... $ac_c" 1>&6 -echo "configure:4519: checking for cma_open in -lpthreads" >&5 +echo "configure:4524: checking for cma_open in -lpthreads" >&5 ac_lib_var=`echo pthreads'_'cma_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lpthreads " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4567,7 +4572,7 @@ fi esac echo $ac_n "checking whether the -xildoff compiler flag is required""... $ac_c" 1>&6 -echo "configure:4571: checking whether the -xildoff compiler flag is required" >&5 +echo "configure:4576: checking whether the -xildoff compiler flag is required" >&5 if ${CC-cc} '-###' -xildon no_such_file.c 2>&1 | grep '^[^ ]*/ild ' > /dev/null ; then if ${CC-cc} '-###' -xildoff no_such_file.c 2>&1 | grep '^[^ ]*/ild ' > /dev/null ; then echo "$ac_t""no" 1>&6; @@ -4578,7 +4583,7 @@ fi if test "$opsys" = "sol2" && test "$OS_RELEASE" -ge 56; then echo $ac_n "checking for \"-z ignore\" linker flag""... $ac_c" 1>&6 -echo "configure:4582: checking for \"-z ignore\" linker flag" >&5 +echo "configure:4587: checking for \"-z ignore\" linker flag" >&5 case "`ld -h 2>&1`" in *-z\ ignore\|record* ) echo "$ac_t""yes" 1>&6 ld_switch_site="-z ignore $ld_switch_site" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-z ignore\" to \$ld_switch_site"; fi ;; @@ -4588,7 +4593,7 @@ fi echo "checking "for specified window system"" 1>&6 -echo "configure:4592: checking "for specified window system"" >&5 +echo "configure:4597: checking "for specified window system"" >&5 if test "$with_x11" != "no"; then test "$x_includes $x_libraries" != "NONE NONE" && \ @@ -4621,7 +4626,7 @@ if test "$with_x11" != "no"; then # Uses ac_ vars as temps to allow command line to override cache and checks. # --without-x overrides everything else, but does not touch the cache. echo $ac_n "checking for X""... $ac_c" 1>&6 -echo "configure:4625: checking for X" >&5 +echo "configure:4630: checking for X" >&5 # Check whether --with-x or --without-x was given. if test "${with_x+set}" = set; then @@ -4681,12 +4686,12 @@ if test "$ac_x_includes" = NO; then # First, try using that file with no special directory specified. cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4690: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4695: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4755,14 +4760,14 @@ if test "$ac_x_libraries" = NO; then ac_save_LIBS="$LIBS" LIBS="-l$x_direct_test_library $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* LIBS="$ac_save_LIBS" # We can link X programs with no special library path. @@ -4871,17 +4876,17 @@ else case "`(uname -sr) 2>/dev/null`" in "SunOS 5"*) echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6 -echo "configure:4875: checking whether -R must be followed by a space" >&5 +echo "configure:4880: checking whether -R must be followed by a space" >&5 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4890: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_R_nospace=yes else @@ -4897,14 +4902,14 @@ rm -f conftest* else LIBS="$ac_xsave_LIBS -R $x_libraries" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4913: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_R_space=yes else @@ -4940,12 +4945,12 @@ ac_cv_lib_dnet_dnet_ntoa=no else echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6 -echo "configure:4944: checking for dnet_ntoa in -ldnet" >&5 +echo "configure:4949: checking for dnet_ntoa in -ldnet" >&5 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'` xe_check_libs=" -ldnet " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4965: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4980,12 +4985,12 @@ fi if test $ac_cv_lib_dnet_dnet_ntoa = no; then echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6 -echo "configure:4984: checking for dnet_ntoa in -ldnet_stub" >&5 +echo "configure:4989: checking for dnet_ntoa in -ldnet_stub" >&5 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'` xe_check_libs=" -ldnet_stub " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5025,10 +5030,10 @@ fi # The nsl library prevents programs from opening the X display # on Irix 5.2, according to dickey@clark.net. echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 -echo "configure:5029: checking for gethostbyname" >&5 +echo "configure:5034: checking for gethostbyname" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_gethostbyname=yes" else @@ -5072,12 +5077,12 @@ fi if test $ac_cv_func_gethostbyname = no; then echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 -echo "configure:5076: checking for gethostbyname in -lnsl" >&5 +echo "configure:5081: checking for gethostbyname in -lnsl" >&5 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` xe_check_libs=" -lnsl " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5097: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5118,10 +5123,10 @@ fi # -lsocket must be given before -lnsl if both are needed. # We assume that if connect needs -lnsl, so does gethostbyname. echo $ac_n "checking for connect""... $ac_c" 1>&6 -echo "configure:5122: checking for connect" >&5 +echo "configure:5127: checking for connect" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5153: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_connect=yes" else @@ -5167,12 +5172,12 @@ fi xe_msg_checking="for connect in -lsocket" test -n "$X_EXTRA_LIBS" && xe_msg_checking="$xe_msg_checking using extra libs $X_EXTRA_LIBS" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:5171: checking "$xe_msg_checking"" >&5 +echo "configure:5176: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'` xe_check_libs=" -lsocket $X_EXTRA_LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5207,10 +5212,10 @@ fi # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX. echo $ac_n "checking for remove""... $ac_c" 1>&6 -echo "configure:5211: checking for remove" >&5 +echo "configure:5216: checking for remove" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5242: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_remove=yes" else @@ -5254,12 +5259,12 @@ fi if test $ac_cv_func_remove = no; then echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6 -echo "configure:5258: checking for remove in -lposix" >&5 +echo "configure:5263: checking for remove in -lposix" >&5 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'` xe_check_libs=" -lposix " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5294,10 +5299,10 @@ fi # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. echo $ac_n "checking for shmat""... $ac_c" 1>&6 -echo "configure:5298: checking for shmat" >&5 +echo "configure:5303: checking for shmat" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_shmat=yes" else @@ -5341,12 +5346,12 @@ fi if test $ac_cv_func_shmat = no; then echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6 -echo "configure:5345: checking for shmat in -lipc" >&5 +echo "configure:5350: checking for shmat in -lipc" >&5 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'` xe_check_libs=" -lipc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5393,12 +5398,12 @@ fi xe_msg_checking="for IceConnectionNumber in -lICE" test -n "$X_EXTRA_LIBS" && xe_msg_checking="$xe_msg_checking using extra libs $X_EXTRA_LIBS" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:5397: checking "$xe_msg_checking"" >&5 +echo "configure:5402: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'` xe_check_libs=" -lICE $X_EXTRA_LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5418: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5578,7 +5583,7 @@ EOF echo "checking for X defines extracted by xmkmf" 1>&6 -echo "configure:5582: checking for X defines extracted by xmkmf" >&5 +echo "configure:5587: checking for X defines extracted by xmkmf" >&5 rm -fr conftestdir if mkdir conftestdir; then cd conftestdir @@ -5610,15 +5615,15 @@ EOF ac_safe=`echo "X11/Intrinsic.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for X11/Intrinsic.h""... $ac_c" 1>&6 -echo "configure:5614: checking for X11/Intrinsic.h" >&5 +echo "configure:5619: checking for X11/Intrinsic.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5622: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:5627: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -5642,12 +5647,12 @@ fi echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6 -echo "configure:5646: checking for XOpenDisplay in -lX11" >&5 +echo "configure:5651: checking for XOpenDisplay in -lX11" >&5 ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'` xe_check_libs=" -lX11 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5667: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5683,12 +5688,12 @@ fi xe_msg_checking="for XGetFontProperty in -lX11" test -n "-b i486-linuxaout" && xe_msg_checking="$xe_msg_checking using extra libs -b i486-linuxaout" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:5687: checking "$xe_msg_checking"" >&5 +echo "configure:5692: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo X11'_'XGetFontProperty | sed 'y%./+-%__p_%'` xe_check_libs=" -lX11 -b i486-linuxaout" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5708: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5726,12 +5731,12 @@ fi echo $ac_n "checking for XShapeSelectInput in -lXext""... $ac_c" 1>&6 -echo "configure:5730: checking for XShapeSelectInput in -lXext" >&5 +echo "configure:5735: checking for XShapeSelectInput in -lXext" >&5 ac_lib_var=`echo Xext'_'XShapeSelectInput | sed 'y%./+-%__p_%'` xe_check_libs=" -lXext " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5751: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5765,12 +5770,12 @@ fi echo $ac_n "checking for XtOpenDisplay in -lXt""... $ac_c" 1>&6 -echo "configure:5769: checking for XtOpenDisplay in -lXt" >&5 +echo "configure:5774: checking for XtOpenDisplay in -lXt" >&5 ac_lib_var=`echo Xt'_'XtOpenDisplay | sed 'y%./+-%__p_%'` xe_check_libs=" -lXt " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5804,14 +5809,14 @@ fi echo $ac_n "checking the version of X11 being used""... $ac_c" 1>&6 -echo "configure:5808: checking the version of X11 being used" >&5 +echo "configure:5813: checking the version of X11 being used" >&5 cat > conftest.$ac_ext < int main(int c, char *v[]) { return c>1 ? XlibSpecificationRelease : 0; } EOF -if { (eval echo configure:5815: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:5820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ./conftest foobar; x11_release=$? else @@ -5836,15 +5841,15 @@ EOF do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5840: checking for $ac_hdr" >&5 +echo "configure:5845: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5848: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:5853: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -5875,7 +5880,7 @@ done echo $ac_n "checking for XFree86""... $ac_c" 1>&6 -echo "configure:5879: checking for XFree86" >&5 +echo "configure:5884: checking for XFree86" >&5 if test -d "/usr/X386/include" -o \ -f "/etc/XF86Config" -o \ -f "/etc/X11/XF86Config" -o \ @@ -5895,12 +5900,12 @@ EOF test -z "$with_xmu" && { echo $ac_n "checking for XmuReadBitmapDataFromFile in -lXmu""... $ac_c" 1>&6 -echo "configure:5899: checking for XmuReadBitmapDataFromFile in -lXmu" >&5 +echo "configure:5904: checking for XmuReadBitmapDataFromFile in -lXmu" >&5 ac_lib_var=`echo Xmu'_'XmuReadBitmapDataFromFile | sed 'y%./+-%__p_%'` xe_check_libs=" -lXmu " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5920: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5950,19 +5955,19 @@ EOF echo $ac_n "checking for main in -lXbsd""... $ac_c" 1>&6 -echo "configure:5954: checking for main in -lXbsd" >&5 +echo "configure:5959: checking for main in -lXbsd" >&5 ac_lib_var=`echo Xbsd'_'main | sed 'y%./+-%__p_%'` xe_check_libs=" -lXbsd " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -5999,22 +6004,22 @@ fi fi if test "$with_msw" != "no"; then echo "checking for MS-Windows" 1>&6 -echo "configure:6003: checking for MS-Windows" >&5 +echo "configure:6008: checking for MS-Windows" >&5 echo $ac_n "checking for main in -lgdi32""... $ac_c" 1>&6 -echo "configure:6006: checking for main in -lgdi32" >&5 +echo "configure:6011: checking for main in -lgdi32" >&5 ac_lib_var=`echo gdi32'_'main | sed 'y%./+-%__p_%'` xe_check_libs=" -lgdi32 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6080,12 +6085,12 @@ EOF fi fi cat > conftest.$ac_ext < int main() { return (open("/dev/windows", O_RDONLY, 0) > 0)? 0 : 1; } EOF -if { (eval echo configure:6089: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:6094: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_MSG_SELECT @@ -6161,7 +6166,7 @@ case "$x_libraries" in *X11R4* ) esac echo "checking for WM_COMMAND option" 1>&6 -echo "configure:6165: checking for WM_COMMAND option" >&5; +echo "configure:6170: checking for WM_COMMAND option" >&5; if test "$with_wmcommand" != "no"; then { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_WMCOMMAND @@ -6176,15 +6181,15 @@ fi test -z "$with_xauth" && test "$window_system" = "none" && with_xauth=no test -z "$with_xauth" && { ac_safe=`echo "X11/Xauth.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for X11/Xauth.h""... $ac_c" 1>&6 -echo "configure:6180: checking for X11/Xauth.h" >&5 +echo "configure:6185: checking for X11/Xauth.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6188: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6193: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -6207,12 +6212,12 @@ fi } test -z "$with_xauth" && { echo $ac_n "checking for XauGetAuthByAddr in -lXau""... $ac_c" 1>&6 -echo "configure:6211: checking for XauGetAuthByAddr in -lXau" >&5 +echo "configure:6216: checking for XauGetAuthByAddr in -lXau" >&5 ac_lib_var=`echo Xau'_'XauGetAuthByAddr | sed 'y%./+-%__p_%'` xe_check_libs=" -lXau " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6232: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6268,15 +6273,15 @@ if test "$with_tooltalk" != "no" ; then for dir in "" "Tt/" "desktop/" ; do ac_safe=`echo "${dir}tt_c.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ${dir}tt_c.h""... $ac_c" 1>&6 -echo "configure:6272: checking for ${dir}tt_c.h" >&5 +echo "configure:6277: checking for ${dir}tt_c.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6280: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6285: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -6312,12 +6317,12 @@ if test "$with_tooltalk" != "no" ; then xe_msg_checking="for tt_message_create in -ltt" test -n "$extra_libs" && xe_msg_checking="$xe_msg_checking using extra libs $extra_libs" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:6316: checking "$xe_msg_checking"" >&5 +echo "configure:6321: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo tt'_'tt_message_create | sed 'y%./+-%__p_%'` xe_check_libs=" -ltt $extra_libs" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6337: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6385,15 +6390,15 @@ fi test -z "$with_cde" && { ac_safe=`echo "Dt/Dt.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for Dt/Dt.h""... $ac_c" 1>&6 -echo "configure:6389: checking for Dt/Dt.h" >&5 +echo "configure:6394: checking for Dt/Dt.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6397: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6402: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -6416,12 +6421,12 @@ fi } test -z "$with_cde" && { echo $ac_n "checking for DtDndDragStart in -lDtSvc""... $ac_c" 1>&6 -echo "configure:6420: checking for DtDndDragStart in -lDtSvc" >&5 +echo "configure:6425: checking for DtDndDragStart in -lDtSvc" >&5 ac_lib_var=`echo DtSvc'_'DtDndDragStart | sed 'y%./+-%__p_%'` xe_check_libs=" -lDtSvc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6441: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6501,7 +6506,7 @@ EOF fi echo $ac_n "checking if drag and drop API is needed""... $ac_c" 1>&6 -echo "configure:6505: checking if drag and drop API is needed" >&5 +echo "configure:6510: checking if drag and drop API is needed" >&5 if test "$with_dragndrop" != "no" ; then if test -n "$dragndrop_proto" ; then with_dragndrop=yes @@ -6522,18 +6527,18 @@ EOF fi echo "checking for LDAP" 1>&6 -echo "configure:6526: checking for LDAP" >&5 +echo "configure:6531: checking for LDAP" >&5 test -z "$with_ldap" && { ac_safe=`echo "ldap.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ldap.h""... $ac_c" 1>&6 -echo "configure:6529: checking for ldap.h" >&5 +echo "configure:6534: checking for ldap.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6537: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6542: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -6556,15 +6561,15 @@ fi } test -z "$with_ldap" && { ac_safe=`echo "lber.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for lber.h""... $ac_c" 1>&6 -echo "configure:6560: checking for lber.h" >&5 +echo "configure:6565: checking for lber.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6568: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6573: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -6588,12 +6593,12 @@ fi if test "$with_ldap" != "no"; then echo $ac_n "checking for ldap_search in -lldap""... $ac_c" 1>&6 -echo "configure:6592: checking for ldap_search in -lldap" >&5 +echo "configure:6597: checking for ldap_search in -lldap" >&5 ac_lib_var=`echo ldap'_'ldap_search | sed 'y%./+-%__p_%'` xe_check_libs=" -lldap " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6613: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6629,12 +6634,12 @@ fi xe_msg_checking="for ldap_open in -lldap" test -n "-llber" && xe_msg_checking="$xe_msg_checking using extra libs -llber" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:6633: checking "$xe_msg_checking"" >&5 +echo "configure:6638: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo ldap'_'ldap_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lldap -llber" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6654: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6670,12 +6675,12 @@ fi xe_msg_checking="for ldap_open in -lldap" test -n "-llber -lkrb" && xe_msg_checking="$xe_msg_checking using extra libs -llber -lkrb" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:6674: checking "$xe_msg_checking"" >&5 +echo "configure:6679: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo ldap'_'ldap_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lldap -llber -lkrb" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6695: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6711,12 +6716,12 @@ fi xe_msg_checking="for ldap_open in -lldap" test -n "-llber -lkrb -ldes" && xe_msg_checking="$xe_msg_checking using extra libs -llber -lkrb -ldes" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:6715: checking "$xe_msg_checking"" >&5 +echo "configure:6720: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo ldap'_'ldap_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lldap -llber -lkrb -ldes" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6736: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -6778,10 +6783,10 @@ EOF for ac_func in ldap_set_option ldap_get_lderrno ldap_result2error ldap_parse_result do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:6782: checking for $ac_func" >&5 +echo "configure:6787: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6813: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -6836,15 +6841,15 @@ fi if test "$window_system" != "none"; then echo "checking for graphics libraries" 1>&6 -echo "configure:6840: checking for graphics libraries" >&5 +echo "configure:6845: checking for graphics libraries" >&5 xpm_problem="" if test -z "$with_xpm"; then echo $ac_n "checking for Xpm - no older than 3.4f""... $ac_c" 1>&6 -echo "configure:6845: checking for Xpm - no older than 3.4f" >&5 +echo "configure:6850: checking for Xpm - no older than 3.4f" >&5 xe_check_libs=-lXpm cat > conftest.$ac_ext < int main(int c, char **v) { @@ -6852,7 +6857,7 @@ echo "configure:6845: checking for Xpm - no older than 3.4f" >&5 XpmIncludeVersion != XpmLibraryVersion() ? 1 : XpmIncludeVersion < 30406 ? 2 : 0 ;} EOF -if { (eval echo configure:6856: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:6861: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ./conftest dummy_arg; xpm_status=$?; if test "$xpm_status" = "0"; then @@ -6894,17 +6899,17 @@ EOF libs_x="-lXpm $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXpm\" to \$libs_x"; fi echo $ac_n "checking for \"FOR_MSW\" xpm""... $ac_c" 1>&6 -echo "configure:6898: checking for \"FOR_MSW\" xpm" >&5 +echo "configure:6903: checking for \"FOR_MSW\" xpm" >&5 xe_check_libs=-lXpm cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6913: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* xpm_for_msw=no else @@ -6930,15 +6935,15 @@ EOF test -z "$with_xface" && { ac_safe=`echo "compface.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for compface.h""... $ac_c" 1>&6 -echo "configure:6934: checking for compface.h" >&5 +echo "configure:6939: checking for compface.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6942: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:6947: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -6961,12 +6966,12 @@ fi } test -z "$with_xface" && { echo $ac_n "checking for UnGenFace in -lcompface""... $ac_c" 1>&6 -echo "configure:6965: checking for UnGenFace in -lcompface" >&5 +echo "configure:6970: checking for UnGenFace in -lcompface" >&5 ac_lib_var=`echo compface'_'UnGenFace | sed 'y%./+-%__p_%'` xe_check_libs=" -lcompface " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7029,12 +7034,12 @@ EOF if test "$with_png $with_tiff" != "no no"; then echo $ac_n "checking for inflate in -lc""... $ac_c" 1>&6 -echo "configure:7033: checking for inflate in -lc" >&5 +echo "configure:7038: checking for inflate in -lc" >&5 ac_lib_var=`echo c'_'inflate | sed 'y%./+-%__p_%'` xe_check_libs=" -lc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7054: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7064,12 +7069,12 @@ else echo "$ac_t""no" 1>&6 echo $ac_n "checking for inflate in -lz""... $ac_c" 1>&6 -echo "configure:7068: checking for inflate in -lz" >&5 +echo "configure:7073: checking for inflate in -lz" >&5 ac_lib_var=`echo z'_'inflate | sed 'y%./+-%__p_%'` xe_check_libs=" -lz " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7089: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7099,12 +7104,12 @@ else echo "$ac_t""no" 1>&6 echo $ac_n "checking for inflate in -lgz""... $ac_c" 1>&6 -echo "configure:7103: checking for inflate in -lgz" >&5 +echo "configure:7108: checking for inflate in -lgz" >&5 ac_lib_var=`echo gz'_'inflate | sed 'y%./+-%__p_%'` xe_check_libs=" -lgz " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7124: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7145,15 +7150,15 @@ fi test -z "$with_jpeg" && { ac_safe=`echo "jpeglib.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for jpeglib.h""... $ac_c" 1>&6 -echo "configure:7149: checking for jpeglib.h" >&5 +echo "configure:7154: checking for jpeglib.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7157: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7162: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7176,12 +7181,12 @@ fi } test -z "$with_jpeg" && { echo $ac_n "checking for jpeg_destroy_decompress in -ljpeg""... $ac_c" 1>&6 -echo "configure:7180: checking for jpeg_destroy_decompress in -ljpeg" >&5 +echo "configure:7185: checking for jpeg_destroy_decompress in -ljpeg" >&5 ac_lib_var=`echo jpeg'_'jpeg_destroy_decompress | sed 'y%./+-%__p_%'` xe_check_libs=" -ljpeg " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7201: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7228,10 +7233,10 @@ EOF png_problem="" test -z "$with_png" && { echo $ac_n "checking for pow""... $ac_c" 1>&6 -echo "configure:7232: checking for pow" >&5 +echo "configure:7237: checking for pow" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7263: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_pow=yes" else @@ -7275,15 +7280,15 @@ fi } test -z "$with_png" && { ac_safe=`echo "png.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for png.h""... $ac_c" 1>&6 -echo "configure:7279: checking for png.h" >&5 +echo "configure:7284: checking for png.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7287: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7292: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7306,12 +7311,12 @@ fi } test -z "$with_png" && { echo $ac_n "checking for png_read_image in -lpng""... $ac_c" 1>&6 -echo "configure:7310: checking for png_read_image in -lpng" >&5 +echo "configure:7315: checking for png_read_image in -lpng" >&5 ac_lib_var=`echo png'_'png_read_image | sed 'y%./+-%__p_%'` xe_check_libs=" -lpng " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7331: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7345,10 +7350,10 @@ fi } if test -z "$with_png"; then echo $ac_n "checking for workable png version information""... $ac_c" 1>&6 -echo "configure:7349: checking for workable png version information" >&5 +echo "configure:7354: checking for workable png version information" >&5 xe_check_libs="-lpng -lz" cat > conftest.$ac_ext < int main(int c, char **v) { @@ -7356,7 +7361,7 @@ echo "configure:7349: checking for workable png version information" >&5 if (strcmp(png_libpng_ver, PNG_LIBPNG_VER_STRING) != 0) return 1; return (PNG_LIBPNG_VER < 10002) ? 2 : 0 ;} EOF -if { (eval echo configure:7360: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:7365: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ./conftest dummy_arg; png_status=$?; if test "$png_status" = "0"; then @@ -7399,15 +7404,15 @@ EOF test -z "$with_tiff" && { ac_safe=`echo "tiffio.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for tiffio.h""... $ac_c" 1>&6 -echo "configure:7403: checking for tiffio.h" >&5 +echo "configure:7408: checking for tiffio.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7411: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7416: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7430,12 +7435,12 @@ fi } test -z "$with_tiff" && { echo $ac_n "checking for TIFFClientOpen in -ltiff""... $ac_c" 1>&6 -echo "configure:7434: checking for TIFFClientOpen in -ltiff" >&5 +echo "configure:7439: checking for TIFFClientOpen in -ltiff" >&5 ac_lib_var=`echo tiff'_'TIFFClientOpen | sed 'y%./+-%__p_%'` xe_check_libs=" -ltiff " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7455: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7485,16 +7490,16 @@ fi if test "$with_x11" = "yes"; then echo "checking for X11 graphics libraries" 1>&6 -echo "configure:7489: checking for X11 graphics libraries" >&5 +echo "configure:7494: checking for X11 graphics libraries" >&5 echo $ac_n "checking for XawScrollbarSetThumb in -lXaw""... $ac_c" 1>&6 -echo "configure:7493: checking for XawScrollbarSetThumb in -lXaw" >&5 +echo "configure:7498: checking for XawScrollbarSetThumb in -lXaw" >&5 ac_lib_var=`echo Xaw'_'XawScrollbarSetThumb | sed 'y%./+-%__p_%'` xe_check_libs=" -lXaw " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7514: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7527,17 +7532,57 @@ fi + +echo $ac_n "checking for XawScrollbarSetThumb in -lXaw3d""... $ac_c" 1>&6 +echo "configure:7538: checking for XawScrollbarSetThumb in -lXaw3d" >&5 +ac_lib_var=`echo Xaw3d'_'XawScrollbarSetThumb | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXaw3d " +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=no" +fi +rm -f conftest* +xe_check_libs="" + +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then + echo "$ac_t""yes" 1>&6 + have_xaw3d=yes +else + echo "$ac_t""no" 1>&6 +have_xaw3d=no +fi + + + ac_safe=`echo "Xm/Xm.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for Xm/Xm.h""... $ac_c" 1>&6 -echo "configure:7533: checking for Xm/Xm.h" >&5 +echo "configure:7578: checking for Xm/Xm.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7541: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7586: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7554,12 +7599,12 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 echo $ac_n "checking for XmStringFree in -lXm""... $ac_c" 1>&6 -echo "configure:7558: checking for XmStringFree in -lXm" >&5 +echo "configure:7603: checking for XmStringFree in -lXm" >&5 ac_lib_var=`echo Xm'_'XmStringFree | sed 'y%./+-%__p_%'` xe_check_libs=" -lXm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7619: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7599,9 +7644,9 @@ fi if test "$have_motif" = "yes"; then echo $ac_n "checking for Lesstif""... $ac_c" 1>&6 -echo "configure:7603: checking for Lesstif" >&5 +echo "configure:7648: checking for Lesstif" >&5 cat > conftest.$ac_ext < #ifdef LESSTIF_VERSION @@ -7629,6 +7674,7 @@ case "$with_menubars" in "" | "yes" | "athena" | "athena3d" ) esac case "$with_dialogs" in "" | "yes" | "lucid" ) if test "$have_motif" = "yes"; then with_dialogs="motif" + elif test "$have_xaw3d" = "yes"; then with_dialogs="athena3d" elif test "$have_xaw" = "yes"; then with_dialogs="athena" else with_dialogs=no fi ;; @@ -7636,15 +7682,41 @@ esac case "$with_scrollbars" in "" | "yes" ) with_scrollbars="lucid" ;; esac -case "$with_widgets" in "" | "yes" ) +case "$with_widgets" in "" | "yes" | "lucid") if test "$have_motif" = "yes"; then with_widgets="motif" + elif test "$have_xaw3d" = "yes"; then with_widgets="athena3d" + elif test "$have_xaw" = "yes"; then with_widgets="athena" else with_widgets=no fi ;; esac all_widgets="$with_menubars $with_scrollbars $with_dialogs $with_toolbars $with_widgets" -case "$all_widgets" in *athena* ) +case "$all_widgets" in + *athena*3d ) + { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_USES_ATHENA +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_USES_ATHENA 1 +EOF +} + + { test "$extra_verbose" = "yes" && cat << \EOF + Defining NEED_ATHENA +EOF +cat >> confdefs.h <<\EOF +#define NEED_ATHENA 1 +EOF +} + + lwlib_objs="$lwlib_objs lwlib-Xaw.o" && if test "$extra_verbose" = "yes"; then echo " Appending \"lwlib-Xaw.o\" to \$lwlib_objs"; fi + if test "$have_xaw3d"; then + libs_x="-lXaw3d $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXaw3d\" to \$libs_x"; fi + else + libs_x="-lXaw $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXaw\" to \$libs_x"; fi + fi ;; + *athena* ) { test "$extra_verbose" = "yes" && cat << \EOF Defining LWLIB_USES_ATHENA EOF @@ -7689,6 +7761,11 @@ esac test "$with_menubars" = "lucid" && lwlib_objs="$lwlib_objs xlwmenu.o" && if test "$extra_verbose" = "yes"; then echo " Appending \"xlwmenu.o\" to \$lwlib_objs"; fi test "$with_menubars" = "motif" && lwlib_objs="$lwlib_objs xlwmenu.o" && if test "$extra_verbose" = "yes"; then echo " Appending \"xlwmenu.o\" to \$lwlib_objs"; fi test "$with_scrollbars" = "lucid" && lwlib_objs="$lwlib_objs xlwscrollbar.o" && if test "$extra_verbose" = "yes"; then echo " Appending \"xlwscrollbar.o\" to \$lwlib_objs"; fi +test "$with_widgets" != "no" && test "$with_widgets" != "msw" && \ + lwlib_objs="$lwlib_objs xlwtabs.o xlwgcs.o" && if test "$extra_verbose" = "yes"; then echo " Appending \"xlwtabs.o xlwgcs.o\" to \$lwlib_objs"; fi +case "$with_widgets" in athena* ) + lwlib_objs="$lwlib_objs xlwradio.o xlwcheckbox.o xlwgauge.o" && if test "$extra_verbose" = "yes"; then echo " Appending \"xlwradio.o xlwcheckbox.o xlwgauge.o\" to \$lwlib_objs"; fi;; +esac case "$all_widgets" in *lucid* ) { test "$extra_verbose" = "yes" && cat << \EOF Defining NEED_LUCID @@ -7735,6 +7812,23 @@ cat >> confdefs.h <<\EOF EOF } +case "$with_widgets" in athena* ) { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_WIDGETS_ATHENA +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_WIDGETS_ATHENA 1 +EOF +} +;; esac +test "$with_widgets" != "no" && test "$with_widgets" != "msw" && \ + { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_TABS_LUCID +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_TABS_LUCID 1 +EOF +} + test "$with_menubars" != "no" && { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_MENUBARS @@ -7768,6 +7862,14 @@ cat >> confdefs.h <<\EOF EOF } +test "$with_widgets" != "no" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_WIDGETS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_WIDGETS 1 +EOF +} + test "$with_menubars" = "lucid" && { test "$extra_verbose" = "yes" && cat << \EOF Defining LWLIB_MENUBARS_LUCID @@ -7810,6 +7912,14 @@ cat >> confdefs.h <<\EOF EOF } +test "$with_widgets" = "motif" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_WIDGETS_MOTIF +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_WIDGETS_MOTIF 1 +EOF +} + test "$with_menubars" != "no" && extra_objs="$extra_objs menubar.o" && if test "$extra_verbose" = "yes"; then echo " xemacs will be linked with \"menubar.o\"" @@ -7869,7 +7979,7 @@ fi if test "$with_mule" = "yes" ; then echo "checking for Mule-related features" 1>&6 -echo "configure:7873: checking for Mule-related features" >&5 +echo "configure:7983: checking for Mule-related features" >&5 { test "$extra_verbose" = "yes" && cat << \EOF Defining MULE EOF @@ -7894,15 +8004,15 @@ EOF do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:7898: checking for $ac_hdr" >&5 +echo "configure:8008: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7906: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8016: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7933,12 +8043,12 @@ done echo $ac_n "checking for strerror in -lintl""... $ac_c" 1>&6 -echo "configure:7937: checking for strerror in -lintl" >&5 +echo "configure:8047: checking for strerror in -lintl" >&5 ac_lib_var=`echo intl'_'strerror | sed 'y%./+-%__p_%'` xe_check_libs=" -lintl " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8063: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -7982,18 +8092,18 @@ fi echo "checking for Mule input methods" 1>&6 -echo "configure:7986: checking for Mule input methods" >&5 +echo "configure:8096: checking for Mule input methods" >&5 case "$with_xim" in "" | "yes" ) echo "checking for XIM" 1>&6 -echo "configure:7989: checking for XIM" >&5 +echo "configure:8099: checking for XIM" >&5 echo $ac_n "checking for XOpenIM in -lX11""... $ac_c" 1>&6 -echo "configure:7992: checking for XOpenIM in -lX11" >&5 +echo "configure:8102: checking for XOpenIM in -lX11" >&5 ac_lib_var=`echo X11'_'XOpenIM | sed 'y%./+-%__p_%'` xe_check_libs=" -lX11 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8118: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8028,12 +8138,12 @@ fi if test "$have_motif $have_lesstif" = "yes no"; then echo $ac_n "checking for XmImMbLookupString in -lXm""... $ac_c" 1>&6 -echo "configure:8032: checking for XmImMbLookupString in -lXm" >&5 +echo "configure:8142: checking for XmImMbLookupString in -lXm" >&5 ac_lib_var=`echo Xm'_'XmImMbLookupString | sed 'y%./+-%__p_%'` xe_check_libs=" -lXm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8109,15 +8219,15 @@ EOF if test "$with_xfs" = "yes" ; then echo "checking for XFontSet" 1>&6 -echo "configure:8113: checking for XFontSet" >&5 +echo "configure:8223: checking for XFontSet" >&5 echo $ac_n "checking for XmbDrawString in -lX11""... $ac_c" 1>&6 -echo "configure:8116: checking for XmbDrawString in -lX11" >&5 +echo "configure:8226: checking for XmbDrawString in -lX11" >&5 ac_lib_var=`echo X11'_'XmbDrawString | sed 'y%./+-%__p_%'` xe_check_libs=" -lX11 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8242: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8168,15 +8278,15 @@ EOF test "$with_wnn6" = "yes" && with_wnn=yes # wnn6 implies wnn support test -z "$with_wnn" && { ac_safe=`echo "wnn/jllib.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for wnn/jllib.h""... $ac_c" 1>&6 -echo "configure:8172: checking for wnn/jllib.h" >&5 +echo "configure:8282: checking for wnn/jllib.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8180: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8290: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -8201,10 +8311,10 @@ fi for ac_func in crypt do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:8205: checking for $ac_func" >&5 +echo "configure:8315: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8341: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -8256,12 +8366,12 @@ done test "$ac_cv_func_crypt" != "yes" && { echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6 -echo "configure:8260: checking for crypt in -lcrypt" >&5 +echo "configure:8370: checking for crypt in -lcrypt" >&5 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'` xe_check_libs=" -lcrypt " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8386: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8307,12 +8417,12 @@ fi if test -z "$with_wnn" -o "$with_wnn" = "yes"; then echo $ac_n "checking for jl_dic_list_e in -lwnn""... $ac_c" 1>&6 -echo "configure:8311: checking for jl_dic_list_e in -lwnn" >&5 +echo "configure:8421: checking for jl_dic_list_e in -lwnn" >&5 ac_lib_var=`echo wnn'_'jl_dic_list_e | sed 'y%./+-%__p_%'` xe_check_libs=" -lwnn " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8341,12 +8451,12 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for jl_dic_list_e in -lwnn4""... $ac_c" 1>&6 -echo "configure:8345: checking for jl_dic_list_e in -lwnn4" >&5 +echo "configure:8455: checking for jl_dic_list_e in -lwnn4" >&5 ac_lib_var=`echo wnn4'_'jl_dic_list_e | sed 'y%./+-%__p_%'` xe_check_libs=" -lwnn4 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8471: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8375,12 +8485,12 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for jl_dic_list_e in -lwnn6""... $ac_c" 1>&6 -echo "configure:8379: checking for jl_dic_list_e in -lwnn6" >&5 +echo "configure:8489: checking for jl_dic_list_e in -lwnn6" >&5 ac_lib_var=`echo wnn6'_'jl_dic_list_e | sed 'y%./+-%__p_%'` xe_check_libs=" -lwnn6 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8505: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8409,12 +8519,12 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for dic_list_e in -lwnn6_fromsrc""... $ac_c" 1>&6 -echo "configure:8413: checking for dic_list_e in -lwnn6_fromsrc" >&5 +echo "configure:8523: checking for dic_list_e in -lwnn6_fromsrc" >&5 ac_lib_var=`echo wnn6_fromsrc'_'dic_list_e | sed 'y%./+-%__p_%'` xe_check_libs=" -lwnn6_fromsrc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8473,12 +8583,12 @@ EOF if test "$with_wnn6" != "no"; then echo $ac_n "checking for jl_fi_dic_list in -l$libwnn""... $ac_c" 1>&6 -echo "configure:8477: checking for jl_fi_dic_list in -l$libwnn" >&5 +echo "configure:8587: checking for jl_fi_dic_list in -l$libwnn" >&5 ac_lib_var=`echo $libwnn'_'jl_fi_dic_list | sed 'y%./+-%__p_%'` xe_check_libs=" -l$libwnn " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8603: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8524,15 +8634,15 @@ EOF if test "$with_canna" != "no"; then ac_safe=`echo "canna/jrkanji.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for canna/jrkanji.h""... $ac_c" 1>&6 -echo "configure:8528: checking for canna/jrkanji.h" >&5 +echo "configure:8638: checking for canna/jrkanji.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8536: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8646: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -8559,15 +8669,15 @@ fi c_switch_site="$c_switch_site -I/usr/local/canna/include" ac_safe=`echo "canna/jrkanji.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for canna/jrkanji.h""... $ac_c" 1>&6 -echo "configure:8563: checking for canna/jrkanji.h" >&5 +echo "configure:8673: checking for canna/jrkanji.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8571: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8681: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -8595,15 +8705,15 @@ fi test -z "$with_canna" && { ac_safe=`echo "canna/RK.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for canna/RK.h""... $ac_c" 1>&6 -echo "configure:8599: checking for canna/RK.h" >&5 +echo "configure:8709: checking for canna/RK.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8607: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:8717: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -8626,12 +8736,12 @@ fi } test -z "$with_canna" && { echo $ac_n "checking for RkBgnBun in -lRKC""... $ac_c" 1>&6 -echo "configure:8630: checking for RkBgnBun in -lRKC" >&5 +echo "configure:8740: checking for RkBgnBun in -lRKC" >&5 ac_lib_var=`echo RKC'_'RkBgnBun | sed 'y%./+-%__p_%'` xe_check_libs=" -lRKC " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8665,12 +8775,12 @@ fi } test -z "$with_canna" && { echo $ac_n "checking for jrKanjiControl in -lcanna""... $ac_c" 1>&6 -echo "configure:8669: checking for jrKanjiControl in -lcanna" >&5 +echo "configure:8779: checking for jrKanjiControl in -lcanna" >&5 ac_lib_var=`echo canna'_'jrKanjiControl | sed 'y%./+-%__p_%'` xe_check_libs=" -lcanna " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8795: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8730,12 +8840,12 @@ if test "$need_motif" = "yes" ; then libs_x="-lXm $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXm\" to \$libs_x"; fi echo $ac_n "checking for layout_object_getvalue in -li18n""... $ac_c" 1>&6 -echo "configure:8734: checking for layout_object_getvalue in -li18n" >&5 +echo "configure:8844: checking for layout_object_getvalue in -li18n" >&5 ac_lib_var=`echo i18n'_'layout_object_getvalue | sed 'y%./+-%__p_%'` xe_check_libs=" -li18n " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -8829,13 +8939,13 @@ fi fi -for ac_func in cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask snprintf strcasecmp strerror tzset ulimit usleep utimes waitpid vsnprintf +for ac_func in cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getpt getwd logb lrand48 matherr mkdir mktime perror poll random rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask snprintf stpcpy strcasecmp strerror tzset ulimit usleep utimes waitpid vsnprintf do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:8836: checking for $ac_func" >&5 +echo "configure:8946: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8972: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -8899,10 +9009,10 @@ case "$opsys" in * ) for ac_func in realpath do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:8903: checking for $ac_func" >&5 +echo "configure:9013: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9039: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -8961,10 +9071,10 @@ esac for ac_func in getloadavg do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:8965: checking for $ac_func" >&5 +echo "configure:9075: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -9023,12 +9133,12 @@ then echo $ac_n "checking for kstat_open in -lkstat""... $ac_c" 1>&6 -echo "configure:9027: checking for kstat_open in -lkstat" >&5 +echo "configure:9137: checking for kstat_open in -lkstat" >&5 ac_lib_var=`echo kstat'_'kstat_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lkstat " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9153: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -9073,12 +9183,12 @@ fi echo $ac_n "checking for kvm_read in -lkvm""... $ac_c" 1>&6 -echo "configure:9077: checking for kvm_read in -lkvm" >&5 +echo "configure:9187: checking for kvm_read in -lkvm" >&5 ac_lib_var=`echo kvm'_'kvm_read | sed 'y%./+-%__p_%'` xe_check_libs=" -lkvm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -9123,16 +9233,16 @@ fi fi echo $ac_n "checking whether netdb declares h_errno""... $ac_c" 1>&6 -echo "configure:9127: checking whether netdb declares h_errno" >&5 +echo "configure:9237: checking whether netdb declares h_errno" >&5 cat > conftest.$ac_ext < int main() { return h_errno; ; return 0; } EOF -if { (eval echo configure:9136: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9246: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* echo "$ac_t""yes" 1>&6 { test "$extra_verbose" = "yes" && cat << \EOF @@ -9152,16 +9262,16 @@ fi rm -f conftest* echo $ac_n "checking for sigsetjmp""... $ac_c" 1>&6 -echo "configure:9156: checking for sigsetjmp" >&5 +echo "configure:9266: checking for sigsetjmp" >&5 cat > conftest.$ac_ext < int main() { sigjmp_buf bar; sigsetjmp (bar, 0); ; return 0; } EOF -if { (eval echo configure:9165: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:9275: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 { test "$extra_verbose" = "yes" && cat << \EOF @@ -9181,11 +9291,11 @@ fi rm -f conftest* echo $ac_n "checking whether localtime caches TZ""... $ac_c" 1>&6 -echo "configure:9185: checking whether localtime caches TZ" >&5 +echo "configure:9295: checking whether localtime caches TZ" >&5 if test "$ac_cv_func_tzset" = "yes"; then cat > conftest.$ac_ext < #if STDC_HEADERS @@ -9220,7 +9330,7 @@ main() exit (0); } EOF -if { (eval echo configure:9224: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9334: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then emacs_cv_localtime_cache=no else @@ -9250,9 +9360,9 @@ fi if test "$HAVE_TIMEVAL" = "yes"; then echo $ac_n "checking whether gettimeofday accepts one or two arguments""... $ac_c" 1>&6 -echo "configure:9254: checking whether gettimeofday accepts one or two arguments" >&5 +echo "configure:9364: checking whether gettimeofday accepts one or two arguments" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* echo "$ac_t""two" 1>&6 else @@ -9296,19 +9406,19 @@ fi echo $ac_n "checking for inline""... $ac_c" 1>&6 -echo "configure:9300: checking for inline" >&5 +echo "configure:9410: checking for inline" >&5 ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:9422: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_inline=$ac_kw; break else @@ -9358,17 +9468,17 @@ fi # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 -echo "configure:9362: checking for working alloca.h" >&5 +echo "configure:9472: checking for working alloca.h" >&5 cat > conftest.$ac_ext < int main() { char *p = alloca(2 * sizeof(int)); ; return 0; } EOF -if { (eval echo configure:9372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9482: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_header_alloca_h=yes else @@ -9392,10 +9502,10 @@ EOF fi echo $ac_n "checking for alloca""... $ac_c" 1>&6 -echo "configure:9396: checking for alloca" >&5 +echo "configure:9506: checking for alloca" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9537: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_func_alloca_works=yes else @@ -9462,10 +9572,10 @@ EOF echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 -echo "configure:9466: checking whether alloca needs Cray hooks" >&5 +echo "configure:9576: checking whether alloca needs Cray hooks" >&5 cat > conftest.$ac_ext <&6 if test $ac_cv_os_cray = yes; then for ac_func in _getb67 GETB67 getb67; do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:9493: checking for $ac_func" >&5 +echo "configure:9603: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9629: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -9545,10 +9655,10 @@ done fi echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 -echo "configure:9549: checking stack direction for C alloca" >&5 +echo "configure:9659: checking stack direction for C alloca" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9681: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_c_stack_direction=1 else @@ -9596,15 +9706,15 @@ test -n "$ALLOCA" && extra_objs="$extra_objs $ALLOCA" && if test "$extra_verbos ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for vfork.h""... $ac_c" 1>&6 -echo "configure:9600: checking for vfork.h" >&5 +echo "configure:9710: checking for vfork.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:9608: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:9718: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -9632,10 +9742,10 @@ else fi echo $ac_n "checking for working vfork""... $ac_c" 1>&6 -echo "configure:9636: checking for working vfork" >&5 +echo "configure:9746: checking for working vfork" >&5 cat > conftest.$ac_ext < @@ -9730,7 +9840,7 @@ main() { } } EOF -if { (eval echo configure:9734: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9844: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_func_vfork_works=yes else @@ -9756,10 +9866,10 @@ fi echo $ac_n "checking for working strcoll""... $ac_c" 1>&6 -echo "configure:9760: checking for working strcoll" >&5 +echo "configure:9870: checking for working strcoll" >&5 cat > conftest.$ac_ext < main () @@ -9769,7 +9879,7 @@ main () strcoll ("123", "456") >= 0); } EOF -if { (eval echo configure:9773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_func_strcoll_works=yes else @@ -9797,10 +9907,10 @@ fi for ac_func in getpgrp do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:9801: checking for $ac_func" >&5 +echo "configure:9911: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9937: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -9851,10 +9961,10 @@ fi done echo $ac_n "checking whether getpgrp takes no argument""... $ac_c" 1>&6 -echo "configure:9855: checking whether getpgrp takes no argument" >&5 +echo "configure:9965: checking whether getpgrp takes no argument" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:10023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_func_getpgrp_void=yes else @@ -9936,10 +10046,10 @@ fi echo $ac_n "checking for working mmap""... $ac_c" 1>&6 -echo "configure:9940: checking for working mmap" >&5 +echo "configure:10050: checking for working mmap" >&5 case "$opsys" in ultrix* ) have_mmap=no ;; *) cat > conftest.$ac_ext < #include @@ -9972,7 +10082,7 @@ int main (int argc, char *argv[]) return 1; } EOF -if { (eval echo configure:9976: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:10086: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then have_mmap=yes else @@ -10007,15 +10117,15 @@ EOF ac_safe=`echo "termios.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for termios.h""... $ac_c" 1>&6 -echo "configure:10011: checking for termios.h" >&5 +echo "configure:10121: checking for termios.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10019: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10129: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10058,15 +10168,15 @@ else echo "$ac_t""no" 1>&6 ac_safe=`echo "termio.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for termio.h""... $ac_c" 1>&6 -echo "configure:10062: checking for termio.h" >&5 +echo "configure:10172: checking for termio.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10070: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10180: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10098,10 +10208,10 @@ fi echo $ac_n "checking for socket""... $ac_c" 1>&6 -echo "configure:10102: checking for socket" >&5 +echo "configure:10212: checking for socket" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_socket=yes" else @@ -10139,15 +10249,15 @@ if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then echo "$ac_t""yes" 1>&6 ac_safe=`echo "netinet/in.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for netinet/in.h""... $ac_c" 1>&6 -echo "configure:10143: checking for netinet/in.h" >&5 +echo "configure:10253: checking for netinet/in.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10151: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10261: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10164,15 +10274,15 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 ac_safe=`echo "arpa/inet.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for arpa/inet.h""... $ac_c" 1>&6 -echo "configure:10168: checking for arpa/inet.h" >&5 +echo "configure:10278: checking for arpa/inet.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10176: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10286: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10197,9 +10307,9 @@ EOF } echo $ac_n "checking "for sun_len member in struct sockaddr_un"""... $ac_c" 1>&6 -echo "configure:10201: checking "for sun_len member in struct sockaddr_un"" >&5 +echo "configure:10311: checking "for sun_len member in struct sockaddr_un"" >&5 cat > conftest.$ac_ext < @@ -10210,7 +10320,7 @@ int main() { static struct sockaddr_un x; x.sun_len = 1; ; return 0; } EOF -if { (eval echo configure:10214: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10324: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* echo "$ac_t""yes" 1>&6; { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_SOCKADDR_SUN_LEN @@ -10228,9 +10338,9 @@ else fi rm -f conftest* echo $ac_n "checking "for ip_mreq struct in netinet/in.h"""... $ac_c" 1>&6 -echo "configure:10232: checking "for ip_mreq struct in netinet/in.h"" >&5 +echo "configure:10342: checking "for ip_mreq struct in netinet/in.h"" >&5 cat > conftest.$ac_ext < @@ -10240,7 +10350,7 @@ int main() { static struct ip_mreq x; ; return 0; } EOF -if { (eval echo configure:10244: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10354: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* echo "$ac_t""yes" 1>&6; { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_MULTICAST @@ -10271,10 +10381,10 @@ fi echo $ac_n "checking for msgget""... $ac_c" 1>&6 -echo "configure:10275: checking for msgget" >&5 +echo "configure:10385: checking for msgget" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_msgget=yes" else @@ -10312,15 +10422,15 @@ if eval "test \"`echo '$ac_cv_func_'msgget`\" = yes"; then echo "$ac_t""yes" 1>&6 ac_safe=`echo "sys/ipc.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for sys/ipc.h""... $ac_c" 1>&6 -echo "configure:10316: checking for sys/ipc.h" >&5 +echo "configure:10426: checking for sys/ipc.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10324: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10434: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10337,15 +10447,15 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 ac_safe=`echo "sys/msg.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for sys/msg.h""... $ac_c" 1>&6 -echo "configure:10341: checking for sys/msg.h" >&5 +echo "configure:10451: checking for sys/msg.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10349: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10459: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10383,15 +10493,15 @@ fi ac_safe=`echo "dirent.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for dirent.h""... $ac_c" 1>&6 -echo "configure:10387: checking for dirent.h" >&5 +echo "configure:10497: checking for dirent.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10395: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10505: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10418,15 +10528,15 @@ else echo "$ac_t""no" 1>&6 ac_safe=`echo "sys/dir.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for sys/dir.h""... $ac_c" 1>&6 -echo "configure:10422: checking for sys/dir.h" >&5 +echo "configure:10532: checking for sys/dir.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10430: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10540: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10459,15 +10569,15 @@ fi ac_safe=`echo "nlist.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for nlist.h""... $ac_c" 1>&6 -echo "configure:10463: checking for nlist.h" >&5 +echo "configure:10573: checking for nlist.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10471: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10581: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10497,7 +10607,7 @@ fi echo "checking "for sound support"" 1>&6 -echo "configure:10501: checking "for sound support"" >&5 +echo "configure:10611: checking "for sound support"" >&5 case "$with_sound" in native | both ) with_native_sound=yes;; nas | no ) with_native_sound=no;; @@ -10508,15 +10618,15 @@ if test "$with_native_sound" != "no"; then if test -n "$native_sound_lib"; then ac_safe=`echo "multimedia/audio_device.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for multimedia/audio_device.h""... $ac_c" 1>&6 -echo "configure:10512: checking for multimedia/audio_device.h" >&5 +echo "configure:10622: checking for multimedia/audio_device.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10520: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10630: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10564,12 +10674,12 @@ fi if test -z "$native_sound_lib"; then echo $ac_n "checking for ALopenport in -laudio""... $ac_c" 1>&6 -echo "configure:10568: checking for ALopenport in -laudio" >&5 +echo "configure:10678: checking for ALopenport in -laudio" >&5 ac_lib_var=`echo audio'_'ALopenport | sed 'y%./+-%__p_%'` xe_check_libs=" -laudio " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -10611,12 +10721,12 @@ fi if test -z "$native_sound_lib"; then echo $ac_n "checking for AOpenAudio in -lAlib""... $ac_c" 1>&6 -echo "configure:10615: checking for AOpenAudio in -lAlib" >&5 +echo "configure:10725: checking for AOpenAudio in -lAlib" >&5 ac_lib_var=`echo Alib'_'AOpenAudio | sed 'y%./+-%__p_%'` xe_check_libs=" -lAlib " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10741: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -10665,15 +10775,15 @@ fi for dir in "machine" "sys" "linux"; do ac_safe=`echo "${dir}/soundcard.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ${dir}/soundcard.h""... $ac_c" 1>&6 -echo "configure:10669: checking for ${dir}/soundcard.h" >&5 +echo "configure:10779: checking for ${dir}/soundcard.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10677: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10787: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10743,7 +10853,7 @@ EOF fi libs_x="-laudio $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-laudio\" to \$libs_x"; fi cat > conftest.$ac_ext < EOF @@ -10770,7 +10880,7 @@ test -z "$with_tty" && with_tty=yes if test "$with_tty" = "yes" ; then echo "checking for TTY-related features" 1>&6 -echo "configure:10774: checking for TTY-related features" >&5 +echo "configure:10884: checking for TTY-related features" >&5 { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_TTY EOF @@ -10786,12 +10896,12 @@ EOF if test -z "$with_ncurses"; then echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6 -echo "configure:10790: checking for tgetent in -lncurses" >&5 +echo "configure:10900: checking for tgetent in -lncurses" >&5 ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'` xe_check_libs=" -lncurses " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10916: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -10835,15 +10945,15 @@ EOF ac_safe=`echo "ncurses/curses.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ncurses/curses.h""... $ac_c" 1>&6 -echo "configure:10839: checking for ncurses/curses.h" >&5 +echo "configure:10949: checking for ncurses/curses.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10847: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10957: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10865,15 +10975,15 @@ fi ac_safe=`echo "ncurses/term.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ncurses/term.h""... $ac_c" 1>&6 -echo "configure:10869: checking for ncurses/term.h" >&5 +echo "configure:10979: checking for ncurses/term.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10877: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:10987: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10903,15 +11013,15 @@ fi c_switch_site="$c_switch_site -I/usr/include/ncurses" ac_safe=`echo "ncurses/curses.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ncurses/curses.h""... $ac_c" 1>&6 -echo "configure:10907: checking for ncurses/curses.h" >&5 +echo "configure:11017: checking for ncurses/curses.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10915: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:11025: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -10946,12 +11056,12 @@ fi for lib in curses termlib termcap; do echo $ac_n "checking for tgetent in -l$lib""... $ac_c" 1>&6 -echo "configure:10950: checking for tgetent in -l$lib" >&5 +echo "configure:11060: checking for tgetent in -l$lib" >&5 ac_lib_var=`echo $lib'_'tgetent | sed 'y%./+-%__p_%'` xe_check_libs=" -l$lib " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11076: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -10993,12 +11103,12 @@ fi else echo $ac_n "checking for tgetent in -lcurses""... $ac_c" 1>&6 -echo "configure:10997: checking for tgetent in -lcurses" >&5 +echo "configure:11107: checking for tgetent in -lcurses" >&5 ac_lib_var=`echo curses'_'tgetent | sed 'y%./+-%__p_%'` xe_check_libs=" -lcurses " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11027,12 +11137,12 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6 -echo "configure:11031: checking for tgetent in -ltermcap" >&5 +echo "configure:11141: checking for tgetent in -ltermcap" >&5 ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'` xe_check_libs=" -ltermcap " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11157: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11091,15 +11201,15 @@ EOF test -z "$with_gpm" && { ac_safe=`echo "gpm.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for gpm.h""... $ac_c" 1>&6 -echo "configure:11095: checking for gpm.h" >&5 +echo "configure:11205: checking for gpm.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:11103: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:11213: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -11122,12 +11232,12 @@ fi } test -z "$with_gpm" && { echo $ac_n "checking for Gpm_Open in -lgpm""... $ac_c" 1>&6 -echo "configure:11126: checking for Gpm_Open in -lgpm" >&5 +echo "configure:11236: checking for Gpm_Open in -lgpm" >&5 ac_lib_var=`echo gpm'_'Gpm_Open | sed 'y%./+-%__p_%'` xe_check_libs=" -lgpm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11252: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11188,20 +11298,20 @@ test "$with_x11" = "yes" -o "$with_tty" = "yes" && extra_objs="$extra_objs event test "$with_database_gnudbm $with_database_dbm $with_database_berkdb" \ != "no no no" && echo "checking for database support" 1>&6 -echo "configure:11192: checking for database support" >&5 +echo "configure:11302: checking for database support" >&5 if test "$with_database_gnudbm $with_database_dbm" != "no no"; then ac_safe=`echo "ndbm.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ndbm.h""... $ac_c" 1>&6 -echo "configure:11197: checking for ndbm.h" >&5 +echo "configure:11307: checking for ndbm.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:11205: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:11315: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -11231,12 +11341,12 @@ fi if test "$with_database_gnudbm" != "no"; then echo $ac_n "checking for dbm_open in -lgdbm""... $ac_c" 1>&6 -echo "configure:11235: checking for dbm_open in -lgdbm" >&5 +echo "configure:11345: checking for dbm_open in -lgdbm" >&5 ac_lib_var=`echo gdbm'_'dbm_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lgdbm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11361: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11275,10 +11385,10 @@ fi if test "$with_database_dbm" != "no"; then echo $ac_n "checking for dbm_open""... $ac_c" 1>&6 -echo "configure:11279: checking for dbm_open" >&5 +echo "configure:11389: checking for dbm_open" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11415: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_dbm_open=yes" else @@ -11320,12 +11430,12 @@ else echo $ac_n "checking for dbm_open in -ldbm""... $ac_c" 1>&6 -echo "configure:11324: checking for dbm_open in -ldbm" >&5 +echo "configure:11434: checking for dbm_open in -ldbm" >&5 ac_lib_var=`echo dbm'_'dbm_open | sed 'y%./+-%__p_%'` xe_check_libs=" -ldbm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11450: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11377,10 +11487,10 @@ EOF if test "$with_database_berkdb" != "no"; then echo $ac_n "checking for Berkeley db.h""... $ac_c" 1>&6 -echo "configure:11381: checking for Berkeley db.h" >&5 +echo "configure:11491: checking for Berkeley db.h" >&5 for path in "db/db.h" "db.h"; do cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:11512: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* db_h_path="$path"; break else @@ -11414,9 +11524,9 @@ rm -f conftest* if test "$with_database_berkdb" != "no"; then echo $ac_n "checking for Berkeley DB version""... $ac_c" 1>&6 -echo "configure:11418: checking for Berkeley DB version" >&5 +echo "configure:11528: checking for Berkeley DB version" >&5 cat > conftest.$ac_ext < #if DB_VERSION_MAJOR > 1 @@ -11435,10 +11545,10 @@ fi rm -f conftest* echo $ac_n "checking for $dbfunc""... $ac_c" 1>&6 -echo "configure:11439: checking for $dbfunc" >&5 +echo "configure:11549: checking for $dbfunc" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11575: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$dbfunc=yes" else @@ -11480,12 +11590,12 @@ else echo $ac_n "checking for $dbfunc in -ldb""... $ac_c" 1>&6 -echo "configure:11484: checking for $dbfunc in -ldb" >&5 +echo "configure:11594: checking for $dbfunc in -ldb" >&5 ac_lib_var=`echo db'_'$dbfunc | sed 'y%./+-%__p_%'` xe_check_libs=" -ldb " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11610: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11560,12 +11670,12 @@ fi if test "$with_socks" = "yes"; then echo $ac_n "checking for SOCKSinit in -lsocks""... $ac_c" 1>&6 -echo "configure:11564: checking for SOCKSinit in -lsocks" >&5 +echo "configure:11674: checking for SOCKSinit in -lsocks" >&5 ac_lib_var=`echo socks'_'SOCKSinit | sed 'y%./+-%__p_%'` xe_check_libs=" -lsocks " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11690: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11633,15 +11743,15 @@ for ac_hdr in dlfcn.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:11637: checking for $ac_hdr" >&5 +echo "configure:11747: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:11645: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:11755: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -11680,12 +11790,12 @@ done test -z "$with_modules" && test ! -z "$have_dlfcn" && { echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 -echo "configure:11684: checking for dlopen in -ldl" >&5 +echo "configure:11794: checking for dlopen in -ldl" >&5 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` xe_check_libs=" -ldl " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11810: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11725,12 +11835,12 @@ fi } test -z "$with_modules" && test ! -z "$have_dlfcn" && { echo $ac_n "checking for _dlopen in -lc""... $ac_c" 1>&6 -echo "configure:11729: checking for _dlopen in -lc" >&5 +echo "configure:11839: checking for _dlopen in -lc" >&5 ac_lib_var=`echo c'_'_dlopen | sed 'y%./+-%__p_%'` xe_check_libs=" -lc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11855: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11770,12 +11880,12 @@ fi } test -z "$with_modules" && test ! -z "$have_dlfcn" && { echo $ac_n "checking for dlopen in -lc""... $ac_c" 1>&6 -echo "configure:11774: checking for dlopen in -lc" >&5 +echo "configure:11884: checking for dlopen in -lc" >&5 ac_lib_var=`echo c'_'dlopen | sed 'y%./+-%__p_%'` xe_check_libs=" -lc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11815,12 +11925,12 @@ fi } test -z "$with_modules" && { echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 -echo "configure:11819: checking for shl_load in -ldld" >&5 +echo "configure:11929: checking for shl_load in -ldld" >&5 ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` xe_check_libs=" -ldld " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11860,12 +11970,12 @@ fi } test -z "$with_modules" && { echo $ac_n "checking for dld_init in -ldld""... $ac_c" 1>&6 -echo "configure:11864: checking for dld_init in -ldld" >&5 +echo "configure:11974: checking for dld_init in -ldld" >&5 ac_lib_var=`echo dld'_'dld_init | sed 'y%./+-%__p_%'` xe_check_libs=" -ldld " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -11915,7 +12025,7 @@ xehost=$canonical xealias=$internal_configuration echo "checking how to build dynamic libraries for ${xehost}" 1>&6 -echo "configure:11919: checking how to build dynamic libraries for ${xehost}" >&5 +echo "configure:12029: checking how to build dynamic libraries for ${xehost}" >&5 # Transform *-*-linux* to *-*-linux-gnu*, to support old configure scripts. case "$xehost" in *-*-linux-gnu*) ;; @@ -11943,9 +12053,9 @@ if test "$GCC" = "yes"; then XEGCC=yes else echo $ac_n "checking checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:11947: checking checking whether we are using GNU C" >&5 +echo "configure:12057: checking checking whether we are using GNU C" >&5 cat > conftest.$ac_ext <&6 -echo "configure:11971: checking how to produce PIC code" >&5 +echo "configure:12081: checking how to produce PIC code" >&5 wl= can_build_shared=yes @@ -12060,18 +12170,18 @@ if test -n "$dll_cflags"; then # Check to make sure the dll_cflags actually works. echo $ac_n "checking if PIC flag ${dll_cflags} really works""... $ac_c" 1>&6 -echo "configure:12064: checking if PIC flag ${dll_cflags} really works" >&5 +echo "configure:12174: checking if PIC flag ${dll_cflags} really works" >&5 save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS $dll_cflags -DPIC" cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:12185: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* # On HP-UX, the stripped-down bundled CC doesn't accept +Z, but also @@ -12102,7 +12212,7 @@ cc_produces_so=no xldf= xcldf= echo $ac_n "checking if C compiler can produce shared libraries""... $ac_c" 1>&6 -echo "configure:12106: checking if C compiler can produce shared libraries" >&5 +echo "configure:12216: checking if C compiler can produce shared libraries" >&5 if test "$XEGCC" = yes; then xcldf="-shared" xldf="-shared" @@ -12153,14 +12263,14 @@ if test -n "$xcldf"; then xe_libs= ac_link='${CC-cc} -o conftest $CFLAGS '"$xe_cppflags $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:12274: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* cc_produces_so=yes else @@ -12185,7 +12295,7 @@ if test -z "$LTLD"; then if test "$XEGCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6 -echo "configure:12189: checking for ld used by GCC" >&5 +echo "configure:12299: checking for ld used by GCC" >&5 ac_prog=`($CC -print-prog-name=ld) 2>&5` case "$ac_prog" in # Accept absolute paths. @@ -12210,7 +12320,7 @@ echo "configure:12189: checking for ld used by GCC" >&5 esac else echo $ac_n "checking for GNU ld""... $ac_c" 1>&6 -echo "configure:12214: checking for GNU ld" >&5 +echo "configure:12324: checking for GNU ld" >&5 fi if test -z "$LTLD"; then @@ -12248,7 +12358,7 @@ ld_dynamic_link_flags= # Check to see if it really is or isn't GNU ld. echo $ac_n "checking if the linker is GNU ld""... $ac_c" 1>&6 -echo "configure:12252: checking if the linker is GNU ld" >&5 +echo "configure:12362: checking if the linker is GNU ld" >&5 # I'd rather use --version here, but apparently some GNU ld's only accept -v. if $LTLD -v 2>&1 &5; then xe_gnu_ld=yes @@ -12275,7 +12385,7 @@ else # OK - only NOW do we futz about with ld. # See if the linker supports building shared libraries. echo $ac_n "checking whether the linker supports shared libraries""... $ac_c" 1>&6 -echo "configure:12279: checking whether the linker supports shared libraries" >&5 +echo "configure:12389: checking whether the linker supports shared libraries" >&5 dll_ld=$CC dll_ldflags=$LDFLAGS ld_shlibs=yes @@ -12491,10 +12601,10 @@ EOF for ac_func in dlerror _dlerror do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:12495: checking for $ac_func" >&5 +echo "configure:12605: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:12631: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -12551,11 +12661,11 @@ done fi cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:12669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then : else @@ -12937,10 +13047,10 @@ for W in $ac_configure_args; do if test -z "$T"; then T="$W"; else T="$T $W"; fi ac_configure_args="$T" { test "$extra_verbose" = "yes" && cat << EOF - Defining EMACS_CONFIGURATION = "$canonical" + Defining EMACS_CONFIGURATION = "$configuration" EOF cat >> confdefs.h <> confdefs.h <<\EOF EOF } +test "$pdump" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining PDUMP +EOF +cat >> confdefs.h <<\EOF +#define PDUMP 1 +EOF +} + ( @@ -13254,15 +13372,20 @@ case "$with_menubars" in echo " *WARNING* The Motif menubar implementation is currently buggy." echo " We recommend using the Lucid menubar instead." echo " Re-run configure with --with-menubars='lucid'." ;; + msw ) echo " Using MS-Windows menubars." ;; esac case "$with_scrollbars" in lucid ) echo " Using Lucid scrollbars." ;; motif ) echo " Using Motif scrollbars." ;; athena ) echo " Using Athena scrollbars." ;; athena3d ) echo " Using Athena-3d scrollbars." ;; + msw ) echo " Using MS-Windows scrollbars." ;; esac case "$with_widgets" in motif ) echo " Using Motif native widgets." ;; + athena ) echo " Using Athena native widgets." ;; + athena3d ) echo " Using Athena-3d native widgets." ;; + msw ) echo " Using MS-Windows native widgets." ;; esac case "$with_dialogs" in motif ) @@ -13276,6 +13399,7 @@ case "$with_dialogs" in ;; athena ) echo " Using Athena dialog boxes." ;; athena3d ) echo " Using Athena-3d dialog boxes." ;; + msw ) echo " Using MS-Windows dialog boxes." ;; esac test "$with_modules" = "yes" && echo " Compiling in DSO module support." test "$with_clash_detection" = yes && \ @@ -13285,8 +13409,9 @@ test "$with_pop" = yes && echo " Using POP for mail access." test "$with_kerberos" = yes && echo " Using Kerberos for POP authentication." test "$with_hesiod" = yes && echo " Using Hesiod to get POP server host." test "$use_union_type" = yes && echo " Using the union type for Lisp_Objects." -test "$debug" = yes && echo " Compiling in extra code for debugging." -test "$usage_tracking" = yes && echo " Compiling with usage tracking active (Sun internal)." +test "$pdump" = yes && echo " Using the new portable dumper (wishful thinking)." +test "$debug" = yes && echo " Compiling in extra code for debugging." +test "$usage_tracking" = yes && echo " Compiling with usage tracking active (Sun internal)." if test "$error_check_extents $error_check_typecheck $error_check_bufpos $error_check_gc $error_check_malloc" \ != "no no no no no"; then echo " WARNING: ---------------------------------------------------------" diff --git a/configure.in b/configure.in index f285e78..9ae8f22 100644 --- a/configure.in +++ b/configure.in @@ -388,6 +388,7 @@ with_toolbars="" with_tty="" use_union_type="no" with_dnet="" +pdump="no" dnl ------------------ dnl Options Processing @@ -516,6 +517,7 @@ while test $# != 0; do const_is_losing | \ usage_tracking | \ use_union_type | \ + pdump | \ debug | \ use_assertions | \ memory_usage_stats | \ @@ -759,6 +761,8 @@ while test $# != 0; do ;; dnl Obsolete legacy argument? Warn, but otherwise ignore. + "use_minimal_tagbits" | \ + "use_indexed_lrecord_implementation" | \ "run_in_place" | \ "with_gnu_make" ) AC_MSG_WARN([Obsolete option \`--$optname' ignored.]) @@ -1030,6 +1034,7 @@ case "$canonical" in vax-*-* ) machine=vax ;; mips-dec-* ) machine=pmax ;; mips-sgi-* ) machine=iris4d ;; + mips*-linux ) machine=mips ;; romp-ibm-* ) machine=ibmrt ;; rs6000-ibm-aix* ) machine=ibmrs6000 ;; powerpc-ibm-aix* ) machine=ibmrs6000 ;; @@ -2860,6 +2865,9 @@ if test "$with_x11" = "yes"; then dnl XE_APPEND(pkg-src/tree-x, INSTALL_ARCH_DEP_SUBDIR)]) dnl fi + dnl Autodetect -lXaw3d + AC_CHECK_LIB(Xaw3d, XawScrollbarSetThumb, have_xaw3d=yes, have_xaw3d=no) + dnl autodetect Motif - but only add to libs_x later (if necessary) AC_CHECK_HEADER(Xm/Xm.h, [AC_CHECK_LIB(Xm, XmStringFree, have_motif=yes, have_motif=no)], @@ -2888,6 +2896,7 @@ case "$with_menubars" in "" | "yes" | "athena" | "athena3d" ) esac case "$with_dialogs" in "" | "yes" | "lucid" ) if test "$have_motif" = "yes"; then with_dialogs="motif" + elif test "$have_xaw3d" = "yes"; then with_dialogs="athena3d" elif test "$have_xaw" = "yes"; then with_dialogs="athena" else with_dialogs=no fi ;; @@ -2895,15 +2904,27 @@ esac case "$with_scrollbars" in "" | "yes" ) with_scrollbars="lucid" ;; esac -case "$with_widgets" in "" | "yes" ) +case "$with_widgets" in "" | "yes" | "lucid") if test "$have_motif" = "yes"; then with_widgets="motif" + elif test "$have_xaw3d" = "yes"; then with_widgets="athena3d" + elif test "$have_xaw" = "yes"; then with_widgets="athena" else with_widgets=no fi ;; esac all_widgets="$with_menubars $with_scrollbars $with_dialogs $with_toolbars $with_widgets" -case "$all_widgets" in *athena* ) +case "$all_widgets" in + *athena*3d ) + AC_DEFINE(LWLIB_USES_ATHENA) + AC_DEFINE(NEED_ATHENA) + XE_APPEND(lwlib-Xaw.o, lwlib_objs) + if test "$have_xaw3d"; then + XE_PREPEND(-lXaw3d, libs_x) + else + XE_PREPEND(-lXaw, libs_x) + fi ;; + *athena* ) AC_DEFINE(LWLIB_USES_ATHENA) AC_DEFINE(NEED_ATHENA) XE_APPEND(lwlib-Xaw.o, lwlib_objs) @@ -2920,6 +2941,11 @@ esac test "$with_menubars" = "lucid" && XE_APPEND(xlwmenu.o, lwlib_objs) test "$with_menubars" = "motif" && XE_APPEND(xlwmenu.o, lwlib_objs) test "$with_scrollbars" = "lucid" && XE_APPEND(xlwscrollbar.o, lwlib_objs) +test "$with_widgets" != "no" && test "$with_widgets" != "msw" && \ + XE_APPEND(xlwtabs.o xlwgcs.o, lwlib_objs) +case "$with_widgets" in athena* ) + XE_APPEND(xlwradio.o xlwcheckbox.o xlwgauge.o, lwlib_objs);; +esac case "$all_widgets" in *lucid* ) AC_DEFINE(NEED_LUCID) XE_APPEND(lwlib-Xlw.o, lwlib_objs) ;; @@ -2931,11 +2957,15 @@ case "$with_scrollbars" in athena* ) AC_DEFINE(LWLIB_SCROLLBARS_ATHENA);; esac case "$with_dialogs" in athena* ) AC_DEFINE(LWLIB_DIALOGS_ATHENA) ;; esac test "$with_scrollbars" = "athena3d" && AC_DEFINE(LWLIB_SCROLLBARS_ATHENA3D) test "$with_dialogs" = "athena3d" && AC_DEFINE(LWLIB_DIALOGS_ATHENA3D) +case "$with_widgets" in athena* ) AC_DEFINE(LWLIB_WIDGETS_ATHENA);; esac +test "$with_widgets" != "no" && test "$with_widgets" != "msw" && \ + AC_DEFINE(LWLIB_TABS_LUCID) test "$with_menubars" != "no" && AC_DEFINE(HAVE_MENUBARS) test "$with_scrollbars" != "no" && AC_DEFINE(HAVE_SCROLLBARS) test "$with_dialogs" != "no" && AC_DEFINE(HAVE_DIALOGS) test "$with_toolbars" != "no" && AC_DEFINE(HAVE_TOOLBARS) +test "$with_widgets" != "no" && AC_DEFINE(HAVE_WIDGETS) test "$with_menubars" = "lucid" && AC_DEFINE(LWLIB_MENUBARS_LUCID) test "$with_scrollbars" = "lucid" && AC_DEFINE(LWLIB_SCROLLBARS_LUCID) @@ -2943,6 +2973,7 @@ test "$with_scrollbars" = "lucid" && AC_DEFINE(LWLIB_SCROLLBARS_LUCID) test "$with_menubars" = "motif" && AC_DEFINE(LWLIB_MENUBARS_MOTIF) test "$with_scrollbars" = "motif" && AC_DEFINE(LWLIB_SCROLLBARS_MOTIF) test "$with_dialogs" = "motif" && AC_DEFINE(LWLIB_DIALOGS_MOTIF) +test "$with_widgets" = "motif" && AC_DEFINE(LWLIB_WIDGETS_MOTIF) test "$with_menubars" != "no" && XE_ADD_OBJS(menubar.o) test "$with_scrollbars" != "no" && XE_ADD_OBJS(scrollbar.o) @@ -3102,7 +3133,7 @@ if test "$need_motif" = "yes" ; then XE_COMPUTE_RUNPATH() fi -AC_CHECK_FUNCS(cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask snprintf strcasecmp strerror tzset ulimit usleep utimes waitpid vsnprintf) +AC_CHECK_FUNCS(cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getpt getwd logb lrand48 matherr mkdir mktime perror poll random rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask snprintf stpcpy strcasecmp strerror tzset ulimit usleep utimes waitpid vsnprintf) dnl realpath is buggy on linux, decosf and aix4 @@ -3962,7 +3993,7 @@ if test "$with_site_modules" = "no"; then fi XE_SPACE(ac_configure_args, $ac_configure_args) -AC_DEFINE_UNQUOTED(EMACS_CONFIGURATION, "$canonical") +AC_DEFINE_UNQUOTED(EMACS_CONFIGURATION, "$configuration") AC_DEFINE_UNQUOTED(EMACS_CONFIG_OPTIONS, "$ac_configure_args") AC_DEFINE_UNQUOTED(config_machfile, "$machfile") AC_DEFINE_UNQUOTED(config_opsysfile, "$opsysfile") @@ -3998,6 +4029,7 @@ test "$with_pop" = "yes" && AC_DEFINE(MAIL_USE_POP) test "$with_kerberos" = "yes" && AC_DEFINE(KERBEROS) test "$with_hesiod" = "yes" && AC_DEFINE(HESIOD) test "$use_union_type" = "yes" && AC_DEFINE(USE_UNION_TYPE) +test "$pdump" = "yes" && AC_DEFINE(PDUMP) dnl ------------------------------- dnl Report on what we decided to do @@ -4132,15 +4164,20 @@ case "$with_menubars" in echo " *WARNING* The Motif menubar implementation is currently buggy." echo " We recommend using the Lucid menubar instead." echo " Re-run configure with --with-menubars='lucid'." ;; + msw ) echo " Using MS-Windows menubars." ;; esac case "$with_scrollbars" in lucid ) echo " Using Lucid scrollbars." ;; motif ) echo " Using Motif scrollbars." ;; athena ) echo " Using Athena scrollbars." ;; athena3d ) echo " Using Athena-3d scrollbars." ;; + msw ) echo " Using MS-Windows scrollbars." ;; esac case "$with_widgets" in motif ) echo " Using Motif native widgets." ;; + athena ) echo " Using Athena native widgets." ;; + athena3d ) echo " Using Athena-3d native widgets." ;; + msw ) echo " Using MS-Windows native widgets." ;; esac case "$with_dialogs" in motif ) @@ -4154,6 +4191,7 @@ case "$with_dialogs" in ;; athena ) echo " Using Athena dialog boxes." ;; athena3d ) echo " Using Athena-3d dialog boxes." ;; + msw ) echo " Using MS-Windows dialog boxes." ;; esac test "$with_modules" = "yes" && echo " Compiling in DSO module support." test "$with_clash_detection" = yes && \ @@ -4163,8 +4201,9 @@ test "$with_pop" = yes && echo " Using POP for mail access." test "$with_kerberos" = yes && echo " Using Kerberos for POP authentication." test "$with_hesiod" = yes && echo " Using Hesiod to get POP server host." test "$use_union_type" = yes && echo " Using the union type for Lisp_Objects." -test "$debug" = yes && echo " Compiling in extra code for debugging." -test "$usage_tracking" = yes && echo " Compiling with usage tracking active (Sun internal)." +test "$pdump" = yes && echo " Using the new portable dumper (wishful thinking)." +test "$debug" = yes && echo " Compiling in extra code for debugging." +test "$usage_tracking" = yes && echo " Compiling with usage tracking active (Sun internal)." if test "$error_check_extents $error_check_typecheck $error_check_bufpos $error_check_gc $error_check_malloc" \ != "no no no no no"; then echo " WARNING: ---------------------------------------------------------" diff --git a/configure.usage b/configure.usage index dbeeb9a..6cbfcc6 100644 --- a/configure.usage +++ b/configure.usage @@ -159,6 +159,9 @@ Additional features: and localdir files in case run-time searching for them fails. --moduledir=DIR Directory to install dynamic modules in. +--pdump New, experimental, non-working, don't-sue-me-if- + your-house-collapses-and-your-wife-goes-away, + portable dumper. Internationalization options: diff --git a/etc/DISTRIB b/etc/DISTRIB index 3dd537c..abd9eb1 100644 --- a/etc/DISTRIB +++ b/etc/DISTRIB @@ -1,8 +1,8 @@ -*- text -*- - XEmacs availability information. Last Modified: 17-Apr-97. + XEmacs availability information. Last Modified: 18-Jul-99. -XEmacs is available via anonymous FTP from ftp.xemacs.org (128.174.252.16) +XEmacs is available via anonymous FTP from ftp.xemacs.org (207.96.122.8) in the directory /pub/xemacs/. ftp.xemacs.org is the primary distribution point, but you may find diff --git a/etc/NEWS b/etc/NEWS index 29238ae..0e7ab45 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -33,30 +33,6 @@ file. * Changes in XEmacs 21.2 ======================== -** The functions in rect.el have been almost completely rewritten... -to avoid inserting undesirable spaces, notably at the end of lines. -Two typical examples of this old behavior are `string-rectangle', which filled -all lines up to the right side of the rectangle, and `clear-rectangle', which -filled even empty lines up to the left side. - -This is not the case any more. All these functions have been rewritten to -avoid inserting unwanted spaces, and an optional prefix now allows them to -behave the old way. - -As a side effect, `move-to-column' now also accepts 'coerce as its second -argument, meaning that the line shouldn't be filled if its too short to reach -the desired column. - -** You can now customize and save comments for faces and variables. - -In Custom buffers, a new menu entry allows you to add and edit a comment. -Comments for variables can also be assigned by calling -`customize-set-(value|variable)' with a prefix argument. - -** XEmacs now locates the early package hierarchy at ~/.xemacs/packages. - -This has changed from simply ~/.xemacs. - ** `delete-key-deletes-forward' now defaults to t. `delete-key-deletes-forward' is the variable that regulates the @@ -83,6 +59,33 @@ The new behavior affects all functions performing interactive searches, like `zap-to-char', `list-matching-lines', `tags-search' etc. The incremental search facility has always behaved that way. +** The rectangle functions have been almost completely rewritten in +order to avoid inserting undesirable spaces, notably at the end of +lines. Two typical examples of the old behavior were +`string-rectangle', which filled all lines up to the right side of the +rectangle, and `clear-rectangle', which filled even empty lines up to +the left side. All functions have been rewritten to avoid inserting +unwanted spaces, and an optional prefix now allows them to behave the +old way. + +As a side effect, the FORCE argument to `move-to-column' now +understands the special value `coerce', which means that the line +should not be filled if it is too short to reach the desired column. + +** Incremental search will now highlight all visible matches, making +it easier to anticipate where consecutive C-s or C-r will place the +point. If you want to disable the feature, set +`isearch-highlight-all-matches' to nil. + +** You can now customize and save comments for faces and variables. +In Custom buffers, a new menu entry allows you to add and edit a +comment. Comments for variables can also be assigned by calling +`customize-set-(value|variable)' with a prefix argument. + +** XEmacs now locates the early package hierarchies at +~/.xemacs/mule-packages/ and ~/.xemacs/xemacs-packages/. Previously, +the early packages were located in ~/.xemacs/. + ** You can now create "indirect buffers", like in GNU Emacs. An indirect buffer shares its text with another buffer ("base buffer"), but has its own major mode, local variables, extents, and narrowing. @@ -115,20 +118,19 @@ The new primitives available for this purpose are functions named ** Native widgets can be displayed in buffers. The glyph system has been extended to allow the display of glyphs that -are implemented as native window-system widgets. Thus you can embed +are implemented as native window-system widgets. Thus you can embed buttons, scrollbars, combo boxes, edit fields and progress gauges in a -buffer. As a side effect subwindow support now works once again. +buffer. As a side effect subwindow support now works once again. This support is currently only available under MS-Windows. -** X-Face support is now available under MS-Windows - +** X-Face support is now available under MS-Windows. If an X-Face libary built under MS-Windows is available then XEmacs will use this at build time. -** The font-menu is now available under MS-Windows +** The font-menu is now available under MS-Windows. -** MS-Windows support for selection is much more robust +** MS-Windows support for selection is now much more robust. Generally selection should now do what you would expect under MS-Windows: the middle mouse button will paste your current selection @@ -137,9 +139,17 @@ clipboard can be made; the kill-ring and friends will be updated as per X. The only thing selection doesn't do is set the clipboard automatically -as this would break the MS-Windows model. If you want this behaviour +as this would break the MS-Windows model. If you want this behaviour then set `selection-sets-clipboard' to t +** New command-line switches -user-init-file and -user-init-directory. +These can be used to specify alternate locations for what is normally +~/.emacs and ~/.xemacs. + +Moreover, -user (which used to only work in unpredictable ways) +is now equivalent to +-user-init-file ~/.emacs -user-init-directory ~/.xemacs. + * Lisp and internal changes in XEmacs 21.2 ========================================== @@ -270,6 +280,13 @@ to check whether a specific symbol is interned in an obarray, e.g.: `base64-encode-region', `base64-encode-string', `base64-decode-region' and `base64-decode-string'. +** user-init-directory is now an absolute, unexpanded path. +Previously, `user-init-directory' used to be relative to +(concat "~" init-file-user). This turned out to be too complicated +for most packages (and some core Lisp files) to use correctly. + +Also, `init-file-user' has been obsoleted in the process. + * Changes in XEmacs 21.0 ======================== @@ -752,7 +769,7 @@ directory hierarchy has been rewritten to support the package system. Look under "Startup Paths" in the Info documentation for more information. -*** site-lisp is now longer part of the load-path by default. +*** site-lisp is no longer part of the load-path by default. Its use is deprecated, but you can specify --with-site-lisp=yes at the configure command line to get it back. diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index b466a85..a969b0c 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,44 @@ +1999-11-10 XEmacs Build Bot + + * XEmacs 21.2.20 is released + +1999-11-04 Martin Buchholz + + * gnuserv.c (handle_response): Warning suppression + +1999-09-27 Martin Buchholz + + * ellcc.c: + ANSIfy. + Remove MSDOS cruft. + Remove WINDOWS cruft. + Remove VMS cruft. + (main): The wrong number of bytes were being read during argument + processing. + Delete ANSI imitations like ellcc_strchr(). + Call functions with the right number of arguments. + Fix a typo. + Make functions static. + Remove compiler warnings. + +1999-09-22 Martin Buchholz + + * cvtmail.c (main): ANSIfy + * digest-doc.c (main): ANSIfy + * hexl.c (main): ANSIfy + + * make-path.c: Remove declaration for errno. + * mmencode.c (nextcharin): ANSIfy + * movemail.c (pop_retr): ANSIfy + +1999-07-30 Gleb Arshinov + + * pop.c (pop_quit): use CLOSESOCKET() instead of close() + + * run.c (build_cmdline): Fix NT native build unreferenced variable + warning + (WinMain): Fix release mode build unreferenced variable warning + 1999-07-30 XEmacs Build Bot * XEmacs 21.2.19 is released diff --git a/lib-src/cvtmail.c b/lib-src/cvtmail.c index 962ec3a..768bcee 100644 --- a/lib-src/cvtmail.c +++ b/lib-src/cvtmail.c @@ -53,9 +53,7 @@ static void fatal (CONST char *s1, CONST char *s2); static void error (CONST char *s1, CONST char *s2); int -main (argc, argv) - int argc; - char *argv[]; +main (int argc, char *argv[]) { char *hd; char *md; diff --git a/lib-src/digest-doc.c b/lib-src/digest-doc.c index b4f7ca2..a39ddc6 100644 --- a/lib-src/digest-doc.c +++ b/lib-src/digest-doc.c @@ -11,7 +11,7 @@ #include int -main () +main (int argc, char *argv[]) { register int ch; register int notfirst = 0; diff --git a/lib-src/ellcc.c b/lib-src/ellcc.c index acc3abe..a116c9d 100644 --- a/lib-src/ellcc.c +++ b/lib-src/ellcc.c @@ -24,8 +24,8 @@ Please mail bugs and suggestions to the XEmacs maintainer. /* Here's the scoop. We would really like this to be a shell script, but -the various Windows platforms dont have reliable scripting that suits -our needs. We dont want to reply on perl or some other such language +the various Windows platforms don't have reliable scripting that suits +our needs. We don't want to rely on perl or some other such language so we have to roll our own executable to act as a front-end for the compiler. @@ -58,87 +58,30 @@ the lines of: See the samples for more details. */ +#include <../src/config.h> #include #include - -#ifdef MSDOS -# include -# include -# include -# ifndef HAVE_CONFIG_H -# define DOS_NT -# include -# endif -#endif /* MSDOS */ - -#ifdef WINDOWSNT -# include -# include -# include -# include -# define MAXPATHLEN _MAX_PATH -# ifdef HAVE_CONFIG_H -# undef HAVE_NTGUI -# else -# define DOS_NT -# define HAVE_GETCWD -# endif /* not HAVE_CONFIG_H */ -#endif /* WINDOWSNT */ - -#ifdef HAVE_CONFIG_H -# include - /* On some systems, Emacs defines static as nothing for the sake - of unexec. We don't want that here since we don't use unexec. */ -# undef static -#endif /* HAVE_CONFIG_H */ - -#if !defined (WINDOWSNT) && defined (STDC_HEADERS) -#include #include -#endif +#include +#include +#include #ifdef HAVE_UNISTD_H # include -#else -# ifdef HAVE_GETCWD - extern char *getcwd (); -# endif #endif /* HAVE_UNISTD_H */ -#include -#include -#include -#ifndef errno - extern int errno; -#endif -#include -#include - #define EMODULES_GATHER_VERSION #include "emodules.h" #include "ellcc.h" -#if !defined (S_ISREG) && defined (S_IFREG) -# define S_ISREG(m) (((m) & S_IFMT) == S_IFREG) -#endif - -/* Exit codes for success and failure. */ -#ifdef VMS -# define GOOD 1 -# define BAD 0 -#else -# define GOOD 0 -# define BAD 1 -#endif - #define DEBUG #ifndef HAVE_SHLIB int -main() +main (int argc, char *argv[]) { fprintf (stderr, "Dynamic modules not supported on this platform\n"); - return (BAD); + return EXIT_FAILURE; } #else @@ -163,11 +106,12 @@ main() # define xnew(n,Type) ((Type *) xmalloc ((n) * sizeof (Type))) # define xrnew(op,n,Type) ((Type *) xrealloc ((op), (n) * sizeof (Type))) #endif -long *xmalloc (), *xrealloc (); -void fatal (), pfatal (); -char *ellcc_strchr (), *ellcc_strrchr (); -void add_to_argv (); -void do_compile_mode(), do_link_mode(), do_init_mode(); +static void *xmalloc (size_t); +static void fatal (char *, char *); +static void add_to_argv (CONST char *); +static void do_compile_mode (void); +static void do_link_mode (void); +static void do_init_mode (void); #define SSTR(S) ((S)?(S):"") @@ -196,9 +140,7 @@ char *ellcc, *ellld, *ellcflags, *ellldflags, *ellpicflags, *elldllflags; STR = DFLT int -main (argc, argv) - int argc; - char *argv[]; +main (int argc, char *argv[]) { char *tmp; int i, done_mode = 0; @@ -207,11 +149,11 @@ main (argc, argv) prog_argv = argv; #if defined(MSDOS) || defined(WINDOWSNT) - tmp = ellcc_strrchr (argv[0], '\\'); + tmp = strrchr (argv[0], '\\'); if (tmp != (char *)0) tmp++; #elif !defined (VMS) - tmp = ellcc_strrchr (argv[0], '/'); + tmp = strrchr (argv[0], '/'); if (tmp != (char *)0) tmp++; #else @@ -248,7 +190,7 @@ main (argc, argv) char *modeopt = argv[i] + 7; if (done_mode && strcmp (modeopt, "verbose")) - fatal ("more than one mode specified"); + fatal ("more than one mode specified", (char *) 0); if (strcmp (modeopt, "link") == 0) { done_mode++; @@ -287,13 +229,13 @@ main (argc, argv) printf ("%s\n", ELLCC_CONFIG); return 0; } - else if (strncmp (argv[i], "--mod-name=", 10) == 0) + else if (strncmp (argv[i], "--mod-name=", 11) == 0) mod_name = argv[i] + 11; - else if (strncmp (argv[i], "--mod-title=", 11) == 0) + else if (strncmp (argv[i], "--mod-title=", 12) == 0) mod_title = argv[i] + 12; - else if (strncmp (argv[i], "--mod-version=", 13) == 0) + else if (strncmp (argv[i], "--mod-version=", 14) == 0) mod_version = argv[i] + 14; - else if (strncmp (argv[i], "--mod-output=", 12) == 0) + else if (strncmp (argv[i], "--mod-output=", 13) == 0) mod_output = argv[i] + 13; else { @@ -339,7 +281,7 @@ main (argc, argv) #endif if (exec_argc < 2) - fatal ("too few arguments"); + fatal ("too few arguments", (char *) 0); /* * Get the over-rides from the environment @@ -378,83 +320,23 @@ main (argc, argv) } /* Like malloc but get fatal error if memory is exhausted. */ -long * -xmalloc (size) - unsigned int size; +static void * +xmalloc (size_t size) { - long *result = (long *) malloc (size); + void *result = malloc (size); if (result == NULL) - fatal ("virtual memory exhausted", (char *)NULL); - return result; -} - -long * -xrealloc (ptr, size) - char *ptr; - unsigned int size; -{ - long *result = (long *) realloc (ptr, size); - if (result == NULL) - fatal ("virtual memory exhausted", (char *)NULL); + fatal ("virtual memory exhausted", (char *)0); return result; } /* Print error message and exit. */ -void -fatal (s1, s2) - char *s1, *s2; +static void +fatal (char *s1, char *s2) { fprintf (stderr, "%s: ", progname); fprintf (stderr, s1, s2); fprintf (stderr, "\n"); - exit (BAD); -} - -void -pfatal (s1) - char *s1; -{ - perror (s1); - exit (BAD); -} - -/* - * Return the ptr in sp at which the character c last - * appears; NULL if not found - * - * Identical to System V strrchr, included for portability. - */ -char * -ellcc_strrchr (sp, c) - register char *sp, c; -{ - register char *r; - - r = NULL; - do - { - if (*sp == c) - r = sp; - } while (*sp++); - return r; -} - -/* - * Return the ptr in sp at which the character c first - * appears; NULL if not found - * - * Identical to System V strchr, included for portability. - */ -char * -ellcc_strchr (sp, c) - register char *sp, c; -{ - do - { - if (*sp == c) - return sp; - } while (*sp++); - return NULL; + exit (EXIT_FAILURE); } /* @@ -462,9 +344,8 @@ ellcc_strchr (sp, c) * to the compiler or linker. We need to split individual words into * arguments, taking quoting into account. This can get ugly. */ -void -add_to_argv (str) - CONST char *str; +static void +add_to_argv (CONST char *str) { int sm = 0; CONST char *s = (CONST char *)0; @@ -557,8 +438,8 @@ add_to_argv (str) * is build up the argument vector and exec() it. We must just make sure * that we get all of the required arguments in place. */ -void -do_compile_mode() +static void +do_compile_mode (void) { int i; char ts[4096]; /* Plenty big enough */ @@ -587,8 +468,8 @@ do_compile_mode() * all of the provided arguments, then the final post arguments. Once * all of this has been done, the argument vector is ready to run. */ -void -do_link_mode() +static void +do_link_mode (void) { int i,x; char *t, ts[4096]; /* Plenty big enough */ @@ -648,8 +529,8 @@ do_link_mode() * the header information first, as make-doc will append to the file by * special dispensation. */ -void -do_init_mode() +static void +do_init_mode (void) { int i; char ts[4096]; /* Plenty big enough */ diff --git a/lib-src/gnuserv.c b/lib-src/gnuserv.c index ddce69c..8400550 100644 --- a/lib-src/gnuserv.c +++ b/lib-src/gnuserv.c @@ -323,7 +323,7 @@ handle_response (void) char buf[GSERV_BUFSZ+1]; int offset=0; int s; - int len; + int len = 0; int result_len; /* read in "n/m:" (n=client fd, m=message length) */ diff --git a/lib-src/hexl.c b/lib-src/hexl.c index 58855a0..0a88b00 100644 --- a/lib-src/hexl.c +++ b/lib-src/hexl.c @@ -29,9 +29,7 @@ char *progname; void usage (void); int -main(argc, argv) - int argc; - char *argv[]; +main (int argc, char *argv[]) { register long address; char string[18]; diff --git a/lib-src/make-path.c b/lib-src/make-path.c index b3de190..a8093e8 100644 --- a/lib-src/make-path.c +++ b/lib-src/make-path.c @@ -35,8 +35,6 @@ Boston, MA 02111-1307, USA. */ #include #include -extern int errno; - char *prog_name; static int touchy_mkdir (char *path) diff --git a/lib-src/mmencode.c b/lib-src/mmencode.c index 8ba79d4..3609a5e 100644 --- a/lib-src/mmencode.c +++ b/lib-src/mmencode.c @@ -52,9 +52,7 @@ char c; static int InNewline=0; static int -nextcharin(infile, PortableNewlines) -FILE *infile; -int PortableNewlines; +nextcharin (FILE *infile, int PortableNewlines) { int c; diff --git a/lib-src/movemail.c b/lib-src/movemail.c index 19793a3..9a1a3c6 100644 --- a/lib-src/movemail.c +++ b/lib-src/movemail.c @@ -150,7 +150,8 @@ static char *concat (char *, char *, char *); static long *xmalloc (unsigned int); #ifdef MAIL_USE_POP static int popmail (char *, char *, char *); -static int pop_retr (popserver server, int msgno, int (*action)(), void *arg); +static int pop_retr (popserver server, int msgno, + int (*action)(char *, FILE *), void *arg); static int mbx_write (char *, FILE *); static int mbx_delimit_begin (FILE *); static int mbx_delimit_end (FILE *); @@ -730,7 +731,7 @@ popmail (char *user, char *outfile, char *password) } static int -pop_retr (popserver server, int msgno, int (*action)(), void *arg) +pop_retr (popserver server, int msgno, int (*action)(char *, FILE *), void *arg) { char *line; int ret; diff --git a/lib-src/pop.c b/lib-src/pop.c index bbec8ab..c50fc14 100644 --- a/lib-src/pop.c +++ b/lib-src/pop.c @@ -922,7 +922,7 @@ pop_quit (popserver server) ret = -1; } - close (server->file); + CLOSESOCKET (server->file); } if (server->buffer) diff --git a/lib-src/run.c b/lib-src/run.c index 86830ba..b808c4a 100644 --- a/lib-src/run.c +++ b/lib-src/run.c @@ -65,10 +65,14 @@ WinMain (HINSTANCE hSelf, HINSTANCE hPrev, LPSTR cmdline, int nShow) char execpath[MAX_PATH]; char* argv[MAX_ARGS+1]; /* leave extra slot for compact_invocation argv[0] */ int argc; - int i,j; + int i; char exec[MAX_PATH + FILENAME_MAX + 100]; char cmdline2[MAX_ARGS * MAX_PATH]; +#ifdef Debug + int j; +#endif + compact_invocation = get_exec_name_and_path(execname,execpath); if (compact_invocation) @@ -157,7 +161,9 @@ void xemacs_special(char* exec) char* p; char* p2; char exec2[MAX_PATH + FILENAME_MAX + 100]; +#if defined(__CYGWIN__) char tmp[MAX_PATH + FILENAME_MAX + 100]; +#endif strcpy(exec2,exec); /* this depends on short-circuit evaluation */ if ( ((p = strrchr(exec2,'\\')) && stricmp(p,"\\xemacs") == 0) || diff --git a/lisp/.cvsignore b/lisp/.cvsignore index a7ad904..c7d7e3f 100644 --- a/lisp/.cvsignore +++ b/lisp/.cvsignore @@ -1 +1,2 @@ +ChangeLog.font-menu finder-inf.el diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ba80ffb..554ed02 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -19,6 +19,571 @@ * files.el (insert-file-contents-literally): Treat file as binary; call file-name-handlers. [sync with Emacs 20.3.10] +1999-11-10 XEmacs Build Bot + + * XEmacs 21.2.20 is released + +1999-11-06 Hrvoje Niksic + + * setup-paths.el (paths-default-info-directories): Add + /usr/share/info and /usr/local/share/info. + +1999-10-30 Hrvoje Niksic + + * about.el: Updated Vladimir Ivanovic's info. + +11999-08-28 Jan Vroonhof + + * auto-show.el (auto-show-truncationp): Remove. + + * auto-show.el (auto-show-should-take-action-p): Use window-truncated-p + +999-09-23 Gunnar Evermann + + * indent.el (indent-line-to): fix bug: spaces were not replaced + with tab if column is multiple of tab-width + From dhn@qedinc.com + +1999-10-24 Jan Vroonhof + + * mule/mule-cmds.el (read-input-method-name): Accept symbols + correctly. Patch from Mikio Nakajima + + * package-get.el (package-get-package-provider): Be verbose when + interactive. Patch from Robert Pluim + +1999-08-23 Mike McEwan + + * info.el (Info-suffix-list): Add ".info.bz2" to the recognised + info file suffixes. + +1999-08-19 Stephen Tse + + * process.el (open-network-stream): Add a new optional parameter + PROTOCOL to support udp; fix a minor typo and add an explanation + in docstring for udp programming. + + * code-process.el (open-network-stream): Add a new optional + parameter PROTOCOL to support udp; fix a minor typo and add an + explanation in docstring for udp programming. + +1999-10-18 Andy Piper + + * gui.el (make-gui-button): be more precise about how we call + callbacks. + + * wid-edit.el (widget-push-button-value-create): Use the new form + of native gui-button. + +1999-10-14 Yoshiki Hayashi + + * info.el (Info-page-prev): Don't do (sit-for 0). + +1999-10-13 Andy Piper + + * gutter-items.el (progress-abort-glyph): new glyph for showing + abort status. + (append-progress): dispatch-event rather than sit-for. + (abort-progress): new function. Show the abort glyph with an + appropriate message. + (raw-append-progress): dispatch-event rather than sit-for. + (display-progress): cope with aborts. + + * gui.el (make-gui-button): Use native widgets for buttons + unconditionally. + (insert-gui-button): ditto. + (gui-button-p): ditto. + + * xbm-button.el: remove from core. + + * xpm-button.el: remove from core. + +1999-10-07 Olivier Galibert + + * faces.el (init-device-faces): Don't initialize the random faces + on the stream device. + +1999-10-06 Andy Piper + + * files.el (recover-file): Don't use ls under windows for revert buffer. + +1999-09-25 Adrian Aichner + + * package-get.el (package-get-download-menu): Make menu really + toggle download sites. + (package-get-download-sites): Add autoload cookie. + +1999-09-29 Michael Sperber [Mr. Preprocessor] + + * setup-paths.el (paths-find-module-directory): Ditto. + +1999-09-29 Werner Fink + + * setup-paths.el (paths-find-exec-directory): Add missing nil + parameter for environment. + +1999-09-27 Martin Buchholz + + * modeline.el (modeline-format): + Only purecopy the strings. Else + (nsublis '(("%p" . "%P")) (default-value 'modeline-format) :test 'equal) + barfs. + +1999-08-28 Mike Woolley + + * winnt.el: Removed nt-shell-mode-hook, which was preventing the + user setting comint-completion-addsuffix and + comint-process-echoes. + +1999-09-22 Andy Piper + + * gutter-items.el (update-tab-in-gutter): use + last-nonminibuf-window instead of selected-window. + +1999-09-18 Andy Piper + + * gnuserv.el (gnuserv-edit-files): select frame we are going to + display on. + + * subr.el (record-buffer-hook): new variable so that the hook gets + some documentation. + +1999-09-16 Andy Piper + + * gutter-items.el (update-tab-in-gutter): only update when the + gutter is visible. + (remove-buffer-from-gutter-tab): ditto. + +1999-09-17 Hrvoje Niksic + + * simple.el (do-auto-fill): Commented out part of Kinsoku + processing. + +1999-09-14 Hrvoje Niksic + + * isearch-mode.el (isearch-highlightify-region): Give the + highlighting extents a high priority. + (isearch-make-extent): Give the main highlighting extent an even + higher priority. + +1999-09-13 Michael Sperber [Mr. Preprocessor] + + * packages.el (packages-compute-package-locations): Fix typo from + -u rationalization. + +1999-09-11 Michael Sperber [Mr. Preprocessor] + + * setup-paths.el (paths-find-doc-directory): Respect value of + `configure-doc-directory.' + + * find-paths.el (paths-find-architecture-directory): Give + precendence `default' argument (which typically comes from + configure). + +1999-09-05 Michael Sperber [Mr. Preprocessor] + + * startup.el (command-line-early): Added options -user-init-file + and -user-init-directory. + + * files.el (user-init-file): Default to NIL so we can recognize + when it's set. + +1999-08-30 Michael Sperber [Mr. Preprocessor] + + * obsolete.el (init-file-user): + * startup.el: + * packages.el (packages-compute-package-locations): + * package-get.el (package-get-user-index-filename): + * menubar-items.el (maybe-add-init-button): + * info.el (Info-annotations-path): + * dump-paths.el: + Change `user-init-directory' to be an absolute path. + Use `user-init-directory' where appropriate. + Zap `init-file-user' and its uses. + +1999-09-09 Hrvoje Niksic + + * subr.el (copy-symbol): New function. + +1999-09-08 Hrvoje Niksic + + * isearch-mode.el (isearch-done): Be sure to restore invisible + extents in the proper buffer. + (isearch-pre-command-hook): Set this-command to the correct value + in case the buffer has changed and old overriding-local-map was + used. + (isearch-restore-extent): Use remprop instead of setting the + property to nil. + +1999-09-08 Hrvoje Niksic + + * cmdloop.el (execute-extended-command): Update zmacs region + before the delay. + (execute-extended-command): Make the message gettext-friendly. + +1999-09-07 Andy Piper + + * gutter-items.el (progress-gauge-glyph): renamed from + progress-glyph. + (progress-text-glyph): new variable. + (progress-layout-glyph): use layouts and text glyphs. + (progress-area-buffer): removed. + (progress-text-and-extent): new variable. + (progress-displayed-p): dynamically create gutter area buffer. + (clear-progress): ditto. + (raw-append-progress): ditto. + (append-progress): use new glyph names. + (raw-append-progress): only create the extent when needed. set + properties more optimally. + (progress): remove args. + +1999-09-07 Hrvoje Niksic + + * isearch-mode.el (isearch-range-invisible): Use mapc instead of + mapcar where the return value is unused. + (isearch-restore-invisible-extents): Ditto. + (isearch-highlight-all-cleanup): Ditto. + (isearch-delete-extents-in-range): Traverse the extents only once. + (isearch-highlight-all-update): Don't start over if the search + string has changed and more input is pending. + +1999-09-07 Hrvoje Niksic + + * packages.el (packages-find-package-data-path): Ditto. + + * cl.el: Use mapcar at top-level -- mapc is no longer a subr. + + * subr.el (mapc-internal): Don't make obsolete. + + * cl-extra.el (mapc): Resurrect. + +1999-09-03 Hrvoje Niksic + + * obsolete.el (isearch-yank-x-clipboard): Define it as an obsolete + alias. + + * isearch-mode.el (isearch-top-state): Restore isearch-word. + (isearch-yank-clipboard): Renamed from isearch-yank-x-clipboard. + (isearch-yank-clipboard): Use get-clipboard instead of + x-get-clipboard. + (isearch-yank-selection): Fix docstring. + +1999-09-02 Martin Buchholz + + * cl-extra.el: Obsolete hash-table-type in favor of hash-table-weakness. + +1999-09-02 Hrvoje Niksic + + * cl-macs.el (extent-start-position): Fix setf method. + (extent-end-position): Ditto. + +1999-09-02 Hrvoje Niksic + + * isearch-mode.el: End merge with FSF 20.4. + + * isearch-mode.el (search-invisible): New variable. + (isearch-hide-immediately): Ditto. + (isearch-unhidden-extents): Ditto. + (isearch-range-invisible): New function. + (isearch-unhide-extent): Ditto. + (isearch-restore-invisible-extents): Ditto. + (isearch-restore-extent): Ditto. + + * isearch-mode.el (isearch-ring-advance-edit): Use FSF + implementation. + (isearch-ring-retreat-edit): Ditto. + (isearch-forward): New argument NO-RECURSIVE-EDIT. + (isearch-forward-regexp): New arguments NOT-REGEXP and + NO-RECURSIVE-EDIT. + (isearch-backward): New argument NO-RECURSIVE-EDIT. + (isearch-backward-regexp): New arguments NOT-REGEXP and + NO-RECURSIVE-EDIT. + (isearch-mode): Return isearch-success. + (isearch-update): Use unread-command-events instead of + unread-command-event. + (isearch-abort): If an invalid regexp is encountered, keep popping + states. + (isearch-*-char): Use FSF implementation. + (isearch-whitespace-chars): Use the more robust FSF's + implementation. + (isearch-within-brackets): New variable. + (isearch-mode): Initialize it. + (isearch-edit-string): Bind it. + (isearch-search-and-update): Set it. + (isearch-push-state): Push it. + (isearch-top-state): Pop it. + (isearch-search): Set it. + (isearch-printing-char): When called by isearch-whitespace-chars, + handle M-SPC gracefully. + (isearch-message-prefix): New argument ELLIPSIS. + (isearch-message-suffix): Ditto. + (isearch-message): Use the ELLIPSIS argument when calling + isearch-message-prefix and isearch-message-suffix. + (isearch-message-prefix): Distinguish between "wrapped" and + "overwrapped" search, FWIW. + +1999-09-01 Hrvoje Niksic + + * isearch-mode.el (isearch-edit-string): Use the head of the + search ring instead of search-last-string and search-last-regexp. + (search-highlight): Renamed from isearch-highlight. + (isearch-exit): Use the new name. + (isearch-highlight): Ditto. + (isearch-dehighlight): Ditto. + (isearch-update-ring): New function. + (isearch-done): Call it. + (isearch-done): New argument EDIT. + (isearch-repeat): If search string is empty, look up at the car of + the search ring; ignore the yank pointer. + (isearch-abort): Call isearch-done with NOPUSH. + (isearch-cancel): New function. + (isearch-mode-map): Bind it to ESC ESC ESC. + + * isearch-mode.el: Begin merge with FSF 20.4. + +1999-09-01 Andy Piper + + * x-select.el (x-get-clipboard): obsolete. + (x-yank-clipboard-selection): obsolete + + * select.el (disown-selection): need to be careful to disown the + clipboard if we set it via selection. + (get-clipboard): move from x-select.el + (yank-clipboard-selection): ditto. + +1999-09-01 Hrvoje Niksic + + * isearch-mode.el (isearch-exit): Bind isearch-highlight and + isearch-highlight-all-matches to nil. + (isearch-fixed-case): New variable. + (isearch-mode): Initialize it. + (isearch-edit-string): Save it. + (isearch-toggle-case-fold): Set it. + (isearch-fix-case): Make sure isearch-toggle-case-fold works -- + need to check isearch-fixed-case. + (isearch-toggle-case-fold): Update highlighting of all matches + before the pause. + (isearch-edit-string): + +1999-09-01 Hrvoje Niksic + + * isearch-mode.el (isearch-edit-string): Call isearch-message + before reading the event so that the prompt is displayed properly. + (isearch-message): Use isearch-nonincremental when calling + isearch-message-prefix. + (minibuffer-local-isearch-map): Bind up and down to do the same as + M-p and M-n respectively. + (isearch-done): New arg NOPUSH. + (isearch-edit-string): Use it. + (isearch-edit-string): Don't bind isearch-string. + (isearch-ring-adjust): Edit string, *then* push state. + +1999-08-31 Hrvoje Niksic + + * faces.el (isearch-secondary): Make isearch-secondary look + different than default. + +1999-08-30 Hrvoje Niksic + + * isearch-mode.el (isearch-yank): Use progn instead of the inner + save-excursion. + (isearch-dehighlight): Remove TOTALLY. Simplify. + (isearch-update): Call isearch-dehighlight without arguments. + (isearch-done): Ditto. + + * isearch-mode.el (isearch-fix-case): If the search string has no + upper-case letters, allow the folding to be reenabled. + Previously, once disabled, the folding would remain that way until + the end of isearch. + (isearch-top-state): Call isearch-fix-case. + + * isearch-mode.el (isearch-yank): Use progn instead of the inner + save-excursion. + (isearch-dehighlight): Remove TOTALLY. Simplify. + +1999-08-31 Jan Vroonhof + + * xpm-button.el: + xbm-button.el: Need to exist in core because gui.el depends on + them. + +1999-08-31 Andy Piper + + * gutter-items.el (buffers-tab-face): new customizable variable. + (buffers-tab-default-buffer-line-length): new specifier for + maximum viewable characters. + (progress-stack): new variable for implementing widget-based + progress messages. + (progress-area-buffer): ditto. + (progress-glyph-height): ditto. + (progress-stop-callback): ditto. + (progress-quit-function): new function. + (progress-glyph): new variable. + (progress-layout-glyph): ditto. + (progress-displayed-p): new function, see message-displayed-p for + details. + (clear-progress): ditto. + (remove-progress): ditto. + (append-progress): ditto. + (raw-append-progress): ditto. + (display-progress): ditto. + (current-progress): ditto. + (current-progress-label): ditto. + (progress): ditto. + (lprogress): ditto. + + +1999-08-29 Hrvoje Niksic + + * obsolete.el (isearch-yank-x-selection): Define obsolete alias. + + * isearch-mode.el (isearch-yank-x-selection): Renamed to + `isearch-yank-selection'. + (isearch-mode-map): Use it. + (isearch-yank-selection): Use `get-selection' instead of + `get-x-selection'. + +1999-08-29 Hrvoje Niksic + + * faces.el (isearch-secondary): Create face here. + + * isearch-mode.el: Rewrote the "lazy highlighting" code not to use + timers. + +1999-08-27 Hrvoje Niksic + + * subr.el (buffer-string): More robust backward compatibility + check, courtesy William Perry. + +1999-08-26 Hrvoje Niksic + + * replace.el (perform-replace): Stop the search after the search + limit has been reached. + +1999-08-23 Andy Piper + + * gutter-items.el (update-tab-in-gutter): call add-tab-to-gutter + here if we don't have one. + +1999-08-15 Oscar Figueiredo + + * ldap.el (ldap-coding-system): Default to nil until we get + efficient UTF8 support + (ldap-decode-string): Guard against `decode-coding-string' not + being defined + (ldap-encode-string): Guard against `encode-coding-string' not + being defined + +1999-08-23 Didier Verna + + * rect.el: Cosmetics suggested by Dave Love . + Some doc strings improvements, and add a star to the `interactive' + calls. + +1999-08-18 Stef Epardaud + + * font-lock.el (java-font-lock-keywords-3): introduced new + keywords and regexpes for javadoc syntax 1.2. + +1999-08-17 Andy Piper + + * gutter-items.el (buffers-tab-format-buffer-line-function): use + format-buffers-tab-line. + (buffers-tab-max-buffer-line-length): new variable. + (format-buffers-tab-line): new function. truncate names if over + buffers-tab-max-buffer-line-length. + +1999-08-13 Charles G Waldman + + * cus-start.el: Customize the variable `bell-inhibit-time'. + +1999-08-16 Andy Piper + + * gutter-items.el (remove-buffer-from-gutter-tab): take a + brute-force approach to deleting the last buffer. + (buffers-tab-grouping-regexp): new customizable variable. + (select-buffers-tab-buffers-by-mode): use it. + +1999-08-13 Andy Piper + + * gutter-items.el (remove-buffer-from-gutter-tab): fix *scratch* + deletion problem. + +1999-07-30 Didier Verna + + * cus-edit.el (custom-save-variables): I said, use prin1 instead + of princ to output symbols. + (custom-save-face-internal): ditto. + (custom-save-resets): ditto. + +1999-08-09 Didier Verna + + * gutter-items.el (select-buffers-tab-buffers-by-mode): use + `regexp-quote' to protect the major mode name for use as a regular + expression (c++ needs this for instance). + +1999-08-08 Andy Piper + + * gutter-items.el (select-buffers-tab-buffers-by-mode): beef up to + cope with similar mode names. + + * gutter-items.el (buffers-tab-selection-function): new selection + function. + (select-buffers-tab-buffers-by-mode): new function. + (buffers-tab-items): use it if set to only display buffers in the + tab in the current buffer's group.. + (update-tab-in-gutter): use new api. + (remove-buffer-from-gutter-tab): ditto. + + * gutter-items.el (buffers-tab-max-size): set custom selection + default to 6. + (buffers-tab-switch-to-buffer): just switch window if the window is visible. + (add-tab-to-gutter): set face as default. + +1999-07-07 Jan Vroonhof + + * faces.el (frob-face-property): Merge the fall-back specifier + with the target, not replace it. + +1999-08-05 Andy Piper + + * gutter-items.el (update-tab-in-gutter): add frame argument for + buffer-items. + (update-tab-in-gutter): use it. + + * gutter-items.el (record-buffer-hook): set. + + * buffer.el (switch-to-buffer): back out switch-to-buffer-hook + change. + (switch-to-buffer-hook) deleted. + +1999-08-04 Andy Piper + + * gutter-items.el (update-tab-in-gutter): make sure this will work + as an argument to create-frame-hook. + +1999-07-30 Hrvoje Niksic + + * isearch-mode.el: Modified Bob and Darryl's code to use itimers + instead of timer emulation. + +1999-07-30 Darryl Okahata + + * isearch-mode.el: Merged Bob Glickstein's GNU + Emacs isearch enhancements. + +1999-07-28 Andy Piper + + * gutter-items.el (add-tab-to-gutter): put in specifier specs for + all devices that support tab controls. + (remove-buffer-from-gutter-tab): new function. to be used as a + value for kill-buffer-hook. + +1999-07-21 Sean MacLennan + + * auto-show.el (auto-show-truncationp): changed to match + `window_translation_on' + 1999-07-30 XEmacs Build Bot * XEmacs 21.2.19 is released @@ -48,8 +613,8 @@ 1999-07-23 Jan Vroonhof - * custom.el: - * cus-face.el: + * custom.el: + * cus-face.el: * cus-edit.el: Massive custom Theme API changes. @@ -81,7 +646,7 @@ 1999-06-25 Karl M. Hegbloom - * files.el (interpreter-mode-alist): add `make', `guile', and + * files.el (interpreter-mode-alist): add `make', `guile', and `emacs' entries. (#!/usr/bin/make -f ought to send a file into makefile-mode, guile is a scheme, and someday XEmacs will be modular enough to use as an efficient scripting tool.) @@ -265,7 +830,7 @@ * mule/mule-cmds.el (set-language-info): Don't set up menus at all. (set-language-info-alist): Set up menus here. - + 1999-06-28 MORIOKA Tomohiko * minibuf.el (completing-read): Add new optional argument diff --git a/lisp/auto-show.el b/lisp/auto-show.el index 9e44467..ec7ee29 100644 --- a/lisp/auto-show.el +++ b/lisp/auto-show.el @@ -92,17 +92,6 @@ visible. Setting this to 0 disables this feature." :type 'number :group 'auto-show) -(defun auto-show-truncationp () - "True if line truncation is enabled for the selected window." - ;; XEmacs change (use specifiers) - ;; ### There should be a more straightforward way to do this from elisp. - (or truncate-lines - (and truncate-partial-width-windows - (< (+ (window-width) - (specifier-instance left-margin-width) - (specifier-instance right-margin-width)) - (frame-width))))) - (defun auto-show-mode (arg) "Turn automatic horizontal scroll mode on or off. With arg, turn auto scrolling on if arg is positive, off otherwise. @@ -128,7 +117,7 @@ This normally includes the horizontal scrollbar commands.") ;; XEmacs addition: (defun auto-show-should-take-action-p () - (and auto-show-mode (auto-show-truncationp) + (and auto-show-mode (window-truncated-p) (equal (window-buffer) (current-buffer)) (not (memq this-command auto-show-inhibiting-commands)))) diff --git a/lisp/buffer.el b/lisp/buffer.el index e7920c0..c829284 100644 --- a/lisp/buffer.el +++ b/lisp/buffer.el @@ -32,9 +32,6 @@ ;;; Code: -(defvar switch-to-buffer-hooks nil - "Hooks to run after a recorded buffer switch.") - (defun switch-to-buffer (bufname &optional norecord) "Select buffer BUFNAME in the current window. BUFNAME may be a buffer or a buffer name and is created if it did not exist. @@ -68,8 +65,6 @@ the window-buffer correspondences." (next-window (minibuffer-window)) (selected-window)) buf) - ;; XEmacs change - (or norecord (run-hook-with-args 'switch-to-buffer-hooks buf)) buf)) (defun pop-to-buffer (bufname &optional not-this-window-p on-frame) diff --git a/lisp/cl-extra.el b/lisp/cl-extra.el index 8c97ea0..ea99b9d 100644 --- a/lisp/cl-extra.el +++ b/lisp/cl-extra.el @@ -183,16 +183,14 @@ the elements themselves." (nreverse cl-res)))) -;; mapc is now in C, renamed from `mapc-internal'. - -;(defun mapc (cl-func cl-seq &rest cl-rest) -; "Like `mapcar', but does not accumulate values returned by the function." -; (if cl-rest -; (apply 'map nil cl-func cl-seq cl-rest) -; ;; XEmacs change: we call mapc-internal, which really doesn't -; ;; accumulate any results. -; (mapc-internal cl-func cl-seq)) -; cl-seq) +(defun mapc (cl-func cl-seq &rest cl-rest) + "Like `mapcar', but does not accumulate values returned by the function." + (if cl-rest + (apply 'map nil cl-func cl-seq cl-rest) + ;; XEmacs change: in the simplest case we call mapc-internal, + ;; which really doesn't accumulate any results. + (mapc-internal cl-func cl-seq)) + cl-seq) (defun mapl (cl-func cl-list &rest cl-rest) "Like `maplist', but does not accumulate values returned by the function." @@ -674,13 +672,13 @@ PROPLIST is a list of the sort returned by `symbol-plist'." ;; The `regular' Common Lisp hash-table stuff has been moved into C. ;; Only backward compatibility stuff remains here. (defun make-hashtable (size &optional test) - (make-hash-table :size size :test test :type 'non-weak)) + (make-hash-table :test test :size size)) (defun make-weak-hashtable (size &optional test) - (make-hash-table :size size :test test :type 'weak)) + (make-hash-table :test test :size size :weakness t)) (defun make-key-weak-hashtable (size &optional test) - (make-hash-table :size size :test test :type 'key-weak)) + (make-hash-table :test test :size size :weakness 'key)) (defun make-value-weak-hashtable (size &optional test) - (make-hash-table :size size :test test :type 'value-weak)) + (make-hash-table :test test :size size :weakness 'value)) (define-obsolete-function-alias 'hashtablep 'hash-table-p) (define-obsolete-function-alias 'hashtable-fullness 'hash-table-count) @@ -693,6 +691,7 @@ PROPLIST is a list of the sort returned by `symbol-plist'." (make-obsolete 'make-weak-hashtable 'make-hash-table) (make-obsolete 'make-key-weak-hashtable 'make-hash-table) (make-obsolete 'make-value-weak-hashtable 'make-hash-table) +(make-obsolete 'hash-table-type 'hash-table-weakness) (when (fboundp 'x-keysym-hash-table) (make-obsolete 'x-keysym-hashtable 'x-keysym-hash-table)) diff --git a/lisp/cl-macs.el b/lisp/cl-macs.el index db30575..04e2f97 100644 --- a/lisp/cl-macs.el +++ b/lisp/cl-macs.el @@ -1647,12 +1647,12 @@ Example: (defsetf nth (n x) (v) (list 'setcar (list 'nthcdr n x) v))." (defsetf extent-priority set-extent-priority) (defsetf extent-property (x y &optional ignored-arg) (arg) (list 'set-extent-property x y arg)) -(defsetf extent-end-position (ext) (store) - (list 'progn (list 'set-extent-endpoints (list 'extent-start-position ext) - store) store)) (defsetf extent-start-position (ext) (store) - (list 'progn (list 'set-extent-endpoints store - (list 'extent-end-position ext)) store)) + `(progn (set-extent-endpoints ,ext ,store (extent-end-position ,ext)) + ,store)) +(defsetf extent-end-position (ext) (store) + `(progn (set-extent-endpoints ,ext (extent-start-position ,ext) ,store) + ,store)) (defsetf face-background (f &optional s) (x) (list 'set-face-background f x s)) (defsetf face-background-pixmap (f &optional s) (x) (list 'set-face-background-pixmap f x s)) diff --git a/lisp/cl.el b/lisp/cl.el index 41a5955..4bddff6 100644 --- a/lisp/cl.el +++ b/lisp/cl.el @@ -680,9 +680,9 @@ FUNC is not added if it already appears on the list stored in HOOK." ;(load "cl-defs") ;;; Define data for indentation and edebug. -(mapc +(mapcar #'(lambda (entry) - (mapc + (mapcar #'(lambda (func) (put func 'lisp-indent-function (nth 1 entry)) (put func 'lisp-indent-hook (nth 1 entry)) diff --git a/lisp/cmdloop.el b/lisp/cmdloop.el index e5b4be0..a9ae8b2 100644 --- a/lisp/cmdloop.el +++ b/lisp/cmdloop.el @@ -319,23 +319,36 @@ when called from Lisp." (if (and teach-extended-commands-p (interactive-p)) - ;; We need to fiddle with keys: remember the keys, run the - ;; command, and show the keys (if any). + ;; Remember the keys, run the command, and show the keys (if + ;; any). The funny variable names are a poor man's guarantee + ;; that we don't get tripped by this-command doing something + ;; funny. Quoth our forefathers: "We want lexical scope!" (let ((_execute_command_keys_ (where-is-internal this-command)) (_execute_command_name_ this-command)) ; the name can change (command-execute this-command t) - (when (and _execute_command_keys_ - ;; Wait for a while, so the user can see a message - ;; printed, if any. - (sit-for 1)) - (display-message - 'no-log - (format "Command `%s' is bound to key%s: %s" - _execute_command_name_ - (if (cdr _execute_command_keys_) "s" "") - (sorted-key-descriptions _execute_command_keys_))) - (sit-for teach-extended-commands-timeout) - (clear-message 'no-log))) + (when _execute_command_keys_ + ;; Normally the region is adjusted in post_command_hook; + ;; however, it is not called until after we finish. It + ;; looks ugly for the region to get updated after the + ;; delays, so we do it now. The code below is a Lispified + ;; copy of code in event-stream.c:post_command_hook(). + (if (and (not zmacs-region-stays) + (or (not (eq (selected-window) (minibuffer-window))) + (eq (zmacs-region-buffer) (current-buffer)))) + (zmacs-deactivate-region) + (zmacs-update-region)) + ;; Wait for a while, so the user can see a message printed, + ;; if any. + (when (sit-for 1) + (display-message + 'no-log + (format (if (cdr _execute_command_keys_) + "Command `%s' is bound to keys: %s" + "Command `%s' is bound to key: %s") + _execute_command_name_ + (sorted-key-descriptions _execute_command_keys_))) + (sit-for teach-extended-commands-timeout) + (clear-message 'no-log)))) ;; Else, just run the command. (command-execute this-command t))) diff --git a/lisp/code-process.el b/lisp/code-process.el index d96ecea..526639d 100644 --- a/lisp/code-process.el +++ b/lisp/code-process.el @@ -198,9 +198,9 @@ or a cons of coding systems which are used as above. See also the function `find-operation-coding-system'.") -(defun open-network-stream (name buffer host service) +(defun open-network-stream (name buffer host service &optional protocol) "Open a TCP connection for a service to a host. -Returns a subprocess-object to represent the connection. +Return a subprocess-object to represent the connection. Input and output work as for subprocesses; `delete-process' closes it. Args are NAME BUFFER HOST SERVICE. NAME is name for process. It is modified if necessary to make it unique. @@ -211,7 +211,17 @@ BUFFER is the buffer (or buffer-name) to associate with the process. with any buffer Third arg is name of the host to connect to, or its IP address. Fourth arg SERVICE is name of the service desired, or an integer - specifying a port number to connect to." + specifying a port number to connect to. +Fifth argument PROTOCOL is a network protocol. Currently 'tcp + (Transmission Control Protocol) and 'udp (User Datagram Protocol) are + supported. When omitted, 'tcp is assumed. + +Ouput via `process-send-string' and input via buffer or filter (see +`set-process-filter') are stream-oriented. That means UDP datagrams are +not guaranteed to be sent and received in discrete packets. (But small +datagrams around 500 bytes that are not truncated by `process-send-string' +are usually fine.) Note further that UDP protocol does not guard against +lost packets." (let (cs-r cs-w) (let (ret) (catch 'found @@ -245,6 +255,6 @@ Fourth arg SERVICE is name of the service desired, or an integer (or coding-system-for-read cs-r)) (coding-system-for-write (or coding-system-for-write cs-w))) - (open-network-stream-internal name buffer host service)))) + (open-network-stream-internal name buffer host service protocol)))) ;;; mule-process.el ends here diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el index 5851776..4db1128 100644 --- a/lisp/cus-edit.el +++ b/lisp/cus-edit.el @@ -3280,7 +3280,7 @@ Leave point at the location of the call, or after the last expression." (when (or (and spec (eq (car spec) 'user) (eq (second spec) 'set)) comment) (princ "\n '(") - (princ symbol) + (prin1 symbol) (princ " ") ;; This comment stuf is in the way #### ;; Is (eq (third spec) (car saved-value)) ???? @@ -3313,7 +3313,7 @@ Leave point at the location of the call, or after the last expression." (eq (car theme-spec) 'user) (eq (second theme-spec) 'set)) comment) (princ "\n '(") - (princ symbol) + (prin1 symbol) (princ " ") (prin1 (get symbol 'saved-face)) (if (or comment now) @@ -3358,7 +3358,7 @@ Leave point at the location of the call, or after the last expression." (princ "(") (princ (quote ,setter)) (princ "\n '(") - (princ object) + (prin1 object) (princ " ") (prin1 (third spec)) (princ ")"))))))) diff --git a/lisp/cus-start.el b/lisp/cus-start.el index 8dc92d8..49685ca 100644 --- a/lisp/cus-start.el +++ b/lisp/cus-start.el @@ -63,6 +63,7 @@ ;; integer (auto-save-interval auto-save integer) (bell-volume sound integer) + (bell-inhibit-time sound integer) (echo-keystrokes keyboard integer) (gc-cons-threshold alloc integer) (next-screen-context-lines display integer) diff --git a/lisp/dump-paths.el b/lisp/dump-paths.el index 10117d5..780f3ad 100644 --- a/lisp/dump-paths.el +++ b/lisp/dump-paths.el @@ -39,7 +39,12 @@ (princ (format "XEmacs thinks the roots of its hierarchy are:\n%S\n" roots))) - (let ((stuff (packages-find-packages roots))) + (let* ((package-locations + (packages-compute-package-locations + ;; temporary kludge: + ;; this should be synched with startup.el + (paths-construct-path '("~" ".xemacs")))) + (stuff (packages-find-packages roots package-locations))) (setq late-packages (car (cdr stuff)))) (setq late-package-load-path (packages-find-package-load-path late-packages)) diff --git a/lisp/faces.el b/lisp/faces.el index b9dc478..90fe697 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -834,12 +834,12 @@ substituted for the specification." ;; happen if that locale has no instantiators. So signal ;; an error to indicate this. - (setq temp-sp - (if (and (or (eq locale 'global) (eq locale 'all) (not locale)) - (not (face-property face property 'global))) - (copy-specifier (face-property 'default property) - nil 'global) - sp)) + + (setq temp-sp (copy-specifier sp)) + (if (and (or (eq locale 'global) (eq locale 'all) (not locale)) + (not (face-property face property 'global))) + (copy-specifier (face-property 'default property) + temp-sp 'global)) (if (and (valid-specifier-locale-p locale) (not (specifier-specs temp-sp locale))) (error "Property must have a specification in locale %S" locale)) @@ -1410,7 +1410,8 @@ and 'global)." (mswindows-init-device-faces device)) ;; Nothing to do for TTYs? ) - (init-other-random-faces device))) + (or (eq 'stream (device-type device)) + (init-other-random-faces device)))) (defun init-frame-faces (frame) (when init-face-from-resources @@ -1618,6 +1619,7 @@ in that frame; otherwise change each frame." (set-face-underline-p 'underline t 'global '(default))) (make-face 'zmacs-region "Used on highlightes region between point and mark.") (make-face 'isearch "Used on region matched by isearch.") +(make-face 'isearch-secondary "Face to use for highlighting all matches.") (make-face 'list-mode-item-selected "Face for the selected list item in list-mode.") (make-face 'highlight "Highlight face.") @@ -1707,6 +1709,13 @@ in that frame; otherwise change each frame." ((mswindows default color) . "green")) 'global) +;; #### This should really, I mean *really*, be converted to some form +;; of `defface' one day. +(set-face-foreground 'isearch-secondary + '(((x default color) . "red3") + ((mswindows default color) . "red3")) + 'global) + ;; Define some logical color names to be used when reading the pixmap files. (if (featurep 'xpm) (setq xpm-color-symbols diff --git a/lisp/files.el b/lisp/files.el index 0b23435..f5d25be 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -1275,7 +1275,7 @@ When checking `inhibit-first-line-modes-regexps', we first discard from the end of the file name anything that matches one of these regexps.") (defvar user-init-file - "" ; set by command-line + nil ; set by command-line "File name including directory of user's initialization file.") (defun set-auto-mode (&optional just-from-file-name) @@ -2756,11 +2756,12 @@ non-nil, it is called instead of rereading visited file contents." (not (file-exists-p file-name))) (error "Auto-save file %s not current" file-name)) ((save-window-excursion - (with-output-to-temp-buffer "*Directory*" - (buffer-disable-undo standard-output) - (call-process "ls" nil standard-output nil - (if (file-symlink-p file) "-lL" "-l") - file file-name)) + (if (not (eq system-type 'windows-nt)) + (with-output-to-temp-buffer "*Directory*" + (buffer-disable-undo standard-output) + (call-process "ls" nil standard-output nil + (if (file-symlink-p file) "-lL" "-l") + file file-name))) (yes-or-no-p (format "Recover auto save file %s? " file-name))) (switch-to-buffer (find-file-noselect file t)) (let ((buffer-read-only nil)) diff --git a/lisp/find-paths.el b/lisp/find-paths.el index f5be624..9118e94 100644 --- a/lisp/find-paths.el +++ b/lisp/find-paths.el @@ -218,13 +218,13 @@ If ENFORCE-VERSION is non-nil, the directory must contain the XEmacs version." ;; from more to less specific (paths-find-version-directory roots (concat base system-configuration) - envvar) + envvar default) (paths-find-version-directory roots base envvar) (paths-find-version-directory roots system-configuration - envvar default))) + envvar))) (defun construct-emacs-version-name () "Construct the raw XEmacs version number." diff --git a/lisp/font-lock.el b/lisp/font-lock.el index ea1e1cb..d71c4fa 100644 --- a/lisp/font-lock.el +++ b/lisp/font-lock.el @@ -2444,11 +2444,11 @@ The name is assumed to begin with a capital letter.") (goto-char (match-end 1)) (goto-char (match-end 0)) (1 font-lock-variable-name-face)))))) - + ;; Modifier keywords and Java doc tags (setq java-font-lock-keywords-3 (append - + '( ;; Feature scoping: ;; These must come first or the Modifiers from keywords-1 will @@ -2458,11 +2458,11 @@ The name is assumed to begin with a capital letter.") ("\\" 0 font-lock-preprocessor-face) ("\\" 0 font-lock-reference-face)) java-font-lock-keywords-2 - + (list ;; Java doc tags - '("@\\(author\\|exception\\|param\\|return\\|see\\|version\\)\\s " + '("@\\(author\\|exception\\|throws\\|deprecated\\|param\\|return\\|see\\|since\\|version\\)\\s " 0 font-lock-keyword-face t) ;; Doc tag - Parameter identifiers @@ -2470,7 +2470,17 @@ The name is assumed to begin with a capital letter.") 1 'font-lock-variable-name-face t) ;; Doc tag - Exception types - (list (concat "@exception\\ s*" + (list (concat "@exception\\s +" + java-font-lock-identifier-regexp) + '(1 (if (equal (char-after (match-end 0)) ?.) + font-lock-reference-face font-lock-type-face) t) + (list (concat "\\=\\." java-font-lock-identifier-regexp) + '(goto-char (match-end 0)) nil + '(1 (if (equal (char-after (match-end 0)) ?.) + 'font-lock-reference-face 'font-lock-type-face) t))) + + ;; Doc tag - Exception types + (list (concat "@exception\\s +" java-font-lock-identifier-regexp) '(1 (if (equal (char-after (match-end 0)) ?.) font-lock-reference-face font-lock-type-face) t) @@ -2482,7 +2492,14 @@ The name is assumed to begin with a capital letter.") ;; Doc tag - Cross-references, usually to methods '("@see\\s +\\(\\S *[^][ \t\n\r\f(){},.;:]\\)" 1 font-lock-function-name-face t) - + + ;; Doc tag - Links + '("{@link\\s +\\([^}]*\\)}" + 0 font-lock-keyword-face t) + ;; Doc tag - Links + '("{@link\\s +\\(\\S +\\s +\\S +\\)}" + 1 font-lock-function-name-face t) + ))) ) diff --git a/lisp/gnuserv.el b/lisp/gnuserv.el index b670e8d..ee47e85 100644 --- a/lisp/gnuserv.el +++ b/lisp/gnuserv.el @@ -440,6 +440,7 @@ If a flag is `view', view the files read-only." (client (make-gnuclient :id gnuserv-current-client :device device :frame new-frame))) + (select-frame frame) (setq gnuserv-current-client nil) ;; If the device was created by this client, push it to the list. (and (/= old-device-num (length (device-list))) diff --git a/lisp/gui.el b/lisp/gui.el index d23ea03..9eb0c79 100644 --- a/lisp/gui.el +++ b/lisp/gui.el @@ -83,7 +83,7 @@ Normally it also has no modelines, menubars, or toolbars." "True if OBJECT is a GUI button." (and (vectorp object) (> (length object) 0) - (eq 'gui-button (aref object 0)))) + (eq 'button (aref object 0)))) (make-face 'gui-button-face "Face used for gui buttons") (if (not (face-differs-from-default-p 'gui-button-face)) @@ -98,26 +98,15 @@ Normally it also has no modelines, menubars, or toolbars." "Make a GUI button whose label is STRING and whose action is ACTION. If the button is inserted in a buffer and then clicked on, and ACTION is non-nil, ACTION will be called with one argument, USER-DATA." - (vector 'gui-button - (if (featurep 'xpm) - (xpm-button-create - string gui-button-shadow-thickness - (color-instance-name (face-foreground-instance 'gui-button-face)) - (color-instance-name (face-background-instance 'gui-button-face))) - (xbm-button-create string gui-button-shadow-thickness)) - action user-data)) + (vector 'button + :descriptor string + :face 'gui-button-face + :callback `(funcall (quote ,action) (quote ,user-data)))) (defun insert-gui-button (button &optional pos buffer) "Insert GUI button BUTTON at POS in BUFFER." (check-argument-type 'gui-button-p button) - (let ((annotation - (make-annotation (make-glyph (car (aref button 1))) - pos 'text buffer nil - (make-glyph (cadr (aref button 1))))) - (action (aref button 2))) - (and action - (progn - (set-annotation-action annotation action) - (set-annotation-data annotation (aref button 3)))))) + (make-annotation (make-glyph button) + pos 'text buffer nil)) ;;; gui.el ends here diff --git a/lisp/gutter-items.el b/lisp/gutter-items.el index 3d83dd1..ef6cabe 100644 --- a/lisp/gutter-items.el +++ b/lisp/gutter-items.el @@ -70,7 +70,7 @@ If this is 10, then only the ten most-recently-selected buffers will be shown. If this is nil, then all buffers will be shown. Setting this to a large number or nil will slow down tab responsiveness." :type '(choice (const :tag "Show all" nil) - (integer 10)) + (integer 6)) :group 'buffers-tab) (defcustom buffers-tab-switch-to-buffer-function 'buffers-tab-switch-to-buffer @@ -91,18 +91,102 @@ begins with a space)." function) :group 'buffers-tab) -(defcustom buffers-tab-format-buffer-line-function 'format-buffers-menu-line +(defcustom buffers-tab-selection-function 'select-buffers-tab-buffers-by-mode + "*If non-nil, a function specifying the buffers to select from the +buffers tab. This is passed two buffers and should return non-nil if +the second buffer should be selected. The default value +`select-buffers-tab-buffers-by-mode' groups buffers by major mode and +by `buffers-tab-grouping-regexp'." + + :type '(choice (const :tag "None" nil) + function) + :group 'buffers-tab) + +(defcustom buffers-tab-face 'default + "*Face to use for displaying the buffers tab." + :type 'face + :group 'buffers-tab) + +(defcustom buffers-tab-grouping-regexp + '("^\\(gnus-\\|message-mode\\|mime/viewer-mode\\)" + "^\\(emacs-lisp-\\|lisp-\\)") + "*If non-nil, a list of regular expressions for buffer grouping. +Each regular expression is applied to the current major-mode symbol +name and mode-name, if it matches then any other buffers that match +the same regular expression be added to the current group." + :type '(choice (const :tag "None" nil) + sexp) + :group 'buffers-tab) + +(defcustom buffers-tab-format-buffer-line-function 'format-buffers-tab-line "*The function to call to return a string to represent a buffer in the -buffers tab. The function is passed a buffer and should return a string. -The default value `format-buffers-menu-line' just returns the name of -the buffer. Also check out `slow-format-buffers-menu-line' which -returns a whole bunch of info about a buffer." +buffers tab. The function is passed a buffer and should return a +string. The default value `format-buffers-tab-line' just returns the +name of the buffer, optionally truncated to +`buffers-tab-max-buffer-line-length'. Also check out +`slow-format-buffers-menu-line' which returns a whole bunch of info +about a buffer." :type 'function :group 'buffers-tab) +(defvar buffers-tab-default-buffer-line-length + (make-specifier-and-init 'generic '((global ((default) . 25))) t) + "*Maximum length of text which may appear in a \"Buffers\" tab. +This is a specifier, use set-specifier to modify it.") + +(defcustom buffers-tab-max-buffer-line-length + (specifier-instance buffers-tab-default-buffer-line-length) + "*Maximum length of text which may appear in a \"Buffers\" tab. +Buffer names over this length will be truncated with elipses. +If this is 0, then the full buffer name will be shown." + :type '(choice (const :tag "Show all" 0) + (integer 25)) + :group 'buffers-tab + :set #'(lambda (var val) + (set-specifier buffers-tab-default-buffer-line-length val) + (setq buffers-tab-max-buffer-line-length val))) + (defun buffers-tab-switch-to-buffer (buffer) "For use as a value for `buffers-tab-switch-to-buffer-function'." - (switch-to-buffer buffer t)) + (unless (eq (window-buffer) buffer) + (if (> (length (windows-of-buffer buffer)) 0) + (select-window (car (windows-of-buffer buffer))) + (switch-to-buffer buffer t)))) + +(defun select-buffers-tab-buffers-by-mode (buf1 buf2) + "For use as a value of `buffers-tab-selection-function'. +This selects buffers by major mode `buffers-tab-grouping-regexp'." + (let ((mode1 (symbol-name (symbol-value-in-buffer 'major-mode buf1))) + (mode2 (symbol-name (symbol-value-in-buffer 'major-mode buf2))) + (modenm1 (symbol-value-in-buffer 'mode-name buf1)) + (modenm2 (symbol-value-in-buffer 'mode-name buf2))) + (cond ((or (eq mode1 mode2) + (eq modenm1 modenm2) + (and (string-match "^[^-]+-" mode1) + (string-match + (concat "^" (regexp-quote + (substring mode1 0 (match-end 0)))) + mode2)) + (and buffers-tab-grouping-regexp + (find-if #'(lambda (x) + (or + (and (string-match x mode1) + (string-match x mode2)) + (and (string-match x modenm1) + (string-match x modenm2)))) + buffers-tab-grouping-regexp))) + t) + (t nil)))) + +(defun format-buffers-tab-line (buffer) + "For use as a value of `buffers-tab-format-buffer-line-function'. +This just returns the buffer's name, optionally truncated." + (let ((len (specifier-instance buffers-tab-default-buffer-line-length))) + (if (and (> len 0) + (> (length (buffer-name buffer)) len)) + (concat (substring (buffer-name buffer) + 0 (- len 3)) "...") + (buffer-name buffer)))) (defsubst build-buffers-tab-internal (buffers) (let (line) @@ -114,14 +198,24 @@ returns a whole bunch of info about a buffer." (buffer-name buffer)))) buffers))) -(defun buffers-tab-items () +(defun buffers-tab-items (&optional in-deletion frame) "This is the tab filter for the top-level buffers \"Buffers\" tab. It dynamically creates a list of buffers to use as the contents of the tab. Only the most-recently-used few buffers will be listed on the tab, for efficiency reasons. You can control how many buffers will be shown by setting `buffers-tab-max-size'. You can control the text of the tab items by redefining the function `format-buffers-menu-line'." - (let ((buffers (delete-if buffers-tab-omit-function (buffer-list)))) + (let* ((buffers (delete-if buffers-tab-omit-function (buffer-list frame))) + (first-buf (car buffers))) + ;; if we're in deletion ignore the current buffer + (when in-deletion + (setq buffers (delq (current-buffer) buffers)) + (setq first-buf (car buffers))) + ;; group buffers by mode + (when buffers-tab-selection-function + (delete-if-not #'(lambda (buf) + (funcall buffers-tab-selection-function + first-buf buf)) buffers)) (and (integerp buffers-tab-max-size) (> buffers-tab-max-size 1) (> (length buffers) buffers-tab-max-size) @@ -137,24 +231,308 @@ items by redefining the function `format-buffers-menu-line'." (make-extent 0 0 gutter-string) (setq gutter-buffers-tab (make-glyph - (vector 'tab-control :descriptor "Buffers" + (vector 'tab-control :descriptor "Buffers" :face buffers-tab-face :properties (list :items (buffers-tab-items)))))) ;; This looks better than a 3d border - (set-specifier default-gutter-border-width 0 'global 'mswindows) - (set-specifier default-gutter gutter-string 'global 'mswindows))) + (mapcar '(lambda (x) + (when (valid-image-instantiator-format-p 'tab-control x) + (set-specifier default-gutter-border-width 0 'global x) + (set-specifier default-gutter gutter-string 'global x))) + (console-type-list)))) -(defun update-tab-in-gutter (&optional notused) +(defun update-tab-in-gutter (&optional frame-or-buffer) "Update the tab control in the gutter area." - (when (valid-image-instantiator-format-p 'tab-control) - (set-image-instance-property (glyph-image-instance gutter-buffers-tab) - :items - (buffers-tab-items)) - (resize-subwindow (glyph-image-instance gutter-buffers-tab) - (gutter-pixel-width) nil))) - -(add-tab-to-gutter) -(add-hook 'switch-to-buffer-hooks 'update-tab-in-gutter) + (let ((locale (if (framep frame-or-buffer) frame-or-buffer))) + (when (specifier-instance default-gutter-visible-p locale) + (unless gutter-buffers-tab + (add-tab-to-gutter)) + (when (valid-image-instantiator-format-p 'tab-control) + (let ((inst (glyph-image-instance + gutter-buffers-tab + (when (framep frame-or-buffer) + (last-nonminibuf-window frame-or-buffer))))) + (set-image-instance-property inst :items + (buffers-tab-items + nil locale)) + (resize-subwindow inst (gutter-pixel-width) nil)) + )))) + +(defun remove-buffer-from-gutter-tab () + "Remove the current buffer from the tab control in the gutter area." + (when (and (valid-image-instantiator-format-p 'tab-control) + (specifier-instance default-gutter-visible-p)) + (let ((inst (glyph-image-instance gutter-buffers-tab)) + (buffers (buffers-tab-items t))) + (unless buffers + (setq buffers (build-buffers-tab-internal + (list + (get-buffer-create "*scratch*"))))) + (set-image-instance-property inst :items buffers) + (resize-subwindow inst (gutter-pixel-width) nil) + ))) + +(add-hook 'kill-buffer-hook 'remove-buffer-from-gutter-tab) (add-hook 'create-frame-hook 'update-tab-in-gutter) +(add-hook 'record-buffer-hook 'update-tab-in-gutter) + +;; +;; progress display +;; ripped off from message display +;; +(defvar progress-stack nil + "An alist of label/string pairs representing active progress gauges. +The first element in the list is currently displayed in the gutter area. +Do not modify this directly--use the `progress' or +`display-progress'/`clear-progress' functions.") + +(defvar progress-glyph-height 32 + "Height of the gutter area for progress messages.") + +(defvar progress-stop-callback 'progress-quit-function + "Function to call to stop the progress operation.") + +(defun progress-quit-function () + "Default function to call for the stop button in a progress gauge. +This just removes the progress gauge and calls quit." + (interactive) + (clear-progress) + (keyboard-quit)) + +;; private variables +(defvar progress-gauge-glyph + (make-glyph + (vector 'progress-gauge + :pixel-height (- progress-glyph-height 8) + :pixel-width 250 + :descriptor "Progress"))) + +(defvar progress-text-glyph + (make-glyph [string :data ""])) + +(defvar progress-layout-glyph + (make-glyph + (vector + 'layout :orientation 'vertical :justify 'left + :items (list + progress-text-glyph + (make-glyph + (vector + 'layout :pixel-height progress-glyph-height + :orientation 'horizontal + :items (list + progress-gauge-glyph + (vector + 'button :pixel-height (- progress-glyph-height 8) + :descriptor " Stop " + :callback '(funcall progress-stop-callback))))))))) + +(defvar progress-abort-glyph + (make-glyph + (vector 'layout :orientation 'vertical :justify 'left + :items (list progress-text-glyph + (make-glyph + (vector 'layout + :pixel-height progress-glyph-height + :orientation 'horizontal)))))) + +(defvar progress-extent-text "") +(defvar progress-extent nil) + +(defun progress-displayed-p (&optional return-string frame) + "Return a non-nil value if a progress gauge is presently displayed in the +gutter area. If optional argument RETURN-STRING is non-nil, +return a string containing the message, otherwise just return t." + (let ((buffer (get-buffer-create " *Gutter Area*"))) + (and (< (point-min buffer) (point-max buffer)) + (if return-string + (buffer-substring nil nil buffer) + t)))) + +;;; Returns the string which remains in the echo area, or nil if none. +;;; If label is nil, the whole message stack is cleared. +(defun clear-progress (&optional label frame no-restore) + "Remove any progress gauge with the given LABEL from the progress gauge-stack, +erasing it from the gutter area if it's currently displayed there. +If a message remains at the head of the progress-stack and NO-RESTORE +is nil, it will be displayed. The string which remains in the gutter +area will be returned, or nil if the progress-stack is now empty. +If LABEL is nil, the entire progress-stack is cleared. + +Unless you need the return value or you need to specify a label, +you should just use (progress nil)." + (or frame (setq frame (selected-frame))) + (remove-progress label frame) + (let ((inhibit-read-only t) + (zmacs-region-stays zmacs-region-stays)) ; preserve from change + (erase-buffer " *Echo Area*") + (erase-buffer (get-buffer-create " *Gutter Area*"))) + (if no-restore + nil ; just preparing to put another msg up + (if progress-stack + (let ((oldmsg (cdr (car progress-stack)))) + (raw-append-progress oldmsg frame) + oldmsg) + ;; nothing to display so get rid of the gauge + (set-specifier bottom-gutter-border-width 0 frame) + (set-specifier bottom-gutter-visible-p nil frame)))) + +(defun remove-progress (&optional label frame) + ;; If label is nil, we want to remove all matching progress gauges. + (while (and progress-stack + (or (null label) ; null label means clear whole stack + (eq label (car (car progress-stack))))) + (setq progress-stack (cdr progress-stack))) + (let ((s progress-stack)) + (while (cdr s) + (let ((msg (car (cdr s)))) + (if (eq label (car msg)) + (progn + (setcdr s (cdr (cdr s)))) + (setq s (cdr s))))))) + +(defun append-progress (label message &optional value frame) + (or frame (setq frame (selected-frame))) + ;; Add a new entry to the message-stack, or modify an existing one + (let* ((top (car progress-stack)) + (tmsg (cdr top))) + (if (eq label (car top)) + (progn + (setcdr top message) + (if (eq tmsg message) + (set-image-instance-property + (glyph-image-instance progress-gauge-glyph) + :percent value) + (raw-append-progress message value frame)) + (redisplay-gutter-area) + (when (input-pending-p) + (dispatch-event (next-command-event)))) + (push (cons label message) progress-stack) + (raw-append-progress message value frame)) + (when (eq value 100) + (sit-for 0.5 nil) + (clear-progress label)))) + +(defun abort-progress (label message &optional frame) + (or frame (setq frame (selected-frame))) + ;; Add a new entry to the message-stack, or modify an existing one + (let* ((top (car progress-stack)) + (inhibit-read-only t) + (zmacs-region-stays zmacs-region-stays)) + (if (eq label (car top)) + (setcdr top message) + (push (cons label message) progress-stack)) + (unless (equal message "") + (insert-string message (get-buffer-create " *Gutter Area*")) + ;; Do what the device is able to cope with. + (if (not (valid-image-instantiator-format-p 'progress-gauge frame)) + (progn + (insert-string message " *Echo Area*") + (if (not executing-kbd-macro) + (redisplay-echo-area))) + ;; do some funky display here. + (unless progress-extent + (setq progress-extent (make-extent 0 0 progress-extent-text))) + (let ((bglyph (extent-begin-glyph progress-extent))) + (set-extent-begin-glyph progress-extent progress-abort-glyph) + ;; fixup the gutter specifiers + (set-specifier bottom-gutter progress-extent-text frame) + (set-specifier bottom-gutter-border-width 2 frame) + (set-image-instance-property + (glyph-image-instance progress-text-glyph) :data message) + (set-specifier bottom-gutter-height 'autodetect frame) + (set-specifier bottom-gutter-visible-p t frame) + ;; we have to do this so redisplay is up-to-date and so + ;; redisplay-gutter-area performs optimally. + (redisplay-gutter-area) + (sit-for 0.5 nil) + (clear-progress label) + (set-extent-begin-glyph progress-extent bglyph) + ))))) + +(defun raw-append-progress (message &optional value frame) + (unless (equal message "") + (let ((inhibit-read-only t) + (zmacs-region-stays zmacs-region-stays) + (val (or value 0))) ; preserve from change + (insert-string message (get-buffer-create " *Gutter Area*")) + ;; Do what the device is able to cope with. + (if (not (valid-image-instantiator-format-p 'progress-gauge frame)) + (progn + (insert-string + (concat message (if (eq val 100) "done.") + (make-string (/ val 5) ?.)) + " *Echo Area*") + (if (not executing-kbd-macro) + (redisplay-echo-area))) + ;; do some funky display here. + (unless progress-extent + (setq progress-extent (make-extent 0 0 progress-extent-text)) + (set-extent-begin-glyph progress-extent progress-layout-glyph)) + ;; fixup the gutter specifiers + (set-specifier bottom-gutter progress-extent-text frame) + (set-specifier bottom-gutter-border-width 2 frame) + (set-image-instance-property + (glyph-image-instance progress-gauge-glyph) :percent val) + (set-image-instance-property + (glyph-image-instance progress-text-glyph) :data message) + (if (and (eq (specifier-instance bottom-gutter-height frame) + 'autodetect) + (specifier-instance bottom-gutter-visible-p frame)) + (progn + ;; if the gauge is already visible then just draw the gutter + ;; checking for user events + (redisplay-gutter-area) + (when (input-pending-p) + (dispatch-event (next-command-event)))) + ;; otherwise make the gutter visible and redraw the frame + (set-specifier bottom-gutter-height 'autodetect frame) + (set-specifier bottom-gutter-visible-p t frame) + ;; we have to do this so redisplay is up-to-date and so + ;; redisplay-gutter-area performs optimally. + (redisplay-frame) + ))))) + +(defun display-progress (label message &optional value frame) + "Display a progress gauge and message in the bottom gutter area. + First argument LABEL is an identifier for this message. MESSAGE is +the string to display. Use `clear-progress' to remove a labelled +message." + (clear-progress label frame t) + (if (eq value 'abort) + (abort-progress label message frame) + (append-progress label message value frame))) + +(defun current-progress (&optional frame) + "Return the current progress gauge in the gutter area, or nil. +The FRAME argument is currently unused." + (cdr (car progress-stack))) + +;;; may eventually be frame-dependent +(defun current-progress-label (&optional frame) + (car (car progress-stack))) + +(defun progress (fmt &optional value &rest args) + "Print a progress gauge and message in the bottom gutter area of the frame. +The arguments are the same as to `format'. + +If the only argument is nil, clear any existing progress gauge." + (if (and (null fmt) (null args)) + (prog1 nil + (clear-progress nil)) + (let ((str (apply 'format fmt args))) + (display-progress 'progress str value) + str))) + +(defun lprogress (label fmt &optional value &rest args) + "Print a progress gauge and message in the bottom gutter area of the frame. +First argument LABEL is an identifier for this progress gauge. The rest of the +arguments are the same as to `format'." + (if (and (null fmt) (null args)) + (prog1 nil + (clear-progress label nil)) + (let ((str (apply 'format fmt args))) + (display-progress label str value) + str))) (provide 'gutter-items) ;;; gutter-items.el ends here. diff --git a/lisp/indent.el b/lisp/indent.el index f93f413..adf2485 100644 --- a/lisp/indent.el +++ b/lisp/indent.el @@ -93,7 +93,7 @@ only if necessary. It leaves point at end of indentation." (back-to-indentation) (let ((cur-col (current-column))) (cond ((< cur-col column) - (if (> (- column (* (/ cur-col tab-width) tab-width)) tab-width) + (if (>= (- column (* (/ cur-col tab-width) tab-width)) tab-width) (delete-region (point) (progn (skip-chars-backward " ") (point)))) (indent-to column)) diff --git a/lisp/info.el b/lisp/info.el index 6d4e22f..d96c5ba 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -459,6 +459,7 @@ heading." ;; Is this right for NT? .zip, with -c for to stdout, right? (defvar Info-suffix-list '( ("" . nil) (".info" . nil) + (".info.bz2" . "bzip2 -dc %s") (".info.gz" . "gzip -dc %s") (".info-z" . "gzip -dc %s") (".info.Z" . "uncompress -c %s") @@ -501,9 +502,12 @@ Marker points nowhere if file has no tag table.") "List of possible matches for last Info-index command.") (defvar Info-index-first-alternative nil) -(defcustom Info-annotations-path '("~/.xemacs/info.notes" - "~/.infonotes" - "/usr/lib/info.notes") +(defcustom Info-annotations-path + (list + (paths-construct-path (list user-init-directory "info.notes")) + (paths-construct-path '("~" ".infonotes")) + (paths-construct-path '("usr" "lib" "info.notes") + (char-to-string directory-sep-char))) "*Names of files that contain annotations for different Info nodes. By convention, the first one should reside in your personal directory. The last should be a world-writable \"public\" annotations file." @@ -2060,11 +2064,9 @@ A positive or negative prefix argument moves by multiple screenfuls." (progn (Info-global-prev) (message "Node: %s" Info-current-node) - (sit-for 0) - ;;(scroll-up 1) ; work around bug in pos-visible-in-window-p - ;;(scroll-down 1) - (while (not (pos-visible-in-window-p (point-max))) - (scroll-up))) + (goto-char (point-max)) + (recenter -1) + (move-to-window-line 0)) (scroll-down))))) (defun Info-scroll-prev (arg) diff --git a/lisp/isearch-mode.el b/lisp/isearch-mode.el index cc5b3fa..3eef6c9 100644 --- a/lisp/isearch-mode.el +++ b/lisp/isearch-mode.el @@ -1,6 +1,6 @@ ;;; isearch-mode.el --- Incremental search minor mode. -;; Copyright (C) 1992, 1993, 1997 Free Software Foundation, Inc. +;; Copyright (C) 1992,93,94,95,96,97,98,1999 Free Software Foundation, Inc. ;; Author: Daniel LaLiberte ;; Maintainer: XEmacs Development Team @@ -19,35 +19,29 @@ ;; General Public License for more details. ;; You should have received a copy of the GNU General Public License -;; along with XEmacs; see the file COPYING. If not, write to the +;; along with XEmacs; see the file COPYING. If not, write to the ;; Free Software Foundation, 59 Temple Place - Suite 330, ;; Boston, MA 02111-1307, USA. -;;; Synched up with: Not synched with FSF. +;;; Synched up with: FSF 20.4. ;;; Commentary: -;; LCD Archive Entry: -;; isearch-mode|Daniel LaLiberte|liberte@cs.uiuc.edu -;; |A minor mode replacement for isearch.el. - -;;==================================================================== ;; Instructions -;; Searching with isearch-mode.el should work just like isearch.el, -;; except it is done in a temporary minor mode that terminates when -;; you finish searching. +;; Searching with isearch-mode.el should work just like isearch.el +;; [the one from Emacs 18], except it is done in a temporary minor +;; mode that terminates when you finish searching. -;; Semi-modal searching is supported, using a recursive edit. If -;; isearching is started non-interactively by calling one of the -;; isearch commands (e.g. (isearch-forward), but not like gnus does -;; it: (call-interactively 'isearch-forward)), isearch-mode does not -;; return until the search is completed. You should still be able -;; switch buffers, so be careful not to get things confused. +;; For programmed use of isearch-mode, e.g. calling (isearch-forward), +;; isearch-mode behaves modally and does not return until the search +;; is completed. It uses a recursive-edit to behave this way. In +;; that case, you should still be able switch buffers, so be careful +;; not to get things confused. ;; The key bindings active within isearch-mode are defined below in ;; `isearch-mode-map' which is given bindings close to the default -;; characters of isearch.el for version 19. With `isearch-mode', +;; characters of the original isearch.el. With `isearch-mode', ;; however, you can bind multi-character keys and it should be easier ;; to add new commands. One bug though: keys with meta-prefix cannot ;; be longer than two chars. Also see minibuffer-local-isearch-map @@ -63,16 +57,18 @@ ;; Exiting immediately from isearch uses isearch-edit-string instead ;; of nonincremental-search, if search-nonincremental-instead is non-nil. ;; The name of this option should probably be changed if we decide to -;; keep the behavior. One difference is that isearch-edit-string does -;; not support word search yet; perhaps isearch-mode should support it -;; even for incremental searches, but how? +;; keep the behavior. No point in forcing nonincremental search until +;; the last possible moment. -;;==================================================================== -;;; Change History: +;; TODO +;; - Integrate generalized command history to isearch-edit-string. +;; - Think about incorporating query-replace. +;; - Hooks and options for failed search. + +;;; Change Log: + +;; Changes before those recorded in ChangeLog: -;; Header: /import/kaplan/kaplan/liberte/Isearch/RCS/isearch-mode.el,v 1.3 92/06/29 13:10:08 liberte Exp Locker: liberte -;; Log: isearch-mode.el,v -;; ;; 20-aug-92 Hacked by jwz for Lucid Emacs 19.3. ;; ;; Revision 1.3 92/06/29 13:10:08 liberte @@ -83,7 +79,7 @@ ;; Renamed all regex to regexp. ;; Got rid of found-start and found-point globals. ;; Generalized handling of upper-case chars. - + ;; Revision 1.2 92/05/27 11:33:57 liberte ;; Emacs version 19 has a search ring, which is supported here. ;; Other fixes found in the version 19 isearch are included here. @@ -100,38 +96,20 @@ ;;; Code: -(defgroup isearch nil - "Incremental search" - :prefix "search-" - :group 'matching) - - -(defun isearch-char-to-string (c) - (if (eventp c) - (make-string 1 (event-to-character c nil nil t)) - (make-string 1 c))) - -;(defun isearch-text-char-description (c) -; (isearch-char-to-string c)) - -(define-function 'isearch-text-char-description 'text-char-description) - ;;;========================================================================= ;;; User-accessible variables -(defvar search-last-string "" - "Last string search for by a search command. -This does not include direct calls to the primitive search functions, -and does not include searches that are aborted.") +(defgroup isearch nil + "Incremental search minor mode." + :prefix "search-" + :group 'matching) -(defvar search-last-regexp "" - "Last string searched for by a regexp search command. -This does not include direct calls to the primitive search functions, -and does not include searches that are aborted.") -(defconst search-exit-option t - "Non-nil means random control characters terminate incremental search.") +(defcustom search-exit-option t + "*Non-nil means random control characters terminate incremental search." + :type 'boolean + :group 'isearch) (defcustom search-slow-window-lines 1 "*Number of lines in slow search display windows. @@ -148,16 +126,70 @@ that the search has reached." :type 'integer :group 'isearch) +;; We have `search-caps-disable-folding'. +;(defcustom search-upper-case 'not-yanks +; "*If non-nil, upper case chars disable case fold searching. +;That is, upper and lower case chars must match exactly. +;This applies no matter where the chars come from, but does not +;apply to chars in regexps that are prefixed with `\\'. +;If this value is `not-yanks', yanked text is always downcased." +; :type '(choice (const :tag "off" nil) +; (const not-yanks) +; (other :tag "on" t)) +; :group 'isearch) + (defcustom search-nonincremental-instead t - "*If non-nil, do a nonincremental search instead if exiting immediately." + "*If non-nil, do a nonincremental search instead if exiting immediately. +Actually, `isearch-edit-string' is called to let you enter the search +string, and RET terminates editing and does a nonincremental search." :type 'boolean :group 'isearch) - -(defcustom search-whitespace-regexp "\\(\\s \\|[\n\r]\\)+" + +;; FSF default is "\\s-+", but I think our default is better so I'm +;; leaving it. +(defcustom search-whitespace-regexp "\\(\\s-\\|[\n\r]\\)+" "*If non-nil, regular expression to match a sequence of whitespace chars." :type 'regexp :group 'isearch) +(defcustom search-highlight t + "*Whether incremental search and query-replace should highlight +the text that currently matches the search string." + :type 'boolean + :group 'isearch) + +;; I think the name `search-highlight' makes more sense, both because +;; of consistency with other search-* variables above, and because it +;; also applies to query-replace. +(define-obsolete-variable-alias 'isearch-highlight 'search-highlight) + +(defcustom search-invisible 'open + "If t incremental search can match hidden text. +nil means don't match invisible text. +If the value is `open', if the text matched is made invisible by +an overlay having an `invisible' property and that overlay has a property +`isearch-open-invisible', then incremental search will show the contents. +\(This applies when using `outline.el' and `hideshow.el'.)" + :type '(choice (const :tag "Match hidden text" t) + (const :tag "Open overlays" open) + (const :tag "Don't match hidden text" nil)) + :group 'isearch) + +(defcustom isearch-hide-immediately t + "If non-nil, re-hide an invisible match right away. +This variable makes a difference when `search-invisible' is set to `open'. +It means that after search makes some invisible text visible +to show the match, it makes the text invisible again when the match moves. +Ordinarily the text becomes invisible again at the end of the search." + :type 'boolean + :group 'isearch) + +(defvar isearch-mode-hook nil + "Function(s) to call after starting up an incremental search.") + +(defvar isearch-mode-end-hook nil + "Function(s) to call after terminating an incremental search.") + ;;;================================================================== ;;; Search ring. @@ -175,22 +207,34 @@ that the search has reached." :type 'integer :group 'isearch) +;; The important difference between pre-20.4-merge yank-pointers and +;; current code is that the yank pointers positions used to be +;; preserved across the isearch sessions. I changed this because I +;; think the FSF code is closer to how the feature is supposed to +;; behave (read: to minibuffer histories.) (defvar search-ring-yank-pointer nil - "The tail of the search ring whose car is the last thing searched for.") + "Index in `search-ring' of last string reused. +nil if none yet.") (defvar regexp-search-ring-yank-pointer nil - "The tail of the regular expression search ring whose car is the last -thing searched for.") + "Index in `regexp-search-ring' of last string reused. +nil if none yet.") + +(defcustom search-ring-update nil + "*Non-nil if advancing or retreating in the search ring should cause search. +Default nil means edit the string from the search ring first." + :type 'boolean + :group 'isearch) ;;;==================================================== ;;; Define isearch-mode keymap. -(defvar isearch-mode-map +(defvar isearch-mode-map (let ((map (make-keymap))) (set-keymap-name map 'isearch-mode-map) ;; Bind all printing characters to `isearch-printing-char'. - ;; This isn't normally necessary, but if a printing character were - ;; bound to something other than self-insert-command in global-map, + ;; This isn't normally necessary, but if a printing character were + ;; bound to something other than self-insert-command in global-map, ;; then it would terminate the search and be executed without this. (let ((i 32) (str (make-string 1 0))) @@ -198,7 +242,10 @@ thing searched for.") (aset str 0 i) (define-key map str 'isearch-printing-char) (setq i (1+ i)))) - (define-key map "\t" 'isearch-printing-char) + + ;; Here FSF sets up various kludges to handle local bindings with + ;; meta char prefix keys. We don't need isearch-other-meta-char + ;; because we handle things differently (via pre-command-hook). ;; Several non-printing chars change the searching behavior. ;; @@ -207,26 +254,29 @@ thing searched for.") (define-key map "\C-r" 'isearch-repeat-backward) (define-key map "\C-g" 'isearch-abort) + ;; I wish this worked... + ;(define-key map [escape escape escape] 'isearch-cancel) + (define-key map [(meta escape) escape] 'isearch-cancel) + (define-key map "\C-q" 'isearch-quote-char) (define-key map "\C-m" 'isearch-exit) (define-key map "\C-j" 'isearch-printing-char) (define-key map "\t" 'isearch-printing-char) + ;; I prefer our default. + ;(define-key map " " 'isearch-whitespace-chars) + (define-key map "\M- " 'isearch-whitespace-chars) (define-key map "\C-w" 'isearch-yank-word) (define-key map "\C-y" 'isearch-yank-line) (define-key map "\M-y" 'isearch-yank-kill) - ;; Define keys for regexp chars * ? | + ;; Define keys for regexp chars * ? |. + ;; Nothing special for + because it matches at least once. (define-key map "*" 'isearch-*-char) (define-key map "?" 'isearch-*-char) (define-key map "|" 'isearch-|-char) - ;; Some bindings you may want to put in your isearch-mode-hook. - ;; Suggest some alternates... - ;; (define-key map "\C-t" 'isearch-toggle-regexp) - ;; (define-key map "\C-^" 'isearch-edit-string) - ;; delete and backspace delete backward, f1 is help, and C-h can be either (define-key map 'delete 'isearch-delete-char) (define-key map 'backspace 'isearch-delete-char) @@ -236,15 +286,23 @@ thing searched for.") (define-key map "\M-n" 'isearch-ring-advance) (define-key map "\M-p" 'isearch-ring-retreat) - (define-key map "\M- " 'isearch-whitespace-chars) (define-key map "\M-\t" 'isearch-complete) - (define-key map 'button2 'isearch-yank-x-selection) + ;; I find this binding somewhat unintuitive, because it doesn't + ;; work if the mouse pointer is over the echo area -- it has to be + ;; over the search window. + (define-key map 'button2 'isearch-yank-selection) map) "Keymap for isearch-mode.") -(defvar minibuffer-local-isearch-map +;; Some bindings you may want to put in your isearch-mode-hook. +;; Suggest some alternates... +;; (define-key isearch-mode-map "\C-t" 'isearch-toggle-case-fold) +;; (define-key isearch-mode-map "\C-t" 'isearch-toggle-regexp) +;; (define-key isearch-mode-map "\C-^" 'isearch-edit-string) + +(defvar minibuffer-local-isearch-map (let ((map (make-sparse-keymap))) ;; #### - this should also be minor-mode-ified (set-keymap-parents map (list minibuffer-local-map)) @@ -254,6 +312,8 @@ thing searched for.") (define-key map "\r" 'isearch-nonincremental-exit-minibuffer) (define-key map "\M-n" 'isearch-ring-advance-edit) (define-key map "\M-p" 'isearch-ring-retreat-edit) + (define-key map 'down 'isearch-ring-advance-edit) + (define-key map 'up 'isearch-ring-retreat-edit) (define-key map "\M-\t" 'isearch-complete-edit) (define-key map "\C-s" 'isearch-forward-exit-minibuffer) (define-key map "\C-r" 'isearch-reverse-exit-minibuffer) @@ -262,7 +322,8 @@ thing searched for.") ;;;======================================================== ;; Internal variables declared globally for byte-compiler. -;; These are all bound locally while editing the search string. +;; These are all set with setq while isearching +;; and bound locally while editing the search string. (defvar isearch-forward nil) ; Searching in the forward direction. (defvar isearch-regexp nil) ; Searching for a regexp. @@ -274,6 +335,7 @@ thing searched for.") (defvar isearch-success t) ; Searching is currently successful. (defvar isearch-invalid-regexp nil) ; Regexp not well formed. +(defvar isearch-within-brackets nil) ; Regexp has unclosed [. (defvar isearch-other-end nil) ; Start (end) of match if forward (backward). (defvar isearch-wrapped nil) ; Searching restarted from the top (bottom). (defvar isearch-barrier 0) @@ -282,6 +344,12 @@ thing searched for.") (defvar isearch-case-fold-search nil) +;; Need this for toggling case in isearch-toggle-case-fold. When this +;; is non-nil, the case-sensitiveness of the search is set by the +;; user, and is may no longer be dynamically changed as per +;; search-caps-disable-folding. +(defvar isearch-fixed-case nil) + (defvar isearch-adjusted nil) (defvar isearch-slow-terminal-mode nil) ;;; If t, using a small window. @@ -308,12 +376,9 @@ thing searched for.") ;; New value of isearch-forward after isearch-edit-string. (defvar isearch-new-forward nil) +;; Accumulate here the extents unhidden during searching. +(defvar isearch-unhidden-extents nil) ; in FSF: isearch-opened-overlays -(defvar isearch-mode-hook nil - "Function(s) to call after starting up an incremental search.") - -(defvar isearch-mode-end-hook nil - "Function(s) to call after terminating an incremental search.") ;;;============================================================== ;; Minor-mode-alist changes - kind of redundant with the @@ -321,21 +386,28 @@ thing searched for.") (add-minor-mode 'isearch-mode 'isearch-mode) -(defvar isearch-mode nil) +(defvar isearch-mode nil) ;; Name of the minor mode, if non-nil. (make-variable-buffer-local 'isearch-mode) +;; We bind these in keydefs.el. +;(define-key global-map "\C-s" 'isearch-forward) +;(define-key global-map "\C-r" 'isearch-backward) +;(define-key global-map "\M-\C-s" 'isearch-forward-regexp) +;(define-key global-map "\M-\C-r" 'isearch-backward-regexp) + ;;;=============================================================== ;;; Entry points to isearch-mode. ;;; These four functions should replace those in loaddefs.el -;;; An alternative is to fset isearch-forward etc to isearch-mode, -;;; and look at the last command to set the options accordingly. +;;; An alternative is to defalias isearch-forward etc to isearch-mode, +;;; and look at this-command to set the options accordingly. -(defun isearch-forward (&optional regexp-p) - "Do incremental search forward. +(defun isearch-forward (&optional regexp-p no-recursive-edit) + "\ +Do incremental search forward. With a prefix argument, do an incremental regular expression search instead. \\ As you type characters, they add to the search string and are found. -The following non-printing keys are bound in `isearch-mode-map'. +The following non-printing keys are bound in `isearch-mode-map'. Type \\[isearch-delete-char] to cancel characters from end of search string. Type \\[isearch-exit] to exit, leaving point at location found. @@ -346,6 +418,8 @@ Type \\[isearch-yank-word] to yank word from buffer onto end of search\ string and search for it. Type \\[isearch-yank-line] to yank rest of line onto end of search string\ and search for it. +Type \\[isearch-yank-kill] to yank last killed text onto end of search string\ + and search for it. Type \\[isearch-quote-char] to quote control character to search for it. Type \\[isearch-whitespace-chars] to match all whitespace chars in regexp. \\[isearch-abort] while searching or when search has failed cancels input\ @@ -377,36 +451,38 @@ The bindings, more precisely: ;; Type \\[isearch-edit-string] to edit the search string in the minibuffer. ;; Terminate editing and return to incremental searching with CR. - (interactive "_P") - (isearch-mode t (not (null regexp-p)) nil (not (interactive-p)))) + (interactive "_P\np") + (isearch-mode t (not (null regexp-p)) nil (not no-recursive-edit))) -(defun isearch-forward-regexp () +(defun isearch-forward-regexp (&optional not-regexp no-recursive-edit) "\ Do incremental search forward for regular expression. +With a prefix argument, do a regular string search instead. Like ordinary incremental search except that your input is treated as a regexp. See \\[isearch-forward] for more info." - (interactive "_") - (isearch-mode t t nil (not (interactive-p)))) + (interactive "_P\np") + (isearch-mode t (null not-regexp) nil (not no-recursive-edit))) -(defun isearch-backward (&optional regexp-p) +(defun isearch-backward (&optional regexp-p no-recursive-edit) "\ Do incremental search backward. -With a prefix argument, do an incremental regular expression search instead. +With a prefix argument, do a regular expression search instead. See \\[isearch-forward] for more information." - (interactive "_P") - (isearch-mode nil (not (null regexp-p)) nil (not (interactive-p)))) + (interactive "_P\np") + (isearch-mode nil (not (null regexp-p)) nil (not no-recursive-edit))) -(defun isearch-backward-regexp () +(defun isearch-backward-regexp (&optional not-regexp no-recursive-edit) "\ Do incremental search backward for regular expression. +With a prefix argument, do a regular string search instead. Like ordinary incremental search except that your input is treated as a regexp. See \\[isearch-forward] for more info." - (interactive "_") - (isearch-mode nil t nil (not (interactive-p)))) + (interactive "_P\np") + (isearch-mode nil (null not-regexp) nil (not no-recursive-edit))) -;; This function is way wrong, because you can't scroll the help -;; screen; as soon as you press a key, it's gone. I don't know of a -;; good way to fix it, though. -hniksic +;; The problem here is that you can't scroll the help screen; as soon +;; as you press a key, it's gone. I don't know of a good way to fix +;; it, though. -hniksic (defun isearch-mode-help () (interactive "_") (let ((w (selected-window))) @@ -420,7 +496,9 @@ is treated as a regexp. See \\[isearch-forward] for more info." ;; All the work is done by the isearch-mode commands. (defun isearch-mode (forward &optional regexp op-fun recursive-edit word-p) - "Start isearch minor mode. Called by isearch-forward, etc." + "Start isearch minor mode. Called by `isearch-forward', etc. + +\\{isearch-mode-map}" (if executing-kbd-macro (setq recursive-edit nil)) @@ -433,6 +511,7 @@ is treated as a regexp. See \\[isearch-forward] for more info." isearch-word word-p isearch-op-fun op-fun isearch-case-fold-search case-fold-search + isearch-fixed-case nil isearch-string "" isearch-message "" isearch-cmds nil @@ -442,6 +521,7 @@ is treated as a regexp. See \\[isearch-forward] for more info." isearch-adjusted nil isearch-yank-flag nil isearch-invalid-regexp nil + isearch-within-brackets nil isearch-slow-terminal-mode (and (<= (device-baud-rate) search-slow-speed) (> (window-height) @@ -451,10 +531,14 @@ is treated as a regexp. See \\[isearch-forward] for more info." isearch-just-started t isearch-opoint (point) + search-ring-yank-pointer nil + regexp-search-ring-yank-pointer nil + isearch-opened-extents nil isearch-window-configuration (current-window-configuration) - ;; #### Should we remember the old value of - ;; overriding-local-map? + ;; #### What we really need is a buffer-local + ;; overriding-local-map. See isearch-pre-command-hook for + ;; more details. overriding-local-map (progn (set-keymap-parents isearch-mode-map (nconc (current-minor-mode-maps) @@ -463,7 +547,6 @@ is treated as a regexp. See \\[isearch-forward] for more info." isearch-mode-map) isearch-selected-frame (selected-frame) - isearch-mode (gettext " Isearch") ) ;; XEmacs change: without clearing the match data, sometimes old values @@ -471,7 +554,10 @@ is treated as a regexp. See \\[isearch-forward] for more info." (store-match-data nil) (add-hook 'pre-command-hook 'isearch-pre-command-hook) - (set-buffer-modified-p (buffer-modified-p)) ; update modeline + + (setq isearch-mode (gettext " Isearch")) + (redraw-modeline) + (isearch-push-state) ) ; inhibit-quit is t before here @@ -479,26 +565,26 @@ is treated as a regexp. See \\[isearch-forward] for more info." (isearch-update) (run-hooks 'isearch-mode-hook) - ;; isearch-mode can be made modal (in the sense of not returning to - ;; the calling function until searching is completed) by entering + ;; isearch-mode can be made modal (in the sense of not returning to + ;; the calling function until searching is completed) by entering ;; a recursive-edit and exiting it when done isearching. (if recursive-edit (let ((isearch-recursive-edit t)) (recursive-edit))) - ) + isearch-success) ;;;==================================================== ;; Some high level utilities. Others below. (defun isearch-update () - ;; Called after each command to update the display. - (if (null unread-command-event) + ;; Called after each command to update the display. + (if (null unread-command-events) (progn (if (not (input-pending-p)) (isearch-message)) (if (and isearch-slow-terminal-mode - (not (or isearch-small-window + (not (or isearch-small-window (pos-visible-in-window-p)))) (let ((found-point (point))) (setq isearch-small-window t) @@ -520,27 +606,24 @@ is treated as a regexp. See \\[isearch-forward] for more info." (if (< isearch-other-end (point)) (isearch-highlight isearch-other-end (point)) (isearch-highlight (point) isearch-other-end)) - (if (extentp isearch-extent) - (isearch-dehighlight nil))) + (isearch-dehighlight)) )) (setq ;; quit-flag nil not for isearch-mode isearch-adjusted nil isearch-yank-flag nil) + (isearch-highlight-all-update) ) -(defun isearch-done () +(defun isearch-done (&optional nopush edit) ;; Called by all commands that terminate isearch-mode. (let ((inhibit-quit t)) ; danger danger! (if (and isearch-buffer (buffer-live-p isearch-buffer)) - (save-excursion - ;; Some loser process filter might have switched the - ;; window's buffer, so be sure to set these variables back - ;; in the buffer we frobbed them in. But only if the buffer - ;; is still alive. - (set-buffer isearch-buffer) - ;; #### Should we restore the old value of - ;; overriding-local-map? + ;; Some loser process filter might have switched the window's + ;; buffer, so be sure to set these variables back in the + ;; buffer we frobbed them in. But only if the buffer is still + ;; alive. + (with-current-buffer isearch-buffer (setq overriding-local-map nil) ;; Use remove-hook instead of just setting it to our saved value ;; in case some process filter has created a buffer and modified @@ -549,8 +632,11 @@ is treated as a regexp. See \\[isearch-forward] for more info." (remove-hook 'pre-command-hook 'isearch-pre-command-hook) (set-keymap-parents isearch-mode-map nil) (setq isearch-mode nil) - (set-buffer-modified-p (buffer-modified-p));; update modeline - (isearch-dehighlight t))) + (redraw-modeline) + (isearch-dehighlight) + (isearch-highlight-all-cleanup) + (isearch-restore-invisible-extents nil nil) + )) ;; it's not critical that this be inside inhibit-quit, but leaving ;; things in small-window-mode would be bad. @@ -568,37 +654,41 @@ is treated as a regexp. See \\[isearch-forward] for more info." ;; Maybe should test difference between and set mark iff > threshold. (if (and (buffer-live-p isearch-buffer) (/= (point isearch-buffer) isearch-opoint)) + ;; #### FSF doesn't do this if the region is active. Should + ;; we do the same? (progn (push-mark isearch-opoint t nil isearch-buffer) (or executing-kbd-macro (> (minibuffer-depth) 0) - (display-message 'command "Mark saved where search started")))) - ) + (display-message 'command "Mark saved where search started"))))) (setq isearch-buffer nil) ) ; inhibit-quit is t before here - (if (> (length isearch-string) 0) + (if (and (> (length isearch-string) 0) (not nopush)) ;; Update the ring data. - (if isearch-regexp - (if (not (setq regexp-search-ring-yank-pointer - (member isearch-string regexp-search-ring))) - (progn - (setq regexp-search-ring - (cons isearch-string regexp-search-ring) - regexp-search-ring-yank-pointer regexp-search-ring) - (if (> (length regexp-search-ring) regexp-search-ring-max) - (setcdr (nthcdr (1- regexp-search-ring-max) regexp-search-ring) - nil)))) - (if (not (setq search-ring-yank-pointer - ;; really need equal test instead of eq. - (member isearch-string search-ring))) - (progn - (setq search-ring (cons isearch-string search-ring) - search-ring-yank-pointer search-ring) - (if (> (length search-ring) search-ring-max) - (setcdr (nthcdr (1- search-ring-max) search-ring) nil)))))) + (isearch-update-ring isearch-string isearch-regexp)) (run-hooks 'isearch-mode-end-hook) - (if isearch-recursive-edit (exit-recursive-edit))) + + (and (not edit) isearch-recursive-edit (exit-recursive-edit))) + +(defun isearch-update-ring (string &optional regexp) + "Add STRING to the beginning of the search ring. +REGEXP says which ring to use." + (if regexp + (if (or (null regexp-search-ring) + (not (string= string (car regexp-search-ring)))) + (progn + (setq regexp-search-ring + (cons string regexp-search-ring)) + (if (> (length regexp-search-ring) regexp-search-ring-max) + (setcdr (nthcdr (1- search-ring-max) regexp-search-ring) + nil)))) + (if (or (null search-ring) + (not (string= string (car search-ring)))) + (progn + (setq search-ring (cons string search-ring)) + (if (> (length search-ring) search-ring-max) + (setcdr (nthcdr (1- search-ring-max) search-ring) nil)))))) ;;;==================================================== @@ -607,12 +697,16 @@ is treated as a regexp. See \\[isearch-forward] for more info." (defun isearch-exit () "Exit search normally. However, if this is the first command after starting incremental -search and `search-nonincremental-instead' is non-nil, do an -incremental search via `isearch-edit-string'." +search and `search-nonincremental-instead' is non-nil, do a +nonincremental search instead via `isearch-edit-string'." (interactive) - (if (and search-nonincremental-instead + (if (and search-nonincremental-instead (= 0 (length isearch-string))) - (let ((isearch-nonincremental t)) + (let ((isearch-nonincremental t) + ;; Highlighting only gets in the way of nonincremental + ;; search. + (search-highlight nil) + (isearch-highlight-all-matches nil)) (isearch-edit-string)) (isearch-done))) @@ -621,115 +715,112 @@ incremental search via `isearch-edit-string'." "Edit the search string in the minibuffer. The following additional command keys are active while editing. \\ -\\[exit-minibuffer] to exit editing and resume incremental searching. +\\[exit-minibuffer] to resume incremental searching with the edited string. +\\[isearch-nonincremental-exit-minibuffer] to do one nonincremental search. \\[isearch-forward-exit-minibuffer] to resume isearching forward. -\\[isearch-backward-exit-minibuffer] to resume isearching backward. -\\[isearch-ring-advance-edit] to replace the search string with the next\ - item in the search ring. -\\[isearch-ring-retreat-edit] to replace the search string with the next\ - item in the search ring. -\\[isearch-complete-edit] to complete the search string from the search ring." +\\[isearch-reverse-exit-minibuffer] to resume isearching backward. +\\[isearch-ring-advance-edit] to replace the search string with the next item in the search ring. +\\[isearch-ring-retreat-edit] to replace the search string with the previous item in the search ring. +\\[isearch-complete-edit] to complete the search string using the search ring. +\\ +If first char entered is \\[isearch-yank-word], then do word search instead." + ;; This code is very hairy for several reasons, explained in the code. + ;; Mainly, isearch-mode must be terminated while editing and then restarted. + ;; If there were a way to catch any change of buffer from the minibuffer, + ;; this could be simplified greatly. ;; Editing doesn't back up the search point. Should it? (interactive) (condition-case nil - (let ((minibuffer-local-map minibuffer-local-isearch-map) - isearch-nonincremental ; should search nonincrementally? - isearch-new-string - isearch-new-message - (isearch-new-forward isearch-forward) - - ;; Locally bind all isearch global variables to protect them - ;; from recursive isearching. - (isearch-string isearch-string) - (isearch-message isearch-message) - (isearch-forward isearch-forward) ; set by commands below. - - (isearch-forward isearch-forward) - (isearch-regexp isearch-regexp) - (isearch-word isearch-word) - (isearch-op-fun isearch-op-fun) - (isearch-cmds isearch-cmds) - (isearch-success isearch-success) - (isearch-wrapped isearch-wrapped) - (isearch-barrier isearch-barrier) - (isearch-adjusted isearch-adjusted) - (isearch-yank-flag isearch-yank-flag) - (isearch-invalid-regexp isearch-invalid-regexp) - (isearch-other-end isearch-other-end) - (isearch-opoint isearch-opoint) - (isearch-slow-terminal-mode isearch-slow-terminal-mode) - (isearch-small-window isearch-small-window) - (isearch-recursive-edit isearch-recursive-edit) - (isearch-window-configuration (current-window-configuration)) - (isearch-selected-frame (selected-frame)) - ) - ;; Actually terminate isearching until editing is done. - ;; This is so that the user can do anything without failure, - ;; like switch buffers and start another isearch, and return. + (progn + (let ((isearch-nonincremental isearch-nonincremental) + + ;; Locally bind all isearch global variables to protect them + ;; from recursive isearching. + ;; isearch-string -message and -forward are not bound + ;; so they may be changed. Instead, save the values. + (isearch-new-string isearch-string) + (isearch-new-message isearch-message) + (isearch-new-forward isearch-forward) + (isearch-new-word isearch-word) + + (isearch-regexp isearch-regexp) + (isearch-op-fun isearch-op-fun) + (isearch-cmds isearch-cmds) + (isearch-success isearch-success) + (isearch-wrapped isearch-wrapped) + (isearch-barrier isearch-barrier) + (isearch-adjusted isearch-adjusted) + (isearch-fixed-case isearch-fixed-case) + (isearch-yank-flag isearch-yank-flag) + (isearch-invalid-regexp isearch-invalid-regexp) + (isearch-within-brackets isearch-within-brackets) + ;;; Don't bind this. We want isearch-search, below, to set it. + ;;; And the old value won't matter after that. + ;;; (isearch-other-end isearch-other-end) + (isearch-opoint isearch-opoint) + (isearch-slow-terminal-mode isearch-slow-terminal-mode) + (isearch-small-window isearch-small-window) + (isearch-recursive-edit isearch-recursive-edit) + (isearch-window-configuration (current-window-configuration)) + (isearch-selected-frame (selected-frame)) + ) + ;; Actually terminate isearching until editing is done. + ;; This is so that the user can do anything without failure, + ;; like switch buffers and start another isearch, and return. ;; (condition-case nil - (isearch-done) + (isearch-done t t) ;;#### What does this mean? There is no such condition! -;; (exit nil)) ; was recursive editing - - (unwind-protect - (let ((prompt (isearch-message-prefix nil t)) - event) - ;; If the first character the user types when we prompt them - ;; for a string is the yank-word character, then go into - ;; word-search mode. Otherwise unread that character and - ;; read a string the normal way. - (let ((cursor-in-echo-area t)) - (display-message 'prompt prompt) - (setq event (next-command-event)) - (if (eq 'isearch-yank-word - (lookup-key isearch-mode-map (vector event))) - (setq isearch-word t) - (setq unread-command-event event))) - (setq isearch-new-string -;; (if (fboundp 'gmhist-old-read-from-minibuffer) -;; ;; Eschew gmhist crockery -;; (gmhist-old-read-from-minibuffer prompt isearch-string) - (read-string - prompt isearch-string - 't ;does its own history (but shouldn't) -;; (if isearch-regexp -;; ;; The search-rings aren't exactly minibuffer -;; ;; histories, but they are close enough -;; (cons 'regexp-search-ring -;; (- (length regexp-search-ring-yank-pointer) -;; (length regexp-search-ring))) -;; (cons 'search-ring -;; (- (length search-ring-yank-pointer) -;; (length search-ring)))) - ) -;; ) - isearch-new-message (mapconcat - 'isearch-text-char-description - isearch-new-string "")) - ) - ;; Always resume isearching by restarting it. - (isearch-mode isearch-forward - isearch-regexp - isearch-op-fun - isearch-recursive-edit - isearch-word) - ) - - ;; Copy new values in outer locals to isearch globals - (setq isearch-string isearch-new-string - isearch-message isearch-new-message - isearch-forward isearch-new-forward) +;; (exit nil)) ; was recursive editing - ;; Empty isearch-string means use default. - (if (= 0 (length isearch-string)) - (setq isearch-string (if isearch-regexp search-last-regexp - search-last-string)) - ;; Set last search string now so it is set even if we fail. - (if search-last-regexp - (setq search-last-regexp isearch-string) - (setq search-last-string isearch-string))) + (unwind-protect + (progn + ;; Fake the prompt message for the sake of + ;; next-command-event below. + (isearch-message) + ;; If the first character the user types when we + ;; prompt them for a string is the yank-word + ;; character, then go into word-search mode. + ;; Otherwise unread that character and read a string + ;; the normal way. + (let* ((cursor-in-echo-area t) + (event (next-command-event))) + (if (eq 'isearch-yank-word + (lookup-key isearch-mode-map (vector event))) + (setq isearch-word t;; so message-prefix is right + isearch-new-word t) + (setq unread-command-event event))) + (setq isearch-new-string + (read-from-minibuffer + (isearch-message-prefix nil isearch-nonincremental) + isearch-string + minibuffer-local-isearch-map + nil + 't ;does its own history (but shouldn't) + ) + isearch-new-message (mapconcat + 'isearch-text-char-description + isearch-new-string ""))) + ;; Always resume isearching by restarting it. + (isearch-mode isearch-forward + isearch-regexp + isearch-op-fun + isearch-recursive-edit + isearch-word) + + ;; Copy new values in outer locals to isearch globals + (setq isearch-string isearch-new-string + isearch-message isearch-new-message + isearch-forward isearch-new-forward + isearch-word isearch-new-word)) + + ;; Empty isearch-string means use default. + (if (= 0 (length isearch-string)) + (setq isearch-string (or (car (if isearch-regexp + regexp-search-ring + search-ring)) + "")))) ;; Reinvoke the pending search. (isearch-push-state) @@ -756,25 +847,33 @@ The following additional command keys are active while editing. (setq isearch-new-forward nil) (exit-minibuffer)) +(defun isearch-cancel () + "Terminate the search and go back to the starting point." + (interactive) + (goto-char isearch-opoint) + (isearch-done t) + (signal 'quit '(isearch))) ; and pass on quit signal (defun isearch-abort () - "Quit incremental search mode if searching is successful, signalling quit. + "Abort incremental search mode if searching is successful, signaling quit. Otherwise, revert to previous successful search and continue searching. -Use `isearch-exit' to quit without signalling." +Use `isearch-exit' to quit without signaling." (interactive) -;; (ding) signal instead below, if quiting +;; (ding) signal instead below, if quitting (discard-input) (if isearch-success ;; If search is successful, move back to starting point ;; and really do quit. (progn (goto-char isearch-opoint) - (isearch-done) ; exit isearch + (setq isearch-success nil) + (isearch-done t) ; exit isearch (signal 'quit '(isearch))) ; and pass on quit signal - ;; If search is failing, rub out until it is once more successful. - (while (not isearch-success) (isearch-pop-state)) + ;; If search is failing, or has an incomplete regexp, + ;; rub out until it is once more successful. + (while (or (not isearch-success) isearch-invalid-regexp) + (isearch-pop-state)) (isearch-update))) - (defun isearch-repeat (direction) ;; Utility for isearch-repeat-forward and -backward. (if (eq isearch-forward (eq direction 'forward)) @@ -783,35 +882,30 @@ Use `isearch-exit' to quit without signalling." ;; If search string is empty, use last one. (setq isearch-string (or (if isearch-regexp - (if regexp-search-ring-yank-pointer - (car regexp-search-ring-yank-pointer) - (car regexp-search-ring)) - (if search-ring-yank-pointer - (car search-ring-yank-pointer) - (car search-ring))) + (car regexp-search-ring) + (car search-ring)) "") isearch-message (mapconcat 'isearch-text-char-description isearch-string "")) ;; If already have what to search for, repeat it. (or isearch-success - (progn - + (progn (goto-char (if isearch-forward (point-min) (point-max))) (setq isearch-wrapped t)))) ;; C-s in reverse or C-r in forward, change direction. (setq isearch-forward (not isearch-forward))) (setq isearch-barrier (point)) ; For subsequent \| if regexp. + (if (equal isearch-string "") (setq isearch-success t) - (if (and (equal (match-end 0) (match-beginning 0)) - isearch-success + (if (and isearch-success (equal (match-end 0) (match-beginning 0)) (not isearch-just-started)) ;; If repeating a search that found ;; an empty string, ensure we advance. (if (if isearch-forward (eobp) (bobp)) - ;; nowhere to advance to, so fail (and wrap next time) + ;; If there's nowhere to advance to, fail (and wrap next time). (progn (setq isearch-success nil) (and executing-kbd-macro @@ -821,6 +915,7 @@ Use `isearch-exit' to quit without signalling." (forward-char (if isearch-forward 1 -1)) (isearch-search)) (isearch-search))) + (isearch-push-state) (isearch-update)) @@ -845,18 +940,21 @@ Use `isearch-exit' to quit without signalling." (defun isearch-toggle-case-fold () "Toggle case folding in searching on or off." (interactive) - (setq isearch-case-fold-search - (if isearch-case-fold-search nil 'yes)) - (message "%s%s [case %ssensitive]" - (isearch-message-prefix) - isearch-message - (if isearch-case-fold-search "in" "")) + (setq isearch-case-fold-search (if isearch-case-fold-search nil 'yes) + isearch-fixed-case t) + (lmessage 'progress "%s%s [case %ssensitive]" + (isearch-message-prefix) + isearch-message + (if isearch-case-fold-search "in" "")) (setq isearch-adjusted t) + ;; Update the highlighting here so that it gets done before the + ;; one-second pause. + (isearch-highlight-all-update) (sit-for 1) (isearch-update)) (defun isearch-delete-char () - "Discard last input item and move point back. + "Discard last input item and move point back. If no previous match was done, just beep." (interactive) (if (null (cdr isearch-cmds)) @@ -876,6 +974,7 @@ backwards." (isearch-delete-char) (isearch-mode-help))) +;; This is similar to FSF isearch-yank-string, but more general. (defun isearch-yank (chunk) ;; Helper for isearch-yank-* functions. CHUNK can be a string or a ;; function. @@ -886,7 +985,7 @@ backwards." (goto-char isearch-other-end)) (buffer-substring (point) - (save-excursion + (progn (funcall chunk) (point))))))) ;; if configured so that typing upper-case characters turns off case @@ -904,7 +1003,6 @@ backwards." isearch-yank-flag t)) (isearch-search-and-update)) - (defun isearch-yank-word () "Pull next word from buffer into search string." (interactive) @@ -925,30 +1023,34 @@ backwards." (interactive) (isearch-yank 'forward-sexp)) -(defun isearch-yank-x-selection () - "Pull the current X selection into the search string." +(defun isearch-yank-selection () + "Pull the current selection into the search string." (interactive) - (isearch-yank (x-get-selection))) + (isearch-yank (get-selection))) -(defun isearch-yank-x-clipboard () - "Pull the current X clipboard selection into the search string." +(defun isearch-yank-clipboard () + "Pull the current clipboard selection into the search string." (interactive) - (isearch-yank (x-get-clipboard))) + (isearch-yank (get-clipboard))) (defun isearch-fix-case () - (if (and isearch-case-fold-search search-caps-disable-folding) - (setq isearch-case-fold-search + ;; The commented-out (and ...) form implies that, once + ;; isearch-case-fold-search becomes nil due to a capital letter + ;; typed in, it can never be restored to the original value. In + ;; that case, it's impossible to revert a case-sensitive search back + ;; to case-insensitive. + (if ;(and isearch-case-fold-search search-caps-disable-folding) + (and case-fold-search + ;; Make sure isearch-toggle-case-fold works. + (not isearch-fixed-case) + search-caps-disable-folding) + (setq isearch-case-fold-search (no-upper-case-p isearch-string isearch-regexp))) (setq isearch-mode (if case-fold-search (if isearch-case-fold-search " Isearch" ;As God Intended Mode " ISeARch") ;Warn about evil case via StuDLYcAps. - "Isearch" -; (if isearch-case-fold-search -; " isearch" ;Presumably case-sensitive losers -; ;will notice this 1-char difference. -; " Isearch") ;Weenie mode. - ))) + " Isearch"))) (defun isearch-search-and-update () ;; Do the search and update the display. @@ -972,16 +1074,17 @@ backwards." (regexp-quote isearch-string))))) (error nil)) (or isearch-yank-flag - (<= (match-end 0) + (<= (match-end 0) (min isearch-opoint isearch-barrier)))) - (setq isearch-success t + (setq isearch-success t isearch-invalid-regexp nil + isearch-within-brackets nil isearch-other-end (match-end 0)) ;; Not regexp, not reverse, or no match at point. (if (and isearch-other-end (not isearch-adjusted)) (goto-char (if isearch-forward isearch-other-end - (min isearch-opoint - isearch-barrier + (min isearch-opoint + isearch-barrier (1+ isearch-other-end))))) (isearch-search) )) @@ -991,31 +1094,34 @@ backwards." ;; *, ?, and | chars can make a regexp more liberal. -;; They can make a regexp match sooner -;; or make it succeed instead of failing. +;; They can make a regexp match sooner or make it succeed instead of failing. ;; So go back to place last successful search started ;; or to the last ^S/^R (barrier), whichever is nearer. +;; + needs no special handling because the string must match at least once. (defun isearch-*-char () "Handle * and ? specially in regexps." (interactive) - (if isearch-regexp - - (progn - (setq isearch-adjusted t) - (let ((cs (nth (if isearch-forward - 5 ; isearch-other-end - 2) ; saved (point) - (car (cdr isearch-cmds))))) + (if isearch-regexp + (let ((idx (length isearch-string))) + (while (and (> idx 0) + (eq (aref isearch-string (1- idx)) ?\\)) + (setq idx (1- idx))) + (when (= (mod (- (length isearch-string) idx) 2) 0) + (setq isearch-adjusted t) + ;; Get the isearch-other-end from before the last search. + ;; We want to start from there, + ;; so that we don't retreat farther than that. ;; (car isearch-cmds) is after last search; ;; (car (cdr isearch-cmds)) is from before it. - (setq cs (or cs isearch-barrier)) - (goto-char - (if isearch-forward - (max cs isearch-barrier) - (min cs isearch-barrier)))))) + (let ((cs (nth 5 (car (cdr isearch-cmds))))) + (setq cs (or cs isearch-barrier)) + (goto-char + (if isearch-forward + (max cs isearch-barrier) + (min cs isearch-barrier))))))) (isearch-process-search-char last-command-event)) - + (defun isearch-|-char () @@ -1027,42 +1133,59 @@ backwards." (goto-char isearch-barrier))) (isearch-process-search-char last-command-event)) +;; FSF: +;(defalias 'isearch-other-control-char 'isearch-other-meta-char) +; +;(defun isearch-other-meta-char () +;... +; + (defun isearch-quote-char () "Quote special characters for incremental search." (interactive) + ;; #### Here FSF does some special conversion of chars in 0200-0377 + ;; range. Maybe we should do the same. (isearch-process-search-char (read-quoted-char (isearch-message t)))) - (defun isearch-return-char () "Convert return into newline for incremental search. Obsolete." (interactive) (isearch-process-search-char ?\n)) - (defun isearch-printing-char () - "Any other printing character => add it to the search string and search." + "Add this ordinary printing character to the search string and search." (interactive) - (isearch-process-search-char last-command-event)) - + (let ((event last-command-event)) + ;; If we are called by isearch-whitespace-chars because the + ;; context disallows whitespace search (e.g. within brackets), + ;; replace M-SPC with a space. FSF has similar code. + (and (eq this-command 'isearch-whitespace-chars) + (null (event-to-character event)) + (setq event (character-to-event ?\ ))) + (isearch-process-search-char event))) (defun isearch-whitespace-chars () "Match all whitespace chars, if in regexp mode." + ;; FSF docstring adds: "If you want to search for just a space, type + ;; C-q SPC." But we don't need the addition because we have a + ;; different (better) default for the variable. (interactive) - (if (and isearch-regexp search-whitespace-regexp) - (isearch-process-search-string search-whitespace-regexp " ") - (beep) - (isearch-process-search-char ?\ ) -; (if isearch-word -; nil -; (setq isearch-word t) -; (goto-char isearch-other-end) -; (isearch-process-search-char ?\ )) - )) + (if isearch-regexp + (if (and search-whitespace-regexp (not isearch-within-brackets) + (not isearch-invalid-regexp)) + (isearch-process-search-string search-whitespace-regexp " ") + (isearch-printing-char)) + (progn + ;; This way of doing word search doesn't correctly extend current search. + ;; (setq isearch-word t) + ;; (setq isearch-adjusted t) + ;; (goto-char isearch-barrier) + (isearch-printing-char)))) (defun isearch-process-search-char (char) ;; Append the char to the search string, update the message and re-search. - (isearch-process-search-string (isearch-char-to-string char) + (isearch-process-search-string (isearch-char-to-string char) (isearch-text-char-description char))) (defun isearch-process-search-string (string message) @@ -1074,12 +1197,6 @@ Obsolete." ;;=========================================================== ;; Search Ring -(defcustom search-ring-update nil - "*Non-nil if advancing or retreating in the search ring should cause search. -Default nil means edit the string from the search ring first." - :type 'boolean - :group 'isearch) - (defun isearch-ring-adjust1 (advance) ;; Helper for isearch-ring-adjust (let* ((ring (if isearch-regexp regexp-search-ring search-ring)) @@ -1092,25 +1209,25 @@ Default nil means edit the string from the search ring first." () (set yank-pointer-name (setq yank-pointer - (nthcdr (% (+ (- length (length yank-pointer)) - (if advance (1- length) 1)) - length) ring))) - (setq isearch-string (car yank-pointer) + (mod (+ (or yank-pointer 0) + (if advance -1 1)) + length))) + (setq isearch-string (nth yank-pointer ring) isearch-message (mapconcat 'isearch-text-char-description isearch-string ""))))) (defun isearch-ring-adjust (advance) ;; Helper for isearch-ring-advance and isearch-ring-retreat - (if (cdr isearch-cmds) ;; is there more than one thing on stack? - (isearch-pop-state)) +; (if (cdr isearch-cmds) ;; is there more than one thing on stack? +; (isearch-pop-state)) (isearch-ring-adjust1 advance) - (isearch-push-state) (if search-ring-update (progn (isearch-search) (isearch-update)) (isearch-edit-string) - )) + ) + (isearch-push-state)) (defun isearch-ring-advance () "Advance to the next search string in the ring." @@ -1123,30 +1240,59 @@ Default nil means edit the string from the search ring first." (interactive) (isearch-ring-adjust nil)) -(defun isearch-ring-adjust-edit (advance) - "Use the next or previous search string in the ring while in minibuffer." - (isearch-ring-adjust1 advance) - (erase-buffer) - (insert isearch-string)) +(defun isearch-ring-advance-edit (n) + "Insert the next element of the search history into the minibuffer." + (interactive "p") + (let* ((yank-pointer-name (if isearch-regexp + 'regexp-search-ring-yank-pointer + 'search-ring-yank-pointer)) + (yank-pointer (eval yank-pointer-name)) + (ring (if isearch-regexp regexp-search-ring search-ring)) + (length (length ring))) + (if (zerop length) + () + (set yank-pointer-name + (setq yank-pointer + (mod (- (or yank-pointer 0) n) + length))) -(defun isearch-ring-advance-edit () - (interactive) - (isearch-ring-adjust-edit 'advance)) + (erase-buffer) + (insert (nth yank-pointer ring)) + (goto-char (point-max))))) -(defun isearch-ring-retreat-edit () - "Retreat to the previous search string in the ring while in the minibuffer." - (interactive) - (isearch-ring-adjust-edit nil)) +(defun isearch-ring-retreat-edit (n) + "Inserts the previous element of the search history into the minibuffer." + (interactive "p") + (isearch-ring-advance-edit (- n))) + +;; Merging note: FSF comments out these functions and implements them +;; differently (see above), presumably because the versions below mess +;; with isearch-string, while what we really want them to do is simply +;; to insert the correct string to the minibuffer. + +;;(defun isearch-ring-adjust-edit (advance) +;; "Use the next or previous search string in the ring while in minibuffer." +;; (isearch-ring-adjust1 advance) +;; (erase-buffer) +;; (insert isearch-string)) + +;;(defun isearch-ring-advance-edit () +;; (interactive) +;; (isearch-ring-adjust-edit 'advance)) + +;;(defun isearch-ring-retreat-edit () +;; "Retreat to the previous search string in the ring while in the minibuffer." +;; (interactive) +;; (isearch-ring-adjust-edit nil)) (defun isearch-complete1 () ;; Helper for isearch-complete and isearch-complete-edit - ;; Return t if completion OK, + ;; Return t if completion OK, nil if no completion exists. (let* ((ring (if isearch-regexp regexp-search-ring search-ring)) (alist (mapcar (function (lambda (string) (list string))) ring)) (completion-ignore-case case-fold-search) - (completion (try-completion isearch-string alist)) - ) + (completion (try-completion isearch-string alist))) (cond ((eq completion t) ;; isearch-string stays the same @@ -1154,12 +1300,14 @@ Default nil means edit the string from the search ring first." ((or completion ; not nil, must be a string (= 0 (length isearch-string))) ; shouldn't have to say this (if (equal completion isearch-string) ;; no extension? - (if completion-auto-help - (with-output-to-temp-buffer "*Isearch completions*" - (display-completion-list - (all-completions isearch-string alist)))) - (setq isearch-string completion)) - t) + (progn + (if completion-auto-help + (with-output-to-temp-buffer "*Isearch completions*" + (display-completion-list + (all-completions isearch-string alist)))) + t) + (and completion + (setq isearch-string completion)))) (t (temp-minibuffer-message "No completion") nil)))) @@ -1186,32 +1334,61 @@ If there is no completion possible, say so and continue searching." ;;;============================================================== -;; The search status stack (and isearch window-local variables, not used). +;; The search status stack. (defun isearch-top-state () -;; (fetch-window-local-variables) (let ((cmd (car isearch-cmds))) + ;; #### Grr, this is so error-prone. If you add something to + ;; isearch-push-state, don't forget to update this. I thout I'd + ;; make a list of variables, and just do (mapcar* #'set vars + ;; values), but the (point) thing would spoil it, leaving to more + ;; complication. (setq isearch-string (car cmd) isearch-message (car (cdr cmd)) isearch-success (nth 3 cmd) isearch-forward (nth 4 cmd) isearch-other-end (nth 5 cmd) - isearch-invalid-regexp (nth 6 cmd) - isearch-wrapped (nth 7 cmd) - isearch-barrier (nth 8 cmd)) + isearch-word (nth 6 cmd) + isearch-invalid-regexp (nth 7 cmd) + isearch-wrapped (nth 8 cmd) + isearch-barrier (nth 9 cmd) + isearch-within-brackets (nth 10 cmd)) (goto-char (car (cdr (cdr cmd)))))) (defun isearch-pop-state () -;; (fetch-window-local-variables) - (setq isearch-cmds (cdr isearch-cmds)) + (pop isearch-cmds) (isearch-top-state) - ) + + ;; Make sure isearch-case-fold-search gets the correct value. FSF + ;; simply stores isearch-case-fold-search to isearch-cmds. We + ;; should probably do the same. + (isearch-fix-case) + + ;; Here, as well as in isearch-search we must deal with the point + ;; landing at an invisible area which may need unhiding. + (if (or (not (eq search-invisible 'open)) + (not isearch-hide-immediately)) + ;; If search-invisible is t, invisible text is just like any + ;; other text. If it is nil, it is always skipped and we can't + ;; land inside. In both cases, we don't need to do anything. + ;; + ;; Similarly, if isearch-hide-immediately is nil, needn't + ;; re-hide the area here, and neither can we land back into a + ;; hidden one. + nil + (when isearch-other-end + ;; This will unhide the extents. + (isearch-range-invisible (point) isearch-other-end)) + (isearch-restore-invisible-extents (point) + (or isearch-other-end (point))))) (defun isearch-push-state () - (setq isearch-cmds + (setq isearch-cmds (cons (list isearch-string isearch-message (point) - isearch-success isearch-forward isearch-other-end - isearch-invalid-regexp isearch-wrapped isearch-barrier) + isearch-success isearch-forward isearch-other-end + isearch-word + isearch-invalid-regexp isearch-wrapped isearch-barrier + isearch-within-brackets) isearch-cmds))) @@ -1222,27 +1399,41 @@ If there is no completion possible, say so and continue searching." ;; Generate and print the message string. (let ((cursor-in-echo-area ellipsis) (m (concat - (isearch-message-prefix c-q-hack) + (isearch-message-prefix c-q-hack ellipsis isearch-nonincremental) isearch-message - (isearch-message-suffix c-q-hack) + (isearch-message-suffix c-q-hack ellipsis) ))) - (if c-q-hack m (display-message 'progress (format "%s" m))))) + (if c-q-hack + m + (display-message 'progress (format "%s" m))))) -(defun isearch-message-prefix (&optional c-q-hack nonincremental) +(defun isearch-message-prefix (&optional c-q-hack ellipsis nonincremental) ;; If about to search, and previous search regexp was invalid, ;; check that it still is. If it is valid now, ;; let the message we display while searching say that it is valid. - (and isearch-invalid-regexp + (and isearch-invalid-regexp ellipsis (condition-case () (progn (re-search-forward isearch-string (point) t) - (setq isearch-invalid-regexp nil)) + (setq isearch-invalid-regexp nil + isearch-within-brackets nil)) (error nil))) - ;; #### - Yo! Emacs assembles strings all over the place, they can't all - ;; be internationalized in the manner proposed below... Add an explicit - ;; call to `gettext' and have the string snarfer pluck the english - ;; strings out of the comment below. XEmacs is on a purespace diet! -Stig + ;; If currently failing, display no ellipsis. + (or isearch-success (setq ellipsis nil)) + ;; #### - ! Emacs assembles strings all over the place, they can't + ;; all be internationalized in the manner proposed below... Add an + ;; explicit call to `gettext' and have the string snarfer pluck the + ;; english strings out of the comment below. XEmacs is on a + ;; purespace diet! -Stig + + ;; The comment below is dead and buried, but it can be rebuilt if + ;; necessary. -hniksic (let ((m (concat (if isearch-success nil "failing ") - (if isearch-wrapped "wrapped ") + (if (and isearch-wrapped + (if isearch-forward + (> (point) isearch-opoint) + (< (point) isearch-opoint))) + "overwrapped " + (if isearch-wrapped "wrapped ")) (if isearch-word "word ") (if isearch-regexp "regexp ") (if nonincremental "search" "I-search") @@ -1252,14 +1443,12 @@ If there is no completion possible, say so and continue searching." (aset m 0 (upcase (aref m 0))) (gettext m))) -(defun isearch-message-suffix (&optional c-q-hack) +(defun isearch-message-suffix (&optional c-q-hack ellipsis) (concat (if c-q-hack "^Q" "") (if isearch-invalid-regexp (concat " [" isearch-invalid-regexp "]") ""))) -;;;;; #### - yuck...this is soooo lame. Is this really worth 4k of purespace??? -;;; ;;;(let ((i (logior (if isearch-success 32 0) ;;; (if isearch-wrapped 16 0) ;;; (if isearch-word 8 0) @@ -1268,68 +1457,7 @@ If there is no completion possible, say so and continue searching." ;;; (if isearch-forward 1 0)))) ;;; (cond ;;; ((= i 63) (gettext "Wrapped word regexp search: ")) ; 111111 -;;; ((= i 62) (gettext "Wrapped word regexp search backward: ")) ; 111110 -;;; ((= i 61) (gettext "Wrapped word regexp I-search: ")) ; 111101 -;;; ((= i 60) (gettext "Wrapped word regexp I-search backward: ")) ; 111100 -;;; ((= i 59) (gettext "Wrapped word search: ")) ; 111011 -;;; ((= i 58) (gettext "Wrapped word search backward: ")) ; 111010 -;;; ((= i 57) (gettext "Wrapped word I-search: ")) ; 111001 -;;; ((= i 56) (gettext "Wrapped word I-search backward: ")) ; 111000 -;;; ((= i 55) (gettext "Wrapped regexp search: ")) ; 110111 -;;; ((= i 54) (gettext "Wrapped regexp search backward: ")) ; 110110 -;;; ((= i 53) (gettext "Wrapped regexp I-search: ")) ; 110101 -;;; ((= i 52) (gettext "Wrapped regexp I-search backward: ")) ; 110100 -;;; ((= i 51) (gettext "Wrapped search: ")) ; 110011 -;;; ((= i 50) (gettext "Wrapped search backward: ")) ; 110010 -;;; ((= i 49) (gettext "Wrapped I-search: ")) ; 110001 -;;; ((= i 48) (gettext "Wrapped I-search backward: ")) ; 110000 -;;; ((= i 47) (gettext "Word regexp search: ")) ; 101111 -;;; ((= i 46) (gettext "Word regexp search backward: ")) ; 101110 -;;; ((= i 45) (gettext "Word regexp I-search: ")) ; 101101 -;;; ((= i 44) (gettext "Word regexp I-search backward: ")) ; 101100 -;;; ((= i 43) (gettext "Word search: ")) ; 101011 -;;; ((= i 42) (gettext "Word search backward: ")) ; 101010 -;;; ((= i 41) (gettext "Word I-search: ")) ; 101001 -;;; ((= i 40) (gettext "Word I-search backward: ")) ; 101000 -;;; ((= i 39) (gettext "Regexp search: ")) ; 100111 -;;; ((= i 38) (gettext "Regexp search backward: ")) ; 100110 -;;; ((= i 37) (gettext "Regexp I-search: ")) ; 100101 -;;; ((= i 36) (gettext "Regexp I-search backward: ")) ; 100100 -;;; ((= i 35) (gettext "Search: ")) ; 100011 -;;; ((= i 34) (gettext "Search backward: ")) ; 100010 -;;; ((= i 33) (gettext "I-search: ")) ; 100001 -;;; ((= i 32) (gettext "I-search backward: ")) ; 100000 -;;; ((= i 31) (gettext "Failing wrapped word regexp search: ")) ; 011111 -;;; ((= i 30) (gettext "Failing wrapped word regexp search backward: ")) ; 011110 -;;; ((= i 29) (gettext "Failing wrapped word regexp I-search: ")) ; 011101 -;;; ((= i 28) (gettext "Failing wrapped word regexp I-search backward: ")) ; 011100 -;;; ((= i 27) (gettext "Failing wrapped word search: ")) ; 011011 -;;; ((= i 26) (gettext "Failing wrapped word search backward: ")) ; 011010 -;;; ((= i 25) (gettext "Failing wrapped word I-search: ")) ; 011001 -;;; ((= i 24) (gettext "Failing wrapped word I-search backward: ")) ; 011000 -;;; ((= i 23) (gettext "Failing wrapped regexp search: ")) ; 010111 -;;; ((= i 22) (gettext "Failing wrapped regexp search backward: ")) ; 010110 -;;; ((= i 21) (gettext "Failing wrapped regexp I-search: ")) ; 010101 -;;; ((= i 20) (gettext "Failing wrapped regexp I-search backward: ")) ; 010100 -;;; ((= i 19) (gettext "Failing wrapped search: ")) ; 010011 -;;; ((= i 18) (gettext "Failing wrapped search backward: ")) ; 010010 -;;; ((= i 17) (gettext "Failing wrapped I-search: ")) ; 010001 -;;; ((= i 16) (gettext "Failing wrapped I-search backward: ")) ; 010000 -;;; ((= i 15) (gettext "Failing word regexp search: ")) ; 001111 -;;; ((= i 14) (gettext "Failing word regexp search backward: ")) ; 001110 -;;; ((= i 13) (gettext "Failing word regexp I-search: ")) ; 001101 -;;; ((= i 12) (gettext "Failing word regexp I-search backward: ")) ; 001100 -;;; ((= i 11) (gettext "Failing word search: ")) ; 001011 -;;; ((= i 10) (gettext "Failing word search backward: ")) ; 001010 -;;; ((= i 9) (gettext "Failing word I-search: ")) ; 001001 -;;; ((= i 8) (gettext "Failing word I-search backward: ")) ; 001000 -;;; ((= i 7) (gettext "Failing regexp search: ")) ; 000111 -;;; ((= i 6) (gettext "Failing regexp search backward: ")) ; 000110 -;;; ((= i 5) (gettext "Failing regexp I-search: ")) ; 000101 -;;; ((= i 4) (gettext "Failing regexp I-search backward: ")) ; 000100 -;;; ((= i 3) (gettext "Failing search: ")) ; 000011 -;;; ((= i 2) (gettext "Failing search backward: ")) ; 000010 -;;; ((= i 1) (gettext "Failing I-search: ")) ; 000001 +;;; ...and so on, ad nauseam... ;;; ((= i 0) (gettext "Failing I-search backward: ")) ; 000000 ;;; (t (error "Something's rotten"))))) @@ -1343,6 +1471,7 @@ If there is no completion possible, say so and continue searching." (put 'isearch-repeat-backward 'isearch-command t) (put 'isearch-delete-char 'isearch-command t) (put 'isearch-help-or-delete-char 'isearch-command t) +(put 'isearch-cancel 'isearch-command t) (put 'isearch-abort 'isearch-command t) (put 'isearch-quote-char 'isearch-command t) (put 'isearch-exit 'isearch-command t) @@ -1371,6 +1500,8 @@ If there is no completion possible, say so and continue searching." (put 'isearch-forward-exit-minibuffer 'isearch-command t) (put 'isearch-reverse-exit-minibuffer 'isearch-command t) (put 'isearch-nonincremental-exit-minibuffer 'isearch-command t) +(put 'isearch-yank-selection 'isearch-command t) +(put 'isearch-yank-clipboard 'isearch-command t) (put 'isearch-yank-x-selection 'isearch-command t) (put 'isearch-yank-x-clipboard 'isearch-command t) @@ -1408,11 +1539,24 @@ If there is no completion possible, say so and continue searching." ;; (cond ((not (eq (current-buffer) isearch-buffer)) ;; If the buffer (likely meaning "frame") has changed, bail. - ;; This can also happen if a proc filter has popped up another - ;; buffer, which is arguably a bad thing for it to have done, - ;; but the way in which isearch would have hosed you in that - ;; case is unarguably even worse. -jwz - (isearch-done)) + ;; This can happen if the user types something into another + ;; frame. It can also happen if a proc filter has popped up + ;; another buffer, which is arguably a bad thing for it to + ;; have done, but the way in which isearch would have hosed + ;; you in that case is unarguably even worse. -jwz + (isearch-done) + + ;; `this-command' is set according to the value of + ;; `overriding-local-map', set by isearch-mode. This is + ;; wrong because that keymap makes sense only in isearch + ;; buffer. To make sure the right command is called, adjust + ;; `this-command' to the appropriate value, now that + ;; `isearch-done' has set `overriding-local-map' to nil. + + ;; FSF does similar magic in `isearch-other-meta-char', which + ;; is horribly complex. I *hope* what we do works in all + ;; cases. + (setq this-command (key-binding (this-command-keys)))) (t (isearch-maybe-frob-keyboard-macros) (if (and this-command @@ -1453,15 +1597,10 @@ If there is no completion possible, say so and continue searching." ;;;======================================================== ;;; Highlighting -(defcustom isearch-highlight t - "*Whether isearch and query-replace should highlight the text which -currently matches the search-string.") - (defvar isearch-extent nil) -;; this face is initialized by x-faces.el since isearch is preloaded. -;; this face is now created in initialize-faces -;;(make-face 'isearch) +;; this face is initialized by faces.el since isearch is preloaded. +;(make-face 'isearch) (defun isearch-make-extent (begin end) (let ((x (make-extent begin end (current-buffer)))) @@ -1469,28 +1608,28 @@ currently matches the search-string.") ;; highlighted extents we may be passing through, since isearch, being ;; modal, is more interesting (there's nothing they could do with a ;; mouse-highlighted extent while in the midst of a search anyway). - (set-extent-priority x (1+ mouse-highlight-priority)) + (set-extent-priority x (+ mouse-highlight-priority 2)) (set-extent-face x 'isearch) (setq isearch-extent x))) (defun isearch-highlight (begin end) - (if (null isearch-highlight) + (if (null search-highlight) nil ;; make sure isearch-extent is in the current buffer - (or (extentp isearch-extent) + (or (and (extentp isearch-extent) + (extent-live-p isearch-extent)) (isearch-make-extent begin end)) (set-extent-endpoints isearch-extent begin end (current-buffer)))) -(defun isearch-dehighlight (totally) - (if (and isearch-highlight isearch-extent) - (if totally - (let ((inhibit-quit t)) - (if (extentp isearch-extent) - (delete-extent isearch-extent)) - (setq isearch-extent nil)) - (if (extentp isearch-extent) - (detach-extent isearch-extent) - (setq isearch-extent nil))))) +;; This used to have a TOTALLY flag that also deleted the extent. I +;; don't think this is necessary any longer, as isearch-highlight can +;; simply move the extent to another buffer. The IGNORED argument is +;; for the code that calls this function with an argument. --hniksic +(defun isearch-dehighlight (&optional ignored) + (and search-highlight + (extentp isearch-extent) + (extent-live-p isearch-extent) + (detach-extent isearch-extent))) ;;;======================================================== @@ -1502,33 +1641,54 @@ currently matches the search-string.") (isearch-fix-case) (condition-case lossage (let ((inhibit-quit nil) - (case-fold-search isearch-case-fold-search)) + (case-fold-search isearch-case-fold-search) + (retry t)) (if isearch-regexp (setq isearch-invalid-regexp nil)) - (setq isearch-success - (funcall - (cond (isearch-word - (if isearch-forward - 'word-search-forward 'word-search-backward)) - (isearch-regexp - (if isearch-forward - 're-search-forward 're-search-backward)) - (t - (if isearch-forward 'search-forward 'search-backward))) - isearch-string nil t)) + (setq isearch-within-brackets nil) + (while retry + (setq isearch-success + (funcall + (cond (isearch-word + (if isearch-forward + 'word-search-forward 'word-search-backward)) + (isearch-regexp + (if isearch-forward + 're-search-forward 're-search-backward)) + (t + (if isearch-forward 'search-forward 'search-backward))) + isearch-string nil t)) + ;; Clear RETRY unless we matched some invisible text + ;; and we aren't supposed to do that. + (if (or (eq search-invisible t) + (not isearch-success) + (bobp) (eobp) + (= (match-beginning 0) (match-end 0)) + (not (isearch-range-invisible + (match-beginning 0) (match-end 0)))) + (setq retry nil))) (setq isearch-just-started nil) - (if isearch-success - (setq isearch-other-end - (if isearch-forward (match-beginning 0) (match-end 0))))) - - (quit (setq unread-command-event (character-to-event (quit-char))) + (when isearch-success + (setq isearch-other-end + (if isearch-forward (match-beginning 0) (match-end 0))) + (and isearch-hide-immediately + (isearch-restore-invisible-extents (match-beginning 0) + (match-end 0))))) + + (quit (setq unread-command-events (nconc unread-command-events + (character-to-event (quit-char)))) (setq isearch-success nil)) - (invalid-regexp + (invalid-regexp (setq isearch-invalid-regexp (car (cdr lossage))) + (setq isearch-within-brackets (string-match "\\`Unmatched \\[" + isearch-invalid-regexp)) (if (string-match "\\`Premature \\|\\`Unmatched \\|\\`Invalid " isearch-invalid-regexp) - (setq isearch-invalid-regexp (gettext "incomplete input"))))) + (setq isearch-invalid-regexp (gettext "incomplete input")))) + (error + ;; stack overflow in regexp search. + (setq isearch-invalid-regexp (car (cdr lossage))))) (if isearch-success nil @@ -1548,59 +1708,79 @@ currently matches the search-string.") (ding nil 'isearch-failed)) (goto-char (nth 2 (car isearch-cmds))))) -;;;================================================= -;; This is called from incremental-search -;; if the first input character is the exit character. - -;; We store the search string in `isearch-string' -;; which has been bound already by `isearch-search' -;; so that, when we exit, it is copied into `search-last-string'. - +;; Replaced with isearch-edit-string. ;(defun nonincremental-search (forward regexp) -; ;; This may be broken. Anyway, it is replaced by the isearch-edit-string. -; ;; Missing features: word search option, command history. -; (setq isearch-forward forward -; isearch-regexp regexp) -; (let (char function -; inhibit-quit -; (cursor-in-echo-area t)) -; ;; Prompt assuming not word search, -; (setq isearch-message -; (if isearch-regexp -; (if isearch-forward "Regexp search: " -; "Regexp search backward: ") -; (if isearch-forward "Search: " "Search backward: "))) -; (message "%s" isearch-message) -; ;; Read 1 char and switch to word search if it is ^W. -; (setq char (read-char)) -; (if (eq char search-yank-word-char) -; (setq isearch-message (if isearch-forward "Word search: " -; "Word search backward: ")) -; ;; Otherwise let that 1 char be part of the search string. -; (setq unread-command-event (character-to-event char)) -; ) -; (setq function -; (if (eq char search-yank-word-char) -; (if isearch-forward 'word-search-forward 'word-search-backward) -; (if isearch-regexp -; (if isearch-forward 're-search-forward 're-search-backward) -; (if isearch-forward 'search-forward 'search-backward)))) -; ;; Read the search string with corrected prompt. -; (setq isearch-string (read-string isearch-message isearch-string)) -; ;; Empty means use default. -; (if (= 0 (length isearch-string)) -; (setq isearch-string search-last-string) -; ;; Set last search string now so it is set even if we fail. -; (setq search-last-string isearch-string)) -; ;; Since we used the minibuffer, we should be available for redo. -; (setq command-history -; (cons (list function isearch-string) command-history)) -; ;; Go ahead and search. -; (if search-caps-disable-folding -; (setq isearch-case-fold-search -; (no-upper-case-p isearch-string isearch-regexp))) -; (let ((case-fold-search isearch-case-fold-search)) -; (funcall function isearch-string)))) +;... + +(defun isearch-unhide-extent (extent) + ;; Store the values for the `invisible' and `intangible' + ;; properties, and then set them to nil. This way the text hidden + ;; by this extent becomes visible. + (put extent 'isearch-invisible (get extent 'invisible)) + (put extent 'isearch-intangible (get extent 'intangible)) + (put extent 'invisible nil) + (put extent 'intangible nil)) + +(defun isearch-range-invisible (beg end) + "Return t if all the text from BEG to END is invisible. +Before that, if search-invisible is `open', unhide the extents with an +`isearch-open-invisible' property." + ;; isearch-search uses this to skip the extents that are invisible, + ;; but don't have `isearch-open-invisible' set. It is unclear + ;; what's supposed to happen if only a part of [BEG, END) overlaps + ;; the extent. + (let (to-be-unhidden) + (if (map-extents + (lambda (extent ignored) + (if (and (<= (extent-start-position extent) beg) + (>= (extent-end-position extent) end)) + ;; All of the region is covered by the extent. + (if (and (eq search-invisible 'open) + (get extent 'isearch-open-invisible)) + (progn + (push extent to-be-unhidden) + nil) ; keep mapping + ;; We can't or won't unhide this extent, so we must + ;; skip the whole match. We return from map-extents + ;; immediately. + t) + ;; Else, keep looking. + nil)) + nil beg end nil 'all-extents-closed 'invisible) + ;; The whole match must be skipped. Signal it by returning t + ;; to the caller. + t + ;; If any extents need to be unhidden, unhide them. + (mapc #'isearch-unhide-extent to-be-unhidden) + ;; Will leave this assert for some time, to catch bugs. + (assert (null (intersection to-be-unhidden isearch-unhidden-extents))) + (setq isearch-unhidden-extents (nconc to-be-unhidden + isearch-unhidden-extents)) + nil))) + +(defun isearch-restore-extent (extent) + (put extent 'invisible (get extent 'isearch-invisible)) + (put extent 'intangible (get extent 'isearch-intangible)) + (remprop extent 'isearch-invisible) + (remprop extent 'isearch-intangible)) + +;; FSF calls this function `isearch-clean-overlays'. +(defun isearch-restore-invisible-extents (beg end) + (cond + ((null beg) + ;; Delete all -- this is called at the end of isearch. + (mapc #'isearch-restore-extent isearch-unhidden-extents) + (setq isearch-unhidden-extents nil)) + (t + ;; Extents that do not overlap the match area can be safely + ;; restored to their hidden state. + (setq isearch-unhidden-extents + (delete-if (lambda (extent) + (unless (extent-in-region-p extent beg end + 'all-extents-closed) + (isearch-restore-extent extent) + t)) + isearch-unhidden-extents))))) (defun isearch-no-upper-case-p (string) "Return t if there are no upper case chars in string. @@ -1611,6 +1791,18 @@ have special meaning in a regexp." (not (string-match "\\(^\\|[^\\]\\)[A-Z]" string)))) (make-obsolete 'isearch-no-upper-case-p 'no-upper-case-p) +;; Portability functions to support various Emacs versions. + +(defun isearch-char-to-string (c) + (if (eventp c) + (make-string 1 (event-to-character c nil nil t)) + (make-string 1 c))) + +;(defun isearch-text-char-description (c) +; (isearch-char-to-string c)) + +(define-function 'isearch-text-char-description 'text-char-description) + ;; Used by etags.el and info.el (defmacro with-caps-disable-folding (string &rest body) "\ Eval BODY with `case-fold-search' let to nil if STRING contains @@ -1624,4 +1816,204 @@ uppercase letters and `search-caps-disable-folding' is t." (put 'with-caps-disable-folding 'lisp-indent-function 1) (put 'with-caps-disable-folding 'edebug-form-spec '(form body)) + +;;;======================================================== +;;; Advanced highlighting + +;; When active, *every* visible match for the current search string is +;; highlighted: the current one using the normal isearch match color +;; and all the others using the `isearch-secondary' face. The extra +;; highlighting makes it easier to anticipate where the cursor will +;; land each time you press C-s or C-r to repeat a pending search. +;; Only the matches visible at any point are highlighted -- when you +;; move through the buffer, the highlighting is readjusted. + +;; This is based on ideas from Bob Glickstein's `ishl' package. It +;; has been merged with XEmacs by Darryl Okahata, and then completely +;; rewritten by Hrvoje Niksic. + +;; The code makes the following assumptions about the rest of this +;; file, so be careful when modifying it. + +;; * `isearch-highlight-all-update' should get called when the search +;; string changes, or when the search advances. This is done from +;; `isearch-update'. +;; * `isearch-highlight-all-cleanup' should get called when the search +;; is done. This is performed in `isearch-done'. +;; * `isearch-string' is expected to contain the current search string +;; as entered by the user. +;; * `isearch-opoint' is expected to contain the location where the +;; current search began. +;; * the type of the current search is expected to be given by +;; `isearch-word' and `isearch-regexp'. +;; * the variable `isearch-invalid-regexp' is expected to be true iff +;; `isearch-string' is an invalid regexp. + +(defcustom isearch-highlight-all-matches search-highlight + "*Non-nil means highlight all visible matches." + :type 'boolean + :group 'isearch) + +;; We can't create this face here, as isearch.el is preloaded. +;; #### Think up a better name for this! +;(defface isearch-secondary '((t (:foreground "red3"))) +; "Face to use for highlighting all matches." +; :group 'isearch) + +(defvar isearch-highlight-extents nil) +(defvar isearch-window-start nil) +(defvar isearch-window-end nil) +;; We compare isearch-string and isearch-case-fold-search to saved +;; values for better efficiency. +(defvar isearch-highlight-last-string nil) +(defvar isearch-highlight-last-case-fold-search nil) +(defvar isearch-highlight-last-regexp nil) + +(defun isearch-delete-extents-in-range (start end) + ;; Delete all highlighting extents that overlap [START, END). + (setq isearch-highlight-extents + (delete-if (lambda (extent) + (when (extent-in-region-p extent start end) + (delete-extent extent) + t)) + isearch-highlight-extents))) + +(defun isearch-highlight-all-cleanup () + ;; Stop lazily highlighting and remove extra highlighting from + ;; buffer. + (mapc #'delete-extent isearch-highlight-extents) + (setq isearch-highlight-extents nil) + (setq isearch-highlight-all-start nil + isearch-window-end nil + isearch-highlight-last-string nil)) + +(defun isearch-highlight-all-update () + ;; Update the highlighting if necessary. This needs to check if the + ;; search string has changed, or if the window has changed position + ;; in the buffer. + (let ((need-start-over nil)) + ;; NB: we don't check for isearch-success because if the point is + ;; after the last match, the search can be unsuccessful, and yet + ;; there are things to highlight. + (cond ((not isearch-highlight-all-matches)) + ((or (equal isearch-string "") + isearch-invalid-regexp) + (isearch-highlight-all-cleanup)) + ((not (eq isearch-case-fold-search + isearch-highlight-last-case-fold-search)) + ;; This case is usually caused by search string being + ;; changed, which would be caught below, but it can also be + ;; tripped using isearch-toggle-case-fold. + (setq need-start-over t)) + ((not (eq isearch-regexp isearch-highlight-last-regexp)) + ;; Ditto for isearch-toggle-regexp. + (setq need-start-over t)) + ((equal isearch-string isearch-highlight-last-string) + ;; The search string is the same. We need to do something + ;; if our position has changed. + + ;; It would be nice if we didn't have to do this; however, + ;; window-start doesn't support a GUARANTEE flag, so we must + ;; force redisplay to get the correct valye for start and end + ;; of window. + (sit-for 0) + + ;; Check whether our location has changed. + (let ((start (window-start)) + (end (min (window-end) (point-max)))) + (cond ((and (= start isearch-window-start) + (= end isearch-window-end)) + ;; Our position is unchanged -- do nothing. + ) + ((and (> start isearch-window-start) + (> end isearch-window-end) + (<= start isearch-window-end)) + ;; We've migrated downward, but we overlap the old + ;; region. Delete the old non-overlapping extents + ;; and fill in the rest. + (isearch-delete-extents-in-range isearch-window-start start) + (isearch-highlightify-region isearch-window-end end) + (setq isearch-window-start start + isearch-window-end end)) + ((and (<= start isearch-window-start) + (<= end isearch-window-end) + (> end isearch-window-start)) + ;; We've migrated upward, but we overlap the old + ;; region. Delete the old non-overlapping extents + ;; and fill in the rest. + (isearch-delete-extents-in-range + end isearch-window-end) + (isearch-highlightify-region start isearch-window-start) + (setq isearch-window-start start + isearch-window-end end)) + (t + ;; The regions don't overlap, or they overlap in a + ;; weird way. + (setq need-start-over t))))) + (t + ;; The search string has changed. + + ;; If more input is pending, don't start over because + ;; starting over forces redisplay, and that slows down + ;; typing. + (unless (input-pending-p) + (setq need-start-over t)))) + (when need-start-over + ;; Force redisplay before removing the old extents, in order to + ;; avoid flicker. + (sit-for 0) + (isearch-highlight-all-cleanup) + (setq isearch-window-start (window-start) + isearch-window-end (min (window-end) (point-max))) + (isearch-highlightify-region isearch-window-start isearch-window-end)) + + (setq isearch-highlight-last-string isearch-string + isearch-highlight-last-case-fold-search isearch-case-fold-search + isearch-highlight-last-regexp isearch-regexp))) + +(defun isearch-highlight-advance (string forwardp) + ;; Search ahead for the next or previous match. This is the same as + ;; isearch-search, but without the extra baggage. Maybe it should + ;; be in a separate function. + (let ((case-fold-search isearch-case-fold-search)) + (funcall (cond (isearch-word (if forwardp + 'word-search-forward + 'word-search-backward)) + (isearch-regexp (if forwardp + 're-search-forward + 're-search-backward)) + (t (if forwardp + 'search-forward + 'search-backward))) + string nil t))) + +(defun isearch-highlightify-region (start end) + ;; Highlight all occurrences of isearch-string between START and + ;; END. To do this right, we have to search forward as long as + ;; there are matches that overlap [START, END), and then search + ;; backward the same way. + (save-excursion + (goto-char isearch-opoint) + (let ((lastpoint (point))) + (while (and (isearch-highlight-advance isearch-string t) + (/= lastpoint (point)) + (< (match-beginning 0) end)) + (let ((extent (make-extent (match-beginning 0) + (match-end 0)))) + (set-extent-priority extent (1+ mouse-highlight-priority)) + (put extent 'face 'isearch-secondary) + (push extent isearch-highlight-extents)) + (setq lastpoint (point)))) + (goto-char isearch-opoint) + (let ((lastpoint (point))) + (while (and (isearch-highlight-advance isearch-string nil) + (/= lastpoint (point)) + (>= (match-end 0) start)) + (let ((extent (make-extent (match-beginning 0) + (match-end 0)))) + (set-extent-priority extent (1+ mouse-highlight-priority)) + (put extent 'face 'isearch-secondary) + (push extent isearch-highlight-extents)) + (setq lastpoint (point)))))) + ;;; isearch-mode.el ends here diff --git a/lisp/ldap.el b/lisp/ldap.el index 4006514..31c5be7 100644 --- a/lisp/ldap.el +++ b/lisp/ldap.el @@ -155,9 +155,7 @@ Valid properties include: :type 'symbol :group 'ldap) -(defcustom ldap-coding-system (if (featurep 'mule) - 'utf-8 - nil) +(defcustom ldap-coding-system nil "*Coding system of LDAP string values. LDAP v3 specifies the coding system of strings to be UTF-8. Mule support is needed for this." @@ -395,10 +393,12 @@ This table is built from RFC2252 Section 5 and RFC2256 Section 5") (error "Invalid country string: %s" str))) (defun ldap-decode-string (str) - (decode-coding-string str ldap-coding-system)) + (if (fboundp 'decode-coding-string) + (decode-coding-string str ldap-coding-system))) (defun ldap-encode-string (str) - (encode-coding-string str ldap-coding-system)) + (if (fboundp 'encode-coding-string) + (encode-coding-string str ldap-coding-system))) (defun ldap-decode-address (str) (mapconcat 'ldap-decode-string diff --git a/lisp/menubar-items.el b/lisp/menubar-items.el index b284749..4f4f403 100644 --- a/lisp/menubar-items.el +++ b/lisp/menubar-items.el @@ -990,7 +990,7 @@ Adds `Load .emacs' button to menubar when starting up with -q." ;; by Stig@hackvan.com (cond - (init-file-user nil) + (load-user-init-file-p nil) ((file-exists-p (expand-file-name ".emacs" "~")) (add-menu-button nil ["Load .emacs" diff --git a/lisp/modeline.el b/lisp/modeline.el index 5311486..ea16c56 100644 --- a/lisp/modeline.el +++ b/lisp/modeline.el @@ -595,13 +595,14 @@ Normally nil in most modes, since there is no process to display.") (purecopy " ") 'global-mode-string (purecopy " %[(") - (cons modeline-minor-mode-extent (list "" 'mode-name 'minor-mode-alist)) - (cons modeline-narrowed-extent "%n") + (cons modeline-minor-mode-extent + (list (purecopy "") 'mode-name 'minor-mode-alist)) + (cons modeline-narrowed-extent (purecopy "%n")) 'modeline-process (purecopy ")%]----") - (purecopy '(line-number-mode "L%l--")) - (purecopy '(column-number-mode "C%c--")) - (purecopy '(-3 . "%p")) + (list 'line-number-mode (purecopy "L%l--")) + (list 'column-number-mode (purecopy "C%c--")) + (cons -3 (purecopy "%p")) (purecopy "-%-"))) ;;; Added for XEmacs 20.3. Provide wrapper for vc since it may not always be diff --git a/lisp/mouse.el b/lisp/mouse.el index 54dafc7..0afebb8 100644 --- a/lisp/mouse.el +++ b/lisp/mouse.el @@ -84,8 +84,9 @@ If set to `symbol', double-click will always attempt to highlight a "Function that is called upon by `mouse-yank' to actually insert text.") (defun mouse-consolidated-yank () - "Insert the current selection or, if there is none under X insert the X cutbuffer. -A mark is pushed, so that the inserted text lies between point and mark." + "Insert the current selection or, if there is none under X insert +the X cutbuffer. A mark is pushed, so that the inserted text lies +between point and mark." (interactive) (if (not (console-on-window-system-p)) (yank) @@ -225,9 +226,10 @@ This functions has to be improved. Currently it is just a (working) test." (if (click-inside-extent-p event zmacs-region-extent) ;; okay, this is a drag (cond ((featurep 'offix) - (offix-start-drag-region event - (extent-start-position zmacs-region-extent) - (extent-end-position zmacs-region-extent))) + (offix-start-drag-region + event + (extent-start-position zmacs-region-extent) + (extent-end-position zmacs-region-extent))) ((featurep 'cde) ;; should also work with CDE (cde-start-drag-region event diff --git a/lisp/mule/mule-cmds.el b/lisp/mule/mule-cmds.el index 20cd3b5..b0bd9f1 100644 --- a/lisp/mule/mule-cmds.el +++ b/lisp/mule/mule-cmds.el @@ -787,6 +787,8 @@ The return value is a string." (input-method (completing-read prompt input-method-alist nil t nil 'input-method-history default))) + (if (and input-method (symbolp input-method)) + (setq input-method (symbol-name input-method))) (if (> (length input-method) 0) input-method (if inhibit-null diff --git a/lisp/obsolete.el b/lisp/obsolete.el index e71fa7a..4dc0fe5 100644 --- a/lisp/obsolete.el +++ b/lisp/obsolete.el @@ -171,6 +171,10 @@ If you want to change the locations where XEmacs looks for info files, set Info-directory-list.") (make-obsolete-variable 'Info-default-directory-list 'Info-directory-list) +(defvar init-file-user nil + "This used to be the name of the user whose init file was read at startup.") +(make-obsolete-variable 'init-file-user 'load-user-init-file-p) + ;;;;;;;;;;;;;;;;;;;;;;;;;;;; hooks (make-compatible-variable 'lisp-indent-hook 'lisp-indent-function) @@ -242,6 +246,11 @@ set Info-directory-list.") (define-compatible-function-alias 'byte-code-function-p 'compiled-function-p) ;FSFmacs +(define-obsolete-function-alias 'isearch-yank-x-selection + 'isearch-yank-selection) +(define-obsolete-function-alias 'isearch-yank-x-clipboard + 'isearch-yank-clipboard) + ;; too bad there's not a way to check for aref, assq, and nconc ;; being called on the values of functions known to return keymaps, ;; or known to return vectors of events instead of strings... diff --git a/lisp/package-get.el b/lisp/package-get.el index 64bdc3e..a3f3eba 100644 --- a/lisp/package-get.el +++ b/lisp/package-get.el @@ -180,6 +180,7 @@ order until the package is found. As a special case, `site-name' can be (list :tag "Remote" host-name directory) )) :group 'package-get) +;;;###autoload (defcustom package-get-download-sites '( ;; North America @@ -239,6 +240,10 @@ with respect to `package-get-remote', or an absolute path." :type 'file :group 'package-get) +(defvar package-get-user-index-filename + (paths-construct-path (list user-init-directory package-get-base-filename)) + "Name for the user-specific location of the package-get database file.") + (defcustom package-get-always-update nil "*If Non-nil always make sure we are using the latest package index (base). Otherwise respect the `force-current' argument of `package-get-require-base'." @@ -261,11 +266,16 @@ When nil, updates which are not PGP signed are allowed without confirmation." (defun package-get-download-menu () "Build the `Add Download Site' menu." (mapcar (lambda (site) - (vector (car site) - `(package-ui-add-site (quote ,(cdr site))) - :style 'toggle :selected - `(member (quote ,(cdr site)) package-get-remote))) - package-get-download-sites)) + (vector (car site) + `(if (member (quote ,(cdr site)) + package-get-remote) + (setq package-get-remote + (delete (quote ,(cdr site)) package-get-remote)) + (package-ui-add-site (quote ,(cdr site)))) + :style 'toggle + :selected `(member (quote ,(cdr site)) + package-get-remote))) + package-get-download-sites)) ;;;###autoload (defun package-get-require-base (&optional force-current) @@ -328,23 +338,21 @@ If NO-REMOTE is non-nil never search remote locations." "Locate the package-get index file. Do not return remote paths if NO-REMOTE is non-nil." (or (package-get-locate-file package-get-base-filename t no-remote) - (locate-data-file package-get-base-filename) - package-get-base-filename)) - -(defvar package-get-user-package-location user-init-directory) + (if (file-exists-p package-get-user-index-filename) + package-get-user-index-filename))) (defun package-get-maybe-save-index (filename) "Offer to save the current buffer as the local package index file, if different." (let ((location (package-get-locate-index-file t))) (unless (and filename (equal filename location)) - (unless (equal (md5 (current-buffer)) - (with-temp-buffer - (insert-file-contents location) - (md5 (current-buffer)))) - (unless (file-writable-p location) - (setq location (expand-file-name package-get-base-filename - (expand-file-name "etc/" package-get-user-package-location)))) + (unless (and location + (equal (md5 (current-buffer)) + (with-temp-buffer + (insert-file-contents-literally location) + (md5 (current-buffer))))) + (unless (and location (file-writable-p location)) + (setq location package-get-user-index-filename)) (when (y-or-n-p (concat "Update package index in" location "? ")) (write-file location)))))) @@ -1001,6 +1009,10 @@ lead to Emacs accessing remote sites." (package-get-info-prop (car this-package) 'version)))) (setq this-package (cdr this-package))))) (setq packages (cdr packages))) + (when (interactive-p) + (if found + (message "%S" found) + (message "No appropriate package found"))) found)) ;; diff --git a/lisp/packages.el b/lisp/packages.el index 03d001b..de7a272 100644 --- a/lisp/packages.el +++ b/lisp/packages.el @@ -84,17 +84,8 @@ (defvar last-package-load-path nil "Load path for packages last in the load path.") -(defvar package-locations - (list - (list (paths-construct-path '("~" ".xemacs" "mule-packages")) - 'early #'(lambda () (featurep 'mule))) - (list (paths-construct-path '("~" ".xemacs" "xemacs-packages")) - 'early #'(lambda () t)) - (list "site-packages" 'late #'(lambda () t)) - (list "infodock-packages" 'late #'(lambda () (featurep 'infodock))) - (list "mule-packages" 'late #'(lambda () (featurep 'mule))) - (list "xemacs-packages" 'late #'(lambda () t))) - "Locations of the various package directories. +(defun packages-compute-package-locations (user-init-directory) + "Compute locations of the various package directories. This is a list each of whose elements describes one directory. A directory description is a three-element list. The first element is either an absolute path or a subdirectory @@ -103,7 +94,16 @@ The second component is one of the symbols EARLY, LATE, LAST, depending on the load-path segment the hierarchy is supposed to show up in. The third component is a thunk which, if it returns NIL, causes -the directory to be ignored.") +the directory to be ignored." + (list + (list (paths-construct-path (list user-init-directory "mule-packages")) + 'early #'(lambda () (featurep 'mule))) + (list (paths-construct-path (list user-init-directory "xemacs-packages")) + 'early #'(lambda () t)) + (list "site-packages" 'late #'(lambda () t)) + (list "infodock-packages" 'late #'(lambda () (featurep 'infodock))) + (list "mule-packages" 'late #'(lambda () (featurep 'mule))) + (list "xemacs-packages" 'late #'(lambda () t)))) (defun package-get-key-1 (info key) "Locate keyword `key' in list." @@ -429,7 +429,7 @@ DEFAULT is a default list of packages." (setq package-locations (cdr package-locations))) packages))) -(defun packages-find-packages (roots) +(defun packages-find-packages (roots package-locations) "Find the packages." (let ((envvar-value (getenv "EMACSPACKAGEPATH"))) (if envvar-value @@ -494,7 +494,7 @@ PACKAGES is a list of package directories." (defun packages-load-package-lisps (package-load-path base) "Load all Lisp files of a certain name along a load path. BASE is the base name of the files." - (mapc #'(lambda (dir) + (mapcar #'(lambda (dir) (let ((file-name (expand-file-name base dir))) (condition-case error (load file-name t t) @@ -513,7 +513,7 @@ BASE is the base name of the files." (defun packages-handle-package-dumped-lisps (handle package-load-path) "Load dumped-lisp.el files along a load path. Call HANDLE on each file off definitions of PACKAGE-LISP there." - (mapc #'(lambda (dir) + (mapcar #'(lambda (dir) (let ((file-name (expand-file-name "dumped-lisp.el" dir))) (if (file-exists-p file-name) (let (package-lisp @@ -522,7 +522,7 @@ Call HANDLE on each file off definitions of PACKAGE-LISP there." (load file-name) ;; dumped-lisp.el could have set this ... (if package-lisp - (mapc #'(lambda (base) + (mapcar #'(lambda (base) (funcall handle base)) package-lisp)))))) package-load-path)) diff --git a/lisp/process.el b/lisp/process.el index 749f99d..0e3d478 100644 --- a/lisp/process.el +++ b/lisp/process.el @@ -299,7 +299,7 @@ Third arg is program file name. It is searched for as in the shell. Remaining arguments are strings to give program as arguments." (apply 'start-process-internal name buffer program program-args)) -(defun open-network-stream (name buffer host service) +(defun open-network-stream (name buffer host service &optional protocol) "Open a TCP connection for a service to a host. Returns a subprocess-object to represent the connection. Input and output work as for subprocesses; `delete-process' closes it. @@ -312,8 +312,18 @@ BUFFER is the buffer (or buffer-name) to associate with the process. with any buffer Third arg is name of the host to connect to, or its IP address. Fourth arg SERVICE is name of the service desired, or an integer - specifying a port number to connect to." - (open-network-stream-internal name buffer host service)) + specifying a port number to connect to. +Fifth argument PROTOCOL is a network protocol. Currently 'tcp + (Transmission Control Protocol) and 'udp (User Datagram Protocol) are + supported. When omitted, 'tcp is assumed. + +Ouput via `process-send-string' and input via buffer or filter (see +`set-process-filter') are stream-oriented. That means UDP datagrams are +not guaranteed to be sent and received in discrete packets. (But small +datagrams around 500 bytes that are not truncated by `process-send-string' +are usually fine.) Note further that UDP protocol does not guard against +lost packets." + (open-network-stream-internal name buffer host service protocol)) (defun shell-quote-argument (argument) "Quote an argument for passing as argument to an inferior shell." diff --git a/lisp/rect.el b/lisp/rect.el index 737e1d3..757a254 100644 --- a/lisp/rect.el +++ b/lisp/rect.el @@ -26,7 +26,7 @@ ;;; Commentary: -;; This package provides the operations on rectangles that are ocumented +;; This package provides the operations on rectangles that are documented ;; in the XEmacs Reference Manual. ;; ### NOTE: this file has been almost completely rewritten by Didier Verna @@ -86,10 +86,10 @@ Point is at the end of the segment of this line within the rectangle." ;; The replacement for `operate-on-rectangle' -- dv (defun apply-on-rectangle (function start end &rest args) - "Call FUNCTION for each line of rectangle with corners at START, END. + "Call FUNCTION for each line of rectangle with corners at START and END. FUNCTION is called with two arguments: the start and end columns of the -rectangle, plus ARGS extra arguments. Point is at the beginning of line when -the function is called." +rectangle, plus ARGS extra arguments. Point is at the beginning of line +when the function is called." (let (startcol startpt endcol endpt) (save-excursion (goto-char start) @@ -134,17 +134,17 @@ the function is called." ;;;###autoload (defvar killed-rectangle nil - "Rectangle for yank-rectangle to insert.") + "Rectangle for `yank-rectangle' to insert.") ;;;###autoload (defun kill-rectangle (start end &optional fill) - "Delete the rectangle with corners at point and mark (START and END when -called from a program) and save it as the last killed one. You might prefer to -use `delete-extract-rectangle' from a program. + "Delete the region-rectangle and save it as the last killed one. +You might prefer to use `delete-extract-rectangle' from a program. -With a prefix (or a FILL) argument, also fill lines where nothing has to be +When called from a program, the rectangle's corners are START and END. +With a prefix (or FILL) argument, also fill lines where nothing has to be deleted." - (interactive "r\nP") + (interactive "*r\nP") (when buffer-read-only (setq killed-rectangle (extract-rectangle start end)) (barf-if-buffer-read-only)) @@ -152,14 +152,14 @@ deleted." ;;;###autoload (defun delete-rectangle (start end &optional fill) - "Delete (don't save) text in rectangle with corners at point and mark (START -and END when called from a program). The same range of columns is deleted in -each line starting with the line where the region begins and ending with the -line where the region ends. + "Delete the text in the region-rectangle without saving it. +The same range of columns is deleted in each line starting with the line +where the region begins and ending with the line where the region ends. -With a prefix (or a FILL) argument, also fill lines where nothing has to be +When called from a program, the rectangle's corners are START and END. +With a prefix (or FILL) argument, also fill lines where nothing has to be deleted." - (interactive "r\nP") + (interactive "*r\nP") (apply-on-rectangle 'delete-rectangle-line start end fill)) (defun delete-rectangle-line (startcol endcol fill) @@ -240,7 +240,7 @@ as a list of strings, one for each line of the rectangle." ;;;###autoload (defun yank-rectangle () "Yank the last killed rectangle with upper left corner at point." - (interactive) + (interactive "*") (insert-rectangle killed-rectangle)) ;; This function is untouched --dv @@ -268,14 +268,12 @@ and point is at the lower right corner." ;;;###autoload (defun open-rectangle (start end &optional fill) - "Blank out rectangle with corners at point and mark (START and END when -called from a program), shifting text right. The text previously in the region -is not overwritten by the blanks, but instead winds up to the right of the -rectangle. + "Blank out the region-rectangle, shifting text right. -With a prefix (or a FILL) argument, fill with blanks even if there is no text +When called from a program, the rectangle's corners are START and END. +With a prefix (or FILL) argument, fill with blanks even if there is no text on the right side of the rectangle." - (interactive "r\nP") + (interactive "*r\nP") (apply-on-rectangle 'open-rectangle-line start end fill) (goto-char start)) @@ -289,11 +287,12 @@ on the right side of the rectangle." ;;;###autoload (defun string-rectangle (start end string) - "Insert STRING on each line of the rectangle with corners at point and mark -(START and END when called from a program), shifting text right. The left edge -of the rectangle specifies the column for insertion. This command does not -delete or overwrite any existing text." - (interactive "r\nsString rectangle: ") + "Insert STRING on each line of the region-rectangle, shifting text right. +The left edge of the rectangle specifies the column for insertion. This +command does not delete or overwrite any existing text. + +When called from a program, the rectangle's corners are START and END." + (interactive "*r\nsString rectangle: ") (apply-on-rectangle 'string-rectangle-line start end string)) (defun string-rectangle-line (startcol endcol string) @@ -302,13 +301,13 @@ delete or overwrite any existing text." ;;;###autoload (defun clear-rectangle (start end &optional fill) - "Blank out the rectangle with corners at point and mark (START and END when -called from a program). The text previously in the region is overwritten with -blanks. + "Blank out the region-rectangle. +The text previously in the region is overwritten with blanks. -With a prefix (or a FILL) argument, also fill with blanks the parts of the +When called from a program, the rectangle's corners are START and END. +With a prefix (or FILL) argument, also fill with blanks the parts of the rectangle which were empty." - (interactive "r\nP") + (interactive "*r\nP") (apply-on-rectangle 'clear-rectangle-line start end fill)) (defun clear-rectangle-line (startcol endcol fill) diff --git a/lisp/replace.el b/lisp/replace.el index 3b6165e..71b8054 100644 --- a/lisp/replace.el +++ b/lisp/replace.el @@ -679,6 +679,7 @@ When searching for a match, this function use `replace-search-function' and `rep ;; Loop finding occurrences that perhaps should be replaced. (while (and keep-going (not (eobp)) + (or (null limit) (< (point) limit)) (let ((case-fold-search qr-case-fold-search)) (funcall search-function search-string limit)) ;; If the search string matches immediately after @@ -688,7 +689,8 @@ When searching for a match, this function use `replace-search-function' and `rep (and regexp-flag (eq lastrepl (match-beginning 0)) (not match-again))) - (if (eobp) + (if (or (eobp) + (and limit (>= (point) limit))) nil ;; Don't replace the null string ;; right after end of previous replacement. diff --git a/lisp/select.el b/lisp/select.el index f21d440..ef3072e 100644 --- a/lisp/select.el +++ b/lisp/select.el @@ -66,10 +66,17 @@ set the clipboard.") (defun yank-clipboard-selection () "Insert the current Clipboard selection at point." (interactive "*") - (case (device-type (selected-device)) - (x (x-yank-clipboard-selection)) - (mswindows (mswindows-paste-clipboard)) - (otherwise nil))) + (when (console-on-window-system-p) + (setq last-command nil) + (setq this-command 'yank) ; so that yank-pop works. + (let ((clip (get-clipboard))) + (or clip (error "there is no clipboard selection")) + (push-mark) + (insert clip)))) + +(defun get-clipboard () + "Return text pasted to the clipboard." + (get-selection 'CLIPBOARD)) (define-device-method get-cutbuffer "Return the value of one of the cut buffers. @@ -178,13 +185,18 @@ Interactively, the text of the region is used as the selection value." (setq lost-selection-hooks 'dehilight-selection) (defun own-clipboard (string) - "Paste the given string to the X Clipboard." + "Paste the given string to the window system Clipboard." (own-selection string 'CLIPBOARD)) (defun disown-selection (&optional secondary-p) "Assuming we own the selection, disown it. With an argument, discard the secondary selection instead of the primary selection." - (disown-selection-internal (if secondary-p 'SECONDARY 'PRIMARY))) + (disown-selection-internal (if secondary-p 'SECONDARY 'PRIMARY)) + (when (and selection-sets-clipboard + (or (not secondary-p) + (eq secondary-p 'PRIMARY) + (eq secondary-p 'CLIPBOARD))) + (disown-selection-internal 'CLIPBOARD))) ;; from x-init.el ;; selections and active regions diff --git a/lisp/setup-paths.el b/lisp/setup-paths.el index b275db2..a01dff3 100644 --- a/lisp/setup-paths.el +++ b/lisp/setup-paths.el @@ -42,10 +42,14 @@ "Depth of load-path searches in core Lisp paths.") (defvar paths-default-info-directories - (list (paths-construct-path '("usr" "local" "info") - (char-to-string directory-sep-char)) - (paths-construct-path '("usr" "info") - (char-to-string directory-sep-char))) + (mapcar (function + (lambda (dirlist) + (paths-construct-path + dirlist (char-to-string directory-sep-char)))) + '(("usr" "local" "info") + ("usr" "info") + ("usr" "local" "share" "info") + ("usr" "share" "info"))) "Directories appended to the end of the info path by default.") (defun paths-find-site-lisp-directory (roots) @@ -69,7 +73,7 @@ (defun paths-find-module-directory (roots) "Find the main modules directory of the XEmacs hierarchy." (paths-find-architecture-directory roots "modules" - configure-module-directory)) + nil configure-module-directory)) (defun paths-construct-load-path (roots early-package-load-path late-package-load-path last-package-load-path @@ -137,7 +141,7 @@ (defun paths-find-doc-directory (roots) "Find the documentation directory." - (paths-find-architecture-directory roots "lib-src")) + (paths-find-architecture-directory roots "lib-src" nil configure-doc-directory)) (defun paths-find-lock-directory (roots) "Find the lock directory." @@ -158,7 +162,8 @@ (defun paths-find-exec-directory (roots) "Find the binary directory." - (paths-find-architecture-directory roots "lib-src" configure-exec-directory)) + (paths-find-architecture-directory roots "lib-src" + nil configure-exec-directory)) (defun paths-construct-exec-path (roots exec-directory early-packages late-packages last-packages) diff --git a/lisp/simple.el b/lisp/simple.el index cbba11c..34bcde7 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -2656,20 +2656,23 @@ indicating whether soft newlines should be inserted.") (if (save-excursion (skip-chars-backward " \t") (= (point) fill-point)) + ;; 1999-09-17 hniksic: turn off Kinsoku until + ;; it's debugged. + (indent-new-comment-line) ;; 97/3/14 jhod: Kinsoku processing - ;(indent-new-comment-line) - (let ((spacep (memq (char-before (point)) '(?\ ?\t)))) - (funcall comment-line-break-function) - ;; if user type space explicitly, leave SPC - ;; even if there is no WAN. - (if spacep - (save-excursion - (goto-char fill-point) - ;; put SPC except that there is SPC - ;; already or there is sentence end. - (or (memq (char-after (point)) '(?\ ?\t)) - (fill-end-of-sentence-p) - (insert ?\ ))))) +; ;(indent-new-comment-line) +; (let ((spacep (memq (char-before (point)) '(?\ ?\t)))) +; (funcall comment-line-break-function) +; ;; if user type space explicitly, leave SPC +; ;; even if there is no WAN. +; (if spacep +; (save-excursion +; (goto-char fill-point) +; ;; put SPC except that there is SPC +; ;; already or there is sentence end. +; (or (memq (char-after (point)) '(?\ ?\t)) +; (fill-end-of-sentence-p) +; (insert ?\ ))))) (save-excursion (goto-char fill-point) (funcall comment-line-break-function))) diff --git a/lisp/startup.el b/lisp/startup.el index 8a73014..ec39fc4 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -104,18 +104,21 @@ the user's init file.") (defvar emacs-roots nil "List of plausible roots of the XEmacs hierarchy.") -(defvar init-file-user nil - "Identity of user whose `.emacs' file is or was read. -The value is nil if no init file is being used; otherwise, it may be either -the null string, meaning that the init file was taken from the user that -originally logged in, or it may be a string containing a user's name. +(defvar user-init-directory-base ".xemacs" + "Base of directory where user-installed init files may go.") -In either of the latter cases, `(concat \"~\" init-file-user \"/\")' -evaluates to the name of the directory in which the `.emacs' file was -searched for. +(defvar user-init-file-base (cond + ((eq system-type 'ms-dos) "_emacs") + (t ".emacs")) + "Base of init file.") -Setting `init-file-user' does not prevent Emacs from loading -`site-start.el'. The only way to do that is to use `--no-site-file'.") +(defvar user-init-directory + (file-name-as-directory + (paths-construct-path (list "~" user-init-directory-base))) + "Directory where user-installed init files may go.") + +(defvar load-user-init-file-p t + "Non-nil if XEmacs should load the user's init file.") ;; #### called `site-run-file' in FSFmacs @@ -226,7 +229,11 @@ In addition, the") startup. Also implies `-vanilla'. -vanilla Equivalent to -q -no-site-file -no-early-packages. -q Same as -no-init-file. + -user-init-file Use as init file. + -user-init-directory use as init directory. -user Load user's init file instead of your own. + Equivalent to -user-init-file ~/.emacs + -user-init-directory ~/.xemacs/ -u Same as -user.\n") (let ((l command-switch-alist) (insert (lambda (&rest x) @@ -396,6 +403,7 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n") (if (null emacs-roots) (startup-find-roots-warning) (startup-setup-paths emacs-roots + user-init-directory inhibit-early-packages inhibit-site-lisp debug-paths)) @@ -491,12 +499,7 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n") ;; (standard-display-european t) ;; (require 'iso-syntax))) - ;; Figure out which user's init file to load, - ;; either from the environment or from the options. - (setq init-file-user (if (noninteractive) nil (user-login-name))) - ;; If user has not done su, use current $HOME to find .emacs. - (and init-file-user (string= init-file-user (user-real-login-name)) - (setq init-file-user "")) + (setq load-user-init-file-p (not (noninteractive))) ;; Allow (at least) these arguments anywhere in the command line (let ((new-args nil) @@ -506,7 +509,7 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n") (cond ((or (string= arg "-q") (string= arg "-no-init-file")) - (setq init-file-user nil)) + (setq load-user-init-file-p nil)) ((string= arg "-no-site-file") (setq site-start-file nil)) ((or (string= arg "-no-early-packages") @@ -517,11 +520,21 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n") ;; Some work on this one already done in emacs.c. (string= arg "-no-autoloads") (string= arg "--no-autoloads")) - (setq init-file-user nil + (setq load-user-init-file-p nil site-start-file nil)) + ((string= arg "-user-init-file") + (setq user-init-file (pop args))) + ((string= arg "-user-init-directory") + (setq user-init-directory (file-name-as-directory (pop args)))) ((or (string= arg "-u") - (string= arg "-user")) - (setq init-file-user (pop args))) + (string= arg "-user")) + (let* ((user (pop args)) + (home-user (concat "~" user))) + (setq user-init-file + (paths-construct-path (list home-user user-init-file-base))) + (setq user-init-directory + (file-name-as-directory + (paths-construct-path (list home-user user-init-directory-base)))))) ((string= arg "-debug-init") (setq init-file-debug t)) ((string= arg "-unmapped") @@ -533,7 +546,9 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n") (while args (push (pop args) new-args))) (t (push arg new-args)))) - + + (setq init-file-user (and load-user-init-file-p "")) + (nreverse new-args))) (defconst initial-scratch-message "\ @@ -618,43 +633,18 @@ If this is nil, no message will be displayed.") (setq term (substring term 0 hyphend)) (setq term nil)))))) -(defconst user-init-directory "/.xemacs/" - "Directory where user-installed packages may go.") -(define-obsolete-variable-alias - 'emacs-user-extension-dir - 'user-init-directory) - -(defun load-user-init-file (init-file-user) +(defun load-user-init-file () "This function actually reads the init file, .emacs." - (when init-file-user -;; purge references to init.el and options.el -;; convert these to use paths-construct-path for eventual migration to init.el -;; needs to be converted when idiom for constructing "~user" paths is created -; (setq user-init-file -; (paths-construct-path (list (concat "~" init-file-user) -; user-init-directory -; "init.el"))) -; (unless (file-exists-p (expand-file-name user-init-file)) - (setq user-init-file - (paths-construct-path (list (concat "~" init-file-user) - (cond - ((eq system-type 'ms-dos) "_emacs") - (t ".emacs"))))) -; ) - (load user-init-file t t t) -;; This should not be loaded since custom stuff currently goes into .emacs -; (let ((default-custom-file -; (paths-construct-path (list (concat "~" init-file-user) -; user-init-directory -; "options.el"))) -; (when (string= custom-file default-custom-file) -; (load default-custom-file t t))) - (unless inhibit-default-init - (let ((inhibit-startup-message nil)) - ;; Users are supposed to be told their rights. - ;; (Plus how to get help and how to undo.) - ;; Don't you dare turn this off for anyone except yourself. - (load "default" t t))))) + (if (not user-init-file) + (setq user-init-file + (paths-construct-path (list "~" user-init-file-base)))) + (load user-init-file t t t) + (unless inhibit-default-init + (let ((inhibit-startup-message nil)) + ;; Users are supposed to be told their rights. + ;; (Plus how to get help and how to undo.) + ;; Don't you dare turn this off for anyone except yourself. + (load "default" t t)))) ;;; Load user's init file and default ones. (defun load-init-file () @@ -675,12 +665,13 @@ If this is nil, no message will be displayed.") (debug-on-error-initial (if (eq init-file-debug t) 'startup init-file-debug))) (let ((debug-on-error debug-on-error-initial)) - (if init-file-debug + (if (and load-user-init-file-p init-file-debug) ;; Do this without a condition-case if the user wants to debug. - (load-user-init-file init-file-user) + (load-user-init-file) (condition-case error (progn - (load-user-init-file init-file-user) + (if load-user-init-file-p + (load-user-init-file)) (setq init-file-had-error nil)) (error (message "Error in init file: %s" (error-message-string error)) @@ -1075,7 +1066,8 @@ Copyright (C) 1995-1996 Ben Wing\n")) ;; don't let /tmp_mnt/... get into the load-path or exec-path. (abbreviate-file-name invocation-directory))) -(defun startup-setup-paths (roots &optional +(defun startup-setup-paths (roots user-init-directory + &optional inhibit-early-packages inhibit-site-lisp debug-paths) "Setup all the various paths. @@ -1090,7 +1082,9 @@ It's idempotent, so call this as often as you like!" early)) (setq late-packages late) (setq last-packages last)) - (packages-find-packages roots)) + (packages-find-packages + roots + (packages-compute-package-locations user-init-directory))) (setq early-package-load-path (packages-find-package-load-path early-packages)) (setq late-package-load-path (packages-find-package-load-path late-packages)) diff --git a/lisp/subr.el b/lisp/subr.el index 4c3977a..0bbb855 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -223,6 +223,12 @@ other hooks, such as major mode hooks, can do the job." The value of this variable may be buffer-local. The buffer about to be killed is current when this hook is run.") +;; called by Frecord_buffer() +(defvar record-buffer-hook nil + "Function or functions to be called when a buffer is recorded. +The value of this variable may be buffer-local. +The buffer being recorded is passed as an argument to the hook.") + ;; in C in FSFmacs (defvar kill-emacs-hook nil "Function or functions to be called when `kill-emacs' is called, @@ -239,6 +245,22 @@ just before emacs is actually killed.") (define-function 'rplaca 'setcar) (define-function 'rplacd 'setcdr) +(defun copy-symbol (symbol &optional copy-properties) + "Return a new uninterned symbol with the same name as SYMBOL. +If COPY-PROPERTIES is non-nil, the new symbol will have a copy of +SYMBOL's value, function, and property lists." + (let ((new (make-symbol (symbol-name symbol)))) + (when copy-properties + ;; This will not copy SYMBOL's chain of forwarding objects, but + ;; I think that's OK. Callers should not expect such magic to + ;; keep working in the copy in the first place. + (and (boundp symbol) + (set new (symbol-value symbol))) + (and (fboundp symbol) + (fset new (symbol-function symbol))) + (setplist new (copy-list (symbol-plist symbol)))) + new)) + ;;;; String functions. ;; XEmacs @@ -569,9 +591,6 @@ This function accepts any number of arguments, but ignores them." (interactive) nil) -(define-function 'mapc-internal 'mapc) -(make-obsolete 'mapc-internal 'mapc) - (define-function 'eval-in-buffer 'with-current-buffer) (make-obsolete 'eval-in-buffer 'with-current-buffer) @@ -632,13 +651,17 @@ If BUFFER is specified, the contents of that buffer are returned. The arguments OLD-END and OLD-BUFFER are supported for backward compatibility with pre-21.2 XEmacsen times when arguments to this function were (buffer-string &optional START END BUFFER)." - (if (or (null buffer) - (bufferp buffer) - (stringp buffer)) - ;; The new way - (buffer-substring nil nil buffer) - ;; The old way - (buffer-substring buffer old-end old-buffer))) + (cond + ((or (stringp buffer) (bufferp buffer)) + ;; Most definitely the new way. + (buffer-substring nil nil buffer)) + ((or (stringp old-buffer) (bufferp old-buffer) + (natnump buffer) (natnump old-end)) + ;; Definitely the old way. + (buffer-substring buffer old-end old-buffer)) + (t + ;; Probably the old way. + (buffer-substring buffer old-end old-buffer)))) ;; This was not present before. I think Jamie had some objections ;; to this, so I'm leaving this undefined for now. --ben diff --git a/lisp/very-early-lisp.el b/lisp/very-early-lisp.el index a6344c4..48deb50 100644 --- a/lisp/very-early-lisp.el +++ b/lisp/very-early-lisp.el @@ -32,8 +32,8 @@ ;;; Code: -;;; Macros from Michael Sperber to replace read-time Lisp reader macros #-, #+ -;;; ####fixme duplicated in make-docfile.el and update-elc.el +;;; Intended replacement for read-time Lisp reader macros #-, #+ + (defmacro assemble-list (&rest components) "Assemble a list from COMPONENTS. This is a poor man's backquote: @@ -55,17 +55,17 @@ Otherwise, the component becomes an element of the list." "Insert STUFF as a list element if FEATURE is a loaded feature. This is intended for use as a component of ASSEMBLE-LIST." (list 'splice - (if (featurep feature) - (list 'list stuff) - '()))) + (list 'if (list 'featurep (list 'quote feature)) + (list 'list stuff) + '()))) (defmacro unless-feature (feature stuff) "Insert STUFF as a list element if FEATURE is NOT a loaded feature. This is intended for use as a component of ASSEMBLE-LIST." (list 'splice - (if (featurep feature) - '() - (list 'list stuff)))) + (list 'if (list 'featurep (list 'quote feature)) + '() + (list 'list stuff)))) (provide 'very-early-lisp) diff --git a/lisp/wid-edit.el b/lisp/wid-edit.el index a21f19c..270135f 100644 --- a/lisp/wid-edit.el +++ b/lisp/wid-edit.el @@ -1935,16 +1935,11 @@ If END is omitted, it defaults to the length of LIST." (console-on-window-system-p)) (unless gui-glyphs (let* ((gui-button-shadow-thickness 1) - (gui (make-gui-button tag 'widget-gui-action widget))) - (setq - gui-glyphs - (list - (make-glyph `(,(nth 0 (aref gui 1)) [string :data ,text])) - (make-glyph `(,(nth 1 (aref gui 1)) [string :data ,text])) - (make-glyph `(,(nth 2 (aref gui 1)) [string :data ,text])))) + (gui (make-glyph + (make-gui-button tag 'widget-gui-action widget)))) + (setq gui-glyphs gui) (laxputf widget-push-button-cache tag gui-glyphs))) - (widget-glyph-insert-glyph - widget (nth 0 gui-glyphs) (nth 1 gui-glyphs) (nth 2 gui-glyphs))) + (widget-glyph-insert-glyph widget gui-glyphs)) (t (insert text))))) diff --git a/lisp/winnt.el b/lisp/winnt.el index 9ce0750..0dedb06 100644 --- a/lisp/winnt.el +++ b/lisp/winnt.el @@ -39,11 +39,14 @@ ;; #### Oh if we had an alist of shells and their command switches. (setq shell-command-switch "/c") -;; For appending suffixes to directories and files in shell completions. -(defun nt-shell-mode-hook () - (setq comint-completion-addsuffix '("\\" . " ") - comint-process-echoes t)) -(add-hook 'shell-mode-hook 'nt-shell-mode-hook) +;; For appending suffixes to directories and files in shell +;; completions. This screws up cygwin users so we leave it out for +;; now. Uncomment this if you only ever want to use cmd. + +;(defun nt-shell-mode-hook () +; (setq comint-completion-addsuffix '("\\" . " ") +; comint-process-echoes t)) +;(add-hook 'shell-mode-hook 'nt-shell-mode-hook) ;; Use ";" instead of ":" as a path separator (from files.el). (setq path-separator ";") diff --git a/lisp/x-select.el b/lisp/x-select.el index adfec7f..62ae9a8 100644 --- a/lisp/x-select.el +++ b/lisp/x-select.el @@ -50,6 +50,9 @@ 'select-make-extent-for-selection) (define-obsolete-function-alias 'x-cut-copy-clear-internal 'cut-copy-clear-internal) (define-obsolete-function-alias 'x-get-selection 'get-selection) +(define-obsolete-function-alias 'x-get-clipboard 'get-clipboard) +(define-obsolete-function-alias 'x-yank-clipboard-selection + 'yank-clipboard-selection) (define-obsolete-function-alias 'x-disown-selection-internal 'disown-selection-internal) @@ -57,10 +60,6 @@ "Return text selected from some X window." (get-selection 'SECONDARY)) -(defun x-get-clipboard () - "Return text pasted to the clipboard." - (get-selection 'CLIPBOARD)) - (defun x-own-secondary-selection (selection &optional type) "Make a secondary X Selection of the given argument. The argument may be a string or a cons of two markers (in which case the selection is considered to @@ -154,19 +153,6 @@ into Emacs." (x-store-cutbuffer-internal 'CUT_BUFFER0 string)))) -;;; Random utility functions - -(defun x-yank-clipboard-selection () - "Insert the current Clipboard selection at point." - (interactive "*") - (setq last-command nil) - (setq this-command 'yank) ; so that yank-pop works. - (let ((clip (x-get-clipboard))) - (or clip (error "there is no clipboard selection")) - (push-mark) - (insert clip))) - - ;FSFmacs (provide 'select) ;;; x-select.el ends here. diff --git a/version.sh b/version.sh index 761f565..af75a6c 100644 --- a/version.sh +++ b/version.sh @@ -2,8 +2,8 @@ emacs_is_beta=t emacs_major_version=21 emacs_minor_version=2 -emacs_beta_version=19 -xemacs_codename="Shinjuku" +emacs_beta_version=20 +xemacs_codename="Yoko" infodock_major_version=4 infodock_minor_version=0 infodock_build_version=8