Mercurial > hg > xemacs-beta
changeset 149:538048ae2ab8 r20-3b1
Import from CVS: tag r20-3b1
line wrap: on
line diff
--- a/CHANGES-beta Mon Aug 13 09:35:15 2007 +0200 +++ b/CHANGES-beta Mon Aug 13 09:36:16 2007 +0200 @@ -1,344 +1,12 @@ -*- indented-text -*- -to 20.2 --- tm-vm-8.12 + manual --- VM-6.31 --- b2m.c/rcs-checking synch with Emacs/Mule zeta. - -to 20.2 beta6 --- ediff-2.65 Courtesy of Michael Kifer --- Gnus-5.4.52 --- Miscellaneous bug fixes --- W3-3.0.86 - -to 20.2 beta5 --- Interface Changes: - `allow-deletion-of-last-visible-frame' becomes a boolean - `delete-auto-save-files' becomes a boolean --- Miscellaneous Customization cleanup from Hrvoje Niksic --- Miscellaneous Egg fixes from Jareth Hein --- Gnus-5.4.51 --- etags.c-11.86 --- Byte compiler optimization backed out for release --- Miscellaneous bug fixes - -to 20.2 beta4 --- 1+ Byte compiler optimization courtesy of Jamie Zawinski --- Miscellaneous Mule/ Egg/Quail patches courtesy of Jareth Hein --- featurep reader macro code introduced and enabled for this beta only. --- Do not default with-xim to Motif if Motif libraries are availble --- Delete/Backspace correction from Gary Foster --- Gnus-5.4.50 --- VM-6.30 --- miscellaneous bug fixes - -to 20.2 beta3 --- Miscellaneous Mule/ Egg/Quail patches courtesy of Jareth Hein --- Various hyperbole fixes courtesy of Bob Weiner --- Restoration of obsolete symbol overriding-file-coding-system --- MULE-ization of lib-complete.el --- W3-3.0.85 --- xmine-1.8 coutesy of Jens Lautenbacher --- efs-1.15-x5 Courtesy of Michael Sperber --- miscellaneous bug fixes --- balloon-help.el-1.06 Courtesy of Kyle Jones - -to 20.2 beta2 --- sundry psgml fixes --- VM-6.29 --- Gnus-5.4.46 --- W3-3.0.84 --- miscellaneous bug fixes --- edmacro.el-3.10 --- Reverted to custom-1.84 --- Make use of DECnet support a configure time option. - -to 20.2 beta1 --- W3-3.0.83 courtesy of William Perry --- edmacro.el-3.09 courtesy of Hrvoje Niksic --- live-icon.el-1.3 courtesy of Karl Hegbloom --- values setf method --- miscellaneous bug fixes --- verilog.el-2.25 courtesy of Michael McNamara --- tpu-edt.el modifications for zmacs region compatibility courtesy of - Kevin Oberman. --- custom-1.89 courtesy of Per Abrahamsen --- etags.c-11.83 courtesy of F. Potorti` --- Mega Customizations courtesy of Hrvoje Niksic --- "C" balloon help courtesy of Douglas Keller (experimental - placeholder) --- update version numbers - -[XEmacs 20.1 was never released to the net] - -to 20.1 --- facemenu.el boo boo. --- VM-6.27 --- README.htmlpro left as reference for htmlpro.dtd - --- Commercial sound driver fix --- Wnn6 corrections --- Filling corrections --- Animated GIF boo boo. - --- time.el-1.15 --- itimer.el-1.06 --- facemenu-keymap moved to `C-x F' --- MULE anchored beginning regexp bug fix courtesy of David Moore --- VM-6.26 --- miscellaneous bug fixes - -to 20.1 beta15 --- tm-vm.el-8.11 -- Courtesy of Oscar Figuerido --- Restoration of zawinski features in telnet.el. --- paren.el & ps-print.el customized --- Gnus-5.4.45 --- W3-3.0.82 --- xmine.el-1.7 --- Crisp.el-1.17 --- miscellaneous bug fixes --- Custom-1.84 - -to 20.1 beta14 --- about.el hacking --- W3-3.0.81 --- autodetect restored for use with Glyphs --- Gnus-5.4.43 --- miscellaneous bug fixes - -[beta13 was skipped] - -to 20.1 beta12 --- Synch to Emacs/MULE patches courtesy of MORIOKA Tomohiko --- VM-6.24 --- miscellaneous documentation fixes/updates --- etc/GNUS-NEWS added from Gnus-5.4.42 distribution --- xemacs-version.h version in C stack backtrace hack --- More unimplemented NeXTstep cruft removed --- W3-3.0.80 --- Lots and lots of Custom-ization by Hrvoje Niksic --- temp-buffer-shrink-to-fit (still needs a better name) defaults to nil. --- Gnus-5.4.42 --- Cleanup -- vms C files removed, dummy NeXTStep C files removed. They're - in the CVS attic if anyone wishes to revive this code. --- Custom-1.74 --- miscellaneous bug fixes - -to 20.1 beta11 --- Move lisp/auctex/style/*.el to etc/auctex/style/. --- regenerated finder database (every lisp file should have a Keywords: line) --- VM-6.23 --- dired-1.15-x4 --- time-1.13 --- xmine-1.2 --- More MS Windows NT patches Courtesy of Marc Paquette --- webster-www.el Courtesy of Tomasz Cholewo --- webster.el, webster-ucb.el removed from distribution --- movemail imported from Emacs 19.34 (With POP/Hesiod/Kerberos support) --- Custom-1.69 --- miscellaneous bug fixes --- W3-3.0.79 --- Gnus-5.4.40 --- GNATS/send-pr fixes, should work now --- edmacro-3.07 --- configure fixes --- cc-mode-4.390 --- restore inline.c - -to 20.1 beta10 --- custom-1.68 [Beyond 19.15] --- W3-3.0.75 --- Documentation updates --- cc-mode-4.388 --- Custom-1.67 --- EFS fixes courtesy of Michael Sperber --- time.el-1.11 --- Various cursor glitch patches courtesy of Darrell Kindred --- Irix -rpath support courtesy of Darrell Kindred --- Miscellaneous bug fixes --- EFS synch to 19.15 for default-dir.el --- hm--html-mode-5.5 --- VM-6.22 --- Gnus-5.4.37 - -to 20.1 beta9 --- VM-6.21 --- tm-7.106 --- Garbage Collection patches courtesy of David Moore --- time.el update --- minor build tweaks --- EFS integration/bug fix patches courtesy of Michael Sperber --- MULE safe char-before added --- preceding-char, following-char are obsolete and broken, do not use them --- user-mail-address now uses the function --- miscellaneous bug fixes --- Egg patches courtesy of Jareth Hein --- corrections to lib-src script setup in --srcdir configuration --- itimer.el-1.05 --- hyperbole-4.023 --- cc-mode.el-4.387 --- floating-toolbar.el-1.02 --- balloon-help.el-1.05 --- W3-3.0.71 --- Custom-1.65 --- Gnus-5.4.33 --- strip unimplemented subwindows subr code --- GIF correction courtesy Darrell Kindred - -to 20.1 beta8 --- GIF crash fix courtesy of David Moore --- Fix for problem dumping comint with sparcworks --- Fixes for problems during build with dynamic puresize --- xpm background color patch courtesy of Darrell Kindred --- Custom-1.64 --- Gnus-5.4.28 --- miscellaneous bug fixes --- timer.el backed out, we're not ready for it. --- GNATS-3.101 info documentation added, further integration of send-pr.el. - -to 20.1 beta7 --- Update to time.el. --- htmlpro DTD, IE3 DTDs added to etc/sgml. --- I18N patches and more courtesy of Jareth Hein --- Invisibility to visibility extent patch courtesy of David Moore - (fixes long-standing Gnus annoyance when unhiding .signature). --- cperl-mode-1.31+ --- Synch to Emacs/mule API --- Configure gets --canna-libs and --canna-includes courtesy of YAMAMOTO Toru --- w3-3.0.68 --- Custom-1.63 --- Define BROKEN_SIGIO for SunOS 4.1 --- timer.el courtesy of Kyle Jones --- itimer.el-1.04 --- cperl-mode.el-1.31 --- tm-7.105.2 --- cc-mode-4.379 courtesy of Barry Warsaw --- more about.el hacking --- Logo adjusted to be more colormap friendly --- efs/dired updates courtesy of Michael Sperber [on hold] --- miscellaneous bug fixes --- hyperbole fix --- Gnus-5.4.26 --- sit-for, etc. The Final Solution courtesy of David Moore - -to 20.1 beta6 --- filladapt.el-2.09 courtesy of Kyle Jones --- itimer.el-1.03 --- more work on sit-for, etc. courtesy of David Moore --- describe-beta command added, etc/BETA, C-h B --- updates to hyper-apropos.el courtesy of Christoph Wedler --- texinfo manual updated to 2.23 --- texinfo.tex update to 3.9 --- Gnus-5.4.23 --- tm-7.105.1 --- W3-3.0.65 --- Custom-1.59 --- AUCTeX-9.7l --- VM-6.19 --- Build fixes from Martin Buchholz --- More work on Linux libc-5/libc-6 portability, it works out of the box now? --- more frame visibility patches courtesy of Jan Vroonhof --- Synch to MULE patches courtesy of MORIOKA Tomohiko --- graphical updates to time.el --- gnuattach fixes courtesy of Hunter Kelly --- dynamic PURESIZE fixes --- miscellaneous bug fixes - -to 20.1 beta5 --- bug fix to gnus-mime.el --- custom-1.50 - -to 20.1 beta4 --- mine.el (almost) fully ported to XEmacs --- time.el updated for XEmacs Courtesy of Jens Lautenbacher --- Gnus-5.4.17 --- some historical files removed from etc for space --- id-select.el-1.4.5 --- M-: (eval-expression) is now enabled by default --- Freeze frame fixes Courtesy of Jan Vroonhof and Darrell Kindred --- mule categories implemented Courtesy of Jareth Hein --- mic-paren.el-1.3.1 --- builds with dynamic PURESIZE should work better --- hyperbole-4.022 - -to 20.1 beta3 --- Customized edit-faces Courtesy of Jens Lautenbacher --- W3-3.0.62 --- AUCTeX-9.7k --- mic-paren.el-1.3 Courtesy of Mikael Sjödin --- hm--html-menus-5.3 --- custom-1.46 --- site-load.el preconfigured to work with DOC string generation --- regex.c MULE bugfix Courtesy of David Moore --- python-mode.el-2.90 --- balloon-help-1.04 --- xrdb-mode.el-1.21 --- itimer.el-1.01 Courtesy of Kyle Jones --- Miscellaneous bug fixes. --- Dynamic computation of PURESIZE during build - -to 20.1 beta2 --- First cut at MS Windows NT support Courtesy of David Hobley --- itimer.el-1.01 Courtesy of Kyle Jones --- hm--html-menus-5.2 --- redo.el-1.01 --- VM-6.15 --- miscellaneous efs/dired fixes --- OO-Browser-2.10 Courtesy of Bob Weiner --- Yet another man.el Courtesy of jwz --- Addition to sample.emacs Courtesy of jwz --- additions/corrections to about.el --- hyperbole-4.021 Courtesy of Bob Weiner --- Restoration of reportmail.el Courtesy of jwz --- Restoration of passwd.el Courtesy of jwz --- AUC TeX-9.7i Courtesy of Per Abrahamsen (Contributed code integrated - courtesy of Soren Dayton) --- viper-2.93 Courtesy of Michael Kifer --- ediff-2.64 Courtesy of Michael Kifer --- edmacro.el-3.05 --- detached-minibuf.el Courtesy of Alvin Shelton --- whitespace-mode.el Courtesy of Heiko Muenkel --- winmgr-mode.el Courtesy of David Konerding, Stefan Strobel & Barry Warsaw --- Gnus-5.4.15 --- custom-1.44 --- error-message-string ported from Emacs 19.34. --- fast-lock.el-3.11.01 Courtesy of Simon Marshall --- lazy-lock.el-1.16 Courtesy of Simon Marshall --- speedbar.el Courtesy of Eric Ludlam and Jens Lautenbacher --- W3-3.0.60 --- Miscellaneous bug fixes --- igrep.el-2.56 Courtesy of Kevin Rodgers --- frame-icon.el Courtesy of Michael Lamoureux and Bob Weiner --- xrdb-mode.el-1.17 Courtesy of Barry Warsaw - -to 20.1 beta1 --- New symbol `signal-error-on-buffer-boundary'. Set to nil to avoid - lossage of zmacs region when moving against buffer boundaries. --- python-mode.el-2.89 Courtesy of Barry Warsaw --- added mouse-[123] and down-mouse-[123] Emacs-compatible keysyms --- Clicking on `**' buffer modified status in mode-line now works the same - way as C-x C-q. --- Miscellanous bug fixes from a number of people --- mine.el-1.17 Courtesy of Jacques Duthen [New] --- fast-lock.el-3.10.2 Courtesy of Simon Marshall --- browse-cltl2.el-1.1 Courtesy of Holger Schauer [New] --- eldoc.el-1.8 Courtesy of Noah Friedman [New] --- webjump.el-1.4 Courtesy of Neil W. Van Dyke [New] --- mime-setup is no longer dumped on SunPro/MULE. --- Canna coredump fixed --- verilog-mode.el Courtesy of Michael McNamara & Adrian Aichner [New] --- overlay.el Courtesy of Joseph Nuspl [New] --- hm--html-menus-5.1 Courtesy of Heiko Muenkel --- tm-7.105 Courtesy of MORIOKA Tomohiko --- Initial port of edmacro.el courtesy of Hrvoje Niksic [New] --- Native sound support for FreeBSD Courtesy Dick van den Burg --- Correct detection of GIF89, and implement detection of PNG --- efs-1.15 courtesy of Andy Norman and Michael Sperber [New] --- Easy customization of toolbar support courtesy of Hrvoje Niksic --- balloon-help-1.03 courtesy of Kyle Jones [New] --- 'compatible byte compiler warning type added and turned off by default --- redo.el-1.00 courtesy of Kyle Jones [New] --- floating-toolbar.el courtesy of Kyle Jones [New] --- Initial Wnn/egg support and bug fixes courtesy of Jareth Hein [New] --- Gnus-5.4.12 Courtesy of Lars Magne Ingebrigtsen [Upgrade] --- custom-1.40 Courtesy of Per Abrahamsen [New] --- W3-3.0.59 Courtesy of William Perry --- VM-6.13 Courtesy of Kyle Jones [Upgrade] +to 20.3 beta1. +-- Custom-1.97 courtesy of Per Abraham +-- Obsolete files emacstool.c, emacsclient.c, emacsserver.c removed +-- etags.c-11.90 courtesy of Francesco Potorti` +-- Dragable modeline courtesy of Kyle Jones +-- Gnuserv.el 3.1 & upgrade of gnuclient courtesy of Hrvoje Niksic +-- Upgrade to configure 2.12 courtesy of Martin Buchholz +-- New variable `Info-button1-follows-hyperlink' to allow disabling the + feature. +-- Restore Gosling Emacs transpose-chars implementation as an option +-- Bytecompiler optimization hacking courtesy of Jamie Zawinski
--- a/ChangeLog Mon Aug 13 09:35:15 2007 +0200 +++ b/ChangeLog Mon Aug 13 09:36:16 2007 +0200 @@ -1,3 +1,15 @@ +Sat May 17 20:30:54 1997 Steven L Baur <steve@altair.xemacs.org> + + * XEmacs 20.3-b1 is released. + +Fri May 16 20:38:19 1997 Steven L Baur <steve@altair.xemacs.org> + + * info/dir (Packages): Update minor version number. + + * etc/README: Update minor version number. + + * README: Update minor version number. + Tue May 13 20:35:52 1997 Steven L Baur <steve@altair.xemacs.org> * XEmacs-20.2 is released.
--- a/INSTALL Mon Aug 13 09:35:15 2007 +0200 +++ b/INSTALL Mon Aug 13 09:36:16 2007 +0200 @@ -21,42 +21,65 @@ BUILDING AND INSTALLATION: 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 -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. + 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 + 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 88 Mb of disk space (including the XEmacs -sources). Once installed, XEmacs occupies about 50 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 momentarily requires 88+50 Mb. +Building XEmacs requires about 88 Mb of disk space (including the +XEmacs sources). Once installed, XEmacs occupies about 50 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 88+50 Mb. + +XEmacs requires an ANSI C compiler, such as GCC. + + +2) Decide on what other software packages you would like to use with +XEmacs, but are not yet available on your system. On some systems, +Motif and CDE are optional additions. On Solaris, the SUNWaudmo +package enables native sound support. There are also a number of free +software packages that XEmacs can use. If these are not yet available +on your system, obtain, build and install those external packages +before building XEmacs. The packages XEmacs can use are: -XEmacs requires an ANSI C compiler, such as LCC or GCC. + Xaw3d, XPM, JPEG, compface, PNG, zlib, OffiX, GNU DBM, Berkeley DB, + socks, term, NAS, Canna, Wnn. + +You can get (most of) them from the XEmacs ftp site at +ftp://ftp.xemacs.org/pub/aux -2) Consult `./etc/MACHINES' to see what configuration name you should -give to the `configure' program. That file offers hints for -getting around some possible installation problems. +If you want users on other systems to be able to use the XEmacs you +have built, try to build those packages so that the generated +libraries are statically linked. + +Use the --site-includes and --site-libraries options when building +XEmacs to allow configure to find the external software packages. + -3) In the top directory of the XEmacs distribution, run the program -`configure' as follows: +3) In the top level directory of the XEmacs distribution, run the + program `configure' as follows: - ./configure CONFIGURATION-NAME [--OPTION[=VALUE]] ... + ./configure [CONFIGURATION-NAME] [--OPTION[=VALUE]] ... -The CONFIGURATION-NAME argument should be a configuration name given -in `./etc/MACHINES'. If omitted, `configure' will try to guess your -system type; if it cannot, you must find the appropriate configuration -name in `./etc/MACHINES' and specify it explicitly. +Usually, you should let `configure' (actually the shell script +`config.guess') guess your system type, by omitting the +CONFIGURATION-NAME argument. If you like to experiment, specify a +configuration name in the form MACHINE-VENDOR-OPSYS, for example: + +sparc-sun-solaris2.6 + +See config.guess and configure.in for valid values for MACHINE, +VENDOR, and OPSYS. Also check `./etc/MACHINES' for advice on building +on particular machines. If you don't want X support, specify `--with-x=no'. If you omit this -option, `configure' will try to figure out for itself whether your -system has X, and arrange to use it if present. - -Additional support can be included for the NeXTstep system by -specifying the flag `--with-ns'. This is not yet fully supported. +option, `configure' will try to autodetect whether your system has X, +and arrange to use it if present. The `--x-includes=DIR' and `--x-libraries=DIR' options tell the build process where the compiler should look for the include files and @@ -67,25 +90,27 @@ The `--site-includes=DIR' and `--site-libraries=DIR' options allow you to specify additional places the compiler should look for include files and object libraries. You may specify multiple DIR's by -enclosing the list in quotes. On some systems (noticeably Solaris) you -may need to use `--site-runtime-libraries=DIR'. This will add -R -versions of each path in addition to the -L versions. +enclosing the list in quotes. All the external packages you want to +use with XEmacs (e.g. xpm, wnn, ...) described later should have their +include and library directories defined using these options. + +The `--site-runtime-libraries=DIR' option specifies additional +directories to search for shared libraries at run time. This may be +necessary on some systems, or if you expect some of the libraries used +to build XEmacs to be in a different directory at run time than at +build time. Usually this will add a `-R' to each directory specified +and use that when linking XEmacs. The `--with-gcc' option specifies that the build process should -compile XEmacs using GCC. The `--with-lcc' option specifies that the -build process should compile XEmacs using Lucid C. The `--compiler' -option allows you to specify some other compiler to be used to compile -XEmacs. It is compatible with both the `--with-gcc' and `--with-lcc' -options, so if the compiler that you specify is a special version of -either gcc or lcc, then use the appropriate --with-gcc or --with-lcc -flag as well as the --compiler flag. If none of these flags is -specified, `configure' will search for GCC in your load path, and use -it if present. If you don't want to use GCC, specify `--with-gcc=no' -and the compiler will then default to 'cc'. +compile XEmacs using GCC. The `--compiler' option allows you to +specify some other compiler to be used to compile XEmacs. If neither +option is specified, the environment variable CC is used instead. +Otherwise the compiler will then default to 'cc'. The `--cflags' option specifies the CFLAGS the build process should -use when compiling XEmacs. If not used CFLAGS defaults to "-g -O" for -gcc and "-g" for all other compilers. +use when compiling XEmacs. Otherwise the value of the environment +variable CFLAGS is consulted. If that is also undefined, CFLAGS +defaults to "-g -O" for gcc and "-g" for all other compilers. The `--with-gnu-make' option specifies that Makefiles should be written to take advantage of special features of GNU Make. GNU Make @@ -111,7 +136,7 @@ - XEmacs (and the other utilities users run) go in PREFIXDIR/bin (unless the `--exec-prefix' option says otherwise). - The architecture-independent files go in PREFIXDIR/lib/xemacs-VERSION - (where VERSION is the version number of XEmacs, like `19.14'). + (where VERSION is the version number of XEmacs, like `20.3'). - The architecture-dependent files go in PREFIXDIR/lib/xemacs-VERSION/CONFIGURATION (where CONFIGURATION is the configuration name, like mips-dec-ultrix4.2), @@ -127,40 +152,41 @@ For example, the command - ./configure mips-dec-ultrix --with-x + ./configure mips-dec-ultrix --with-x11=yes configures XEmacs to build for a DECstation running Ultrix, with support for the X11 window system. -The `--run-in-place' option will make the installed binaries reference -the source tree for the elisp files. - The `--with-menubars=TYPE' option allows you to specify which X toolkit you wish to use for the menubar. The valid options are -`lucid', `motif' and `none'. The default is `lucid' which is a +`lucid', `motif' and `no'. The default is `lucid' which is a Motif-lookalike menubar. We highly recommend its usage over the real Motif menubar. (In fact, the Motif menubar is currently broken.) If -`none' is specified then support for menubars will not be compiled in. +`no' is specified then support for menubars will not be compiled in. The `--with-scrollbars=TYPE' option allows you to specify which X toolkit you wish to use for the scrollbars. The valid options are -`lucid', `motif', `athena', `athena3d', and `none'. The default is -`lucid' which is a Motif-lookalike scrollbar. If `none' is specified +`lucid', `motif', `athena', `athena3d', and `no'. The default is +`lucid' which is a Motif-lookalike scrollbar. If `no' is specified then support for scrollbars will not be compiled in. The `--with-dialogs=TYPE' option allows you to specify which X toolkit you wish to use for the scrollbars. The valid options are `athena', -`motif, and `none. The `lucid' option is accepted and will result in +`motif, and `no. The `lucid' option is accepted and will result in the `athena' toolkit being used. If the Motif toolkit can be found the default is `motif'. Otherwise, the default is `athena'. If -`none' is specified then support for dialog boxes will not be compiled +`no' is specified then support for dialog boxes will not be compiled in. The `--with-toolbars' option allows you to enable or disable toolbar support. The default is `yes' as long as support for a windowing system is included. -The `--with-xpm' option specifies that XEmacs should support X +The `--with-gif' option specifies that XEmacs should support GIF image +conversion. No extra libraries are required. This options defaults +to `yes'. + +The `--with-xpm' option specifies that XEmacs should support X11 Pixmaps. `configure' will attempt to detect if you have the Xpm libraries and define `--with-xpm' for you. @@ -168,23 +194,18 @@ X-Faces. `configure' will attempt to detect if you have the compface library and define `--with-xface' for you. -The `--with-gif' option specifies that XEmacs should support GIF image -conversion. No extra libraries are required. This options defaults -to `yes'. - The `--with-jpeg' option specifies that XEmacs should support JPEG image conversion. This option requires libjpeg from the Independent JPEG Group which is available on the XEmacs ftp site. `configure' will attempt to detect if you have libjpeg and define `--with-jpeg' for you. -The `--with-png option specifies that XEmacs should support PNG image -conversion. The valid options at `yes', `no' and `gnuz'. This option +The `--with-png' option specifies that XEmacs should support PNG image +conversion. The valid options are `yes' and `no'. This option requires libpng which is available on the XEmacs ftp site. This -option also requires a decompression library, either libz or libgz. -The default is to use libz. Specify `gnuz' as the option to use libgz -instead. `configure' will attempt to detect if you have libpng and -define `--with-png' for you. +option also requires a decompression library, either libz or +libgz. XEmacs will detect whether libz is available, and use that, +else it will use libgz. The `--with-database' option specifies that XEmacs should be built with additional database support. The valid options are `no' or a @@ -193,7 +214,7 @@ files and define `--with-database' for you. The `--with-socks' option specifies that XEmacs should be built with -SOCKS support. +SOCKS support. This requires the libsocks library. The `--with-term' option specifies that XEmacs should be built with TERM support. TERM is a way to multiplex serial lines over a simple @@ -206,14 +227,15 @@ ToolTalk is not yet supported on all architectures. The `--with-sparcworks' option specifies that XEmacs should be built -with support for Sun Sparcworks 3.0.1 and up. This functionality is -only of use on SunOS 4.1.x and Solaris 2.x systems. +with support for Sun Sparcworks 3.0.1 and up (including Sun WorkShop). +This functionality is only of use on SunOS 4.1.x and Solaris 2.x +systems. -The `--with-cde option allows you to enable or disable CDE drag and +The `--with-cde' option allows you to enable or disable CDE drag and drop support. `configure' will attempt to detect this option and define `--with-cde' for you. -The `--with-offix option allows you to enable or disable OffiX drag and +The `--with-offix' option allows you to enable or disable OffiX drag and drop support. `configure' will attempt to detect this option and define `--with-offix' for you. @@ -223,8 +245,8 @@ Currently this doesn't work. The `--external-widget' option specifies that XEmacs should be built -with support for being used as a widget. This functionality should be -considered beta. +with support for being used as a widget by other X11 applications. +This functionality should be considered beta. The `--with-mocklisp' option specifies that XEmacs should be built with support for Mocklisp. Do not use this option unless you have a @@ -240,29 +262,25 @@ The `--with-sound=TYPE' option specifies that XEmacs should be built with sound support. Native (`--with-sound=native') sound support is currently available only on Sun SparcStations, SGI's, HP9000s, and -Linux. Network Audio Support (NAS) (`--with-sound=nas' or -`--with-sound=both') is an extension to X that you may or may not have -for your system. For NAS, you will probably need to provide the paths -to the nas include and library directories to configure. `configure' -will attempt to determine if your configuration supports sound and +systems (such as Linux) with soundcard.h. Network Audio Support (NAS) +(`--with-sound=nas' or `--with-sound=both') is an extension to X that +you may or may not have for your system. For NAS, you will probably +need to provide the paths to the nas include and library directories +to configure. If `--with-sound' is not specified, `configure' will +attempt to determine if your configuration supports native sound and define --with-sound for you. If your native sound library is not in a -standard location you can specify where it is with the -`--native-sound-lib=LIB' flag. For Linux, `/dev/audio' is required -for SunAudio files and `/dev/dsp' is required for raw data and WAVE -format files. +standard location you can specify it with the `--native-sound-lib=LIB' +flag. For Linux, `/dev/audio' is required for SunAudio files and +`/dev/dsp' is required for raw data and WAVE format files. The `--rel-alloc' option can be used to either enable or disable use of the relocating allocator. Generally, it's best to go with the default configuration for your system. The `--use-system-malloc' option can be use to either enable or -disable use of the relocating allocator. Generally, it's best to go -with the default configuration for your system. Note that on many -systems using the system malloc disables the use of the relocating -allocator. - -The `--with-epoch' option enables functionality taken from Epoch. -Currently this doesn't work. +disable use of the system malloc. Generally, it's best to go with the +default configuration for your system. Note that on many systems +using the system malloc disables the use of the relocating allocator. The `--debug' and `--error-checking' options are intended for use only by the developers. `--debug' adds code to be compiled in for @@ -271,41 +289,47 @@ The `--verbose' and `--extra-verbose' options are intended for use only by the developers. `--verbose' causes the results of all -configure tests to be displayed. `--extra-verbose' also displays the -output of any compiler invocations done by configure. +configure tests to be displayed. `--extra-verbose' displays +additional information, useful for debugging. Another help for +determining configure failures is the file `config.log', which +contains the results of the compile and link tests used by configure. + +The `--with-mule' option enables (MUlti-Lingual Emacs) support, needed +to suport non-Latin-1 (including Asian) languages. The Mule support +is not yet as stable or efficient as the `Latin1' support. The +following options require Mule support: + +The `--with-xim' option enables use of the X11 XIM mechanism to allow +an input method to input text into XEmacs. The input method is shared +among all the X applications sharing an X display and using the same +language. The XIM support comes in 2 flavors: motif, and xlib. If +Motif support (the XmIm* set of functions) is available, it is +preferred when available. The xlib XIM support does not work quite as +well, so by default if the XmIm* routines are autodetected, then the +default is `--with-xim=motif', else `--with-xim=no'. + +The `--with-canna' option enables the use of the Canna Japanese input +method. The `--with-wnn' and `--with-wnn6' options are for compiling with the -Wnn multi-language input method. `--with-wnn' is for compiling -against Wnn-4.2 the free version of WNN. This is beta level code. -`--with-wnn6' is for compiling against WNN6 the commercial version of -WNN. This is alpha level code and very lightly tested at present. +Wnn multi-language input method. `--with-wnn' is for compiling with +Wnn-4.2, the free version of WNN. This is beta level code. +`--with-wnn6' is for compiling against WNN6, the commercial version +of WNN. This is alpha level code and very lightly tested at present. -The `--wnn-includes=DIR' and `wnn-libraries=DIR' options are provided -for specifying information about where to find WNN include directories -and WNN libraries. Currently you need to specify wnn-includes in most -installations of Wnn-4.2. +`configure' doesn't do any compilation or installation itself. It +just creates the files that influence those things: `./src/config.h', +and all the Makefile's in the build tree. The `--with-pop', `--with-hesiod', and `--with-kerberos' options are used in conjunction with movemail. As of XEmacs 20.1, movemail is identical to the one used in Emacs. -`configure' doesn't do any compilation or installation -itself. It just creates the files that influence those things: -`./Makefile', `src/Makefile', `lwlib/Makefile', `lib-src/Makefile', -`man/Makefile', `dynodump/Makefile', and `./src/config.h'. For -details on exactly what it does, see the section called `CONFIGURATION -BY HAND', below. - When it is done, `configure' prints a description of what it did and 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'. -The work of `configure' can be done by editing various files in the -distribution, but using `configure' is supposed to be simpler. See -the section called "CONFIGURATION BY HAND" below if you want to do the -configuration yourself. - 4) 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
--- a/Makefile.in Mon Aug 13 09:35:15 2007 +0200 +++ b/Makefile.in Mon Aug 13 09:36:16 2007 +0200 @@ -56,11 +56,8 @@ CC=@CC@ CPP=@CPP@ -C_SWITCH_SYSTEM=@c_switch_system@ LN_S=@LN_S@ CFLAGS=@CFLAGS@ -C_SWITCH_X_SITE=@C_SWITCH_X_SITE@ -LD_SWITCH_X_SITE=@LD_SWITCH_X_SITE@ YACC=@YACC@ ### These help us choose version- and architecture-specific directories @@ -74,9 +71,6 @@ ### for, like `mips-dec-ultrix' or `sparc-sun-sunos'. configuration=@configuration@ -### Libraries which should be edited into lib-src/Makefile. -libsrc_libs=@libsrc_libs@ - # ==================== Where To Install Things ==================== # The default location for installation. Everything is placed in @@ -205,13 +199,13 @@ # Subdirectories to make recursively. `lisp' is not included # because the compiled lisp files are part of the distribution # and you cannot remake them without installing XEmacs first. -MAKE_SUBDIR = lib-src lwlib dynodump src +MAKE_SUBDIR = @MAKE_SUBDIR@ # Subdirectories that can be made recursively. SUBDIR = ${MAKE_SUBDIR} man -# The makefiles of the directories in $SUBDIR. -SUBDIR_MAKEFILES = lib-src/Makefile lwlib/Makefile dynodump/Makefile src/Makefile +# The makefiles of the directories in ${MAKE_SUBDIR}. +SUBDIR_MAKEFILES = @SUBDIR_MAKEFILES@ # Subdirectories to install, and where they'll go. # lib-src's makefile knows how to install it, so we don't do that here.
--- a/PROBLEMS Mon Aug 13 09:35:15 2007 +0200 +++ b/PROBLEMS Mon Aug 13 09:36:16 2007 +0200 @@ -659,14 +659,6 @@ If your system uses the lock file protocol, and fascist restrictions prevent ordinary users from writing the lock files in /usr/spool/mail, you may need to make `movemail' setgid to a suitable group such as -`mail'. You can use these commands (as root): - - chgrp mail movemail - chmod 2755 movemail - -If your system uses the lock file protocol, and fascist restrictions -prevent ordinary users from writing the lock files in /usr/spool/mail, -you may need to make `movemail' setgid to a suitable group such as `mail'. To do this, use the following commands (as root) after doing the make install.
--- a/README Mon Aug 13 09:35:15 2007 +0200 +++ b/README Mon Aug 13 09:36:16 2007 +0200 @@ -1,4 +1,4 @@ -This directory tree holds version 20.2 of XEmacs, the extensible, +This directory tree holds version 20.3 of XEmacs, the extensible, customizable, self-documenting real-time display editor. See the file `etc/NEWS' for information on new features and other
--- a/config.guess Mon Aug 13 09:35:15 2007 +0200 +++ b/config.guess Mon Aug 13 09:36:16 2007 +0200 @@ -21,8 +21,6 @@ # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. -# Synched up with: FSF 19.31. - # Written by Per Bothner <bothner@cygnus.com>. # The master version of this file is at the FSF in /home/gd/gnu/lib. # @@ -53,14 +51,13 @@ # Note: order is significant - the case branches are not exclusive. case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in - alpha:OSF1:V*.*) - # After 1.2, OSF1 uses "V1.3" for uname -r. - echo alpha-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^V//'` + alpha:OSF1:*:*) + # A Vn.n version is a released version. + # A Tn.n version is a released field test version. + # A Xn.n version is an unreleased experimental baselevel. + # 1.2 uses "1.2" for uname -r. + echo alpha-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//'` exit 0 ;; - alpha:OSF1:*:*) - # 1.2 uses "1.2" for uname -r. - echo alpha-dec-osf${UNAME_RELEASE} - exit 0 ;; 21064:Windows_NT:50:3) echo alpha-dec-winnt3.5 exit 0 ;; @@ -70,21 +67,28 @@ amiga:NetBSD:*:*) echo m68k-cbm-netbsd${UNAME_RELEASE} exit 0 ;; + amiga:OpenBSD:*:*) + echo m68k-cbm-openbsd${UNAME_RELEASE} + exit 0 ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit 0;; - Pyramid*:OSx*:*:*) + Pyramid*:OSx*:*:*|MIS*:OSx*:*:*) + # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 else echo pyramid-pyramid-bsd fi exit 0 ;; - sun4*:SunOS:5.*:*) + NILE:*:*:dcosx) + echo pyramid-pyramid-svr4 + exit 0 ;; + sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; i86pc:SunOS:5.*:*) - echo i386-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize @@ -104,25 +108,60 @@ sun3*:SunOS:*:*) echo m68k-sun-sunos${UNAME_RELEASE} exit 0 ;; + aushp:SunOS:*:*) + echo sparc-auspex-sunos${UNAME_RELEASE} + exit 0 ;; atari*:NetBSD:*:*) echo m68k-atari-netbsd${UNAME_RELEASE} exit 0 ;; + atari*:OpenBSD:*:*) + echo m68k-atari-openbsd${UNAME_RELEASE} + exit 0 ;; sun3*:NetBSD:*:*) echo m68k-sun-netbsd${UNAME_RELEASE} exit 0 ;; + sun3*:OpenBSD:*:*) + echo m68k-sun-openbsd${UNAME_RELEASE} + exit 0 ;; mac68k:NetBSD:*:*) echo m68k-apple-netbsd${UNAME_RELEASE} exit 0 ;; + mac68k:OpenBSD:*:*) + echo m68k-apple-openbsd${UNAME_RELEASE} + exit 0 ;; + powerpc:machten:*:*) + echo powerpc-apple-machten${UNAME_RELEASE} + exit 0 ;; + RISC*:Mach:*:*) + echo mips-dec-mach_bsd4.3 + exit 0 ;; RISC*:ULTRIX:*:*) echo mips-dec-ultrix${UNAME_RELEASE} exit 0 ;; VAX*:ULTRIX*:*:*) echo vax-dec-ultrix${UNAME_RELEASE} exit 0 ;; - mips:*:4*:UMIPS) - echo mips-mips-riscos4sysv - exit 0 ;; - mips:*:5*:RISCos) + mips:*:*:UMIPS | mips:*:*:RISCos) + sed 's/^ //' << EOF >dummy.c + int main (argc, argv) int argc; char **argv; { + #if defined (host_mips) && defined (MIPSEB) + #if defined (SYSTYPE_SYSV) + printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); + #endif + #if defined (SYSTYPE_SVR4) + printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); + #endif + #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) + printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); + #endif + #endif + exit (-1); + } +EOF + ${CC-cc} dummy.c -o dummy \ + && ./dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \ + && rm dummy.c dummy && exit 0 + rm -f dummy.c dummy echo mips-mips-riscos${UNAME_RELEASE} exit 0 ;; Night_Hawk:Power_UNIX:*:*) @@ -140,7 +179,7 @@ AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` - if [ $UNAME_PROCESSOR = mc88100 -o $UNAME_PROCESSOR = mc88100 ] ; then + if [ $UNAME_PROCESSOR = mc88100 -o $UNAME_PROCESSOR = mc88110 ] ; then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx \ -o ${TARGET_BINARY_INTERFACE}x = x ] ; then echo m88k-dg-dgux${UNAME_RELEASE} @@ -166,10 +205,10 @@ *:IRIX*:*:*) echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` exit 0 ;; - ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. + ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX ' - i[3-9]86:AIX:*:*) + i?86:AIX:*:*) echo i386-ibm-aix exit 0 ;; *:AIX:2:3) @@ -214,7 +253,7 @@ echo romp-ibm-bsd4.4 exit 0 ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC NetBSD and - echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to + echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to exit 0 ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx @@ -232,7 +271,7 @@ case "${UNAME_MACHINE}" in 9000/31? ) HP_ARCH=m68000 ;; 9000/[34]?? ) HP_ARCH=m68k ;; - 9000/7?? | 9000/8?[679] ) HP_ARCH=hppa1.1 ;; + 9000/7?? | 9000/8?[1679] ) HP_ARCH=hppa1.1 ;; 9000/8?? ) HP_ARCH=hppa1.0 ;; esac HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` @@ -280,6 +319,13 @@ hp8??:OSF1:*:*) echo hppa1.0-hp-osf exit 0 ;; + i?86:OSF1:*:*) + if [ -x /usr/sbin/sysversion ] ; then + echo ${UNAME_MACHINE}-unknown-osf1mk + else + echo ${UNAME_MACHINE}-unknown-osf1 + fi + exit 0 ;; parisc*:Lites*:*:*) echo hppa1.1-hp-lites exit 0 ;; @@ -307,17 +353,33 @@ CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} exit 0 ;; - CRAY*C90:*:*:*) - echo c90-cray-unicos${UNAME_RELEASE} + CRAY*[A-Z]90:*:*:*) + echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ + | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ + -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ + exit 0 ;; + CRAY*TS:*:*:*) + echo t90-cray-unicos${UNAME_RELEASE} exit 0 ;; CRAY-2:*:*:*) echo cray2-cray-unicos exit 0 ;; + F300:UNIX_System_V:*:*) + FUJITSU_SYS=`uname -p | tr [A-Z] [a-z] | sed -e 's/\///'` + FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` + echo "f300-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" + exit 0 ;; + F301:UNIX_System_V:*:*) + echo f301-fujitsu-uxpv`echo $UNAME_RELEASE | sed 's/ .*//'` + exit 0 ;; hp3[0-9][05]:NetBSD:*:*) echo m68k-hp-netbsd${UNAME_RELEASE} exit 0 ;; - i[3-9]86:BSD/386:*:* | *:BSD/OS:*:*) - echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} + hp3[0-9][05]:OpenBSD:*:*) + echo m68k-hp-openbsd${UNAME_RELEASE} + exit 0 ;; + i?86:BSD/386:*:* | *:BSD/OS:*:*) + echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit 0 ;; *:FreeBSD:*:*) echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` @@ -325,8 +387,11 @@ *:NetBSD:*:*) echo ${UNAME_MACHINE}-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` exit 0 ;; + *:OpenBSD:*:*) + echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` + exit 0 ;; i*:CYGWIN*:*) - echo i386-unknown-cygwin32 + echo i386-pc-cygwin32 exit 0 ;; p*:CYGWIN*:*) echo powerpcle-unknown-cygwin32 @@ -338,28 +403,30 @@ echo `echo ${UNAME_MACHINE}|sed -e 's,/.*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit 0 ;; *:Linux:*:*) - # XEmacs changes in this section: add the version number of Linux - # (1.1.56 and above has working SIGIO) # The BFD linker knows what the default object file format is, so # first see if it will tell us. ld_help_string=`ld --help 2>&1` - if echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: elf_i[3-9]86"; then - echo "${UNAME_MACHINE}-unknown-linux${UNAME_RELEASE}" ; exit 0 - elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: i[3-9]86linux"; then - echo "${UNAME_MACHINE}-unknown-linuxaout${UNAME_RELEASE}" ; exit 0 - elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: i[3-9]86coff"; then - echo "${UNAME_MACHINE}-unknown-linuxcoff${UNAME_RELEASE}" ; exit 0 + if echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: elf_i.86"; then + echo "${UNAME_MACHINE}-pc-linux-gnu" ; exit 0 + elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: i.86linux"; then + echo "${UNAME_MACHINE}-pc-linux-gnuaout" ; exit 0 + elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: i.86coff"; then + echo "${UNAME_MACHINE}-pc-linux-gnucoff" ; exit 0 elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: m68kelf"; then - echo "${UNAME_MACHINE}-unknown-linux${UNAME_RELEASE}" ; exit 0 + echo "${UNAME_MACHINE}-unknown-linux-gnu" ; exit 0 elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: m68klinux"; then - echo "${UNAME_MACHINE}-unknown-linuxaout${UNAME_RELEASE}" ; exit 0 + echo "${UNAME_MACHINE}-unknown-linux-gnuaout" ; exit 0 + elif echo "$ld_help_string" | grep >/dev/null 2>&1 "supported emulations: elf32ppc"; then + echo "powerpc-unknown-linux-gnu" ; exit 0 elif test "${UNAME_MACHINE}" = "alpha" ; then - echo "alpha-unknown-linux${UNAME_RELEASE}" ; exit 0 + echo alpha-unknown-linux-gnu ; exit 0 + elif test "${UNAME_MACHINE}" = "sparc" ; then + echo sparc-unknown-linux-gnu ; exit 0 else - # Either a pre-BFD a.out linker (linuxoldld) or one that does not give us - # useful --help. Gcc wants to distinguish between linuxoldld and linuxaout. + # Either a pre-BFD a.out linker (linux-gnuoldld) or one that does not give us + # useful --help. Gcc wants to distinguish between linux-gnuoldld and linux-gnuaout. test ! -d /usr/lib/ldscripts/. \ - && echo "${UNAME_MACHINE}-unknown-linuxoldld${UNAME_RELEASE}" && exit 0 + && echo "${UNAME_MACHINE}-pc-linux-gnuoldld" && exit 0 # Determine whether the default compiler is a.out or elf cat >dummy.c <<EOF main(argc, argv) @@ -367,44 +434,44 @@ char *argv[]; { #ifdef __ELF__ - printf ("%s-unknown-linux%s\n", argv[1], argv[2]); + printf ("%s-pc-linux-gnu\n", argv[1]); #else - printf ("%s-unknown-linuxaout%s\n", argv[1], argv[2]); + printf ("%s-pc-linux-gnuaout\n", argv[1]); #endif return 0; } EOF - ${CC-cc} dummy.c -o dummy 2>/dev/null && ./dummy "${UNAME_MACHINE}" "${UNAME_RELEASE}" && rm dummy.c dummy && exit 0 + ${CC-cc} dummy.c -o dummy 2>/dev/null && ./dummy "${UNAME_MACHINE}" && rm dummy.c dummy && exit 0 rm -f dummy.c dummy fi ;; # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. earlier versions # are messed up and put the nodename in both sysname and nodename. - i[3-9]86:DYNIX/ptx:4*:*) + i?86:DYNIX/ptx:4*:*) echo i386-sequent-sysv4 exit 0 ;; - i[3-9]86:*:4.*:* | i[3-9]86:SYSTEM_V:4.*:*) + i?86:*:4.*:* | i?86:SYSTEM_V:4.*:*) if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then echo ${UNAME_MACHINE}-univel-sysv${UNAME_RELEASE} else - echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE} + echo ${UNAME_MACHINE}-pc-sysv${UNAME_RELEASE} fi exit 0 ;; - i[3-9]86:*:3.2:*) + i?86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name` - echo ${UNAME_MACHINE}-unknown-isc$UNAME_REL + echo ${UNAME_MACHINE}-pc-isc$UNAME_REL elif /bin/uname -X 2>/dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')` (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 - echo ${UNAME_MACHINE}-unknown-sco$UNAME_REL + echo ${UNAME_MACHINE}-pc-sco$UNAME_REL else - echo ${UNAME_MACHINE}-unknown-sysv32 + echo ${UNAME_MACHINE}-pc-sysv32 fi exit 0 ;; Intel:Mach:3*:*) - echo i386-unknown-mach3 + echo i386-pc-mach3 exit 0 ;; paragon:*:*:*) echo i860-intel-osf1 @@ -420,28 +487,36 @@ # "miniframe" echo m68010-convergent-sysv exit 0 ;; - M680[234]0:*:R3V[567]*:*) + M68*:*:R3V[567]*:*) test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;; - 3[34]??:*:4.0:3.0 | 3[345]??,*:*:4.0:3.0) - uname -p 2>/dev/null | grep 86 >/dev/null \ - && echo i486-ncr-sysv4.3 && exit 0 ;; - 3[34]??:*:4.0:* | 3[345]??,*:*:4.0:*) - uname -p 2>/dev/null | grep 86 >/dev/null \ + 3[34]??:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 4850:*:4.0:3.0) + OS_REL='' + test -r /etc/.relid \ + && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ + && echo i486-ncr-sysv4.3${OS_REL} && exit 0 + /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ + && echo i586-ncr-sysv4.3${OS_REL} && exit 0 ;; + 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) + /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && echo i486-ncr-sysv4 && exit 0 ;; - m680[234]0:LynxOS:2.[23]*:*) - echo m68k-lynx-lynxos${UNAME_RELEASE} + m68*:LynxOS:2.*:*) + echo m68k-unknown-lynxos${UNAME_RELEASE} exit 0 ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit 0 ;; - i[3-9]86:LynxOS:2.[23]*:*) - echo i386-lynx-lynxos${UNAME_RELEASE} + i?86:LynxOS:2.*:*) + echo i386-unknown-lynxos${UNAME_RELEASE} + exit 0 ;; + TSUNAMI:LynxOS:2.*:*) + echo sparc-unknown-lynxos${UNAME_RELEASE} exit 0 ;; - TSUNAMI:LynxOS:2.[23]*:*) - echo sparc-lynx-lynxos${UNAME_RELEASE} + rs6000:LynxOS:2.*:* | PowerPC:LynxOS:2.*:*) + echo rs6000-unknown-lynxos${UNAME_RELEASE} exit 0 ;; - rs6000:LynxOS:2.[23]*:*) - echo rs6000-lynx-lynxos${UNAME_RELEASE} + SM[BE]S:UNIX_SV:*:*) + echo mips-dde-sysv${UNAME_RELEASE} exit 0 ;; RM*:SINIX-*:*:*) echo mips-sni-sysv4 @@ -454,16 +529,29 @@ echo ns32k-sni-sysv fi exit 0 ;; + *:UNIX_System_V:4*:FTX*) + # From Gerald Hewes <hewes@openmarket.com>. + # How about differentiating between stratus architectures? -djm + echo hppa1.1-stratus-sysv4 + exit 0 ;; + *:*:*:FTX*) + # From seanf@swdc.stratus.com. + echo i860-stratus-sysv4 + exit 0 ;; mc68*:A/UX:*:*) echo m68k-apple-aux${UNAME_RELEASE} exit 0 ;; - R3000:*System_V*:*:*) + R3000:*System_V*:*:* | R4000:UNIX_SYSV:*:*) if [ -d /usr/nec ]; then echo mips-nec-sysv${UNAME_RELEASE} else echo mips-unknown-sysv${UNAME_RELEASE} fi exit 0 ;; + PENTIUM:CPunix:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + # says <Richard.M.Bartel@ccMail.Census.GOV> + echo i586-unisys-sysv4 + exit 0 ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 @@ -502,41 +590,13 @@ #endif #if defined (NeXT) -/*#if !defined (__ARCHITECTURE__) - *#define __ARCHITECTURE__ "m68k" - *#endif - * int version; - * version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; - * printf ("%s-next-nextstep%s\n", __ARCHITECTURE__, version==2 ? "2" : "3"); - * exit (0); - */ - printf("mab-next-nextstep3\n"); exit(0); +#if !defined (__ARCHITECTURE__) +#define __ARCHITECTURE__ "m68k" #endif - -#if defined (MACH) -#if defined (vax) - printf("vax-dec-mach\n"); exit(0); -#else -#if defined (sun3) - printf("mc68000-sun-mach\n"); exit(0); -#else -#if defined (sparc) - printf("sparc-sun-mach\n"); exit(0); -#else -#if defined (mips) - printf("mips-dec-mach\n"); exit(0); -#else -#if defined (ibmrt) - printf("romp-ibm-mach\n"); exit(0); -#else -#if defined (i386) - printf("i386-unknown-mach\n"); exit(0); -#endif -#endif -#endif -#endif -#endif -#endif + int version; + version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; + printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); + exit (0); #endif #if defined (MULTIMAX) || defined (n16) @@ -552,7 +612,7 @@ #endif #if defined (__386BSD__) - printf ("i386-unknown-bsd\n"); exit (0); + printf ("i386-pc-bsd\n"); exit (0); #endif #if defined (sequent)
--- a/configure Mon Aug 13 09:35:15 2007 +0200 +++ b/configure Mon Aug 13 09:36:16 2007 +0200 @@ -1,7 +1,11 @@ -#!/bin/sh -#### Configuration script for XEmacs. -#### Copyright (C) 1994 Free Software Foundation, Inc. +#! /bin/sh + +#### Configuration script for XEmacs. Largely divergent from FSF. +#### Guess values for system-dependent variables and create Makefiles. +#### Generated automatically using autoconf version 2.12 +#### Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. #### Copyright (C) 1993-1995 Board of Trustees, University of Illinois. +#### Copyright (C) 1996, 1997 Sun Microsystems, Inc. #### Copyright (C) 1995, 1996 Ben Wing. ### Don't edit this script! @@ -9,7 +13,7 @@ ### from the file `./configure.in'. ### To rebuild it, execute the command ### autoconf -### in the this directory. You must have autoconf version 1.9 or later. +### in the this directory. You must have autoconf version 2.12 or later. ### This file is part of XEmacs. @@ -28,48 +32,181 @@ ### Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ### 02111-1307, USA. -### Since XEmacs has configuration requirements that autoconf can't -### meet, this file is an unholy marriage of custom-baked -### configuration code and autoconf macros. -### -### We use the m4 quoting characters [ ] (as established by the -### autoconf system) to include large sections of raw sewage - Oops, I -### mean, shell code - in the final configuration script. -### -### Usage: configure config_name +### For usage, run `./configure --help' +### For more detailed information on building and installing XEmacs, +### read the file `INSTALL'. ### ### If configure succeeds, it leaves its status in config.status. +### A log of configuration tests can be found in config.log. ### If configure fails after disturbing the status quo, ### config.status is removed. -### Remove any more than one leading "." element from the path name. -### If we don't remove them, then another "./" will be prepended to -### the file name each time we use config.status, and the program name -### will get larger and larger. This wouldn't be a problem, except -### that since progname gets recorded in all the Makefiles this script -### produces, move-if-change thinks they're different when they're -### not. -### -### It would be nice if we could put the ./ in a \( \) group and then -### apply the * operator to that, so we remove as many leading ./././'s -### as are present, but some seds (like Ultrix's sed) don't allow you to -### apply * to a \( \) group. Bleah. +ac_help="$ac_help + --with-x use the X Window System" + +build=NONE +cache_file=/dev/null +exec_prefix=NONE +host=NONE +no_create= +nonopt=NONE +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, +silent= +site= +srcdir= +target=NONE +verbose= +x_includes=NONE +x_libraries=NONE +bindir='${exec_prefix}/bin' +sbindir='${exec_prefix}/sbin' +libexecdir='${exec_prefix}/libexec' +datadir='${prefix}/share' +sysconfdir='${prefix}/etc' +sharedstatedir='${prefix}/com' +localstatedir='${prefix}/var' +libdir='${{exec_prefix}}/lib' +includedir='${prefix}/include' +oldincludedir='/usr/include' +infodir='${prefix}/info' +mandir='${prefix}/man' + +subdirs= +MFLAGS= MAKEFLAGS= +ac_max_here_lines=12 + +trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 + +# File descriptor usage: +# 0 standard input +# 1 file creation +# 2 errors and warnings +# 3 some systems may open it to /dev/tty +# 4 used on the Kubota Titan +# 6 checking for... messages and results +# 5 compiler messages saved in config.log +if test "$silent" = yes; then + exec 6>/dev/null +else + exec 6>&1 +fi +exec 5>./config.log + +echo "\ +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. +" 1>&5 + +# Strip out --no-create and --no-recursion so they do not pile up. +# Also quote any args containing shell metacharacters. +ac_configure_args= +for ac_arg +do + case "$ac_arg" in + -no-create | --no-create | --no-creat | --no-crea | --no-cre \ + | --no-cr | --no-c) ;; + -no-recursion | --no-recursion | --no-recursio | --no-recursi \ + | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; + *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) + ac_configure_args="$ac_configure_args '$ac_arg'" ;; + *) ac_configure_args="$ac_configure_args $ac_arg" ;; + esac +done + +# NLS nuisances. +# Only set these to C if already set. These must not be set unconditionally +# because not all systems understand e.g. LANG=C (notably SCO). +# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! +# Non-C LC_CTYPE values break the ctype check. +if test "${LANG+set}" = set; then LANG=C; export LANG; fi +if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi +if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi +if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi + +# confdefs.h avoids OS command line length limits that DEFS can exceed. +rm -rf conftest* confdefs.h +# AIX cpp loses on an empty file, so make sure it contains at least a newline. +echo > confdefs.h + +# A filename unique to this package, relative to the directory that +# configure is in, which we can look for to find out if srcdir is correct. +ac_unique_file=src/lisp.h + +# Find the source files, if location was not specified. +if test -z "$srcdir"; then + ac_srcdir_defaulted=yes + # Try the directory containing this script, then its parent. + ac_prog=$0 + ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` + test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. + srcdir=$ac_confdir + if test ! -r $srcdir/$ac_unique_file; then + srcdir=.. + fi +else + ac_srcdir_defaulted=no +fi +if test ! -r $srcdir/$ac_unique_file; then + if test "$ac_srcdir_defaulted" = yes; then + { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } + else + { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } + fi +fi +srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` + +# Prefer explicitly selected file to automatically selected ones. +if test -z "$CONFIG_SITE"; then + if test "x$prefix" != xNONE; then + CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" + else + CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" + fi +fi +for ac_site_file in $CONFIG_SITE; do + if test -r "$ac_site_file"; then + echo "loading site script $ac_site_file" + . "$ac_site_file" + fi +done + + +ac_ext=c +xe_cppflags='$c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS $CPPFLAGS' # $c_switch_x_machine $c_switch_x_system' +xe_ldflags='$ld_switch_site $ld_switch_machine $ld_switch_system $ld_switch_x_site' # $ld_switch_x_machine $ld_switch_x_system' +xe_libs='$xe_check_libs $X_PRE_LIBS $libs_x $X_EXTRA_LIBS $LIBS $libs_machine $libs_system $libs_standard' +ac_cpp='$CPP '"$xe_cppflags" +ac_compile='${CC-cc} -c '"$CFLAGS $xe_cppflags"' conftest.$ac_ext 1>&5' +ac_link='${CC-cc} -o conftest '"$CFLAGS $xe_cppflags $LDFLAGS $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' +cross_compiling=no + +if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then + # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. + if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then + ac_n= ac_c=' +' ac_t=' ' + else + ac_n=-n ac_c= ac_t= + fi +else + ac_n= ac_c='\c' ac_t= +fi + + progname="`echo $0 | sed 's:^\./\./:\./:'`" -############################################################################ -# # -# Establish some default values # -# # -############################################################################ - -#run_in_place='no' + +cache_file=/dev/null + +MAKE_SUBDIR="src lib-src" + prefix='/usr/local' exec_prefix='${prefix}' bindir='${exec_prefix}/bin' -# FSF 19.29 changes to: -# datadir='${prefix}/share' -# sharedstatedir='${prefix}/com' -# libexecdir='${exec_prefix}/libexec' datadir='${prefix}/lib' statedir='${prefix}/lib' libdir='${exec_prefix}/lib' @@ -95,55 +232,24 @@ with_x11='' rel_alloc='default' use_system_malloc='default' -internal_makefile_list='Makefile lib-src/Makefile.in src/Makefile.in lwlib/Makefile.in dynodump/Makefile.in' -energize_version='no' +energize_version='' native_sound_lib='' -# make normal error-checking be the default in alpha and beta versions, so -# that bugs get noticed. Change this for released versions. error_check_default='no' error_check_extents=$error_check_default error_check_typecheck=$error_check_default error_check_bufpos=$error_check_default error_check_gc=$error_check_default error_check_malloc=$error_check_default -# debug=yes must be set when error checking is present. This should be -# fixed up. debug=$error_check_default -quantify='no' -# use-assertions should be 'yes' by default. Too many people in this -# world have core dumps turned off by default or "can't find where the -# core file went". At least we should get some useful output ... use_assertions='yes' -# the following is set to yes or no later. with_gif='' -# the following is set to yes or no later. with_toolbars='' -with_tty='yes' use_union_type='no' with_dnet='' -# # gnu echo silently eats `--help', `--version', `-n', `-e', `-E', `-n'. -# # other versions of echo eat any strings beginning with `-n'. -# # when parsing arguments, special case these strings and don't -# # pass them through echo -# echo=/bin/echo -# -# this approach abandoned in favor of -# -# echo "" ${stuff_to_filter} | sed -e 's:^ ::' - -# On Sun systems, people sometimes set up the variable CPP -# with a value that is a directory, not an executable at all. -# Detect that case, and ignore that value. test -n "$CPP" -a -d "$CPP" && CPP= -############################################################################ -# # -# Usage messages # -# # -############################################################################ - -short_usage="Usage: ${progname} CONFIGURATION [-OPTION[=VALUE] ...] +usage="Usage: $progname CONFIGURATION [-OPTION[=VALUE] ...] Set compilation and installation parameters for XEmacs, and report. CONFIGURATION specifies the machine and operating system to build for. @@ -154,27 +260,25 @@ Options marked with a (*) are autodetected. - + General options: --help Issue this usage message. --verbose Display the results of configure tests. ---extra-verbose Also display the output of any compiler invocation. - (Useful when feature tests are coming out wrong.) - - -Compiler options: - ---compiler=XXXX Specify compiler. +--extra-verbose Display even more information, useful for debugging. + + +Compilation options: + +--compiler=XXXX Specify compiler. Overrides environment variable CC. --with-gcc (*) Use GCC to compile XEmacs. ---with-lcc Use Lucid's LCC to compile XEmacs. --with-gcc=no Don't use GCC to compile XEmacs. --with-gnu-make Write the Makefiles to take advantage of special features of GNU Make. (GNU Make works fine on the Makefiles even without this option. This just allows for simultaneous in-place and --srcdir building.) ---cflags=FLAGS Override the default values for CFLAGS. +--cflags=FLAGS Compiler flags. Overrides environment variable CFLAGS. --site-includes=DIR Other header file directories. Separate multiple dirs with spaces and use quotes to enclose. --site-libraries=DIR Other library directories. @@ -189,8 +293,8 @@ Installation options: - ---prefix=DIR Install files below DIR. Defaults to \`${prefix}'. + +--prefix=DIR Install files below DIR. Defaults to \`$prefix'. Window-system options: @@ -199,29 +303,49 @@ --with-x=no Don't support X. --x-includes=DIR Search for X header files in DIR. --x-libraries=DIR Search for X libraries in DIR. +--with-toolbars=no Don't compile with any toolbar support. --with-menubars=TYPE Use TYPE menubars (lucid, motif, or no). The Lucid widgets emulate Motif (mostly) but are faster. *WARNING* The Motif menubar is currently broken. ---with-scrollbars=TYPE Use TYPE scrollbars (lucid, motif, athena, - athena3d, or no). +--with-scrollbars=TYPE Use TYPE scrollbars + (lucid, motif, athena, athena3d, or no). --with-dialogs=TYPE Use TYPE dialog boxes (motif, athena, athena3d, or no). (Lucid menubars and scrollbars are the default. Motif dialog boxes will be used if Motif can be found.) --with-cde (*) Compile in support for CDE drag and drop. --with-offix (*) Compile in support for OffiX drag and drop. +--with-xmu=no (*) For those unfortunates whose vendors don't ship Xmu. +--external-widget Compile with external widget support. +--with-gif Compile with support for GIF image conversion. + This support is built-in and defaults to \`yes'. --with-xpm (*) Compile with support for XPM files. It is highly recommended that you obtain XPM - (version 3.4g or better) if you don't already + (version 3.4h or better) if you don't already have it. Get it from the XEmacs FTP site. ---with-xmu=no (*) For those unfortunates whose vendors don't ship Xmu. +--with-xface (*) Compile with support for X-Face mail header + conversion. Requires the compface library. + Get it from the XEmacs FTP site. +--with-jpeg (*) Compile with support for JPEG image conversion. + Requires libjpeg from the Independent JPEG Group. + Get it from the XEmacs FTP site. +--with-png (*) Compile with support for PNG image conversion. + Requires libpng. Get it from the XEmacs FTP site. +--with-tiff Compile with support for TIFF image conversion + (not yet implemented). + + +TTY options: + +--with-ncurses (*) Use the ncurses library for tty support. +--with-gpm (*) Compile in support for General Purpose Mouse. Additional features: ---with-toolbars=no Don't compile with any toolbar support. ---with-tooltalk Support the ToolTalk IPC protocol. ---with-sparcworks Support the Sun Sparcworks development environment. +--with-tooltalk (*) Support the ToolTalk IPC protocol. +--with-workshop Support the Sun WorkShop (formerly Sparcworks) + development environment. --with-energize Support the Lucid Energize development environment. This doesn't currently work. --with-socks Compile with support for SOCKS (an Internet proxy). @@ -231,25 +355,9 @@ used on Linux and other systems. NOTE: We can't guarantee that our TERM support coexists well with standard Internet connections). ---with-xface (*) Compile with support for X-Face mail header - conversion. Requires the compface library. - Get it from the XEmacs FTP site. ---with-gif Compile with support for GIF image conversion. - This requires no special support and defaults to - \`yes'. ---with-jpeg (*) Compile with support for JPEG image conversion. - Requires libjpeg from the Independent JPEG Group. - Get it from the XEmacs FTP site. ---with-png (*) Compile with support for PNG image conversion. - Requires libpng. Get it from the XEmacs FTP site. - Accepted values are \`yes', \`no', and \`gnuz' - if you want to use -lgz instead of -lz. ---with-tiff Compile with support for TIFF image conversion - (not yet implemented). --with-database=type (*) Compile with database support. Valid types are \`no' or a comma-separated list of one or more of \`dbm', \`gnudbm', or \`berkdb'. ---external-widget Compile with external widget support. --with-sound=native (*) Compile with native sound support. --with-sound=nas Compile with network sound support. --with-sound=both Compile with native and network sound support. @@ -259,12 +367,13 @@ --with-mocklisp Compile with Mocklisp support. Don't do this unless you have a Mocklisp program that you need to run. ---usage-tracking Enable some Sun-internal code. If you don't - know what this is, you don't want it. --with-pop support POP for mail retrieval --with-kerberos support Kerberos-authenticated POP --with-hesiod support Hesiod to get the POP server host --with-dnet (*) Compile with support for DECnet. +--mail-locking=TYPE (*) Specify the locking to be used by movemail to prevent + concurrent updates of mail spool files. Valid types + are \`lockf', \`flock', and \`lock-file'. Internationalization options: @@ -278,19 +387,15 @@ then the default is --with-xim=motif, else --with-xim=no. NOTE: On some systems like SunOS4 use of this option will cause XEmacs to crash at startup. ---with-canna Compile with support for Canna (a Japanese input method +--with-canna (*) Compile with support for Canna (a Japanese input method used in conjunction with Mule support). ---with-wnn Compile with support for WNN (a multi-language input method +--with-wnn (*) Compile with support for WNN (a multi-language input method used in conjunction with Mule support). This is beta level code. ---with-wnn6 Compile with support for WNN version 6 +--with-wnn6 (*) Compile with support for WNN version 6 This is alpha level code. ---wnn-includes=DIR Search for WNN header files in DIR. ---wnn-libraries=DIR Search for WNN libraries in DIR. --with-i18n3 Compile with I18N level 3 (support for message translation). This doesn't currently work. ---canna-includes=DIR Search for Canna header files in DIR. ---canna-libraries=DIR Search for Canna libraries in DIR. Debugging options: @@ -314,7 +419,7 @@ int, for the fundamental Lisp_Object type; this provides stricter type-checking. Only works with some systems and compilers. - + Other options: @@ -330,24 +435,23 @@ variables. See the INSTALL file for a complete list plus the reasons we advise not changing them. -If successful, ${progname} leaves its status in config.status. If -unsuccessful after disturbing the status quo, it removes config.status." - -############################################################################ -# # -# Options processing # -# # -############################################################################ - - - -### Record all the arguments, so we can save them in config.status. +If successful, $progname leaves its status in config.status. If +unsuccessful after disturbing the status quo, it removes config.status. + +The configure build process also used the following environment variables: +CC C compiler to use (but configure flags take precedence) +CFLAGS C compiler compilation flags (such as -O) +CPPFLAGS Additional compilation flags (sucha s -I) used only by the preprocessor +LDFLAGS Additional linker flags + +For more details on the install process, consult the INSTALL file. +" + + + + arguments="$@" -### Shell Magic: Quote the quoted arguments in ARGUMENTS. At a later date, -### in order to get the arguments back in $@, we have to do an -### `eval set x "$quoted_arguments"; shift'. -### We use sed to turn embedded ' into '"'"'. I truly hate sh's quoting. quoted_sed_magic=s/"'"/"'"'"'"'"'"'"'"/g quoted_arguments= for i in "$@"; do @@ -362,68 +466,50 @@ esac done -### Don't use shift -- that destroys the argument list, which autoconf needs -### to produce config.status. It turns out that "set - ${arguments}" doesn't -### work portably. -### However, it also turns out that many shells cannot expand ${10} at all. -### So using an index variable doesn't work either. It is possible to use -### some shell magic to make 'set x "$arguments"; shift' work portably. while test $# != 0; do arg="$1"; shift - case "${arg}" in - - ## Anything starting with a hyphen we assume is an option. - -* ) - ## Separate the switch name from the value it's being given. - case "${arg}" in + case "$arg" in + + -* ) + case "$arg" in -*=*) - opt=`echo '' ${arg} | sed -e 's:^ ::' -e 's:^-*\([^=]*\)=.*$:\1:'` - val=`echo '' ${arg} | sed -e 's:^ ::' -e 's:^-*[^=]*=\(.*\)$:\1:'` + opt=`echo '' $arg | sed -e 's:^ ::' -e 's:^-*\([^=]*\)=.*$:\1:'` + val=`echo '' $arg | sed -e 's:^ ::' -e 's:^-*[^=]*=\(.*\)$:\1:'` valomitted=no ;; -# ## special case these strings since echo may -# ## silently eat them. -# --help ) opt=help val=yes valomitted=yes ;; -# --version ) opt=version val=yes valomitted=yes ;; -# -e ) opt=e val=yes valomitted=yes ;; -# -E ) opt=E val=yes valomitted=yes ;; -# -n ) opt=n val=yes valomitted=yes ;; - -*) - ## If FOO is a boolean argument, --FOO is equivalent to - ## --FOO=yes. Otherwise, the value comes from the next - ## argument - see below. - opt=`echo '' ${arg} | sed -e 's:^ ::' -e 's:^-*\(.*\)$:\1:'` + -*) + opt=`echo '' $arg | sed -e 's:^ ::' -e 's:^-*\(.*\)$:\1:'` val="yes" valomitted=yes ;; esac - ## Change `-' in the option name to `_'. - optname="${opt}" - opt="`echo '' ${opt} | sed -e 's:^ ::' | tr - _`" - - ## Process the option. - case "${opt}" in - - ## Process (many) boolean options - run_in_place | \ + optname="$opt" + opt="`echo '' $opt | sed -e 's:^ ::' | tr - _`" + + case "$opt" in + + run_in_place | \ with_x | \ with_x11 | \ with_gcc | \ - with_lcc | \ with_gnu_make | \ dynamic | \ + with_ncurses | \ + with_dnet | \ with_term | \ + with_socks | \ with_cde | \ with_offix | \ - with_xpm | \ + with_gpm | \ with_gif | \ + with_xpm | \ + with_xface | \ with_jpeg | \ + with_png | \ with_tiff | \ - with_socks | \ - with_xface | \ with_xmu | \ - quantify | \ + with_quantify | \ with_toolbars | \ with_tty | \ with_i18n3 | \ @@ -433,6 +519,7 @@ with_wnn6 | \ with_mocklisp | \ with_energize | \ + with_workshop | \ with_sparcworks | \ with_tooltalk | \ with_pop | \ @@ -448,148 +535,125 @@ debug | \ use_assertions | \ memory_usage_stats | \ - no_doc_file ) - ## Make sure the value given was either "yes" or "no". - case "${val}" in + no_doc_file ) + case "$val" in y | ye | yes ) val=yes ;; n | no ) val=no ;; - * ) (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option requires a boolean value: \`yes' or \`no'." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 ;; + * ) (echo "$progname: Usage error:" +echo " " "The \`--$optname' option requires a boolean value: \`yes' or \`no'." +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; esac - eval "${opt}=\"${val}\"" ;; - - - ## Options that take a user-supplied value, as in --puresize=8000000 - srcdir | \ + eval "$opt=\"$val\"" ;; + + + srcdir | \ compiler | \ puresize | \ native_sound_lib | \ x_includes | \ x_libraries | \ - wnn_includes | \ - wnn_libraries | \ - canna_includes | \ - canna_libraries | \ site_includes | \ site_libraries | \ - site_runtime_libraries ) - ## If the value was omitted, get it from the next argument. - if test "${valomitted}" = "yes" ; then - ## Get the next argument from the argument list, if there is one. - if test "$#" = 0 ; then - (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option requires a value." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1; + site_runtime_libraries ) + if test "$valomitted" = "yes" ; then + if test "$#" = 0 ; then + (echo "$progname: Usage error:" +echo " " "The \`--$optname' option requires a value." +echo " Use \`$progname --help' to show usage.") >&2 && exit 1; fi val="$1"; shift fi - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ### Options that take "yes", "no", or "default" values - rel_alloc | \ + rel_alloc | \ use_system_malloc ) - case "${val}" in + case "$val" in y | ye | yes ) val=yes ;; n | no ) val=no ;; d | de | def | defa | defau | defaul | default ) val=default ;; - * ) (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option requires one of these values: + * ) (echo "$progname: Usage error:" +echo " " "The \`--$optname' option requires one of these values: \`yes', \`no', or \`default'." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 ;; +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Has the user requested database support? - "with_database" ) + "with_database" ) with_database_berkdb=no with_database_dbm=no with_database_gnudbm=no - ## Make sure the value given was `no' or a list of berkdb, dbm, gnudbm - for x in `echo "${val}" | sed 's/,/ /'` ; do - case "${x}" in + for x in `echo "$val" | sed 's/,/ /'` ; do + case "$x" in no ) : ;; b | be | ber | berk | berkd | berkdb ) with_database_berkdb=yes ;; d | db | dbm ) with_database_dbm=yes ;; g | gn | gnu | gnud | gnudb | gnudbm ) with_database_gnudbm=yes ;; - * ) (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option value + * ) (echo "$progname: Usage error:" +echo " " "The \`--$optname' option value must be either \`no' or a comma-separated list of one or more of \`berkdb', \`dbm', or \`gnudbm'." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 ;; +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; esac done - if test "${with_database_dbm}" = "yes" -a \ - "${with_database_gnudbm}" = "yes" ; then - (echo "${progname}: Usage error:" + if test "$with_database_dbm" = "yes" -a \ + "$with_database_gnudbm" = "yes" ; then + (echo "$progname: Usage error:" echo " " "Only one of \`dbm' and \`gnudbm' may be specified - with the \`--${optname}' option." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 + with the \`--$optname' option." +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 fi ;; - ## Has the user requested sound support? - "with_sound" ) - ## value can be native, nas or both. yes is allowed - ## as a backwards compatible synonym for native - case "${val}" in + "with_sound" ) + case "$val" in y | ye | yes ) val=native ;; n | no | non | none ) val=no;; na | nat | nati | nativ | native ) val=native ;; - ne | net | neta | netau | netaud | netaudi | netaudio | nas ) val=nas ;; + ne | net | neta | netau | netaud | netaudi | netaudio | nas ) val=nas ;; b | bo | bot | both ) val=both;; - * ) (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option must have one of these values: + * ) (echo "$progname: Usage error:" +echo " " "The \`--$optname' option must have one of these values: \`native', \`nas', \`both', or \`none'." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 ;; +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; esac - eval "${opt}=\"${val}\"" - ;; - - ## Has the user requested XIM support? - "with_xim" ) - ## value can be xlib or motif - case "${val}" in - y | ye | yes ) val=yes ;; - n | no | non | none ) val=no ;; - x | xl | xli | xlib ) val=xlib ;; - m | mo | mot | moti | motif ) val=motif ;; - * ) (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option must have one of these values: - \`motif', \`xlib', \`yes', or \`no'." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 ;; - esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Has the user requested PNG support? - "with_png" ) - ## Make sure the value given was either "yes", "no", or "gnuz". - case "${val}" in - y | ye | yes ) val=yes ;; - n | no ) val=no ;; - g | gn | gnu | gnuz ) val=gnuz ;; - * ) (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option must have one of these values: - \`yes', \`no', or \`gnuz'." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 ;; + "with_xim" ) + case "$val" in + y | ye | yes ) val=yes ;; + n | no | non | none ) val=no ;; + x | xl | xli | xlib ) val=xlib ;; + m | mo | mot | moti | motif ) val=motif ;; + * ) (echo "$progname: Usage error:" +echo " " "The \`--$optname' option must have one of these values: + \`motif', \`xlib', \`yes', or \`no'." +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Has the user requested error-checking? - "error_checking" ) - ## value can be all, none, and/or a list of categories to check. - ## Example: --error-checking=all,noextents,nobufpos - ## Example: --error-checking=none,malloc,gc - - for x in `echo "${val}" | sed 's/,/ /'` ; do - case "${x}" in - # all and none are only permitted as the first in the list. - n | no | non | none ) new_default=no ;; + "mail_locking" ) + case "$val" in + lockf ) val=lockf ;; + flock ) val=flock ;; + file ) val=file ;; + * ) (echo "$progname: Usage error:" +echo " " "The \`--$optname' option must have one of these values: + \`lockf', \`flock', or \`file'." +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; + esac + eval "$opt=\"$val\"" + ;; + + "error_checking" ) + + for x in `echo "$val" | sed 's/,/ /'` ; do + case "$x" in + n | no | non | none ) new_default=no ;; a | al | all ) new_default=yes ;; extents ) error_check_extents=yes ;; @@ -606,7 +670,7 @@ malloc ) error_check_malloc=yes ;; nomalloc ) error_check_malloc=no ;; - + * ) bogus_error_check=yes ;; esac if test "$bogus_error_check" -o \ @@ -616,10 +680,10 @@ else types="\`all', \`none' (default), \`extents', \`typecheck', \`bufpos', \`gc', and \`malloc'." fi - (echo "${progname}: Usage error:" -echo " " "Valid types for the \`--${optname}' option are: + (echo "$progname: Usage error:" +echo " " "Valid types for the \`--$optname' option are: $types." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 elif test "$new_default" ; then error_check_extents=$new_default error_check_typecheck=$new_default @@ -632,253 +696,209 @@ done ;; - ## Has the user tried to tell us where the X files are? - ## I think these are dopey, but no less than three alpha - ## testers, at large sites, have said they have their X files - ## installed in odd places. - - ## Has the user specified one of the path options? - prefix | exec_prefix | bindir | datadir | statedir | libdir | \ + + prefix | exec_prefix | bindir | datadir | statedir | libdir | \ mandir | infodir | lispdir | etcdir | lockdir | archlibdir | \ sitelispdir | docdir ) - ## If the value was omitted, get it from the next argument. - if test "${valomitted}" = "yes" ; then + if test "$valomitted" = "yes" ; then if test "$#" = 0 ; then - (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option requires a value." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1; + (echo "$progname: Usage error:" +echo " " "The \`--$optname' option requires a value." +echo " Use \`$progname --help' to show usage.") >&2 && exit 1; fi val="$1"; shift fi - eval "${opt}=\"${val}\"" - - ## Changing exec_prefix or libdir will change the default value - ## of archlibdir. Changing datadir will change the default value - ## of etcdir and lispdir. Changing statedir will change the - ## default value of lockdir. - if test "${opt}" = exec_prefix; then archlibdir_user_defined=yes - elif test "${opt}" = libdir ; then archlibdir_user_defined=yes - elif test "${opt}" = archlibdir ; then archlibdir_user_defined=yes - elif test "${opt}" = lispdir ; then lispdir_user_defined=yes - elif test "${opt}" = etcdir ; then etcdir_user_defined=yes - elif test "${opt}" = datadir ; then - lispdir_user_defined=yes - etcdir_user_defined=yes - elif test "${opt}" = statedir ; then lockdir_user_defined=yes - elif test "${opt}" = lockdir ; then lockdir_user_defined=yes - elif test "${opt}" = infodir ; then infodir_user_defined=yes - fi + eval "$opt=\"$val\"" + + case "$opt" in + lispdir ) lispdir_user_defined=yes ;; + etcdir ) etcdir_user_defined=yes ;; + infodir ) infodir_user_defined=yes ;; + datadir ) lispdir_user_defined=yes etcdir_user_defined=yes ;; + statedir | lockdir ) lockdir_user_defined=yes ;; + exec_prefix | libdir | archlibdir ) archlibdir_user_defined=yes ;; + esac ;; - ## Has the user specified values to override CFLAGS? - cflags ) - ## If the value was omitted, get it from the next argument. - if test "${valomitted}" = "yes" ; then - if test "$#" = 0 ; then - (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option requires a value." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1; + cflags ) + if test "$valomitted" = "yes" ; then + if test "$#" = 0; then + (echo "$progname: Usage error:" +echo " " "The \`--$optname' option requires a value." +echo " Use \`$progname --help' to show usage.") >&2 && exit 1; fi val="$1"; shift fi - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" eval "${opt}_specified=1" ;; - ## --no-create added by autoconf for use by config.status - "no_create" ) - ;; - - ## Has the user asked for some help? - "usage" | "help" ) - echo "${short_usage}" | ${PAGER:-more} - exit 0 - ;; - - ## Has the user specified what toolkit to use for the menubars, - ## scrollbar or dialogs? - "with_menubars" | "with_scrollbars" | "with_dialogs" ) - ## value can be lucid, motif, or athena. - case "${val}" in + "no_create" ) ;; + + "usage" | "help" ) echo "$usage" | ${PAGER-more}; exit 0 ;; + + "with_menubars" | "with_scrollbars" | "with_dialogs" ) + case "$val" in l | lu | luc | luci | lucid ) val=lucid ;; m | mo | mot | moti | motif ) val=motif ;; athena3d | athena-3d ) val=athena3d ;; a | at | ath | athe | athen | athena ) val=athena ;; n | no | non | none ) val=no ;; - * ) (echo "${progname}: Usage error:" -echo " " "The \`--${optname}' option must have one of these values: - \`lucid', \`motif', \`athena', or \`no'." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 ;; + * ) (echo "$progname: Usage error:" +echo " " "The \`--$optname' option must have one of these values: + \`lucid', \`motif', \`athena', \`athena3d', or \`no'." +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Fail on unrecognized arguments. - * ) (echo "${progname}: Usage error:" -echo " " "Unrecognized option: ${arg}" -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 ;; + * ) (echo "$progname: Usage error:" +echo " " "Unrecognized option: $arg" +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; esac ;; - ## Anything not starting with a hyphen we assume is a - ## configuration name. - *) - configuration=${arg} - ;; + *) configuration="$arg" ;; esac done -############################################################################ -# # -# Finish options processing # -# # -############################################################################ - -### Get the arguments back. See the diatribe on Shell Magic above. + eval set x "$quoted_arguments"; shift -### Argument interdependencies -if test "${with_energize}" = "yes" ; then - with_menubars="lucid" - with_scrollbars="motif" - with_dialogs="motif" - with_tooltalk="yes" - internal_makefile_list="$internal_makefile_list lwlib/energize/Makefile.in" -fi - -### --extra-verbose implies --verbose -test "${extra_verbose}" = yes && verbose=yes - -### Sparcworks requires tooltalk -test "${with_sparcworks}" = yes && with_tooltalk=yes - -### debug implies other options -test "${debug}" = "yes" && use_assertions=yes memory_usage_stats=yes - -### with_x is a synonym for with_x11 -test -n "${with_x}" && with_x11="${with_x}" - -### Can't specify 2 compilers -if test "${with_gcc}" = "yes" -a "${with_lcc}" = "yes"; then - (echo "${progname}: Usage error:" -echo " " "Only one of --with-gcc and --with-lcc may be specified." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 -fi - -### Ignore useless run-in-place flag -if test "${run_in_place}" = "yes"; then - echo "configure: warning: The --run-in-place option is ignored because it is unnecessary." >&2 -fi - -########################################################################### -if test "${configuration}" = "" ; then +if test "$with_energize" = "yes" ; then + with_menubars=lucid with_scrollbars=motif with_dialogs=motif with_tooltalk=yes + MAKE_SUBDIR="$MAKE_SUBDIR lwlib/energize" +fi + +test "$extra_verbose" = "yes" && verbose=yes + +test "$with_sparcworks" = "yes" && with_workshop=yes # compatibility alias +if test "$with_workshop" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining SUNPRO +EOF +cat >> confdefs.h <<\EOF +#define SUNPRO 1 +EOF +} + + extra_objs="$extra_objs sunpro.o" + with_tooltalk=yes +fi + +case "site_includes" in *:* ) site_includes="`echo $site_includes | sed 's/:/ /g'`";; esac +case "site_libraries" in *:* ) site_libraries="`echo $site_libraries | sed 's/:/ /g'`";; esac +case "site_runtime_libraries" in *:* ) site_runtime_libraries="`echo $site_runtime_libraries | sed 's/:/ /g'`";; esac + +if test "$debug" = "yes"; then + use_assertions=yes memory_usage_stats=yes + extra_objs="$extra_objs debug.o" +fi + +test -n "$with_x" && with_x11="$with_x" + +if test "$run_in_place" = "yes"; then + echo "configure: warning: "The --run-in-place option is ignored because it is unnecessary."" 1>&2 +fi + +if test "$configuration" = "" ; then echo '- You did not tell me what kind of host system you want to configure. - I will attempt to guess the kind of system this is.' 1>&2 - guesssys=`echo ${progname} | sed 's/configure$/config.guess/'` - if configuration=`${CONFIG_SHELL-/bin/sh} ${guesssys}` ; then - echo "- Looks like this is a ${configuration}" 1>&2 + guesssys=`echo $progname | sed 's/configure$/config.guess/'` + if configuration=`${CONFIG_SHELL-/bin/sh} $guesssys | \ + sed 's/^\([^-][^-]*-[^-][^-]*-[^-][^-]*\)-.*$/\1/'` ; then + echo "- Looks like this is a $configuration" 1>&2 else - (echo "${progname}: Usage error:" + (echo "$progname: Usage error:" echo " " "Failed to guess the system type. You need to tell me." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 fi fi -### Find the source directory. -case "${srcdir}" in - - ## If it's not specified, see if `.' or `..' might work. - "" ) +case "$srcdir" in + + "" ) for dir in "`echo $0 | sed 's|//|/|' | sed 's|/[^/]*$||'`" "." ".." ; do if test -f "$dir/src/lisp.h" -a \ -f "$dir/lisp/version.el" ; then - srcdir="${dir}" + srcdir="$dir" break fi done - if test -z "${srcdir}" ; then - (echo "${progname}: Usage error:" + if test -z "$srcdir" ; then + (echo "$progname: Usage error:" echo " " "Neither the current directory nor its parent seem to contain the XEmacs sources. If you do not want to build XEmacs in its - source tree, you should run \`${progname}' in the directory in which + source tree, you should run \`$progname' in the directory in which you wish to build XEmacs, using the \`--srcdir' option to say where the sources may be found." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 fi ;; - ## Otherwise, check if the directory they specified is okay. - * ) - if test ! -d "${srcdir}" -o \ - ! -f "${srcdir}/src/lisp.h" -o \ - ! -f "${srcdir}/lisp/version.el" ; then - (echo "${progname}: Usage error:" + * ) + if test ! -d "$srcdir" -o \ + ! -f "$srcdir/src/lisp.h" -o \ + ! -f "$srcdir/lisp/version.el" ; then + (echo "$progname: Usage error:" echo " " "The directory specified with the \`--srcdir' option, - \`${srcdir}', doesn't seem to contain the XEmacs sources. You should - either run the \`${progname}' script at the top of the XEmacs source + \`$srcdir', doesn't seem to contain the XEmacs sources. You should + either run the \`$progname' script at the top of the XEmacs source tree, or use the \`--srcdir' option to specify the XEmacs source directory." -echo " Use \`${progname} --help' for more details.") >&2 && exit 1 +echo " Use \`$progname --help' to show usage.") >&2 && exit 1 fi ;; esac -## We check for this now instead of later when we check for other -## programs because we need to use its return value now. -test -n "$silent" || echo "checking for ln -s" +echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 +echo "configure:857: checking whether ln -s works" >&5 + rm -f conftestdata if ln -s X conftestdata 2>/dev/null then rm -f conftestdata - LN_S="ln -s" -else - LN_S=ln -fi - - - -test -n "$verbose" && echo " "setting LN_S to ${LN_S}"" - -#### Make symlinks for etc, lisp, and info directories while the path -#### is still relative. We don't symlink lock because someone may -#### have stuck the source on a read-only partition. Instead we'll -#### create it as an actual directory later on if it doesn't already -#### exist. + ac_cv_prog_LN_S="ln -s" +else + ac_cv_prog_LN_S=ln +fi +LN_S="$ac_cv_prog_LN_S" +if test "$ac_cv_prog_LN_S" = "ln -s"; then + echo "$ac_t""yes" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + for dir in lisp etc man info site-lisp do - if test ! -d $dir ; then - echo Making symbolic link to ${srcdir}/$dir - ${LN_S} ${srcdir}/$dir . + if test ! -d "$dir" ; then + echo Making symbolic link to "$srcdir/$dir" + ${LN_S} "$srcdir/$dir" . fi done -#### Make srcdir absolute, if it isn't already. It's important to -#### avoid running the path through pwd unnecessary, since pwd can -#### give you automounter prefixes, which can go away. -case "${srcdir}" in +case "$srcdir" in /* ) ;; . ) - ## We may be able to use the $PWD environment variable to make this - ## absolute. But sometimes PWD is inaccurate. - if test "${PWD}" != "" -a "`(cd ${PWD} ; sh -c pwd)`" = "`pwd`"; then + if test "$PWD" != "" -a "`(cd $PWD ; sh -c pwd)`" = "`pwd`"; then srcdir="$PWD" else - srcdir="`(cd ${srcdir}; pwd)`" + srcdir="`(cd $srcdir && pwd)`" fi ;; - * ) srcdir="`(cd ${srcdir}; pwd)`" ;; + * ) srcdir="`(cd $srcdir && pwd)`" ;; esac -#### Check if the source directory already has a configured system in it. -if test `pwd` != `sh -c cd ${srcdir} && pwd` \ - && test -f "${srcdir}/src/config.h"; then - (echo "${progname}: WARNING: The directory tree \`${srcdir}' is being used" +if test `pwd` != `sh -c cd $srcdir && pwd` \ + && test -f "$srcdir/src/config.h"; then + (echo "$progname: WARNING: The directory tree \`$srcdir' is being used" echo " as a build directory right now; it has been configured in its own" echo " right. To configure in another directory as well, you MUST" echo " use GNU make. If you do not have GNU make, then you must" - echo " now do \`make distclean' in ${srcdir}," - echo " and then run ${progname} again.") >&2 + echo " now do \`make distclean' in $srcdir," + echo " and then run $progname again.") >&2 extrasub='/^VPATH[ ]*=/c\ vpath %.c $(srcdir)\ vpath %.h $(srcdir)\ @@ -888,256 +908,183 @@ vpath %.in $(srcdir)' fi -### Make the necessary directories, if they don't exist. for dir in ./src ./lib-src ./dynodump ./lwlib ./lock ; do - if test ! -d ${dir} ; then - mkdir ${dir} - fi + test ! -d "$dir" && mkdir "$dir" done -if test "${with_energize}" = "yes" -a ! -d ./lwlib/energize; then +if test "$with_energize" = "yes" -a ! -d ./lwlib/energize; then mkdir ./lwlib/energize fi -############################################################################ -# # -# Determine the s&m files to use # -# # -############################################################################ - -#### Given the configuration name, set machfile and opsysfile to the -#### names of the m/*.h and s/*.h files we should use. - -### Canonicalize the configuration name. -echo "checking the configuration name" -# allow -energize prefix on configuration name -internal_configuration=`echo ${configuration} | sed 's/-energize//'` -# allow --sparcworks prefix on configuration name -internal_configuration=`echo ${configuration} | sed 's/-sparcworks//'` -if canonical=`${srcdir}/config.sub "${internal_configuration}"` ; then : ; else + +echo "checking "the configuration name"" 1>&6 +echo "configure:921: checking "the configuration name"" >&5 +internal_configuration=`echo $configuration | sed 's/-\(energize\|workshop\)//'` +if canonical=`$srcdir/config.sub "$internal_configuration"` ; then : ; else exit $? fi -### If you add support for a new configuration, add code to this -### switch statement to recognize your configuration name and select -### the appropriate operating system and machine description files. - -### You would hope that you could choose an m/*.h file pretty much -### based on the machine portion of the configuration name, and an s- -### file based on the operating system portion. However, it turns out -### that each m/*.h file is pretty manufacturer-specific - for -### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are -### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS -### machines. So we basically have to have a special case for each -### configuration name. -### -### As far as handling version numbers on operating systems is -### concerned, make sure things will fail in a fixable way. If -### /etc/MACHINES doesn't say anything about version numbers, be -### prepared to handle anything reasonably. If version numbers -### matter, be sure /etc/MACHINES says something about it. -### -### Eric Raymond says we should accept strings like "sysvr4" to mean -### "System V Release 4"; he writes, "The old convention encouraged -### confusion between `system' and `release' levels'." - -machine='' opsys='' unported=no need_dynodump=no -case "${canonical}" in - - ## NetBSD ports - *-*-netbsd* ) - opsys=netbsd - case "${canonical}" in - sparc-*-netbsd*) machine=sparc ;; + + + + +machine='' opsys='' need_dynodump=no + +case "$canonical" in + sparc-*-* ) machine=sparc ;; + alpha-*-* ) machine=alpha ;; + vax-*-* ) machine=vax ;; + mips-dec-* ) machine=pmax ;; + mips-sgi-* ) machine=iris4d ;; + romp-ibm-* ) machine=ibmrt ;; + rs6000-ibm-aix* ) machine=ibmrs6000 ;; + powerpc-ibm-aix* ) machine=ibmrs6000 ;; + powerpc-*-* ) machine=powerpc ;; + hppa-*-* ) machine=hp800 ;; + m88k-dg-* ) machine=aviion ;; + m68*-sony-* ) machine=news ;; + mips-sony-* ) machine=news-risc ;; + clipper-* ) machine=clipper ;; +esac + +case "$canonical" in + *-*-linux* ) opsys=linux ;; + *-*-netbsd* ) opsys=netbsd ;; + *-*-nextstep* ) opsys=nextstep ;; + *-*-vms ) opsys=vms ;; + + *-dec-osf1.3 | *-dec-osf2* ) opsys=decosf1-3 ;; + *-dec-osf1.2 | *-dec-osf1* ) opsys=decosf1-2 ;; + *-dec-osf3.[2-9] ) opsys=decosf3-2 ;; + *-dec-osf3* ) opsys=decosf3-1 ;; + *-dec-osf4* ) opsys=decosf4-0 ;; + + *-*-ultrix[0-3].* | *-*-ultrix4.0* ) opsys=bsd4-2 ;; + *-*-ultrix4.[12]* ) opsys=bsd4-3 ;; + *-*-ultrix* ) opsys=ultrix4-3 ;; + + *-*-aix3.1* ) opsys=aix3-1 ;; + *-*-aix3.2.5 ) opsys=aix3-2-5 ;; + *-*-aix3* ) opsys=aix3-2 ;; + *-*-aix4.2* ) opsys=aix4-2 ;; + *-*-aix4.1* ) opsys=aix4-1 ;; + *-*-aix4* ) opsys=aix4 ;; + + *-gnu* ) opsys=gnu ;; + *-*-bsd4.[01] ) opsys=bsd4-1 ;; + *-*-bsd4.2 ) opsys=bsd4-2 ;; + *-*-bsd4.3 ) opsys=bsd4-3 ;; + *-*-aos4.2 ) opsys=bsd4-2 ;; + *-*-aos* ) opsys=bsd4-3 ;; + *-*-sysv0 | *-*-sysvr0 ) opsys=usg5-0 ;; + *-*-sysv2 | *-*-sysvr2 ) opsys=usg5-2 ;; + *-*-sysv2.2 | *-*-sysvr2.2 ) opsys=usg5-2-2 ;; + *-*-sysv3* | *-*-sysvr3* ) opsys=usg5-3 ;; + *-*-sysv4.1* | *-*-sysvr4.1* )opsys=usg5-4 NON_GNU_CPP=/usr/lib/cpp ;; + *-*-sysv4.[2-9]* | *-sysvr4.[2-9]* ) + if test -z "$NON_GNU_CPP" ; then + if test -f /usr/ccs/lib/cpp + then NON_GNU_CPP=/usr/ccs/lib/cpp + else NON_GNU_CPP=/lib/cpp + fi + fi + opsys=usg5-4-2 ;; + *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;; + *-*-mach_bsd4.3* ) opsys=mach-bsd4-3 ;; +esac + +case "$canonical" in + + *-*-netbsd* ) + case "$canonical" in i[3-9]86-*-netbsd*) machine=intel386 ;; hp300-*-netbsd* | amiga-*-netbsd* | sun3-*-netbsd* | mac68k-*-netbsd* | da30-*-netbsd* | m68k-*-netbsd* ) - # Yes, this is somewhat bogus. - machine=hp9000s300 ;; + machine=hp9000s300 ;; pc532-*-netbsd* | ns32k-*-netbsd* ) machine=ns32000 ;; pmax-*-netbsd* | mips-*-netbsd* ) machine=pmax ;; esac ;; - ## Acorn RISCiX: - arm-acorn-riscix1.1* ) machine=acorn opsys=riscix1-1 ;; + arm-acorn-riscix1.1* ) machine=acorn opsys=riscix1-1 ;; arm-acorn-riscix1.2* | arm-acorn-riscix ) machine=acorn opsys=riscix1-2 ;; - ## Alliant machines - ## Strictly speaking, we need the version of the alliant operating - ## system to choose the right machine file, but currently the - ## configuration name doesn't tell us enough to choose the right - ## one; we need to give alliants their own operating system name to - ## do this right. When someone cares, they can help us. - fx80-alliant-* ) machine=alliant4 opsys=bsd4-2 ;; + fx80-alliant-* ) machine=alliant4 opsys=bsd4-2 ;; i860-alliant-* ) machine=alliant-2800 opsys=bsd4-3 ;; - ## Alpha (DEC) machines. - ## XEmacs change: split apart into numerous files. - alpha-*-* ) - machine=alpha - case "${canonical}" in - *-dec-osf1.3 | *-dec-osf2* ) opsys=decosf1-3 ;; - *-dec-osf1.2 | *-dec-osf1* ) opsys=decosf1-2 ;; - - ## XEmacs: Add switch for OSF 1 version 3 (roth@cse.ucsc.edu) - ## XEmacs: Add switch for Digital Unix version 4 (srivasta@pilgrim.umass.edu) - *-dec-osf3.[2-9] ) opsys=decosf3-2 ;; - *-dec-osf3* ) opsys=decosf3-1 ;; - *-dec-osf4* ) opsys=decosf4-0 ;; - *-*-linux* ) opsys=linux ;; - esac - ;; - - ## Altos 3068 - m68*-altos-sysv* ) machine=altos opsys=usg5-2 ;; - - ## Amdahl UTS - 580-amdahl-sysv* ) machine=amdahl opsys=usg5-2-2 ;; - - ## Apollo, Domain/OS - m68*-apollo-* ) machine=apollo opsys=bsd4-3 ;; - - ## AT&T 3b2, 3b5, 3b15, 3b20 - we32k-att-sysv* ) machine=att3b opsys=usg5-2-2 ;; - - ## AT&T 3b1 - The Mighty Unix PC! - m68*-att-sysv* ) machine=7300 opsys=usg5-2-2 ;; - - ## Bull machines - rs6000-bull-bosx* ) machine=ibmrs6000 opsys=aix3-2 ;; # dpx20 + m68*-altos-sysv* ) machine=altos opsys=usg5-2 ;; + + 580-amdahl-sysv* ) machine=amdahl opsys=usg5-2-2 ;; + + m68*-apollo-* ) machine=apollo opsys=bsd4-3 ;; + + we32k-att-sysv* ) machine=att3b opsys=usg5-2-2 ;; + + m68*-att-sysv* ) machine=7300 opsys=usg5-2-2 ;; + + rs6000-bull-bosx* ) machine=ibmrs6000 opsys=aix3-2 ;; # dpx20 m68*-bull-sysv3* ) machine=dpx2 opsys=usg5-3 ;; # dpx2 m68*-bull-sysv2* ) machine=sps7 opsys=usg5-2 ;; # sps7 - ## CCI 5/32, 6/32 -- see "Tahoe". - - ## Celerity - ## I don't know what configuration name to use for this; config.sub - ## doesn't seem to know anything about it. Hey, Celerity users, get - ## in touch with us! - celerity-celerity-bsd* ) machine=celerity opsys=bsd4-2 ;; - - ## Clipper - ## What operating systems does this chip run that XEmacs has been - ## tested on? - clipper-* ) machine=clipper - ## We'll use the catch-all code at the bottom to guess the - ## operating system. - ;; - - ## Convex - *-convex-bsd* | *-convex-convexos* ) + + celerity-celerity-bsd* ) machine=celerity opsys=bsd4-2 ;; + + *-convex-bsd* | *-convex-convexos* ) machine=convex opsys=bsd4-3 - ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov NON_GNU_CPP="cc -E -P" ;; - ## Cubix QBx/386 - i[3-9]86-cubix-sysv* ) machine=intel386 opsys=usg5-3 ;; - - ## Cydra 5 - cydra*-cydrome-sysv* ) machine=cydra5 opsys=usg5-3 ;; - - ## Data General AViiON Machines - i586-dg-dgux*R4* | i586-dg-dgux5.4.4* ) machine=aviion opsys=dgux5-4r4 ;; - m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* ) machine=aviion opsys=dgux5-4r3 ;; - m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* ) machine=aviion opsys=dgux5-4r2 ;; - m88k-dg-dgux* ) machine=aviion opsys=dgux ;; - - ## Dec Mips machines - mips-dec-* ) - machine=pmax - case "${canonical}" in - *-*-ultrix[0-3].* | *-*-ultrix4.0* | *-*-bsd4.2* ) opsys=bsd4-2 ;; - *-*-ultrix4.[12]* | *-*-bsd* ) opsys=bsd4-3 ;; - *-*-ultrix* ) opsys=ultrix4-3 ;; - *-*-osf* ) opsys=osf1 ;; - *-*-mach_bsd4.3* ) opsys=mach-bsd4-3 ;; - esac - ;; - - ## Motorola Delta machines - m68k-motorola-sysv* | m68000-motorola-sysv* ) - machine=delta opsys=usg5-3 - if test -z "`type gnucc | grep 'not found'`" - then - if test -s /etc/167config - then CC="gnucc -m68040" - else CC="gnucc -m68881" - fi - else - if test -z "`type gcc | grep 'not found'`" - then CC=gcc - else CC=cc - fi - fi - ;; + i[3-9]86-cubix-sysv* ) machine=intel386 opsys=usg5-3 ;; + + cydra*-cydrome-sysv* ) machine=cydra5 opsys=usg5-3 ;; + + i586-dg-dgux*R4* | i586-dg-dgux5.4.4* ) machine=aviion opsys=dgux5-4r4 ;; + m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* ) opsys=dgux5-4r3 ;; + m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* ) opsys=dgux5-4r2 ;; + m88k-dg-dgux* ) opsys=dgux ;; + + m68k-motorola-sysv* | m68000-motorola-sysv* ) machine=delta opsys=usg5-3 ;; m88k-motorola-sysv4* ) - # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110 - # needs POSIX_SIGNALS and therefore needs usg5-4-2. - # I hope there are not other 4.0 versions for this machine - # which really need usg5-4 instead. - machine=delta88k opsys=usg5-4-2 + machine=delta88k opsys=usg5-4-2 ;; m88k-motorola-sysv* | m88k-motorola-m88kbcs* ) machine=delta88k opsys=usg5-3 ;; - ## Dual machines - m68*-dual-sysv* ) machine=dual opsys=usg5-2 ;; + m68*-dual-sysv* ) machine=dual opsys=usg5-2 ;; m68*-dual-uniplus* ) machine=dual opsys=unipl5-2 ;; - ## Elxsi 6400 - elxsi-elxsi-sysv* ) machine=elxsi opsys=usg5-2 ;; - - ## Encore machines - ns16k-encore-bsd* ) machine=ns16000 opsys=umax ;; - - ## Gould Power Node and NP1 - pn-gould-bsd4.2* ) machine=gould opsys=bsd4-2 ;; + elxsi-elxsi-sysv* ) machine=elxsi opsys=usg5-2 ;; + + ns16k-encore-bsd* ) machine=ns16000 opsys=umax ;; + + pn-gould-bsd4.2* ) machine=gould opsys=bsd4-2 ;; pn-gould-bsd4.3* ) machine=gould opsys=bsd4-3 ;; np1-gould-bsd* ) machine=gould-np1 opsys=bsd4-3 ;; - ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000 - ## as far as XEmacs is concerned). - m88k-harris-cxux* ) - # Build needs to be different on 7.0 and later releases - case "`uname -r`" in + m88k-harris-cxux* ) + case "`uname -r`" in [56].[0-9] ) machine=nh4000 opsys=cxux ;; [7].[0-9] ) machine=nh4000 opsys=cxux7 ;; esac NON_GNU_CPP="/lib/cpp" ;; - ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000) - m68k-harris-cxux* ) machine=nh3000 opsys=cxux ;; - ## Harris power pc NightHawk running Power UNIX (Series 6000) - powerpc-harris-powerunix ) - machine=nh6000 opsys=powerunix - NON_GNU_CPP="cc -Xo -E -P" - ;; - - ## Honeywell XPS100 - xps*-honeywell-sysv* ) machine=xps100 opsys=usg5-2 ;; - - ## HP 9000 series 200 or 300 - m68*-hp-bsd* ) machine=hp9000s300 opsys=bsd4-3 ;; - - ## HP-UX on HP's - *-hp-hpux* ) - NON_GNU_CC="cc -Aa" - NON_GNU_CPP="cc -Aa -E" - - ### Figure out machine and opsys orthogonally - case "${canonical}" in + m68k-harris-cxux* ) machine=nh3000 opsys=cxux ;; + powerpc-harris-powerunix ) machine=nh6000 opsys=powerunix NON_GNU_CPP="cc -Xo -E -P" ;; + + xps*-honeywell-sysv* ) machine=xps100 opsys=usg5-2 ;; + + m68*-hp-bsd* ) machine=hp9000s300 opsys=bsd4-3 ;; + + *-hp-hpux* ) + case "$canonical" in m68* ) machine=hp9000s300 ;; hppa* ) machine=hp800 ;; esac - case "${canonical}" in - *-hp-hpux7* ) opsys=hpux ;; - *-hp-hpux8* ) opsys=hpux8 ;; - *-hp-hpux9* ) opsys=hpux9 ;; - *-hp-hpux10* ) opsys=hpux10 ;; + case "$canonical" in + *-hp-hpux7* ) opsys=hpux ;; + *-hp-hpux8* ) opsys=hpux8 ;; + *-hp-hpux9* ) opsys=hpux9 ;; + *-hp-hpux10* ) opsys=hpux10 ;; * ) case "`uname -r`" in - ## Someone's system reports A.B8.05 for this. - ## I wonder what other possibilities there are. *.B8.* ) opsys=hpux8 ;; *.08.* ) opsys=hpux8 ;; *.09.* ) opsys=hpux9 ;; @@ -1147,99 +1094,51 @@ ;; esac - if test $opsys = hpux10 ; then - NON_GNU_CC="cc -Ae" - NON_GNU_CPP="cc -Ae -E" - fi - - case "${canonical}" in *-hp-hpux*shr* ) opsys="${opsys}-shr" ;; esac + case "$opsys" in hpux9 | hpux10 ) extra_objs="$extra_objs strcat.o";; esac + + if test "$opsys" = "hpux10"; then ansi_flag="-Ae"; else ansi_flag="-Aa"; fi + NON_GNU_CC="cc $ansi_flag" NON_GNU_CPP="cc $ansi_flag -E" + + case "$canonical" in *-hp-hpux*shr* ) opsys="${opsys}-shr" ;; esac ;; - hppa-*-nextstep* ) machine=hp800 opsys=nextstep ;; - - ## Orion machines - orion-orion-bsd* ) machine=orion opsys=bsd4-2 ;; + orion-orion-bsd* ) machine=orion opsys=bsd4-2 ;; clipper-orion-bsd* ) machine=orion105 opsys=bsd4-2 ;; - ## IBM machines - i[3-9]86-ibm-aix1.1* ) machine=ibmps2-aix opsys=usg5-2-2 ;; + i[3-9]86-ibm-aix1.1* ) machine=ibmps2-aix opsys=usg5-2-2 ;; i[3-9]86-ibm-aix1.[23]* | i[3-9]86-ibm-aix* ) machine=ibmps2-aix opsys=usg5-3 ;; i370-ibm-aix*) machine=ibm370aix opsys=usg5-3 ;; - rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* ) machine=ibmrs6000 opsys=aix3-1 ;; - rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 ) machine=ibmrs6000 opsys=aix3-2-5 ;; - rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* ) machine=ibmrs6000 opsys=aix4-2 ;; - rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* ) machine=ibmrs6000 opsys=aix4-1 ;; - rs6000-ibm-aix4* | powerpc-ibm-aix4* ) machine=ibmrs6000 opsys=aix4 ;; - rs6000-ibm-aix* | powerpc-ibm-aix* ) machine=ibmrs6000 opsys=aix3-2 ;; - romp-ibm-bsd4.3* ) machine=ibmrt opsys=bsd4-3 ;; - romp-ibm-bsd4.2* ) machine=ibmrt opsys=bsd4-2 ;; - romp-ibm-aos4.3* ) machine=ibmrt opsys=bsd4-3 ;; - romp-ibm-aos4.2* ) machine=ibmrt opsys=bsd4-2 ;; - romp-ibm-aos* ) machine=ibmrt opsys=bsd4-3 ;; - romp-ibm-bsd* ) machine=ibmrt opsys=bsd4-3 ;; - romp-ibm-aix* ) machine=ibmrt-aix opsys=usg5-2-2 ;; - romp-ibm-mach* ) machine=ibmrt opsys=mach-bsd4-3 ;; - - ## Integrated Solutions `Optimum V' - m68*-isi-bsd4.2* ) machine=isi-ov opsys=bsd4-2 ;; + romp-ibm-aos* ) opsys=bsd4-3 ;; + romp-ibm-bsd* ) opsys=bsd4-3 ;; + romp-ibm-mach* ) opsys=mach-bsd4-3 ;; + + m68*-isi-bsd4.2* ) machine=isi-ov opsys=bsd4-2 ;; m68*-isi-bsd4.3* ) machine=isi-ov opsys=bsd4-3 ;; - ## Intel 386 machines where we do care about the manufacturer - i[3-9]86-intsys-sysv* ) machine=is386 opsys=usg5-2-2 ;; - - ## Prime EXL - i[3-9]86-prime-sysv* ) machine=i386 opsys=usg5-3 ;; - - ## Sequent Symmetry running Dynix - i[3-9]86-sequent-bsd* ) machine=symmetry opsys=bsd4-3 ;; - - ## Sequent Symmetry running DYNIX/ptx - ## Use the old cpp rather than the newer ANSI one. - i[3-9]86-sequent-ptx* ) - machine=sequent-ptx opsys=ptx - NON_GNU_CPP="/lib/cpp" - ;; - - ## Unspecified sysv on an ncr machine defaults to svr4.2. - ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.) - i[3-9]86-ncr-sysv* ) machine=ncr386 opsys=usg5-4-2 ;; - - ## Intel Paragon OSF/1 - i860-intel-osf1* ) machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp ;; - - ## Intel 860 - i860-*-sysv4* ) - machine=i860 opsys=usg5-4 - NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc. - NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion. - ;; - - ## Masscomp machines - m68*-masscomp-rtu* ) machine=masscomp opsys=rtu ;; - - ## Megatest machines - m68*-megatest-bsd* ) machine=mega68 opsys=bsd4-2 ;; - - ## Workstations sold by MIPS - ## This is not necessarily all workstations using the MIPS processor - - ## Irises are produced by SGI, and DECstations by DEC. - - ## etc/MACHINES lists mips.h and mips4.h as possible machine files, - ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance - ## it gives for choosing between the alternatives seems to be "Use - ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with - ## the BSD world." I'll assume that these are instructions for - ## handling two odd situations, and that every other situation - ## should use mips.h and usg5-2-2, they being listed first. - mips-mips-usg* ) - machine=mips4 - ## Fall through to the general code at the bottom to decide on the OS. - ;; + i[3-9]86-intsys-sysv* ) machine=is386 opsys=usg5-2-2 ;; + + i[3-9]86-prime-sysv* ) machine=i386 opsys=usg5-3 ;; + + i[3-9]86-sequent-bsd* ) machine=symmetry opsys=bsd4-3 ;; + + i[3-9]86-sequent-ptx* ) machine=sequent-ptx opsys=ptx NON_GNU_CPP="/lib/cpp" ;; + + i[3-9]86-ncr-sysv* ) machine=ncr386 opsys=usg5-4-2 ;; + + i860-intel-osf1* ) machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp ;; + + i860-*-sysv4* ) machine=i860 opsys=usg5-4 NON_GNU_CC="/bin/cc" NON_GNU_CPP="/usr/ccs/lib/cpp" ;; + + m68*-masscomp-rtu* ) machine=masscomp opsys=rtu ;; + + m68*-megatest-bsd* ) machine=mega68 opsys=bsd4-2 ;; + + mips-mips-usg* ) machine=mips4 ;; mips-mips-riscos4 ) machine=mips4 NON_GNU_CC="cc -systype bsd43" NON_GNU_CPP="cc -systype bsd43 -E" - case "${canonical}" in + case "$canonical" in mips-mips-riscos4* ) opsys=bsd4-3 ;; mips-mips-riscos5* ) opsys=riscos5 ;; esac @@ -1247,105 +1146,70 @@ mips-mips-bsd* ) machine=mips opsys=bsd4-3 ;; mips-mips-* ) machine=mips opsys=usg5-2-2 ;; - ## NeXT - m68*-next-* | m68k-*-nextstep* ) machine=m68k opsys=nextstep ;; - - ## The complete machine from National Semiconductor - ns32k-ns-genix* ) machine=ns32000 opsys=usg5-2 ;; - - ## NCR machines - m68*-ncr-sysv2* | m68*-ncr-sysvr2* ) machine=tower32 opsys=usg5-2-2 ;; + m68*-next-* | m68k-*-nextstep* ) machine=m68k opsys=nextstep ;; + + ns32k-ns-genix* ) machine=ns32000 opsys=usg5-2 ;; + + m68*-ncr-sysv2* | m68*-ncr-sysvr2* ) machine=tower32 opsys=usg5-2-2 ;; m68*-ncr-sysv3* | m68*-ncr-sysvr3* ) machine=tower32v3 opsys=usg5-3 ;; - ## Nixdorf Targon 31 - m68*-nixdorf-sysv* ) machine=targon31 opsys=usg5-2-2 ;; - - ## Nu (TI or LMI) - m68*-nu-sysv* ) machine=nu opsys=usg5-2 ;; - - ## Plexus - m68*-plexus-sysv* ) machine=plexus opsys=usg5-2 ;; - - ## Pyramid machines - ## I don't really have any idea what sort of processor the Pyramid has, - ## so I'm assuming it is its own architecture. - pyramid-pyramid-bsd* ) machine=pyramid opsys=bsd4-2 ;; - - ## Sequent Balance - ns32k-sequent-bsd4.2* ) machine=sequent opsys=bsd4-2 ;; + m68*-nixdorf-sysv* ) machine=targon31 opsys=usg5-2-2 ;; + + m68*-nu-sysv* ) machine=nu opsys=usg5-2 ;; + + m68*-plexus-sysv* ) machine=plexus opsys=usg5-2 ;; + + pyramid-pyramid-bsd* ) machine=pyramid opsys=bsd4-2 ;; + + ns32k-sequent-bsd4.2* ) machine=sequent opsys=bsd4-2 ;; ns32k-sequent-bsd4.3* ) machine=sequent opsys=bsd4-3 ;; - ## Siemens Nixdorf - mips-siemens-sysv* | mips-sni-sysv*) + mips-siemens-sysv* | mips-sni-sysv*) machine=mips-siemens opsys=usg5-4 NON_GNU_CC=/usr/ccs/bin/cc NON_GNU_CPP=/usr/ccs/lib/cpp ;; - ## Silicon Graphics machines - ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030) - m68*-sgi-iris3.5* ) machine=irist opsys=iris3-5 ;; + m68*-sgi-iris3.5* ) machine=irist opsys=iris3-5 ;; m68*-sgi-iris3.6* | m68*-sgi-iris*) machine=irist opsys=iris3-6 ;; - ## Iris 4D - mips-sgi-irix3.* ) machine=iris4d opsys=irix3-3 ;; - mips-sgi-irix4.* ) machine=iris4d opsys=irix4-0 ;; - mips-sgi-irix6* ) machine=iris4d opsys=irix6-0 NON_GNU_CC="cc -Olimit 2000" ;; - mips-sgi-irix5.[3-9]* ) machine=iris4d opsys=irix5-3 ;; - mips-sgi-irix5.2* ) machine=iris4d opsys=irix5-2 ;; - mips-sgi-irix5.1* ) machine=iris4d opsys=irix5-1 ;; - mips-sgi-irix* ) machine=iris4d opsys=irix5-0 ;; - - ## SONY machines - m68*-sony-bsd4.2* ) machine=news opsys=bsd4-2 ;; - m68*-sony-bsd4.3* ) machine=news opsys=bsd4-3 ;; - m68*-sony-newsos3* | m68*-sony-news3*) machine=news opsys=bsd4-3 ;; - mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*) machine=news-risc opsys=bsd4-3 ;; - mips-sony-news* ) machine=news-risc opsys=newsos5 ;; - - ## Stride - m68*-stride-sysv* ) machine=stride opsys=usg5-2 ;; - - ## Suns - sparc-*-linux* ) machine=sparc opsys=linux ;; - - *-*-solaris* | *-*-sunos* | *-sun-mach* | *-sun-bsd* ) - # Hardware type - case "${canonical}" in + mips-sgi-irix3.* ) opsys=irix3-3 ;; + mips-sgi-irix4.* ) opsys=irix4-0 ;; + mips-sgi-irix6* ) opsys=irix6-0 NON_GNU_CC="cc -Olimit 2000" ;; + mips-sgi-irix5.1* ) opsys=irix5-1 ;; + mips-sgi-irix5.2* ) opsys=irix5-2 ;; + mips-sgi-irix5.* ) opsys=irix5-3 ;; + mips-sgi-irix* ) opsys=irix5-0 ;; + + *-sony-newsos[34]* | *-sony-news[34]* ) opsys=bsd4-3 ;; + *-sony-news* ) opsys=newsos5 ;; + + m68*-stride-sysv* ) machine=stride opsys=usg5-2 ;; + + *-*-solaris* | *-*-sunos* | *-sun-mach* | *-sun-bsd* ) + case "$canonical" in m68*-sunos1* ) machine=sun1 ;; m68*-sunos2* ) machine=sun2 ;; m68* ) machine=sun3 ;; i[3-9]86*-sun-sunos[34]* ) machine=sun386 ;; i[3-9]86-*-* ) machine=intel386 ;; rs6000* ) machine=rs6000 ;; - sparc* ) machine=sparc ;; - powerpc* ) machine=powerpc ;; - * ) unported=yes ;; esac - - # Make `canonical' even more so. - case "${canonical}" in *-sunos5*) - canonical="`echo \"${canonical}\" | sed -e s/sunos5/solaris2/`";; + + case "$canonical" in *-sunos5*) + canonical="`echo \"$canonical\" | sed -e s/sunos5/solaris2/`";; esac - # On SunOS 4, use /usr/lib/cpp, sans dynodump, /bin/ranlib - # On SunOS 5, use /usr/ccs/lib/cpp, need dynodump, RANLIB not needed - # But, SunOS 5.6 no longer needs dynodump because it has a similar - # function integrated. - case "${canonical}" in + case "$canonical" in *-sunos4* ) test -f /usr/lib/cpp && NON_GNU_CPP=/usr/lib/cpp ;; *-solaris2* ) test -f /usr/ccs/lib/cpp && NON_GNU_CPP=/usr/ccs/lib/cpp RANLIB=':' - case "${canonical}" in - *-solaris2.[6-9]* ) need_dynodump=no ;; - *-solaris2* ) need_dynodump=yes ;; + case "$canonical" in *-solaris2.[0-5]* ) need_dynodump=yes ;; esac esac - esac - - case "${canonical}" in - ## The Sun386 didn't get past 4.0. - i[3-9]86-*-sunos4* ) opsys=sunos4-0 ;; + + case "$canonical" in + i[3-9]86-*-sunos4*) opsys=sunos4-0 ;; *-sunos4.0* ) opsys=sunos4-0 ;; *-sunos4.1.2* ) opsys=sunos4-1-2 ;; *-sunos4.1.3* ) opsys=sunos4-1-3 ;; @@ -1362,69 +1226,44 @@ * ) opsys=bsd4-2 ;; esac - case "${canonical}" in *-sunos4*shr* ) opsys="${opsys}-shr" ;; esac - - ## Watch out for a compiler that is guaranteed not to work. - case "${canonical}" in - *-solaris* ) test "$CC" = "/usr/ucb/cc" && unset CC ;; + case "$canonical" in *-sunos4*shr* ) opsys="${opsys}-shr" ;; esac + + case "$canonical" in + *-solaris* ) case "$CC" in /usr/ucb/cc* ) CC="" ;; esac ;; esac ;; - sparc-*-nextstep* ) machine=sparc opsys=nextstep ;; - - ## Tadpole 68k - m68*-tadpole-sysv* ) machine=tad68k opsys=usg5-3 ;; - - ## Tahoe machines - tahoe-tahoe-bsd4.2* ) machine=tahoe opsys=bsd4-2 ;; + m68*-tadpole-sysv* ) machine=tad68k opsys=usg5-3 ;; + + tahoe-tahoe-bsd4.2* ) machine=tahoe opsys=bsd4-2 ;; tahoe-tahoe-bsd4.3* ) machine=tahoe opsys=bsd4-3 ;; - ## Tandem Integrity S2 - mips-tandem-sysv* ) machine=tandem-s2 opsys=usg5-3 ;; - - ## Tektronix XD88 - m88k-tektronix-sysv3* ) machine=tekxd88 opsys=usg5-3 ;; - - ## Tektronix 16000 box (6130?) - ns16k-tektronix-bsd* ) machine=ns16000 opsys=bsd4-2 ;; - ## Tektronix 4300 - ## src/m/tek4300.h hints that this is a m68k machine. - m68*-tektronix-bsd* ) machine=tek4300 opsys=bsd4-3 ;; - - ## Titan P2 or P3 - ## We seem to have lost the machine-description file titan.h! - titan-titan-sysv* ) machine=titan opsys=usg5-3 ;; - - ## Ustation E30 (SS5E) - m68*-unisys-uniplus* ) machine=ustation opsystem=unipl5-2 ;; - - ## Vaxen. - vax-dec-* ) - machine=vax - case "${canonical}" in - *-bsd4.1* ) opsys=bsd4-1 ;; - *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* ) opsys=bsd4-2 ;; - *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;; - *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;; - *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;; - *-vms* ) opsys=vms ;; - *-mach* ) opsys=mach-bsd4-3 ;; - * ) unported=yes + mips-tandem-sysv* ) machine=tandem-s2 opsys=usg5-3 ;; + + m88k-tektronix-sysv3* ) machine=tekxd88 opsys=usg5-3 ;; + + ns16k-tektronix-bsd* ) machine=ns16000 opsys=bsd4-2 ;; + m68*-tektronix-bsd* ) machine=tek4300 opsys=bsd4-3 ;; + + titan-titan-sysv* ) machine=titan opsys=usg5-3 ;; + + m68*-unisys-uniplus* ) machine=ustation opsystem=unipl5-2 ;; + + vax-dec-* ) + case "$canonical" in + *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;; + *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;; + *-mach* ) opsys=mach-bsd4-3 ;; esac ;; - ## Whitechapel MG1 - ## We don't know what sort of OS runs on these; we'll let the - ## operating system guessing code below try. - ns16k-whitechapel-* ) machine=mg1 ;; - - ## Wicat - m68*-wicat-sysv* ) machine=wicat opsys=usg5-2 ;; - - ## Intel 386 machines where we don't care about the manufacturer - i[3-9]86-*-* ) + ns16k-whitechapel-* ) machine=mg1 ;; + + m68*-wicat-sysv* ) machine=wicat opsys=usg5-2 ;; + + i[3-9]86-*-* ) machine=intel386 - case "${canonical}" in + case "$canonical" in *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;; *-isc2.2* ) opsys=isc2-2 ;; *-isc4.0* ) opsys=isc4-0 ;; @@ -1433,24 +1272,17 @@ NON_GCC_TEST_OPTIONS=-Xp ;; *-isc* ) opsys=isc3-0 ;; - *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;; + *-esix5* ) opsys=esix5r4 NON_GNU_CPP=/usr/lib/cpp ;; *-esix* ) opsys=esix ;; *-mach* ) opsys=mach-bsd4-3 ;; *-xenix* ) opsys=xenix ;; - *-linux* ) opsys=linux ;; - *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;; + *-sco3.2v4* ) opsys=sco4 NON_GNU_CPP=/lib/cpp ;; *-bsd386* | *-bsdi1* ) opsys=bsd386 ;; *-bsdi3* ) opsys=bsdos3 ;; *-bsdi2.1* ) opsys=bsdos2-1 ;; *-bsdi2* ) opsys=bsdos2 ;; - *-sco3.2v5* ) opsys=sco5 ; - ## This is a pain. Like the current USL cc, SCO's cc -E - ## tokenizes as it preprocesses, making configure very - ## unhappy. Unfortunately, /lib/cpp doesn't understand - ## flags like "-b elf", so we have to cheat in order to - ## pick up the right defines for UNEXEC from the s-file. - ## 01/05/95 robertl@dgii.com - if test "${dynamic}" = "yes" ; then + *-sco3.2v5* ) opsys=sco5 ; + if test "$dynamic" = "yes" ; then NON_GNU_CPP="/lib/cpp -D_XOPEN_SOURCE -D_SCO_ELF" ; else NON_GNU_CPP="/lib/cpp -D_XOPEN_SOURCE" ; @@ -1458,350 +1290,827 @@ *-386bsd* ) opsys=386bsd ;; *-freebsd* ) opsys=freebsd ;; *-nextstep* ) opsys=nextstep ;; - ## Otherwise, we'll fall through to the generic opsys code at the bottom. - esac + esac ;; - ## Linux/68k - m68k-*-linux* ) machine=m68k opsys=linux ;; - - * ) unported=yes ;; + m68k-*-linux* ) machine=m68k opsys=linux ;; + esac -### If the code above didn't choose an operating system, just choose -### an operating system based on the configuration name. You really -### only want to use this when you have no idea what the right -### operating system is; if you know what operating systems a machine -### runs, it's cleaner to make it explicit in the case statement -### above. -if test -z "${opsys}" ; then - case "${canonical}" in - *-gnu* ) opsys=gnu ;; - *-bsd4.[01] ) opsys=bsd4-1 ;; - *-bsd4.2 ) opsys=bsd4-2 ;; - *-bsd4.3 ) opsys=bsd4-3 ;; - *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;; - *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;; - *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;; - *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;; - *-sysv4.1* | *-sysvr4.1* ) opsys=usg5-4 NON_GNU_CPP=/usr/lib/cpp ;; - *-sysv4.[2-9]* | *-sysvr4.[2-9]* ) - if test -z "$NON_GNU_CPP" ; then - if test -f /usr/ccs/lib/cpp - then NON_GNU_CPP=/usr/ccs/lib/cpp - else NON_GNU_CPP=/lib/cpp - fi - fi - opsys=usg5-4-2 ;; - *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;; - * ) unported=yes ;; - esac -fi - -test -z "$RANLIB" && RANLIB=ranlib - -if test ${unported} = yes; then - (echo "${progname}: XEmacs hasn't been ported to \`${canonical}' systems." - echo "${progname}: Check \`etc/MACHINES' for recognized configuration names." +if test -z "$machine" -o -z "$opsys"; then + (echo "$progname: XEmacs hasn't been ported to \`$canonical' systems." + echo "$progname: Check \`etc/MACHINES' for recognized configuration names." ) >&2 exit 1 fi -if test "${dynamic}" = "yes" ; then - case "${opsys}" in +if test "$dynamic" = "yes" ; then + case "$opsys" in hpux* | sunos4* | sco5 ) opsys="${opsys}-shr" ;; esac -elif test "${dynamic}" = "no" ; then - case "${opsys}" in +elif test "$dynamic" = "no" ; then + case "$opsys" in sol2* | decosf1-3 | decosf3-* | decosf4-* | linux ) opsys="${opsys}-static" ;; esac fi -dynodump_arch='' -if test "${need_dynodump}" = "yes" ; then - case "${canonical}" in - sparc* ) dynodump_arch=sparc ;; - powerpc* ) dynodump_arch=ppc ;; - i[3-9]86* ) dynodump_arch=i386 ;; - esac -fi - machfile="m/${machine}.h" opsysfile="s/${opsys}.h" -############################################################################ -# # -# Determine the compiler, set up for feature testing # -# # -############################################################################ - - - +test -n "$CC" && cc_specified=yes + +SPECIFIED_CFLAGS="$CFLAGS" + +if test -n "$compiler"; then CC="$compiler"; fi + +test -n "$NON_GNU_CC" -a "$with_gcc" = "no" -a -z "$CC" && CC="$NON_GNU_CC" +# 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:1332: checking for $ac_word" >&5 + +if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_CC="gcc" + break + fi + done + IFS="$ac_save_ifs" +fi +CC="$ac_cv_prog_CC" +if test -n "$CC"; then + echo "$ac_t""$CC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:1358: checking for $ac_word" >&5 + +if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + ac_prog_rejected=no + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + break + fi + done + IFS="$ac_save_ifs" +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# -gt 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + set dummy "$ac_dir/$ac_word" "$@" + shift + ac_cv_prog_CC="$@" + fi +fi +fi +CC="$ac_cv_prog_CC" +if test -n "$CC"; then + echo "$ac_t""$CC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } +fi + +echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 +echo "configure:1403: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c -# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. -ac_cpp='${CPP}' -ac_compile='${CC-cc} $CFLAGS $LDFLAGS conftest.${ac_ext} -o conftest $LIBS >/dev/null 2>&1' - -trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15 -trap 'rm -fr confdefs* $ac_clean_files' 0 - -# Save the original args if we used an alternate arg parser. -ac_configure_temp="${configure_args-$*}" -# Strip out --no-create and --norecursion so they don't pile up. -configure_args= -for ac_arg in $ac_configure_temp; do - case "$ac_arg" in - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c) ;; - -norecursion | --norecursion | --norecursio | --norecursi \ - | --norecurs | --norecur | --norecu | --norec | --nore | --nor) ;; - *) configure_args="$configure_args $ac_arg" ;; - esac -done - -# NLS nuisances. -# These must not be set unconditionally because not all systems understand -# e.g. LANG=C (notably SCO). -if test "${LC_ALL+set}" = 'set'; then LC_ALL=C; export LC_ALL; fi -if test "${LANG+set}" = 'set'; then LANG=C; export LANG; fi - -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -rf conftest* confdefs.h -# AIX cpp loses on an empty file, so make sure it contains at least a newline. -echo > confdefs.h - -# A filename unique to this package, relative to the directory that -# configure is in, which we can look for to find out if srcdir is correct. -ac_unique_file=lisp - -# Find the source files, if location was not specified. -if test -z "$srcdir"; then - ac_srcdir_defaulted=yes - # Try the directory containing this script, then `..'. - ac_prog=$0 - ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` - test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. - srcdir=$ac_confdir - if test ! -r $srcdir/$ac_unique_file; then - srcdir=.. +xe_cppflags='$c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS $CPPFLAGS' # $c_switch_x_machine $c_switch_x_system' +xe_ldflags='$ld_switch_site $ld_switch_machine $ld_switch_system $ld_switch_x_site' # $ld_switch_x_machine $ld_switch_x_system' +xe_libs='$xe_check_libs $X_PRE_LIBS $libs_x $X_EXTRA_LIBS $LIBS $libs_machine $libs_system $libs_standard' +ac_cpp='$CPP '"$xe_cppflags" +ac_compile='${CC-cc} -c '"$CFLAGS $xe_cppflags"' conftest.$ac_ext 1>&5' +ac_link='${CC-cc} -o conftest '"$CFLAGS $xe_cppflags $LDFLAGS $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' +cross_compiling=no + +cat > conftest.$ac_ext <<EOF +#line 1415 "configure" +#include "confdefs.h" +main(){return(0);} +EOF +if { (eval echo configure:1419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_cv_prog_cc_cross=no + else + ac_cv_prog_cc_cross=yes fi -fi -if test ! -r $srcdir/$ac_unique_file; then - if test x$ac_srcdir_defaulted = xyes; then - echo "configure: can not find sources in ${ac_confdir} or .." >&2; exit 1 +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + ac_cv_prog_cc_works=no +fi +rm -fr conftest* + +echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 +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:1439: 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:1444: checking whether we are using GNU C" >&5 + +cat > conftest.c <<EOF +#ifdef __GNUC__ + yes; +#endif +EOF +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1451: \"$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 +fi + +echo "$ac_t""$ac_cv_prog_gcc" 1>&6 + +if test $ac_cv_prog_gcc = yes; then + GCC=yes + 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:1465: checking whether ${CC-cc} accepts -g" >&5 + +echo 'void f(){}' > conftest.c +if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then + ac_cv_prog_cc_g=yes +else + ac_cv_prog_cc_g=no +fi +rm -f conftest* + + +echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 + if test "$ac_test_CFLAGS" = set; then + CFLAGS="$ac_save_CFLAGS" + elif test $ac_cv_prog_cc_g = yes; then + CFLAGS="-g -O2" else - echo "configure: can not find sources in ${srcdir}" >&2; exit 1 + CFLAGS="-O2" fi -fi -ac_ext=c -# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. -ac_cpp='${CPP}' -ac_compile='${CC-cc} $CFLAGS $LDFLAGS conftest.${ac_ext} -o conftest $LIBS >/dev/null 2>&1' - - - - -if test "${extra_verbose}" = "yes" ; then -# This is identical to the version that A\C_LANG_C generates except that -# it omits the redirection of all output to /dev/null. - ac_compile='${CC-cc} $CFLAGS $LDFLAGS conftest.${ac_ext} -o conftest $LIBS' -fi - -#### Choose a compiler. -if test "x$CC" = x ; then - cc_specified=1 -fi - -# Save the value of CFLAGS that the user specified. -SPECIFIED_CFLAGS="$CFLAGS" - -if test "${with_gcc}" = "yes" ; then - CC="${compiler-gcc}" - GCC=1 -elif test "${with_lcc}" = "yes" ; then - CC="${compiler-lcc}" - dash_r_space=' ' # this bullshit is here because lcc for solaris - # will not accept -Rargument. - # It needs -R argument instead. Yuck yuck yuck. - test -z "$NON_GNU_CPP" && NON_GNU_CPP="yes" # this is handled specially below... -elif test "${compiler}" != "" ; then CC="${compiler}" -elif test "${with_gcc}" = "no" ; then CC="cc" -elif test "${with_lcc}" = "no" ; then - test -z "$CC" && CC=cc -else - case "${canonical}" in - * ) - if test -z "$CC"; then - # Extract the first word of `gcc', so it can be a program name with args. - set ac_dummy gcc; ac_word=$2 - test -n "$silent" || echo "checking for $ac_word" +else + GCC= + test "${CFLAGS+set}" = set || CFLAGS="-g" +fi + + +if test "$with_gcc" = "no" -a "$ac_cv_prog_gcc" = "yes"; then + CC=${NON_GNU_CC-cc} + # 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:1495: checking for $ac_word" >&5 + +if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then - CC="gcc" + ac_cv_prog_CC="gcc" + break + fi + done + IFS="$ac_save_ifs" +fi +CC="$ac_cv_prog_CC" +if test -n "$CC"; then + echo "$ac_t""$CC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:1521: checking for $ac_word" >&5 + +if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + ac_prog_rejected=no + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + break + fi + done + IFS="$ac_save_ifs" +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# -gt 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + set dummy "$ac_dir/$ac_word" "$@" + shift + ac_cv_prog_CC="$@" + fi +fi +fi +CC="$ac_cv_prog_CC" +if test -n "$CC"; then + echo "$ac_t""$CC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } +fi + +echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 +echo "configure:1566: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 + +ac_ext=c +xe_cppflags='$c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS $CPPFLAGS' # $c_switch_x_machine $c_switch_x_system' +xe_ldflags='$ld_switch_site $ld_switch_machine $ld_switch_system $ld_switch_x_site' # $ld_switch_x_machine $ld_switch_x_system' +xe_libs='$xe_check_libs $X_PRE_LIBS $libs_x $X_EXTRA_LIBS $LIBS $libs_machine $libs_system $libs_standard' +ac_cpp='$CPP '"$xe_cppflags" +ac_compile='${CC-cc} -c '"$CFLAGS $xe_cppflags"' conftest.$ac_ext 1>&5' +ac_link='${CC-cc} -o conftest '"$CFLAGS $xe_cppflags $LDFLAGS $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' +cross_compiling=no + +cat > conftest.$ac_ext <<EOF +#line 1578 "configure" +#include "confdefs.h" +main(){return(0);} +EOF +if { (eval echo configure:1582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_cv_prog_cc_cross=no + else + ac_cv_prog_cc_cross=yes + fi +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + ac_cv_prog_cc_works=no +fi +rm -fr conftest* + +echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 +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:1602: 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:1607: checking whether we are using GNU C" >&5 + +cat > conftest.c <<EOF +#ifdef __GNUC__ + yes; +#endif +EOF +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1614: \"$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 +fi + +echo "$ac_t""$ac_cv_prog_gcc" 1>&6 + +if test $ac_cv_prog_gcc = yes; then + GCC=yes + 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:1628: checking whether ${CC-cc} accepts -g" >&5 + +echo 'void f(){}' > conftest.c +if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then + ac_cv_prog_cc_g=yes +else + ac_cv_prog_cc_g=no +fi +rm -f conftest* + + +echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 + if test "$ac_test_CFLAGS" = set; then + CFLAGS="$ac_save_CFLAGS" + elif test $ac_cv_prog_cc_g = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-O2" + fi +else + GCC= + test "${CFLAGS+set}" = set || CFLAGS="-g" +fi + +elif test "$with_gcc" = "yes" -a "$ac_cv_prog_gcc" = "no" ; then + CC=gcc + # 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:1657: checking for $ac_word" >&5 + +if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_CC="gcc" + break + fi + done + IFS="$ac_save_ifs" +fi +CC="$ac_cv_prog_CC" +if test -n "$CC"; then + echo "$ac_t""$CC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:1683: checking for $ac_word" >&5 + +if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + ac_prog_rejected=no + for ac_dir in $PATH; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" break fi done IFS="$ac_save_ifs" -fi -test -z "$CC" && CC="cc" -test -n "$CC" && test -n "$verbose" && echo " setting CC to $CC" - -# Find out if we are using GNU C, under whatever name. +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# -gt 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + set dummy "$ac_dir/$ac_word" "$@" + shift + ac_cv_prog_CC="$@" + fi +fi +fi +CC="$ac_cv_prog_CC" +if test -n "$CC"; then + echo "$ac_t""$CC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } +fi + +echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 +echo "configure:1728: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 + +ac_ext=c +xe_cppflags='$c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS $CPPFLAGS' # $c_switch_x_machine $c_switch_x_system' +xe_ldflags='$ld_switch_site $ld_switch_machine $ld_switch_system $ld_switch_x_site' # $ld_switch_x_machine $ld_switch_x_system' +xe_libs='$xe_check_libs $X_PRE_LIBS $libs_x $X_EXTRA_LIBS $LIBS $libs_machine $libs_system $libs_standard' +ac_cpp='$CPP '"$xe_cppflags" +ac_compile='${CC-cc} -c '"$CFLAGS $xe_cppflags"' conftest.$ac_ext 1>&5' +ac_link='${CC-cc} -o conftest '"$CFLAGS $xe_cppflags $LDFLAGS $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' +cross_compiling=no + +cat > conftest.$ac_ext <<EOF +#line 1740 "configure" +#include "confdefs.h" +main(){return(0);} +EOF +if { (eval echo configure:1744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_cv_prog_cc_cross=no + else + ac_cv_prog_cc_cross=yes + fi +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + ac_cv_prog_cc_works=no +fi +rm -fr conftest* + +echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 +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:1764: 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:1769: checking whether we are using GNU C" >&5 + cat > conftest.c <<EOF #ifdef __GNUC__ - yes + yes; #endif EOF -${CC-cc} -E conftest.c > conftest.out 2>&1 -if egrep yes conftest.out >/dev/null 2>&1; then - GCC=1 # For later tests. -fi -rm -f conftest* - - if test "${CC}" = "gcc" ; then - with_gcc="yes" - GCC=1 - fi - ;; - esac -fi - -#### Some systems specify a CPP to use unless we are using GCC. -#### Now that we know whether we are using GCC, we can decide whether -#### to use that one. -if test "x$NON_GNU_CPP" = x -o x$GCC = x1 -then true -else - if test "x$CPP" = x ; then - if test "${with_lcc}" = "yes" -a "${NON_GNU_CPP}" = "yes"; then - CPP='gcc -E -traditional' # cross fingers and hope it's there.... - else - CPP="$NON_GNU_CPP" - fi +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1776: \"$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 +fi + +echo "$ac_t""$ac_cv_prog_gcc" 1>&6 + +if test $ac_cv_prog_gcc = yes; then + GCC=yes + 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:1790: checking whether ${CC-cc} accepts -g" >&5 + +echo 'void f(){}' > conftest.c +if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then + ac_cv_prog_cc_g=yes +else + ac_cv_prog_cc_g=no +fi +rm -f conftest* + + +echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 + if test "$ac_test_CFLAGS" = set; then + CFLAGS="$ac_save_CFLAGS" + elif test $ac_cv_prog_cc_g = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-O2" fi -fi - -#### Some systems specify a CC to use unless we are using GCC. -#### Now that we know whether we are using GCC, we can decide whether -#### to use that one. -if test "x$NON_GNU_CC" = x -o x$GCC = x1 -o x$cc_specified = x1 -then true -else - CC="$NON_GNU_CC" -fi - -## Huh? I commented out the following because it always enabled -## the "test" options, whatever the hell those are supposed to be -## for, and the result is that SunOS builds were always static. - -# test x$GCC = x1 -a "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS" -# test x$GCC = x -a "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS" - -############################################################################ -# # -# Do some misc autoconf-special tests # -# # -############################################################################ - -#### Some other nice autoconf tests. If you add a test here which -#### should make an entry in src/config.h, don't forget to add an -#### #undef clause to src/config.h.in for autoconf to modify. -test -n "$silent" || echo "checking how to run the C preprocessor" +else + GCC= + test "${CFLAGS+set}" = set || CFLAGS="-g" +fi + +fi + +if test "$GCC" = "yes"; then with_gcc=yes; else with_gcc=no; fi +test -n "$NON_GNU_CPP" -a "$with_gcc" = "no" -a -z "$CPP" && CPP="$NON_GNU_CPP" + +echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 +echo "configure:1820: checking how to run the C preprocessor" >&5 +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi if test -z "$CPP"; then + # This must be in double quotes, not single quotes, because CPP may get - # substituted into the Makefile and ``${CC-cc}'' will simply confuse - # make. It must be expanded now. + # substituted into the Makefile and "${CC-cc}" will confuse make. CPP="${CC-cc} -E" - cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <stdio.h> + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. + cat > conftest.$ac_ext <<EOF +#line 1833 "configure" +#include "confdefs.h" +#include <assert.h> Syntax Error EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:1839: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + : +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + CPP="${CC-cc} -E -traditional-cpp" + cat > conftest.$ac_ext <<EOF +#line 1850 "configure" +#include "confdefs.h" +#include <assert.h> +Syntax Error +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:1856: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then : else - rm -rf conftest* - CPP="${CC-cc} -E -traditional-cpp" - cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <stdio.h> -Syntax Error -EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi -if test -z "$ac_err"; then - : -else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 rm -rf conftest* CPP=/lib/cpp fi rm -f conftest* fi rm -f conftest* -fi -test -n "$verbose" && echo " setting CPP to $CPP" - - -case "${canonical}" in - *-sun-sunos* ) - if test "${CPP}" = "acc -E" ; then - CPP="acc -E -Xs" - fi - ;; + ac_cv_prog_CPP="$CPP" + CPP="$ac_cv_prog_CPP" +else + ac_cv_prog_CPP="$CPP" +fi +echo "$ac_t""$CPP" 1>&6 + + +case "$canonical" in + *-sun-sunos* ) test "$CPP" = "acc -E" && CPP="acc -E -Xs" ;; esac -if test -z "$RANLIB"; then - # Extract the first word of `ranlib', so it can be a program name with args. - set ac_dummy ranlib; ac_word=$2 - test -n "$silent" || echo "checking for $ac_word" + +echo "Extracting information from the machine- and system-dependent headers..." + + + +tempcname="conftest.c" + + + + + + +echo ' +#define NOT_C_CODE +#define C_SWITCH_SITE +#define C_SWITCH_X_SITE +#define LD_SWITCH_SITE +#define LD_SWITCH_X_SITE +#define LD_SWITCH_X_SITE_AUX +#include "'$srcdir'/src/'$opsysfile'" +#include "'$srcdir'/src/'$machfile'" + +#ifndef LIBS_MACHINE +#define LIBS_MACHINE +#endif +configure___ libs_machine=LIBS_MACHINE + +#ifndef LIBS_SYSTEM +#define LIBS_SYSTEM +#endif +configure___ libs_system=LIBS_SYSTEM + +#ifndef LIBS_TERMCAP +#define LIBS_TERMCAP +#endif +configure___ libs_termcap=LIBS_TERMCAP + +#ifndef LIB_STANDARD +#define LIB_STANDARD +#endif +configure___ libs_standard=LIB_STANDARD + +#ifndef C_SWITCH_SYSTEM +#define C_SWITCH_SYSTEM +#endif +configure___ c_switch_system=C_SWITCH_SYSTEM + +#ifndef C_SWITCH_MACHINE +#define C_SWITCH_MACHINE +#endif +configure___ c_switch_machine=C_SWITCH_MACHINE + +#ifndef C_SWITCH_X_SYSTEM +#define C_SWITCH_X_SYSTEM +#endif +configure___ c_switch_x_system=C_SWITCH_X_SYSTEM + +#ifndef LD_SWITCH_X_SYSTEM +#define LD_SWITCH_X_SYSTEM +#endif +configure___ ld_switch_x_system=LD_SWITCH_X_SYSTEM + +#ifndef LD_SWITCH_SYSTEM +#define LD_SWITCH_SYSTEM +#endif +configure___ ld_switch_system=LD_SWITCH_SYSTEM + +#ifndef UNEXEC +#define UNEXEC unexec.o +#endif +configure___ unexec=UNEXEC + +#ifndef C_DEBUG_SWITCH +#define C_DEBUG_SWITCH -g +#endif +configure___ c_debug_switch=C_DEBUG_SWITCH + +#ifndef C_OPTIMIZE_SWITCH +#define C_OPTIMIZE_SWITCH -O +#endif +configure___ c_optimize_switch=C_OPTIMIZE_SWITCH + + +#ifdef SYSTEM_MALLOC +configure___ system_malloc=yes +#else +configure___ system_malloc=no +#endif + +#ifdef TERMINFO +configure___ have_terminfo=yes +#else +configure___ have_terminfo=no +#endif + +#ifdef MAIL_USE_FLOCK +configure___ mail_use_flock=yes +#else +configure___ mail_use_flock=no +#endif + +#ifdef MAIL_USE_LOCKF +configure___ mail_use_lockf=yes +#else +configure___ mail_use_lockf=no +#endif + +#ifdef __SUNPRO_C +configure___ sunpro_c=yes +#else +configure___ sunpro_c=no +#endif + + +#ifdef THIS_IS_CONFIGURE + +/* Get the CFLAGS for tests in configure. */ +#ifdef __GNUC__ +configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '$SPECIFIED_CFLAGS' +#else +configure___ CFLAGS=C_DEBUG_SWITCH '$SPECIFIED_CFLAGS' +#endif + +#else /* not THIS_IS_CONFIGURE */ + +/* Get the CFLAGS for real compilation. */ +#ifdef __GNUC__ +configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '$SPECIFIED_CFLAGS' +#else +configure___ REAL_CFLAGS=C_DEBUG_SWITCH '$SPECIFIED_CFLAGS' +#endif + +#endif /* not THIS_IS_CONFIGURE */ +' > $tempcname +CPP=`eval "echo $CPP"` +eval `$CPP -Isrc $tempcname \ + | grep 'configure___' \ + | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'` +if test -z "$SPECIFIED_CFLAGS"; then + eval `$CPP -Isrc -DTHIS_IS_CONFIGURE $tempcname \ + | grep 'configure___' \ + | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'` +else + REAL_CFLAGS="$CFLAGS" +fi +rm $tempcname + +if test "$cflags" != "NO_CFLAGS_DEFINED" ; then + REAL_CFLAGS=$cflags +fi + +UNEXEC_SRC="`echo $unexec | sed 's/\.o/.c/'`" + +GNU_MALLOC=yes +if test "$system_malloc" = "yes" ; then + GNU_MALLOC=no + GNU_MALLOC_reason=" + (The GNU allocators don't work with this system configuration.)" +elif test "$use_system_malloc" = "yes" ; then + GNU_MALLOC=no + GNU_MALLOC_reason=" + (User chose not to use GNU allocators.)" +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:2051: checking for $ac_word" >&5 + +if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. +else IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then - RANLIB="ranlib" + ac_cv_prog_RANLIB="ranlib" break fi done IFS="$ac_save_ifs" -fi -test -z "$RANLIB" && RANLIB=":" -test -n "$RANLIB" && test -n "$verbose" && echo " setting RANLIB to $RANLIB" - -# Make sure to not get the incompatible SysV /etc/install and -# /usr/sbin/install, which might be in PATH before a BSD-like install, -# or the SunOS /usr/etc/install directory, or the AIX /bin/install, -# or the AFS install, which mishandles nonexistent args, or -# /usr/ucb/install on SVR4, which tries to use the nonexistent group -# `staff', or /sbin/install on IRIX which has incompatible command-line -# syntax. Sigh. -# -# On most BSDish systems install is in /usr/bin, not /usr/ucb -# anyway. -# This turns out not to be true, so the mere pathname isn't an indication -# of whether the program works. What we really need is a set of tests for -# the install program to see if it actually works in all the required ways. -# -# Avoid using ./install, which might have been erroneously created -# by make from ./install.sh. -if test -z "${INSTALL}"; then - test -n "$silent" || echo "checking for a BSD compatible install" - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" +fi +RANLIB="$ac_cv_prog_RANLIB" +if test -n "$RANLIB"; then + echo "$ac_t""$RANLIB" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +ac_aux_dir= +for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do + if test -f $ac_dir/install-sh; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install-sh -c" + break + elif test -f $ac_dir/install.sh; then + ac_aux_dir=$ac_dir + ac_install_sh="$ac_aux_dir/install.sh -c" + break + fi +done +if test -z "$ac_aux_dir"; then + { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } +fi +ac_config_guess=$ac_aux_dir/config.guess +ac_config_sub=$ac_aux_dir/config.sub +ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. + +# Find a good install program. We prefer a C program (faster), +# so one script is as good as another. But avoid the broken or +# incompatible versions: +# SysV /etc/install, /usr/sbin/install +# SunOS /usr/etc/install +# IRIX /sbin/install +# AIX /bin/install +# AFS /usr/afsws/bin/install, which mishandles nonexistent args +# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" +# ./install, which can be erroneously created by make from ./install.sh. +echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 +echo "configure:2104: checking for a BSD compatible install" >&5 +if test -z "$INSTALL"; then + + IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do - case "$ac_dir" in - ''|.|/etc|/sbin|/usr/sbin|/usr/etc|/usr/afsws/bin|/usr/ucb) ;; + # Account for people who put trailing slashes in PATH elements. + case "$ac_dir/" in + /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. - for ac_prog in installbsd scoinst install; do + for ac_prog in ginstall installbsd scoinst install; do if test -f $ac_dir/$ac_prog; then if test $ac_prog = install && grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then @@ -1809,7 +2118,7 @@ # OSF/1 installbsd also uses dspmsg, but is usable. : else - INSTALL="$ac_dir/$ac_prog -c" + ac_cv_path_install="$ac_dir/$ac_prog -c" break 2 fi fi @@ -1817,78 +2126,82 @@ ;; esac done - IFS="$ac_save_ifs" -fi - -if test -z "$INSTALL"; then - # As a last resort, use the slow shell script. - for ac_dir in ${srcdir} ${srcdir}/.. ${srcdir}/../..; do - if test -f $ac_dir/install.sh; then - INSTALL="$ac_dir/install.sh -c"; break - fi - done -fi -if test -z "$INSTALL"; then - echo "configure: can not find install.sh in ${srcdir} or ${srcdir}/.. or ${srcdir}/../.." >&2; exit 1 -fi -test -n "$verbose" && echo " setting INSTALL to $INSTALL" - -# Use test -z because SunOS4 sh mishandles ${INSTALL_PROGRAM-'${INSTALL}'}. + IFS="$ac_save_IFS" + + if test "${ac_cv_path_install+set}" = set; then + INSTALL="$ac_cv_path_install" + else + # As a last resort, use the slow shell script. We don't cache a + # path for INSTALL within a source directory, because that will + # break other packages using the cache if that directory is + # removed, or if the path is relative. + INSTALL="$ac_install_sh" + fi +fi +echo "$ac_t""$INSTALL" 1>&6 + +# Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' -test -n "$verbose" && echo " setting INSTALL_PROGRAM to $INSTALL_PROGRAM" test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' -test -n "$verbose" && echo " setting INSTALL_DATA to $INSTALL_DATA" for ac_prog in 'bison -y' byacc do -if test -z "$YACC"; then - # Extract the first word of `$ac_prog', so it can be a program name with args. - set ac_dummy $ac_prog; ac_word=$2 - test -n "$silent" || echo "checking for $ac_word" +# 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:2155: checking for $ac_word" >&5 + +if test -n "$YACC"; then + ac_cv_prog_YACC="$YACC" # Let the user override the test. +else IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then - YACC="$ac_prog" + ac_cv_prog_YACC="$ac_prog" break fi done IFS="$ac_save_ifs" fi - -test -n "$YACC" && test -n "$verbose" && echo " setting YACC to $YACC" +YACC="$ac_cv_prog_YACC" +if test -n "$YACC"; then + echo "$ac_t""$YACC" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi test -n "$YACC" && break done test -n "$YACC" || YACC="yacc" -test -n "$silent" || echo "checking for AIX" -cat > conftest.${ac_ext} <<EOF +echo $ac_n "checking for AIX""... $ac_c" 1>&6 +echo "configure:2183: checking for AIX" >&5 +cat > conftest.$ac_ext <<EOF +#line 2185 "configure" #include "confdefs.h" #ifdef _AIX yes #endif EOF -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "yes" conftest.out >/dev/null 2>&1; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining _ALL_SOURCE" -echo "#define" _ALL_SOURCE "1" >> confdefs.h -DEFS="$DEFS -D_ALL_SOURCE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}_ALL_SOURCE\${ac_dB}_ALL_SOURCE\${ac_dC}1\${ac_dD} -\${ac_uA}_ALL_SOURCE\${ac_uB}_ALL_SOURCE\${ac_uC}1\${ac_uD} -\${ac_eA}_ALL_SOURCE\${ac_eB}_ALL_SOURCE\${ac_eC}1\${ac_eD} -" -} - - +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "yes" >/dev/null 2>&1; then + rm -rf conftest* + echo "$ac_t""yes" 1>&6; { test "$extra_verbose" = "yes" && cat << \EOF + Defining _ALL_SOURCE +EOF +cat >> confdefs.h <<\EOF +#define _ALL_SOURCE 1 +EOF +} + +else + rm -rf conftest* + echo "$ac_t""no" 1>&6 fi rm -f conftest* @@ -1896,223 +2209,307 @@ for ac_hdr in mach/mach.h sys/stropts.h sys/timeb.h sys/time.h unistd.h do -ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./' '[A-Z]__'` -test -n "$silent" || echo "checking for ${ac_hdr}" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <${ac_hdr}> -EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:2215: checking for $ac_hdr" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2218 "configure" +#include "confdefs.h" +#include <$ac_hdr> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:2223: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining ${ac_tr_hdr}" -echo "#define" ${ac_tr_hdr} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_hdr}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_hdr}\${ac_dB}${ac_tr_hdr}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_hdr}\${ac_uB}${ac_tr_hdr}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_hdr}\${ac_eB}${ac_tr_hdr}\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_hdr +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_hdr 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi done for ac_hdr in utime.h sys/wait.h libintl.h locale.h libgen.h do -ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./' '[A-Z]__'` -test -n "$silent" || echo "checking for ${ac_hdr}" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <${ac_hdr}> -EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:2256: checking for $ac_hdr" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2259 "configure" +#include "confdefs.h" +#include <$ac_hdr> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:2264: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining ${ac_tr_hdr}" -echo "#define" ${ac_tr_hdr} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_hdr}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_hdr}\${ac_dB}${ac_tr_hdr}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_hdr}\${ac_uB}${ac_tr_hdr}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_hdr}\${ac_eB}${ac_tr_hdr}\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_hdr +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_hdr 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi done for ac_hdr in linux/version.h kstat.h sys/pstat.h inttypes.h do -ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./' '[A-Z]__'` -test -n "$silent" || echo "checking for ${ac_hdr}" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <${ac_hdr}> -EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:2297: checking for $ac_hdr" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2300 "configure" +#include "confdefs.h" +#include <$ac_hdr> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:2305: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining ${ac_tr_hdr}" -echo "#define" ${ac_tr_hdr} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_hdr}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_hdr}\${ac_dB}${ac_tr_hdr}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_hdr}\${ac_uB}${ac_tr_hdr}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_hdr}\${ac_eB}${ac_tr_hdr}\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_hdr +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_hdr 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi done -test -n "$silent" || echo "checking for ANSI C header files" -cat > conftest.${ac_ext} <<EOF +echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 +echo "configure:2335: checking for ANSI C header files" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2338 "configure" #include "confdefs.h" #include <stdlib.h> #include <stdarg.h> #include <string.h> #include <float.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:2346: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* + ac_cv_header_stdc=yes +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* + +if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. -echo '#include "confdefs.h" -#include <string.h>' > conftest.${ac_ext} -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "memchr" conftest.out >/dev/null 2>&1; then - rm -rf conftest* - # SGI's /bin/cc from Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. -cat > conftest.${ac_ext} <<EOF +cat > conftest.$ac_ext <<EOF +#line 2363 "configure" +#include "confdefs.h" +#include <string.h> +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "memchr" >/dev/null 2>&1; then + : +else + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* + +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 +#line 2381 "configure" +#include "confdefs.h" +#include <stdlib.h> +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "free" >/dev/null 2>&1; then + : +else + rm -rf conftest* + ac_cv_header_stdc=no +fi +rm -f conftest* + +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 <<EOF +#line 2399 "configure" #include "confdefs.h" #include <ctype.h> #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#define XOR(e,f) (((e) && !(f)) || (!(e) && (f))) +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); exit (0); } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. -echo '#include "confdefs.h" -#include <stdlib.h>' > conftest.${ac_ext} -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "free" conftest.out >/dev/null 2>&1; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining STDC_HEADERS" -echo "#define" STDC_HEADERS "1" >> confdefs.h -DEFS="$DEFS -DSTDC_HEADERS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STDC_HEADERS\${ac_dB}STDC_HEADERS\${ac_dC}1\${ac_dD} -\${ac_uA}STDC_HEADERS\${ac_uB}STDC_HEADERS\${ac_uC}1\${ac_uD} -\${ac_eA}STDC_HEADERS\${ac_eB}STDC_HEADERS\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - - +if { (eval echo configure:2410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + : +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_header_stdc=no fi rm -fr conftest* - -fi -rm -f conftest* - - -fi -rm -f conftest* - -test -n "$silent" || echo "checking for whether time.h and sys/time.h may both be included" -cat > conftest.${ac_ext} <<EOF +fi + +echo "$ac_t""$ac_cv_header_stdc" 1>&6 +if test $ac_cv_header_stdc = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining STDC_HEADERS +EOF +cat >> confdefs.h <<\EOF +#define STDC_HEADERS 1 +EOF +} + +fi + +echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 +echo "configure:2435: checking whether time.h and sys/time.h may both be included" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2438 "configure" #include "confdefs.h" #include <sys/types.h> #include <sys/time.h> #include <time.h> -int main() { return 0; } -int t() { struct tm *tp;; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining TIME_WITH_SYS_TIME" -echo "#define" TIME_WITH_SYS_TIME "1" >> confdefs.h -DEFS="$DEFS -DTIME_WITH_SYS_TIME=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}TIME_WITH_SYS_TIME\${ac_dB}TIME_WITH_SYS_TIME\${ac_dC}1\${ac_dD} -\${ac_uA}TIME_WITH_SYS_TIME\${ac_uB}TIME_WITH_SYS_TIME\${ac_uC}1\${ac_uD} -\${ac_eA}TIME_WITH_SYS_TIME\${ac_eB}TIME_WITH_SYS_TIME\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - -test -n "$silent" || echo "checking for sys_siglist declaration in signal.h or unistd.h" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" +int main() { +struct tm *tp; +; return 0; } +EOF +if { (eval echo configure:2447: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_header_time=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_header_time=no +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_header_time" 1>&6 +if test $ac_cv_header_time = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining TIME_WITH_SYS_TIME +EOF +cat >> confdefs.h <<\EOF +#define TIME_WITH_SYS_TIME 1 +EOF +} + +fi + +echo $ac_n "checking for sys_siglist declaration in signal.h or unistd.h""... $ac_c" 1>&6 +echo "configure:2471: checking for sys_siglist declaration in signal.h or unistd.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2474 "configure" +#include "confdefs.h" +#include <sys/types.h> #include <signal.h> -/* NetBSD declares sys_siglist in <unistd.h>. */ +/* NetBSD declares sys_siglist in unistd.h. */ #ifdef HAVE_UNISTD_H #include <unistd.h> #endif -int main() { return 0; } -int t() { char *msg = *(sys_siglist + 1);; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining SYS_SIGLIST_DECLARED" -echo "#define" SYS_SIGLIST_DECLARED "1" >> confdefs.h -DEFS="$DEFS -DSYS_SIGLIST_DECLARED=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SYS_SIGLIST_DECLARED\${ac_dB}SYS_SIGLIST_DECLARED\${ac_dC}1\${ac_dD} -\${ac_uA}SYS_SIGLIST_DECLARED\${ac_uB}SYS_SIGLIST_DECLARED\${ac_uC}1\${ac_uD} -\${ac_eA}SYS_SIGLIST_DECLARED\${ac_eB}SYS_SIGLIST_DECLARED\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - - -test -n "$silent" || echo "checking for struct utimbuf" -cat > conftest.${ac_ext} <<EOF +int main() { +char *msg = *(sys_siglist + 1); +; return 0; } +EOF +if { (eval echo configure:2486: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_decl_sys_siglist=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_decl_sys_siglist=no +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_decl_sys_siglist" 1>&6 +if test $ac_cv_decl_sys_siglist = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining SYS_SIGLIST_DECLARED +EOF +cat >> confdefs.h <<\EOF +#define SYS_SIGLIST_DECLARED 1 +EOF +} + +fi + + +echo $ac_n "checking for struct utimbuf""... $ac_c" 1>&6 +echo "configure:2511: checking for struct utimbuf" >&5 +cat > conftest.$ac_ext <<EOF +#line 2513 "configure" #include "confdefs.h" #ifdef TIME_WITH_SYS_TIME #include <sys/time.h> @@ -2127,76 +2524,76 @@ #ifdef HAVE_UTIME_H #include <utime.h> #endif -int main() { return 0; } -int t() { static struct utimbuf x; x.actime = x.modtime;; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_STRUCT_UTIMBUF" -echo "#define" HAVE_STRUCT_UTIMBUF "1" >> confdefs.h -DEFS="$DEFS -DHAVE_STRUCT_UTIMBUF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_STRUCT_UTIMBUF\${ac_dB}HAVE_STRUCT_UTIMBUF\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_STRUCT_UTIMBUF\${ac_uB}HAVE_STRUCT_UTIMBUF\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_STRUCT_UTIMBUF\${ac_eB}HAVE_STRUCT_UTIMBUF\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - - -test -n "$silent" || echo "checking for return type of signal handlers" -cat > conftest.${ac_ext} <<EOF +int main() { +static struct utimbuf x; x.actime = x.modtime; +; return 0; } +EOF +if { (eval echo configure:2532: \"$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 + Defining HAVE_STRUCT_UTIMBUF +EOF +cat >> confdefs.h <<\EOF +#define HAVE_STRUCT_UTIMBUF 1 +EOF +} + +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + echo "$ac_t""no" 1>&6 +fi +rm -f conftest* + +echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 +echo "configure:2552: checking return type of signal handlers" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2555 "configure" #include "confdefs.h" #include <sys/types.h> #include <signal.h> #ifdef signal #undef signal #endif -extern void (*signal ()) (); -int main() { return 0; } -int t() { int i;; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining" RETSIGTYPE to be "void" -echo "#define" RETSIGTYPE "void" >> confdefs.h -DEFS="$DEFS -DRETSIGTYPE=void" -ac_sed_defs="${ac_sed_defs}\${ac_dA}RETSIGTYPE\${ac_dB}RETSIGTYPE\${ac_dC}void\${ac_dD} -\${ac_uA}RETSIGTYPE\${ac_uB}RETSIGTYPE\${ac_uC}void\${ac_uD} -\${ac_eA}RETSIGTYPE\${ac_eB}RETSIGTYPE\${ac_eC}void\${ac_eD} -" -} - - -else - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining" RETSIGTYPE to be "int" -echo "#define" RETSIGTYPE "int" >> confdefs.h -DEFS="$DEFS -DRETSIGTYPE=int" -ac_sed_defs="${ac_sed_defs}\${ac_dA}RETSIGTYPE\${ac_dB}RETSIGTYPE\${ac_dC}int\${ac_dD} -\${ac_uA}RETSIGTYPE\${ac_uB}RETSIGTYPE\${ac_uC}int\${ac_uD} -\${ac_eA}RETSIGTYPE\${ac_eB}RETSIGTYPE\${ac_eC}int\${ac_eD} -" -} - -fi -rm -f conftest* - - - -test -n "$silent" || echo "checking for struct timeval" -cat > conftest.${ac_ext} <<EOF +#ifdef __cplusplus +extern "C" void (*signal (int, void (*)(int)))(int); +#else +void (*signal ()) (); +#endif + +int main() { +int i; +; return 0; } +EOF +if { (eval echo configure:2572: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_type_signal=void +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_type_signal=int +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_type_signal" 1>&6 +{ test "$extra_verbose" = "yes" && cat << EOF + Defining RETSIGTYPE = $ac_cv_type_signal +EOF +cat >> confdefs.h <<EOF +#define RETSIGTYPE $ac_cv_type_signal +EOF +} + + + +echo $ac_n "checking for struct timeval""... $ac_c" 1>&6 +echo "configure:2595: checking for struct timeval" >&5 +cat > conftest.$ac_ext <<EOF +#line 2597 "configure" #include "confdefs.h" #ifdef TIME_WITH_SYS_TIME #include <sys/time.h> @@ -2208,135 +2605,156 @@ #include <time.h> #endif #endif -int main() { return 0; } -int t() { static struct timeval x; x.tv_sec = x.tv_usec;; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - +int main() { +static struct timeval x; x.tv_sec = x.tv_usec; +; return 0; } +EOF +if { (eval echo configure:2613: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + echo "$ac_t""yes" 1>&6 HAVE_TIMEVAL=yes - -{ -test -n "$verbose" && \ -echo " defining HAVE_TIMEVAL" -echo "#define" HAVE_TIMEVAL "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TIMEVAL=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TIMEVAL\${ac_dB}HAVE_TIMEVAL\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TIMEVAL\${ac_uB}HAVE_TIMEVAL\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TIMEVAL\${ac_eB}HAVE_TIMEVAL\${ac_eC}1\${ac_eD} -" -} - - -else - rm -rf conftest* - HAVE_TIMEVAL=no -fi -rm -f conftest* - - -test -n "$silent" || echo "checking for struct tm in time.h" -cat > conftest.${ac_ext} <<EOF + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TIMEVAL +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TIMEVAL 1 +EOF +} + +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + echo "$ac_t""no" 1>&6 + HAVE_TIMEVAL=no +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:2635: checking whether struct tm is in sys/time.h or time.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2638 "configure" #include "confdefs.h" #include <sys/types.h> #include <time.h> -int main() { return 0; } -int t() { struct tm *tp; tp->tm_sec;; return 0; } -EOF -if eval $ac_compile; then - : -else - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining TM_IN_SYS_TIME" -echo "#define" TM_IN_SYS_TIME "1" >> confdefs.h -DEFS="$DEFS -DTM_IN_SYS_TIME=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}TM_IN_SYS_TIME\${ac_dB}TM_IN_SYS_TIME\${ac_dC}1\${ac_dD} -\${ac_uA}TM_IN_SYS_TIME\${ac_uB}TM_IN_SYS_TIME\${ac_uC}1\${ac_uD} -\${ac_eA}TM_IN_SYS_TIME\${ac_eB}TM_IN_SYS_TIME\${ac_eC}1\${ac_eD} -" -} - -fi -rm -f conftest* - -ac_decl='#include <sys/types.h> -' -case "$DEFS" in - *TM_IN_SYS_TIME*) ac_decl="$ac_decl -#include <sys/time.h> -" ;; - *) ac_decl="$ac_decl -#include <time.h> -" ;; -esac -test -n "$silent" || echo "checking for tm_zone in struct tm" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -$ac_decl -int main() { return 0; } -int t() { struct tm tm; tm.tm_zone;; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_TM_ZONE" -echo "#define" HAVE_TM_ZONE "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TM_ZONE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TM_ZONE\${ac_dB}HAVE_TM_ZONE\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TM_ZONE\${ac_uB}HAVE_TM_ZONE\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TM_ZONE\${ac_eB}HAVE_TM_ZONE\${ac_eC}1\${ac_eD} -" -} - - -else - rm -rf conftest* - ac_no_tm_zone=1 -fi -rm -f conftest* - -if test -n "$ac_no_tm_zone"; then -test -n "$silent" || echo "checking for tzname" -cat > conftest.${ac_ext} <<EOF +int main() { +struct tm *tp; tp->tm_sec; +; return 0; } +EOF +if { (eval echo configure:2646: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_struct_tm=time.h +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_struct_tm=sys/time.h +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_struct_tm" 1>&6 +if test $ac_cv_struct_tm = sys/time.h; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining TM_IN_SYS_TIME +EOF +cat >> confdefs.h <<\EOF +#define TM_IN_SYS_TIME 1 +EOF +} + +fi + +echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 +echo "configure:2670: checking for tm_zone in struct tm" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2673 "configure" +#include "confdefs.h" +#include <sys/types.h> +#include <$ac_cv_struct_tm> +int main() { +struct tm tm; tm.tm_zone; +; return 0; } +EOF +if { (eval echo configure:2681: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_struct_tm_zone=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_struct_tm_zone=no +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6 +if test "$ac_cv_struct_tm_zone" = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TM_ZONE +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TM_ZONE 1 +EOF +} + +else + echo $ac_n "checking for tzname""... $ac_c" 1>&6 +echo "configure:2704: checking for tzname" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2707 "configure" #include "confdefs.h" #include <time.h> #ifndef tzname /* For SGI. */ -extern char *tzname[]; /* RS6000 and others want it this way. */ +extern char *tzname[]; /* RS6000 and others reject char **tzname. */ #endif -int main() { return 0; } -int t() { atoi(*tzname);; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_TZNAME" -echo "#define" HAVE_TZNAME "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TZNAME=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TZNAME\${ac_dB}HAVE_TZNAME\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TZNAME\${ac_uB}HAVE_TZNAME\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TZNAME\${ac_eB}HAVE_TZNAME\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - -fi - - -ac_prog='/* Ultrix mips cc rejects this. */ +int main() { +atoi(*tzname); +; return 0; } +EOF +if { (eval echo configure:2717: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + ac_cv_var_tzname=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_var_tzname=no +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_var_tzname" 1>&6 + if test $ac_cv_var_tzname = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TZNAME +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TZNAME 1 +EOF +} + + fi +fi + + +echo $ac_n "checking for working const""... $ac_c" 1>&6 +echo "configure:2743: checking for working const" >&5 + +cat > conftest.$ac_ext <<EOF +#line 2746 "configure" +#include "confdefs.h" + +int main() { + +/* Ultrix mips cc rejects this. */ typedef int charset[2]; const charset x; /* SunOS 4.1.1 cc rejects this. */ char const *const *ccp; char **p; +/* NEC SVR4.0.2 mips cc rejects this. */ +struct point {int x, y;}; +static struct point const zero = {0,0}; /* AIX XL C 1.02.0.0 rejects this. It does not let you subtract one const X* pointer from another in an arm of an if-expression whose if-part is not a constant expression */ @@ -2353,7 +2771,7 @@ *t++ = 0; } { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25,17}; + int x[] = {25, 17}; const int *foo = &x[0]; ++foo; } @@ -2369,47 +2787,109 @@ } { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ const int foo = 10; -}' -test -n "$silent" || echo "checking for lack of working const" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { $ac_prog; return 0; } -EOF -if eval $ac_compile; then - : -else - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining" const to be empty -echo "#define" const "" >> confdefs.h -DEFS="$DEFS -Dconst=" -ac_sed_defs="${ac_sed_defs}\${ac_dA}const\${ac_dB}const\${ac_dC}\${ac_dD} -\${ac_uA}const\${ac_uB}const\${ac_uC}\${ac_uD} -\${ac_eA}const\${ac_eB}const\${ac_eC}\${ac_eD} -" -} - -fi -rm -f conftest* - - -cat > conftestmake <<'EOF' +} + +; return 0; } +EOF +if { (eval echo configure:2795: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_const=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_c_const=no +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_c_const" 1>&6 +if test $ac_cv_c_const = no; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining const = +EOF +cat >> confdefs.h <<\EOF +#define const +EOF +} + +fi + + +echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 +echo "configure:2820: checking whether ${MAKE-make} sets \${MAKE}" >&5 +set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` + +cat > conftestmake <<\EOF all: @echo 'ac_maketemp="${MAKE}"' EOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` -if test -n "$ac_maketemp"; then SET_MAKE= -else SET_MAKE="MAKE=${MAKE-make}"; fi +if test -n "$ac_maketemp"; then + eval ac_cv_prog_make_${ac_make}_set=yes +else + eval ac_cv_prog_make_${ac_make}_set=no +fi rm -f conftestmake - - -test -n "$silent" || echo "checking byte ordering" -cat > conftest.${ac_ext} <<EOF +if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then + echo "$ac_t""yes" 1>&6 + SET_MAKE= +else + echo "$ac_t""no" 1>&6 + SET_MAKE="MAKE=${MAKE-make}" +fi + + +echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 +echo "configure:2845: 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 <<EOF +#line 2850 "configure" +#include "confdefs.h" +#include <sys/types.h> +#include <sys/param.h> +int main() { + +#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN + bogus endian macros +#endif +; return 0; } +EOF +if { (eval echo configure:2861: \"$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 <<EOF +#line 2865 "configure" +#include "confdefs.h" +#include <sys/types.h> +#include <sys/param.h> +int main() { + +#if BYTE_ORDER != BIG_ENDIAN + not big endian +#endif +; return 0; } +EOF +if { (eval echo configure:2876: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_bigendian=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_c_bigendian=no +fi +rm -f conftest* +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 +fi +rm -f conftest* +if test $ac_cv_c_bigendian = unknown; then +cat > conftest.$ac_ext <<EOF +#line 2893 "configure" #include "confdefs.h" main () { /* Are we little or big endian? From Harbison&Steele. */ @@ -2422,119 +2902,215 @@ exit (u.c[sizeof (long) - 1] == 1); } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - : -else - -{ -test -n "$verbose" && \ -echo " defining WORDS_BIGENDIAN" -echo "#define" WORDS_BIGENDIAN "1" >> confdefs.h -DEFS="$DEFS -DWORDS_BIGENDIAN=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}WORDS_BIGENDIAN\${ac_dB}WORDS_BIGENDIAN\${ac_dC}1\${ac_dD} -\${ac_uA}WORDS_BIGENDIAN\${ac_uB}WORDS_BIGENDIAN\${ac_uC}1\${ac_uD} -\${ac_eA}WORDS_BIGENDIAN\${ac_eB}WORDS_BIGENDIAN\${ac_eC}1\${ac_eD} -" -} - +if { (eval echo configure:2906: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_c_bigendian=no +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_c_bigendian=yes fi rm -fr conftest* - - -test -n "$silent" || echo "checking for long file names" -ac_some_dir_failed=false +fi + +echo "$ac_t""$ac_cv_c_bigendian" 1>&6 +if test $ac_cv_c_bigendian = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining WORDS_BIGENDIAN +EOF +cat >> confdefs.h <<\EOF +#define WORDS_BIGENDIAN 1 +EOF +} + +fi + + +echo $ac_n "checking for long file names""... $ac_c" 1>&6 +echo "configure:2932: 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: # . the current directory, where building will happen +# $prefix/lib where we will be installing things +# $exec_prefix/lib likewise +# eval it to expand exec_prefix. +# $TMPDIR if set, where it might want to write temporary files +# if $TMPDIR is not set: # /tmp where it might want to write temporary files # /var/tmp likewise # /usr/tmp likewise -# $prefix/lib where we will be installing things -# $exec_prefix/lib likewise -# eval it to expand exec_prefix. -for ac_dir in `eval echo . /tmp /var/tmp /usr/tmp $prefix/lib $exec_prefix/lib` ; do +if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then + ac_tmpdirs="$TMPDIR" +else + ac_tmpdirs='/tmp /var/tmp /usr/tmp' +fi +for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do test -d $ac_dir || continue - test -w $ac_dir || continue # It's less confusing to not echo anything here. + test -w $ac_dir || continue # It is less confusing to not echo anything here. (echo 1 > $ac_dir/conftest9012345) 2>/dev/null (echo 2 > $ac_dir/conftest9012346) 2>/dev/null val=`cat $ac_dir/conftest9012345 2>/dev/null` - test -f $ac_dir/conftest9012345 && test "$val" = 1 || ac_some_dir_failed=true - rm -f $ac_dir/conftest9012345 $ac_dir/conftest9012346 2> /dev/null -done -$ac_some_dir_failed || -{ -test -n "$verbose" && \ -echo " defining HAVE_LONG_FILE_NAMES" -echo "#define" HAVE_LONG_FILE_NAMES "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LONG_FILE_NAMES=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LONG_FILE_NAMES\${ac_dB}HAVE_LONG_FILE_NAMES\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LONG_FILE_NAMES\${ac_uB}HAVE_LONG_FILE_NAMES\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LONG_FILE_NAMES\${ac_eB}HAVE_LONG_FILE_NAMES\${ac_eC}1\${ac_eD} -" -} - - - -echo "checking for -xildoff compiler flag" -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 - : - else - test -n "$verbose" && echo " defining NEED_XILDOFF" - need_xildoff=yes + if test ! -f $ac_dir/conftest9012345 || test "$val" != 1; then + ac_cv_sys_long_file_names=no + rm -f $ac_dir/conftest9012345 $ac_dir/conftest9012346 2>/dev/null + break fi -fi - -# What the hell was this doing here?????? -### echo > confdefs.h # this gets nuked above... - -############################################################################ -# # -# Choose a window system # -# # -############################################################################ - -#### Choose a window system. -echo "checking for specified window system" - -window_system='' -case "${with_x11}" in - yes ) window_system=${window_system}x11 ;; - no ) window_system=${window_system}none ;; -esac - -case "${window_system}" in - "none" | "x11" ) ;; - "" ) - # --x-includes or --x-libraries implies --with-x11. - if test -n "${x_includes}" -o -n "${x_libraries}"; then - window_system=x11 - else - echo " No window system specified. Looking for X11." - # If the user didn't specify a window system and we found X11, use it. - if test -r /usr/lib/libX11.a \ - -o -d /usr/include/X11 \ - -o -d /usr/X386/include \ - -o -d /usr/X11R6/include \ - -o -d ${x_includes}/X11 ; then - window_system=x11 - fi - fi - ;; - * ) - echo "Don't specify a window system more than once." >&2 - exit 1 - ;; -esac - -case "${window_system}" in "" | "x11" ) - ### If the user hasn't specified where we should find X, try - ### letting autoconf figure that out. - if test -z "${x_includes}${x_libraries}" ; then - # If we find X, set shell vars x_includes and x_libraries to the paths. -no_x=true -if test "x$with_x" != xno; then -test -n "$silent" || echo "checking for X include and library files with xmkmf" + rm -f $ac_dir/conftest9012345 $ac_dir/conftest9012346 2>/dev/null +done + +echo "$ac_t""$ac_cv_sys_long_file_names" 1>&6 +if test $ac_cv_sys_long_file_names = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_LONG_FILE_NAMES +EOF +cat >> confdefs.h <<\EOF +#define HAVE_LONG_FILE_NAMES 1 +EOF +} + +fi + + + + +echo $ac_n "checking for sqrt in -lm""... $ac_c" 1>&6 +echo "configure:2980: checking for sqrt in -lm" >&5 +ac_lib_var=`echo m'_'sqrt | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lm " +cat > conftest.$ac_ext <<EOF +#line 2985 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char sqrt(); + +int main() { +sqrt() +; return 0; } +EOF +if { (eval echo configure:2996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_tr_lib=HAVE_LIB`echo m | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_lib +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_lib 1 +EOF +} + + LIBS="-lm $LIBS" + +else + echo "$ac_t""no" 1>&6 +fi + + + +echo "checking type of mail spool file locking" 1>&6 +echo "configure:3029: 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 + Defining REAL_MAIL_USE_LOCKF +EOF +cat >> confdefs.h <<\EOF +#define REAL_MAIL_USE_LOCKF 1 +EOF +} + +elif test "$mail_locking" = "flock"; then { test "$extra_verbose" = "yes" && cat << \EOF + Defining REAL_MAIL_USE_FLOCK +EOF +cat >> confdefs.h <<\EOF +#define REAL_MAIL_USE_FLOCK 1 +EOF +} + +fi + +if test "$need_dynodump" = "yes" ; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining DYNODUMP +EOF +cat >> confdefs.h <<\EOF +#define DYNODUMP 1 +EOF +} + + MAKE_SUBDIR="$MAKE_SUBDIR dynodump" + case "$canonical" in + sparc* ) dynodump_arch=sparc ;; + powerpc* ) dynodump_arch=ppc ;; + i*86* ) dynodump_arch=i386 ;; + esac + test "$GCC" = "yes" && ld_switch_site="-fno-gnu-linker $ld_switch_site" +fi + +for dir in "/usr/ccs/lib"; do + test -d "$dir" && ld_switch_site="$ld_switch_site -L${dir}" +done + + +echo "checking "for specified window system"" 1>&6 +echo "configure:3074: checking "for specified window system"" >&5 + +if test "$x_includes $x_libraries" = "NONE NONE"; then + if test -n "$OPENWINHOME" \ + -a "$OPENWINHOME" != "/usr/openwin" \ + -a -d "$OPENWINHOME"; then + test -d "$OPENWINHOME/lib" && x_libraries="$OPENWINHOME/lib" + test -d "$OPENWINHOME/include" && x_includes="$OPENWINHOME/include" + test -d "$OPENWINHOME/share/include" && x_includes="$OPENWINHOME/share/include" + fi +fi + +test "$x_includes $x_libraries" != "NONE NONE" && \ + window_system=x11 with_x11=yes + +if test "$with_x11" != "no"; then + # If we find X, set shell vars x_includes and x_libraries to the +# paths, otherwise set no_x=yes. +# 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:3095: checking for X" >&5 + +# Check whether --with-x or --without-x was given. +if test "${with_x+set}" = set; then + withval="$with_x" + : +fi + +# $have_x is `yes', `no', `disabled', or empty when we do not yet know. +if test "x$with_x" = xno; then + # The user explicitly disabled X. + have_x=disabled +else + if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then + # Both variables are already set. + have_x=yes + else + +# One or both of the vars are not set, and there is no cached value. +ac_x_includes=NO ac_x_libraries=NO rm -fr conftestdir if mkdir conftestdir; then cd conftestdir @@ -2544,71 +3120,76 @@ @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"' EOF if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then - no_x= # GNU make sometimes prints "make[1]: Entering...", which would confuse us. - eval `make acfindx 2>/dev/null | grep -v make` + eval `${MAKE-make} acfindx 2>/dev/null | grep -v make` # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. - if test ! -f $ac_im_usrlibdir/libX11.a && test -f $ac_im_libdir/libX11.a - then - ac_im_usrlibdir=$ac_im_libdir - fi + for ac_extension in a so sl; do + if test ! -f $ac_im_usrlibdir/libX11.$ac_extension && + test -f $ac_im_libdir/libX11.$ac_extension; then + ac_im_usrlibdir=$ac_im_libdir; break + fi + done + # Screen out bogus values from the imake configuration. They are + # bogus both because they are the default anyway, and because + # using them would break gcc on systems where it needs fixed includes. case "$ac_im_incroot" in /usr/include) ;; - *) test -z "$x_includes" && x_includes="$ac_im_incroot" ;; + *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;; esac case "$ac_im_usrlibdir" in /usr/lib | /lib) ;; - *) test -z "$x_libraries" && x_libraries="$ac_im_usrlibdir" ;; + *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;; esac fi cd .. rm -fr conftestdir fi -if test -z "$ac_im_usrlibdir"; then -test -n "$silent" || echo "checking for X include and library files directly" -if test ".$x_direct_test_library" = . ; then - x_direct_test_library='Xt' -fi -if test ".$x_direct_test_include" = . ; then - x_direct_test_include='X11/Intrinsic.h' -fi -cat > conftest.${ac_ext} <<EOF +if test "$ac_x_includes" = NO; then + # Guess where to find include files, by looking for this one X11 .h file. + test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h + + # First, try using that file with no special directory specified. +cat > conftest.$ac_ext <<EOF +#line 3155 "configure" #include "confdefs.h" #include <$x_direct_test_include> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3160: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - no_x= - -else - rm -rf conftest* + # We can compile using X headers with no special include directory. +ac_x_includes= +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + # Look for the header file in a standard set of common directories. +# Check X11 before X11Rn because it is often a symlink to the current release. for ac_dir in \ + /usr/X11/include \ /usr/X11R6/include \ /usr/X11R5/include \ /usr/X11R4/include \ \ + /usr/include/X11 \ /usr/include/X11R6 \ /usr/include/X11R5 \ /usr/include/X11R4 \ \ + /usr/local/X11/include \ /usr/local/X11R6/include \ /usr/local/X11R5/include \ /usr/local/X11R4/include \ \ + /usr/local/include/X11 \ /usr/local/include/X11R6 \ /usr/local/include/X11R5 \ /usr/local/include/X11R4 \ \ - /usr/X11/include \ - /usr/include/X11 \ - /usr/local/X11/include \ - /usr/local/include/X11 \ - \ /usr/X386/include \ /usr/x386/include \ /usr/XFree86/include/X11 \ @@ -2625,58 +3206,65 @@ ; \ do if test -r "$ac_dir/$x_direct_test_include"; then - test -z "$x_includes" && x_includes=$ac_dir - no_x= + ac_x_includes=$ac_dir break fi done fi rm -f conftest* - -# Check for the libraries. First see if replacing the `include' by -# `lib' works. -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -l"$x_direct_test_library"" -ac_have_lib="" -test -n "$silent" || echo "checking for -l"$x_direct_test_library"" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; no_x= -else - :; for ac_dir in `echo "$x_includes" | sed s/include/lib/` \ +fi # $ac_x_includes = NO + +if test "$ac_x_libraries" = NO; then + # Check for the libraries. + + test -z "$x_direct_test_library" && x_direct_test_library=Xt + test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc + + # See if we find them without any special options. + # Don't add to $LIBS permanently. + ac_save_LIBS="$LIBS" + LIBS="-l$x_direct_test_library $LIBS" +cat > conftest.$ac_ext <<EOF +#line 3229 "configure" +#include "confdefs.h" + +int main() { +${x_direct_test_function}() +; return 0; } +EOF +if { (eval echo configure:3236: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + LIBS="$ac_save_LIBS" +# We can link X programs with no special library path. +ac_x_libraries= +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + LIBS="$ac_save_LIBS" +# First see if replacing the include by lib works. +# Check X11 before X11Rn because it is often a symlink to the current release. +for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \ + /usr/X11/lib \ /usr/X11R6/lib \ /usr/X11R5/lib \ /usr/X11R4/lib \ \ + /usr/lib/X11 \ /usr/lib/X11R6 \ /usr/lib/X11R5 \ /usr/lib/X11R4 \ \ + /usr/local/X11/lib \ /usr/local/X11R6/lib \ /usr/local/X11R5/lib \ /usr/local/X11R4/lib \ \ + /usr/local/lib/X11 \ /usr/local/lib/X11R6 \ /usr/local/lib/X11R5 \ /usr/local/lib/X11R4 \ \ - /usr/X11/lib \ - /usr/lib/X11 \ - /usr/local/X11/lib \ - /usr/local/lib/X11 \ - \ /usr/X386/lib \ /usr/x386/lib \ /usr/XFree86/lib/X11 \ @@ -2687,6 +3275,7 @@ /usr/athena/lib \ /usr/local/x11r5/lib \ /usr/lpp/Xamples/lib \ + /lib/usr/lib/X11 \ \ /usr/openwin/lib \ /usr/openwin/share/lib \ @@ -2694,53 +3283,1192 @@ do for ac_extension in a so sl; do if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then - test -z "$x_libraries" && x_libraries=$ac_dir - no_x= + ac_x_libraries=$ac_dir break 2 fi done done fi - -fi -test -n "$x_includes" && test -n "$verbose" && echo " X11 headers are in $x_includes" -test -n "$x_libraries" && test -n "$verbose" && echo " X11 libraries are in $x_libraries" -fi +rm -f conftest* +fi # $ac_x_libraries = NO + +if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then + # Didn't find X anywhere. Cache the known absence of X. + ac_cv_have_x="have_x=no" +else + # Record where we found X for the cache. + ac_cv_have_x="have_x=yes \ + ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries" +fi + fi + eval "$ac_cv_have_x" +fi # $with_x != no + +if test "$have_x" != yes; then + echo "$ac_t""$have_x" 1>&6 + no_x=yes +else + # If each of the values was on the command line, it overrides each guess. + test "x$x_includes" = xNONE && x_includes=$ac_x_includes + test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries + # Update the cache value to reflect the command line values. + ac_cv_have_x="have_x=yes \ + ac_x_includes=$x_includes ac_x_libraries=$x_libraries" + echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6 +fi + +if test "$no_x" = yes; then + # Not all programs may use this symbol, but it does not hurt to define it. + { test "$extra_verbose" = "yes" && cat << \EOF + Defining X_DISPLAY_MISSING +EOF +cat >> confdefs.h <<\EOF +#define X_DISPLAY_MISSING 1 +EOF +} + + X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= +else + if test -n "$x_includes"; then + X_CFLAGS="$X_CFLAGS -I$x_includes" + fi + + # It would also be nice to do this for all -L options, not just this one. + if test -n "$x_libraries"; then + X_LIBS="$X_LIBS -L$x_libraries" + # For Solaris; some versions of Sun CC require a space after -R and + # others require no space. Words are not sufficient . . . . + case "`(uname -sr) 2>/dev/null`" in + "SunOS 5"*) + echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6 +echo "configure:3345: checking whether -R must be followed by a space" >&5 + ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries" + cat > conftest.$ac_ext <<EOF +#line 3348 "configure" +#include "confdefs.h" + +int main() { + +; return 0; } +EOF +if { (eval echo configure:3355: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + ac_R_nospace=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_R_nospace=no +fi +rm -f conftest* + if test $ac_R_nospace = yes; then + echo "$ac_t""no" 1>&6 + X_LIBS="$X_LIBS -R$x_libraries" + else + LIBS="$ac_xsave_LIBS -R $x_libraries" + cat > conftest.$ac_ext <<EOF +#line 3371 "configure" +#include "confdefs.h" + +int main() { + +; return 0; } +EOF +if { (eval echo configure:3378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + ac_R_space=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_R_space=no +fi +rm -f conftest* + if test $ac_R_space = yes; then + echo "$ac_t""yes" 1>&6 + X_LIBS="$X_LIBS -R $x_libraries" + else + echo "$ac_t""neither works" 1>&6 + fi + fi + LIBS="$ac_xsave_LIBS" + esac + fi + + # Check for system-dependent libraries X programs must link with. + # Do this before checking for the system-independent R6 libraries + # (-lICE), since we may need -lsocket or whatever for X linking. + + if test "$ISC" = yes; then + X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" + else + # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X + # libraries were built with DECnet support. And karl@cs.umb.edu says + # the Alpha needs dnet_stub (dnet does not exist). + if test "$with_dnet" = "no"; then +ac_cv_lib_dnet_dnet_ntoa=no +else + +echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6 +echo "configure:3414: 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 <<EOF +#line 3419 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dnet_ntoa(); + +int main() { +dnet_ntoa() +; return 0; } +EOF +if { (eval echo configure:3430: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" +else + echo "$ac_t""no" 1>&6 +fi + +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:3454: 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 <<EOF +#line 3459 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dnet_ntoa(); + +int main() { +dnet_ntoa() +; return 0; } +EOF +if { (eval echo configure:3470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" +else + echo "$ac_t""no" 1>&6 +fi + + + fi + + # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, + # to get the SysV transport functions. + # chad@anasazi.com says the Pyramis MIS-ES running DC/OSx (SVR4) + # needs -lnsl. + # The nsl library prevents programs from opening the X display + # on Irix 5.2, according to dickey@clark.net. + echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 +echo "configure:3499: checking for gethostbyname" >&5 + +cat > conftest.$ac_ext <<EOF +#line 3502 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char gethostbyname(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char gethostbyname(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) +choke me +#else +gethostbyname(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3525: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_gethostbyname=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_gethostbyname=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +fi + + if test $ac_cv_func_gethostbyname = no; then + +echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 +echo "configure:3546: checking for gethostbyname in -lnsl" >&5 +ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lnsl " +cat > conftest.$ac_ext <<EOF +#line 3551 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char gethostbyname(); + +int main() { +gethostbyname() +; return 0; } +EOF +if { (eval echo configure:3562: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" +else + echo "$ac_t""no" 1>&6 +fi + + + fi + + # lieder@skyler.mavd.honeywell.com says without -lsocket, + # socket/setsockopt and other routines are undefined under SCO ODT + # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary + # on later versions), says simon@lia.di.epfl.ch: it contains + # gethostby* variants that don't use the nameserver (or something). + # -lsocket must be given before -lnsl if both are needed. + # We assume that if connect needs -lnsl, so does gethostbyname. + echo $ac_n "checking for connect""... $ac_c" 1>&6 +echo "configure:3592: checking for connect" >&5 + +cat > conftest.$ac_ext <<EOF +#line 3595 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char connect(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char connect(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_connect) || defined (__stub___connect) +choke me +#else +connect(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_connect=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_connect=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +fi + + if test $ac_cv_func_connect = no; then + +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:3641: 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 <<EOF +#line 3646 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char connect(); + +int main() { +connect() +; return 0; } +EOF +if { (eval echo configure:3657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" +else + echo "$ac_t""no" 1>&6 +fi + + + 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:3681: checking for remove" >&5 + +cat > conftest.$ac_ext <<EOF +#line 3684 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char remove(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char remove(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_remove) || defined (__stub___remove) +choke me +#else +remove(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_remove=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_remove=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'remove`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +fi + + if test $ac_cv_func_remove = no; then + +echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6 +echo "configure:3728: checking for remove in -lposix" >&5 +ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lposix " +cat > conftest.$ac_ext <<EOF +#line 3733 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char remove(); + +int main() { +remove() +; return 0; } +EOF +if { (eval echo configure:3744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" +else + echo "$ac_t""no" 1>&6 +fi + + + fi + + # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. + echo $ac_n "checking for shmat""... $ac_c" 1>&6 +echo "configure:3768: checking for shmat" >&5 + +cat > conftest.$ac_ext <<EOF +#line 3771 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char shmat(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char shmat(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_shmat) || defined (__stub___shmat) +choke me +#else +shmat(); +#endif + +; return 0; } +EOF +if { (eval echo configure:3794: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_shmat=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_shmat=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'shmat`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +fi + + if test $ac_cv_func_shmat = no; then + +echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6 +echo "configure:3815: checking for shmat in -lipc" >&5 +ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lipc " +cat > conftest.$ac_ext <<EOF +#line 3820 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char shmat(); + +int main() { +shmat() +; return 0; } +EOF +if { (eval echo configure:3831: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" +else + echo "$ac_t""no" 1>&6 +fi + fi - if test -n "${x_includes}${x_libraries}" ; then window_system=x11 ; fi - ;; + fi + + # Check for libraries that X11R6 Xt/Xaw programs need. + ac_save_LDFLAGS="$LDFLAGS" + test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" + # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to + # check for ICE first), but we must link in the order -lSM -lICE or + # we get undefined symbols. So assume we have SM if we have ICE. + # These have to be linked with before -lX11, unlike the other + # libraries we check for below, so use a different variable. + # --interran@uluru.Stanford.EDU, kb@cs.umb.edu. + +echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6 +echo "configure:3865: checking for IceConnectionNumber in -lICE" >&5 +ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lICE " +cat > conftest.$ac_ext <<EOF +#line 3870 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char IceConnectionNumber(); + +int main() { +IceConnectionNumber() +; return 0; } +EOF +if { (eval echo configure:3881: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" +else + echo "$ac_t""no" 1>&6 +fi + + + LDFLAGS="$ac_save_LDFLAGS" + +fi + # Autoconf claims to find X library and include dirs for us. + if test "$no_x" = "yes" + then with_x11=no window_system=none HAVE_X_WINDOWS=no + else with_x11=yes window_system=x11 HAVE_X_WINDOWS=yes + fi +fi + +case "$with_x11" in + yes ) window_system=x11 HAVE_X_WINDOWS=yes ;; + no ) window_system=none HAVE_X_WINDOWS=no ;; esac -test -z "${window_system}" && window_system="none" - -if test "${window_system}" = "none" ; then - if test "${with_tty}" != "yes" ; then - echo "No window system support, and no TTY support." >&2 - echo "Unable to proceed." >&2 - exit 1 +if test "$with_x11" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_X_WINDOWS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_X_WINDOWS 1 +EOF +} + + MAKE_SUBDIR="$MAKE_SUBDIR lwlib" + + for lib_dir in "/usr/dt/lib" "/usr/lib/Motif1.2" "/usr/lib/Motif1.1"; do + inc_dir="`echo $lib_dir | sed 's/lib/include/'`" + if test -d "$lib_dir" -a -d "$inc_dir"; then + case "$x_libraries" in *"$lib_dir"* ) : ;; *) + x_libraries="$lib_dir $x_libraries" X_LIBS="-L${lib_dir} $X_LIBS" + esac + case "$x_includes" in "$inc_dir"* ) : ;; *) + x_includes="$inc_dir $x_includes" X_CFLAGS="-I${inc_dir} $X_CFLAGS" + esac + break; fi + done + + for rel in "X11R6" "X11R5" "X11R4"; do + lib_dir="/usr/contrib/$rel/lib" inc_dir="/usr/contrib/$rel/include" + if test -d "$lib_dir" -a -d "$inc_dir"; then + case "$x_libraries" in *"$lib_dir"* ) : ;; *) + x_libraries="$x_libraries $lib_dir" X_LIBS="$X_LIBS -L${lib_dir}" + esac + case "$x_includes" in "$inc_dir"* ) : ;; *) + x_includes="$x_includes $inc_dir" X_CFLAGS="$X_CFLAGS -I${inc_dir}" + esac + break; fi + done + + ld_switch_x_site="$X_LIBS" + + if test "$extra_verbose" = "yes"; then + echo; echo "X11 compilation variables:" + echo "x_libraries = $x_libraries" +echo "x_includes = $x_includes" +echo "X_CFLAGS = $X_CFLAGS" +echo "X_LIBS = $X_LIBS" +echo "X_PRE_LIBS = $X_PRE_LIBS" +echo "X_EXTRA_LIBS = $X_EXTRA_LIBS" + echo + fi + + ac_safe=`echo "X11/Intrinsic.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/Intrinsic.h""... $ac_c" 1>&6 +echo "configure:3966: checking for X11/Intrinsic.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 3969 "configure" +#include "confdefs.h" +#include <X11/Intrinsic.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3974: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: "Unable to find X11 header files."" 1>&2; exit 1; } +fi + + + +echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6 +echo "configure:3998: checking for XOpenDisplay in -lX11" >&5 +ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lX11 " +cat > conftest.$ac_ext <<EOF +#line 4003 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XOpenDisplay(); + +int main() { +XOpenDisplay() +; return 0; } +EOF +if { (eval echo configure:4014: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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_lib_x11=yes +else + echo "$ac_t""no" 1>&6 +fi + + + if test "$have_lib_x11" != "yes"; then + +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:4039: 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 <<EOF +#line 4044 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XGetFontProperty(); + +int main() { +XGetFontProperty() +; return 0; } +EOF +if { (eval echo configure:4055: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ld_switch_x_site="-b i486-linuxaout $ld_switch_x_site" +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: "Unable to find X11 libraries."" 1>&2; exit 1; } +fi + + fi - for feature in cde offix menubars scrollbars toolbars dialogs xim tiff + libs_x="-lX11" + + case "$canonical" in *-sunos4.* ) # Bug workaround + ld_switch_x_site="$ld_switch_x_site -u _XtToolkitInitialize" ;; + esac + +echo $ac_n "checking for XtOpenDisplay in -lXt""... $ac_c" 1>&6 +echo "configure:4084: checking for XtOpenDisplay in -lXt" >&5 +ac_lib_var=`echo Xt'_'XtOpenDisplay | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXt " +cat > conftest.$ac_ext <<EOF +#line 4089 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XtOpenDisplay(); + +int main() { +XtOpenDisplay() +; return 0; } +EOF +if { (eval echo configure:4100: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + libs_x="-lXt $libs_x" +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: "Unable to find X11 libraries."" 1>&2; exit 1; } +fi + + + + echo $ac_n "checking the version of X11 being used""... $ac_c" 1>&6 +echo "configure:4123: checking the version of X11 being used" >&5 + cat > conftest.$ac_ext <<EOF +#line 4125 "configure" +#include "confdefs.h" +#include <X11/Intrinsic.h> + main(int c, char* v[]) { return c>1 ? XlibSpecificationRelease : 0; } +EOF +if { (eval echo configure:4130: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ./conftest foobar; rc=$? +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + rc=4 +fi +rm -fr conftest* + echo "$ac_t""R${rc}" 1>&6 + { test "$extra_verbose" = "yes" && cat << EOF + Defining THIS_IS_X11R${rc} +EOF +cat >> confdefs.h <<EOF +#define THIS_IS_X11R${rc} 1 +EOF +} + + + for ac_hdr in X11/Xlocale.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:4154: checking for $ac_hdr" >&5 + +cat > conftest.$ac_ext <<EOF +#line 4157 "configure" +#include "confdefs.h" +#include <$ac_hdr> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4162: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_hdr +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_hdr 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi +done + + + echo $ac_n "checking for XFree86""... $ac_c" 1>&6 +echo "configure:4193: checking for XFree86" >&5 + if test -d "/usr/X386/include" -o \ + -f "/etc/XF86Config" -o \ + -f "/etc/X11/XF86Config" -o \ + -f "/usr/X11R6/lib/X11/XF86Config"; then + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_XFREE386 +EOF +cat >> confdefs.h <<\EOF +#define HAVE_XFREE386 1 +EOF +} + + else + echo "$ac_t""no" 1>&6 + fi + + +echo $ac_n "checking for XShapeSelectInput in -lXext""... $ac_c" 1>&6 +echo "configure:4213: checking for XShapeSelectInput in -lXext" >&5 +ac_lib_var=`echo Xext'_'XShapeSelectInput | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXext " +cat > conftest.$ac_ext <<EOF +#line 4218 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XShapeSelectInput(); + +int main() { +XShapeSelectInput() +; return 0; } +EOF +if { (eval echo configure:4229: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + libs_x="-lXext $libs_x" +else + echo "$ac_t""no" 1>&6 +fi + + + + case "$canonical" in *-sunos4.* ) # Bug workaround + ld_switch_x_site="$ld_switch_x_site -u _get_applicationShellWidgetClass" ;; + esac + if test -z "$with_xmu"; then + +echo $ac_n "checking for XmuConvertStandardSelection in -lXmu""... $ac_c" 1>&6 +echo "configure:4256: checking for XmuConvertStandardSelection in -lXmu" >&5 +ac_lib_var=`echo Xmu'_'XmuConvertStandardSelection | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXmu " +cat > conftest.$ac_ext <<EOF +#line 4261 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XmuConvertStandardSelection(); + +int main() { +XmuConvertStandardSelection() +; return 0; } +EOF +if { (eval echo configure:4272: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_xmu=yes +else + echo "$ac_t""no" 1>&6 +with_xmu=no +fi + + + fi + if test "$with_xmu" = "no"; then + extra_objs="$extra_objs xmu.o" + else + libs_x="-lXmu $libs_x" + fi + + +echo $ac_n "checking for main in -lXbsd""... $ac_c" 1>&6 +echo "configure:4302: checking for main in -lXbsd" >&5 +ac_lib_var=`echo Xbsd'_'main | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXbsd " +cat > conftest.$ac_ext <<EOF +#line 4307 "configure" +#include "confdefs.h" + +int main() { +main() +; return 0; } +EOF +if { (eval echo configure:4314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + libs_x="-lXbsd $libs_x" +else + echo "$ac_t""no" 1>&6 +fi + + + + ac_safe=`echo "Xm/Xm.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for Xm/Xm.h""... $ac_c" 1>&6 +echo "configure:4337: checking for Xm/Xm.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 4340 "configure" +#include "confdefs.h" +#include <Xm/Xm.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4345: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +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:4362: checking for XmStringFree in -lXm" >&5 +ac_lib_var=`echo Xm'_'XmStringFree | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXm " +cat > conftest.$ac_ext <<EOF +#line 4367 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XmStringFree(); + +int main() { +XmStringFree() +; return 0; } +EOF +if { (eval echo configure:4378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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_motif=yes +else + echo "$ac_t""no" 1>&6 +have_motif=no +fi + + +else + echo "$ac_t""no" 1>&6 +have_motif=no +fi + + + +echo $ac_n "checking for XawScrollbarSetThumb in -lXaw""... $ac_c" 1>&6 +echo "configure:4407: checking for XawScrollbarSetThumb in -lXaw" >&5 +ac_lib_var=`echo Xaw'_'XawScrollbarSetThumb | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXaw " +cat > conftest.$ac_ext <<EOF +#line 4412 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XawScrollbarSetThumb(); + +int main() { +XawScrollbarSetThumb() +; return 0; } +EOF +if { (eval echo configure:4423: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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_xaw=yes +else + echo "$ac_t""no" 1>&6 +have_xaw=no +fi + + + +fi +test -z "$window_system" && window_system="none" + +if test "$window_system" = "none" ; then + if test "$with_tty" = "no" ; then + { echo "configure: error: No window system support and no TTY support - Unable to proceed." 1>&2; exit 1; } + fi + for feature in tooltalk cde offix \ + menubars scrollbars toolbars dialogs xim xmu \ + tiff png jpeg gif compface xpm do - if eval "test -n \"\$with_$feature\" -a \"\$with_$feature\" != no" ; then - echo "configure: warning: --with-$feature ignored: Not valid without X support" >&2 + if eval "test -n \"\$with_${feature}\" -a \"\$with_${feature}\" != no" ; then + echo "configure: warning: --with-$feature ignored: Not valid without X support" 1>&2 fi - eval "with_$feature=no" + eval "with_${feature}=no" done -elif test -z "${with_toolbars}" ; then - with_toolbars='yes' -fi - +else + test -z "$with_toolbars" && with_toolbars=yes +fi + +if false; then # obsolete runtime_arg="-R${dash_r_space}" -case "${canonical}" in - *-sun-solaris* | *-sun-sunos5* ) +case "$canonical" in + *-sun-solaris* | *-sun-sunos5* ) add_runtime_flag=yes ;; *-sgi-irix5.* ) - # In the IRIX 5.3 ld, only the last -rpath arg has any effect. This is - # fundamentaly incompatible with having separate LD_SWITCH_X_SITE - # and LD_SWITCH_SITE variables. Fortunately, SGI fixed this by 6.2. - if test -n "${x_libraries}" || test -n "${site_runtime_libraries}" ; then + if test -n "$x_libraries" || test -n "$site_runtime_libraries" ; then (echo "WARNING: The IRIX 5 ld ignores all but the last -rpath argument,"; echo " so if you need to specify more than one additional"; echo " runtime library directory, you will have to do so"; @@ -2751,1954 +4479,1825 @@ fi runtime_arg="-rpath " ;; *-sgi-irix* ) - # Note that IRIX gcc (as of 2.7.2) doesn't accept -rpath, so - # using it can cause trouble. Specifying --use-gcc=no will work - # around this, but the real problem is that configure uses $LDFLAGS - # as arguments to $(CC), instead of using prefix-args like the - # src/Makefile does. - add_runtime_flag=yes; + add_runtime_flag=yes; runtime_arg="-rpath " ;; esac - -if test -n "${x_libraries}" ; then - if test "${add_runtime_flag}" = "yes" ; then - LD_SWITCH_X_SITE="-L${x_libraries} ${runtime_arg}${x_libraries}" - else - LD_SWITCH_X_SITE="-L${x_libraries}" - fi -fi -# LD_SWITCH_X_SITE_AUX (from FSF) is ill-conceived. See s/sol2*.h. -# test -n "${x_libraries}" -a LD_SWITCH_X_SITE_AUX="-R${x_libraries}" -test -n "${x_includes}" && C_SWITCH_X_SITE="-I${x_includes}" - -if test -n "${site_libraries}" ; then - for arg in ${site_libraries} - do - LD_SWITCH_SITE="${LD_SWITCH_SITE} -L${arg}" +fi + +if test -n "$site_libraries"; then + for arg in $site_libraries; do + test -d "$arg" && arg="-L${arg}" + ld_switch_site="$ld_switch_site $arg" done fi -if test -n "${site_runtime_libraries}" ; then - for arg in ${site_runtime_libraries} - do - LD_SWITCH_SITE="${LD_SWITCH_SITE} -L${arg}" - LD_SWITCH_SITE="${LD_SWITCH_SITE} ${runtime_arg}${arg}" - done -fi -if test -n "${site_includes}" ; then - for arg in ${site_includes} - do - C_SWITCH_SITE="${C_SWITCH_SITE} -I${arg}" - CPP="${CPP} -I${arg}" + +if test -n "$site_runtime_libraries" ; then + LD_RUN_PATH="`echo $site_runtime_libraries | sed 's/ */:/'`" + export LD_RUN_PATH +fi + +if test -n "$site_includes" ; then + for arg in $site_includes; do + test -d "$arg" && arg="-I${arg}" + c_switch_site="$c_switch_site $arg" done fi -# FSF 19.29 has some bitmapdir stuff here. + bitmapdir= -# Avoid forcing the search of /usr/include before fixed include files. -test "$C_SWITCH_X_SITE" = "-I/usr/include" && C_SWITCH_X_SITE=" " - -# Need for check for audio/Xtutil.h. -CPP="${CPP} ${C_SWITCH_X_SITE}" - -case "${window_system}" in +case "$window_system" in x11 ) HAVE_X_WINDOWS=yes; echo " Using X11." ;; none ) HAVE_X_WINDOWS=no ; echo " Using no window system." ;; esac -if test "${opsys}" = "hpux9"; then - case "${x_libraries}" in - *X11R4* ) opsysfile="s/hpux9-x11r4.h" ;; - esac -fi - -if test "${opsys}" = "hpux9-shr"; then - case "${x_libraries}" in - *X11R4* ) opsysfile="s/hpux9shxr4.h" ;; - esac -fi - -############################################################################ -# # -# Extract some information from the operating system and machine files # -# # -############################################################################ - -echo "examining the machine- and system-dependent files to find out" -echo " - which libraries the lib-src programs will want, and" -echo " - whether the GNU malloc routines are usable." - -### First figure out CFLAGS (which we use for running the compiler here) -### and REAL_CFLAGS (which we use for real compilation). -### The two are the same except on a few systems, where they are made -### different to work around various lossages. For example, -### GCC 2.5 on Linux needs them to be different because it treats -g -### as implying static linking. - -### If the CFLAGS env var is specified, we use that value -### instead of the default. - -### It's not important that this name contain the PID; you can't run -### two configures in the same directory and have anything work -### anyway. -tempcname="conftest.c" - -echo ' -#define NOT_C_CODE -#include "'${srcdir}'/src/'${opsysfile}'" -#include "'${srcdir}'/src/'${machfile}'" -#ifndef LIBS_MACHINE -#define LIBS_MACHINE -#endif -#ifndef LIBS_SYSTEM -#define LIBS_SYSTEM -#endif -#ifndef C_SWITCH_SYSTEM -#define C_SWITCH_SYSTEM -#endif -#ifndef C_SWITCH_X_SYSTEM -#define C_SWITCH_X_SYSTEM -#endif -#ifndef C_SWITCH_MACHINE -#define C_SWITCH_MACHINE -#endif -#ifndef LD_SWITCH_X_SYSTEM -#define LD_SWITCH_X_SYSTEM -#endif -#ifndef LIB_STANDARD -#define LIB_STANDARD -#endif -configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM LIB_STANDARD -configure___ c_switch_system=C_SWITCH_SYSTEM -configure___ c_switch_x_system=C_SWITCH_X_SYSTEM -configure___ ld_switch_x_system=LD_SWITCH_X_SYSTEM -configure___ c_switch_machine=C_SWITCH_MACHINE - -#ifndef LIB_X11_LIB -#define LIB_X11_LIB -lX11 -#endif - -#ifndef LIBX11_MACHINE -#define LIBX11_MACHINE -#endif - -#ifndef LIBX11_SYSTEM -#define LIBX11_SYSTEM -#endif -configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM - -#ifdef UNEXEC -configure___ unexec=UNEXEC -#else -configure___ unexec=unexec.o -#endif - -#ifdef SYSTEM_MALLOC -configure___ system_malloc=yes -#else -configure___ system_malloc=no -#endif - -#ifndef C_DEBUG_SWITCH -#define C_DEBUG_SWITCH -g -#endif - -#ifndef C_OPTIMIZE_SWITCH -#define C_OPTIMIZE_SWITCH -O -#endif - -#ifdef THIS_IS_CONFIGURE - -/* Get the CFLAGS for tests in configure. */ -#ifdef __GNUC__ -configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}' -#else -configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}' -#endif - -#else /* not THIS_IS_CONFIGURE */ - -/* Get the CFLAGS for real compilation. */ -#ifdef __GNUC__ -configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}' -#else -configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}' -#endif - -#endif /* not THIS_IS_CONFIGURE */ -' > ${tempcname} -# The value of CPP is a quoted variable reference, so we need to do this -# to get its actual value... -CPP=`eval "echo $CPP"` -eval `${CPP} -Isrc ${tempcname} \ - | grep 'configure___' \ - | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'` -if test "x$SPECIFIED_CFLAGS" = x ; then - eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \ - | grep 'configure___' \ - | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'` -else - REAL_CFLAGS="$CFLAGS" -fi -rm ${tempcname} - -# override CFLAGS if user wishes -if test "${cflags}" != "NO_CFLAGS_DEFINED" ; then - REAL_CFLAGS=${cflags} -fi - -### Compute the unexec source name from the object name. -UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`" - -# Do the opsystem or machine files prohibit the use of the GNU malloc? -# Assume not, until told otherwise. -GNU_MALLOC=yes -if test "${system_malloc}" = "yes" ; then - GNU_MALLOC=no - GNU_MALLOC_reason=" - (The GNU allocators don't work with this system configuration.)" -elif test "${use_system_malloc}" = "yes" ; then - GNU_MALLOC=no - GNU_MALLOC_reason=" - (User chose not to use GNU allocators.)" -fi - -LISP_FLOAT_TYPE=yes - - -#### Add the libraries to LIBS and check for some functions. - -CPPFLAGS="${C_SWITCH_SITE} $c_switch_system $c_switch_machine $c_switch_x_system $CPPFLAGS" -DEFS="${C_SWITCH_SITE} $c_switch_system $c_switch_machine $c_switch_x_system $DEFS" -LIBS="${LD_SWITCH_SITE} $ld_switch_x_system $libsrc_libs $LIBS" - -test "${with_dnet}" != "no" -a \ - "${with_dnet}" != "yes" && { ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -ldnet" -ac_have_lib="" -test -n "$silent" || echo "checking for -ldnet" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_dnet="yes" -else - :; +case "$x_libraries" in *X11R4* ) + test "$opsys" = "hpux9" && opsysfile="s/hpux9-x11r4.h" + test "$opsys" = "hpux9-shr" && opsysfile="s/hpux9shxr4.h" +esac + +{ test "$extra_verbose" = "yes" && cat << \EOF + Defining LISP_FLOAT_TYPE +EOF +cat >> confdefs.h <<\EOF +#define LISP_FLOAT_TYPE 1 +EOF +} + + +echo $ac_n "checking for kstat_open in -lkstat""... $ac_c" 1>&6 +echo "configure:4530: 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 <<EOF +#line 4535 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char kstat_open(); + +int main() { +kstat_open() +; return 0; } +EOF +if { (eval echo configure:4546: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_tr_lib=HAVE_LIB`echo kstat | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_lib +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_lib 1 +EOF +} + + LIBS="-lkstat $LIBS" + +else + echo "$ac_t""no" 1>&6 +fi + + + + +echo $ac_n "checking for kvm_read in -lkvm""... $ac_c" 1>&6 +echo "configure:4580: 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 <<EOF +#line 4585 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char kvm_read(); + +int main() { +kvm_read() +; return 0; } +EOF +if { (eval echo configure:4596: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_tr_lib=HAVE_LIB`echo kvm | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_lib +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_lib 1 +EOF +} + + LIBS="-lkvm $LIBS" + +else + echo "$ac_t""no" 1>&6 +fi + + + + +echo $ac_n "checking for cma_open in -lpthreads""... $ac_c" 1>&6 +echo "configure:4630: 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 <<EOF +#line 4635 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char cma_open(); + +int main() { +cma_open() +; return 0; } +EOF +if { (eval echo configure:4646: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_tr_lib=HAVE_LIB`echo pthreads | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_lib +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_lib 1 +EOF +} + + LIBS="-lpthreads $LIBS" + +else + echo "$ac_t""no" 1>&6 +fi + + +if test "$ac_cv_lib_pthreads_cma_open" = "yes"; then + case "$opsys" in decosf*) c_switch_site="$c_switch_site -threads";; esac +fi + +echo $ac_n "checking whether the -xildoff compiler flag is required""... $ac_c" 1>&6 +echo "configure:4682: 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; + else echo "$ac_t""yes" 1>&6; ld_switch_site="$ld_switch_site -xildoff" + fi + else echo "$ac_t""no" 1>&6 +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:4694: checking for X11/Xauth.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 4697 "configure" +#include "confdefs.h" +#include <X11/Xauth.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4702: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_xauth=no +fi + } +test -z "$with_xauth" && { +echo $ac_n "checking for XauGetAuthByAddr in -lXau""... $ac_c" 1>&6 +echo "configure:4725: checking for XauGetAuthByAddr in -lXau" >&5 +ac_lib_var=`echo Xau'_'XauGetAuthByAddr | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXau " +cat > conftest.$ac_ext <<EOF +#line 4730 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XauGetAuthByAddr(); + +int main() { +XauGetAuthByAddr() +; return 0; } +EOF +if { (eval echo configure:4741: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_xauth=no +fi + + } +test -z "$with_xauth" && with_xauth=yes +if test "$with_xauth" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_XAUTH +EOF +cat >> confdefs.h <<\EOF +#define HAVE_XAUTH 1 +EOF +} + + libs_x="-lXau $libs_x" +fi + +test -z "$with_offix" && { ac_safe=`echo "OffiX/DragAndDrop.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for OffiX/DragAndDrop.h""... $ac_c" 1>&6 +echo "configure:4777: checking for OffiX/DragAndDrop.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 4780 "configure" +#include "confdefs.h" +#include <OffiX/DragAndDrop.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4785: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_offix=no +fi + } +test -z "$with_offix" && { +echo $ac_n "checking for DndInitialize in -lDnd""... $ac_c" 1>&6 +echo "configure:4808: checking for DndInitialize in -lDnd" >&5 +ac_lib_var=`echo Dnd'_'DndInitialize | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lDnd " +cat > conftest.$ac_ext <<EOF +#line 4813 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char DndInitialize(); + +int main() { +DndInitialize() +; return 0; } +EOF +if { (eval echo configure:4824: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_offix=no +fi + + } +test -z "$with_offix" && with_offix=yes +if test "$with_offix" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_OFFIX_DND +EOF +cat >> confdefs.h <<\EOF +#define HAVE_OFFIX_DND 1 +EOF +} + + libs_x="-lDnd $libs_x" +fi + +test "$with_cde" = "yes" && with_tooltalk=yes # CDE requires tooltalk +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:4863: checking for ${dir}tt_c.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 4866 "configure" +#include "confdefs.h" +#include <${dir}tt_c.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4871: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + tt_c_h_path="${dir}tt_c.h" && break +else + echo "$ac_t""no" 1>&6 +fi + + done + test -z "$tt_c_h_path" && with_tooltalk=no +fi +if test "$with_tooltalk" != "no" ; then + for extra_libs in "" "-lI18N -lce" "-lcxx"; do + +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:4900: 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 <<EOF +#line 4905 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char tt_message_create(); + +int main() { +tt_message_create() +; return 0; } +EOF +if { (eval echo configure:4916: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_tooltalk=yes tt_libs="-ltt $extra_libs"; break +else + echo "$ac_t""no" 1>&6 +: +fi + + + done +fi +test -z "$with_tooltalk" && with_tooltalk=no +if test "$with_tooltalk" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining TOOLTALK +EOF +cat >> confdefs.h <<\EOF +#define TOOLTALK 1 +EOF +} + + { test "$extra_verbose" = "yes" && cat << EOF + Defining TT_C_H_PATH = "$tt_c_h_path" +EOF +cat >> confdefs.h <<EOF +#define TT_C_H_PATH "$tt_c_h_path" +EOF +} + + libs_x="$tt_libs $libs_x" + extra_objs="$extra_objs tooltalk.o" +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:4963: checking for Dt/Dt.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 4966 "configure" +#include "confdefs.h" +#include <Dt/Dt.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4971: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_cde=no fi } -test "${with_dnet}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_LIBDNET" -echo "#define" HAVE_LIBDNET "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LIBDNET=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LIBDNET\${ac_dB}HAVE_LIBDNET\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LIBDNET\${ac_uB}HAVE_LIBDNET\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LIBDNET\${ac_eB}HAVE_LIBDNET\${ac_eC}1\${ac_eD} -" -} - - - -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lkstat" -ac_have_lib="" -test -n "$silent" || echo "checking for -lkstat" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - -{ -test -n "$verbose" && \ -echo " defining HAVE_LIBKSTAT" -echo "#define" HAVE_LIBKSTAT "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LIBKSTAT=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LIBKSTAT\${ac_dB}HAVE_LIBKSTAT\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LIBKSTAT\${ac_uB}HAVE_LIBKSTAT\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LIBKSTAT\${ac_eB}HAVE_LIBKSTAT\${ac_eC}1\${ac_eD} -" -} - - LIBS="${LIBS} -lkstat" -fi - - -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lintl" -ac_have_lib="" -test -n "$silent" || echo "checking for -lintl" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; -{ -test -n "$verbose" && \ -echo " defining HAVE_LIBINTL" -echo "#define" HAVE_LIBINTL "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LIBINTL=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LIBINTL\${ac_dB}HAVE_LIBINTL\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LIBINTL\${ac_uB}HAVE_LIBINTL\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LIBINTL\${ac_eB}HAVE_LIBINTL\${ac_eC}1\${ac_eD} -" -} - -else - :; -fi - - -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lXbsd" -ac_have_lib="" -test -n "$silent" || echo "checking for -lXbsd" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd" -else - :; -fi - - -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lpthreads" -ac_have_lib="" -test -n "$silent" || echo "checking for -lpthreads" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; HAVE_PTHREADS=yes -else - :; -fi - -if test -n "${HAVE_PTHREADS}" ; then - -{ -test -n "$verbose" && \ -echo " defining HAVE_PTHREADS" -echo "#define" HAVE_PTHREADS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_PTHREADS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_PTHREADS\${ac_dB}HAVE_PTHREADS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_PTHREADS\${ac_uB}HAVE_PTHREADS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_PTHREADS\${ac_eB}HAVE_PTHREADS\${ac_eC}1\${ac_eD} -" -} - - case "${opsys}" in - decosf* ) CFLAGS="${CFLAGS} -threads" ;; - esac -fi - -if test "${window_system}" != "none" ; then - test -n "$silent" || echo "checking for XFree86" - if test -d /usr/X386/include; then - HAVE_XFREE386=yes - test -z "${C_SWITCH_X_SITE}" && C_SWITCH_X_SITE="-I/usr/X386/include" - elif test -f /etc/XF86Config -o \ - -f /etc/X11/XF86Config -o \ - -f /usr/X11R6/lib/X11/XF86Config; then - HAVE_XFREE386=yes - test -z "${C_SWITCH_X_SITE}" && C_SWITCH_X_SITE="-I/usr/X11R6/include" - else - HAVE_XFREE386=no - fi - test -n "$verbose" && echo " ${HAVE_XFREE386}" -else - HAVE_XFREE386=no -fi - -############################################################################ -# # -# Test for various X-specific features # -# # -############################################################################ - -# Change CFLAGS temporarily for damn binutils 2.6.0.10 check. -if test "${HAVE_X_WINDOWS}" = "yes"; then - case "${opsys}" in - linux* ) - CFLAGS="-Wl,-rpath-link,/usr/X11R6/lib $CFLAGS" - test -n "$silent" || echo "checking for whether path-link option is needed" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { ;; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - need_path_link=yes - -else - rm -rf conftest* - need_path_link=no -fi -rm -f conftest* - - if test "${need_path_link}" = "no"; then - CFLAGS="$REAL_CFLAGS" - test -n "$verbose" && echo " no" - else - test -n "$verbose" && echo " yes" - fi - ;; - esac -fi - -# Change CFLAGS temporarily so that C_SWITCH_X_SITE gets used -# for the tests that follow. We set it back to REAL_CFLAGS later on. +test -z "$with_cde" && { +echo $ac_n "checking for DtDndDragStart in -lDtSvc""... $ac_c" 1>&6 +echo "configure:4994: checking for DtDndDragStart in -lDtSvc" >&5 +ac_lib_var=`echo DtSvc'_'DtDndDragStart | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lDtSvc " +cat > conftest.$ac_ext <<EOF +#line 4999 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char DtDndDragStart(); + +int main() { +DtDndDragStart() +; return 0; } +EOF +if { (eval echo configure:5010: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_cde=no +fi + + } +test -z "$with_cde" && with_cde=yes +if test "$with_cde" = "yes" ; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_CDE +EOF +cat >> confdefs.h <<\EOF +#define HAVE_CDE 1 +EOF +} + + libs_x="-lDtSvc $libs_x" + with_tooltalk=yes # CDE requires Tooltalk + with_motif=yes # CDE requires Motif +fi + +if test "$with_energize" = "yes" ; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining ENERGIZE +EOF +cat >> confdefs.h <<\EOF +#define ENERGIZE 1 +EOF +} + -if test "${HAVE_X_WINDOWS}" = "yes"; then - DEFS="$C_SWITCH_X_SITE $DEFS" - LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE" - LIBS="$LIBX $LIBS" - CFLAGS="$C_SWITCH_X_SITE $CFLAGS" - - # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests. - # This is handled by LD_SWITCH_X_SITE_AUX during the real build, - # but it's more convenient here to set LD_RUN_PATH - # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX. - if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then - LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH - export LD_RUN_PATH - fi - - if test "${HAVE_XFREE386}" = "yes" ; then - case "${opsys}" in - linux* ) - test -n "$silent" || echo "checking for whether XFree86 needs -b to link" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { XOpenDisplay ("foo");; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - xfree86_first_failure=no - -else - rm -rf conftest* - xfree86_first_failure=yes -fi -rm -f conftest* - - if test "${xfree86_first_failure}" = "yes"; then - OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE" - OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE" - OLD_CPPFLAGS="$CPPFLAGS" - OLD_LIBS="$LIBS" - LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout" - C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout" - CPPFLAGS="$CPPFLAGS -b i486-linuxaout" - LIBS="$LIBS -b i486-linuxaout" - cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { XOpenDisplay ("foo");; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - xfree86_second_failure=no - -else - rm -rf conftest* - xfree86_second_failure=yes -fi -rm -f conftest* - - if test "${xfree86_second_failure}" = "yes"; then - # If we get the same failure with -b, there is no use adding -b. - # So take it out. This plays safe. - LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE" - C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE" - CPPFLAGS="$OLD_CPPFLAGS" - LIBS="$OLD_LIBS" - test -n "$verbose" && echo " no" - else - test -n "$verbose" && echo " yes" - fi - else - test -n "$verbose" && echo " no" - fi - ;; - esac - fi - -# A C_CHECK_FUNCS(XrmSetDatabase XScreenResourceString \ -#XScreenNumberOfScreen XSetWMProtocols) -fi - -# -# make sure we can find libX11.* -# -if test "${window_system}" != "none" ; then - internal_xlibs_found='no' - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lX11" -ac_have_lib="" -test -n "$silent" || echo "checking for -lX11" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; internal_xlibs_found='yes' -else - :; -fi - - if test "${internal_xlibs_found}" = "no" ; then - echo "Unable to find X11 libraries." >&2 - exit 1 - else - test -n "$verbose" && echo " yes" - fi -fi - -# -# make sure we can find Intrinsic.h -# -if test "${window_system}" != "none" ; then - internal_xincludes_found='no' - for arg in ${DEFS} /usr/include - do - if test -f `echo "${arg}/X11/Intrinsic.h" | sed 's/^\-I//'` ; then - internal_xincludes_found='yes' +echo $ac_n "checking for main in -lenergize""... $ac_c" 1>&6 +echo "configure:5057: checking for main in -lenergize" >&5 +ac_lib_var=`echo energize'_'main | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lenergize " +cat > conftest.$ac_ext <<EOF +#line 5062 "configure" +#include "confdefs.h" + +int main() { +main() +; return 0; } +EOF +if { (eval echo configure:5069: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + LIBS="$LIBS -lenergize" + energize_version="3.X" + { test "$extra_verbose" = "yes" && cat << \EOF + Defining ENERGIZE_3 +EOF +cat >> confdefs.h <<\EOF +#define ENERGIZE_3 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi + + + if test -z "$energize_version"; then + +echo $ac_n "checking for main in -lconn""... $ac_c" 1>&6 +echo "configure:5101: checking for main in -lconn" >&5 +ac_lib_var=`echo conn'_'main | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lconn " +cat > conftest.$ac_ext <<EOF +#line 5106 "configure" +#include "confdefs.h" + +int main() { +main() +; return 0; } +EOF +if { (eval echo configure:5113: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + LIBS="$LIBS -lconn" + energize_version="2.X" + { test "$extra_verbose" = "yes" && cat << \EOF + Defining ENERGIZE_2 +EOF +cat >> confdefs.h <<\EOF +#define ENERGIZE_2 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: Unable to find Energize library." 1>&2; exit 1; } +fi + + fi - done - if test "${internal_xincludes_found}" = "no" ; then - echo "Unable to find X11 header files." >&2 - exit 1 - fi -fi - -# -# Sun OS 4 systems need the following kludge -# -if test "${window_system}" != "none" ; then - case "${canonical}" in *-sunos4* ) - LIBS="$LIBS -u _XtToolkitInitialize -u _get_applicationShellWidgetClass" ;; - esac -fi - -# -# See if we can find Xauth. -# -with_xauth='no' -if test "${window_system}" != "none" ; then - internal_xauth_lib_found='no' - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lXau" -ac_have_lib="" -test -n "$silent" || echo "checking for -lXau" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; internal_xauth_lib_found='yes' -else - :; -fi - - if test "${internal_xauth_lib_found}" = "yes" ; then - internal_xauth_includes_found='no' - for arg in ${DEFS} /usr/include - do - if test -f `echo "${arg}/X11/Xauth.h" | sed 's/^\-I//'` ; then - internal_xauth_includes_found='yes' - fi - done - if test "${internal_xauth_includes_found}" = "yes" ; then - with_xauth='yes' - fi - fi -fi -test "${with_xauth}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_XAUTH" -echo "#define" HAVE_XAUTH "1" >> confdefs.h -DEFS="$DEFS -DHAVE_XAUTH=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_XAUTH\${ac_dB}HAVE_XAUTH\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_XAUTH\${ac_uB}HAVE_XAUTH\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_XAUTH\${ac_eB}HAVE_XAUTH\${ac_eC}1\${ac_eD} -" -} - - -# -# See if we can find CDE. -# -if test "${window_system}" != "none" -a \ - "${with_cde}" != "no" -a \ - "${with_cde}" != "yes" ; then - internal_cde_lib_found='no' - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lDtSvc" -ac_have_lib="" -test -n "$silent" || echo "checking for -lDtSvc" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; internal_cde_lib_found='yes' -else - :; -fi - - if test "${internal_cde_lib_found}" = "no" -a -f "/usr/dt/lib/libDtSvc.a"; then - internal_cde_lib_found="yes" - fi - if test "${internal_cde_lib_found}" = "yes" ; then - internal_cde_includes_found='no' - for arg in ${DEFS} /usr/include /usr/dt/include ; do - if test -f `echo "${arg}/Dt/Dt.h" | sed 's/^\-I//'` ; then - internal_cde_includes_found='yes' - fi - done - if test "${internal_cde_includes_found}" = "yes" ; then - with_cde='yes' - fi - fi -fi -test "${with_cde}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_CDE" -echo "#define" HAVE_CDE "1" >> confdefs.h -DEFS="$DEFS -DHAVE_CDE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_CDE\${ac_dB}HAVE_CDE\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_CDE\${ac_uB}HAVE_CDE\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_CDE\${ac_eB}HAVE_CDE\${ac_eC}1\${ac_eD} -" -} - - -# having CDE implies Tooltalk -if test "${with_cde}" = "yes" -a \ - "${with_tooltalk}" != "no" -a \ - "${with_tooltalk}" != "none" ; then - with_tooltalk='yes' -fi - -# having CDE requires Motif -if test "${with_cde}" = "yes" ; then - motif_libs="-lXm -lXt" -fi - -# -# See if we can find OffiX. -# -if test "${window_system}" != "none" -a \ - "${with_offix}" != "no" -a \ - "${with_offix}" != "yes" ; then - internal_offix_lib_found='no' - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lDnd" -ac_have_lib="" -test -n "$silent" || echo "checking for -lDnd" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; internal_offix_lib_found='yes' -else - :; -fi - - if test "${internal_offix_lib_found}" = "yes" ; then - internal_offix_includes_found='no' - for arg in ${DEFS} /usr/include ; do - if test -f `echo "${arg}/OffiX/DragAndDrop.h" | sed 's/^\-I//'` ; then - internal_offix_includes_found='yes' - fi - done - test "${internal_offix_includes_found}" = "yes" && with_offix='yes' - fi -fi -test "${with_offix}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_OFFIX_DND" -echo "#define" HAVE_OFFIX_DND "1" >> confdefs.h -DEFS="$DEFS -DHAVE_OFFIX_DND=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_OFFIX_DND\${ac_dB}HAVE_OFFIX_DND\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_OFFIX_DND\${ac_uB}HAVE_OFFIX_DND\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_OFFIX_DND\${ac_eB}HAVE_OFFIX_DND\${ac_eC}1\${ac_eD} -" -} - - -# X window options -if test "${window_system}" != "none" ; then - test -n "$silent" || echo "checking the version of X11 being used" -cat > conftest.${ac_ext} <<EOF -#include <X11/Intrinsic.h> -int main() { -#if (XlibSpecificationRelease == 4) - printf ("X11R4\n"); -#elif (XlibSpecificationRelease == 5) - printf ("X11R5\n"); -#elif (XlibSpecificationRelease == 6) - printf ("X11R6\n"); -#elif (XtSpecificationRelease == 4) - printf ("X11R4\n"); -#endif - return 0; -} -EOF -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} ${DEFS}" -if eval $ac_compile; then - case "`./conftest`" in - X11R4 ) -{ -test -n "$verbose" && \ -echo " defining THIS_IS_X11R4" -echo "#define" THIS_IS_X11R4 "1" >> confdefs.h -DEFS="$DEFS -DTHIS_IS_X11R4=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}THIS_IS_X11R4\${ac_dB}THIS_IS_X11R4\${ac_dC}1\${ac_dD} -\${ac_uA}THIS_IS_X11R4\${ac_uB}THIS_IS_X11R4\${ac_uC}1\${ac_uD} -\${ac_eA}THIS_IS_X11R4\${ac_eB}THIS_IS_X11R4\${ac_eC}1\${ac_eD} -" -} - ;; - X11R5 ) -{ -test -n "$verbose" && \ -echo " defining THIS_IS_X11R5" -echo "#define" THIS_IS_X11R5 "1" >> confdefs.h -DEFS="$DEFS -DTHIS_IS_X11R5=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}THIS_IS_X11R5\${ac_dB}THIS_IS_X11R5\${ac_dC}1\${ac_dD} -\${ac_uA}THIS_IS_X11R5\${ac_uB}THIS_IS_X11R5\${ac_uC}1\${ac_uD} -\${ac_eA}THIS_IS_X11R5\${ac_eB}THIS_IS_X11R5\${ac_eC}1\${ac_eD} -" -} - ;; - X11R6 ) -{ -test -n "$verbose" && \ -echo " defining THIS_IS_X11R6" -echo "#define" THIS_IS_X11R6 "1" >> confdefs.h -DEFS="$DEFS -DTHIS_IS_X11R6=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}THIS_IS_X11R6\${ac_dB}THIS_IS_X11R6\${ac_dC}1\${ac_dD} -\${ac_uA}THIS_IS_X11R6\${ac_uB}THIS_IS_X11R6\${ac_uC}1\${ac_uD} -\${ac_eA}THIS_IS_X11R6\${ac_eB}THIS_IS_X11R6\${ac_eC}1\${ac_eD} -" -} - ;; - esac -fi -LIBS=$ac_save_LIBS -rm -f conftest* - - for ac_hdr in X11/Xlocale.h -do -ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./' '[A-Z]__'` -test -n "$silent" || echo "checking for ${ac_hdr}" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <${ac_hdr}> -EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi + ac_safe=`echo "editorconn.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for editorconn.h""... $ac_c" 1>&6 +echo "configure:5146: checking for editorconn.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 5149 "configure" +#include "confdefs.h" +#include <editorconn.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:5154: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining ${ac_tr_hdr}" -echo "#define" ${ac_tr_hdr} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_hdr}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_hdr}\${ac_dB}${ac_tr_hdr}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_hdr}\${ac_uB}${ac_tr_hdr}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_hdr}\${ac_eB}${ac_tr_hdr}\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* -done - -fi - -# -# if Energize specified, make sure we can find its need libraries/headers -# -if test "${with_energize}" = "yes" ; then - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lenergize" -ac_have_lib="" -test -n "$silent" || echo "checking for -lenergize" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; energize_version='3.X' -else - :; -fi - - if test "${energize_version}" = "no" ; then - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lconn" -ac_have_lib="" -test -n "$silent" || echo "checking for -lconn" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; energize_version='2.X' -else - :; -fi - - if test "${energize_version}" = "no" ; then - echo "Unable to find Energize library." >&2 - exit 1 - fi - fi - - internal_eincludes_found='no' - for arg in ${DEFS} /usr/include - do - if test -f `echo "${arg}/editorconn.h" | sed 's/^\-I//'` ; then - internal_eincludes_found='yes' - fi - done - if test "${internal_eincludes_found}" = "no" ; then - echo "Unable to find Energize editorconn.h header file." >&2 - exit 1 - fi -fi - -# -# logb and frexp are found in -lm on most systems. -# -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lm" -ac_have_lib="" -test -n "$silent" || echo "checking for -lm" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - -{ -test -n "$verbose" && \ -echo " defining HAVE_LIBM" -echo "#define" HAVE_LIBM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LIBM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LIBM\${ac_dB}HAVE_LIBM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LIBM\${ac_uB}HAVE_LIBM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LIBM\${ac_eB}HAVE_LIBM\${ac_eC}1\${ac_eD} -" -} - - LIBS="${LIBS} -lm" -fi - - -# -# see if XPM is hanging around somewhere -# -test "${window_system}" != "none" -a \ - "${with_xpm}" != "no" -a \ - "${with_xpm}" != "yes" && { ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lXpm" -ac_have_lib="" -test -n "$silent" || echo "checking for -lXpm" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_xpm="yes" -else - :; + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +{ echo "configure: error: Unable to find Energize editorconn.h header file." 1>&2; exit 1; } +fi + + + test "$energize_version" = "2.X" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining ENERGIZE_2 +EOF +cat >> confdefs.h <<\EOF +#define ENERGIZE_2 1 +EOF +} + + test "$energize_version" = "3.X" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining ENERGIZE_3 +EOF +cat >> confdefs.h <<\EOF +#define ENERGIZE_3 1 +EOF +} + +fi + + +echo "checking for graphics libraries" 1>&6 +echo "configure:5196: checking for graphics libraries" >&5 +test -z "$with_gif" && with_gif=yes; +if test "$with_gif" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_GIF +EOF +cat >> confdefs.h <<\EOF +#define HAVE_GIF 1 +EOF +} + + extra_objs="$extra_objs dgif_lib.o gif_err.o gifalloc.o" +fi + +test -z "$with_xpm" && { ac_safe=`echo "X11/xpm.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/xpm.h""... $ac_c" 1>&6 +echo "configure:5212: checking for X11/xpm.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 5215 "configure" +#include "confdefs.h" +#include <X11/xpm.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:5220: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_xpm=no fi } - -test "${with_xpm}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_XPM" -echo "#define" HAVE_XPM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_XPM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_XPM\${ac_dB}HAVE_XPM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_XPM\${ac_uB}HAVE_XPM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_XPM\${ac_eB}HAVE_XPM\${ac_eC}1\${ac_eD} -" -} - - -# -# see if Xmu is hanging around somewhere -# -# FSF 19.31 has this: -#dnl If using toolkit, check whether libXmu.a exists. -#dnl tranle@intellicorp.com says libXmu.a can need XtMalloc in libXt.a to link. -# OLDLIBS="$LIBS" -# if test x$HAVE_X11XTR6 = xyes; then -# LIBS="-lXt -lSM -lICE $LIBS" -# else -# LIBS="-lXt $LIBS" -# fi -# A C_CHECK_LIB(Xmu, XmuConvertStandardSelection) -# LIBS="$OLDLIBS" - -if test "${window_system}" != "none" ; then - if test "${with_xmu}" != "no" ; then - test "${with_xmu}" != "yes" && { ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lXmu" -ac_have_lib="" -test -n "$silent" || echo "checking for -lXmu" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_xmu="yes" -else - :; -fi +test -z "$with_xpm" && { +echo $ac_n "checking for XpmReadFileToData in -lXpm""... $ac_c" 1>&6 +echo "configure:5243: checking for XpmReadFileToData in -lXpm" >&5 +ac_lib_var=`echo Xpm'_'XpmReadFileToData | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXpm " +cat > conftest.$ac_ext <<EOF +#line 5248 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XpmReadFileToData(); + +int main() { +XpmReadFileToData() +; return 0; } +EOF +if { (eval echo configure:5259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_xpm=no +fi + } - # On SunOS4 (and 5!) we must kludge harder to try to detect Xmu - # Upgrade to autoconf 2 and use ac_check_lib - mrb - if test "${with_xmu}" != "yes" ; then - # begin expansion of ac_have_library - ac_save_LIBS="${LIBS}" - LIBS="${LIBS} -lXmu -lXt -lXext -lX11 -lm" - if test ${machine} = sparc -a ${opsys} = linux; then - LIBS="${LIBS} -lICE -lSM" - fi - ac_have_lib="" - cat > conftest.${ac_ext} <<EOF -int main() { return 0; } -EOF - if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - fi - rm -f conftest* - LIBS="${ac_save_LIBS}" - test -n "${ac_have_lib}" && with_xmu="yes" - # end expansion of ac_have_library - fi - # Sparc/Linux test - fp - if test "${with_xmu}" != "yes" -a ${machine} = sparc -a ${opsys} = linux; then - # begin expansion of ac_have_library - ac_save_LIBS="${LIBS}" - LIBS="${LIBS} -lXmu -lXt -lXext -lX11 -lm -lICE -lSM" - ac_have_lib="" - cat > conftest.${ac_ext} <<EOF -int main() { return 0; } -EOF - if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - fi - rm -f conftest* - LIBS="${ac_save_LIBS}" - test -n "${ac_have_lib}" && with_xmu="yes" - # end expansion of ac_have_library - fi - # On UnixWare 2.1 we must kludge harder to try to detect Xmu - # Upgrade to autoconf 2 and use ac_check_lib - mrb - if test "${with_xmu}" != "yes" && test -f "/.UpgradeVer2.1" ; then - # begin expansion of ac_have_library - ac_save_LIBS="${LIBS}" - if test x$HAVE_XFREE386 = xyes; then - LIBS="-lXt -lSM -lICE ${LIBS}" - else - LIBS="${LIBS} -lXmu -lXt -lXext -lX11" - fi - ac_have_lib="" - cat > conftest.${ac_ext} <<EOF -int main() { return 0; } -EOF - if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - fi - rm -f conftest* - LIBS="${ac_save_LIBS}" - test -n "${ac_have_lib}" && with_xmu="yes" - # end expansion of ac_have_library - fi - fi -fi -test "${with_xmu}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_XMU" -echo "#define" HAVE_XMU "1" >> confdefs.h -DEFS="$DEFS -DHAVE_XMU=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_XMU\${ac_dB}HAVE_XMU\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_XMU\${ac_uB}HAVE_XMU\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_XMU\${ac_eB}HAVE_XMU\${ac_eC}1\${ac_eD} -" -} - - -# -# see if COMPFACE is hanging around somewhere -# -if test "${window_system}" != "none" -a \ - "${with_xface}" != "no" -a \ - "${with_xface}" != "yes" ; then - test -n "$silent" || echo "checking for compface.h" -cat > conftest.${ac_ext} <<EOF +test -z "$with_xpm" && with_xpm=yes +if test "$with_xpm" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_XPM +EOF +cat >> confdefs.h <<\EOF +#define HAVE_XPM 1 +EOF +} + + libs_x="-lXpm $libs_x" +fi + +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:5295: checking for compface.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 5298 "configure" #include "confdefs.h" #include <compface.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:5303: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - compface_incl="yes" - -else - rm -rf conftest* - with_xface="no" -fi -rm -f conftest* - - if test "${compface_incl}" = "yes" ; then - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lcompface" -ac_have_lib="" -test -n "$silent" || echo "checking for -lcompface" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_xface="yes" -else - :; -fi - - fi -fi -test "${with_xface}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_XFACE" -echo "#define" HAVE_XFACE "1" >> confdefs.h -DEFS="$DEFS -DHAVE_XFACE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_XFACE\${ac_dB}HAVE_XFACE\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_XFACE\${ac_uB}HAVE_XFACE\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_XFACE\${ac_eB}HAVE_XFACE\${ac_eC}1\${ac_eD} -" -} - - -# -# check whether we're using GIF support -# -if test "${window_system}" = "none" ; then - if test -z "${with_gif}" ; then - with_gif=no - elif test "${with_gif}" != "no" ; then - echo "GIF support cannot be specified without a window system." - exit 1 - fi -elif test -z "${with_gif}" ; then - with_gif=yes -fi -test "${with_gif}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_GIF" -echo "#define" HAVE_GIF "1" >> confdefs.h -DEFS="$DEFS -DHAVE_GIF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_GIF\${ac_dB}HAVE_GIF\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_GIF\${ac_uB}HAVE_GIF\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_GIF\${ac_eB}HAVE_GIF\${ac_eC}1\${ac_eD} -" -} - - -if test "${window_system}" = "none" ; then - if test -z "${with_jpeg}" ; then - with_jpeg=no - elif test "${with_jpeg}" != "no" ; then - echo "JPEG support cannot be specified without a window system." - exit 1 - fi -else - if test "${with_jpeg}" != "no" -a \ - "${with_jpeg}" != "yes" ; then - test -n "$silent" || echo "checking for jpeglib.h" -cat > conftest.${ac_ext} <<EOF + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_xface=no +fi + } +test -z "$with_xface" && { +echo $ac_n "checking for UnGenFace in -lcompface""... $ac_c" 1>&6 +echo "configure:5326: checking for UnGenFace in -lcompface" >&5 +ac_lib_var=`echo compface'_'UnGenFace | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lcompface " +cat > conftest.$ac_ext <<EOF +#line 5331 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char UnGenFace(); + +int main() { +UnGenFace() +; return 0; } +EOF +if { (eval echo configure:5342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_xface=no +fi + + } +test -z "$with_xface" && with_xface=yes +if test "$with_xface" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_XFACE +EOF +cat >> confdefs.h <<\EOF +#define HAVE_XFACE 1 +EOF +} + + libs_x="-lcompface $libs_x" +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:5378: checking for jpeglib.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 5381 "configure" #include "confdefs.h" #include <jpeglib.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:5386: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - jpeglib_incl="yes" - -else - rm -rf conftest* - with_jpeg="no" -fi -rm -f conftest* - - test "${jpeglib_incl}" = "yes" && { ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -ljpeg" -ac_have_lib="" -test -n "$silent" || echo "checking for -ljpeg" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_jpeg="yes" -else - :; + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_jpeg=no fi } - fi -fi -test "${with_jpeg}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_JPEG" -echo "#define" HAVE_JPEG "1" >> confdefs.h -DEFS="$DEFS -DHAVE_JPEG=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_JPEG\${ac_dB}HAVE_JPEG\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_JPEG\${ac_uB}HAVE_JPEG\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_JPEG\${ac_eB}HAVE_JPEG\${ac_eC}1\${ac_eD} -" -} - - -if test "${window_system}" = "none" ; then - if test -z "${with_png}" ; then - with_png=no - elif test "${with_png}" != "no" ; then - echo "PNG support cannot be specified without a window system." - exit 1 - fi -fi -test -z "${with_png}" && { test -n "$silent" || echo "checking for png.h" -cat > conftest.${ac_ext} <<EOF +test -z "$with_jpeg" && { +echo $ac_n "checking for jpeg_destroy_decompress in -ljpeg""... $ac_c" 1>&6 +echo "configure:5409: 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 <<EOF +#line 5414 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char jpeg_destroy_decompress(); + +int main() { +jpeg_destroy_decompress() +; return 0; } +EOF +if { (eval echo configure:5425: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_jpeg=no +fi + + } +test -z "$with_jpeg" && with_jpeg=yes +if test "$with_jpeg" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_JPEG +EOF +cat >> confdefs.h <<\EOF +#define HAVE_JPEG 1 +EOF +} + + libs_x="-ljpeg $libs_x" +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:5461: checking for png.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 5464 "configure" #include "confdefs.h" #include <png.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:5469: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 : else - rm -rf conftest* - with_png="no" -fi -rm -f conftest* + echo "$ac_t""no" 1>&6 +with_png=no +fi } -test -z "${with_png}" && { test -n "$silent" || echo "checking for pow" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { +test -z "$with_png" && { echo $ac_n "checking for pow""... $ac_c" 1>&6 +echo "configure:5491: checking for pow" >&5 + +cat > conftest.$ac_ext <<EOF +#line 5494 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char pow(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char pow(); + +int main() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined (__stub_pow) || defined (__stub___pow) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char pow(); pow(); +pow(); #endif + ; return 0; } EOF -if eval $ac_compile; then +if { (eval echo configure:5517: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_pow=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_pow=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'pow`\" = yes"; then + echo "$ac_t""yes" 1>&6 : else - rm -rf conftest* - with_png="no" -fi -rm -f conftest* - } -if test -z "${with_png}" ; then - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lz" -ac_have_lib="" -test -n "$silent" || echo "checking for -lz" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_png="yes" -else - :; -fi - - test -z "${with_png}" && { ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lgz" -ac_have_lib="" -test -n "$silent" || echo "checking for -lgz" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_png="gnuz" -else - :; with_png="no" + echo "$ac_t""no" 1>&6 +with_png=no fi } - if test "${with_png}" != "no"; then - png_save_libs="${LIBS}" - case "${with_png}" in - yes ) LIBS="${LIBS} -lz" ;; - gnuz ) LIBS="${LIBS} -lgz" ;; - esac - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lpng" -ac_have_lib="" -test -n "$silent" || echo "checking for -lpng" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; -else - :; with_png="no" -fi - - LIBS="$png_save_libs" - fi -fi -case "${with_png}" in - yes ) -{ -test -n "$verbose" && \ -echo " defining HAVE_PNG" -echo "#define" HAVE_PNG "1" >> confdefs.h -DEFS="$DEFS -DHAVE_PNG=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_PNG\${ac_dB}HAVE_PNG\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_PNG\${ac_uB}HAVE_PNG\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_PNG\${ac_eB}HAVE_PNG\${ac_eC}1\${ac_eD} -" -} - ;; - gnuz ) -{ -test -n "$verbose" && \ -echo " defining HAVE_PNG" -echo "#define" HAVE_PNG "1" >> confdefs.h -DEFS="$DEFS -DHAVE_PNG=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_PNG\${ac_dB}HAVE_PNG\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_PNG\${ac_uB}HAVE_PNG\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_PNG\${ac_eB}HAVE_PNG\${ac_eC}1\${ac_eD} -" -} - -{ -test -n "$verbose" && \ -echo " defining HAVE_PNG_GNUZ" -echo "#define" HAVE_PNG_GNUZ "1" >> confdefs.h -DEFS="$DEFS -DHAVE_PNG_GNUZ=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_PNG_GNUZ\${ac_dB}HAVE_PNG_GNUZ\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_PNG_GNUZ\${ac_uB}HAVE_PNG_GNUZ\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_PNG_GNUZ\${ac_eB}HAVE_PNG_GNUZ\${ac_eC}1\${ac_eD} -" -} - ;; +if test "$with_png" != "no"; then + for extra_libs in "" "-lz" "-lgz"; do + +xe_msg_checking="for png_read_image in -lpng" +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:5542: checking "$xe_msg_checking"" >&5 +ac_lib_var=`echo png'_'png_read_image | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lpng $extra_libs" +cat > conftest.$ac_ext <<EOF +#line 5547 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char png_read_image(); + +int main() { +png_read_image() +; return 0; } +EOF +if { (eval echo configure:5558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + png_libs="-lpng $extra_libs" with_png=yes; break +else + echo "$ac_t""no" 1>&6 +: +fi + + + done +fi +test -z "$with_png" && with_png=no +if test "$with_png" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_PNG +EOF +cat >> confdefs.h <<\EOF +#define HAVE_PNG 1 +EOF +} + + libs_x="$png_libs $libs_x" +fi + +if test "$with_tiff" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TIFF +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TIFF 1 +EOF +} + + libs_x="-ltiff $libs_x" +fi + + +case "$with_menubars" in "" | "yes" | "athena" ) + with_menubars="lucid" ;; +esac +case "$with_dialogs" in "" | "yes" | "lucid" ) + if test "$have_motif" = "yes"; then with_dialogs="motif" + elif test "$have_xaw" = "yes"; then with_dialogs="athena" + else with_dialogs=no + fi ;; +esac +case "$with_scrollbars" in "" | "yes" ) + with_scrollbars="lucid" ;; +esac + +all_widgets="$with_menubars $with_scrollbars $with_dialogs $with_toolbars" + +case "$all_widgets" in *athena* ) + { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_USES_ATHENA +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_USES_ATHENA 1 +EOF +} + + libs_x="-lXaw $libs_x" ;; +esac + +case "$all_widgets" in *motif* ) + { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_USES_MOTIF +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_USES_MOTIF 1 +EOF +} + + need_motif=yes ;; esac -test "${with_tiff}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_TIFF" -echo "#define" HAVE_TIFF "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TIFF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TIFF\${ac_dB}HAVE_TIFF\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TIFF\${ac_uB}HAVE_TIFF\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TIFF\${ac_eB}HAVE_TIFF\${ac_eC}1\${ac_eD} -" -} - - -# We use Lucid toolkit defaults for the menubars and scrollbars, but -# if Motif is available we use it for the dialog boxes. -if test "${window_system}" != "none" ; then - save_libs="${LIBS}" - if test "x${with_dialogs}" = "x" ; then - # We can't use ac_have_library because it simply appends -lXm to the - # end of the link line which is insufficient since -lXm will generate - # dependencies on -lXt -# begin expansion of ac_have_library -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lXm -lXt ${LIBS}" -ac_have_lib="" -test -n "$silent" || echo "checking for -lXm" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_dialogs="motif" motif_libs="-lXm -lXt" -else - :; -fi -# end expansion of ac_have_library - # Sigh. My Motif (MoTeeth) under Linux also depends on Xpm and Xext. - if test "${with_dialogs}" != "motif" ; then -# begin expansion of ac_have_library -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lXm -lXt -lXpm -lXext ${LIBS}" -ac_have_lib="" -test -n "$silent" || echo "checking for -lXm in another way" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_dialogs="motif" motif_libs="-lXm -lXt -lXpm -lXext" -else - :; -fi -# end expansion of ac_have_library - fi - test "${with_dialogs}" = "motif" && test -n "$verbose" && echo " Found Motif" +case "$with_scrollbars" in athena* ) { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_SCROLLBARS_ATHENA +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_SCROLLBARS_ATHENA 1 +EOF +} +;; esac +case "$with_dialogs" in athena* ) { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_DIALOGS_ATHENA +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_DIALOGS_ATHENA 1 +EOF +} + ;; esac +test "$with_scrollbars" = "athena3d" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_SCROLLBARS_ATHENA3D +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_SCROLLBARS_ATHENA3D 1 +EOF +} + +test "$with_dialogs" = "athena3d" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_DIALOGS_ATHENA3D +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_DIALOGS_ATHENA3D 1 +EOF +} + + +test "$with_menubars" != "no" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_MENUBARS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_MENUBARS 1 +EOF +} + +test "$with_scrollbars" != "no" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_SCROLLBARS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_SCROLLBARS 1 +EOF +} + +test "$with_dialogs" != "no" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_DIALOGS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_DIALOGS 1 +EOF +} + +test "$with_toolbars" != "no" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TOOLBARS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TOOLBARS 1 +EOF +} + + +test "$with_menubars" = "lucid" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_MENUBARS_LUCID +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_MENUBARS_LUCID 1 +EOF +} + +test "$with_scrollbars" = "lucid" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_SCROLLBARS_LUCID +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_SCROLLBARS_LUCID 1 +EOF +} + + +test "$with_menubars" = "motif" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_MENUBARS_MOTIF +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_MENUBARS_MOTIF 1 +EOF +} + +test "$with_scrollbars" = "motif" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_SCROLLBARS_MOTIF +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_SCROLLBARS_MOTIF 1 +EOF +} + +test "$with_dialogs" = "motif" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_DIALOGS_MOTIF +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_DIALOGS_MOTIF 1 +EOF +} + + +test "$with_menubars" != "no" && extra_objs="$extra_objs menubar.o" +test "$with_scrollbars" != "no" && extra_objs="$extra_objs scrollbar.o" +test "$with_dialogs" != "no" && extra_objs="$extra_objs dialog.o" +test "$with_toolbars" != "no" && extra_objs="$extra_objs toolbar.o" +test "$all_widgets" != "no no no no" && extra_objs="$extra_objs gui.o" + +if test "$with_x11" = "yes"; then + test "$with_menubars" != "no" && extra_objs="$extra_objs menubar-x.o" + test "$with_scrollbars" != "no" && extra_objs="$extra_objs scrollbar-x.o" + test "$with_dialogs" != "no" && extra_objs="$extra_objs dialog-x.o" + test "$with_toolbars" != "no" && extra_objs="$extra_objs toolbar-x.o" + test "$all_widgets" != "no no no no" && extra_objs="$extra_objs gui-x.o" +fi + + +test -z "$with_mule" && with_mule=no + +if test "$with_mule" = "yes" ; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining MULE +EOF +cat >> confdefs.h <<\EOF +#define MULE 1 +EOF +} + + extra_objs="$extra_objs mule.o mule-ccl.o mule-charset.o mule-coding.o" + + +echo $ac_n "checking for strerror in -lintl""... $ac_c" 1>&6 +echo "configure:5784: checking for strerror in -lintl" >&5 +ac_lib_var=`echo intl'_'strerror | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lintl " +cat > conftest.$ac_ext <<EOF +#line 5789 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char strerror(); + +int main() { +strerror() +; return 0; } +EOF +if { (eval echo configure:5800: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_tr_lib=HAVE_LIB`echo intl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_lib +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_lib 1 +EOF +} + + LIBS="-lintl $LIBS" + +else + echo "$ac_t""no" 1>&6 +fi + + + + echo "checking for Mule input methods" 1>&6 +echo "configure:5833: checking for Mule input methods" >&5 + case "$with_xim" in "" | "yes" ) + echo "checking for XIM" 1>&6 +echo "configure:5836: checking for XIM" >&5 + +echo $ac_n "checking for XmImMbLookupString in -lXm""... $ac_c" 1>&6 +echo "configure:5839: checking for XmImMbLookupString in -lXm" >&5 +ac_lib_var=`echo Xm'_'XmImMbLookupString | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lXm " +cat > conftest.$ac_ext <<EOF +#line 5844 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char XmImMbLookupString(); + +int main() { +XmImMbLookupString() +; return 0; } +EOF +if { (eval echo configure:5855: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_xim=motif +else + echo "$ac_t""no" 1>&6 +with_xim=xlib +fi + + + esac + if test "$with_xim" != "no" ; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_XIM +EOF +cat >> confdefs.h <<\EOF +#define HAVE_XIM 1 +EOF +} + + if test "$with_xim" = "xlib"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining XIM_XLIB +EOF +cat >> confdefs.h <<\EOF +#define XIM_XLIB 1 +EOF +} + + extra_objs="$extra_objs input-method-xlib.o" fi -fi - -# Finish ensuring that we have values for the various toolkit items. - -test "${with_menubars}" = "motif" -o \ - "${with_scrollbars}" = "motif" -o \ - "${with_dialogs}" = "motif" && with_motif="yes" -test "${with_menubars}" = "athena" -o \ - "${with_scrollbars}" = "athena" -o \ - "${with_dialogs}" = "athena" && with_athena="yes" -test "${with_menubars}" = "athena3d" -o \ - "${with_scrollbars}" = "athena3d" -o \ - "${with_dialogs}" = "athena3d" && with_athena="yes" -test "${with_menubars}" = "" && with_menubars="lucid" -test "${with_menubars}" = "athena" && with_menubars="lucid" -test "${with_scrollbars}" = "" && with_scrollbars="lucid" -test "${with_dialogs}" = "" && with_dialogs="athena" -test "${with_dialogs}" = "lucid" && with_dialogs="athena" - -test "${with_menubars}" != "no" && -{ -test -n "$verbose" && \ -echo " defining HAVE_MENUBARS" -echo "#define" HAVE_MENUBARS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_MENUBARS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_MENUBARS\${ac_dB}HAVE_MENUBARS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_MENUBARS\${ac_uB}HAVE_MENUBARS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_MENUBARS\${ac_eB}HAVE_MENUBARS\${ac_eC}1\${ac_eD} -" -} - -test "${with_scrollbars}" != "no" && -{ -test -n "$verbose" && \ -echo " defining HAVE_SCROLLBARS" -echo "#define" HAVE_SCROLLBARS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_SCROLLBARS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_SCROLLBARS\${ac_dB}HAVE_SCROLLBARS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_SCROLLBARS\${ac_uB}HAVE_SCROLLBARS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_SCROLLBARS\${ac_eB}HAVE_SCROLLBARS\${ac_eC}1\${ac_eD} -" -} - -test "${with_dialogs}" != "no" && -{ -test -n "$verbose" && \ -echo " defining HAVE_DIALOGS" -echo "#define" HAVE_DIALOGS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_DIALOGS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_DIALOGS\${ac_dB}HAVE_DIALOGS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_DIALOGS\${ac_uB}HAVE_DIALOGS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_DIALOGS\${ac_eB}HAVE_DIALOGS\${ac_eC}1\${ac_eD} -" -} - - -test "${with_menubars}" = "lucid" && -{ -test -n "$verbose" && \ -echo " defining LWLIB_MENUBARS_LUCID" -echo "#define" LWLIB_MENUBARS_LUCID "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_MENUBARS_LUCID=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_MENUBARS_LUCID\${ac_dB}LWLIB_MENUBARS_LUCID\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_MENUBARS_LUCID\${ac_uB}LWLIB_MENUBARS_LUCID\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_MENUBARS_LUCID\${ac_eB}LWLIB_MENUBARS_LUCID\${ac_eC}1\${ac_eD} -" -} - -test "${with_menubars}" = "motif" && -{ -test -n "$verbose" && \ -echo " defining LWLIB_MENUBARS_MOTIF" -echo "#define" LWLIB_MENUBARS_MOTIF "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_MENUBARS_MOTIF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_MENUBARS_MOTIF\${ac_dB}LWLIB_MENUBARS_MOTIF\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_MENUBARS_MOTIF\${ac_uB}LWLIB_MENUBARS_MOTIF\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_MENUBARS_MOTIF\${ac_eB}LWLIB_MENUBARS_MOTIF\${ac_eC}1\${ac_eD} -" -} - -test "${with_scrollbars}" = "lucid" && -{ -test -n "$verbose" && \ -echo " defining LWLIB_SCROLLBARS_LUCID" -echo "#define" LWLIB_SCROLLBARS_LUCID "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_SCROLLBARS_LUCID=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_SCROLLBARS_LUCID\${ac_dB}LWLIB_SCROLLBARS_LUCID\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_SCROLLBARS_LUCID\${ac_uB}LWLIB_SCROLLBARS_LUCID\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_SCROLLBARS_LUCID\${ac_eB}LWLIB_SCROLLBARS_LUCID\${ac_eC}1\${ac_eD} -" -} - -test "${with_scrollbars}" = "motif" && -{ -test -n "$verbose" && \ -echo " defining LWLIB_SCROLLBARS_MOTIF" -echo "#define" LWLIB_SCROLLBARS_MOTIF "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_SCROLLBARS_MOTIF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_SCROLLBARS_MOTIF\${ac_dB}LWLIB_SCROLLBARS_MOTIF\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_SCROLLBARS_MOTIF\${ac_uB}LWLIB_SCROLLBARS_MOTIF\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_SCROLLBARS_MOTIF\${ac_eB}LWLIB_SCROLLBARS_MOTIF\${ac_eC}1\${ac_eD} -" -} - -test "${with_scrollbars}" = "athena" && -{ -test -n "$verbose" && \ -echo " defining LWLIB_SCROLLBARS_ATHENA" -echo "#define" LWLIB_SCROLLBARS_ATHENA "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_SCROLLBARS_ATHENA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_SCROLLBARS_ATHENA\${ac_dB}LWLIB_SCROLLBARS_ATHENA\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_SCROLLBARS_ATHENA\${ac_uB}LWLIB_SCROLLBARS_ATHENA\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_SCROLLBARS_ATHENA\${ac_eB}LWLIB_SCROLLBARS_ATHENA\${ac_eC}1\${ac_eD} -" -} - -if test "${with_scrollbars}" = "athena3d"; then - -{ -test -n "$verbose" && \ -echo " defining LWLIB_SCROLLBARS_ATHENA" -echo "#define" LWLIB_SCROLLBARS_ATHENA "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_SCROLLBARS_ATHENA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_SCROLLBARS_ATHENA\${ac_dB}LWLIB_SCROLLBARS_ATHENA\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_SCROLLBARS_ATHENA\${ac_uB}LWLIB_SCROLLBARS_ATHENA\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_SCROLLBARS_ATHENA\${ac_eB}LWLIB_SCROLLBARS_ATHENA\${ac_eC}1\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining LWLIB_SCROLLBARS_ATHENA3D" -echo "#define" LWLIB_SCROLLBARS_ATHENA3D "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_SCROLLBARS_ATHENA3D=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_SCROLLBARS_ATHENA3D\${ac_dB}LWLIB_SCROLLBARS_ATHENA3D\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_SCROLLBARS_ATHENA3D\${ac_uB}LWLIB_SCROLLBARS_ATHENA3D\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_SCROLLBARS_ATHENA3D\${ac_eB}LWLIB_SCROLLBARS_ATHENA3D\${ac_eC}1\${ac_eD} -" -} - -fi -test "${with_dialogs}" = "motif" && -{ -test -n "$verbose" && \ -echo " defining LWLIB_DIALOGS_MOTIF" -echo "#define" LWLIB_DIALOGS_MOTIF "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_DIALOGS_MOTIF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_DIALOGS_MOTIF\${ac_dB}LWLIB_DIALOGS_MOTIF\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_DIALOGS_MOTIF\${ac_uB}LWLIB_DIALOGS_MOTIF\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_DIALOGS_MOTIF\${ac_eB}LWLIB_DIALOGS_MOTIF\${ac_eC}1\${ac_eD} -" -} - -test "${with_dialogs}" = "athena" && -{ -test -n "$verbose" && \ -echo " defining LWLIB_DIALOGS_ATHENA" -echo "#define" LWLIB_DIALOGS_ATHENA "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_DIALOGS_ATHENA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_DIALOGS_ATHENA\${ac_dB}LWLIB_DIALOGS_ATHENA\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_DIALOGS_ATHENA\${ac_uB}LWLIB_DIALOGS_ATHENA\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_DIALOGS_ATHENA\${ac_eB}LWLIB_DIALOGS_ATHENA\${ac_eC}1\${ac_eD} -" -} - -if test "${with_dialogs}" = "athena3d"; then - -{ -test -n "$verbose" && \ -echo " defining LWLIB_DIALOGS_ATHENA" -echo "#define" LWLIB_DIALOGS_ATHENA "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_DIALOGS_ATHENA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_DIALOGS_ATHENA\${ac_dB}LWLIB_DIALOGS_ATHENA\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_DIALOGS_ATHENA\${ac_uB}LWLIB_DIALOGS_ATHENA\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_DIALOGS_ATHENA\${ac_eB}LWLIB_DIALOGS_ATHENA\${ac_eC}1\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining LWLIB_DIALOGS_ATHENA3D" -echo "#define" LWLIB_DIALOGS_ATHENA3D "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_DIALOGS_ATHENA3D=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_DIALOGS_ATHENA3D\${ac_dB}LWLIB_DIALOGS_ATHENA3D\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_DIALOGS_ATHENA3D\${ac_uB}LWLIB_DIALOGS_ATHENA3D\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_DIALOGS_ATHENA3D\${ac_eB}LWLIB_DIALOGS_ATHENA3D\${ac_eC}1\${ac_eD} -" -} - -fi - -############################################################################ -# # -# Misc other feature tests # -# # -############################################################################ - -# Mule-dependent option processing -if test "$with_mule" = "yes" ; then - # Do we have the XmIm* routines? And if so, do we want to use them? - test "$with_xim" != no && test -n "$silent" || echo "checking for XIM" - if test -z "$with_xim" -o "$with_xim" = "yes" ; then - xim_save_libs="$LIBS" - LIBS="${motif_libs} ${LIBS}" - test -n "$silent" || echo "checking for XmImMbLookupString" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { + if test "$with_xim" = "motif"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining XIM_MOTIF +EOF +cat >> confdefs.h <<\EOF +#define XIM_MOTIF 1 +EOF +} + + need_motif=yes + extra_objs="$extra_objs input-method-motif.o" + fi + fi + + test "$with_wnn6" = "yes" && with_wnn=yes # wnn6 implies wnn support + test -z "$with_wnn" && { ac_safe=`echo "wnn/wnnerror.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for wnn/wnnerror.h""... $ac_c" 1>&6 +echo "configure:5914: checking for wnn/wnnerror.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 5917 "configure" +#include "confdefs.h" +#include <wnn/wnnerror.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:5922: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_wnn=no +fi + } + test -z "$with_wnn" && { +echo $ac_n "checking for jl_dic_list in -lwnn""... $ac_c" 1>&6 +echo "configure:5945: checking for jl_dic_list in -lwnn" >&5 +ac_lib_var=`echo wnn'_'jl_dic_list | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lwnn " +cat > conftest.$ac_ext <<EOF +#line 5950 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char jl_dic_list(); + +int main() { +jl_dic_list() +; return 0; } +EOF +if { (eval echo configure:5961: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_wnn=no +fi + + } + test -z "$with_wnn" && with_wnn=yes + if test "$with_wnn" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_WNN +EOF +cat >> confdefs.h <<\EOF +#define HAVE_WNN 1 +EOF +} + + libs_x="-lwnn $libs_x" + extra_objs="$extra_objs mule-wnnfns.o" + +echo $ac_n "checking for jl_fi_dic_list in -lwnn""... $ac_c" 1>&6 +echo "configure:5996: checking for jl_fi_dic_list in -lwnn" >&5 +ac_lib_var=`echo wnn'_'jl_fi_dic_list | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lwnn " +cat > conftest.$ac_ext <<EOF +#line 6001 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char jl_fi_dic_list(); + +int main() { +jl_fi_dic_list() +; return 0; } +EOF +if { (eval echo configure:6012: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_wnn6=yes +else + echo "$ac_t""no" 1>&6 +fi + + + test "$with_wnn6" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_WNN6 +EOF +cat >> confdefs.h <<\EOF +#define HAVE_WNN6 1 +EOF +} + + 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:6044: checking for canna/RK.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6047 "configure" +#include "confdefs.h" +#include <canna/RK.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:6052: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_canna=no +fi + } + test -z "$with_canna" && { +echo $ac_n "checking for RkBgnBun in -lRKC""... $ac_c" 1>&6 +echo "configure:6075: checking for RkBgnBun in -lRKC" >&5 +ac_lib_var=`echo RKC'_'RkBgnBun | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lRKC " +cat > conftest.$ac_ext <<EOF +#line 6080 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char RkBgnBun(); + +int main() { +RkBgnBun() +; return 0; } +EOF +if { (eval echo configure:6091: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_canna=no +fi + + } + test -z "$with_canna" && { +echo $ac_n "checking for jrKanjiControl in -lcanna""... $ac_c" 1>&6 +echo "configure:6114: checking for jrKanjiControl in -lcanna" >&5 +ac_lib_var=`echo canna'_'jrKanjiControl | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lcanna " +cat > conftest.$ac_ext <<EOF +#line 6119 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char jrKanjiControl(); + +int main() { +jrKanjiControl() +; return 0; } +EOF +if { (eval echo configure:6130: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + : +else + echo "$ac_t""no" 1>&6 +with_canna=no +fi + + } + test -z "$with_canna" && with_canna=yes + if test "$with_canna" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_CANNA +EOF +cat >> confdefs.h <<\EOF +#define HAVE_CANNA 1 +EOF +} + + libs_x="-lcanna -lRKC $libs_x" + extra_objs="$extra_objs mule-canna.o" + fi +else # "$with_mule" = "no" + for feature in xim canna wnn; do + if eval "test -n \"\$with_${feature}\" -a \"\$with_${feature}\" != no" ; then + echo "configure: warning: "--with-${feature} ignored: Not valid without Mule support"" 1>&2 + fi + eval "with_${feature}=no" + done +fi + + +test "$need_motif" = "yes" && libs_x="-lXm $libs_x" + +for ac_func in acosh asinh atanh cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random realpath rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask strcasecmp strerror tzset utimes waitpid +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:6179: checking for $ac_func" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6182 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ -#if defined (__stub_XmImMbLookupString) || defined (__stub___XmImMbLookupString) +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char XmImMbLookupString(); XmImMbLookupString(); +$ac_func(); #endif + ; return 0; } EOF -if eval $ac_compile; then - rm -rf conftest* - have_XmIm=yes - -else - rm -rf conftest* - have_XmIm=no -fi -rm -f conftest* - - LIBS="$xim_save_libs" - if test "$with_xim" = "yes" -a "$have_XmIm" = "yes"; then with_xim=motif - elif test "$with_xim" = "yes"; then with_xim=xlib - else with_xim=no - fi - fi - if test "$with_xim" != "no" ; then - -{ -test -n "$verbose" && \ -echo " defining HAVE_XIM" -echo "#define" HAVE_XIM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_XIM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_XIM\${ac_dB}HAVE_XIM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_XIM\${ac_uB}HAVE_XIM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_XIM\${ac_eB}HAVE_XIM\${ac_eC}1\${ac_eD} -" -} - - test "$with_xim" = "xlib" && -{ -test -n "$verbose" && \ -echo " defining XIM_XLIB" -echo "#define" XIM_XLIB "1" >> confdefs.h -DEFS="$DEFS -DXIM_XLIB=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}XIM_XLIB\${ac_dB}XIM_XLIB\${ac_dC}1\${ac_dD} -\${ac_uA}XIM_XLIB\${ac_uB}XIM_XLIB\${ac_uC}1\${ac_uD} -\${ac_eA}XIM_XLIB\${ac_eB}XIM_XLIB\${ac_eC}1\${ac_eD} -" -} - - test "$with_xim" = "motif" && -{ -test -n "$verbose" && \ -echo " defining XIM_MOTIF" -echo "#define" XIM_MOTIF "1" >> confdefs.h -DEFS="$DEFS -DXIM_MOTIF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}XIM_MOTIF\${ac_dB}XIM_MOTIF\${ac_dC}1\${ac_dD} -\${ac_uA}XIM_MOTIF\${ac_uB}XIM_MOTIF\${ac_uC}1\${ac_uD} -\${ac_eA}XIM_MOTIF\${ac_eB}XIM_MOTIF\${ac_eC}1\${ac_eD} -" -} - - fi - # wnn6 implies wnn support - if test "$with_wnn6" = "yes" ; then - with_wnn=yes - fi -else # Other internationalization features depend on Mule - with_mule="no" - for feature in xim canna wnn wnn6 ; do - if eval "test -n \"\$with_$feature\" -a \"\$with_$feature\" != no" ; then - echo "configure: warning: --with-$feature ignored: Not valid without Mule support" >&2 - fi - eval "with_$feature=no" - done -fi - -# -# set defaults for finding WNN includes and libs -# -if test "${with_wnn}" = "yes" ; then - for arg in "-I${wnn_includes}" "-I/usr/X11R6/include/wnn" "-I/usr/include/wnn" - do - if test -f `echo "${arg}/wnnerror.h" | sed 's/^\-I//'` ; then - C_SWITCH_SITE="${C_SWITCH_SITE} ${arg}" - wnn_includes=${arg} - break - fi - done - for arg in "-L${wnn_libraries}" "-L/usr/X11R6/lib" "-L/usr/lib" - do - if test -f `echo "${arg}/libwnn.a" | sed 's/^\-L//'` ; then - LD_SWITCH_SITE="${LD_SWITCH_SITE} ${arg}" - wnn_libraries=${arg} - break - fi - done -fi - -# -# set defaults for finding Canna includes and libs -# -if test "${with_canna}" = "yes" ; then - for arg in "-I${canna_includes}" "-I/usr/X11R6/include" - do - if test -f `echo "${arg}/canna/RK.h" | sed 's/^\-I//'` ; then - C_SWITCH_SITE="${C_SWITCH_SITE} ${arg}" - canna_includes=${arg} - break - fi - done - for arg in "-L${canna_libraries}" "-L/usr/X11R6/lib" - do - if test -f `echo "${arg}/libcanna.a" | sed 's/^\-L//'` ; then - LD_SWITCH_SITE="${LD_SWITCH_SITE} ${arg}" - canna_libraries=${arg} - break - fi - done -fi - -# If netdb.h doesn't declare h_errno, we must declare it by hand. -test -n "$silent" || echo "checking for declaration of h_errno in netdb.h" -cat > conftest.${ac_ext} <<EOF +if { (eval echo configure:6205: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_func +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_func 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi +done + + +test "$ac_cv_func_realpath" = "yes" && extra_objs="$extra_objs realpath.o" + +echo $ac_n "checking whether netdb declares h_errno""... $ac_c" 1>&6 +echo "configure:6236: checking whether netdb declares h_errno" >&5 +cat > conftest.$ac_ext <<EOF +#line 6238 "configure" #include "confdefs.h" #include <netdb.h> -int main() { return 0; } -int t() { int i = h_errno;; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_H_ERRNO" -echo "#define" HAVE_H_ERRNO "1" >> confdefs.h -DEFS="$DEFS -DHAVE_H_ERRNO=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_H_ERRNO\${ac_dB}HAVE_H_ERRNO\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_H_ERRNO\${ac_uB}HAVE_H_ERRNO\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_H_ERRNO\${ac_eB}HAVE_H_ERRNO\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - - -test -n "$silent" || echo "checking for sigsetjmp" -cat > conftest.${ac_ext} <<EOF +int main() { +return h_errno; +; return 0; } +EOF +if { (eval echo configure:6245: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_H_ERRNO +EOF +cat >> confdefs.h <<\EOF +#define HAVE_H_ERRNO 1 +EOF +} + +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + echo "$ac_t""no" 1>&6 +fi +rm -f conftest* + +echo $ac_n "checking for sigsetjmp""... $ac_c" 1>&6 +echo "configure:6265: checking for sigsetjmp" >&5 +cat > conftest.$ac_ext <<EOF +#line 6267 "configure" #include "confdefs.h" #include <setjmp.h> -int main() { return 0; } -int t() { sigjmp_buf bar; sigsetjmp (bar, 0);; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_SIGSETJMP" -echo "#define" HAVE_SIGSETJMP "1" >> confdefs.h -DEFS="$DEFS -DHAVE_SIGSETJMP=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_SIGSETJMP\${ac_dB}HAVE_SIGSETJMP\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_SIGSETJMP\${ac_uB}HAVE_SIGSETJMP\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_SIGSETJMP\${ac_eB}HAVE_SIGSETJMP\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - - -test -n "$silent" || echo "checking whether localtime caches TZ" -emacs_cv_localtime_cache= -test -n "$silent" || echo "checking whether cross-compiling" -# If we cannot run a trivial program, we must be cross compiling. -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -main(){exit(0);} -EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - : -else - cross_compiling=1 -fi -rm -fr conftest* - -if test -n "$cross_compiling" -then - # If we have tzset, assume the worst when cross-compiling. -emacs_cv_localtime_cache=yes -else -cat > conftest.${ac_ext} <<EOF +int main() { +sigjmp_buf bar; sigsetjmp (bar, 0); +; return 0; } +EOF +if { (eval echo configure:6274: \"$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 + Defining HAVE_SIGSETJMP +EOF +cat >> confdefs.h <<\EOF +#define HAVE_SIGSETJMP 1 +EOF +} + +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + echo "$ac_t""no" 1>&6 +fi +rm -f conftest* + +echo $ac_n "checking whether localtime caches TZ""... $ac_c" 1>&6 +echo "configure:6294: checking whether localtime caches TZ" >&5 + +if test "$ac_cv_func_tzset" = "yes"; then +cat > conftest.$ac_ext <<EOF +#line 6298 "configure" #include "confdefs.h" #include <time.h> -#if 1 /* STDC_HEADERS */ +#if STDC_HEADERS # include <stdlib.h> #endif extern char **environ; @@ -4709,16 +6308,18 @@ if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '=')) to++; } +char TZ_GMT0[] = "TZ=GMT0"; +char TZ_PST8[] = "TZ=PST8"; main() { time_t now = time ((time_t *) 0); int hour_GMT0, hour_unset; - if (putenv ("TZ=GMT0") != 0) + if (putenv (TZ_GMT0) != 0) exit (1); hour_GMT0 = localtime (&now)->tm_hour; unset_TZ (); hour_unset = localtime (&now)->tm_hour; - if (putenv ("TZ=PST8") != 0) + if (putenv (TZ_PST8) != 0) exit (1); if (localtime (&now)->tm_hour == hour_GMT0) exit (1); @@ -4728,34 +6329,38 @@ exit (0); } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then +if { (eval echo configure:6333: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then emacs_cv_localtime_cache=no - -else +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* emacs_cv_localtime_cache=yes fi -fi rm -fr conftest* -test -n "$verbose" && echo " "$emacs_cv_localtime_cache"" -if test x$emacs_cv_localtime_cache = xyes; then - -{ -test -n "$verbose" && \ -echo " defining LOCALTIME_CACHE" -echo "#define" LOCALTIME_CACHE "1" >> confdefs.h -DEFS="$DEFS -DLOCALTIME_CACHE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LOCALTIME_CACHE\${ac_dB}LOCALTIME_CACHE\${ac_dC}1\${ac_dD} -\${ac_uA}LOCALTIME_CACHE\${ac_uB}LOCALTIME_CACHE\${ac_uC}1\${ac_uD} -\${ac_eA}LOCALTIME_CACHE\${ac_eB}LOCALTIME_CACHE\${ac_eC}1\${ac_eD} -" -} - -fi - -if test "x$HAVE_TIMEVAL" = xyes; then -test -n "$silent" || echo "checking for whether gettimeofday can't accept two arguments" -cat > conftest.${ac_ext} <<EOF +else + # If we lack tzset, report that localtime does not cache TZ, + # since we can't invalidate the cache if we don't have tzset. + emacs_cv_localtime_cache=no +fi +echo "$ac_t""$emacs_cv_localtime_cache" 1>&6 +if test $emacs_cv_localtime_cache = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining LOCALTIME_CACHE +EOF +cat >> confdefs.h <<\EOF +#define LOCALTIME_CACHE 1 +EOF +} + +fi + +if test "$HAVE_TIMEVAL" = "yes"; then +echo $ac_n "checking whether gettimeofday cannot accept two arguments""... $ac_c" 1>&6 +echo "configure:6362: checking whether gettimeofday cannot accept two arguments" >&5 +cat > conftest.$ac_ext <<EOF +#line 6364 "configure" #include "confdefs.h" #ifdef TIME_WITH_SYS_TIME @@ -4769,301 +6374,279 @@ #endif #endif -int main() { return 0; } -int t() { +int main() { + struct timeval time; struct timezone dummy; gettimeofday (&time, &dummy); + ; return 0; } EOF -if eval $ac_compile; then - rm -rf conftest* - test -n "$verbose" && echo " no" - -else - rm -rf conftest* - test -n "$verbose" && echo " yes" - -{ -test -n "$verbose" && \ -echo " defining GETTIMEOFDAY_ONE_ARGUMENT" -echo "#define" GETTIMEOFDAY_ONE_ARGUMENT "1" >> confdefs.h -DEFS="$DEFS -DGETTIMEOFDAY_ONE_ARGUMENT=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}GETTIMEOFDAY_ONE_ARGUMENT\${ac_dB}GETTIMEOFDAY_ONE_ARGUMENT\${ac_dC}1\${ac_dD} -\${ac_uA}GETTIMEOFDAY_ONE_ARGUMENT\${ac_uB}GETTIMEOFDAY_ONE_ARGUMENT\${ac_uC}1\${ac_uD} -\${ac_eA}GETTIMEOFDAY_ONE_ARGUMENT\${ac_eB}GETTIMEOFDAY_ONE_ARGUMENT\${ac_eC}1\${ac_eD} -" -} - -fi -rm -f conftest* - -fi - -test -n "$silent" || echo "checking for whether inline functions are supported" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { -inline int -foo () -{ - return 0; -} +if { (eval echo configure:6386: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + echo "$ac_t""no" 1>&6 +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining GETTIMEOFDAY_ONE_ARGUMENT +EOF +cat >> confdefs.h <<\EOF +#define GETTIMEOFDAY_ONE_ARGUMENT 1 +EOF +} + +fi +rm -f conftest* +fi + + +echo $ac_n "checking for inline""... $ac_c" 1>&6 +echo "configure:6408: checking for inline" >&5 + +ac_cv_c_inline=no +for ac_kw in inline __inline__ __inline; do + cat > conftest.$ac_ext <<EOF +#line 6413 "configure" +#include "confdefs.h" + +int main() { +} $ac_kw foo() { ; return 0; } EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_INLINE" -echo "#define" HAVE_INLINE "1" >> confdefs.h -DEFS="$DEFS -DHAVE_INLINE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_INLINE\${ac_dB}HAVE_INLINE\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_INLINE\${ac_uB}HAVE_INLINE\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_INLINE\${ac_eB}HAVE_INLINE\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - - -# This does all sorts of magic to make sure alloca() works OK. -# It might even add some junk to the top of <config.h>. -# (I don't understand what goes on here, but it seems to work.) +if { (eval echo configure:6420: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_c_inline=$ac_kw; break +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 +fi +rm -f conftest* +done + + +echo "$ac_t""$ac_cv_c_inline" 1>&6 +case "$ac_cv_c_inline" in + inline | yes) ;; + no) { test "$extra_verbose" = "yes" && cat << \EOF + Defining inline = +EOF +cat >> confdefs.h <<\EOF +#define inline +EOF +} + ;; + *) { test "$extra_verbose" = "yes" && cat << EOF + Defining inline = $ac_cv_c_inline +EOF +cat >> confdefs.h <<EOF +#define inline $ac_cv_c_inline +EOF +} + ;; +esac + +test "$ac_cv_c_inline" != "no" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_INLINE +EOF +cat >> confdefs.h <<\EOF +#define HAVE_INLINE 1 +EOF +} + + + # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! -test -n "$silent" || echo "checking for working alloca.h" -cat > conftest.${ac_ext} <<EOF +echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 +echo "configure:6465: checking for working alloca.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6468 "configure" #include "confdefs.h" #include <alloca.h> -int main() { return 0; } -int t() { char *p = alloca(2 * sizeof(int));; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_ALLOCA_H" -echo "#define" HAVE_ALLOCA_H "1" >> confdefs.h -DEFS="$DEFS -DHAVE_ALLOCA_H=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_ALLOCA_H\${ac_dB}HAVE_ALLOCA_H\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_ALLOCA_H\${ac_uB}HAVE_ALLOCA_H\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_ALLOCA_H\${ac_eB}HAVE_ALLOCA_H\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - -ac_decl="#ifdef __GNUC__ -#define alloca __builtin_alloca -#else -#if HAVE_ALLOCA_H -#include <alloca.h> -#else -#ifdef _AIX - #pragma alloca -#else -char *alloca (); -#endif -#endif -#endif -" -test -n "$silent" || echo "checking for alloca" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -$ac_decl -int main() { return 0; } -int t() { char *p = (char *) alloca(1);; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_ALLOCA" -echo "#define" HAVE_ALLOCA "1" >> confdefs.h -DEFS="$DEFS -DHAVE_ALLOCA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_ALLOCA\${ac_dB}HAVE_ALLOCA\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_ALLOCA\${ac_uB}HAVE_ALLOCA\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_ALLOCA\${ac_eB}HAVE_ALLOCA\${ac_eC}1\${ac_eD} -" -} - - -else - rm -rf conftest* - ac_alloca_missing=1 -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -#if defined(CRAY) && ! defined(CRAY2) -winnitude -#else -lossage -#endif - -EOF -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "winnitude" conftest.out >/dev/null 2>&1; then - rm -rf conftest* - test -n "$silent" || echo "checking for _getb67" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub__getb67) || defined (__stub____getb67) -choke me -#else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char _getb67(); _getb67(); -#endif +int main() { +char *p = alloca(2 * sizeof(int)); ; return 0; } EOF -if eval $ac_compile; then - rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining" CRAY_STACKSEG_END to be "_getb67" -echo "#define" CRAY_STACKSEG_END "_getb67" >> confdefs.h -DEFS="$DEFS -DCRAY_STACKSEG_END=_getb67" -ac_sed_defs="${ac_sed_defs}\${ac_dA}CRAY_STACKSEG_END\${ac_dB}CRAY_STACKSEG_END\${ac_dC}_getb67\${ac_dD} -\${ac_uA}CRAY_STACKSEG_END\${ac_uB}CRAY_STACKSEG_END\${ac_uC}_getb67\${ac_uD} -\${ac_eA}CRAY_STACKSEG_END\${ac_eB}CRAY_STACKSEG_END\${ac_eC}_getb67\${ac_eD} -" -} - - -else - rm -rf conftest* - test -n "$silent" || echo "checking for GETB67" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_GETB67) || defined (__stub___GETB67) -choke me +if { (eval echo configure:6475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + ac_cv_header_alloca_h=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_header_alloca_h=no +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_header_alloca_h" 1>&6 +if test $ac_cv_header_alloca_h = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_ALLOCA_H +EOF +cat >> confdefs.h <<\EOF +#define HAVE_ALLOCA_H 1 +EOF +} + +fi + +echo $ac_n "checking for alloca""... $ac_c" 1>&6 +echo "configure:6499: checking for alloca" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6502 "configure" +#include "confdefs.h" + +#ifdef __GNUC__ +# define alloca __builtin_alloca #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char GETB67(); GETB67(); +# if HAVE_ALLOCA_H +# include <alloca.h> +# else +# ifdef _AIX + #pragma alloca +# else +# ifndef alloca /* predefined by HP cc +Olibcalls */ +char *alloca (); +# endif +# endif +# endif #endif + +int main() { +char *p = (char *) alloca(1); ; return 0; } EOF -if eval $ac_compile; then - rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining" CRAY_STACKSEG_END to be "GETB67" -echo "#define" CRAY_STACKSEG_END "GETB67" >> confdefs.h -DEFS="$DEFS -DCRAY_STACKSEG_END=GETB67" -ac_sed_defs="${ac_sed_defs}\${ac_dA}CRAY_STACKSEG_END\${ac_dB}CRAY_STACKSEG_END\${ac_dC}GETB67\${ac_dD} -\${ac_uA}CRAY_STACKSEG_END\${ac_uB}CRAY_STACKSEG_END\${ac_uC}GETB67\${ac_uD} -\${ac_eA}CRAY_STACKSEG_END\${ac_eB}CRAY_STACKSEG_END\${ac_eC}GETB67\${ac_eD} -" -} - - -else - rm -rf conftest* - test -n "$silent" || echo "checking for getb67" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_getb67) || defined (__stub___getb67) -choke me -#else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char getb67(); getb67(); -#endif -; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining" CRAY_STACKSEG_END to be "getb67" -echo "#define" CRAY_STACKSEG_END "getb67" >> confdefs.h -DEFS="$DEFS -DCRAY_STACKSEG_END=getb67" -ac_sed_defs="${ac_sed_defs}\${ac_dA}CRAY_STACKSEG_END\${ac_dB}CRAY_STACKSEG_END\${ac_dC}getb67\${ac_dD} -\${ac_uA}CRAY_STACKSEG_END\${ac_uB}CRAY_STACKSEG_END\${ac_uC}getb67\${ac_uD} -\${ac_eA}CRAY_STACKSEG_END\${ac_eB}CRAY_STACKSEG_END\${ac_eC}getb67\${ac_eD} -" -} - - -fi -rm -f conftest* - -fi -rm -f conftest* - -fi -rm -f conftest* - - -fi -rm -f conftest* - - -fi -rm -f conftest* - -if test -n "$ac_alloca_missing"; then +if { (eval echo configure:6525: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + ac_cv_func_alloca_works=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_func_alloca_works=no +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_func_alloca_works" 1>&6 +if test $ac_cv_func_alloca_works = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_ALLOCA +EOF +cat >> confdefs.h <<\EOF +#define HAVE_ALLOCA 1 +EOF +} + +fi + +if test $ac_cv_func_alloca_works = no; then # The SVR3 libPW and SVR4 libucb both contain incompatible functions # that cause trouble. Some versions do not even contain alloca or # contain a buggy version. If you still want to use their alloca, # use ar to extract alloca.o from them instead of compiling alloca.c. ALLOCA=alloca.o - -{ -test -n "$verbose" && \ -echo " defining C_ALLOCA" -echo "#define" C_ALLOCA "1" >> confdefs.h -DEFS="$DEFS -DC_ALLOCA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}C_ALLOCA\${ac_dB}C_ALLOCA\${ac_dC}1\${ac_dD} -\${ac_uA}C_ALLOCA\${ac_uB}C_ALLOCA\${ac_uC}1\${ac_uD} -\${ac_eA}C_ALLOCA\${ac_eB}C_ALLOCA\${ac_eC}1\${ac_eD} -" -} - - - test -n "$silent" || echo "checking stack direction for C alloca" - if test -n "$cross_compiling" -then - -{ -test -n "$verbose" && \ -echo " defining" STACK_DIRECTION to be "0" -echo "#define" STACK_DIRECTION "0" >> confdefs.h -DEFS="$DEFS -DSTACK_DIRECTION=0" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STACK_DIRECTION\${ac_dB}STACK_DIRECTION\${ac_dC}0\${ac_dD} -\${ac_uA}STACK_DIRECTION\${ac_uB}STACK_DIRECTION\${ac_uC}0\${ac_uD} -\${ac_eA}STACK_DIRECTION\${ac_eB}STACK_DIRECTION\${ac_eC}0\${ac_eD} -" -} - -else -cat > conftest.${ac_ext} <<EOF + { test "$extra_verbose" = "yes" && cat << \EOF + Defining C_ALLOCA +EOF +cat >> confdefs.h <<\EOF +#define C_ALLOCA 1 +EOF +} + + +echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 +echo "configure:6564: checking whether alloca needs Cray hooks" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6567 "configure" +#include "confdefs.h" +#if defined(CRAY) && ! defined(CRAY2) +webecray +#else +wenotbecray +#endif + +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "webecray" >/dev/null 2>&1; then + rm -rf conftest* + ac_cv_os_cray=yes +else + rm -rf conftest* + ac_cv_os_cray=no +fi +rm -f conftest* + + +echo "$ac_t""$ac_cv_os_cray" 1>&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:6591: checking for $ac_func" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6594 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +choke me +#else +$ac_func(); +#endif + +; return 0; } +EOF +if { (eval echo configure:6617: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << EOF + Defining CRAY_STACKSEG_END = $ac_func +EOF +cat >> confdefs.h <<EOF +#define CRAY_STACKSEG_END $ac_func +EOF +} + + break +else + echo "$ac_t""no" 1>&6 +fi + +done +fi + +echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 +echo "configure:6647: checking stack direction for C alloca" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6650 "configure" #include "confdefs.h" find_stack_direction () { @@ -5082,127 +6665,158 @@ exit (find_stack_direction() < 0); } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - -{ -test -n "$verbose" && \ -echo " defining" STACK_DIRECTION to be "1" -echo "#define" STACK_DIRECTION "1" >> confdefs.h -DEFS="$DEFS -DSTACK_DIRECTION=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STACK_DIRECTION\${ac_dB}STACK_DIRECTION\${ac_dC}1\${ac_dD} -\${ac_uA}STACK_DIRECTION\${ac_uB}STACK_DIRECTION\${ac_uC}1\${ac_uD} -\${ac_eA}STACK_DIRECTION\${ac_eB}STACK_DIRECTION\${ac_eC}1\${ac_eD} -" -} - - -else - -{ -test -n "$verbose" && \ -echo " defining" STACK_DIRECTION to be "-1" -echo "#define" STACK_DIRECTION "-1" >> confdefs.h -DEFS="$DEFS -DSTACK_DIRECTION=-1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}STACK_DIRECTION\${ac_dB}STACK_DIRECTION\${ac_dC}-1\${ac_dD} -\${ac_uA}STACK_DIRECTION\${ac_uB}STACK_DIRECTION\${ac_uC}-1\${ac_uD} -\${ac_eA}STACK_DIRECTION\${ac_eB}STACK_DIRECTION\${ac_eC}-1\${ac_eD} -" -} - -fi +if { (eval echo configure:6669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_c_stack_direction=1 +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_c_stack_direction=-1 fi rm -fr conftest* -fi - - -# Check whether vfork exists and works correctly. (This does more -# than just check for its existence.) If so, it defines HAVE_VFORK_H. -# If not, it defines vfork to be fork. -test -n "$silent" || echo "checking for pid_t in sys/types.h" -echo '#include "confdefs.h" -#include <sys/types.h>' > conftest.${ac_ext} -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "pid_t" conftest.out >/dev/null 2>&1; then - : -else - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining" pid_t to be "int" -echo "#define" pid_t "int" >> confdefs.h -DEFS="$DEFS -Dpid_t=int" -ac_sed_defs="${ac_sed_defs}\${ac_dA}pid_t\${ac_dB}pid_t\${ac_dC}int\${ac_dD} -\${ac_uA}pid_t\${ac_uB}pid_t\${ac_uC}int\${ac_uD} -\${ac_eA}pid_t\${ac_eB}pid_t\${ac_eC}int\${ac_eD} -" -} - -fi -rm -f conftest* - -test -n "$silent" || echo "checking for vfork.h" -cat > conftest.${ac_ext} <<EOF + +echo "$ac_t""$ac_cv_c_stack_direction" 1>&6 +{ test "$extra_verbose" = "yes" && cat << EOF + Defining STACK_DIRECTION = $ac_cv_c_stack_direction +EOF +cat >> confdefs.h <<EOF +#define STACK_DIRECTION $ac_cv_c_stack_direction +EOF +} + +fi + +test -n "$ALLOCA" && extra_objs="$extra_objs $ALLOCA" + +echo $ac_n "checking for pid_t""... $ac_c" 1>&6 +echo "configure:6694: checking for pid_t" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6697 "configure" +#include "confdefs.h" +#include <sys/types.h> +#if STDC_HEADERS +#include <stdlib.h> +#include <stddef.h> +#endif +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then + rm -rf conftest* + ac_cv_type_pid_t=yes +else + rm -rf conftest* + ac_cv_type_pid_t=no +fi +rm -f conftest* + +echo "$ac_t""$ac_cv_type_pid_t" 1>&6 +if test $ac_cv_type_pid_t = no; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining pid_t = int +EOF +cat >> confdefs.h <<\EOF +#define pid_t int +EOF +} + +fi + +ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for vfork.h""... $ac_c" 1>&6 +echo "configure:6729: checking for vfork.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6732 "configure" #include "confdefs.h" #include <vfork.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:6737: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_VFORK_H" -echo "#define" HAVE_VFORK_H "1" >> confdefs.h -DEFS="$DEFS -DHAVE_VFORK_H=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_VFORK_H\${ac_dB}HAVE_VFORK_H\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_VFORK_H\${ac_uB}HAVE_VFORK_H\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_VFORK_H\${ac_eB}HAVE_VFORK_H\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - -test -n "$silent" || echo "checking for working vfork" - -cat > conftest.${ac_ext} <<EOF + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_VFORK_H +EOF +cat >> confdefs.h <<\EOF +#define HAVE_VFORK_H 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi + +echo $ac_n "checking for working vfork""... $ac_c" 1>&6 +echo "configure:6765: checking for working vfork" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6768 "configure" #include "confdefs.h" /* Thanks to Paul Eggert for this test. */ #include <stdio.h> #include <sys/types.h> #include <sys/stat.h> -#include <signal.h> #ifdef HAVE_UNISTD_H #include <unistd.h> #endif #ifdef HAVE_VFORK_H #include <vfork.h> #endif -static int signalled; -static RETSIGTYPE catch (s) int s; { signalled = 1; } +/* On some sparc systems, changes by the child to local and incoming + argument registers are propagated back to the parent. + The compiler is told about this with #include <vfork.h>, + but some compilers (e.g. gcc -O) don't grok <vfork.h>. + Test for this by using a static variable whose address + is put into a register that is clobbered by the vfork. */ +static +#ifdef __cplusplus +sparc_address_test (int arg) +#else +sparc_address_test (arg) int arg; +#endif +{ + static pid_t child; + if (!child) { + child = vfork (); + if (child < 0) { + perror ("vfork"); + _exit(2); + } + if (!child) { + arg = getpid(); + write(-1, "", 0); + _exit (arg); + } + } +} main() { pid_t parent = getpid (); pid_t child; - signal (SIGINT, catch); + sparc_address_test (); child = vfork (); if (child == 0) { - /* On sparc systems, changes by the child to local and incoming - argument registers are propagated back to the parent. - The compiler is told about this with #include <vfork.h>, - but some compilers (e.g. gcc -O) don't grok <vfork.h>. - Test for this by using lots of local variables, at least + /* Here is another test for sparc vfork register problems. + This test uses lots of local variables, at least as many local variables as main has allocated so far including compiler temporaries. 4 locals are enough for - gcc 1.40.3 on a sparc, but we use 8 to be safe. + gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should reuse the register of parent for one of the local variables, since it will think that parent can't possibly be used any more in this routine. @@ -5217,12 +6831,6 @@ || p != p5 || p != p6 || p != p7) _exit(1); - /* On some systems (e.g. SunOS 5.2), if the parent is catching - a signal, the child ignores the signal before execing, - and the parent later receives that signal, the parent dumps core. - Test for this by ignoring SIGINT in the child. */ - signal (SIGINT, SIG_IGN); - /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent from child file descriptors. If the child closes a descriptor before it execs or exits, @@ -5245,46 +6853,41 @@ /* Did the vfork/compiler bug occur? */ || parent != getpid() - /* Did the signal handling bug occur? */ - || kill(parent, SIGINT) != 0 - || signalled != 1 - /* Did the file descriptor bug occur? */ || fstat(fileno(stdout), &st) != 0 ); } } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - : -else - -{ -test -n "$verbose" && \ -echo " defining" vfork to be "fork" -echo "#define" vfork "fork" >> confdefs.h -DEFS="$DEFS -Dvfork=fork" -ac_sed_defs="${ac_sed_defs}\${ac_dA}vfork\${ac_dB}vfork\${ac_dC}fork\${ac_dD} -\${ac_uA}vfork\${ac_uB}vfork\${ac_uC}fork\${ac_uD} -\${ac_eA}vfork\${ac_eB}vfork\${ac_eC}fork\${ac_eD} -" -} - +if { (eval echo configure:6863: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_func_vfork_works=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_func_vfork_works=no fi rm -fr conftest* - -# Check whether mmap exists and works correctly. (This does more -# than just check for its existence.) If so, it defines HAVE_MMAP. -# Actually, this seems to rule out some cases where mmap() can -# work fine for our purposes (e.g. HPUX). We get a big win out -# of using mmap(), so let's go back to the old way. - -# Check whether strcoll exists and works correctly. (This does more -# than just check for its existence.) If so, it defines HAVE_STRCOLL. -test -n "$silent" || echo "checking for strcoll" -cat > conftest.${ac_ext} <<EOF +echo "$ac_t""$ac_cv_func_vfork_works" 1>&6 +if test $ac_cv_func_vfork_works = no; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining vfork = fork +EOF +cat >> confdefs.h <<\EOF +#define vfork fork +EOF +} + +fi + + +echo $ac_n "checking for working strcoll""... $ac_c" 1>&6 +echo "configure:6888: checking for working strcoll" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6891 "configure" #include "confdefs.h" #include <string.h> main () @@ -5294,26 +6897,35 @@ strcoll ("123", "456") >= 0); } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - -{ -test -n "$verbose" && \ -echo " defining HAVE_STRCOLL" -echo "#define" HAVE_STRCOLL "1" >> confdefs.h -DEFS="$DEFS -DHAVE_STRCOLL=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_STRCOLL\${ac_dB}HAVE_STRCOLL\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_STRCOLL\${ac_uB}HAVE_STRCOLL\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_STRCOLL\${ac_eB}HAVE_STRCOLL\${ac_eC}1\${ac_eD} -" -} - - +if { (eval echo configure:6901: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_func_strcoll_works=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_func_strcoll_works=no fi rm -fr conftest* -test -n "$silent" || echo "checking size of short" -cat > conftest.${ac_ext} <<EOF +echo "$ac_t""$ac_cv_func_strcoll_works" 1>&6 +if test $ac_cv_func_strcoll_works = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_STRCOLL +EOF +cat >> confdefs.h <<\EOF +#define HAVE_STRCOLL 1 +EOF +} + +fi + + +echo $ac_n "checking size of short""... $ac_c" 1>&6 +echo "configure:6926: checking size of short" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6929 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -5324,28 +6936,31 @@ exit(0); } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - ac_size=`cat conftestval` - -else - echo "configure: can not determine size of short" >&2; exit 1 +if { (eval echo configure:6940: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_sizeof_short=`cat conftestval` +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_sizeof_short=0 fi rm -fr conftest* - -{ -test -n "$verbose" && \ -echo " defining" SIZEOF_SHORT to be "$ac_size" -echo "#define" SIZEOF_SHORT "$ac_size" >> confdefs.h -DEFS="$DEFS -DSIZEOF_SHORT=$ac_size" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SIZEOF_SHORT\${ac_dB}SIZEOF_SHORT\${ac_dC}$ac_size\${ac_dD} -\${ac_uA}SIZEOF_SHORT\${ac_uB}SIZEOF_SHORT\${ac_uC}$ac_size\${ac_uD} -\${ac_eA}SIZEOF_SHORT\${ac_eB}SIZEOF_SHORT\${ac_eC}$ac_size\${ac_eD} -" -} - -test -n "$silent" || echo "checking size of int" -cat > conftest.${ac_ext} <<EOF +echo "$ac_t""$ac_cv_sizeof_short" 1>&6 +{ test "$extra_verbose" = "yes" && cat << EOF + Defining SIZEOF_SHORT = $ac_cv_sizeof_short +EOF +cat >> confdefs.h <<EOF +#define SIZEOF_SHORT $ac_cv_sizeof_short +EOF +} + + +echo $ac_n "checking size of int""... $ac_c" 1>&6 +echo "configure:6961: checking size of int" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6964 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -5356,28 +6971,31 @@ exit(0); } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - ac_size=`cat conftestval` - -else - echo "configure: can not determine size of int" >&2; exit 1 +if { (eval echo configure:6975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_sizeof_int=`cat conftestval` +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_sizeof_int=0 fi rm -fr conftest* - -{ -test -n "$verbose" && \ -echo " defining" SIZEOF_INT to be "$ac_size" -echo "#define" SIZEOF_INT "$ac_size" >> confdefs.h -DEFS="$DEFS -DSIZEOF_INT=$ac_size" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SIZEOF_INT\${ac_dB}SIZEOF_INT\${ac_dC}$ac_size\${ac_dD} -\${ac_uA}SIZEOF_INT\${ac_uB}SIZEOF_INT\${ac_uC}$ac_size\${ac_uD} -\${ac_eA}SIZEOF_INT\${ac_eB}SIZEOF_INT\${ac_eC}$ac_size\${ac_eD} -" -} - -test -n "$silent" || echo "checking size of long" -cat > conftest.${ac_ext} <<EOF +echo "$ac_t""$ac_cv_sizeof_int" 1>&6 +{ test "$extra_verbose" = "yes" && cat << EOF + Defining SIZEOF_INT = $ac_cv_sizeof_int +EOF +cat >> confdefs.h <<EOF +#define SIZEOF_INT $ac_cv_sizeof_int +EOF +} + + +echo $ac_n "checking size of long""... $ac_c" 1>&6 +echo "configure:6996: checking size of long" >&5 + +cat > conftest.$ac_ext <<EOF +#line 6999 "configure" #include "confdefs.h" #include <stdio.h> main() @@ -5388,488 +7006,688 @@ exit(0); } EOF -eval $ac_compile -if test -s conftest && (./conftest; exit) 2>/dev/null; then - ac_size=`cat conftestval` - -else - echo "configure: can not determine size of long" >&2; exit 1 +if { (eval echo configure:7010: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_sizeof_long=`cat conftestval` +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_sizeof_long=0 fi rm -fr conftest* - -{ -test -n "$verbose" && \ -echo " defining" SIZEOF_LONG to be "$ac_size" -echo "#define" SIZEOF_LONG "$ac_size" >> confdefs.h -DEFS="$DEFS -DSIZEOF_LONG=$ac_size" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SIZEOF_LONG\${ac_dB}SIZEOF_LONG\${ac_dC}$ac_size\${ac_dD} -\${ac_uA}SIZEOF_LONG\${ac_uB}SIZEOF_LONG\${ac_uC}$ac_size\${ac_uD} -\${ac_eA}SIZEOF_LONG\${ac_eB}SIZEOF_LONG\${ac_eC}$ac_size\${ac_eD} -" -} - - -# FSF 19.29 does this: -# # fmod, logb, and frexp are found in -lm on most systems. -# # On HPUX 9.01, -lm does not contain logb, so check for sqrt. -# A C_CHECK_LIB(m, sqrt) - -for ac_func in acosh asinh atanh cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random realpath rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask strcasecmp strerror tzset utimes waitpid +echo "$ac_t""$ac_cv_sizeof_long" 1>&6 +{ test "$extra_verbose" = "yes" && cat << EOF + Defining SIZEOF_LONG = $ac_cv_sizeof_long +EOF +cat >> confdefs.h <<EOF +#define SIZEOF_LONG $ac_cv_sizeof_long +EOF +} + + + +for ac_hdr in unistd.h do -ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` -test -n "$silent" || echo "checking for ${ac_func}" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:7035: checking for $ac_hdr" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7038 "configure" +#include "confdefs.h" +#include <$ac_hdr> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7043: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_hdr +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_hdr 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi +done + +for ac_func in getpagesize +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:7075: checking for $ac_func" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7078 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $ac_func(); + +int main() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ -#if defined (__stub_${ac_func}) || defined (__stub___${ac_func}) +#if defined (__stub_$ac_func) || defined (__stub___$ac_func) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char ${ac_func}(); ${ac_func}(); +$ac_func(); #endif + ; return 0; } EOF -if eval $ac_compile; then - rm -rf conftest* - { -test -n "$verbose" && \ -echo " defining ${ac_tr_func}" -echo "#define" ${ac_tr_func} "1" >> confdefs.h -DEFS="$DEFS -D${ac_tr_func}=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}${ac_tr_func}\${ac_dB}${ac_tr_func}\${ac_dC}1\${ac_dD} -\${ac_uA}${ac_tr_func}\${ac_uB}${ac_tr_func}\${ac_uC}1\${ac_uD} -\${ac_eA}${ac_tr_func}\${ac_eB}${ac_tr_func}\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* +if { (eval echo configure:7101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_$ac_func=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then + echo "$ac_t""yes" 1>&6 + ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_func +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_func 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi done - -# Check for mmap. -found_mmap=true -test -n "$silent" || echo "checking for mmap" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_mmap) || defined (__stub___mmap) -choke me +echo $ac_n "checking for working mmap""... $ac_c" 1>&6 +echo "configure:7129: checking for working mmap" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7132 "configure" +#include "confdefs.h" + +/* Thanks to Mike Haertel and Jim Avera for this test. + Here is a matrix of mmap possibilities: + mmap private not fixed + mmap private fixed at somewhere currently unmapped + mmap private fixed at somewhere already mapped + mmap shared not fixed + mmap shared fixed at somewhere currently unmapped + mmap shared fixed at somewhere already mapped + For private mappings, we should verify that changes cannot be read() + back from the file, nor mmap's back from the file at a different + address. (There have been systems where private was not correctly + implemented like the infamous i386 svr4.0, and systems where the + VM page cache was not coherent with the filesystem buffer cache + like early versions of FreeBSD and possibly contemporary NetBSD.) + For shared mappings, we should conversely verify that changes get + propogated back to all the places they're supposed to be. + + Grep wants private fixed already mapped. + The main things grep needs to know about mmap are: + * does it exist and is it safe to write into the mmap'd area + * how to use it (BSD variants) */ +#include <sys/types.h> +#include <fcntl.h> +#include <sys/mman.h> + +/* This mess was copied from the GNU getpagesize.h. */ +#ifndef HAVE_GETPAGESIZE +# ifdef HAVE_UNISTD_H +# include <unistd.h> +# endif + +/* Assume that all systems that can run configure have sys/param.h. */ +# ifndef HAVE_SYS_PARAM_H +# define HAVE_SYS_PARAM_H 1 +# endif + +# ifdef _SC_PAGESIZE +# define getpagesize() sysconf(_SC_PAGESIZE) +# else /* no _SC_PAGESIZE */ +# ifdef HAVE_SYS_PARAM_H +# include <sys/param.h> +# ifdef EXEC_PAGESIZE +# define getpagesize() EXEC_PAGESIZE +# else /* no EXEC_PAGESIZE */ +# ifdef NBPG +# define getpagesize() NBPG * CLSIZE +# ifndef CLSIZE +# define CLSIZE 1 +# endif /* no CLSIZE */ +# else /* no NBPG */ +# ifdef NBPC +# define getpagesize() NBPC +# else /* no NBPC */ +# ifdef PAGESIZE +# define getpagesize() PAGESIZE +# endif /* PAGESIZE */ +# endif /* no NBPC */ +# endif /* no NBPG */ +# endif /* no EXEC_PAGESIZE */ +# else /* no HAVE_SYS_PARAM_H */ +# define getpagesize() 8192 /* punt totally */ +# endif /* no HAVE_SYS_PARAM_H */ +# endif /* no _SC_PAGESIZE */ + +#endif /* no HAVE_GETPAGESIZE */ + +#ifdef __cplusplus +extern "C" { void *malloc(unsigned); } #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char mmap(); mmap(); +char *malloc(); #endif -; return 0; } -EOF -if eval $ac_compile; then - : -else - rm -rf conftest* - found_mmap= -fi -rm -f conftest* - -test -n "$found_mmap" && + +int +main() { -test -n "$verbose" && \ -echo " defining HAVE_MMAP" -echo "#define" HAVE_MMAP "1" >> confdefs.h -DEFS="$DEFS -DHAVE_MMAP=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_MMAP\${ac_dB}HAVE_MMAP\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_MMAP\${ac_uB}HAVE_MMAP\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_MMAP\${ac_eB}HAVE_MMAP\${ac_eC}1\${ac_eD} -" -} - - -test "${GNU_MALLOC}" != "yes" -a "${found_mmap}" != "true" && rel_alloc=no -test "${rel_alloc}" = "default" -a "${found_mmap}" = "true" && rel_alloc=yes - -# Check for Internet sockets. - -ok_so_far=true -test -n "$silent" || echo "checking for socket" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { + char *data, *data2, *data3; + int i, pagesize; + int fd; + + pagesize = getpagesize(); + + /* + * First, make a file with some known garbage in it. + */ + data = malloc(pagesize); + if (!data) + exit(1); + for (i = 0; i < pagesize; ++i) + *(data + i) = rand(); + umask(0); + fd = creat("conftestmmap", 0600); + if (fd < 0) + exit(1); + if (write(fd, data, pagesize) != pagesize) + exit(1); + close(fd); + + /* + * Next, try to mmap the file at a fixed address which + * already has something else allocated at it. If we can, + * also make sure that we see the same garbage. + */ + fd = open("conftestmmap", O_RDWR); + if (fd < 0) + exit(1); + data2 = malloc(2 * pagesize); + if (!data2) + exit(1); + data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); + if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, + MAP_PRIVATE | MAP_FIXED, fd, 0L)) + exit(1); + for (i = 0; i < pagesize; ++i) + if (*(data + i) != *(data2 + i)) + exit(1); + + /* + * Finally, make sure that changes to the mapped area + * do not percolate back to the file as seen by read(). + * (This is a bug on some variants of i386 svr4.0.) + */ + for (i = 0; i < pagesize; ++i) + *(data2 + i) = *(data2 + i) + 1; + data3 = malloc(pagesize); + if (!data3) + exit(1); + if (read(fd, data3, pagesize) != pagesize) + exit(1); + for (i = 0; i < pagesize; ++i) + if (*(data + i) != *(data3 + i)) + exit(1); + close(fd); + unlink("conftestmmap"); + exit(0); +} + +EOF +if { (eval echo configure:7272: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_func_mmap_fixed_mapped=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_func_mmap_fixed_mapped=no +fi +rm -fr conftest* + +echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 +if test $ac_cv_func_mmap_fixed_mapped = yes; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_MMAP +EOF +cat >> confdefs.h <<\EOF +#define HAVE_MMAP 1 +EOF +} + +fi + + +test "$GNU_MALLOC" != "yes" -a "$ac_cv_func_mmap_fixed_mapped" != "yes" && rel_alloc=no +test "$rel_alloc" = "default" -a "$ac_cv_func_mmap_fixed_mapped" = "yes" && rel_alloc=yes +test "$rel_alloc" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining REL_ALLOC +EOF +cat >> confdefs.h <<\EOF +#define REL_ALLOC 1 +EOF +} + + +echo $ac_n "checking for socket""... $ac_c" 1>&6 +echo "configure:7308: checking for socket" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7311 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char socket(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char socket(); + +int main() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined (__stub_socket) || defined (__stub___socket) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char socket(); socket(); +socket(); #endif + ; return 0; } EOF -if eval $ac_compile; then - : -else - rm -rf conftest* - ok_so_far= -fi -rm -f conftest* - -test -n "$ok_so_far" && { test -n "$silent" || echo "checking for netinet/in.h" -cat > conftest.${ac_ext} <<EOF +if { (eval echo configure:7334: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_socket=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_socket=no" +fi +rm -f conftest* + +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:7349: checking for netinet/in.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7352 "configure" #include "confdefs.h" #include <netinet/in.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7357: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then - : -else - rm -rf conftest* - ok_so_far= -fi -rm -f conftest* - } -test -n "$ok_so_far" && { test -n "$silent" || echo "checking for arpa/inet.h" -cat > conftest.${ac_ext} <<EOF + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +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:7374: checking for arpa/inet.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7377 "configure" #include "confdefs.h" #include <arpa/inet.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7382: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then - : -else - rm -rf conftest* - ok_so_far= -fi -rm -f conftest* - } -if test -n "$ok_so_far"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 -{ -test -n "$verbose" && \ -echo " defining HAVE_SOCKETS" -echo "#define" HAVE_SOCKETS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_SOCKETS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_SOCKETS\${ac_dB}HAVE_SOCKETS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_SOCKETS\${ac_uB}HAVE_SOCKETS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_SOCKETS\${ac_eB}HAVE_SOCKETS\${ac_eC}1\${ac_eD} -" -} - - # Check for the sun_len member in struct sockaddr_un. - - test -n "$silent" || echo "checking for sun_len member in struct sockaddr_un" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_SOCKETS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_SOCKETS 1 +EOF +} + + echo $ac_n "checking "for sun_len member in struct sockaddr_un"""... $ac_c" 1>&6 +echo "configure:7407: checking "for sun_len member in struct sockaddr_un"" >&5 + cat > conftest.$ac_ext <<EOF +#line 7409 "configure" +#include "confdefs.h" + #include <sys/types.h> - #include <sys/socket.h> - #include <sys/un.h> -int main() { return 0; } -int t() { static struct sockaddr_un x; x.sun_len = 1;; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining HAVE_SOCKADDR_SUN_LEN" -echo "#define" HAVE_SOCKADDR_SUN_LEN "1" >> confdefs.h -DEFS="$DEFS -DHAVE_SOCKADDR_SUN_LEN=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_SOCKADDR_SUN_LEN\${ac_dB}HAVE_SOCKADDR_SUN_LEN\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_SOCKADDR_SUN_LEN\${ac_uB}HAVE_SOCKADDR_SUN_LEN\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_SOCKADDR_SUN_LEN\${ac_eB}HAVE_SOCKADDR_SUN_LEN\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - -fi - -# Check for SYS V IPC. (Inferior to sockets.) - -if test -z "$ok_so_far"; then - ok_so_far=true - test -n "$silent" || echo "checking for msgget" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { +#include <sys/socket.h> +#include <sys/un.h> + +int main() { +static struct sockaddr_un x; x.sun_len = 1; +; return 0; } +EOF +if { (eval echo configure:7420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + echo "$ac_t""yes" 1>&6; { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_SOCKADDR_SUN_LEN +EOF +cat >> confdefs.h <<\EOF +#define HAVE_SOCKADDR_SUN_LEN 1 +EOF +} + +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + echo "$ac_t""no" 1>&6 +fi +rm -f conftest* +else + echo "$ac_t""no" 1>&6 +fi + +else + echo "$ac_t""no" 1>&6 +fi + +else + echo "$ac_t""no" 1>&6 +fi + + +echo $ac_n "checking for msgget""... $ac_c" 1>&6 +echo "configure:7451: checking for msgget" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7454 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char msgget(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char msgget(); + +int main() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined (__stub_msgget) || defined (__stub___msgget) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char msgget(); msgget(); +msgget(); #endif + ; return 0; } EOF -if eval $ac_compile; then - : -else - rm -rf conftest* - ok_so_far= -fi -rm -f conftest* - - test -n "$ok_so_far" && { test -n "$silent" || echo "checking for sys/ipc.h" -cat > conftest.${ac_ext} <<EOF +if { (eval echo configure:7477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_msgget=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_msgget=no" +fi +rm -f conftest* + +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:7492: checking for sys/ipc.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7495 "configure" #include "confdefs.h" #include <sys/ipc.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7500: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then - : -else - rm -rf conftest* - ok_so_far= -fi -rm -f conftest* - } - test -n "$ok_so_far" && { test -n "$silent" || echo "checking for sys/msg.h" -cat > conftest.${ac_ext} <<EOF + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +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:7517: checking for sys/msg.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7520 "configure" #include "confdefs.h" #include <sys/msg.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7525: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then - : -else - rm -rf conftest* - ok_so_far= -fi -rm -f conftest* - } - test -n "$ok_so_far" && -{ -test -n "$verbose" && \ -echo " defining HAVE_SYSVIPC" -echo "#define" HAVE_SYSVIPC "1" >> confdefs.h -DEFS="$DEFS -DHAVE_SYSVIPC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_SYSVIPC\${ac_dB}HAVE_SYSVIPC\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_SYSVIPC\${ac_uB}HAVE_SYSVIPC\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_SYSVIPC\${ac_eB}HAVE_SYSVIPC\${ac_eC}1\${ac_eD} -" -} - -fi - -# Check for directory variants - -sysv_system_dir= -nonsystem_dir_library= -test -n "$silent" || echo "checking for dirent.h" -cat > conftest.${ac_ext} <<EOF + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_SYSVIPC +EOF +cat >> confdefs.h <<\EOF +#define HAVE_SYSVIPC 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi + +else + echo "$ac_t""no" 1>&6 +fi + +else + echo "$ac_t""no" 1>&6 +fi + + +ac_safe=`echo "dirent.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for dirent.h""... $ac_c" 1>&6 +echo "configure:7563: checking for dirent.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7566 "configure" #include "confdefs.h" #include <dirent.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7571: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - sysv_system_dir=yes - -fi -rm -f conftest* - -test -z "$sysv_system_dir" && - { test -n "$silent" || echo "checking for sys/dir.h" -cat > conftest.${ac_ext} <<EOF + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining SYSV_SYSTEM_DIR +EOF +cat >> confdefs.h <<\EOF +#define SYSV_SYSTEM_DIR 1 +EOF +} + +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:7598: checking for sys/dir.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7601 "configure" #include "confdefs.h" #include <sys/dir.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7606: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 : else - rm -rf conftest* - nonsystem_dir_library=yes -fi -rm -f conftest* - } -if test -n "$sysv_system_dir" ; then -{ -test -n "$verbose" && \ -echo " defining SYSV_SYSTEM_DIR" -echo "#define" SYSV_SYSTEM_DIR "1" >> confdefs.h -DEFS="$DEFS -DSYSV_SYSTEM_DIR=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SYSV_SYSTEM_DIR\${ac_dB}SYSV_SYSTEM_DIR\${ac_dC}1\${ac_dD} -\${ac_uA}SYSV_SYSTEM_DIR\${ac_uB}SYSV_SYSTEM_DIR\${ac_uC}1\${ac_uD} -\${ac_eA}SYSV_SYSTEM_DIR\${ac_eB}SYSV_SYSTEM_DIR\${ac_eC}1\${ac_eD} -" -} - -elif test -n "$nonsystem_dir_library" ; then -{ -test -n "$verbose" && \ -echo " defining NONSYSTEM_DIR_LIBRARY" -echo "#define" NONSYSTEM_DIR_LIBRARY "1" >> confdefs.h -DEFS="$DEFS -DNONSYSTEM_DIR_LIBRARY=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NONSYSTEM_DIR_LIBRARY\${ac_dB}NONSYSTEM_DIR_LIBRARY\${ac_dC}1\${ac_dD} -\${ac_uA}NONSYSTEM_DIR_LIBRARY\${ac_uB}NONSYSTEM_DIR_LIBRARY\${ac_uC}1\${ac_uD} -\${ac_eA}NONSYSTEM_DIR_LIBRARY\${ac_eB}NONSYSTEM_DIR_LIBRARY\${ac_eC}1\${ac_eD} -" -} - -fi - - -echo "checking how to do terminal I/O" - -have_termios= -have_termio= -test -n "$silent" || echo "checking for termios.h" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <termios.h> -EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi -if test -z "$ac_err"; then - rm -rf conftest* - have_termios=yes - -fi -rm -f conftest* - -test -z "$have_termios" && { test -n "$silent" || echo "checking for termio.h" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <termio.h> -EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi -if test -z "$ac_err"; then - rm -rf conftest* - have_termio=yes - -fi -rm -f conftest* - } -if test -n "$have_termios" ; then -{ -test -n "$verbose" && \ -echo " defining HAVE_TERMIOS" -echo "#define" HAVE_TERMIOS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TERMIOS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TERMIOS\${ac_dB}HAVE_TERMIOS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TERMIOS\${ac_uB}HAVE_TERMIOS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TERMIOS\${ac_eB}HAVE_TERMIOS\${ac_eC}1\${ac_eD} -" -} - -elif test -n "$have_termio" ; then -{ -test -n "$verbose" && \ -echo " defining HAVE_TERMIO" -echo "#define" HAVE_TERMIO "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TERMIO=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TERMIO\${ac_dB}HAVE_TERMIO\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TERMIO\${ac_uB}HAVE_TERMIO\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TERMIO\${ac_eB}HAVE_TERMIO\${ac_eC}1\${ac_eD} -" -} - -fi - -# Check for nlist.h -test -n "$silent" || echo "checking for nlist.h" -cat > conftest.${ac_ext} <<EOF + echo "$ac_t""no" 1>&6 +{ test "$extra_verbose" = "yes" && cat << \EOF + Defining NONSYSTEM_DIR_LIBRARY +EOF +cat >> confdefs.h <<\EOF +#define NONSYSTEM_DIR_LIBRARY 1 +EOF +} + +fi + +fi + + +ac_safe=`echo "nlist.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for nlist.h""... $ac_c" 1>&6 +echo "configure:7639: checking for nlist.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7642 "configure" #include "confdefs.h" #include <nlist.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7647: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - -{ -test -n "$verbose" && \ -echo " defining NLIST_STRUCT" -echo "#define" NLIST_STRUCT "1" >> confdefs.h -DEFS="$DEFS -DNLIST_STRUCT=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NLIST_STRUCT\${ac_dB}NLIST_STRUCT\${ac_dC}1\${ac_dD} -\${ac_uA}NLIST_STRUCT\${ac_uB}NLIST_STRUCT\${ac_uC}1\${ac_uD} -\${ac_eA}NLIST_STRUCT\${ac_eB}NLIST_STRUCT\${ac_eC}1\${ac_eD} -" -} - - -fi -rm -f conftest* - - -# AIX export list -if test -f /usr/lpp/X11/bin/smt.exp ; then - -{ -test -n "$verbose" && \ -echo " defining" AIX_SMT_EXP to be "-bI:/usr/lpp/X11/bin/smt.exp" -echo "#define" AIX_SMT_EXP "-bI:/usr/lpp/X11/bin/smt.exp" >> confdefs.h -DEFS="$DEFS -DAIX_SMT_EXP=-bI:/usr/lpp/X11/bin/smt.exp" -ac_sed_defs="${ac_sed_defs}\${ac_dA}AIX_SMT_EXP\${ac_dB}AIX_SMT_EXP\${ac_dC}-bI:/usr/lpp/X11/bin/smt.exp\${ac_dD} -\${ac_uA}AIX_SMT_EXP\${ac_uB}AIX_SMT_EXP\${ac_uC}-bI:/usr/lpp/X11/bin/smt.exp\${ac_uD} -\${ac_eA}AIX_SMT_EXP\${ac_eB}AIX_SMT_EXP\${ac_eC}-bI:/usr/lpp/X11/bin/smt.exp\${ac_eD} -" -} - -elif test -f /usr/bin/X11/smt.exp ; then - -{ -test -n "$verbose" && \ -echo " defining" AIX_SMT_EXP to be "-bI:/usr/bin/X11/smt.exp" -echo "#define" AIX_SMT_EXP "-bI:/usr/bin/X11/smt.exp" >> confdefs.h -DEFS="$DEFS -DAIX_SMT_EXP=-bI:/usr/bin/X11/smt.exp" -ac_sed_defs="${ac_sed_defs}\${ac_dA}AIX_SMT_EXP\${ac_dB}AIX_SMT_EXP\${ac_dC}-bI:/usr/bin/X11/smt.exp\${ac_dD} -\${ac_uA}AIX_SMT_EXP\${ac_uB}AIX_SMT_EXP\${ac_uC}-bI:/usr/bin/X11/smt.exp\${ac_uD} -\${ac_eA}AIX_SMT_EXP\${ac_eB}AIX_SMT_EXP\${ac_eC}-bI:/usr/bin/X11/smt.exp\${ac_eD} -" -} - -fi + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining NLIST_STRUCT +EOF +cat >> confdefs.h <<\EOF +#define NLIST_STRUCT 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi + + +for f in "/usr/lpp/X11/bin/smt.exp" "/usr/bin/X11/smt.exp" ; do + if test -r $f; then { test "$extra_verbose" = "yes" && cat << EOF + Defining AIX_SMT_EXP = -bI:$f +EOF +cat >> confdefs.h <<EOF +#define AIX_SMT_EXP -bI:$f +EOF +} + break; fi +done CFLAGS="$REAL_CFLAGS" -file="${srcdir}/lisp/version.el" +file="$srcdir/lisp/version.el" version=`sed -ne 's/^(defconst emacs-version "\(.*\)".*/\1/p' "$file"` -if test -z "${version}"; then - echo "${progname}: can't find current emacs version in \"$file\"." >&2 +if test -z "$version"; then + echo "$progname: can't find current emacs version in \"$file\"." >&2 exit 1 fi beta=`sed -ne 's/^.*XEmacs Lucid (beta\([0-9][0-9]*\)).*$/\1/p' "$file"` @@ -5877,1316 +7695,1643 @@ -# the following needs to be fixed for SGI. -if test -z "${native_sound_lib}" ; then - if test -r /usr/demo/SOUND/lib/libaudio.a; then - native_sound_lib=/usr/demo/SOUND/lib/libaudio.a - elif test -r /usr/demo/SOUND/libaudio.a ; then - native_sound_lib=/usr/demo/SOUND/libaudio.a +echo "checking "for sound support"" 1>&6 +echo "configure:7700: checking "for sound support"" >&5 +case "$with_sound" in + native | both ) with_native_sound=yes;; + nas | no ) with_native_sound=no;; +esac +if test "$with_native_sound" != "no"; then + if test -d "/usr/demo/SOUND"; then + sound_found="yes" extra_objs="$extra_objs sunplay.o" + if test -d "/usr/demo/SOUND/include" + then sound_cflags="-I/usr/demo/SOUND/include" + else sound_cflags="-I/usr/demo/SOUND" + fi + if test -z "$native_sound_lib" ; then + if test -r "/usr/demo/SOUND/lib/libaudio.a" + then native_sound_lib="/usr/demo/SOUND/lib/libaudio.a" + else native_sound_lib="/usr/demo/SOUND/libaudio.a" + fi + fi else - case "${canonical}" in - *-sgi-* ) ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -laudio" -ac_have_lib="" -test -n "$silent" || echo "checking for -laudio" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; native_sound_lib="-laudio" -else - :; -fi - ;; - hppa*-hp-hpux* ) ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lAlib" -ac_have_lib="" -test -n "$silent" || echo "checking for -lAlib" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; native_sound_lib="-lAlib" -else - :; -fi - ;; + case "$canonical" in \ + *-sgi-* ) + +echo $ac_n "checking for ALopenport in -laudio""... $ac_c" 1>&6 +echo "configure:7723: checking for ALopenport in -laudio" >&5 +ac_lib_var=`echo audio'_'ALopenport | sed 'y%./+-%__p_%'` + +xe_check_libs=" -laudio " +cat > conftest.$ac_ext <<EOF +#line 7728 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char ALopenport(); + +int main() { +ALopenport() +; return 0; } +EOF +if { (eval echo configure:7739: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + native_sound_lib="-laudio" +else + echo "$ac_t""no" 1>&6 +fi + + + if test "$native_sound_lib" = "-laudio"; then + sound_found="yes" extra_objs="$extra_objs sgiplay.o" sound_cflags="" + fi ;; + hppa*-hp-hpux* ) + +echo $ac_n "checking for AOpenAudio in -lAlib""... $ac_c" 1>&6 +echo "configure:7765: checking for AOpenAudio in -lAlib" >&5 +ac_lib_var=`echo Alib'_'AOpenAudio | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lAlib " +cat > conftest.$ac_ext <<EOF +#line 7770 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char AOpenAudio(); + +int main() { +AOpenAudio() +; return 0; } +EOF +if { (eval echo configure:7781: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + native_sound_lib="-lAlib" +else + echo "$ac_t""no" 1>&6 +fi + + + if test "$native_sound_lib" = "-lAlib"; then + sound_found="yes" extra_objs="$extra_objs hpplay.o" + if test "$with_gcc" = "yes" # Kludge city + then sound_cflags="-Dconst= -Dvolatile= -I/usr/audio/examples" + else sound_cflags="+e -I/usr/audio/examples" + fi + fi ;; esac fi -fi -test -z "${with_sound}" -a -n "${native_sound_lib}" && with_sound="native"; - -#### If the nas library doesn't contain the error jump point, then -#### we force safer behaviour. - -if test "${with_sound}" = "nas" -o \ - "${with_sound}" = "both"; then - echo '#include "confdefs.h" -#include <audio/Xtutil.h>' > conftest.${ac_ext} -eval "$ac_cpp conftest.${ac_ext} > conftest.out 2>&1" -if egrep "AuXtErrorJump" conftest.out >/dev/null 2>&1; then - : -else - rm -rf conftest* - old_nas=true -fi -rm -f conftest* - -fi - -if test "${with_cde}" = "yes" ; then - if test -f "/usr/dt/include/Dt/Dt.h" ; then - C_SWITCH_X_SITE="${C_SWITCH_X_SITE} -I/usr/dt/include" + + if test -z "$sound_found"; then + 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:7815: checking for ${dir}/soundcard.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7818 "configure" +#include "confdefs.h" +#include <${dir}/soundcard.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7823: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + sound_found=yes + extra_objs="$extra_objs linuxplay.o" + { test "$extra_verbose" = "yes" && cat << EOF + Defining SOUNDCARD_H_PATH = "${dir}/soundcard.h" +EOF +cat >> confdefs.h <<EOF +#define SOUNDCARD_H_PATH "${dir}/soundcard.h" +EOF +} + + break +else + echo "$ac_t""no" 1>&6 +fi + + done fi - if test -f "/usr/dt/lib/libDtSvc.a" ; then - LD_SWITCH_X_SITE="${LD_SWITCH_X_SITE} -L/usr/dt/lib" + + test "$sound_found" = "yes" && with_native_sound=yes +fi + +if test -z "$with_sound"; then + if test "$with_native_sound" = "yes" -o -n "$native_sound_lib"; then + with_sound=native fi fi -if test "${with_tooltalk}" = "yes" ; then - for arg in "-I/usr/include/desktop" "-I${OPENWINHOME-/usr/openwin}/include/desktop" "-I/usr/dt/include/Tt" - do - if test -f `echo "${arg}/tt_c.h" | sed 's/^\-I//'` ; then - C_SWITCH_X_SITE="${C_SWITCH_X_SITE} ${arg}" - fi - done - for arg in "-L/usr/lib" "-L${OPENWINHOME-/usr/openwin}/lib" "-L/usr/dt/lib" - do - case "${arg}" in - -L*) if test -f `echo "${arg}/libtt.a" | sed 's/^\-L//'` ; then - dash_r='' - if test "${add_runtime_flag}" = "yes" ; then - dash_r=`echo ${arg} | sed "s/^-L */${runtime_arg}/"` - fi - LD_SWITCH_X_SITE="${LD_SWITCH_X_SITE} ${arg} ${dash_r}" - fi - ;; - esac - done -fi - - -if test "${with_tty}" != "no" ; then - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lncurses" -ac_have_lib="" -test -n "$silent" || echo "checking for -lncurses" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; have_ncurses=yes -else - :; have_ncurses=no -fi - - if test "${have_ncurses}" = "yes" ; then +if test "$with_native_sound" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_NATIVE_SOUND +EOF +cat >> confdefs.h <<\EOF +#define HAVE_NATIVE_SOUND 1 +EOF +} + + test -n "$native_sound_lib" && LIBS="$LIBS $native_sound_lib" +fi + +case "$with_sound" in both | nas ) + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_NAS_SOUND +EOF +cat >> confdefs.h <<\EOF +#define HAVE_NAS_SOUND 1 +EOF +} + + extra_objs="$extra_objs nas.o" + LIBS="$LIBS -laudio" + cat > conftest.$ac_ext <<EOF +#line 7889 "configure" +#include "confdefs.h" +#include <audio/Xtutil.h> +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "AuXtErrorJump" >/dev/null 2>&1; then + : +else + rm -rf conftest* + { test "$extra_verbose" = "yes" && cat << \EOF + Defining NAS_NO_ERROR_JUMP +EOF +cat >> confdefs.h <<\EOF +#define NAS_NO_ERROR_JUMP 1 +EOF +} + +fi +rm -f conftest* + +esac + + + + +echo "checking "how to do terminal I/O"" 1>&6 +echo "configure:7915: checking "how to do terminal I/O"" >&5 + +test -z "$with_tty" && with_tty=yes + +if test "$with_tty" = "yes" ; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TTY +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TTY 1 +EOF +} + + + ac_safe=`echo "termios.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for termios.h""... $ac_c" 1>&6 +echo "configure:7931: checking for termios.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7934 "configure" +#include "confdefs.h" +#include <termios.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7939: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TERMIOS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TERMIOS 1 +EOF +} + +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:7966: checking for termio.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 7969 "configure" +#include "confdefs.h" +#include <termio.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:7974: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TERMIO +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TERMIO 1 +EOF +} + +else + echo "$ac_t""no" 1>&6 +fi + +fi + + + #### Attn: Bill Perry: Remove next line when GPM support is added + test -z "$with_gpm" && with_gpm=no + + 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:8009: checking for gpm.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 8012 "configure" +#include "confdefs.h" +#include <gpm.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:8017: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 +with_gpm=no +fi + } + test -z "$with_gpm" && { +echo $ac_n "checking for connect_to_gpm in -lgpm""... $ac_c" 1>&6 +echo "configure:8040: checking for connect_to_gpm in -lgpm" >&5 +ac_lib_var=`echo gpm'_'connect_to_gpm | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lgpm " +cat > conftest.$ac_ext <<EOF +#line 8045 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char connect_to_gpm(); + +int main() { +connect_to_gpm() +; return 0; } +EOF +if { (eval echo configure:8056: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_gpm=yes +else + echo "$ac_t""no" 1>&6 +with_gpm=no +fi + + } + if test "$with_gpm" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_GPM +EOF +cat >> confdefs.h <<\EOF +#define HAVE_GPM 1 +EOF +} + + extra_objs="$extra_objs gpmevent.o" + LIBS="$LIBS -lgpm" + fi + + if test -z "$with_ncurses"; then -{ -test -n "$verbose" && \ -echo " defining HAVE_NCURSES" -echo "#define" HAVE_NCURSES "1" >> confdefs.h -DEFS="$DEFS -DHAVE_NCURSES=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_NCURSES\${ac_dB}HAVE_NCURSES\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_NCURSES\${ac_uB}HAVE_NCURSES\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_NCURSES\${ac_eB}HAVE_NCURSES\${ac_eC}1\${ac_eD} -" -} - - test -n "$silent" || echo "checking for ncurses/term.h" -cat > conftest.${ac_ext} <<EOF +echo $ac_n "checking for tparm in -lncurses""... $ac_c" 1>&6 +echo "configure:8093: checking for tparm in -lncurses" >&5 +ac_lib_var=`echo ncurses'_'tparm | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lncurses " +cat > conftest.$ac_ext <<EOF +#line 8098 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char tparm(); + +int main() { +tparm() +; return 0; } +EOF +if { (eval echo configure:8109: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_ncurses=yes +else + echo "$ac_t""no" 1>&6 +with_ncurses=no +fi + + + fi + if test "$with_ncurses" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_NCURSES +EOF +cat >> confdefs.h <<\EOF +#define HAVE_NCURSES 1 +EOF +} + + ac_safe=`echo "ncurses/curses.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for ncurses/curses.h""... $ac_c" 1>&6 +echo "configure:8142: checking for ncurses/curses.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 8145 "configure" +#include "confdefs.h" +#include <ncurses/curses.h> +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:8150: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` +if test -z "$ac_err"; then + rm -rf conftest* + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + curses_h_path=ncurses/curses.h +else + echo "$ac_t""no" 1>&6 +fi + + ac_safe=`echo "ncurses/term.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for ncurses/term.h""... $ac_c" 1>&6 +echo "configure:8172: checking for ncurses/term.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 8175 "configure" #include "confdefs.h" #include <ncurses/term.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +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; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - have_ncurses_term_h=yes - -else - rm -rf conftest* - have_ncurses_term_h=no -fi -rm -f conftest* - - test "${have_ncurses_term_h}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_NCURSES_TERM_H" -echo "#define" HAVE_NCURSES_TERM_H "1" >> confdefs.h -DEFS="$DEFS -DHAVE_NCURSES_TERM_H=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_NCURSES_TERM_H\${ac_dB}HAVE_NCURSES_TERM_H\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_NCURSES_TERM_H\${ac_uB}HAVE_NCURSES_TERM_H\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_NCURSES_TERM_H\${ac_eB}HAVE_NCURSES_TERM_H\${ac_eC}1\${ac_eD} -" -} - - test -n "$silent" || echo "checking for ncurses/curses.h" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ncurses/curses.h> -EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi -if test -z "$ac_err"; then - rm -rf conftest* - have_ncurses_curses_h=yes - -else - rm -rf conftest* - have_ncurses_curses_h=no -fi -rm -f conftest* - - if test "${have_ncurses_curses_h}" = "no" ; then - OLD_CPP="${CPP}" - CPP="${CPP} -I/usr/include/ncurses" - test -n "$silent" || echo "checking for ncurses/curses.h" -cat > conftest.${ac_ext} <<EOF + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + term_h_path=ncurses/term.h +else + echo "$ac_t""no" 1>&6 +fi + + extra_objs="$extra_objs terminfo.o" + LIBS="$LIBS -lncurses" + + if test "$ac_cv_header_ncurses_curses_h" != "yes" ; then + save_c_switch_site="$c_switch_site" + 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:8208: checking for ncurses/curses.h" >&5 + +cat > conftest.$ac_ext <<EOF +#line 8211 "configure" #include "confdefs.h" #include <ncurses/curses.h> EOF -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:8216: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* - have_ncurses_curses_h=yes - -else - rm -rf conftest* - have_ncurses_curses_h=no -fi -rm -f conftest* - - if test "${have_ncurses_curses_h}" = "yes" ; then - site_includes="${site_includes} /usr/include/ncurses" - C_SWITCH_SITE="${C_SWITCH_SITE} -I/usr/include/ncurses" - test -n "$verbose" && echo " Your system has the bogus ncurses include bug." - else - CPP="${OLD_CPP}" + eval "ac_cv_header_$ac_safe=yes" +else + echo "$ac_err" >&5 + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_header_$ac_safe=no" +fi +rm -f conftest* +if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then + echo "$ac_t""yes" 1>&6 + curses_h_path=ncurses/curses.h +else + echo "$ac_t""no" 1>&6 +fi + + if test "$ac_cv_header_ncurses_curses_h" = "yes"; + then echo "configure: warning: "Your system has the bogus ncurses include bug."" 1>&2 + else c_switch_site="$save_c_switch_site" + fi + fi + else +echo $ac_n "checking for tgoto in -ltermlib""... $ac_c" 1>&6 +echo "configure:8243: checking for tgoto in -ltermlib" >&5 +ac_lib_var=`echo termlib'_'tgoto | sed 'y%./+-%__p_%'` + +xe_check_libs=" -ltermlib " +cat > conftest.$ac_ext <<EOF +#line 8248 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char tgoto(); + +int main() { +tgoto() +; return 0; } +EOF +if { (eval echo configure:8259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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_libtermlib=yes +else + echo "$ac_t""no" 1>&6 +have_libtermlib=no +fi + + + +echo $ac_n "checking for tgoto in -ltermcap""... $ac_c" 1>&6 +echo "configure:8282: checking for tgoto in -ltermcap" >&5 +ac_lib_var=`echo termcap'_'tgoto | sed 'y%./+-%__p_%'` + +xe_check_libs=" -ltermcap " +cat > conftest.$ac_ext <<EOF +#line 8287 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char tgoto(); + +int main() { +tgoto() +; return 0; } +EOF +if { (eval echo configure:8298: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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_libtermcap=yes +else + echo "$ac_t""no" 1>&6 +have_libtermcap=no +fi + + + +echo $ac_n "checking for tparm in -lcurses""... $ac_c" 1>&6 +echo "configure:8321: checking for tparm in -lcurses" >&5 +ac_lib_var=`echo curses'_'tparm | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lcurses " +cat > conftest.$ac_ext <<EOF +#line 8326 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char tparm(); + +int main() { +tparm() +; return 0; } +EOF +if { (eval echo configure:8337: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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_libcurses=yes +else + echo "$ac_t""no" 1>&6 +have_libcurses=no +fi + + + + if test "$have_terminfo" = "yes"; then + extra_objs="$extra_objs terminfo.o" + if test -n "$libs_termcap"; then LIBS="$LIBS $libs_termcap" + elif test "$have_libcurses" = "yes"; then LIBS="$LIBS -lcurses" + elif test "$have_libtermlib" = "yes"; then LIBS="$LIBS -ltermlib" + elif test "$have_libtermcap" = "yes"; then LIBS="$LIBS -ltermcap" + fi + else extra_objs="$extra_objs tparam.o" + if test -n "$libs_termcap"; then LIBS="$LIBS $libs_termcap" + elif test "$have_libtermcap" = "yes"; then LIBS="$LIBS -ltermcap" + elif test "$have_libcurses" = "yes"; then LIBS="$LIBS -lcurses" + else extra_objs="$extra_objs termcap.o" fi fi - test "${have_ncurses_curses_h}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_NCURSES_CURSES_H" -echo "#define" HAVE_NCURSES_CURSES_H "1" >> confdefs.h -DEFS="$DEFS -DHAVE_NCURSES_CURSES_H=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_NCURSES_CURSES_H\${ac_dB}HAVE_NCURSES_CURSES_H\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_NCURSES_CURSES_H\${ac_uB}HAVE_NCURSES_CURSES_H\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_NCURSES_CURSES_H\${ac_eB}HAVE_NCURSES_CURSES_H\${ac_eC}1\${ac_eD} -" -} + fi + { test "$extra_verbose" = "yes" && cat << EOF + Defining CURSES_H_PATH = "${curses_h_path-curses.h}" +EOF +cat >> confdefs.h <<EOF +#define CURSES_H_PATH "${curses_h_path-curses.h}" +EOF +} + + { test "$extra_verbose" = "yes" && cat << EOF + Defining TERM_H_PATH = "${term_h_path-term.h}" +EOF +cat >> confdefs.h <<EOF +#define TERM_H_PATH "${term_h_path-term.h}" +EOF +} + +else # "$with_tty" = "no" + for feature in ncurses gpm; do + if eval "test -n \"\$with_${feature}\" -a \"\$with_${feature}\" != no" ; then + echo "configure: warning: "--with-${feature} ignored: Not valid without TTY support"" 1>&2 + fi + eval "with_${feature}=no" + done +fi + + +echo "checking for database support" 1>&6 +echo "configure:8401: checking for database support" >&5 + +if test "$with_database_gnudbm" != "no" ; then + +echo $ac_n "checking for dbm_open in -lgdbm""... $ac_c" 1>&6 +echo "configure:8406: 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 <<EOF +#line 8411 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dbm_open(); + +int main() { +dbm_open() +; return 0; } +EOF +if { (eval echo configure:8422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_database_gnudbm=yes have_libgdbm=yes +else + echo "$ac_t""no" 1>&6 +fi + + + if test "$with_database_gnudbm" != "yes"; then + echo $ac_n "checking for dbm_open""... $ac_c" 1>&6 +echo "configure:8444: checking for dbm_open" >&5 + +cat > conftest.$ac_ext <<EOF +#line 8447 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char dbm_open(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dbm_open(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_dbm_open) || defined (__stub___dbm_open) +choke me +#else +dbm_open(); +#endif + +; return 0; } +EOF +if { (eval echo configure:8470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_dbm_open=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_dbm_open=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'dbm_open`\" = yes"; then + echo "$ac_t""yes" 1>&6 + with_database_gnudbm=yes +else + echo "$ac_t""no" 1>&6 +fi + + fi + if test "$with_database_gnudbm" = "yes" ; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_DBM +EOF +cat >> confdefs.h <<\EOF +#define HAVE_DBM 1 +EOF +} + + test "$have_libgdbm" = "yes" && LIBS="$LIBS -lgdbm" + with_database_dbm=no + else with_database_gnudbm=no + fi +fi + +if test "$with_database_dbm" != "no" ; then + echo $ac_n "checking for dbm_open""... $ac_c" 1>&6 +echo "configure:8506: checking for dbm_open" >&5 + +cat > conftest.$ac_ext <<EOF +#line 8509 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char dbm_open(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dbm_open(); + +int main() { + +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined (__stub_dbm_open) || defined (__stub___dbm_open) +choke me +#else +dbm_open(); +#endif + +; return 0; } +EOF +if { (eval echo configure:8532: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_dbm_open=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_dbm_open=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'dbm_open`\" = yes"; then + echo "$ac_t""yes" 1>&6 + with_database_dbm=yes need_libdbm=no +else + echo "$ac_t""no" 1>&6 +fi + + if test "$need_libdbm" != "no"; then + +echo $ac_n "checking for dbm_open in -ldbm""... $ac_c" 1>&6 +echo "configure:8553: 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 <<EOF +#line 8558 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dbm_open(); + +int main() { +dbm_open() +; return 0; } +EOF +if { (eval echo configure:8569: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_database_dbm=yes need_libdbm=yes +else + echo "$ac_t""no" 1>&6 +fi + fi -fi - - - -if test "${with_database_berkdb}" != "no" ; then - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -ldb" -ac_have_lib="" -test -n "$silent" || echo "checking for -ldb" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; have_libdb=yes -else - :; have_libdb=no -fi - - test "${have_libdb}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_LIBDB" -echo "#define" HAVE_LIBDB "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LIBDB=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LIBDB\${ac_dB}HAVE_LIBDB\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LIBDB\${ac_uB}HAVE_LIBDB\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LIBDB\${ac_eB}HAVE_LIBDB\${ac_eC}1\${ac_eD} -" -} - - if test "${with_database_berkdb}" != "yes" ; then - if test "${have_libdb}" = "yes" ; then - with_database_berkdb=yes - else - test -n "$silent" || echo "checking for dbopen" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { + if test "$with_database_dbm" = "yes" ; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_DBM +EOF +cat >> confdefs.h <<\EOF +#define HAVE_DBM 1 +EOF +} + + test "$need_libdbm" = "yes" && LIBS="$LIBS -ldbm" + else with_database_dbm=no + fi +fi + +if test "$with_database_berkdb" != "no"; then + echo $ac_n "checking for dbopen""... $ac_c" 1>&6 +echo "configure:8606: checking for dbopen" >&5 + +cat > conftest.$ac_ext <<EOF +#line 8609 "configure" +#include "confdefs.h" +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char dbopen(); below. */ +#include <assert.h> +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dbopen(); + +int main() { + /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined (__stub_dbopen) || defined (__stub___dbopen) choke me #else -/* Override any gcc2 internal prototype to avoid an error. */ -extern char dbopen(); dbopen(); +dbopen(); #endif + ; return 0; } EOF -if eval $ac_compile; then - rm -rf conftest* - with_database_berkdb=yes - -else - rm -rf conftest* - with_database_berkdb=no -fi -rm -f conftest* - - fi - fi -fi -test "${with_database_berkdb}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_BERKELEY_DB" -echo "#define" HAVE_BERKELEY_DB "1" >> confdefs.h -DEFS="$DEFS -DHAVE_BERKELEY_DB=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_BERKELEY_DB\${ac_dB}HAVE_BERKELEY_DB\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_BERKELEY_DB\${ac_uB}HAVE_BERKELEY_DB\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_BERKELEY_DB\${ac_eB}HAVE_BERKELEY_DB\${ac_eC}1\${ac_eD} -" -} - - -if test "${with_database_gnudbm}" != "no" ; then - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lgdbm" -ac_have_lib="" -test -n "$silent" || echo "checking for -lgdbm" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; have_libgdbm=yes -else - :; have_libgdbm=no -fi - - test "${have_libgdbm}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_LIBGDBM" -echo "#define" HAVE_LIBGDBM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LIBGDBM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LIBGDBM\${ac_dB}HAVE_LIBGDBM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LIBGDBM\${ac_uB}HAVE_LIBGDBM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LIBGDBM\${ac_eB}HAVE_LIBGDBM\${ac_eC}1\${ac_eD} -" -} - - test -z "${with_database_gnudbm}" && with_database_gnudbm="${have_libgdbm}" -fi -if test "${with_database_gnudbm}" = "yes" ; then - -{ -test -n "$verbose" && \ -echo " defining HAVE_DBM" -echo "#define" HAVE_DBM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_DBM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_DBM\${ac_dB}HAVE_DBM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_DBM\${ac_uB}HAVE_DBM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_DBM\${ac_eB}HAVE_DBM\${ac_eC}1\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining HAVE_GNU_DBM" -echo "#define" HAVE_GNU_DBM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_GNU_DBM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_GNU_DBM\${ac_dB}HAVE_GNU_DBM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_GNU_DBM\${ac_uB}HAVE_GNU_DBM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_GNU_DBM\${ac_eB}HAVE_GNU_DBM\${ac_eC}1\${ac_eD} -" -} - - with_database_dbm=no -fi - -if test "${with_database_dbm}" != "no" ; then - ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -ldbm" -ac_have_lib="" -test -n "$silent" || echo "checking for -ldbm" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; have_libdbm=yes -else - :; have_libdbm=no -fi - - test "${have_libdbm}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_LIBDBM" -echo "#define" HAVE_LIBDBM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_LIBDBM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_LIBDBM\${ac_dB}HAVE_LIBDBM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_LIBDBM\${ac_uB}HAVE_LIBDBM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_LIBDBM\${ac_eB}HAVE_LIBDBM\${ac_eC}1\${ac_eD} -" -} - - if test "${with_database_dbm}" != "yes" ; then - if test "${have_libdbm}" = "yes" ; then - with_database_dbm=yes - else - test -n "$silent" || echo "checking for dbm_open" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -#include <ctype.h> -int main() { return 0; } -int t() { -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined (__stub_dbm_open) || defined (__stub___dbm_open) -choke me -#else +if { (eval echo configure:8632: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_dbopen=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_dbopen=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'dbopen`\" = yes"; then + echo "$ac_t""yes" 1>&6 + with_database_berkdb=yes need_libdb=no +else + echo "$ac_t""no" 1>&6 +fi + + if test "$need_libdb" != "no"; then + +echo $ac_n "checking for dbopen in -ldb""... $ac_c" 1>&6 +echo "configure:8653: checking for dbopen in -ldb" >&5 +ac_lib_var=`echo db'_'dbopen | sed 'y%./+-%__p_%'` + +xe_check_libs=" -ldb " +cat > conftest.$ac_ext <<EOF +#line 8658 "configure" +#include "confdefs.h" /* Override any gcc2 internal prototype to avoid an error. */ -extern char dbm_open(); dbm_open(); -#endif +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char dbopen(); + +int main() { +dbopen() ; return 0; } EOF -if eval $ac_compile; then - rm -rf conftest* - with_database_dbm=yes - -else - rm -rf conftest* - with_database_dbm=no -fi -rm -f conftest* +if { (eval echo configure:8669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + with_database_berkdb=yes need_libdb=yes +else + echo "$ac_t""no" 1>&6 +fi + fi + if test "$with_database_berkdb" = "yes"; then + for path in "db/db.h" "db.h"; do +cat > conftest.$ac_ext <<EOF +#line 8693 "configure" +#include "confdefs.h" +#ifdef HAVE_INTTYPES_H +#define __BIT_TYPES_DEFINED__ +#include <inttypes.h> +typedef uint8_t u_int8_t; +typedef uint16_t u_int16_t; +typedef uint32_t u_int32_t; +#ifdef WE_DONT_NEED_QUADS +typedef uint64_t u_int64_t; +#endif +#endif +#include <$path> + +int main() { + +; return 0; } +EOF +if { (eval echo configure:8711: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + db_h_path="$path"; break +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 +fi +rm -f conftest* + done + test -z "$db_h_path" && with_database_berkdb=no fi -fi -test "${with_database_dbm}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_DBM" -echo "#define" HAVE_DBM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_DBM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_DBM\${ac_dB}HAVE_DBM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_DBM\${ac_uB}HAVE_DBM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_DBM\${ac_eB}HAVE_DBM\${ac_eC}1\${ac_eD} -" -} - - - -############################################################################ -# # -# Substitute into Makefile and config.h # -# # -############################################################################ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -{ -test -n "$verbose" && \ -echo " defining" EMACS_VERSION to be ""${version}"" -echo "#define" EMACS_VERSION ""${version}"" >> confdefs.h -DEFS="$DEFS -DEMACS_VERSION="${version}"" -ac_sed_defs="${ac_sed_defs}\${ac_dA}EMACS_VERSION\${ac_dB}EMACS_VERSION\${ac_dC}"${version}"\${ac_dD} -\${ac_uA}EMACS_VERSION\${ac_uB}EMACS_VERSION\${ac_uC}"${version}"\${ac_uD} -\${ac_eA}EMACS_VERSION\${ac_eB}EMACS_VERSION\${ac_eC}"${version}"\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" EMACS_CONFIGURATION to be ""\"${canonical}\""" -echo "#define" EMACS_CONFIGURATION ""\"${canonical}\""" >> confdefs.h -DEFS="$DEFS -DEMACS_CONFIGURATION="\"${canonical}\""" -ac_sed_defs="${ac_sed_defs}\${ac_dA}EMACS_CONFIGURATION\${ac_dB}EMACS_CONFIGURATION\${ac_dC}"\"${canonical}\""\${ac_dD} -\${ac_uA}EMACS_CONFIGURATION\${ac_uB}EMACS_CONFIGURATION\${ac_uC}"\"${canonical}\""\${ac_uD} -\${ac_eA}EMACS_CONFIGURATION\${ac_eB}EMACS_CONFIGURATION\${ac_eC}"\"${canonical}\""\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" config_machfile to be ""\"${machfile}\""" -echo "#define" config_machfile ""\"${machfile}\""" >> confdefs.h -DEFS="$DEFS -Dconfig_machfile="\"${machfile}\""" -ac_sed_defs="${ac_sed_defs}\${ac_dA}config_machfile\${ac_dB}config_machfile\${ac_dC}"\"${machfile}\""\${ac_dD} -\${ac_uA}config_machfile\${ac_uB}config_machfile\${ac_uC}"\"${machfile}\""\${ac_uD} -\${ac_eA}config_machfile\${ac_eB}config_machfile\${ac_eC}"\"${machfile}\""\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" config_opsysfile to be ""\"${opsysfile}\""" -echo "#define" config_opsysfile ""\"${opsysfile}\""" >> confdefs.h -DEFS="$DEFS -Dconfig_opsysfile="\"${opsysfile}\""" -ac_sed_defs="${ac_sed_defs}\${ac_dA}config_opsysfile\${ac_dB}config_opsysfile\${ac_dC}"\"${opsysfile}\""\${ac_dD} -\${ac_uA}config_opsysfile\${ac_uB}config_opsysfile\${ac_uC}"\"${opsysfile}\""\${ac_uD} -\${ac_eA}config_opsysfile\${ac_eB}config_opsysfile\${ac_eC}"\"${opsysfile}\""\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" LD_SWITCH_X_SITE to be "${LD_SWITCH_X_SITE}" -echo "#define" LD_SWITCH_X_SITE "${LD_SWITCH_X_SITE}" >> confdefs.h -DEFS="$DEFS -DLD_SWITCH_X_SITE=${LD_SWITCH_X_SITE}" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LD_SWITCH_X_SITE\${ac_dB}LD_SWITCH_X_SITE\${ac_dC}${LD_SWITCH_X_SITE}\${ac_dD} -\${ac_uA}LD_SWITCH_X_SITE\${ac_uB}LD_SWITCH_X_SITE\${ac_uC}${LD_SWITCH_X_SITE}\${ac_uD} -\${ac_eA}LD_SWITCH_X_SITE\${ac_eB}LD_SWITCH_X_SITE\${ac_eC}${LD_SWITCH_X_SITE}\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" LD_SWITCH_X_SITE_AUX to be "${LD_SWITCH_X_SITE_AUX}" -echo "#define" LD_SWITCH_X_SITE_AUX "${LD_SWITCH_X_SITE_AUX}" >> confdefs.h -DEFS="$DEFS -DLD_SWITCH_X_SITE_AUX=${LD_SWITCH_X_SITE_AUX}" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LD_SWITCH_X_SITE_AUX\${ac_dB}LD_SWITCH_X_SITE_AUX\${ac_dC}${LD_SWITCH_X_SITE_AUX}\${ac_dD} -\${ac_uA}LD_SWITCH_X_SITE_AUX\${ac_uB}LD_SWITCH_X_SITE_AUX\${ac_uC}${LD_SWITCH_X_SITE_AUX}\${ac_uD} -\${ac_eA}LD_SWITCH_X_SITE_AUX\${ac_eB}LD_SWITCH_X_SITE_AUX\${ac_eC}${LD_SWITCH_X_SITE_AUX}\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" C_SWITCH_X_SITE to be "${C_SWITCH_X_SITE}" -echo "#define" C_SWITCH_X_SITE "${C_SWITCH_X_SITE}" >> confdefs.h -DEFS="$DEFS -DC_SWITCH_X_SITE=${C_SWITCH_X_SITE}" -ac_sed_defs="${ac_sed_defs}\${ac_dA}C_SWITCH_X_SITE\${ac_dB}C_SWITCH_X_SITE\${ac_dC}${C_SWITCH_X_SITE}\${ac_dD} -\${ac_uA}C_SWITCH_X_SITE\${ac_uB}C_SWITCH_X_SITE\${ac_uC}${C_SWITCH_X_SITE}\${ac_uD} -\${ac_eA}C_SWITCH_X_SITE\${ac_eB}C_SWITCH_X_SITE\${ac_eC}${C_SWITCH_X_SITE}\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" LD_SWITCH_SITE to be "${LD_SWITCH_SITE}" -echo "#define" LD_SWITCH_SITE "${LD_SWITCH_SITE}" >> confdefs.h -DEFS="$DEFS -DLD_SWITCH_SITE=${LD_SWITCH_SITE}" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LD_SWITCH_SITE\${ac_dB}LD_SWITCH_SITE\${ac_dC}${LD_SWITCH_SITE}\${ac_dD} -\${ac_uA}LD_SWITCH_SITE\${ac_uB}LD_SWITCH_SITE\${ac_uC}${LD_SWITCH_SITE}\${ac_uD} -\${ac_eA}LD_SWITCH_SITE\${ac_eB}LD_SWITCH_SITE\${ac_eC}${LD_SWITCH_SITE}\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" C_SWITCH_SITE to be "${C_SWITCH_SITE}" -echo "#define" C_SWITCH_SITE "${C_SWITCH_SITE}" >> confdefs.h -DEFS="$DEFS -DC_SWITCH_SITE=${C_SWITCH_SITE}" -ac_sed_defs="${ac_sed_defs}\${ac_dA}C_SWITCH_SITE\${ac_dB}C_SWITCH_SITE\${ac_dC}${C_SWITCH_SITE}\${ac_dD} -\${ac_uA}C_SWITCH_SITE\${ac_uB}C_SWITCH_SITE\${ac_uC}${C_SWITCH_SITE}\${ac_uD} -\${ac_eA}C_SWITCH_SITE\${ac_eB}C_SWITCH_SITE\${ac_eC}${C_SWITCH_SITE}\${ac_eD} -" -} - - -{ -test -n "$verbose" && \ -echo " defining" UNEXEC_SRC to be "${UNEXEC_SRC}" -echo "#define" UNEXEC_SRC "${UNEXEC_SRC}" >> confdefs.h -DEFS="$DEFS -DUNEXEC_SRC=${UNEXEC_SRC}" -ac_sed_defs="${ac_sed_defs}\${ac_dA}UNEXEC_SRC\${ac_dB}UNEXEC_SRC\${ac_dC}${UNEXEC_SRC}\${ac_dD} -\${ac_uA}UNEXEC_SRC\${ac_uB}UNEXEC_SRC\${ac_uC}${UNEXEC_SRC}\${ac_uD} -\${ac_eA}UNEXEC_SRC\${ac_eB}UNEXEC_SRC\${ac_eC}${UNEXEC_SRC}\${ac_eD} -" -} - - - -test -n "${puresize}" && -{ -test -n "$verbose" && \ -echo " defining" RAW_PURESIZE to be "${puresize}" -echo "#define" RAW_PURESIZE "${puresize}" >> confdefs.h -DEFS="$DEFS -DRAW_PURESIZE=${puresize}" -ac_sed_defs="${ac_sed_defs}\${ac_dA}RAW_PURESIZE\${ac_dB}RAW_PURESIZE\${ac_dC}${puresize}\${ac_dD} -\${ac_uA}RAW_PURESIZE\${ac_uB}RAW_PURESIZE\${ac_uC}${puresize}\${ac_uD} -\${ac_eA}RAW_PURESIZE\${ac_eB}RAW_PURESIZE\${ac_eC}${puresize}\${ac_eD} -" -} - -test "${HAVE_X_WINDOWS}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_X_WINDOWS" -echo "#define" HAVE_X_WINDOWS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_X_WINDOWS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_X_WINDOWS\${ac_dB}HAVE_X_WINDOWS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_X_WINDOWS\${ac_uB}HAVE_X_WINDOWS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_X_WINDOWS\${ac_eB}HAVE_X_WINDOWS\${ac_eC}1\${ac_eD} -" -} - -test "${HAVE_XFREE386}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_XFREE386" -echo "#define" HAVE_XFREE386 "1" >> confdefs.h -DEFS="$DEFS -DHAVE_XFREE386=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_XFREE386\${ac_dB}HAVE_XFREE386\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_XFREE386\${ac_uB}HAVE_XFREE386\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_XFREE386\${ac_eB}HAVE_XFREE386\${ac_eC}1\${ac_eD} -" -} - - -if test "${GNU_MALLOC}" = yes; then -{ -test -n "$verbose" && \ -echo " defining GNU_MALLOC" -echo "#define" GNU_MALLOC "1" >> confdefs.h -DEFS="$DEFS -DGNU_MALLOC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}GNU_MALLOC\${ac_dB}GNU_MALLOC\${ac_dC}1\${ac_dD} -\${ac_uA}GNU_MALLOC\${ac_uB}GNU_MALLOC\${ac_uC}1\${ac_uD} -\${ac_eA}GNU_MALLOC\${ac_eB}GNU_MALLOC\${ac_eC}1\${ac_eD} -" -} - -elif test "${use_system_malloc}" = yes; then -{ -test -n "$verbose" && \ -echo " defining USE_SYSTEM_MALLOC" -echo "#define" USE_SYSTEM_MALLOC "1" >> confdefs.h -DEFS="$DEFS -DUSE_SYSTEM_MALLOC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}USE_SYSTEM_MALLOC\${ac_dB}USE_SYSTEM_MALLOC\${ac_dC}1\${ac_dD} -\${ac_uA}USE_SYSTEM_MALLOC\${ac_uB}USE_SYSTEM_MALLOC\${ac_uC}1\${ac_uD} -\${ac_eA}USE_SYSTEM_MALLOC\${ac_eB}USE_SYSTEM_MALLOC\${ac_eC}1\${ac_eD} -" -} - -fi -test "${rel_alloc}" = yes && -{ -test -n "$verbose" && \ -echo " defining REL_ALLOC" -echo "#define" REL_ALLOC "1" >> confdefs.h -DEFS="$DEFS -DREL_ALLOC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}REL_ALLOC\${ac_dB}REL_ALLOC\${ac_dC}1\${ac_dD} -\${ac_uA}REL_ALLOC\${ac_uB}REL_ALLOC\${ac_uC}1\${ac_uD} -\${ac_eA}REL_ALLOC\${ac_eB}REL_ALLOC\${ac_eC}1\${ac_eD} -" -} - -test "${LISP_FLOAT_TYPE}" = yes && -{ -test -n "$verbose" && \ -echo " defining LISP_FLOAT_TYPE" -echo "#define" LISP_FLOAT_TYPE "1" >> confdefs.h -DEFS="$DEFS -DLISP_FLOAT_TYPE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LISP_FLOAT_TYPE\${ac_dB}LISP_FLOAT_TYPE\${ac_dC}1\${ac_dD} -\${ac_uA}LISP_FLOAT_TYPE\${ac_uB}LISP_FLOAT_TYPE\${ac_uC}1\${ac_uD} -\${ac_eA}LISP_FLOAT_TYPE\${ac_eB}LISP_FLOAT_TYPE\${ac_eC}1\${ac_eD} -" -} - -test "${with_motif}" = yes && -{ -test -n "$verbose" && \ -echo " defining LWLIB_USES_MOTIF" -echo "#define" LWLIB_USES_MOTIF "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_USES_MOTIF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_USES_MOTIF\${ac_dB}LWLIB_USES_MOTIF\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_USES_MOTIF\${ac_uB}LWLIB_USES_MOTIF\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_USES_MOTIF\${ac_eB}LWLIB_USES_MOTIF\${ac_eC}1\${ac_eD} -" -} - -test "${with_athena}" = yes && -{ -test -n "$verbose" && \ -echo " defining LWLIB_USES_ATHENA" -echo "#define" LWLIB_USES_ATHENA "1" >> confdefs.h -DEFS="$DEFS -DLWLIB_USES_ATHENA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}LWLIB_USES_ATHENA\${ac_dB}LWLIB_USES_ATHENA\${ac_dC}1\${ac_dD} -\${ac_uA}LWLIB_USES_ATHENA\${ac_uB}LWLIB_USES_ATHENA\${ac_uC}1\${ac_uD} -\${ac_eA}LWLIB_USES_ATHENA\${ac_eB}LWLIB_USES_ATHENA\${ac_eC}1\${ac_eD} -" -} - -test "${with_toolbars}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_TOOLBARS" -echo "#define" HAVE_TOOLBARS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TOOLBARS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TOOLBARS\${ac_dB}HAVE_TOOLBARS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TOOLBARS\${ac_uB}HAVE_TOOLBARS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TOOLBARS\${ac_eB}HAVE_TOOLBARS\${ac_eC}1\${ac_eD} -" -} - -test "${with_tty}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_TTY" -echo "#define" HAVE_TTY "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TTY=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TTY\${ac_dB}HAVE_TTY\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TTY\${ac_uB}HAVE_TTY\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TTY\${ac_eB}HAVE_TTY\${ac_eC}1\${ac_eD} -" -} - -test "${with_tooltalk}" = yes && -{ -test -n "$verbose" && \ -echo " defining TOOLTALK" -echo "#define" TOOLTALK "1" >> confdefs.h -DEFS="$DEFS -DTOOLTALK=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}TOOLTALK\${ac_dB}TOOLTALK\${ac_dC}1\${ac_dD} -\${ac_uA}TOOLTALK\${ac_uB}TOOLTALK\${ac_uC}1\${ac_uD} -\${ac_eA}TOOLTALK\${ac_eB}TOOLTALK\${ac_eC}1\${ac_eD} -" -} - -test "${with_i18n3}" = yes && -{ -test -n "$verbose" && \ -echo " defining I18N3" -echo "#define" I18N3 "1" >> confdefs.h -DEFS="$DEFS -DI18N3=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}I18N3\${ac_dB}I18N3\${ac_dC}1\${ac_dD} -\${ac_uA}I18N3\${ac_uB}I18N3\${ac_uC}1\${ac_uD} -\${ac_eA}I18N3\${ac_eB}I18N3\${ac_eC}1\${ac_eD} -" -} - -test "${with_mule}" = yes && -{ -test -n "$verbose" && \ -echo " defining MULE" -echo "#define" MULE "1" >> confdefs.h -DEFS="$DEFS -DMULE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}MULE\${ac_dB}MULE\${ac_dC}1\${ac_dD} -\${ac_uA}MULE\${ac_uB}MULE\${ac_uC}1\${ac_uD} -\${ac_eA}MULE\${ac_eB}MULE\${ac_eC}1\${ac_eD} -" -} - -test "${with_canna}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_CANNA" -echo "#define" HAVE_CANNA "1" >> confdefs.h -DEFS="$DEFS -DHAVE_CANNA=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_CANNA\${ac_dB}HAVE_CANNA\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_CANNA\${ac_uB}HAVE_CANNA\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_CANNA\${ac_eB}HAVE_CANNA\${ac_eC}1\${ac_eD} -" -} - -test "${with_wnn}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_WNN" -echo "#define" HAVE_WNN "1" >> confdefs.h -DEFS="$DEFS -DHAVE_WNN=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_WNN\${ac_dB}HAVE_WNN\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_WNN\${ac_uB}HAVE_WNN\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_WNN\${ac_eB}HAVE_WNN\${ac_eC}1\${ac_eD} -" -} - -test "${with_wnn6}" = yes && -{ -test -n "$verbose" && \ -echo " defining WNN6" -echo "#define" WNN6 "1" >> confdefs.h -DEFS="$DEFS -DWNN6=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}WNN6\${ac_dB}WNN6\${ac_dC}1\${ac_dD} -\${ac_uA}WNN6\${ac_uB}WNN6\${ac_uC}1\${ac_uD} -\${ac_eA}WNN6\${ac_eB}WNN6\${ac_eC}1\${ac_eD} -" -} - -test "${with_mock}" = yes && -{ -test -n "$verbose" && \ -echo " defining MOCKLISP_SUPPORT" -echo "#define" MOCKLISP_SUPPORT "1" >> confdefs.h -DEFS="$DEFS -DMOCKLISP_SUPPORT=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}MOCKLISP_SUPPORT\${ac_dB}MOCKLISP_SUPPORT\${ac_dC}1\${ac_dD} -\${ac_uA}MOCKLISP_SUPPORT\${ac_uB}MOCKLISP_SUPPORT\${ac_uC}1\${ac_uD} -\${ac_eA}MOCKLISP_SUPPORT\${ac_eB}MOCKLISP_SUPPORT\${ac_eC}1\${ac_eD} -" -} - -test "${with_sparcworks}" = yes && -{ -test -n "$verbose" && \ -echo " defining SUNPRO" -echo "#define" SUNPRO "1" >> confdefs.h -DEFS="$DEFS -DSUNPRO=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}SUNPRO\${ac_dB}SUNPRO\${ac_dC}1\${ac_dD} -\${ac_uA}SUNPRO\${ac_uB}SUNPRO\${ac_uC}1\${ac_uD} -\${ac_eA}SUNPRO\${ac_eB}SUNPRO\${ac_eC}1\${ac_eD} -" -} - -test "${usage_tracking}" = yes && -{ -test -n "$verbose" && \ -echo " defining USAGE_TRACKING" -echo "#define" USAGE_TRACKING "1" >> confdefs.h -DEFS="$DEFS -DUSAGE_TRACKING=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}USAGE_TRACKING\${ac_dB}USAGE_TRACKING\${ac_dC}1\${ac_dD} -\${ac_uA}USAGE_TRACKING\${ac_uB}USAGE_TRACKING\${ac_uC}1\${ac_uD} -\${ac_eA}USAGE_TRACKING\${ac_eB}USAGE_TRACKING\${ac_eC}1\${ac_eD} -" -} - -test "${need_dynodump}" = yes && -{ -test -n "$verbose" && \ -echo " defining DYNODUMP" -echo "#define" DYNODUMP "1" >> confdefs.h -DEFS="$DEFS -DDYNODUMP=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}DYNODUMP\${ac_dB}DYNODUMP\${ac_dC}1\${ac_dD} -\${ac_uA}DYNODUMP\${ac_uB}DYNODUMP\${ac_uC}1\${ac_uD} -\${ac_eA}DYNODUMP\${ac_eB}DYNODUMP\${ac_eC}1\${ac_eD} -" -} - -test "${need_xildoff}" = yes && -{ -test -n "$verbose" && \ -echo " defining NEED_XILDOFF" -echo "#define" NEED_XILDOFF "1" >> confdefs.h -DEFS="$DEFS -DNEED_XILDOFF=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NEED_XILDOFF\${ac_dB}NEED_XILDOFF\${ac_dC}1\${ac_dD} -\${ac_uA}NEED_XILDOFF\${ac_uB}NEED_XILDOFF\${ac_uC}1\${ac_uD} -\${ac_eA}NEED_XILDOFF\${ac_eB}NEED_XILDOFF\${ac_eC}1\${ac_eD} -" -} - -test "${with_gcc}" = yes && -{ -test -n "$verbose" && \ -echo " defining USE_GCC" -echo "#define" USE_GCC "1" >> confdefs.h -DEFS="$DEFS -DUSE_GCC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}USE_GCC\${ac_dB}USE_GCC\${ac_dC}1\${ac_dD} -\${ac_uA}USE_GCC\${ac_uB}USE_GCC\${ac_uC}1\${ac_uD} -\${ac_eA}USE_GCC\${ac_eB}USE_GCC\${ac_eC}1\${ac_eD} -" -} - -test "${with_lcc}" = yes && -{ -test -n "$verbose" && \ -echo " defining USE_LCC" -echo "#define" USE_LCC "1" >> confdefs.h -DEFS="$DEFS -DUSE_LCC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}USE_LCC\${ac_dB}USE_LCC\${ac_dC}1\${ac_dD} -\${ac_uA}USE_LCC\${ac_uB}USE_LCC\${ac_uC}1\${ac_uD} -\${ac_eA}USE_LCC\${ac_eB}USE_LCC\${ac_eC}1\${ac_eD} -" -} - -test "${with_socks}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_SOCKS" -echo "#define" HAVE_SOCKS "1" >> confdefs.h -DEFS="$DEFS -DHAVE_SOCKS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_SOCKS\${ac_dB}HAVE_SOCKS\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_SOCKS\${ac_uB}HAVE_SOCKS\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_SOCKS\${ac_eB}HAVE_SOCKS\${ac_eC}1\${ac_eD} -" -} - -test "${with_term}" = yes && -{ -test -n "$verbose" && \ -echo " defining HAVE_TERM" -echo "#define" HAVE_TERM "1" >> confdefs.h -DEFS="$DEFS -DHAVE_TERM=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_TERM\${ac_dB}HAVE_TERM\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_TERM\${ac_uB}HAVE_TERM\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_TERM\${ac_eB}HAVE_TERM\${ac_eC}1\${ac_eD} -" -} - -test "${external_widget}" = yes && -{ -test -n "$verbose" && \ -echo " defining EXTERNAL_WIDGET" -echo "#define" EXTERNAL_WIDGET "1" >> confdefs.h -DEFS="$DEFS -DEXTERNAL_WIDGET=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}EXTERNAL_WIDGET\${ac_dB}EXTERNAL_WIDGET\${ac_dC}1\${ac_dD} -\${ac_uA}EXTERNAL_WIDGET\${ac_uB}EXTERNAL_WIDGET\${ac_uC}1\${ac_uD} -\${ac_eA}EXTERNAL_WIDGET\${ac_eB}EXTERNAL_WIDGET\${ac_eC}1\${ac_eD} -" -} - -test "${with_gnu_make}" = yes && -{ -test -n "$verbose" && \ -echo " defining USE_GNU_MAKE" -echo "#define" USE_GNU_MAKE "1" >> confdefs.h -DEFS="$DEFS -DUSE_GNU_MAKE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}USE_GNU_MAKE\${ac_dB}USE_GNU_MAKE\${ac_dC}1\${ac_dD} -\${ac_uA}USE_GNU_MAKE\${ac_uB}USE_GNU_MAKE\${ac_uC}1\${ac_uD} -\${ac_eA}USE_GNU_MAKE\${ac_eB}USE_GNU_MAKE\${ac_eC}1\${ac_eD} -" -} - -test "${no_doc_file}" = yes && -{ -test -n "$verbose" && \ -echo " defining NO_DOC_FILE" -echo "#define" NO_DOC_FILE "1" >> confdefs.h -DEFS="$DEFS -DNO_DOC_FILE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NO_DOC_FILE\${ac_dB}NO_DOC_FILE\${ac_dC}1\${ac_dD} -\${ac_uA}NO_DOC_FILE\${ac_uB}NO_DOC_FILE\${ac_uC}1\${ac_uD} -\${ac_eA}NO_DOC_FILE\${ac_eB}NO_DOC_FILE\${ac_eC}1\${ac_eD} -" -} - -test "${const_is_losing}" = yes && -{ -test -n "$verbose" && \ -echo " defining CONST_IS_LOSING" -echo "#define" CONST_IS_LOSING "1" >> confdefs.h -DEFS="$DEFS -DCONST_IS_LOSING=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}CONST_IS_LOSING\${ac_dB}CONST_IS_LOSING\${ac_dC}1\${ac_dD} -\${ac_uA}CONST_IS_LOSING\${ac_uB}CONST_IS_LOSING\${ac_uC}1\${ac_uD} -\${ac_eA}CONST_IS_LOSING\${ac_eB}CONST_IS_LOSING\${ac_eC}1\${ac_eD} -" -} - -test "${use_assertions}" = yes && -{ -test -n "$verbose" && \ -echo " defining USE_ASSERTIONS" -echo "#define" USE_ASSERTIONS "1" >> confdefs.h -DEFS="$DEFS -DUSE_ASSERTIONS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}USE_ASSERTIONS\${ac_dB}USE_ASSERTIONS\${ac_dC}1\${ac_dD} -\${ac_uA}USE_ASSERTIONS\${ac_uB}USE_ASSERTIONS\${ac_uC}1\${ac_uD} -\${ac_eA}USE_ASSERTIONS\${ac_eB}USE_ASSERTIONS\${ac_eC}1\${ac_eD} -" -} - -test "${debug}" = yes && -{ -test -n "$verbose" && \ -echo " defining DEBUG_XEMACS" -echo "#define" DEBUG_XEMACS "1" >> confdefs.h -DEFS="$DEFS -DDEBUG_XEMACS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}DEBUG_XEMACS\${ac_dB}DEBUG_XEMACS\${ac_dC}1\${ac_dD} -\${ac_uA}DEBUG_XEMACS\${ac_uB}DEBUG_XEMACS\${ac_uC}1\${ac_uD} -\${ac_eA}DEBUG_XEMACS\${ac_eB}DEBUG_XEMACS\${ac_eC}1\${ac_eD} -" -} - -test "${quantify}" = yes && -{ -test -n "$verbose" && \ -echo " defining QUANTIFY" -echo "#define" QUANTIFY "1" >> confdefs.h -DEFS="$DEFS -DQUANTIFY=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}QUANTIFY\${ac_dB}QUANTIFY\${ac_dC}1\${ac_dD} -\${ac_uA}QUANTIFY\${ac_uB}QUANTIFY\${ac_uC}1\${ac_uD} -\${ac_eA}QUANTIFY\${ac_eB}QUANTIFY\${ac_eC}1\${ac_eD} -" -} - -test "${memory_usage_stats}" = yes && -{ -test -n "$verbose" && \ -echo " defining MEMORY_USAGE_STATS" -echo "#define" MEMORY_USAGE_STATS "1" >> confdefs.h -DEFS="$DEFS -DMEMORY_USAGE_STATS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}MEMORY_USAGE_STATS\${ac_dB}MEMORY_USAGE_STATS\${ac_dC}1\${ac_dD} -\${ac_uA}MEMORY_USAGE_STATS\${ac_uB}MEMORY_USAGE_STATS\${ac_uC}1\${ac_uD} -\${ac_eA}MEMORY_USAGE_STATS\${ac_eB}MEMORY_USAGE_STATS\${ac_eC}1\${ac_eD} -" -} - -test "${with_pop}" = yes && -{ -test -n "$verbose" && \ -echo " defining MAIL_USE_POP" -echo "#define" MAIL_USE_POP "1" >> confdefs.h -DEFS="$DEFS -DMAIL_USE_POP=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}MAIL_USE_POP\${ac_dB}MAIL_USE_POP\${ac_dC}1\${ac_dD} -\${ac_uA}MAIL_USE_POP\${ac_uB}MAIL_USE_POP\${ac_uC}1\${ac_uD} -\${ac_eA}MAIL_USE_POP\${ac_eB}MAIL_USE_POP\${ac_eC}1\${ac_eD} -" -} - -test "${with_kerberos}" = yes && -{ -test -n "$verbose" && \ -echo " defining KERBEROS" -echo "#define" KERBEROS "1" >> confdefs.h -DEFS="$DEFS -DKERBEROS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}KERBEROS\${ac_dB}KERBEROS\${ac_dC}1\${ac_dD} -\${ac_uA}KERBEROS\${ac_uB}KERBEROS\${ac_uC}1\${ac_uD} -\${ac_eA}KERBEROS\${ac_eB}KERBEROS\${ac_eC}1\${ac_eD} -" -} - -test "${with_hesiod}" = yes && -{ -test -n "$verbose" && \ -echo " defining HESIOD" -echo "#define" HESIOD "1" >> confdefs.h -DEFS="$DEFS -DHESIOD=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HESIOD\${ac_dB}HESIOD\${ac_dC}1\${ac_dD} -\${ac_uA}HESIOD\${ac_uB}HESIOD\${ac_uC}1\${ac_uD} -\${ac_eA}HESIOD\${ac_eB}HESIOD\${ac_eC}1\${ac_eD} -" -} - - -test "${error_check_extents}" = yes && -{ -test -n "$verbose" && \ -echo " defining ERROR_CHECK_EXTENTS" -echo "#define" ERROR_CHECK_EXTENTS "1" >> confdefs.h -DEFS="$DEFS -DERROR_CHECK_EXTENTS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}ERROR_CHECK_EXTENTS\${ac_dB}ERROR_CHECK_EXTENTS\${ac_dC}1\${ac_dD} -\${ac_uA}ERROR_CHECK_EXTENTS\${ac_uB}ERROR_CHECK_EXTENTS\${ac_uC}1\${ac_uD} -\${ac_eA}ERROR_CHECK_EXTENTS\${ac_eB}ERROR_CHECK_EXTENTS\${ac_eC}1\${ac_eD} -" -} - -test "${error_check_typecheck}" = yes && -{ -test -n "$verbose" && \ -echo " defining ERROR_CHECK_TYPECHECK" -echo "#define" ERROR_CHECK_TYPECHECK "1" >> confdefs.h -DEFS="$DEFS -DERROR_CHECK_TYPECHECK=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}ERROR_CHECK_TYPECHECK\${ac_dB}ERROR_CHECK_TYPECHECK\${ac_dC}1\${ac_dD} -\${ac_uA}ERROR_CHECK_TYPECHECK\${ac_uB}ERROR_CHECK_TYPECHECK\${ac_uC}1\${ac_uD} -\${ac_eA}ERROR_CHECK_TYPECHECK\${ac_eB}ERROR_CHECK_TYPECHECK\${ac_eC}1\${ac_eD} -" -} - -test "${error_check_bufpos}" = yes && -{ -test -n "$verbose" && \ -echo " defining ERROR_CHECK_BUFPOS" -echo "#define" ERROR_CHECK_BUFPOS "1" >> confdefs.h -DEFS="$DEFS -DERROR_CHECK_BUFPOS=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}ERROR_CHECK_BUFPOS\${ac_dB}ERROR_CHECK_BUFPOS\${ac_dC}1\${ac_dD} -\${ac_uA}ERROR_CHECK_BUFPOS\${ac_uB}ERROR_CHECK_BUFPOS\${ac_uC}1\${ac_uD} -\${ac_eA}ERROR_CHECK_BUFPOS\${ac_eB}ERROR_CHECK_BUFPOS\${ac_eC}1\${ac_eD} -" -} - -test "${error_check_gc}" = yes && -{ -test -n "$verbose" && \ -echo " defining ERROR_CHECK_GC" -echo "#define" ERROR_CHECK_GC "1" >> confdefs.h -DEFS="$DEFS -DERROR_CHECK_GC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}ERROR_CHECK_GC\${ac_dB}ERROR_CHECK_GC\${ac_dC}1\${ac_dD} -\${ac_uA}ERROR_CHECK_GC\${ac_uB}ERROR_CHECK_GC\${ac_uC}1\${ac_uD} -\${ac_eA}ERROR_CHECK_GC\${ac_eB}ERROR_CHECK_GC\${ac_eC}1\${ac_eD} -" -} - -test "${error_check_malloc}" = yes && -{ -test -n "$verbose" && \ -echo " defining ERROR_CHECK_MALLOC" -echo "#define" ERROR_CHECK_MALLOC "1" >> confdefs.h -DEFS="$DEFS -DERROR_CHECK_MALLOC=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}ERROR_CHECK_MALLOC\${ac_dB}ERROR_CHECK_MALLOC\${ac_dC}1\${ac_dD} -\${ac_uA}ERROR_CHECK_MALLOC\${ac_uB}ERROR_CHECK_MALLOC\${ac_uC}1\${ac_uD} -\${ac_eA}ERROR_CHECK_MALLOC\${ac_eB}ERROR_CHECK_MALLOC\${ac_eC}1\${ac_eD} -" -} - - -if test "${with_energize}" = yes; then + if test "$with_database_berkdb" = "yes"; then + { test "$extra_verbose" = "yes" && cat << EOF + Defining DB_H_PATH = "$db_h_path" +EOF +cat >> confdefs.h <<EOF +#define DB_H_PATH "$db_h_path" +EOF +} + + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_BERKELEY_DB +EOF +cat >> confdefs.h <<\EOF +#define HAVE_BERKELEY_DB 1 +EOF +} + + test "$need_libdb" = "yes" && LIBS="$LIBS -ldb" + else with_database_berkdb=no + fi +fi + +if test "$with_database_gnudbm" = "yes" -o \ + "$with_database_dbm" = "yes" -o \ + "$with_database_berkdb" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_DATABASE +EOF +cat >> confdefs.h <<\EOF +#define HAVE_DATABASE 1 +EOF +} + + extra_objs="$extra_objs database.o" +fi + +if test "$with_socks" = "yes"; then + +echo $ac_n "checking for SOCKSinit in -lsocks""... $ac_c" 1>&6 +echo "configure:8761: checking for SOCKSinit in -lsocks" >&5 +ac_lib_var=`echo socks'_'SOCKSinit | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lsocks " +cat > conftest.$ac_ext <<EOF +#line 8766 "configure" +#include "confdefs.h" +/* Override any gcc2 internal prototype to avoid an error. */ +/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char SOCKSinit(); + +int main() { +SOCKSinit() +; return 0; } +EOF +if { (eval echo configure:8777: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 + ac_tr_lib=HAVE_LIB`echo socks | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + { test "$extra_verbose" = "yes" && cat << EOF + Defining $ac_tr_lib +EOF +cat >> confdefs.h <<EOF +#define $ac_tr_lib 1 +EOF +} + + LIBS="-lsocks $LIBS" + +else + echo "$ac_t""no" 1>&6 +fi + + + test -n "$ac_cv_lib_socks_SOCKSinit" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_SOCKS +EOF +cat >> confdefs.h <<\EOF +#define HAVE_SOCKS 1 +EOF +} + +fi + +if test "$usage_tracking" = "yes"; then + { test "$extra_verbose" = "yes" && cat << \EOF + Defining USAGE_TRACKING +EOF +cat >> confdefs.h <<\EOF +#define USAGE_TRACKING 1 +EOF +} + + LIBS="$LIBS -Bstatic -lut -Bdynamic" +fi + + +if test "$dynamic" = "no"; then add_runtime_path=no +elif test -n "$LD_RUN_PATH"; then add_runtime_path=yes +else case "$canonical" in + *-solaris2.* | *-sgi-irix* ) add_runtime_path=yes ;; + * ) add_runtime_path=no ;; + esac +fi + +if test "$add_runtime_path" = "yes"; then + echo $ac_n "checking "for runtime libraries flag"""... $ac_c" 1>&6 +echo "configure:8841: checking "for runtime libraries flag"" >&5 + dash_r="" + for try_dash_r in "-R" "-R " "-rpath "; do + xe_check_libs="${try_dash_r}/no/such/file-or-directory" + cat > conftest.$ac_ext <<EOF +#line 8846 "configure" +#include "confdefs.h" + +int main() { + +; return 0; } +EOF +if { (eval echo configure:8853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + dash_r="$try_dash_r" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 +fi +rm -f conftest* + xe_check_libs="" + test -n "$dash_r" && break + done + if test -n "$dash_r"; + then echo "$ac_t"""\"${dash_r}\""" 1>&6 + else echo "$ac_t""NONE" 1>&6 + fi +fi + +if test "$add_runtime_path" = "yes" -a -n "$dash_r"; then + ld_switch_site="`echo $ld_switch_site | sed \"s/${dash_r}[^ ]*//\"`" + ld_switch_x_site="`echo $ld_switch_x_site | sed \"s/${dash_r}[^ ]*//\"`" -{ -test -n "$verbose" && \ -echo " defining ENERGIZE" -echo "#define" ENERGIZE "1" >> confdefs.h -DEFS="$DEFS -DENERGIZE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}ENERGIZE\${ac_dB}ENERGIZE\${ac_dC}1\${ac_dD} -\${ac_uA}ENERGIZE\${ac_uB}ENERGIZE\${ac_uC}1\${ac_uD} -\${ac_eA}ENERGIZE\${ac_eB}ENERGIZE\${ac_eC}1\${ac_eD} -" -} - - test "${energize_version}" = "2.X" && -{ -test -n "$verbose" && \ -echo " defining ENERGIZE_2" -echo "#define" ENERGIZE_2 "1" >> confdefs.h -DEFS="$DEFS -DENERGIZE_2=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}ENERGIZE_2\${ac_dB}ENERGIZE_2\${ac_dC}1\${ac_dD} -\${ac_uA}ENERGIZE_2\${ac_uB}ENERGIZE_2\${ac_uC}1\${ac_uD} -\${ac_eA}ENERGIZE_2\${ac_eB}ENERGIZE_2\${ac_eC}1\${ac_eD} -" -} - - test "${energize_version}" = "3.X" && -{ -test -n "$verbose" && \ -echo " defining ENERGIZE_3" -echo "#define" ENERGIZE_3 "1" >> confdefs.h -DEFS="$DEFS -DENERGIZE_3=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}ENERGIZE_3\${ac_dB}ENERGIZE_3\${ac_dC}1\${ac_dD} -\${ac_uA}ENERGIZE_3\${ac_uB}ENERGIZE_3\${ac_uC}1\${ac_uD} -\${ac_eA}ENERGIZE_3\${ac_eB}ENERGIZE_3\${ac_eC}1\${ac_eD} -" -} - -fi - -test "${with_sound}" = "native" -o "${with_sound}" = "both" && -{ -test -n "$verbose" && \ -echo " defining HAVE_NATIVE_SOUND" -echo "#define" HAVE_NATIVE_SOUND "1" >> confdefs.h -DEFS="$DEFS -DHAVE_NATIVE_SOUND=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_NATIVE_SOUND\${ac_dB}HAVE_NATIVE_SOUND\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_NATIVE_SOUND\${ac_uB}HAVE_NATIVE_SOUND\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_NATIVE_SOUND\${ac_eB}HAVE_NATIVE_SOUND\${ac_eC}1\${ac_eD} -" -} - -test "${with_sound}" = "nas" -o "${with_sound}" = "both" && -{ -test -n "$verbose" && \ -echo " defining HAVE_NAS_SOUND" -echo "#define" HAVE_NAS_SOUND "1" >> confdefs.h -DEFS="$DEFS -DHAVE_NAS_SOUND=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}HAVE_NAS_SOUND\${ac_dB}HAVE_NAS_SOUND\${ac_dC}1\${ac_dD} -\${ac_uA}HAVE_NAS_SOUND\${ac_uB}HAVE_NAS_SOUND\${ac_uC}1\${ac_uD} -\${ac_eA}HAVE_NAS_SOUND\${ac_eB}HAVE_NAS_SOUND\${ac_eC}1\${ac_eD} -" -} - -test "${old_nas}" = "true" && -{ -test -n "$verbose" && \ -echo " defining NAS_NO_ERROR_JUMP" -echo "#define" NAS_NO_ERROR_JUMP "1" >> confdefs.h -DEFS="$DEFS -DNAS_NO_ERROR_JUMP=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NAS_NO_ERROR_JUMP\${ac_dB}NAS_NO_ERROR_JUMP\${ac_dC}1\${ac_dD} -\${ac_uA}NAS_NO_ERROR_JUMP\${ac_uB}NAS_NO_ERROR_JUMP\${ac_uC}1\${ac_uD} -\${ac_eA}NAS_NO_ERROR_JUMP\${ac_eB}NAS_NO_ERROR_JUMP\${ac_eC}1\${ac_eD} -" -} - - -test "${use_union_type}" != yes && -{ -test -n "$verbose" && \ -echo " defining NO_UNION_TYPE" -echo "#define" NO_UNION_TYPE "1" >> confdefs.h -DEFS="$DEFS -DNO_UNION_TYPE=1" -ac_sed_defs="${ac_sed_defs}\${ac_dA}NO_UNION_TYPE\${ac_dB}NO_UNION_TYPE\${ac_dC}1\${ac_dD} -\${ac_uA}NO_UNION_TYPE\${ac_uB}NO_UNION_TYPE\${ac_uC}1\${ac_uD} -\${ac_eA}NO_UNION_TYPE\${ac_eB}NO_UNION_TYPE\${ac_eC}1\${ac_eD} -" + if test -n "$LD_RUN_PATH"; then + runpath="$LD_RUN_PATH" + else + runpath="" + for arg in $ld_switch_site $ld_switch_x_site; do + case "$arg" in -L* ) + dir=`echo $arg | sed 's/^-L//'` + if test -n "`ls ${dir}/*.so 2>/dev/null`"; then + test -n "$runpath" && runpath="${runpath}:" + runpath="${runpath}${dir}" + fi + ;; + esac + done + case "$canonical" in *-solaris2.* ) + test "$have_motif" = "yes" && runpath="${runpath}:/opt/SUNWdt/lib" ;; + esac + fi + + if test -n "$runpath"; then + ld_switch_site="$ld_switch_site ${dash_r}${runpath}" + test "$extra_verbose" = "yes" && echo "Setting runpath to $runpath" + fi +fi + +c_switch_general="-DHAVE_CONFIG_H $c_switch_site $c_switch_machine $c_switch_system" +c_switch_window_system="$c_switch_x_site $X_CFLAGS" +c_switch_all="$c_switch_general $c_switch_window_system" +ld_switch_general="$ld_switch_site $ld_switch_machine $ld_switch_system" +ld_switch_window_system="$ld_switch_x_site" +ld_switch_all="$ld_switch_general $ld_switch_window_system" +ld_libs_general="$LIBS $libs_machine $libs_system $libs_standard" +ld_libs_window_system="$X_PRE_LIBS $libs_x $X_EXTRA_LIBS" +ld_libs_all="$ld_libs_window_system $ld_libs_general" + +internal_makefile_list="Makefile" +SUBDIR_MAKEFILES='' +for dir in $MAKE_SUBDIR; do + SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $dir/Makefile" + internal_makefile_list="$internal_makefile_list $dir/Makefile.in" +done + + + +if test "$extra_verbose" = "yes"; then + echo "" + echo "extra_objs = $extra_objs" +echo "c_switch_general = $c_switch_general" +echo "c_switch_window_system = $c_switch_window_system" +echo "c_switch_all = $c_switch_all" +echo "ld_switch_general = $ld_switch_general" +echo "ld_switch_window_system = $ld_switch_window_system" +echo "ld_switch_all = $ld_switch_all" +echo "ld_libs_general = $ld_libs_general" +echo "ld_libs_window_system = $ld_libs_window_system" +echo "ld_libs_all = $ld_libs_all" + echo "" +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining EMACS_VERSION = $version +EOF +cat >> confdefs.h <<EOF +#define EMACS_VERSION $version +EOF +} + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining EMACS_CONFIGURATION = "$canonical" +EOF +cat >> confdefs.h <<EOF +#define EMACS_CONFIGURATION "$canonical" +EOF +} + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining config_machfile = "$machfile" +EOF +cat >> confdefs.h <<EOF +#define config_machfile "$machfile" +EOF +} + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining config_opsysfile = "$opsysfile" +EOF +cat >> confdefs.h <<EOF +#define config_opsysfile "$opsysfile" +EOF +} + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining UNEXEC_SRC = $UNEXEC_SRC +EOF +cat >> confdefs.h <<EOF +#define UNEXEC_SRC $UNEXEC_SRC +EOF +} + + + +null_string="" +{ test "$extra_verbose" = "yes" && cat << EOF + Defining LD_SWITCH_X_SITE = $null_string +EOF +cat >> confdefs.h <<EOF +#define LD_SWITCH_X_SITE $null_string +EOF +} + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining LD_SWITCH_X_SITE_AUX = $null_string +EOF +cat >> confdefs.h <<EOF +#define LD_SWITCH_X_SITE_AUX $null_string +EOF +} + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining C_SWITCH_X_SITE = $null_string +EOF +cat >> confdefs.h <<EOF +#define C_SWITCH_X_SITE $null_string +EOF +} + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining LD_SWITCH_SITE = $null_string +EOF +cat >> confdefs.h <<EOF +#define LD_SWITCH_SITE $null_string +EOF +} + +{ test "$extra_verbose" = "yes" && cat << EOF + Defining C_SWITCH_SITE = $null_string +EOF +cat >> confdefs.h <<EOF +#define C_SWITCH_SITE $null_string +EOF +} + + + +test -n "$puresize" && { test "$extra_verbose" = "yes" && cat << EOF + Defining RAW_PURESIZE = $puresize +EOF +cat >> confdefs.h <<EOF +#define RAW_PURESIZE $puresize +EOF +} + + +if test "$GNU_MALLOC" = "yes"; then { test "$extra_verbose" = "yes" && cat << \EOF + Defining GNU_MALLOC +EOF +cat >> confdefs.h <<\EOF +#define GNU_MALLOC 1 +EOF +} + +elif test "$use_system_malloc" = "yes"; then { test "$extra_verbose" = "yes" && cat << \EOF + Defining USE_SYSTEM_MALLOC +EOF +cat >> confdefs.h <<\EOF +#define USE_SYSTEM_MALLOC 1 +EOF +} + +fi +test "$with_motif" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining LWLIB_USES_MOTIF +EOF +cat >> confdefs.h <<\EOF +#define LWLIB_USES_MOTIF 1 +EOF +} + +test "$with_i18n3" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining I18N3 +EOF +cat >> confdefs.h <<\EOF +#define I18N3 1 +EOF +} + +test "$with_mocklisp" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining MOCKLISP_SUPPORT +EOF +cat >> confdefs.h <<\EOF +#define MOCKLISP_SUPPORT 1 +EOF +} + +test "$with_gcc" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining USE_GCC +EOF +cat >> confdefs.h <<\EOF +#define USE_GCC 1 +EOF +} + +test "$with_term" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HAVE_TERM +EOF +cat >> confdefs.h <<\EOF +#define HAVE_TERM 1 +EOF +} + +test "$external_widget" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining EXTERNAL_WIDGET +EOF +cat >> confdefs.h <<\EOF +#define EXTERNAL_WIDGET 1 +EOF +} + +test "$with_gnu_make" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining USE_GNU_MAKE +EOF +cat >> confdefs.h <<\EOF +#define USE_GNU_MAKE 1 +EOF +} + +test "$no_doc_file" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining NO_DOC_FILE +EOF +cat >> confdefs.h <<\EOF +#define NO_DOC_FILE 1 +EOF +} + +test "$const_is_losing" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining CONST_IS_LOSING +EOF +cat >> confdefs.h <<\EOF +#define CONST_IS_LOSING 1 +EOF +} + +test "$use_assertions" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining USE_ASSERTIONS +EOF +cat >> confdefs.h <<\EOF +#define USE_ASSERTIONS 1 +EOF +} + +test "$debug" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining DEBUG_XEMACS +EOF +cat >> confdefs.h <<\EOF +#define DEBUG_XEMACS 1 +EOF +} + +test "$with_quantify" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining QUANTIFY +EOF +cat >> confdefs.h <<\EOF +#define QUANTIFY 1 +EOF +} + +test "$memory_usage_stats" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining MEMORY_USAGE_STATS +EOF +cat >> confdefs.h <<\EOF +#define MEMORY_USAGE_STATS 1 +EOF +} + +test "$with_pop" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining MAIL_USE_POP +EOF +cat >> confdefs.h <<\EOF +#define MAIL_USE_POP 1 +EOF +} + +test "$with_kerberos" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining KERBEROS +EOF +cat >> confdefs.h <<\EOF +#define KERBEROS 1 +EOF +} + +test "$with_hesiod" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining HESIOD +EOF +cat >> confdefs.h <<\EOF +#define HESIOD 1 +EOF +} + + +test "$error_check_extents" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining ERROR_CHECK_EXTENTS +EOF +cat >> confdefs.h <<\EOF +#define ERROR_CHECK_EXTENTS 1 +EOF +} + +test "$error_check_typecheck" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining ERROR_CHECK_TYPECHECK +EOF +cat >> confdefs.h <<\EOF +#define ERROR_CHECK_TYPECHECK 1 +EOF +} + +test "$error_check_bufpos" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining ERROR_CHECK_BUFPOS +EOF +cat >> confdefs.h <<\EOF +#define ERROR_CHECK_BUFPOS 1 +EOF +} + +test "$error_check_gc" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining ERROR_CHECK_GC +EOF +cat >> confdefs.h <<\EOF +#define ERROR_CHECK_GC 1 +EOF +} + +test "$error_check_malloc" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF + Defining ERROR_CHECK_MALLOC +EOF +cat >> confdefs.h <<\EOF +#define ERROR_CHECK_MALLOC 1 +EOF +} + + +test "$use_union_type" != yes && { test "$extra_verbose" = "yes" && cat << \EOF + Defining NO_UNION_TYPE +EOF +cat >> confdefs.h <<\EOF +#define NO_UNION_TYPE 1 +EOF } ( -if test -f /etc/osversion; then - # SONY NEWS-OS - echo "osversion: `cat /etc/osversion`" -eles - echo "uname -a: `uname -a`" -fi -echo "" -echo "$0 $quoted_arguments" +if test -f /etc/osversion; then echo "osversion: `cat /etc/osversion`" +else + echo "uname -a: `uname -a`" +fi +echo "" +echo "$0 $quoted_arguments" ) >> Installation -# Start stdout redirection to '| tee -a Installation' + ( echo " -Configured for \`${canonical}'. - - Where should the build process find the source code? ${srcdir} - What installation prefix should install use? ${prefix} +Configured for \`$canonical'. + + Where should the build process find the source code? $srcdir + What installation prefix should install use? $prefix What operating system and machine description files should XEmacs use? - \`${opsysfile}' and \`${machfile}' - What compiler should XEmacs be built with? ${CC} ${CFLAGS} + \`$opsysfile' and \`$machfile' + What compiler should XEmacs be built with? $CC $CFLAGS Should XEmacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason} - Should XEmacs use the relocating allocator for buffers? ${rel_alloc} - What window system should XEmacs use? ${window_system}${x_includes+ - Where do we find X Windows header files? }${x_includes}${x_libraries+ - Where do we find X Windows libraries? }${x_libraries}" - + Should XEmacs use the relocating allocator for buffers? $rel_alloc + What window system should XEmacs use? ${window_system}" +if test "$with_x11" = "yes"; then + echo " Where do we find X Windows header files? $x_includes" + echo " Where do we find X Windows libraries? $x_libraries" +fi if test -n "$site_includes"; then - echo " Additional header files: ${site_includes}" -fi - -if test -n "$site_libraries" -a -n "$site_runtime_libraries"; then - echo " Additional libraries: ${site_libraries} ${site_runtime_libraries}" -elif test -n "$site_libraries"; then - echo " Additional libraries: ${site_libraries}" -elif test -n "$site_runtime_libraries"; then - echo " Additional libraries: ${site_runtime_libraries}" + echo " Additional header files: $site_includes" +fi +if test -n "$site_libraries"; then + echo " Additional libraries: $site_libraries" +fi +if test -n "$runpath"; then + echo " Runtime library search path: $runpath" fi test "$with_dnet" = yes && echo " Compiling in support for DNET." test "$with_socks" = yes && echo " Compiling in support for SOCKS." test "$with_term" = yes && echo " Compiling in support for TERM." test "$with_xauth" = yes && echo " Compiling in support for XAUTH." -test "$with_xpm" = yes && echo " Compiling in support for XPM." -if test "$with_xmu" != yes -a "$window_system" != none; then +if test "$with_xmu" != yes -a "$with_x11" = yes; then echo " No Xmu; substituting equivalent routines." fi -test "$with_xface" = yes && echo " Compiling in support for X-Face headers." + test "$with_gif" = yes && echo " Compiling in support for GIF image conversion." +test "$with_xpm" = yes && echo " Compiling in support for XPM images." +test "$with_xface" = yes && echo " Compiling in support for X-Face message headers." test "$with_jpeg" = yes && echo " Compiling in support for JPEG image conversion." -if test "$with_png" = yes -o "$with_png" = gnuz; then - echo " Compiling in support for PNG image conversion." -fi -if test "$with_png" = gnuz; then - echo " (Using -lgz instead of -lz.)" -fi +test "$with_png" = yes && echo " Compiling in support for PNG image conversion." test "$with_tiff" = yes && echo " Compiling in support for TIFF image conversion (not implemented)." -test "$with_sound" = nas && echo " Compiling in network sound support." -test "$with_sound" = native && echo " Compiling in native sound support." -test "$with_sound" = both && echo " Compiling in both network and native sound support." -test "$old_nas" = true && echo " nas library lacks error trapping, will play synchronously" +case "$with_sound" in + nas ) echo " Compiling in network sound (NAS) support." ;; + native ) echo " Compiling in native sound support." ;; + both ) echo " Compiling in both network and native sound support." ;; +esac +test "$old_nas" = yes && echo " nas library lacks error trapping, will play synchronously" test "$with_database_berkdb" = yes && echo " Compiling in support for Berkeley DB." test "$with_database_dbm" = yes && echo " Compiling in support for DBM." test "$with_database_gnudbm" = yes && echo " Compiling in support for GNU DBM." -test "$have_ncurses" = yes && echo " Compiling in support for ncurses." -test "$with_socks" = yes && echo " Compiling in support for SOCKS." +test "$with_ncurses" = yes && echo " Compiling in support for ncurses." +test "$with_gpm" = yes && echo " Compiling in support for GPM (General Purpose Mouse)." test "$with_mule" = yes && echo " Compiling in Mule (multi-lingual) support." test "$with_xim" != no && echo " Compiling in XIM (X11R5+ I18N input method) support." @@ -7196,8 +9341,6 @@ if test "$with_wnn" = yes; then echo " Compiling in support for the WNN input method on Mule." test "$with_wnn6" = yes && echo " WNN support for version 6." - echo " Finding WNN includes with: ${wnn_includes}" - echo " Finding WNN libs with: ${wnn_libraries}" fi test "$with_i18n3" = yes && echo " Compiling in I18N support, level 3 (doesn't currently work)." @@ -7205,30 +9348,34 @@ test "$with_tooltalk" = yes && echo " Compiling in support for ToolTalk." test "$with_offix" = yes && echo " Compiling in support for OffiX." test "$with_mocklisp" = yes && echo " Compiling in support for Mocklisp." -test "$with_sparcworks" = yes && echo " Compiling in support for SparcWorks." +test "$with_workshop" = yes && echo " Compiling in support for Sun WorkShop." test "$with_energize" = yes && echo " Compiling in support for Lucid Energize (doesn't currently work)." -test "$with_menubars" = "lucid" && echo " Using the Lucid menubar." -if test "$with_menubars" = "motif"; then - echo " Using the Motif menubar." - echo " *WARNING* The Motif menubar is currently buggy. We recommend" - echo " that you use the Lucid menubar instead. Re-run" - echo " configure with --with-menubars='lucid'." -fi -test "$with_scrollbars" = lucid && echo " Using the Lucid scrollbar." -test "$with_scrollbars" = motif && echo " Using the Motif scrollbar." -test "$with_scrollbars" = athena && echo " Using the Athena scrollbar." -test "$with_scrollbars" = athena3d && echo " Using the Athena-3d scrollbar." -test "$with_dialogs" = motif && echo " Using the Motif dialog boxes." -test "$with_dialogs" = athena && echo " Using the Athena dialog boxes." -test "$with_dialogs" = athena3d && echo " Using the Athena-3d dialog boxes." +case "$with_menubars" in + lucid ) echo " Using the Lucid menubar." ;; + motif ) echo " Using the Motif menubar." + echo " *WARNING* The Motif menubar is currently buggy." + echo " We recommend using the Lucid menubar instead." + echo " Re-run configure with --with-menubars='lucid'." ;; +esac +case "$with_scrollbars" in + lucid ) echo " Using the Lucid scrollbar." ;; + motif ) echo " Using the Motif scrollbar." ;; + athena ) echo " Using the Athena scrollbar." ;; + athena3d ) echo " Using the Athena-3d scrollbar." ;; +esac +case "$with_dialogs" in + motif ) echo " Using the Motif dialog boxes." ;; + athena ) echo " Using the Athena dialog boxes." ;; + athena3d ) echo " Using the Athena-3d dialog boxes." ;; +esac 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 "${memory_usage_stats}" = yes && echo " Compiling in code for checking XEmacs memory usage." -test "$usage_tracking" = yes && echo " Compiling with usage tracking active (Sun internal)." +test "$use_union_type" = yes && echo " Using the union type for Lisp_Objects." +test "$debug" = yes && echo " Compiling in extra code for debugging." +test "$memory_usage_stats" = yes && echo " Compiling in code for checking XEmacs memory usage." +test "$usage_tracking" = yes && echo " Compiling with usage tracking active (Sun internal)." echo "" ) | tee -a Installation echo 'The above configure report is appended to "Installation" file.' @@ -7237,24 +9384,19 @@ # Remove any trailing slashes in these variables. -test -n "${prefix}" && - prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'` -test -n "${exec_prefix}" && - exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'` - - -# The preferred way to propogate these variables is regular @ substitutions. -if test -n "$prefix"; then - ac_prsub="s%^prefix\\([ ]*\\)=\\([ ]*\\).*$%prefix\\1=\\2$prefix%" -else - prefix=/usr/local -fi -if test -n "$exec_prefix"; then - ac_prsub="$ac_prsub -s%^exec_prefix\\([ ]*\\)=\\([ ]*\\).*$%exec_prefix\\1=\\2$exec_prefix%" -else - exec_prefix='${prefix}' # Let make expand it. -fi +test -n "$prefix" && + prefix=`echo "$prefix" | sed 's,\([^/]\)/*$,\1,'` +test -n "$exec_prefix" && + exec_prefix=`echo "$exec_prefix" | sed 's,\([^/]\)/*$,\1,'` + + +trap '' 1 2 15 + +trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' # Any assignment to VPATH causes Sun make to only execute # the first set of double-colon rules, so remove it if not needed. @@ -7263,36 +9405,36 @@ ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' fi -# Quote sed substitution magic chars in DEFS. -cat >conftest.def <<EOF -$DEFS -EOF -ac_escape_ampersand_and_backslash='s%[&\\]%\\&%g' -DEFS=`sed "$ac_escape_ampersand_and_backslash" <conftest.def` -rm -f conftest.def -# Substitute for predefined variables. - -trap 'rm -f config.status; exit 1' 1 2 15 -echo creating config.status -rm -f config.status -cat > config.status <<EOF -#!/bin/sh +trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 + +DEFS=-DHAVE_CONFIG_H + +# Without the "./", some shells look in PATH for config.status. +: ${CONFIG_STATUS=./config.status} + +echo creating $CONFIG_STATUS +rm -f $CONFIG_STATUS +cat > $CONFIG_STATUS <<EOF +#! /bin/sh # Generated automatically by configure. # Run this file to recreate the current configuration. # This directory was configured as follows, # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # -# $0 $quoted_arguments - -ac_cs_usage="Usage: config.status [--recheck] [--version] [--help]" +# $0 $ac_configure_args +# +# Compiler output produced by configure, useful for debugging +# configure, is in ./config.log if it exists. + +ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" for ac_option do case "\$ac_option" in -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - echo running \${CONFIG_SHELL-/bin/sh} $0 $quoted_arguments --no-create - exec \${CONFIG_SHELL-/bin/sh} $0 $quoted_arguments --no-create ;; + echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" + exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; -version | --version | --versio | --versi | --vers | --ver | --ve | --v) - echo "config.status generated by autoconf version 1.11" + echo "$CONFIG_STATUS generated by autoconf version 2.12" exit 0 ;; -help | --help | --hel | --he | --h) echo "\$ac_cs_usage"; exit 0 ;; @@ -7300,122 +9442,59 @@ esac done -trap 'rm -fr $internal_makefile_list src/config.h conftest*; exit 1' 1 2 15 -LN_S='$LN_S' -CC='$CC' -CPP='$CPP' -RANLIB='$RANLIB' -INSTALL='$INSTALL' -INSTALL_PROGRAM='$INSTALL_PROGRAM' -INSTALL_DATA='$INSTALL_DATA' -YACC='$YACC' -SET_MAKE='$SET_MAKE' -ALLOCA='$ALLOCA' -version='$version' -configuration='$configuration' -canonical='$canonical' -srcdir='$srcdir' -prefix='$prefix' -exec_prefix='$exec_prefix' -bindir='$bindir' -datadir='$datadir' -statedir='$statedir' -libdir='$libdir' -mandir='$mandir' -infodir='$infodir' -infodir_user_defined='$infodir_user_defined' -lispdir='$lispdir' -lispdir_user_defined='$lispdir_user_defined' -sitelispdir='$sitelispdir' -etcdir='$etcdir' -etcdir_user_defined='$etcdir_user_defined' -lockdir='$lockdir' -lockdir_user_defined='$lockdir_user_defined' -archlibdir='$archlibdir' -archlibdir_user_defined='$archlibdir_user_defined' -docdir='$docdir' -bitmapdir='$bitmapdir' -c_switch_system='$c_switch_system' -c_switch_machine='$c_switch_machine' -libsrc_libs='$libsrc_libs' -LD_SWITCH_X_SITE='$LD_SWITCH_X_SITE' -LD_SWITCH_X_SITE_AUX='$LD_SWITCH_X_SITE_AUX' -C_SWITCH_X_SITE='$C_SWITCH_X_SITE' -LD_SWITCH_SITE='$LD_SWITCH_SITE' -C_SWITCH_SITE='$C_SWITCH_SITE' -CFLAGS='$CFLAGS' -native_sound_lib='$native_sound_lib' -machfile='$machfile' -opsysfile='$opsysfile' -dynodump_arch='$dynodump_arch' -internal_makefile_list='$internal_makefile_list' -LIBS='$LIBS' -top_srcdir='$top_srcdir' -ac_prsub='$ac_prsub' -ac_vpsub='$ac_vpsub' -extrasub='$extrasub' -EOF -cat >> config.status <<\EOF - ac_given_srcdir=$srcdir - -CONFIG_FILES=${CONFIG_FILES-"$internal_makefile_list"} -for ac_file in .. ${CONFIG_FILES}; do if test "x$ac_file" != x..; then - # Remove last slash and all that follows it. Not all systems have dirname. - ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` - if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then - # The file is in a subdirectory. - test ! -d "$ac_dir" && mkdir "$ac_dir" - ac_dir_suffix="/$ac_dir" - else - ac_dir_suffix= - fi - - # A "../" for each directory in $ac_dir_suffix. - ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` - case "$ac_given_srcdir" in - .) srcdir=. - if test -z "$ac_dir_suffix"; then top_srcdir=. - else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; - /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; - *) # Relative path. - srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" - top_srcdir="$ac_dots$ac_given_srcdir" ;; - esac - - echo creating "$ac_file" - rm -f "$ac_file" - comment_str="Generated automatically from `echo $ac_file|sed 's|.*/||'`.in by configure." - case "$ac_file" in - *.c | *.h | *.C | *.cc | *.m ) echo "/* $comment_str */" > "$ac_file" ;; - * ) echo "# $comment_str" > "$ac_file" ;; - esac - sed -e " -$ac_prsub +ac_given_INSTALL="$INSTALL" + +trap 'rm -fr `echo "$internal_makefile_list src/config.h lwlib/config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 +EOF +cat >> $CONFIG_STATUS <<EOF + +# Protect against being on the right side of a sed subst in config.status. +sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; + s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF $ac_vpsub $extrasub +s%@CFLAGS@%$CFLAGS%g +s%@CPPFLAGS@%$CPPFLAGS%g +s%@CXXFLAGS@%$CXXFLAGS%g +s%@DEFS@%$DEFS%g +s%@LDFLAGS@%$LDFLAGS%g +s%@LIBS@%$LIBS%g +s%@exec_prefix@%$exec_prefix%g +s%@prefix@%$prefix%g +s%@program_transform_name@%$program_transform_name%g +s%@bindir@%$bindir%g +s%@sbindir@%$sbindir%g +s%@libexecdir@%$libexecdir%g +s%@datadir@%$datadir%g +s%@sysconfdir@%$sysconfdir%g +s%@sharedstatedir@%$sharedstatedir%g +s%@localstatedir@%$localstatedir%g +s%@libdir@%$libdir%g +s%@includedir@%$includedir%g +s%@oldincludedir@%$oldincludedir%g +s%@infodir@%$infodir%g +s%@mandir@%$mandir%g s%@LN_S@%$LN_S%g s%@CC@%$CC%g s%@CPP@%$CPP%g s%@RANLIB@%$RANLIB%g -s%@INSTALL@%$INSTALL%g s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g s%@INSTALL_DATA@%$INSTALL_DATA%g s%@YACC@%$YACC%g s%@SET_MAKE@%$SET_MAKE%g +s%@X_CFLAGS@%$X_CFLAGS%g +s%@X_PRE_LIBS@%$X_PRE_LIBS%g +s%@X_LIBS@%$X_LIBS%g +s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g s%@ALLOCA@%$ALLOCA%g +s%@MAKE_SUBDIR@%$MAKE_SUBDIR%g +s%@SUBDIR_MAKEFILES@%$SUBDIR_MAKEFILES%g s%@version@%$version%g s%@configuration@%$configuration%g s%@canonical@%$canonical%g s%@srcdir@%$srcdir%g -s%@prefix@%$prefix%g -s%@exec_prefix@%$exec_prefix%g -s%@bindir@%$bindir%g -s%@datadir@%$datadir%g s%@statedir@%$statedir%g -s%@libdir@%$libdir%g -s%@mandir@%$mandir%g -s%@infodir@%$infodir%g s%@infodir_user_defined@%$infodir_user_defined%g s%@lispdir@%$lispdir%g s%@lispdir_user_defined@%$lispdir_user_defined%g @@ -7428,300 +9507,278 @@ s%@archlibdir_user_defined@%$archlibdir_user_defined%g s%@docdir@%$docdir%g s%@bitmapdir@%$bitmapdir%g -s%@c_switch_system@%$c_switch_system%g -s%@c_switch_machine@%$c_switch_machine%g -s%@libsrc_libs@%$libsrc_libs%g -s%@LD_SWITCH_X_SITE@%$LD_SWITCH_X_SITE%g -s%@LD_SWITCH_X_SITE_AUX@%$LD_SWITCH_X_SITE_AUX%g -s%@C_SWITCH_X_SITE@%$C_SWITCH_X_SITE%g -s%@LD_SWITCH_SITE@%$LD_SWITCH_SITE%g -s%@C_SWITCH_SITE@%$C_SWITCH_SITE%g -s%@CFLAGS@%$CFLAGS%g -s%@native_sound_lib@%$native_sound_lib%g +s%@extra_objs@%$extra_objs%g s%@machfile@%$machfile%g s%@opsysfile@%$opsysfile%g +s%@c_switch_general@%$c_switch_general%g +s%@c_switch_window_system@%$c_switch_window_system%g +s%@c_switch_all@%$c_switch_all%g +s%@ld_switch_general@%$ld_switch_general%g +s%@ld_switch_window_system@%$ld_switch_window_system%g +s%@ld_switch_all@%$ld_switch_all%g +s%@ld_libs_general@%$ld_libs_general%g +s%@ld_libs_window_system@%$ld_libs_window_system%g +s%@ld_libs_all@%$ld_libs_all%g +s%@libsrc_libs@%$libsrc_libs%g +s%@native_sound_lib@%$native_sound_lib%g +s%@sound_cflags@%$sound_cflags%g s%@dynodump_arch@%$dynodump_arch%g s%@internal_makefile_list@%$internal_makefile_list%g -s%@LIBS@%$LIBS%g + +CEOF +EOF + +cat >> $CONFIG_STATUS <<\EOF + +# Split the substitutions into bite-sized pieces for seds with +# small command number limits, like on Digital OSF/1 and HP-UX. +ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. +ac_file=1 # Number of current file. +ac_beg=1 # First line for current file. +ac_end=$ac_max_sed_cmds # Line after last line for current file. +ac_more_lines=: +ac_sed_cmds="" +while $ac_more_lines; do + if test $ac_beg -gt 1; then + sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file + else + sed "${ac_end}q" conftest.subs > conftest.s$ac_file + fi + if test ! -s conftest.s$ac_file; then + ac_more_lines=false + rm -f conftest.s$ac_file + else + if test -z "$ac_sed_cmds"; then + ac_sed_cmds="sed -f conftest.s$ac_file" + else + ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" + fi + ac_file=`expr $ac_file + 1` + ac_beg=$ac_end + ac_end=`expr $ac_end + $ac_max_sed_cmds` + fi +done +if test -z "$ac_sed_cmds"; then + ac_sed_cmds=cat +fi +EOF + +cat >> $CONFIG_STATUS <<EOF + +CONFIG_FILES=\${CONFIG_FILES-"$internal_makefile_list"} +EOF +cat >> $CONFIG_STATUS <<\EOF +for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then + # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". + case "$ac_file" in + *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` + ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; + *) ac_file_in="${ac_file}.in" ;; + esac + + # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. + + # Remove last slash and all that follows it. Not all systems have dirname. + ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` + if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then + # The file is in a subdirectory. + test ! -d "$ac_dir" && mkdir "$ac_dir" + ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" + # A "../" for each directory in $ac_dir_suffix. + ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` + else + ac_dir_suffix= ac_dots= + fi + + case "$ac_given_srcdir" in + .) srcdir=. + if test -z "$ac_dots"; then top_srcdir=. + else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; + /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; + *) # Relative path. + srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" + top_srcdir="$ac_dots$ac_given_srcdir" ;; + esac + + case "$ac_given_INSTALL" in + [/$]*) INSTALL="$ac_given_INSTALL" ;; + *) INSTALL="$ac_dots$ac_given_INSTALL" ;; + esac + + echo creating "$ac_file" + rm -f "$ac_file" + configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." + case "$ac_file" in + *Makefile*) ac_comsub="1i\\ +# $configure_input" ;; + *) ac_comsub= ;; + esac + + ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` + sed -e "$ac_comsub +s%@configure_input@%$configure_input%g +s%@srcdir@%$srcdir%g s%@top_srcdir@%$top_srcdir%g -s%@DEFS@%-DHAVE_CONFIG_H%" $ac_given_srcdir/${ac_file}.in >> $ac_file +s%@INSTALL@%$INSTALL%g +" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file fi; done - -# These sed commands are put into ac_sed_defs when defining a macro. -# They are broken into pieces to make the sed script easier to manage. -# They are passed to sed as "A NAME B NAME C VALUE D", where NAME -# is the cpp macro being defined and VALUE is the value it is being given. -# Each defining turns into a single global substitution command. -# Hopefully no one uses "!" as a variable value. -# Other candidates for the sed separators, like , and @, do get used. +rm -f conftest.s* + +# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where +# NAME is the cpp macro being defined and VALUE is the value it is being given. # # ac_d sets the value in "#define NAME VALUE" lines. -ac_dA='s!^\([ ]*\)#\([ ]*define[ ][ ]*\)' -ac_dB='\([ ][ ]*\)[^ ]*!\1#\2' +ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' +ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' ac_dC='\3' -ac_dD='!g' +ac_dD='%g' # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". -ac_uA='s!^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' -ac_uB='\([ ]\)!\1#\2define\3' +ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' +ac_uB='\([ ]\)%\1#\2define\3' ac_uC=' ' -ac_uD='\4!g' +ac_uD='\4%g' # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". -ac_eA='s!^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' -ac_eB='$!\1#\2define\3' +ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' +ac_eB='$%\1#\2define\3' ac_eC=' ' -ac_eD='!g' -rm -f conftest.sed -EOF -# Turn off quoting long enough to insert the sed commands. -rm -f conftest.sh -cat > conftest.sh <<EOF -$ac_sed_defs -EOF - -# Break up $ac_sed_defs (now in conftest.sh) because some shells have a limit -# on the size of here documents. - -# Maximum number of lines to put in a single here document. -ac_max_sh_lines=9 - +ac_eD='%g' + +if test "${CONFIG_HEADERS+set}" != set; then +EOF +cat >> $CONFIG_STATUS <<EOF + CONFIG_HEADERS="src/config.h lwlib/config.h" +EOF +cat >> $CONFIG_STATUS <<\EOF +fi +for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then + # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". + case "$ac_file" in + *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` + ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; + *) ac_file_in="${ac_file}.in" ;; + esac + + echo creating $ac_file + + rm -f conftest.frag conftest.in conftest.out + ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` + cat $ac_file_inputs > conftest.in + +EOF + +# Transform confdefs.h into a sed script conftest.vals that substitutes +# the proper values into config.h.in to produce config.h. And first: +# Protect against being on the right side of a sed subst in config.status. +# Protect against being in an unquoted here document in config.status. +rm -f conftest.vals +cat > conftest.hdr <<\EOF +s/[\\&%]/\\&/g +s%[\\$`]%\\&%g +s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp +s%ac_d%ac_u%gp +s%ac_u%ac_e%gp +EOF +sed -n -f conftest.hdr confdefs.h > conftest.vals +rm -f conftest.hdr + +# This sed command replaces #undef with comments. This is necessary, for +# example, in the case of _POSIX_SOURCE, which is predefined and required +# on some systems where configure will not decide to define it. +cat >> conftest.vals <<\EOF +s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% +EOF + +# Break up conftest.vals because some shells have a limit on +# the size of here documents, and old seds have small limits too. + +rm -f conftest.tail while : do - # wc gives bogus results for an empty file on some AIX systems. - ac_lines=`grep -c . conftest.sh` + ac_lines=`grep -c . conftest.vals` + # grep -c gives empty output for an empty file on some AIX systems. if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi - rm -f conftest.s1 conftest.s2 - sed ${ac_max_sh_lines}q conftest.sh > conftest.s1 # Like head -9. - sed 1,${ac_max_sh_lines}d conftest.sh > conftest.s2 # Like tail +10. - # Write a limited-size here document to append to conftest.sed. - echo 'cat >> conftest.sed <<CONFEOF' >> config.status - cat conftest.s1 >> config.status - echo 'CONFEOF' >> config.status - rm -f conftest.s1 conftest.sh - mv conftest.s2 conftest.sh + # Write a limited-size here document to conftest.frag. + echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS + sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS + echo 'CEOF + sed -f conftest.frag conftest.in > conftest.out + rm -f conftest.in + mv conftest.out conftest.in +' >> $CONFIG_STATUS + sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail + rm -f conftest.vals + mv conftest.tail conftest.vals done -rm -f conftest.sh - -# Now back to your regularly scheduled config.status. -cat >> config.status <<\EOF -# This sed command replaces #undef's with comments. This is necessary, for -# example, in the case of _POSIX_SOURCE, which is predefined and required -# on some systems where configure will not decide to define it in -# src/config.h. -cat >> conftest.sed <<\CONFEOF -s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */, -CONFEOF -rm -f conftest.h -# Break up the sed commands because old seds have small limits. -ac_max_sed_lines=20 - -CONFIG_HEADERS=${CONFIG_HEADERS-"src/config.h"} -for ac_file in .. ${CONFIG_HEADERS}; do if test "x$ac_file" != x..; then - echo creating $ac_file - - cp $ac_given_srcdir/$ac_file.in conftest.h1 - cp conftest.sed conftest.stm - while : - do - ac_lines=`grep -c . conftest.stm` - if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi - rm -f conftest.s1 conftest.s2 conftest.h2 - sed ${ac_max_sed_lines}q conftest.stm > conftest.s1 # Like head -20. - sed 1,${ac_max_sed_lines}d conftest.stm > conftest.s2 # Like tail +21. - sed -f conftest.s1 < conftest.h1 > conftest.h2 - rm -f conftest.s1 conftest.h1 conftest.stm - mv conftest.h2 conftest.h1 - mv conftest.s2 conftest.stm - done - rm -f conftest.stm conftest.h +rm -f conftest.vals + +cat >> $CONFIG_STATUS <<\EOF + rm -f conftest.frag conftest.h echo "/* $ac_file. Generated automatically by configure. */" > conftest.h - cat conftest.h1 >> conftest.h - rm -f conftest.h1 + cat conftest.in >> conftest.h + rm -f conftest.in if cmp -s $ac_file conftest.h 2>/dev/null; then - # The file exists and we would not be changing it. echo "$ac_file is unchanged" rm -f conftest.h else + # Remove last slash and all that follows it. Not all systems have dirname. + ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` + if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then + # The file is in a subdirectory. + test ! -d "$ac_dir" && mkdir "$ac_dir" + fi rm -f $ac_file mv conftest.h $ac_file fi fi; done -rm -f conftest.sed - - + +EOF +cat >> $CONFIG_STATUS <<EOF +CPP="$CPP" + CPPFLAGS="$CPPFLAGS" + top_srcdir="$srcdir" + MAKE_SUBDIR="$MAKE_SUBDIR" + +EOF +cat >> $CONFIG_STATUS <<\EOF + +for dir in $MAKE_SUBDIR; do + echo creating $dir/Makefile + ( set -e + cd $dir + rm -f junk.c + sed -e 's/^# Generated.*//' -e 's%/\*\*/#.*%%' < Makefile.in > junk.c; + $CPP -I. -I${top_srcdir}/src $CPPFLAGS junk.c > junk.cpp; + < junk.cpp \ + sed -e 's/^#.*//' \ + -e 's/^[ \f\t][ \f\t]*$//' \ + -e 's/^ / /' \ + | sed -n -e '/^..*$/p' \ + > Makefile.new + chmod 444 Makefile.new + mv -f Makefile.new Makefile + rm -f junk.c junk.cpp + ) + test "$?" != 0 && exit "$?" # For debugging +done exit 0 EOF -chmod +x config.status -# Some shells look in PATH for config.status without the "./". -test -n "$no_create" || ${CONFIG_SHELL-/bin/sh} ./config.status - -# Build: -# src/Makefile from ${srcdir}/src/Makefile.in -# lwlib/Makefile from ${srcdir}/lwlib/Makefile.in -# lib-src/Makefile from ${srcdir}/lib-src/Makefile.in -# dynodump/Makefile from ${srcdir}/dynodump/Makefile.in -# and possibly -# lwlib/energize/Makefile from ${srcdir}/lwlib/energize/Makefile.in. -# This must be done after src/config.h is built, since we rely on that -# file. Only do the build if "config.status" is present, since its -# non-presence indicates an error occured. -status=$? -if test ! -f ./config.status ; then - exit $status -fi -topsrcdir=${srcdir} - # We discard all lines in Makefile.in that start with `# Generated' or /**/# - # because some cpps get confused by them. - # Really we should preserve them somehow into Makefile, - # but that is beyond my level of shell programming. -makefile_command='echo "creating src/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./src; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[ \f\t][ \f\t]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $makefile_command` -lwlib_makefile_command='echo "creating lwlib/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./lwlib; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[ \f\t][ \f\t]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $lwlib_makefile_command` -lib_src_makefile_command='echo "creating lib-src/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./lib-src; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[ \f\t][ \f\t]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $lib_src_makefile_command` - -# Mule utilitity programs - currently disabled -if test "${with_mule_util}" = "yes"; then -lib_src_mule_makefile_command='echo "creating lib-src/mule/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./lib-src/mule; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[ \f\t][ \f\t]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $lib_src_mule_makefile_command` -fi # Mule - -dynodump_makefile_command='echo "creating dynodump/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./dynodump; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[ \f\t][ \f\t]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $dynodump_makefile_command` -if test "${with_energize}" = "yes" ; then -energize_makefile_command='echo "creating lwlib/energize/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./lwlib/energize; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[ \f\t][ \f\t]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $energize_makefile_command` -fi -# AC-OUTPUT has created `config.status' already. We need to add the -# above commands to re-create `src/Makefile', `lwlib/Makefile', -# `lib-src/Makefile', `dynodump/Makefile', and possibly -# `lwlib/energize/Makefile', and we need to insert them before the final -# "exit 0" which appears at the end of `config.status'. -<config.status sed -e 's/^exit 0$//' >config.new -echo $makefile_command >>config.new -echo $lwlib_makefile_command >>config.new -echo $lib_src_makefile_command >>config.new -if test "${with_mule_util}" = "yes"; then - echo $lib_src_mule_makefile_command >>config.new -fi -echo $dynodump_makefile_command >>config.new -echo $man_makefile_command >>config.new -if test "${with_energize}" = "yes" ; then - echo $energize_makefile_command >>config.new -fi -echo exit 0 >>config.new -mv -f config.new config.status -chmod +x config.status -# Don't let the fact that we just rewrote config.status make Makefile think -# that it is now newer. We have just rewritten all of the Makefiles as well. -MFS="Makefile \ - src/Makefile src/Makefile.in \ - lib-src/Makefile lib-src/Makefile.in \ - dynodump/Makefile dynodump/Makefile.in \ - lwlib/Makefile lwlib/Makefile.in" -chmod a+w $MFS -touch $MFS -chmod 444 $MFS +chmod +x $CONFIG_STATUS +rm -fr confdefs* $ac_clean_files +test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 + if test ! -f src/gdbinit && test -f $topsrcdir/src/gdbinit; then - echo creating src/gdbinit - echo source $topsrcdir/src/gdbinit > src/gdbinit -fi - -exit 0 - - -# Local Variables: -# eval: (modify-syntax-entry ?\" "\"") -# End: + echo "creating src/gdbinit" + echo "source $topsrcdir/src/gdbinit" > src/gdbinit +fi + +if test "$sunpro_c" = "yes"; then cat < EOF > .sbinit +# For use with Sun WorkShop's Source browser. +# See sbquery(1) and sbinit(4) for more information +import src +import lwlib +import lib-src +import dynodump +EOF +fi
--- a/configure.in Mon Aug 13 09:35:15 2007 +0200 +++ b/configure.in Mon Aug 13 09:36:16 2007 +0200 @@ -1,23 +1,13 @@ -dnl -*- mode: m4; -*- -dnl Synched up with: FSF 19.31. -dnl (19.29 -- 19.31 use Autoconf 2.x instead of Autoconf 1.x. -dnl Some stuff related to this change has not been synched because -dnl it can't be until we switch to Autoconf 2.x.) -dnl -dnl This is an autoconf script. -dnl To rebuild the `configure' script from this, execute the command -dnl autoconf -dnl in the directory containing this script. You must have autoconf -dnl version 1.9 or later. -dnl -dnl The following text appears in the resulting `configure' script, -dnl explaining how to rebuild it. -dnl -AC_PREREQ(1.9)dnl means 'delete newline' and this one needs to be here -#!/bin/sh -#### Configuration script for XEmacs. -#### Copyright (C) 1994 Free Software Foundation, Inc. +dnl Define our own header notice with own copyrights +define([PRINT_VAR],[ifelse([$#] ,0, , [$#], 1, echo "[$1] = $[$1]", echo "[$1] = $[$1]" +[PRINT_VAR(builtin([shift],$@))])]) +define([AC_INIT_NOTICE], +[#### Configuration script for XEmacs. Largely divergent from FSF. +#### Guess values for system-dependent variables and create Makefiles. +#### Generated automatically using autoconf version] AC_ACVERSION [ +#### Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. #### Copyright (C) 1993-1995 Board of Trustees, University of Illinois. +#### Copyright (C) 1996, 1997 Sun Microsystems, Inc. #### Copyright (C) 1995, 1996 Ben Wing. ### Don't edit this script! @@ -25,7 +15,7 @@ ### from the file `./configure.in'. ### To rebuild it, execute the command ### autoconf -### in the this directory. You must have autoconf version 1.9 or later. +### in the this directory. You must have autoconf version 2.12 or later. ### This file is part of XEmacs. @@ -44,48 +34,231 @@ ### Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ### 02111-1307, USA. -### Since XEmacs has configuration requirements that autoconf can't -### meet, this file is an unholy marriage of custom-baked -### configuration code and autoconf macros. -### -### We use the m4 quoting characters [ ] (as established by the -### autoconf system) to include large sections of raw sewage - Oops, I -### mean, shell code - in the final configuration script. -### -### Usage: configure config_name +### For usage, run `./configure --help' +### For more detailed information on building and installing XEmacs, +### read the file `INSTALL'. ### ### If configure succeeds, it leaves its status in config.status. +### A log of configuration tests can be found in config.log. ### If configure fails after disturbing the status quo, ### config.status is removed. - -### Remove any more than one leading "." element from the path name. -### If we don't remove them, then another "./" will be prepended to -### the file name each time we use config.status, and the program name -### will get larger and larger. This wouldn't be a problem, except -### that since progname gets recorded in all the Makefiles this script -### produces, move-if-change thinks they're different when they're -### not. -### -### It would be nice if we could put the ./ in a \( \) group and then -### apply the * operator to that, so we remove as many leading ./././'s -### as are present, but some seds (like Ultrix's sed) don't allow you to -### apply * to a \( \) group. Bleah. +]) + +dnl Since XEmacs has configuration requirements that autoconf cannot +dnl meet, this file is an unholy marriage of custom-baked +dnl configuration code and autoconf macros. + +dnl We use the m4 quoting characters [ ] (as established by the +dnl autoconf system), so quote them like this: [[foo]] + +AC_PREREQ(2.12)dnl +dnl Redefine some standard autoconf macros +dnl here is how XEmacs is different: +dnl - no cache file +dnl - non-standard options +dnl - suport for extra-verbosity +dnl - ordinary libs are handled separately from X libs (might be a mistake) +dnl - various random kludges (e.g. -with-dnet=no + +dnl Disable cache files: +dnl This is controversial, but I am convinced this is the right way to go, +dnl at least by default. Otherwise there are too many surprises. +define([AC_CACHE_LOAD], )dnl +define([AC_CACHE_SAVE], )dnl +define([AC_CACHE_VAL], [ +$2 +])dnl + +dnl Avoid spurious cross-compiling warnings from AC_TRY_RUN +dnl XEmacs is unlikely to ever cross-compile +define([AC_TRY_RUN],[AC_TRY_RUN_NATIVE([$1], [$2], [$3])])dnl + + +dnl Redefine AC_DEFINE* to provide more output if extra_verbose +dnl Set VARIABLE to VALUE, verbatim, or 1. +dnl AC_DEFINE(VARIABLE [, VALUE]) +define([AC_DEFINE], +[{ test "$extra_verbose" = "yes" && cat << \EOF + Defining $1[]ifelse($#, 2, [ = $2],) +EOF +cat >> confdefs.h <<\EOF +[#define] $1 ifelse($#, 2, [$2], 1) +EOF +} +]) + +define([AC_DEFINE_UNQUOTED], +[{ test "$extra_verbose" = "yes" && cat << EOF + Defining $1[]ifelse($#, 2, [ = $2],) +EOF +cat >> confdefs.h <<EOF +[#define] $1 ifelse($#, 2, [$2], 1) +EOF +} +]) + + +dnl redefine AC_CHECK_LIB in accordance with our own value of ac_link +dnl Add in extra kludgy check to support with_dnet=no +dnl Add in extra LDFLAGS arg, which PRECEDE libs +dnl Support --with-dnet=no + +dnl AC_CHECK_LIB(LIBRARY, FUNCTION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND +dnl [, OTHER-LIBRARIES] [, LDFLAGS]]]]) +define([AC_CHECK_LIB], +[ifelse([$1],dnet, [if test "$with_dnet" = "no"; then +ac_cv_lib_dnet_dnet_ntoa=no +ifelse([$4], , , [$4] +)dnl +else +])] +AC_CHECK_LIB_ORIG_HACKED([$1],[$2],[$3],[$4],[$5], [$6]) +[ifelse([$1],dnet,[fi +])]dnl +) + +define([AC_CHECK_LIB_ORIG_HACKED], +[ifelse([$5],,AC_MSG_CHECKING([for $2 in -l$1]), +xe_msg_checking="for [$2] in -l[$1]" +test -n "[$5]" && xe_msg_checking="$xe_msg_checking using extra libs [$5]" +AC_MSG_CHECKING("$xe_msg_checking")) +dnl Use a cache variable name containing both the library and function name, +dnl because the test really is for library $1 defining function $2, not +dnl just for library $1. Separate tests with the same $1 and different $2s +dnl may have different results. +ac_lib_var=`echo $1['_']$2 | sed 'y%./+-%__p_%'` +AC_CACHE_VAL(ac_cv_lib_$ac_lib_var, +[xe_check_libs="$6 -l$1 $5" +AC_TRY_LINK(dnl +ifelse([$2], [main], , dnl Avoid conflicting decl of main. +[/* Override any gcc2 internal prototype to avoid an error. */ +]ifelse(AC_LANG, CPLUSPLUS, [#ifdef __cplusplus +extern "C" +#endif +])dnl +[/* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +char $2(); +]), + [$2()], + eval "ac_cv_lib_$ac_lib_var=yes", + eval "ac_cv_lib_$ac_lib_var=no") +xe_check_libs="" +])dnl +if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then + AC_MSG_RESULT(yes) + ifelse([$3], , +[changequote(, )dnl + ac_tr_lib=HAVE_LIB`echo $1 | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` +changequote([, ])dnl + AC_DEFINE_UNQUOTED($ac_tr_lib) + LIBS="-l$1 $LIBS" +], [$3]) +else + AC_MSG_RESULT(no) +ifelse([$4], , , [$4 +])dnl +fi +]) + + +dnl AC_LANG_C() +define([AC_LANG_C], +[define([AC_LANG], [C])dnl +ac_ext=c +dnl CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. +dnl ac_cpp='$CPP $CPPFLAGS' +dnl ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&AC_FD_CC' +dnl ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&AC_FD_CC' +xe_cppflags='$c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS $CPPFLAGS' # $c_switch_x_machine $c_switch_x_system' +xe_ldflags='$ld_switch_site $ld_switch_machine $ld_switch_system $ld_switch_x_site' # $ld_switch_x_machine $ld_switch_x_system' +xe_libs='$xe_check_libs $X_PRE_LIBS $libs_x $X_EXTRA_LIBS $LIBS $libs_machine $libs_system $libs_standard' +ac_cpp='$CPP '"$xe_cppflags" +ac_compile='${CC-cc} -c '"$CFLAGS $xe_cppflags"' conftest.$ac_ext 1>&AC_FD_CC' +ac_link='${CC-cc} -o conftest '"$CFLAGS $xe_cppflags $LDFLAGS $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&AC_FD_CC' +cross_compiling=no +]) + +define([AC_INIT_PARSE_ARGS],[ +dnl Initialize some variables set by options. +dnl The variables have the same names as the options, with +dnl dashes changed to underlines. +build=NONE +cache_file=/dev/null +exec_prefix=NONE +host=NONE +no_create= +nonopt=NONE +no_recursion= +prefix=NONE +program_prefix=NONE +program_suffix=NONE +program_transform_name=s,x,x, +silent= +site= +srcdir= +target=NONE +verbose= +x_includes=NONE +x_libraries=NONE +dnl Installation directory options. +dnl These are left unexpanded so users can "make install exec_prefix=/foo" +dnl and all the variables that are supposed to be based on exec_prefix +dnl by default will actually change. +dnl Use braces instead of parens because sh, perl, etc. also accept them. +bindir='${exec_prefix}/bin' +sbindir='${exec_prefix}/sbin' +libexecdir='${exec_prefix}/libexec' +datadir='${prefix}/share' +sysconfdir='${prefix}/etc' +sharedstatedir='${prefix}/com' +localstatedir='${prefix}/var' +libdir='${{exec_prefix}}/lib' +includedir='${prefix}/include' +oldincludedir='/usr/include' +infodir='${prefix}/info' +mandir='${prefix}/man' + +dnl Initialize some other variables. +subdirs= +MFLAGS= MAKEFLAGS= +dnl Maximum number of lines to put in a shell here document. +ac_max_here_lines=12 +])dnl +AC_INIT(src/lisp.h)dnl +AC_CONFIG_HEADER(src/config.h lwlib/config.h) +dnl Remove any more than one leading "." element from the path name. +dnl If we do not remove them, then another "./" will be prepended to +dnl the file name each time we use config.status, and the program name +dnl will get larger and larger. This would not be a problem, except +dnl that since progname gets recorded in all the Makefiles this script +dnl produces, move-if-change thinks they're different when they're +dnl not. +dnl +dnl It would be nice if we could put the ./ in a \( \) group and then +dnl apply the * operator to that, so we remove as many leading './././'s +dnl as are present, but some seds (like Ultrix's sed) don't allow you to +dnl apply * to a \( \) group. Bleah. progname="`echo $0 | sed 's:^\./\./:\./:'`" -############################################################################ -# # -# Establish some default values # -# # -############################################################################ - -#run_in_place='no' +dnl ----------------------------- +dnl Establish some default values +dnl ----------------------------- + +dnl Prevent autoconf2 caching +cache_file=/dev/null + +MAKE_SUBDIR="src lib-src" + +dnl run_in_place='no' prefix='/usr/local' exec_prefix='${prefix}' bindir='${exec_prefix}/bin' -# FSF 19.29 changes to: -# datadir='${prefix}/share' -# sharedstatedir='${prefix}/com' -# libexecdir='${exec_prefix}/libexec' +dnl FSF 19.29 changes to: +dnl datadir='${prefix}/share' +dnl sharedstatedir='${prefix}/com' +dnl libexecdir='${exec_prefix}/libexec' datadir='${prefix}/lib' statedir='${prefix}/lib' libdir='${exec_prefix}/lib' @@ -111,55 +284,37 @@ with_x11='' rel_alloc='default' use_system_malloc='default' -internal_makefile_list='Makefile lib-src/Makefile.in src/Makefile.in lwlib/Makefile.in dynodump/Makefile.in' -energize_version='no' +energize_version='' native_sound_lib='' -# make normal error-checking be the default in alpha and beta versions, so -# that bugs get noticed. Change this for released versions. +dnl make normal error-checking be the default in alpha and beta versions, so +dnl that bugs get noticed. Change this for released versions. error_check_default='no' error_check_extents=$error_check_default error_check_typecheck=$error_check_default error_check_bufpos=$error_check_default error_check_gc=$error_check_default error_check_malloc=$error_check_default -# debug=yes must be set when error checking is present. This should be -# fixed up. +dnl debug=yes must be set when error checking is present. This should be +dnl fixed up. debug=$error_check_default -quantify='no' -# use-assertions should be 'yes' by default. Too many people in this -# world have core dumps turned off by default or "can't find where the -# core file went". At least we should get some useful output ... +dnl use-assertions should be 'yes' by default. Too many people in this +dnl world have core dumps turned off by default or \"cannot find where the +dnl core file went\". At least we should get some useful output ... use_assertions='yes' -# the following is set to yes or no later. +dnl the following is set to yes or no later. with_gif='' -# the following is set to yes or no later. +dnl the following is set to yes or no later. with_toolbars='' -with_tty='yes' use_union_type='no' with_dnet='' -# # gnu echo silently eats `--help', `--version', `-n', `-e', `-E', `-n'. -# # other versions of echo eat any strings beginning with `-n'. -# # when parsing arguments, special case these strings and don't -# # pass them through echo -# echo=/bin/echo -# -# this approach abandoned in favor of -# -# echo "" ${stuff_to_filter} | sed -e 's:^ ::' - -# On Sun systems, people sometimes set up the variable CPP -# with a value that is a directory, not an executable at all. -# Detect that case, and ignore that value. +dnl On Sun systems, people sometimes set up the variable CPP +dnl with a value that is a directory, not an executable at all. +dnl Detect that case, and ignore that value. test -n "$CPP" -a -d "$CPP" && CPP= -############################################################################ -# # -# Usage messages # -# # -############################################################################ - -short_usage="Usage: ${progname} CONFIGURATION [[-OPTION[=VALUE] ...]] +dnl Usage message (get it via -help) +usage="Usage: $progname CONFIGURATION [[-OPTION[=VALUE] ...]] Set compilation and installation parameters for XEmacs, and report. CONFIGURATION specifies the machine and operating system to build for. @@ -170,27 +325,25 @@ Options marked with a (*) are autodetected. - + General options: --help Issue this usage message. --verbose Display the results of configure tests. ---extra-verbose Also display the output of any compiler invocation. - (Useful when feature tests are coming out wrong.) - - -Compiler options: - ---compiler=XXXX Specify compiler. +--extra-verbose Display even more information, useful for debugging. + + +Compilation options: + +--compiler=XXXX Specify compiler. Overrides environment variable CC. --with-gcc (*) Use GCC to compile XEmacs. ---with-lcc Use Lucid's LCC to compile XEmacs. --with-gcc=no Don't use GCC to compile XEmacs. --with-gnu-make Write the Makefiles to take advantage of special features of GNU Make. (GNU Make works fine on the Makefiles even without this option. This just allows for simultaneous in-place and --srcdir building.) ---cflags=FLAGS Override the default values for CFLAGS. +--cflags=FLAGS Compiler flags. Overrides environment variable CFLAGS. --site-includes=DIR Other header file directories. Separate multiple dirs with spaces and use quotes to enclose. --site-libraries=DIR Other library directories. @@ -205,8 +358,8 @@ Installation options: - ---prefix=DIR Install files below DIR. Defaults to \`${prefix}'. + +--prefix=DIR Install files below DIR. Defaults to \`$prefix'. Window-system options: @@ -215,29 +368,49 @@ --with-x=no Don't support X. --x-includes=DIR Search for X header files in DIR. --x-libraries=DIR Search for X libraries in DIR. +--with-toolbars=no Don't compile with any toolbar support. --with-menubars=TYPE Use TYPE menubars (lucid, motif, or no). The Lucid widgets emulate Motif (mostly) but are faster. *WARNING* The Motif menubar is currently broken. ---with-scrollbars=TYPE Use TYPE scrollbars (lucid, motif, athena, - athena3d, or no). +--with-scrollbars=TYPE Use TYPE scrollbars + (lucid, motif, athena, athena3d, or no). --with-dialogs=TYPE Use TYPE dialog boxes (motif, athena, athena3d, or no). (Lucid menubars and scrollbars are the default. Motif dialog boxes will be used if Motif can be found.) --with-cde (*) Compile in support for CDE drag and drop. --with-offix (*) Compile in support for OffiX drag and drop. +--with-xmu=no (*) For those unfortunates whose vendors don't ship Xmu. +--external-widget Compile with external widget support. +--with-gif Compile with support for GIF image conversion. + This support is built-in and defaults to \`yes'. --with-xpm (*) Compile with support for XPM files. It is highly recommended that you obtain XPM - (version 3.4g or better) if you don't already + (version 3.4h or better) if you don't already have it. Get it from the XEmacs FTP site. ---with-xmu=no (*) For those unfortunates whose vendors don't ship Xmu. +--with-xface (*) Compile with support for X-Face mail header + conversion. Requires the compface library. + Get it from the XEmacs FTP site. +--with-jpeg (*) Compile with support for JPEG image conversion. + Requires libjpeg from the Independent JPEG Group. + Get it from the XEmacs FTP site. +--with-png (*) Compile with support for PNG image conversion. + Requires libpng. Get it from the XEmacs FTP site. +--with-tiff Compile with support for TIFF image conversion + (not yet implemented). + + +TTY options: + +--with-ncurses (*) Use the ncurses library for tty support. +--with-gpm (*) Compile in support for General Purpose Mouse. Additional features: ---with-toolbars=no Don't compile with any toolbar support. ---with-tooltalk Support the ToolTalk IPC protocol. ---with-sparcworks Support the Sun Sparcworks development environment. +--with-tooltalk (*) Support the ToolTalk IPC protocol. +--with-workshop Support the Sun WorkShop (formerly Sparcworks) + development environment. --with-energize Support the Lucid Energize development environment. This doesn't currently work. --with-socks Compile with support for SOCKS (an Internet proxy). @@ -247,25 +420,9 @@ used on Linux and other systems. NOTE: We can't guarantee that our TERM support coexists well with standard Internet connections). ---with-xface (*) Compile with support for X-Face mail header - conversion. Requires the compface library. - Get it from the XEmacs FTP site. ---with-gif Compile with support for GIF image conversion. - This requires no special support and defaults to - \`yes'. ---with-jpeg (*) Compile with support for JPEG image conversion. - Requires libjpeg from the Independent JPEG Group. - Get it from the XEmacs FTP site. ---with-png (*) Compile with support for PNG image conversion. - Requires libpng. Get it from the XEmacs FTP site. - Accepted values are \`yes', \`no', and \`gnuz' - if you want to use -lgz instead of -lz. ---with-tiff Compile with support for TIFF image conversion - (not yet implemented). --with-database=type (*) Compile with database support. Valid types are \`no' or a comma-separated list of one or more of \`dbm', \`gnudbm', or \`berkdb'. ---external-widget Compile with external widget support. --with-sound=native (*) Compile with native sound support. --with-sound=nas Compile with network sound support. --with-sound=both Compile with native and network sound support. @@ -275,12 +432,13 @@ --with-mocklisp Compile with Mocklisp support. Don't do this unless you have a Mocklisp program that you need to run. ---usage-tracking Enable some Sun-internal code. If you don't - know what this is, you don't want it. --with-pop support POP for mail retrieval --with-kerberos support Kerberos-authenticated POP --with-hesiod support Hesiod to get the POP server host --with-dnet (*) Compile with support for DECnet. +--mail-locking=TYPE (*) Specify the locking to be used by movemail to prevent + concurrent updates of mail spool files. Valid types + are \`lockf', \`flock', and \`lock-file'. Internationalization options: @@ -294,19 +452,15 @@ then the default is --with-xim=motif, else --with-xim=no. NOTE: On some systems like SunOS4 use of this option will cause XEmacs to crash at startup. ---with-canna Compile with support for Canna (a Japanese input method +--with-canna (*) Compile with support for Canna (a Japanese input method used in conjunction with Mule support). ---with-wnn Compile with support for WNN (a multi-language input method +--with-wnn (*) Compile with support for WNN (a multi-language input method used in conjunction with Mule support). This is beta level code. ---with-wnn6 Compile with support for WNN version 6 +--with-wnn6 (*) Compile with support for WNN version 6 This is alpha level code. ---wnn-includes=DIR Search for WNN header files in DIR. ---wnn-libraries=DIR Search for WNN libraries in DIR. --with-i18n3 Compile with I18N level 3 (support for message translation). This doesn't currently work. ---canna-includes=DIR Search for Canna header files in DIR. ---canna-libraries=DIR Search for Canna libraries in DIR. Debugging options: @@ -330,7 +484,7 @@ int, for the fundamental Lisp_Object type; this provides stricter type-checking. Only works with some systems and compilers. - + Other options: @@ -346,27 +500,34 @@ variables. See the INSTALL file for a complete list plus the reasons we advise not changing them. -If successful, ${progname} leaves its status in config.status. If -unsuccessful after disturbing the status quo, it removes config.status." - -############################################################################ -# # -# Options processing # -# # -############################################################################ +If successful, $progname leaves its status in config.status. If +unsuccessful after disturbing the status quo, it removes config.status. + +The configure build process also used the following environment variables: +CC C compiler to use (but configure flags take precedence) +CFLAGS C compiler compilation flags (such as -O) +CPPFLAGS Additional compilation flags (sucha s -I) used only by the preprocessor +LDFLAGS Additional linker flags + +For more details on the install process, consult the INSTALL file. +" + +dnl ------------------ +dnl Options Processing +dnl ------------------ define([USAGE_ERROR], -[(echo "${progname}: Usage error:" +[(echo "$progname: Usage error:" echo " " $1 -echo " Use \`${progname} --help' for more details.") >&2 && exit 1]) - -### Record all the arguments, so we can save them in config.status. +echo " Use \`$progname --help' to show usage.") >&2 && exit 1]) + +dnl Record all the arguments, so we can save them in config.status. arguments="$@" -### Shell Magic: Quote the quoted arguments in ARGUMENTS. At a later date, -### in order to get the arguments back in $@, we have to do an -### `eval set x "$quoted_arguments"; shift'. -### We use sed to turn embedded ' into '"'"'. I truly hate sh's quoting. +dnl Shell Magic: Quote the quoted arguments in ARGUMENTS. At a later date, +dnl in order to get the arguments back in $@, we have to do an +dnl 'eval set x "$quoted_arguments"; shift' +dnl # We use sed to turn embedded ' into '"'"'. I truly hate sh quoting. quoted_sed_magic=s/"'"/"'"'"'"'"'"'"'"/g quoted_arguments= for i in "$@"; do @@ -381,68 +542,70 @@ esac done -### Don't use shift -- that destroys the argument list, which autoconf needs -### to produce config.status. It turns out that "set - ${arguments}" doesn't -### work portably. -### However, it also turns out that many shells cannot expand ${10} at all. -### So using an index variable doesn't work either. It is possible to use -### some shell magic to make 'set x "$arguments"; shift' work portably. +dnl Do not use shift -- that destroys the argument list, which autoconf needs +dnl to produce config.status. It turns out that "set - $arguments" does not +dnl work portably. +dnl However, it also turns out that many shells cannot expand ${10} at all. +dnl So using an index variable does not work either. It is possible to use +dnl some shell magic to make 'set x "$arguments"; shift' work portably. while test $# != 0; do arg="$1"; shift - case "${arg}" in - - ## Anything starting with a hyphen we assume is an option. + case "$arg" in + + dnl Anything starting with a hyphen we assume is an option. -* ) - ## Separate the switch name from the value it's being given. - case "${arg}" in + dnl Separate the switch name from the value it is being given. + case "$arg" in -*=*) - opt=`echo '' ${arg} | sed -e 's:^ ::' -e 's:^-*\([[^=]]*\)=.*$:\1:'` - val=`echo '' ${arg} | sed -e 's:^ ::' -e 's:^-*[[^=]]*=\(.*\)$:\1:'` + opt=`echo '' $arg | sed -e 's:^ ::' -e 's:^-*\([[^=]]*\)=.*$:\1:'` + val=`echo '' $arg | sed -e 's:^ ::' -e 's:^-*[[^=]]*=\(.*\)$:\1:'` valomitted=no ;; -# ## special case these strings since echo may -# ## silently eat them. -# --help ) opt=help val=yes valomitted=yes ;; -# --version ) opt=version val=yes valomitted=yes ;; -# -e ) opt=e val=yes valomitted=yes ;; -# -E ) opt=E val=yes valomitted=yes ;; -# -n ) opt=n val=yes valomitted=yes ;; + dnl special case these strings since echo may silently eat them: + dnl --help ) opt=help val=yes valomitted=yes ;; + dnl --version ) opt=version val=yes valomitted=yes ;; + dnl -e ) opt=e val=yes valomitted=yes ;; + dnl -E ) opt=E val=yes valomitted=yes ;; + dnl -n ) opt=n val=yes valomitted=yes ;; -*) - ## If FOO is a boolean argument, --FOO is equivalent to - ## --FOO=yes. Otherwise, the value comes from the next - ## argument - see below. - opt=`echo '' ${arg} | sed -e 's:^ ::' -e 's:^-*\(.*\)$:\1:'` + dnl If FOO is a boolean argument, --FOO is equivalent to + dnl --FOO=yes. Otherwise, the value comes from the next + dnl argument - see below. + opt=`echo '' $arg | sed -e 's:^ ::' -e 's:^-*\(.*\)$:\1:'` val="yes" valomitted=yes ;; esac - ## Change `-' in the option name to `_'. - optname="${opt}" - opt="`echo '' ${opt} | sed -e 's:^ ::' | tr - _`" - - ## Process the option. - case "${opt}" in - - ## Process (many) boolean options + dnl translate "-" in option string to "_" + optname="$opt" + opt="`echo '' $opt | sed -e 's:^ ::' | tr - _`" + + dnl Process the option. + case "$opt" in + + dnl Process (many) boolean options run_in_place | \ with_x | \ with_x11 | \ with_gcc | \ - with_lcc | \ with_gnu_make | \ dynamic | \ + with_ncurses | \ + with_dnet | \ with_term | \ + with_socks | \ with_cde | \ with_offix | \ - with_xpm | \ + with_gpm | \ with_gif | \ + with_xpm | \ + with_xface | \ with_jpeg | \ + with_png | \ with_tiff | \ - with_socks | \ - with_xface | \ with_xmu | \ - quantify | \ + with_quantify | \ with_toolbars | \ with_tty | \ with_i18n3 | \ @@ -452,6 +615,7 @@ with_wnn6 | \ with_mocklisp | \ with_energize | \ + with_workshop | \ with_sparcworks | \ with_tooltalk | \ with_pop | \ @@ -467,131 +631,124 @@ debug | \ use_assertions | \ memory_usage_stats | \ - no_doc_file ) - ## Make sure the value given was either "yes" or "no". - case "${val}" in + no_doc_file ) + dnl Make sure the value given was either "yes" or "no". + case "$val" in y | ye | yes ) val=yes ;; n | no ) val=no ;; - * ) USAGE_ERROR("The \`--${optname}' option requires a boolean value: \`yes' or \`no'.") ;; + * ) USAGE_ERROR("The \`--$optname' option requires a boolean value: \`yes' or \`no'.") ;; esac - eval "${opt}=\"${val}\"" ;; - - - ## Options that take a user-supplied value, as in --puresize=8000000 + eval "$opt=\"$val\"" ;; + + + dnl Options that take a user-supplied value, as in --puresize=8000000 srcdir | \ compiler | \ puresize | \ native_sound_lib | \ x_includes | \ x_libraries | \ - wnn_includes | \ - wnn_libraries | \ - canna_includes | \ - canna_libraries | \ site_includes | \ site_libraries | \ - site_runtime_libraries ) - ## If the value was omitted, get it from the next argument. - if test "${valomitted}" = "yes" ; then - ## Get the next argument from the argument list, if there is one. - if test "$#" = 0 ; then - USAGE_ERROR("The \`--${optname}' option requires a value."); + site_runtime_libraries ) + dnl If the value was omitted, get it from the next argument. + if test "$valomitted" = "yes" ; then + dnl Get the next argument from the argument list, if there is one. + if test "$#" = 0 ; then + USAGE_ERROR("The \`--$optname' option requires a value."); fi val="$1"; shift fi - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ### Options that take "yes", "no", or "default" values + dnl Options that take "yes", "no", or "default" values rel_alloc | \ use_system_malloc ) - case "${val}" in + case "$val" in y | ye | yes ) val=yes ;; n | no ) val=no ;; d | de | def | defa | defau | defaul | default ) val=default ;; - * ) USAGE_ERROR(["The \`--${optname}' option requires one of these values: + * ) USAGE_ERROR(["The \`--$optname' option requires one of these values: \`yes', \`no', or \`default'."]) ;; esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Has the user requested database support? + dnl Has the user requested database support? "with_database" ) with_database_berkdb=no with_database_dbm=no with_database_gnudbm=no - ## Make sure the value given was `no' or a list of berkdb, dbm, gnudbm - for x in `echo "${val}" | sed 's/,/ /'` ; do - case "${x}" in + for x in `echo "$val" | sed 's/,/ /'` ; do + case "$x" in no ) : ;; b | be | ber | berk | berkd | berkdb ) with_database_berkdb=yes ;; d | db | dbm ) with_database_dbm=yes ;; g | gn | gnu | gnud | gnudb | gnudbm ) with_database_gnudbm=yes ;; - * ) USAGE_ERROR(["The \`--${optname}' option value + * ) USAGE_ERROR(["The \`--$optname' option value must be either \`no' or a comma-separated list of one or more of \`berkdb', \`dbm', or \`gnudbm'."]) ;; esac done - if test "${with_database_dbm}" = "yes" -a \ - "${with_database_gnudbm}" = "yes" ; then + if test "$with_database_dbm" = "yes" -a \ + "$with_database_gnudbm" = "yes" ; then USAGE_ERROR("Only one of \`dbm' and \`gnudbm' may be specified - with the \`--${optname}' option.") + with the \`--$optname' option.") fi ;; - ## Has the user requested sound support? + dnl Has the user requested sound support? "with_sound" ) - ## value can be native, nas or both. yes is allowed - ## as a backwards compatible synonym for native - case "${val}" in + dnl value can be native, nas or both. yes is allowed + dnl as a backwards compatible synonym for native + case "$val" in y | ye | yes ) val=native ;; n | no | non | none ) val=no;; na | nat | nati | nativ | native ) val=native ;; - ne | net | neta | netau | netaud | netaudi | netaudio | nas ) val=nas ;; + ne | net | neta | netau | netaud | netaudi | netaudio | nas ) val=nas ;; b | bo | bot | both ) val=both;; - * ) USAGE_ERROR(["The \`--${optname}' option must have one of these values: + * ) USAGE_ERROR(["The \`--$optname' option must have one of these values: \`native', \`nas', \`both', or \`none'."]) ;; esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Has the user requested XIM support? + dnl Has the user requested XIM support? "with_xim" ) - ## value can be xlib or motif - case "${val}" in - y | ye | yes ) val=yes ;; - n | no | non | none ) val=no ;; - x | xl | xli | xlib ) val=xlib ;; - m | mo | mot | moti | motif ) val=motif ;; - * ) USAGE_ERROR(["The \`--${optname}' option must have one of these values: + case "$val" in + y | ye | yes ) val=yes ;; + n | no | non | none ) val=no ;; + x | xl | xli | xlib ) val=xlib ;; + m | mo | mot | moti | motif ) val=motif ;; + * ) USAGE_ERROR(["The \`--$optname' option must have one of these values: \`motif', \`xlib', \`yes', or \`no'."]) ;; esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Has the user requested PNG support? - "with_png" ) - ## Make sure the value given was either "yes", "no", or "gnuz". - case "${val}" in - y | ye | yes ) val=yes ;; - n | no ) val=no ;; - g | gn | gnu | gnuz ) val=gnuz ;; - * ) USAGE_ERROR(["The \`--${optname}' option must have one of these values: - \`yes', \`no', or \`gnuz'."]) ;; + dnl Mail locking specification + "mail_locking" ) + case "$val" in + lockf ) val=lockf ;; + flock ) val=flock ;; + file ) val=file ;; + * ) USAGE_ERROR(["The \`--$optname' option must have one of these values: + \`lockf', \`flock', or \`file'."]) ;; esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Has the user requested error-checking? + dnl Has the user requested error-checking? "error_checking" ) - ## value can be all, none, and/or a list of categories to check. - ## Example: --error-checking=all,noextents,nobufpos - ## Example: --error-checking=none,malloc,gc - - for x in `echo "${val}" | sed 's/,/ /'` ; do - case "${x}" in - # all and none are only permitted as the first in the list. + dnl value can be all, none, and/or a list of categories to check. + dnl Example: --error-checking=all,noextents,nobufpos + dnl Example: --error-checking=none,malloc,gc + + for x in `echo "$val" | sed 's/,/ /'` ; do + case "$x" in + dnl all and none are only permitted as the first in the list. n | no | non | none ) new_default=no ;; a | al | all ) new_default=yes ;; @@ -609,7 +766,7 @@ malloc ) error_check_malloc=yes ;; nomalloc ) error_check_malloc=no ;; - + * ) bogus_error_check=yes ;; esac if test "$bogus_error_check" -o \ @@ -619,7 +776,7 @@ else types="\`all', \`none' (default), \`extents', \`typecheck', \`bufpos', \`gc', and \`malloc'." fi - USAGE_ERROR(["Valid types for the \`--${optname}' option are: + USAGE_ERROR(["Valid types for the \`--$optname' option are: $types."]) elif test "$new_default" ; then error_check_extents=$new_default @@ -633,227 +790,219 @@ done ;; - ## Has the user tried to tell us where the X files are? - ## I think these are dopey, but no less than three alpha - ## testers, at large sites, have said they have their X files - ## installed in odd places. - - ## Has the user specified one of the path options? + dnl Has the user tried to tell us where the X files are? + dnl I think these are dopey, but no less than three alpha + dnl testers, at large sites, have said they have their X files + dnl installed in odd places. + + dnl Has the user specified one of the path options? prefix | exec_prefix | bindir | datadir | statedir | libdir | \ mandir | infodir | lispdir | etcdir | lockdir | archlibdir | \ sitelispdir | docdir ) - ## If the value was omitted, get it from the next argument. - if test "${valomitted}" = "yes" ; then + dnl If the value was omitted, get it from the next argument. + if test "$valomitted" = "yes" ; then if test "$#" = 0 ; then - USAGE_ERROR("The \`--${optname}' option requires a value."); + USAGE_ERROR("The \`--$optname' option requires a value."); fi val="$1"; shift fi - eval "${opt}=\"${val}\"" - - ## Changing exec_prefix or libdir will change the default value - ## of archlibdir. Changing datadir will change the default value - ## of etcdir and lispdir. Changing statedir will change the - ## default value of lockdir. - if test "${opt}" = exec_prefix; then archlibdir_user_defined=yes - elif test "${opt}" = libdir ; then archlibdir_user_defined=yes - elif test "${opt}" = archlibdir ; then archlibdir_user_defined=yes - elif test "${opt}" = lispdir ; then lispdir_user_defined=yes - elif test "${opt}" = etcdir ; then etcdir_user_defined=yes - elif test "${opt}" = datadir ; then - lispdir_user_defined=yes - etcdir_user_defined=yes - elif test "${opt}" = statedir ; then lockdir_user_defined=yes - elif test "${opt}" = lockdir ; then lockdir_user_defined=yes - elif test "${opt}" = infodir ; then infodir_user_defined=yes - fi + eval "$opt=\"$val\"" + + dnl Changing exec_prefix or libdir will change the default value + dnl of archlibdir. Changing datadir will change the default value + dnl of etcdir and lispdir. Changing statedir will change the + dnl default value of lockdir. + case "$opt" in + lispdir ) lispdir_user_defined=yes ;; + etcdir ) etcdir_user_defined=yes ;; + infodir ) infodir_user_defined=yes ;; + datadir ) lispdir_user_defined=yes etcdir_user_defined=yes ;; + statedir | lockdir ) lockdir_user_defined=yes ;; + exec_prefix | libdir | archlibdir ) archlibdir_user_defined=yes ;; + esac ;; - ## Has the user specified values to override CFLAGS? + dnl Has the user specified values to override CFLAGS? cflags ) - ## If the value was omitted, get it from the next argument. - if test "${valomitted}" = "yes" ; then - if test "$#" = 0 ; then - USAGE_ERROR("The \`--${optname}' option requires a value."); + dnl If the value was omitted, get it from the next argument. + if test "$valomitted" = "yes" ; then + if test "$#" = 0; then + USAGE_ERROR("The \`--$optname' option requires a value."); fi val="$1"; shift fi - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" eval "${opt}_specified=1" ;; - ## --no-create added by autoconf for use by config.status - "no_create" ) - ;; - - ## Has the user asked for some help? - "usage" | "help" ) - echo "${short_usage}" | ${PAGER:-more} - exit 0 - ;; - - ## Has the user specified what toolkit to use for the menubars, - ## scrollbar or dialogs? + dnl --no-create added by autoconf for use by config.status + "no_create" ) ;; + + dnl Has the user asked for some help? + "usage" | "help" ) echo "$usage" | ${PAGER-more}; exit 0 ;; + + dnl Has the user specified what toolkit to use for the menubars, + dnl scrollbar or dialogs? "with_menubars" | "with_scrollbars" | "with_dialogs" ) - ## value can be lucid, motif, or athena. - case "${val}" in + case "$val" in l | lu | luc | luci | lucid ) val=lucid ;; m | mo | mot | moti | motif ) val=motif ;; athena3d | athena-3d ) val=athena3d ;; a | at | ath | athe | athen | athena ) val=athena ;; n | no | non | none ) val=no ;; - * ) USAGE_ERROR(["The \`--${optname}' option must have one of these values: - \`lucid', \`motif', \`athena', or \`no'."]) ;; + * ) USAGE_ERROR(["The \`--$optname' option must have one of these values: + \`lucid', \`motif', \`athena', \`athena3d', or \`no'."]) ;; esac - eval "${opt}=\"${val}\"" + eval "$opt=\"$val\"" ;; - ## Fail on unrecognized arguments. - * ) USAGE_ERROR("Unrecognized option: ${arg}") ;; + dnl Fail on unrecognized arguments. + * ) USAGE_ERROR("Unrecognized option: $arg") ;; esac ;; - ## Anything not starting with a hyphen we assume is a - ## configuration name. - *) - configuration=${arg} - ;; + dnl Anything not starting with a hyphen we assume is a + dnl configuration name. + *) configuration="$arg" ;; esac done -############################################################################ -# # -# Finish options processing # -# # -############################################################################ - -### Get the arguments back. See the diatribe on Shell Magic above. +dnl ------------------------- +dnl Finish options processing +dnl ------------------------- + +dnl Get the arguments back. See the diatribe on Shell Magic above. eval set x "$quoted_arguments"; shift -### Argument interdependencies -if test "${with_energize}" = "yes" ; then - with_menubars="lucid" - with_scrollbars="motif" - with_dialogs="motif" - with_tooltalk="yes" - internal_makefile_list="$internal_makefile_list lwlib/energize/Makefile.in" +dnl Argument interdependencies +if test "$with_energize" = "yes" ; then + with_menubars=lucid with_scrollbars=motif with_dialogs=motif with_tooltalk=yes + MAKE_SUBDIR="$MAKE_SUBDIR lwlib/energize" +fi + +dnl --extra-verbose implies --verbose +test "$extra_verbose" = "yes" && verbose=yes + +dnl Sun Development environment support +test "$with_sparcworks" = "yes" && with_workshop=yes # compatibility alias +if test "$with_workshop" = "yes"; then + AC_DEFINE(SUNPRO) + extra_objs="$extra_objs sunpro.o" + with_tooltalk=yes fi -### --extra-verbose implies --verbose -test "${extra_verbose}" = yes && verbose=yes - -### Sparcworks requires tooltalk -test "${with_sparcworks}" = yes && with_tooltalk=yes - -### debug implies other options -test "${debug}" = "yes" && use_assertions=yes memory_usage_stats=yes - -### with_x is a synonym for with_x11 -test -n "${with_x}" && with_x11="${with_x}" - -### Can't specify 2 compilers -if test "${with_gcc}" = "yes" -a "${with_lcc}" = "yes"; then - USAGE_ERROR("Only one of --with-gcc and --with-lcc may be specified.") +dnl Allow use of either ":" or spaces for lists of directories +define(COLON_TO_SPACE, + [case "[$1]" in *:* [)] [$1]="`echo $[$1] | sed 's/:/ /g'`";; esac])dnl +COLON_TO_SPACE(site_includes) +COLON_TO_SPACE(site_libraries) +COLON_TO_SPACE(site_runtime_libraries) + +dnl debug implies other options +if test "$debug" = "yes"; then + use_assertions=yes memory_usage_stats=yes + extra_objs="$extra_objs debug.o" fi -### Ignore useless run-in-place flag -if test "${run_in_place}" = "yes"; then - AC_WARN(The --run-in-place option is ignored because it is unnecessary.) +dnl with_x is obsolete synonym for with_x11 +test -n "$with_x" && with_x11="$with_x" + +dnl# Ignore useless run-in-place flag +if test "$run_in_place" = "yes"; then + AC_MSG_WARN("The --run-in-place option is ignored because it is unnecessary.") fi -########################################################################### -if test "${configuration}" = "" ; then +dnl ########################################################################### +if test "$configuration" = "" ; then echo '- You did not tell me what kind of host system you want to configure. - I will attempt to guess the kind of system this is.' 1>&2 - guesssys=`echo ${progname} | sed 's/configure$/config.guess/'` - if configuration=`${CONFIG_SHELL-/bin/sh} ${guesssys}` ; then - echo "- Looks like this is a ${configuration}" 1>&2 + guesssys=`echo $progname | sed 's/configure$/config.guess/'` + dnl Guess the configuration and remove 4th name component, if present. + if configuration=`${CONFIG_SHELL-/bin/sh} $guesssys | \ + sed '[s/^\([^-][^-]*-[^-][^-]*-[^-][^-]*\)-.*$/\1/]'` ; then + echo "- Looks like this is a $configuration" 1>&2 else USAGE_ERROR("Failed to guess the system type. You need to tell me.") fi fi -### Find the source directory. -case "${srcdir}" in - - ## If it's not specified, see if `.' or `..' might work. +dnl Find the source directory. +case "$srcdir" in + + dnl If srcdir is not specified, see if "." or ".." might work. "" ) for dir in "`echo $0 | sed 's|//|/|' | sed 's|/[[^/]]*$||'`" "." ".." ; do if test -f "$dir/src/lisp.h" -a \ -f "$dir/lisp/version.el" ; then - srcdir="${dir}" + srcdir="$dir" break fi done - if test -z "${srcdir}" ; then + if test -z "$srcdir" ; then USAGE_ERROR(["Neither the current directory nor its parent seem to contain the XEmacs sources. If you do not want to build XEmacs in its - source tree, you should run \`${progname}' in the directory in which + source tree, you should run \`$progname' in the directory in which you wish to build XEmacs, using the \`--srcdir' option to say where the sources may be found."]) fi ;; - ## Otherwise, check if the directory they specified is okay. + dnl Otherwise, check if the directory they specified is okay. * ) - if test ! -d "${srcdir}" -o \ - ! -f "${srcdir}/src/lisp.h" -o \ - ! -f "${srcdir}/lisp/version.el" ; then + if test ! -d "$srcdir" -o \ + ! -f "$srcdir/src/lisp.h" -o \ + ! -f "$srcdir/lisp/version.el" ; then USAGE_ERROR(["The directory specified with the \`--srcdir' option, - \`${srcdir}', doesn't seem to contain the XEmacs sources. You should - either run the \`${progname}' script at the top of the XEmacs source + \`$srcdir', doesn't seem to contain the XEmacs sources. You should + either run the \`$progname' script at the top of the XEmacs source tree, or use the \`--srcdir' option to specify the XEmacs source directory."]) fi ;; esac -## We check for this now instead of later when we check for other -## programs because we need to use its return value now. -AC_LN_S - -AC_VERBOSE("setting LN_S to ${LN_S}") - -#### Make symlinks for etc, lisp, and info directories while the path -#### is still relative. We don't symlink lock because someone may -#### have stuck the source on a read-only partition. Instead we'll -#### create it as an actual directory later on if it doesn't already -#### exist. +AC_PROG_LN_S + +dnl Make symlinks for etc, lisp, and info directories while the path +dnl is still relative. We do not symlink lock because someone may +dnl have stuck the source on a read-only partition. Instead we +dnl create it as an actual directory later on if it does not already +dnl exist. for dir in lisp etc man info site-lisp do - if test ! -d $dir ; then - echo Making symbolic link to ${srcdir}/$dir - ${LN_S} ${srcdir}/$dir . + if test ! -d "$dir" ; then + echo Making symbolic link to "$srcdir/$dir" + ${LN_S} "$srcdir/$dir" . fi done -#### Make srcdir absolute, if it isn't already. It's important to -#### avoid running the path through pwd unnecessary, since pwd can -#### give you automounter prefixes, which can go away. -case "${srcdir}" in +dnl Make srcdir absolute, if not already. It is important to +dnl avoid running the path through pwd unnecessary, since pwd can +dnl give you automounter prefixes, which can go away. +case "$srcdir" in /* ) ;; . ) - ## We may be able to use the $PWD environment variable to make this - ## absolute. But sometimes PWD is inaccurate. - if test "${PWD}" != "" -a "`(cd ${PWD} ; sh -c pwd)`" = "`pwd`"; then + dnl We may be able to use the $PWD environment variable to make this + dnl absolute. But sometimes PWD is inaccurate. + if test "$PWD" != "" -a "`(cd $PWD ; sh -c pwd)`" = "`pwd`"; then srcdir="$PWD" else - srcdir="`(cd ${srcdir}; pwd)`" + srcdir="`(cd $srcdir && pwd)`" fi ;; - * ) srcdir="`(cd ${srcdir}; pwd)`" ;; + * ) srcdir="`(cd $srcdir && pwd)`" ;; esac -#### Check if the source directory already has a configured system in it. -if test `pwd` != `sh -c cd ${srcdir} && pwd` \ - && test -f "${srcdir}/src/config.h"; then - (echo "${progname}: WARNING: The directory tree \`${srcdir}' is being used" +dnl Check if the source directory already has a configured system in it. +if test `pwd` != `sh -c cd $srcdir && pwd` \ + && test -f "$srcdir/src/config.h"; then + (echo "$progname: WARNING: The directory tree \`$srcdir' is being used" echo " as a build directory right now; it has been configured in its own" echo " right. To configure in another directory as well, you MUST" echo " use GNU make. If you do not have GNU make, then you must" - echo " now do \`make distclean' in ${srcdir}," - echo " and then run ${progname} again.") >&2 + echo " now do \`make distclean' in $srcdir," + echo " and then run $progname again.") >&2 extrasub='/^VPATH[[ ]]*=/c\ vpath %.c $(srcdir)\ vpath %.h $(srcdir)\ @@ -863,256 +1012,249 @@ vpath %.in $(srcdir)' fi -### Make the necessary directories, if they don't exist. +dnl Make the necessary directories, if they do not exist. for dir in ./src ./lib-src ./dynodump ./lwlib ./lock ; do - if test ! -d ${dir} ; then - mkdir ${dir} - fi + test ! -d "$dir" && mkdir "$dir" done -if test "${with_energize}" = "yes" -a ! -d ./lwlib/energize; then +if test "$with_energize" = "yes" -a ! -d ./lwlib/energize; then mkdir ./lwlib/energize fi -############################################################################ -# # -# Determine the s&m files to use # -# # -############################################################################ - -#### Given the configuration name, set machfile and opsysfile to the -#### names of the m/*.h and s/*.h files we should use. - -### Canonicalize the configuration name. -echo "checking the configuration name" -# allow -energize prefix on configuration name -internal_configuration=`echo ${configuration} | sed 's/-energize//'` -# allow --sparcworks prefix on configuration name -internal_configuration=`echo ${configuration} | sed 's/-sparcworks//'` -if canonical=`${srcdir}/config.sub "${internal_configuration}"` ; then : ; else +dnl ------------------------------ +dnl Determine the s&m files to use +dnl ------------------------------ +dnl Given the configuration name, set machfile and opsysfile to the +dnl names of the m/*.h and s/*.h files we should use. + +dnl Canonicalize the configuration name. +AC_CHECKING("the configuration name") +dnl allow -energize or -workshop suffix on configuration name +internal_configuration=`echo $configuration | sed 's/-\(energize\|workshop\)//'` +if canonical=`$srcdir/config.sub "$internal_configuration"` ; then : ; else exit $? fi -### If you add support for a new configuration, add code to this -### switch statement to recognize your configuration name and select -### the appropriate operating system and machine description files. - -### You would hope that you could choose an m/*.h file pretty much -### based on the machine portion of the configuration name, and an s- -### file based on the operating system portion. However, it turns out -### that each m/*.h file is pretty manufacturer-specific - for -### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are -### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS -### machines. So we basically have to have a special case for each -### configuration name. -### -### As far as handling version numbers on operating systems is -### concerned, make sure things will fail in a fixable way. If -### /etc/MACHINES doesn't say anything about version numbers, be -### prepared to handle anything reasonably. If version numbers -### matter, be sure /etc/MACHINES says something about it. -### -### Eric Raymond says we should accept strings like "sysvr4" to mean -### "System V Release 4"; he writes, "The old convention encouraged -### confusion between `system' and `release' levels'." - -machine='' opsys='' unported=no need_dynodump=no -case "${canonical}" in - - ## NetBSD ports +dnl If you add support for a new configuration, add code to this +dnl switch statement to recognize your configuration name and select +dnl the appropriate operating system and machine description files. + +dnl You would hope that you could choose an m/*.h file pretty much +dnl based on the machine portion of the configuration name, and an s- +dnl file based on the operating system portion. However, it turns out +dnl that each m/*.h file is pretty manufacturer-specific - for +dnl example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are +dnl all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS +dnl machines. So we basically have to have a special case for each +dnl configuration name. + +dnl As far as handling version numbers on operating systems is +dnl concerned, make sure things will fail in a fixable way. If +dnl /etc/MACHINES says nothing about version numbers, be +dnl prepared to handle anything reasonably. If version numbers +dnl matter, be sure /etc/MACHINES says something about it. + +dnl Eric Raymond says we should accept strings like "sysvr4" to mean +dnl "System V Release 4"; he writes, "The old convention encouraged" +dnl "confusion between `system' and `release' levels'." + +machine='' opsys='' need_dynodump=no + +dnl Straightforward machine determination +case "$canonical" in + sparc-*-* ) machine=sparc ;; + alpha-*-* ) machine=alpha ;; + vax-*-* ) machine=vax ;; + mips-dec-* ) machine=pmax ;; + mips-sgi-* ) machine=iris4d ;; + romp-ibm-* ) machine=ibmrt ;; + rs6000-ibm-aix* ) machine=ibmrs6000 ;; + powerpc-ibm-aix* ) machine=ibmrs6000 ;; + powerpc-*-* ) machine=powerpc ;; + hppa-*-* ) machine=hp800 ;; + m88k-dg-* ) machine=aviion ;; + m68*-sony-* ) machine=news ;; + mips-sony-* ) machine=news-risc ;; + clipper-* ) machine=clipper ;; +esac + +dnl Straightforward OS determination +case "$canonical" in + *-*-linux* ) opsys=linux ;; + *-*-netbsd* ) opsys=netbsd ;; + *-*-nextstep* ) opsys=nextstep ;; + *-*-vms ) opsys=vms ;; + + dnl DEC OSF + *-dec-osf1.3 | *-dec-osf2* ) opsys=decosf1-3 ;; + *-dec-osf1.2 | *-dec-osf1* ) opsys=decosf1-2 ;; + *-dec-osf3.[[2-9]] ) opsys=decosf3-2 ;; + *-dec-osf3* ) opsys=decosf3-1 ;; + *-dec-osf4* ) opsys=decosf4-0 ;; + + dnl DEC Ultrix + *-*-ultrix[[0-3]].* | *-*-ultrix4.0* ) opsys=bsd4-2 ;; + *-*-ultrix4.[[12]]* ) opsys=bsd4-3 ;; + *-*-ultrix* ) opsys=ultrix4-3 ;; + + dnl AIX + *-*-aix3.1* ) opsys=aix3-1 ;; + *-*-aix3.2.5 ) opsys=aix3-2-5 ;; + *-*-aix3* ) opsys=aix3-2 ;; + *-*-aix4.2* ) opsys=aix4-2 ;; + *-*-aix4.1* ) opsys=aix4-1 ;; + *-*-aix4* ) opsys=aix4 ;; + + dnl Other generic OSes + *-gnu* ) opsys=gnu ;; + *-*-bsd4.[[01]] ) opsys=bsd4-1 ;; + *-*-bsd4.2 ) opsys=bsd4-2 ;; + *-*-bsd4.3 ) opsys=bsd4-3 ;; + *-*-aos4.2 ) opsys=bsd4-2 ;; + *-*-aos* ) opsys=bsd4-3 ;; + *-*-sysv0 | *-*-sysvr0 ) opsys=usg5-0 ;; + *-*-sysv2 | *-*-sysvr2 ) opsys=usg5-2 ;; + *-*-sysv2.2 | *-*-sysvr2.2 ) opsys=usg5-2-2 ;; + *-*-sysv3* | *-*-sysvr3* ) opsys=usg5-3 ;; + *-*-sysv4.1* | *-*-sysvr4.1* )opsys=usg5-4 NON_GNU_CPP=/usr/lib/cpp ;; + *-*-sysv4.[[2-9]]* | *-sysvr4.[[2-9]]* ) + if test -z "$NON_GNU_CPP" ; then + if test -f /usr/ccs/lib/cpp + then NON_GNU_CPP=/usr/ccs/lib/cpp + else NON_GNU_CPP=/lib/cpp + fi + fi + opsys=usg5-4-2 ;; + *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;; + *-*-mach_bsd4.3* ) opsys=mach-bsd4-3 ;; +esac + +case "$canonical" in + + dnl NetBSD ports *-*-netbsd* ) - opsys=netbsd - case "${canonical}" in - sparc-*-netbsd*) machine=sparc ;; + case "$canonical" in i[[3-9]]86-*-netbsd*) machine=intel386 ;; hp300-*-netbsd* | amiga-*-netbsd* | sun3-*-netbsd* | mac68k-*-netbsd* | da30-*-netbsd* | m68k-*-netbsd* ) - # Yes, this is somewhat bogus. + dnl Yes, this is somewhat bogus. machine=hp9000s300 ;; pc532-*-netbsd* | ns32k-*-netbsd* ) machine=ns32000 ;; pmax-*-netbsd* | mips-*-netbsd* ) machine=pmax ;; esac ;; - ## Acorn RISCiX: + dnl Acorn RISCiX: arm-acorn-riscix1.1* ) machine=acorn opsys=riscix1-1 ;; arm-acorn-riscix1.2* | arm-acorn-riscix ) machine=acorn opsys=riscix1-2 ;; - ## Alliant machines - ## Strictly speaking, we need the version of the alliant operating - ## system to choose the right machine file, but currently the - ## configuration name doesn't tell us enough to choose the right - ## one; we need to give alliants their own operating system name to - ## do this right. When someone cares, they can help us. + dnl Alliant machines fx80-alliant-* ) machine=alliant4 opsys=bsd4-2 ;; i860-alliant-* ) machine=alliant-2800 opsys=bsd4-3 ;; - ## Alpha (DEC) machines. - ## XEmacs change: split apart into numerous files. - alpha-*-* ) - machine=alpha - case "${canonical}" in - *-dec-osf1.3 | *-dec-osf2* ) opsys=decosf1-3 ;; - *-dec-osf1.2 | *-dec-osf1* ) opsys=decosf1-2 ;; - - ## XEmacs: Add switch for OSF 1 version 3 (roth@cse.ucsc.edu) - ## XEmacs: Add switch for Digital Unix version 4 (srivasta@pilgrim.umass.edu) - *-dec-osf3.[[2-9]] ) opsys=decosf3-2 ;; - *-dec-osf3* ) opsys=decosf3-1 ;; - *-dec-osf4* ) opsys=decosf4-0 ;; - *-*-linux* ) opsys=linux ;; - esac - ;; - - ## Altos 3068 + dnl Altos 3068 m68*-altos-sysv* ) machine=altos opsys=usg5-2 ;; - ## Amdahl UTS + dnl Amdahl UTS 580-amdahl-sysv* ) machine=amdahl opsys=usg5-2-2 ;; - ## Apollo, Domain/OS + dnl Apollo, Domain/OS m68*-apollo-* ) machine=apollo opsys=bsd4-3 ;; - - ## AT&T 3b2, 3b5, 3b15, 3b20 + + dnl AT&T 3b2, 3b5, 3b15, 3b20 we32k-att-sysv* ) machine=att3b opsys=usg5-2-2 ;; - ## AT&T 3b1 - The Mighty Unix PC! + dnl AT&T 3b1 - The Mighty Unix PC! m68*-att-sysv* ) machine=7300 opsys=usg5-2-2 ;; - ## Bull machines + dnl Bull machines rs6000-bull-bosx* ) machine=ibmrs6000 opsys=aix3-2 ;; # dpx20 m68*-bull-sysv3* ) machine=dpx2 opsys=usg5-3 ;; # dpx2 m68*-bull-sysv2* ) machine=sps7 opsys=usg5-2 ;; # sps7 - ## CCI 5/32, 6/32 -- see "Tahoe". - - ## Celerity - ## I don't know what configuration name to use for this; config.sub - ## doesn't seem to know anything about it. Hey, Celerity users, get - ## in touch with us! + dnl CCI 5/32, 6/32 -- see "Tahoe". + + dnl Celerity celerity-celerity-bsd* ) machine=celerity opsys=bsd4-2 ;; - ## Clipper - ## What operating systems does this chip run that XEmacs has been - ## tested on? - clipper-* ) machine=clipper - ## We'll use the catch-all code at the bottom to guess the - ## operating system. - ;; - - ## Convex + dnl Convex *-convex-bsd* | *-convex-convexos* ) machine=convex opsys=bsd4-3 - ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov NON_GNU_CPP="cc -E -P" ;; - ## Cubix QBx/386 + dnl Cubix QBx/386 i[[3-9]]86-cubix-sysv* ) machine=intel386 opsys=usg5-3 ;; - ## Cydra 5 + dnl Cydra 5 cydra*-cydrome-sysv* ) machine=cydra5 opsys=usg5-3 ;; - ## Data General AViiON Machines + dnl Data General AViiON Machines i586-dg-dgux*R4* | i586-dg-dgux5.4.4* ) machine=aviion opsys=dgux5-4r4 ;; - m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* ) machine=aviion opsys=dgux5-4r3 ;; - m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* ) machine=aviion opsys=dgux5-4r2 ;; - m88k-dg-dgux* ) machine=aviion opsys=dgux ;; - - ## Dec Mips machines - mips-dec-* ) - machine=pmax - case "${canonical}" in - *-*-ultrix[[0-3]].* | *-*-ultrix4.0* | *-*-bsd4.2* ) opsys=bsd4-2 ;; - *-*-ultrix4.[[12]]* | *-*-bsd* ) opsys=bsd4-3 ;; - *-*-ultrix* ) opsys=ultrix4-3 ;; - *-*-osf* ) opsys=osf1 ;; - *-*-mach_bsd4.3* ) opsys=mach-bsd4-3 ;; - esac - ;; - - ## Motorola Delta machines - m68k-motorola-sysv* | m68000-motorola-sysv* ) - machine=delta opsys=usg5-3 - if test -z "`type gnucc | grep 'not found'`" - then - if test -s /etc/167config - then CC="gnucc -m68040" - else CC="gnucc -m68881" - fi - else - if test -z "`type gcc | grep 'not found'`" - then CC=gcc - else CC=cc - fi - fi - ;; + m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* ) opsys=dgux5-4r3 ;; + m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* ) opsys=dgux5-4r2 ;; + m88k-dg-dgux* ) opsys=dgux ;; + + dnl Motorola Delta machines + m68k-motorola-sysv* | m68000-motorola-sysv* ) machine=delta opsys=usg5-3 ;; m88k-motorola-sysv4* ) - # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110 - # needs POSIX_SIGNALS and therefore needs usg5-4-2. - # I hope there are not other 4.0 versions for this machine - # which really need usg5-4 instead. + dnl jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110 + dnl needs POSIX_SIGNALS and therefore needs usg5-4-2. + dnl I hope there are not other 4.0 versions for this machine + dnl which really need usg5-4 instead. machine=delta88k opsys=usg5-4-2 ;; m88k-motorola-sysv* | m88k-motorola-m88kbcs* ) machine=delta88k opsys=usg5-3 ;; - ## Dual machines + dnl Dual machines m68*-dual-sysv* ) machine=dual opsys=usg5-2 ;; m68*-dual-uniplus* ) machine=dual opsys=unipl5-2 ;; - ## Elxsi 6400 + dnl Elxsi 6400 elxsi-elxsi-sysv* ) machine=elxsi opsys=usg5-2 ;; - ## Encore machines + dnl Encore machines ns16k-encore-bsd* ) machine=ns16000 opsys=umax ;; - ## Gould Power Node and NP1 + dnl Gould Power Node and NP1 pn-gould-bsd4.2* ) machine=gould opsys=bsd4-2 ;; pn-gould-bsd4.3* ) machine=gould opsys=bsd4-3 ;; np1-gould-bsd* ) machine=gould-np1 opsys=bsd4-3 ;; - ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000 - ## as far as XEmacs is concerned). + dnl Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000 + dnl as far as XEmacs is concerned). m88k-harris-cxux* ) - # Build needs to be different on 7.0 and later releases + dnl Build needs to be different on 7.0 and later releases case "`uname -r`" in [[56]].[[0-9]] ) machine=nh4000 opsys=cxux ;; [[7]].[[0-9]] ) machine=nh4000 opsys=cxux7 ;; esac NON_GNU_CPP="/lib/cpp" ;; - ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000) + dnl Harris ecx or gcx running CX/UX (Series 1200, Series 3000) m68k-harris-cxux* ) machine=nh3000 opsys=cxux ;; - ## Harris power pc NightHawk running Power UNIX (Series 6000) - powerpc-harris-powerunix ) - machine=nh6000 opsys=powerunix - NON_GNU_CPP="cc -Xo -E -P" - ;; - - ## Honeywell XPS100 + dnl Harris power pc NightHawk running Power UNIX (Series 6000) + powerpc-harris-powerunix ) machine=nh6000 opsys=powerunix NON_GNU_CPP="cc -Xo -E -P" ;; + + dnl Honeywell XPS100 xps*-honeywell-sysv* ) machine=xps100 opsys=usg5-2 ;; - ## HP 9000 series 200 or 300 + dnl HP 9000 series 200 or 300 m68*-hp-bsd* ) machine=hp9000s300 opsys=bsd4-3 ;; - ## HP-UX on HP's + dnl HP-UX *-hp-hpux* ) - NON_GNU_CC="cc -Aa" - NON_GNU_CPP="cc -Aa -E" - - ### Figure out machine and opsys orthogonally - case "${canonical}" in + dnl Figure out machine and opsys orthogonally + case "$canonical" in m68* ) machine=hp9000s300 ;; hppa* ) machine=hp800 ;; esac - case "${canonical}" in - *-hp-hpux7* ) opsys=hpux ;; - *-hp-hpux8* ) opsys=hpux8 ;; - *-hp-hpux9* ) opsys=hpux9 ;; - *-hp-hpux10* ) opsys=hpux10 ;; + case "$canonical" in + *-hp-hpux7* ) opsys=hpux ;; + *-hp-hpux8* ) opsys=hpux8 ;; + *-hp-hpux9* ) opsys=hpux9 ;; + *-hp-hpux10* ) opsys=hpux10 ;; * ) case "`uname -r`" in - ## Someone's system reports A.B8.05 for this. - ## I wonder what other possibilities there are. *.B8.* ) opsys=hpux8 ;; *.08.* ) opsys=hpux8 ;; *.09.* ) opsys=hpux9 ;; @@ -1122,99 +1264,68 @@ ;; esac - if test $opsys = hpux10 ; then - NON_GNU_CC="cc -Ae" - NON_GNU_CPP="cc -Ae -E" - fi - - case "${canonical}" in *-hp-hpux*shr* ) opsys="${opsys}-shr" ;; esac + dnl HP has a broken "strcat" + case "$opsys" in hpux9 | hpux10 ) extra_objs="$extra_objs strcat.o";; esac + + if test "$opsys" = "hpux10"; then ansi_flag="-Ae"; else ansi_flag="-Aa"; fi + NON_GNU_CC="cc $ansi_flag" NON_GNU_CPP="cc $ansi_flag -E" + + case "$canonical" in *-hp-hpux*shr* ) opsys="${opsys}-shr" ;; esac ;; - hppa-*-nextstep* ) machine=hp800 opsys=nextstep ;; - - ## Orion machines + dnl Orion machines orion-orion-bsd* ) machine=orion opsys=bsd4-2 ;; clipper-orion-bsd* ) machine=orion105 opsys=bsd4-2 ;; - ## IBM machines + dnl IBM machines i[[3-9]]86-ibm-aix1.1* ) machine=ibmps2-aix opsys=usg5-2-2 ;; i[[3-9]]86-ibm-aix1.[[23]]* | i[[3-9]]86-ibm-aix* ) machine=ibmps2-aix opsys=usg5-3 ;; i370-ibm-aix*) machine=ibm370aix opsys=usg5-3 ;; - rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* ) machine=ibmrs6000 opsys=aix3-1 ;; - rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 ) machine=ibmrs6000 opsys=aix3-2-5 ;; - rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* ) machine=ibmrs6000 opsys=aix4-2 ;; - rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* ) machine=ibmrs6000 opsys=aix4-1 ;; - rs6000-ibm-aix4* | powerpc-ibm-aix4* ) machine=ibmrs6000 opsys=aix4 ;; - rs6000-ibm-aix* | powerpc-ibm-aix* ) machine=ibmrs6000 opsys=aix3-2 ;; - romp-ibm-bsd4.3* ) machine=ibmrt opsys=bsd4-3 ;; - romp-ibm-bsd4.2* ) machine=ibmrt opsys=bsd4-2 ;; - romp-ibm-aos4.3* ) machine=ibmrt opsys=bsd4-3 ;; - romp-ibm-aos4.2* ) machine=ibmrt opsys=bsd4-2 ;; - romp-ibm-aos* ) machine=ibmrt opsys=bsd4-3 ;; - romp-ibm-bsd* ) machine=ibmrt opsys=bsd4-3 ;; - romp-ibm-aix* ) machine=ibmrt-aix opsys=usg5-2-2 ;; - romp-ibm-mach* ) machine=ibmrt opsys=mach-bsd4-3 ;; - - ## Integrated Solutions `Optimum V' + romp-ibm-aos* ) opsys=bsd4-3 ;; + romp-ibm-bsd* ) opsys=bsd4-3 ;; + romp-ibm-mach* ) opsys=mach-bsd4-3 ;; + + dnl Integrated Solutions "Optimum V" m68*-isi-bsd4.2* ) machine=isi-ov opsys=bsd4-2 ;; m68*-isi-bsd4.3* ) machine=isi-ov opsys=bsd4-3 ;; - ## Intel 386 machines where we do care about the manufacturer + dnl Intel 386 machines where we do care about the manufacturer i[[3-9]]86-intsys-sysv* ) machine=is386 opsys=usg5-2-2 ;; - ## Prime EXL + dnl Prime EXL i[[3-9]]86-prime-sysv* ) machine=i386 opsys=usg5-3 ;; - ## Sequent Symmetry running Dynix + dnl Sequent Symmetry running Dynix i[[3-9]]86-sequent-bsd* ) machine=symmetry opsys=bsd4-3 ;; - ## Sequent Symmetry running DYNIX/ptx - ## Use the old cpp rather than the newer ANSI one. - i[[3-9]]86-sequent-ptx* ) - machine=sequent-ptx opsys=ptx - NON_GNU_CPP="/lib/cpp" - ;; - - ## Unspecified sysv on an ncr machine defaults to svr4.2. - ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.) + dnl Sequent Symmetry running DYNIX/ptx + i[[3-9]]86-sequent-ptx* ) machine=sequent-ptx opsys=ptx NON_GNU_CPP="/lib/cpp" ;; + + dnl Unspecified sysv on an ncr machine defaults to svr4.2. + dnl (Plain usg5-4 does not turn on POSIX signals, which we need.) i[[3-9]]86-ncr-sysv* ) machine=ncr386 opsys=usg5-4-2 ;; - ## Intel Paragon OSF/1 + dnl Intel Paragon OSF/1 i860-intel-osf1* ) machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp ;; - ## Intel 860 - i860-*-sysv4* ) - machine=i860 opsys=usg5-4 - NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc. - NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion. - ;; - - ## Masscomp machines + dnl Intel 860 + i860-*-sysv4* ) machine=i860 opsys=usg5-4 NON_GNU_CC="/bin/cc" NON_GNU_CPP="/usr/ccs/lib/cpp" ;; + + dnl Masscomp machines m68*-masscomp-rtu* ) machine=masscomp opsys=rtu ;; - ## Megatest machines + dnl Megatest machines m68*-megatest-bsd* ) machine=mega68 opsys=bsd4-2 ;; - ## Workstations sold by MIPS - ## This is not necessarily all workstations using the MIPS processor - - ## Irises are produced by SGI, and DECstations by DEC. - - ## etc/MACHINES lists mips.h and mips4.h as possible machine files, - ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance - ## it gives for choosing between the alternatives seems to be "Use - ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with - ## the BSD world." I'll assume that these are instructions for - ## handling two odd situations, and that every other situation - ## should use mips.h and usg5-2-2, they being listed first. - mips-mips-usg* ) - machine=mips4 - ## Fall through to the general code at the bottom to decide on the OS. - ;; + dnl Workstations sold by MIPS + dnl This is not necessarily all workstations using the MIPS processor - + dnl Irises are produced by SGI, and DECstations by DEC. + mips-mips-usg* ) machine=mips4 ;; mips-mips-riscos4 ) machine=mips4 NON_GNU_CC="cc -systype bsd43" NON_GNU_CPP="cc -systype bsd43 -E" - case "${canonical}" in + case "$canonical" in mips-mips-riscos4* ) opsys=bsd4-3 ;; mips-mips-riscos5* ) opsys=riscos5 ;; esac @@ -1222,105 +1333,92 @@ mips-mips-bsd* ) machine=mips opsys=bsd4-3 ;; mips-mips-* ) machine=mips opsys=usg5-2-2 ;; - ## NeXT + dnl NeXT m68*-next-* | m68k-*-nextstep* ) machine=m68k opsys=nextstep ;; - ## The complete machine from National Semiconductor + dnl The complete machine from National Semiconductor ns32k-ns-genix* ) machine=ns32000 opsys=usg5-2 ;; - ## NCR machines + dnl NCR machines m68*-ncr-sysv2* | m68*-ncr-sysvr2* ) machine=tower32 opsys=usg5-2-2 ;; m68*-ncr-sysv3* | m68*-ncr-sysvr3* ) machine=tower32v3 opsys=usg5-3 ;; - ## Nixdorf Targon 31 + dnl Nixdorf Targon 31 m68*-nixdorf-sysv* ) machine=targon31 opsys=usg5-2-2 ;; - ## Nu (TI or LMI) + dnl Nu (TI or LMI) m68*-nu-sysv* ) machine=nu opsys=usg5-2 ;; - ## Plexus + dnl Plexus m68*-plexus-sysv* ) machine=plexus opsys=usg5-2 ;; - ## Pyramid machines - ## I don't really have any idea what sort of processor the Pyramid has, - ## so I'm assuming it is its own architecture. + dnl Pyramid machines pyramid-pyramid-bsd* ) machine=pyramid opsys=bsd4-2 ;; - ## Sequent Balance + dnl Sequent Balance ns32k-sequent-bsd4.2* ) machine=sequent opsys=bsd4-2 ;; ns32k-sequent-bsd4.3* ) machine=sequent opsys=bsd4-3 ;; - ## Siemens Nixdorf + dnl Siemens Nixdorf mips-siemens-sysv* | mips-sni-sysv*) machine=mips-siemens opsys=usg5-4 NON_GNU_CC=/usr/ccs/bin/cc NON_GNU_CPP=/usr/ccs/lib/cpp ;; - ## Silicon Graphics machines - ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030) + dnl Silicon Graphics machines + dnl Iris 2500 and Iris 2500 Turbo (aka the Iris 3030) m68*-sgi-iris3.5* ) machine=irist opsys=iris3-5 ;; m68*-sgi-iris3.6* | m68*-sgi-iris*) machine=irist opsys=iris3-6 ;; - ## Iris 4D - mips-sgi-irix3.* ) machine=iris4d opsys=irix3-3 ;; - mips-sgi-irix4.* ) machine=iris4d opsys=irix4-0 ;; - mips-sgi-irix6* ) machine=iris4d opsys=irix6-0 NON_GNU_CC="cc -Olimit 2000" ;; - mips-sgi-irix5.[[3-9]]* ) machine=iris4d opsys=irix5-3 ;; - mips-sgi-irix5.2* ) machine=iris4d opsys=irix5-2 ;; - mips-sgi-irix5.1* ) machine=iris4d opsys=irix5-1 ;; - mips-sgi-irix* ) machine=iris4d opsys=irix5-0 ;; - - ## SONY machines - m68*-sony-bsd4.2* ) machine=news opsys=bsd4-2 ;; - m68*-sony-bsd4.3* ) machine=news opsys=bsd4-3 ;; - m68*-sony-newsos3* | m68*-sony-news3*) machine=news opsys=bsd4-3 ;; - mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*) machine=news-risc opsys=bsd4-3 ;; - mips-sony-news* ) machine=news-risc opsys=newsos5 ;; - - ## Stride + dnl Iris 4D + mips-sgi-irix3.* ) opsys=irix3-3 ;; + mips-sgi-irix4.* ) opsys=irix4-0 ;; + mips-sgi-irix6* ) opsys=irix6-0 NON_GNU_CC="cc -Olimit 2000" ;; + mips-sgi-irix5.1* ) opsys=irix5-1 ;; + mips-sgi-irix5.2* ) opsys=irix5-2 ;; + mips-sgi-irix5.* ) opsys=irix5-3 ;; + mips-sgi-irix* ) opsys=irix5-0 ;; + + dnl SONY machines + *-sony-newsos[[34]]* | *-sony-news[[34]]* ) opsys=bsd4-3 ;; + *-sony-news* ) opsys=newsos5 ;; + + dnl Stride m68*-stride-sysv* ) machine=stride opsys=usg5-2 ;; - ## Suns - sparc-*-linux* ) machine=sparc opsys=linux ;; - + dnl Suns *-*-solaris* | *-*-sunos* | *-sun-mach* | *-sun-bsd* ) - # Hardware type - case "${canonical}" in + dnl Hardware type + case "$canonical" in m68*-sunos1* ) machine=sun1 ;; m68*-sunos2* ) machine=sun2 ;; m68* ) machine=sun3 ;; i[[3-9]]86*-sun-sunos[[34]]* ) machine=sun386 ;; i[[3-9]]86-*-* ) machine=intel386 ;; rs6000* ) machine=rs6000 ;; - sparc* ) machine=sparc ;; - powerpc* ) machine=powerpc ;; - * ) unported=yes ;; + esac + + dnl Make $canonical even more so. + case "$canonical" in *-sunos5*) + canonical="`echo \"$canonical\" | sed -e s/sunos5/solaris2/`";; esac - - # Make `canonical' even more so. - case "${canonical}" in *-sunos5*) - canonical="`echo \"${canonical}\" | sed -e s/sunos5/solaris2/`";; - esac - - # On SunOS 4, use /usr/lib/cpp, sans dynodump, /bin/ranlib - # On SunOS 5, use /usr/ccs/lib/cpp, need dynodump, RANLIB not needed - # But, SunOS 5.6 no longer needs dynodump because it has a similar - # function integrated. - case "${canonical}" in + + dnl On SunOS 4, use /usr/lib/cpp, sans dynodump, /bin/ranlib + dnl On SunOS 5, use /usr/ccs/lib/cpp, need dynodump, RANLIB not needed + dnl But, SunOS 5.6 no longer needs dynodump because it has a similar + dnl function integrated. + case "$canonical" in *-sunos4* ) test -f /usr/lib/cpp && NON_GNU_CPP=/usr/lib/cpp ;; *-solaris2* ) test -f /usr/ccs/lib/cpp && NON_GNU_CPP=/usr/ccs/lib/cpp RANLIB=':' - case "${canonical}" in - *-solaris2.[[6-9]]* ) need_dynodump=no ;; - *-solaris2* ) need_dynodump=yes ;; + case "$canonical" in *-solaris2.[[0-5]]* ) need_dynodump=yes ;; esac esac - esac - - case "${canonical}" in - ## The Sun386 didn't get past 4.0. - i[[3-9]]86-*-sunos4* ) opsys=sunos4-0 ;; + + case "$canonical" in + dnl The last Sun386 ran 4.0. + i[[3-9]]86-*-sunos4*) opsys=sunos4-0 ;; *-sunos4.0* ) opsys=sunos4-0 ;; *-sunos4.1.2* ) opsys=sunos4-1-2 ;; *-sunos4.1.3* ) opsys=sunos4-1-3 ;; @@ -1337,69 +1435,58 @@ * ) opsys=bsd4-2 ;; esac - case "${canonical}" in *-sunos4*shr* ) opsys="${opsys}-shr" ;; esac - - ## Watch out for a compiler that is guaranteed not to work. - case "${canonical}" in - *-solaris* ) test "$CC" = "/usr/ucb/cc" && unset CC ;; + case "$canonical" in *-sunos4*shr* ) opsys="${opsys}-shr" ;; esac + + dnl Watch out for a compiler guaranteed not to work. + case "$canonical" in + *-solaris* ) case "$CC" in /usr/ucb/cc* ) CC="" ;; esac ;; esac ;; - sparc-*-nextstep* ) machine=sparc opsys=nextstep ;; - - ## Tadpole 68k + dnl Tadpole 68k m68*-tadpole-sysv* ) machine=tad68k opsys=usg5-3 ;; - ## Tahoe machines + dnl Tahoe machines tahoe-tahoe-bsd4.2* ) machine=tahoe opsys=bsd4-2 ;; tahoe-tahoe-bsd4.3* ) machine=tahoe opsys=bsd4-3 ;; - ## Tandem Integrity S2 + dnl Tandem Integrity S2 mips-tandem-sysv* ) machine=tandem-s2 opsys=usg5-3 ;; - ## Tektronix XD88 + dnl Tektronix XD88 m88k-tektronix-sysv3* ) machine=tekxd88 opsys=usg5-3 ;; - ## Tektronix 16000 box (6130?) + dnl Tektronix 16000 box (6130?) ns16k-tektronix-bsd* ) machine=ns16000 opsys=bsd4-2 ;; - ## Tektronix 4300 - ## src/m/tek4300.h hints that this is a m68k machine. + dnl Tektronix 4300 + dnl src/m/tek4300.h hints that this is a m68k machine. m68*-tektronix-bsd* ) machine=tek4300 opsys=bsd4-3 ;; - ## Titan P2 or P3 - ## We seem to have lost the machine-description file titan.h! + dnl Titan P2 or P3 titan-titan-sysv* ) machine=titan opsys=usg5-3 ;; - ## Ustation E30 (SS5E) + dnl Ustation E30 (SS5E) m68*-unisys-uniplus* ) machine=ustation opsystem=unipl5-2 ;; - ## Vaxen. + dnl Vaxen. vax-dec-* ) - machine=vax - case "${canonical}" in - *-bsd4.1* ) opsys=bsd4-1 ;; - *-bsd4.2* | *-ultrix[[0-3]].* | *-ultrix4.0* ) opsys=bsd4-2 ;; - *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;; - *-sysv[[01]]* | *-sysvr[[01]]* ) opsys=usg5-0 ;; - *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;; - *-vms* ) opsys=vms ;; - *-mach* ) opsys=mach-bsd4-3 ;; - * ) unported=yes + case "$canonical" in + *-sysv[[01]]* | *-sysvr[[01]]* ) opsys=usg5-0 ;; + *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;; + *-mach* ) opsys=mach-bsd4-3 ;; esac ;; - ## Whitechapel MG1 - ## We don't know what sort of OS runs on these; we'll let the - ## operating system guessing code below try. + dnl Whitechapel MG1 ns16k-whitechapel-* ) machine=mg1 ;; - ## Wicat + dnl Wicat m68*-wicat-sysv* ) machine=wicat opsys=usg5-2 ;; - ## Intel 386 machines where we don't care about the manufacturer + dnl Intel 386 machines where we do not care about the manufacturer i[[3-9]]86-*-* ) machine=intel386 - case "${canonical}" in + case "$canonical" in *-isc1.* | *-isc2.[[01]]* ) opsys=386-ix ;; *-isc2.2* ) opsys=isc2-2 ;; *-isc4.0* ) opsys=isc4-0 ;; @@ -1408,24 +1495,23 @@ NON_GCC_TEST_OPTIONS=-Xp ;; *-isc* ) opsys=isc3-0 ;; - *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;; + *-esix5* ) opsys=esix5r4 NON_GNU_CPP=/usr/lib/cpp ;; *-esix* ) opsys=esix ;; *-mach* ) opsys=mach-bsd4-3 ;; *-xenix* ) opsys=xenix ;; - *-linux* ) opsys=linux ;; - *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;; + *-sco3.2v4* ) opsys=sco4 NON_GNU_CPP=/lib/cpp ;; *-bsd386* | *-bsdi1* ) opsys=bsd386 ;; *-bsdi3* ) opsys=bsdos3 ;; *-bsdi2.1* ) opsys=bsdos2-1 ;; *-bsdi2* ) opsys=bsdos2 ;; - *-sco3.2v5* ) opsys=sco5 ; - ## This is a pain. Like the current USL cc, SCO's cc -E - ## tokenizes as it preprocesses, making configure very - ## unhappy. Unfortunately, /lib/cpp doesn't understand - ## flags like "-b elf", so we have to cheat in order to - ## pick up the right defines for UNEXEC from the s-file. - ## 01/05/95 robertl@dgii.com - if test "${dynamic}" = "yes" ; then + *-sco3.2v5* ) opsys=sco5 ; + dnl This is a pain. Like the current USL cc, SCO cc -E + dnl tokenizes as it preprocesses, making configure very + dnl unhappy. Unfortunately, /lib/cpp does not understand + dnl flags like "-b elf", so we have to cheat in order to + dnl pick up the right defines for UNEXEC from the s-file. + dnl 01/05/95 robertl@dgii.com + if test "$dynamic" = "yes" ; then NON_GNU_CPP="/lib/cpp -D_XOPEN_SOURCE -D_SCO_ELF" ; else NON_GNU_CPP="/lib/cpp -D_XOPEN_SOURCE" ; @@ -1433,254 +1519,199 @@ *-386bsd* ) opsys=386bsd ;; *-freebsd* ) opsys=freebsd ;; *-nextstep* ) opsys=nextstep ;; - ## Otherwise, we'll fall through to the generic opsys code at the bottom. + dnl Otherwise, we fall through to the generic opsys code at the bottom. esac ;; - ## Linux/68k + dnl Linux/68k m68k-*-linux* ) machine=m68k opsys=linux ;; - * ) unported=yes ;; esac -### If the code above didn't choose an operating system, just choose -### an operating system based on the configuration name. You really -### only want to use this when you have no idea what the right -### operating system is; if you know what operating systems a machine -### runs, it's cleaner to make it explicit in the case statement -### above. -if test -z "${opsys}" ; then - case "${canonical}" in - *-gnu* ) opsys=gnu ;; - *-bsd4.[[01]] ) opsys=bsd4-1 ;; - *-bsd4.2 ) opsys=bsd4-2 ;; - *-bsd4.3 ) opsys=bsd4-3 ;; - *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;; - *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;; - *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;; - *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;; - *-sysv4.1* | *-sysvr4.1* ) opsys=usg5-4 NON_GNU_CPP=/usr/lib/cpp ;; - *-sysv4.[[2-9]]* | *-sysvr4.[[2-9]]* ) - if test -z "$NON_GNU_CPP" ; then - if test -f /usr/ccs/lib/cpp - then NON_GNU_CPP=/usr/ccs/lib/cpp - else NON_GNU_CPP=/lib/cpp - fi - fi - opsys=usg5-4-2 ;; - *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;; - * ) unported=yes ;; - esac -fi - -test -z "$RANLIB" && RANLIB=ranlib - -if test ${unported} = yes; then - (echo "${progname}: XEmacs hasn't been ported to \`${canonical}' systems." - echo "${progname}: Check \`etc/MACHINES' for recognized configuration names." +if test -z "$machine" -o -z "$opsys"; then + (echo "$progname: XEmacs hasn't been ported to \`$canonical' systems." + echo "$progname: Check \`etc/MACHINES' for recognized configuration names." ) >&2 exit 1 fi -if test "${dynamic}" = "yes" ; then - case "${opsys}" in +if test "$dynamic" = "yes" ; then + case "$opsys" in hpux* | sunos4* | sco5 ) opsys="${opsys}-shr" ;; esac -elif test "${dynamic}" = "no" ; then - case "${opsys}" in +elif test "$dynamic" = "no" ; then + case "$opsys" in sol2* | decosf1-3 | decosf3-* | decosf4-* | linux ) opsys="${opsys}-static" ;; esac fi -dynodump_arch='' -if test "${need_dynodump}" = "yes" ; then - case "${canonical}" in - sparc* ) dynodump_arch=sparc ;; - powerpc* ) dynodump_arch=ppc ;; - i[[3-9]]86* ) dynodump_arch=i386 ;; - esac -fi - machfile="m/${machine}.h" opsysfile="s/${opsys}.h" - -############################################################################ -# # -# Determine the compiler, set up for feature testing # -# # -############################################################################ - -dnl ----------------------------------------------------------------------- -dnl Let's do a couple of macro (re)definitions. -dnl -dnl First we redefine AC_TEST_CPP so that we can see the error output -dnl from preprocessor runs. This definition is identical to the standard -dnl one supplied by Autoconf 1.11 extra for the extra_verbose check. -dnl -dnl Note that we *must* include the brackets around the macro definition -dnl name here. Autoconf has redefined the quoting characters to be brackets, -dnl and if we don't supply them, the original definition will get -dnl substituted in place of the macro name! -dnl - -dnl Following macro is useful shorthand -define([IF_YES_AC_DEFINE],test "${$1}" = yes && [AC_DEFINE]($2)) - -define([AC_TEST_CPP], -[AC_REQUIRE_CPP()dnl -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" -[$1] -EOF -dnl # Some shells (Coherent) do redirections in the wrong order, so need -dnl # the parens. -dnl # The exec was added by Mly to make this work under BSDI -ac_err=`eval "(exec $ac_cpp conftest.${ac_ext} >/dev/null) 2>&1"` -dnl # Use test here, not brackets, to avoid strange autoconf-quoting lossage. -if test "${extra_verbose}" = "yes" && test -n "$ac_err"; then - echo "$ac_err" -fi -if test -z "$ac_err"; then - ifelse([$2], , :, [rm -rf conftest* - $2 -]) -ifelse([$3], , , [else - rm -rf conftest* - $3 -])dnl -fi -rm -f conftest*])dnl -dnl -dnl Second, a macro of our own: -dnl Subroutine to find version of X being used -dnl It can't use xmkmf because the first version in the user's path -dnl may not belong to the version of X that is being built with -define(AC_FIND_X_VERSION, -[AC_CHECKING(the version of X11 being used) -cat > conftest.${ac_ext} <<EOF -#include <X11/Intrinsic.h> -int main() { -#if (XlibSpecificationRelease == 4) - printf ("X11R4\n"); -#elif (XlibSpecificationRelease == 5) - printf ("X11R5\n"); -#elif (XlibSpecificationRelease == 6) - printf ("X11R6\n"); -#elif (XtSpecificationRelease == 4) - printf ("X11R4\n"); -#endif - return 0; -} -EOF -dnl We need to run this which will prevent cross-configuring. But since -dnl we can't do that anyhow, oh darn. -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} ${DEFS}" -if eval $ac_compile; then - case "`./conftest`" in - X11R4 ) AC_DEFINE(THIS_IS_X11R4) ;; - X11R5 ) AC_DEFINE(THIS_IS_X11R5) ;; - X11R6 ) AC_DEFINE(THIS_IS_X11R6) ;; - esac +dnl -------------------------------------------------- +dnl Determine the compiler, set up for feature testing +dnl -------------------------------------------------- + +dnl Choose a compiler. +test -n "$CC" && cc_specified=yes + +dnl Save the value of CFLAGS that the user specified. +SPECIFIED_CFLAGS="$CFLAGS" + +if test -n "$compiler"; then CC="$compiler"; fi + +dnl Some systems specify a CPP or CC to use unless we are using GCC. +test -n "$NON_GNU_CC" -a "$with_gcc" = "no" -a -z "$CC" && CC="$NON_GNU_CC" +AC_PROG_CC + +if test "$with_gcc" = "no" -a "$ac_cv_prog_gcc" = "yes"; then + CC=${NON_GNU_CC-cc} + AC_PROG_CC +elif test "$with_gcc" = "yes" -a "$ac_cv_prog_gcc" = "no" ; then + CC=gcc + AC_PROG_CC fi -LIBS=$ac_save_LIBS -rm -f conftest*] -)dnl -dnl ----------------------------------------------------------------------- -AC_LANG_C -AC_PREPARE(lisp) -AC_CONFIG_HEADER(src/config.h) - -if test "${extra_verbose}" = "yes" ; then -# This is identical to the version that A\C_LANG_C generates except that -# it omits the redirection of all output to /dev/null. - ac_compile='${CC-cc} $CFLAGS $LDFLAGS conftest.${ac_ext} -o conftest $LIBS' -fi - -#### Choose a compiler. -if test "x$CC" = x ; then - cc_specified=1 -fi - -# Save the value of CFLAGS that the user specified. -SPECIFIED_CFLAGS="$CFLAGS" - -if test "${with_gcc}" = "yes" ; then - CC="${compiler-gcc}" - GCC=1 -elif test "${with_lcc}" = "yes" ; then - CC="${compiler-lcc}" - dash_r_space=' ' # this bullshit is here because lcc for solaris - # will not accept -Rargument. - # It needs -R argument instead. Yuck yuck yuck. - test -z "$NON_GNU_CPP" && NON_GNU_CPP="yes" # this is handled specially below... -elif test "${compiler}" != "" ; then CC="${compiler}" -elif test "${with_gcc}" = "no" ; then CC="cc" -elif test "${with_lcc}" = "no" ; then - test -z "$CC" && CC=cc + +if test "$GCC" = "yes"; then with_gcc=yes; else with_gcc=no; fi +test -n "$NON_GNU_CPP" -a "$with_gcc" = "no" -a -z "$CPP" && CPP="$NON_GNU_CPP" + +AC_PROG_CPP + +case "$canonical" in + *-sun-sunos* ) test "$CPP" = "acc -E" && CPP="acc -E -Xs" ;; +esac + +dnl -------------------------------------------------------------------- +dnl Extract some information from the operating system and machine files +dnl -------------------------------------------------------------------- + +echo "Extracting information from the machine- and system-dependent headers..." + +dnl First figure out CFLAGS (which we use for running the compiler here) +dnl and REAL_CFLAGS (which we use for real compilation). +dnl The two are the same except on a few systems, where they are made +dnl different to work around various lossages. For example, +dnl GCC 2.5 on Linux needs them to be different because it treats -g +dnl as implying static linking. + +dnl If the CFLAGS env var is specified, we use that value +dnl instead of the default. + +dnl It is not important that this name contain the PID; you cannot run +dnl two configures in the same directory and have anything work +dnl anyway. +tempcname="conftest.c" + +dnl CPP_to_sh(CPP_SYMBOL, SH_VAR, DEFAULT_VALUE) +define([CPP_to_sh], +[[#]ifndef [$1] +[#]define [$1] [$3] +[#]endif +configure___ [$2]=[$1] +]) + +dnl CPP_boolean_to_sh(CPP_SYMBOL, SH_VAR) +define([CPP_boolean_to_sh], +[[#]ifdef [$1] +configure___ [$2]=yes +[#]else +configure___ [$2]=no +[#]endif +]) + + +echo ' +#define NOT_C_CODE +#define C_SWITCH_SITE +#define C_SWITCH_X_SITE +#define LD_SWITCH_SITE +#define LD_SWITCH_X_SITE +#define LD_SWITCH_X_SITE_AUX +#include "'$srcdir'/src/'$opsysfile'" +#include "'$srcdir'/src/'$machfile'" + +CPP_to_sh(LIBS_MACHINE, libs_machine) +CPP_to_sh(LIBS_SYSTEM, libs_system) +CPP_to_sh(LIBS_TERMCAP, libs_termcap) +CPP_to_sh(LIB_STANDARD, libs_standard) +CPP_to_sh(C_SWITCH_SYSTEM, c_switch_system) +CPP_to_sh(C_SWITCH_MACHINE, c_switch_machine) +CPP_to_sh(C_SWITCH_X_SYSTEM, c_switch_x_system) +CPP_to_sh(LD_SWITCH_X_SYSTEM, ld_switch_x_system) +CPP_to_sh(LD_SWITCH_SYSTEM, ld_switch_system) +CPP_to_sh(UNEXEC, unexec, unexec.o) +CPP_to_sh(C_DEBUG_SWITCH, c_debug_switch, -g) +CPP_to_sh(C_OPTIMIZE_SWITCH, c_optimize_switch, -O) + +CPP_boolean_to_sh(SYSTEM_MALLOC, system_malloc) +CPP_boolean_to_sh(TERMINFO, have_terminfo) +CPP_boolean_to_sh(MAIL_USE_FLOCK, mail_use_flock) +CPP_boolean_to_sh(MAIL_USE_LOCKF, mail_use_lockf) +CPP_boolean_to_sh(__SUNPRO_C, sunpro_c) + +#ifdef THIS_IS_CONFIGURE + +/* Get the CFLAGS for tests in configure. */ +#ifdef __GNUC__ +configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '$SPECIFIED_CFLAGS' +#else +configure___ CFLAGS=C_DEBUG_SWITCH '$SPECIFIED_CFLAGS' +#endif + +#else /* not THIS_IS_CONFIGURE */ + +/* Get the CFLAGS for real compilation. */ +#ifdef __GNUC__ +configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '$SPECIFIED_CFLAGS' +#else +configure___ REAL_CFLAGS=C_DEBUG_SWITCH '$SPECIFIED_CFLAGS' +#endif + +#endif /* not THIS_IS_CONFIGURE */ +' > $tempcname +dnl The value of CPP is a quoted variable reference, so we need to do this +dnl to get its actual value... +CPP=`eval "echo $CPP"` +eval `$CPP -Isrc $tempcname \ + | grep 'configure___' \ + | sed -n -e 's/^configure___ \([[^=]]*=\)\(.*\)$/\1"\2"/p'` +if test -z "$SPECIFIED_CFLAGS"; then + eval `$CPP -Isrc -DTHIS_IS_CONFIGURE $tempcname \ + | grep 'configure___' \ + | sed -n -e 's/^configure___ \([[^=]]*=\)\(.*\)$/\1"\2"/p'` else - case "${canonical}" in - * ) - AC_PROG_CC - if test "${CC}" = "gcc" ; then - with_gcc="yes" - GCC=1 - fi - ;; - esac + REAL_CFLAGS="$CFLAGS" fi - -#### Some systems specify a CPP to use unless we are using GCC. -#### Now that we know whether we are using GCC, we can decide whether -#### to use that one. -if test "x$NON_GNU_CPP" = x -o x$GCC = x1 -then true -else - if test "x$CPP" = x ; then - if test "${with_lcc}" = "yes" -a "${NON_GNU_CPP}" = "yes"; then - CPP='gcc -E -traditional' # cross fingers and hope it's there.... - else - CPP="$NON_GNU_CPP" - fi - fi -fi - -#### Some systems specify a CC to use unless we are using GCC. -#### Now that we know whether we are using GCC, we can decide whether -#### to use that one. -if test "x$NON_GNU_CC" = x -o x$GCC = x1 -o x$cc_specified = x1 -then true -else - CC="$NON_GNU_CC" +rm $tempcname + +dnl override CFLAGS if user wishes +if test "$cflags" != "NO_CFLAGS_DEFINED" ; then + REAL_CFLAGS=$cflags fi -## Huh? I commented out the following because it always enabled -## the "test" options, whatever the hell those are supposed to be -## for, and the result is that SunOS builds were always static. - -# test x$GCC = x1 -a "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS" -# test x$GCC = x -a "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS" - -############################################################################ -# # -# Do some misc autoconf-special tests # -# # -############################################################################ - -#### Some other nice autoconf tests. If you add a test here which -#### should make an entry in src/config.h, don't forget to add an -#### #undef clause to src/config.h.in for autoconf to modify. -dnl checks for programs -AC_PROG_CPP - -case "${canonical}" in - *-sun-sunos* ) - if test "${CPP}" = "acc -E" ; then - CPP="acc -E -Xs" - fi - ;; -esac +dnl Compute the unexec source name from the object name. +UNEXEC_SRC="`echo $unexec | sed 's/\.o/.c/'`" + +dnl Do the opsystem or machine files prohibit the use of the GNU malloc? +dnl Assume not, until told otherwise. +GNU_MALLOC=yes +if test "$system_malloc" = "yes" ; then + GNU_MALLOC=no + GNU_MALLOC_reason=" + (The GNU allocators don't work with this system configuration.)" +elif test "$use_system_malloc" = "yes" ; then + GNU_MALLOC=no + GNU_MALLOC_reason=" + (User chose not to use GNU allocators.)" +fi + +dnl ----------------------------------- +dnl Do some misc autoconf-special tests +dnl ----------------------------------- + +dnl Some other nice autoconf tests. If you add a test here which +dnl should make an entry in src/config.h, do not forget to add an +dnl #undef clause to src/config.h.in for autoconf to modify. AC_PROG_RANLIB AC_PROG_INSTALL @@ -1690,16 +1721,16 @@ AC_AIX dnl checks for header files -AC_HAVE_HEADERS(mach/mach.h sys/stropts.h sys/timeb.h sys/time.h unistd.h) -AC_HAVE_HEADERS(utime.h sys/wait.h libintl.h locale.h libgen.h) -AC_HAVE_HEADERS(linux/version.h kstat.h sys/pstat.h inttypes.h) -AC_STDC_HEADERS -AC_TIME_WITH_SYS_TIME -AC_SYS_SIGLIST_DECLARED - -dnl Some systems have utime.h but don't declare the struct anyplace. -AC_COMPILE_CHECK(struct utimbuf, -[#ifdef TIME_WITH_SYS_TIME +AC_CHECK_HEADERS(mach/mach.h sys/stropts.h sys/timeb.h sys/time.h unistd.h) +AC_CHECK_HEADERS(utime.h sys/wait.h libintl.h locale.h libgen.h) +AC_CHECK_HEADERS(linux/version.h kstat.h sys/pstat.h inttypes.h) +AC_HEADER_STDC +AC_HEADER_TIME +AC_DECL_SYS_SIGLIST + +dnl Some systems have utime.h but do not declare the struct anyplace. +AC_MSG_CHECKING(for struct utimbuf) +AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME #include <sys/time.h> #include <time.h> #else @@ -1712,13 +1743,15 @@ #ifdef HAVE_UTIME_H #include <utime.h> #endif], [static struct utimbuf x; x.actime = x.modtime;], - AC_DEFINE(HAVE_STRUCT_UTIMBUF)) + [AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_STRUCT_UTIMBUF)], + AC_MSG_RESULT(no)) dnl checks for typedefs -AC_RETSIGTYPE - -AC_COMPILE_CHECK(struct timeval, -[#ifdef TIME_WITH_SYS_TIME +AC_TYPE_SIGNAL + +AC_MSG_CHECKING(for struct timeval) +AC_TRY_COMPILE([#ifdef TIME_WITH_SYS_TIME #include <sys/time.h> #include <time.h> #else @@ -1727,119 +1760,238 @@ #else #include <time.h> #endif -#endif], [static struct timeval x; x.tv_sec = x.tv_usec;], [ +#endif], [static struct timeval x; x.tv_sec = x.tv_usec;], + [AC_MSG_RESULT(yes) HAVE_TIMEVAL=yes AC_DEFINE(HAVE_TIMEVAL)], - [HAVE_TIMEVAL=no]) + [AC_MSG_RESULT(no) + HAVE_TIMEVAL=no]) dnl checks for structure members AC_STRUCT_TM -AC_TIMEZONE +AC_STRUCT_TIMEZONE dnl checks for compiler characteristics -AC_CONST +AC_C_CONST dnl check for Make feature -AC_SET_MAKE +AC_PROG_MAKE_SET dnl check byte order -AC_WORDS_BIGENDIAN +AC_C_BIGENDIAN dnl check for long file names -AC_LONG_FILE_NAMES - -echo "checking for -xildoff compiler flag" -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 - : - else - AC_VERBOSE(defining NEED_XILDOFF) - need_xildoff=yes - fi -fi +AC_SYS_LONG_FILE_NAMES dnl other checks for UNIX variants -# What the hell was this doing here?????? -### echo > confdefs.h # this gets nuked above... - -############################################################################ -# # -# Choose a window system # -# # -############################################################################ - -#### Choose a window system. -echo "checking for specified window system" - -window_system='' -case "${with_x11}" in - yes ) window_system=${window_system}x11 ;; - no ) window_system=${window_system}none ;; + +dnl -lm might be required for some X libraries to link with later +AC_CHECK_LIB(m, sqrt) + +dnl Determine type of mail locking from configure args and s&m headers +AC_CHECKING(type of mail spool file locking) +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 AC_DEFINE(REAL_MAIL_USE_LOCKF) +elif test "$mail_locking" = "flock"; then AC_DEFINE(REAL_MAIL_USE_FLOCK) +fi + +dnl Dynodump +if test "$need_dynodump" = "yes" ; then + AC_DEFINE(DYNODUMP) + MAKE_SUBDIR="$MAKE_SUBDIR dynodump" + case "$canonical" in + sparc* ) dynodump_arch=sparc ;; + powerpc* ) dynodump_arch=ppc ;; + i*86* ) dynodump_arch=i386 ;; + esac + dnl Dynodump requires the system linker + test "$GCC" = "yes" && ld_switch_site="-fno-gnu-linker $ld_switch_site" +fi + +dnl Extra library directories - please add to list +for dir in "/usr/ccs/lib"; do + test -d "$dir" && ld_switch_site="$ld_switch_site -L${dir}" +done + +dnl ---------------------- +dnl Choose a window system +dnl ---------------------- + +AC_CHECKING("for specified window system") + +dnl $OPENWINHOME implies --x-includes and --x-libraries +dnl Not (yet) handled by autoconf2 +if test "$x_includes $x_libraries" = "NONE NONE"; then + if test -n "$OPENWINHOME" \ + -a "$OPENWINHOME" != "/usr/openwin" \ + -a -d "$OPENWINHOME"; then + test -d "$OPENWINHOME/lib" && x_libraries="$OPENWINHOME/lib" + test -d "$OPENWINHOME/include" && x_includes="$OPENWINHOME/include" + test -d "$OPENWINHOME/share/include" && x_includes="$OPENWINHOME/share/include" + fi +fi + +dnl --x-includes or --x-libraries implies --with-x11. +test "$x_includes $x_libraries" != "NONE NONE" && \ + window_system=x11 with_x11=yes + +if test "$with_x11" != "no"; then + AC_PATH_XTRA # Autoconf claims to find X library and include dirs for us. + if test "$no_x" = "yes" + then with_x11=no window_system=none HAVE_X_WINDOWS=no + else with_x11=yes window_system=x11 HAVE_X_WINDOWS=yes + fi +fi + +case "$with_x11" in + yes ) window_system=x11 HAVE_X_WINDOWS=yes ;; + no ) window_system=none HAVE_X_WINDOWS=no ;; esac -case "${window_system}" in - "none" | "x11" ) ;; - "" ) - # --x-includes or --x-libraries implies --with-x11. - if test -n "${x_includes}" -o -n "${x_libraries}"; then - window_system=x11 - else - echo " No window system specified. Looking for X11." - # If the user didn't specify a window system and we found X11, use it. - if test -r /usr/lib/libX11.a \ - -o -d /usr/include/X11 \ - -o -d /usr/X386/include \ - -o -d /usr/X11R6/include \ - -o -d ${x_includes}/X11 ; then - window_system=x11 +if test "$with_x11" = "yes"; then + AC_DEFINE(HAVE_X_WINDOWS) + MAKE_SUBDIR="$MAKE_SUBDIR lwlib" + + dnl Try to find Motif/CDE/Tooltalk dirs + dnl These take precedence over other X libs/includes, so PRE-pend + for lib_dir in "/usr/dt/lib" "/usr/lib/Motif1.2" "/usr/lib/Motif1.1"; do + inc_dir="`echo $lib_dir | sed 's/lib/include/'`" + if test -d "$lib_dir" -a -d "$inc_dir"; then + case "$x_libraries" in *"$lib_dir"* ) : ;; *) + x_libraries="$lib_dir $x_libraries" X_LIBS="-L${lib_dir} $X_LIBS" + esac + case "$x_includes" in "$inc_dir"* ) : ;; *) + x_includes="$inc_dir $x_includes" X_CFLAGS="-I${inc_dir} $X_CFLAGS" + esac + break; dnl only need ONE Motif implementation! fi + done + + dnl Contrib X libs/includes do NOT take precedence, so AP-pend + for rel in "X11R6" "X11R5" "X11R4"; do + lib_dir="/usr/contrib/$rel/lib" inc_dir="/usr/contrib/$rel/include" + if test -d "$lib_dir" -a -d "$inc_dir"; then + case "$x_libraries" in *"$lib_dir"* ) : ;; *) + x_libraries="$x_libraries $lib_dir" X_LIBS="$X_LIBS -L${lib_dir}" + esac + case "$x_includes" in "$inc_dir"* ) : ;; *) + x_includes="$x_includes $inc_dir" X_CFLAGS="$X_CFLAGS -I${inc_dir}" + esac + break; dnl Only need ONE X11 implementation ! fi - ;; - * ) - echo "Don't specify a window system more than once." >&2 - exit 1 - ;; -esac - -case "${window_system}" in "" | "x11" ) - ### If the user hasn't specified where we should find X, try - ### letting autoconf figure that out. - if test -z "${x_includes}${x_libraries}" ; then - AC_FIND_X + done + + ld_switch_x_site="$X_LIBS" + + if test "$extra_verbose" = "yes"; then + echo; echo "X11 compilation variables:" + PRINT_VAR(x_libraries, x_includes, X_CFLAGS, X_LIBS, X_PRE_LIBS, X_EXTRA_LIBS) + echo + fi + + dnl make sure we can find Intrinsic.h + AC_CHECK_HEADER(X11/Intrinsic.h, , + [AC_MSG_ERROR("Unable to find X11 header files.")]) + + dnl -lXt -lX11 are required + dnl Some broken systems require the magic "-b i486-linuxaout" flag + AC_CHECK_LIB(X11, XOpenDisplay, have_lib_x11=yes) + if test "$have_lib_x11" != "yes"; then + AC_CHECK_LIB(X11, XGetFontProperty, + ld_switch_x_site="-b i486-linuxaout $ld_switch_x_site", + [AC_MSG_ERROR("Unable to find X11 libraries.")], + -b i486-linuxaout) + fi + libs_x="-lX11" + + case "$canonical" in *-sunos4.* ) # Bug workaround + ld_switch_x_site="$ld_switch_x_site -u _XtToolkitInitialize" ;; + esac + AC_CHECK_LIB(Xt, XtOpenDisplay, libs_x="-lXt $libs_x", + [AC_MSG_ERROR("Unable to find X11 libraries.")]) + + AC_MSG_CHECKING(the version of X11 being used) + AC_TRY_RUN([#include <X11/Intrinsic.h> + main(int c, char* v[]) { return c>1 ? XlibSpecificationRelease : 0; }], + [./conftest foobar; rc=$?],[rc=4],[rc=4]) + AC_MSG_RESULT(R${rc}) + AC_DEFINE_UNQUOTED(THIS_IS_X11R${rc}) + + AC_CHECK_HEADERS(X11/Xlocale.h) + + dnl remove this - we should avoid checking for specific OS + AC_MSG_CHECKING(for XFree86) + if test -d "/usr/X386/include" -o \ + -f "/etc/XF86Config" -o \ + -f "/etc/X11/XF86Config" -o \ + -f "/usr/X11R6/lib/X11/XF86Config"; then + AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_XFREE386) + else + AC_MSG_RESULT(no) + fi + + dnl Autodetect -lXext + AC_CHECK_LIB(Xext, XShapeSelectInput, libs_x="-lXext $libs_x") + + dnl autodetect -lXmu + case "$canonical" in *-sunos4.* ) # Bug workaround + ld_switch_x_site="$ld_switch_x_site -u _get_applicationShellWidgetClass" ;; + esac + if test -z "$with_xmu"; then + AC_CHECK_LIB(Xmu, XmuConvertStandardSelection, with_xmu=yes, with_xmu=no) + fi + if test "$with_xmu" = "no"; then + extra_objs="$extra_objs xmu.o" + else + libs_x="-lXmu $libs_x" + fi + + dnl Autodetect -lXbsd + dnl #### Someone, please add a better function than main + AC_CHECK_LIB(Xbsd, main, libs_x="-lXbsd $libs_x") + + 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)], + have_motif=no) + + dnl Autodetect -lXaw + AC_CHECK_LIB(Xaw, XawScrollbarSetThumb, have_xaw=yes, have_xaw=no) + +fi dnl $with_x11 = yes + +test -z "$window_system" && window_system="none" + +if test "$window_system" = "none" ; then + if test "$with_tty" = "no" ; then + AC_MSG_ERROR([No window system support and no TTY support - Unable to proceed.]) + fi + for feature in tooltalk cde offix \ + menubars scrollbars toolbars dialogs xim xmu \ + tiff png jpeg gif compface xpm + do + if eval "test -n \"\$with_${feature}\" -a \"\$with_${feature}\" != no" ; then + AC_MSG_WARN([--with-$feature ignored: Not valid without X support]) fi - if test -n "${x_includes}${x_libraries}" ; then window_system=x11 ; fi - ;; -esac - -test -z "${window_system}" && window_system="none" - -if test "${window_system}" = "none" ; then - if test "${with_tty}" != "yes" ; then - echo "No window system support, and no TTY support." >&2 - echo "Unable to proceed." >&2 - exit 1 - fi - for feature in cde offix menubars scrollbars toolbars dialogs xim tiff - do - if eval "test -n \"\$with_$feature\" -a \"\$with_$feature\" != no" ; then - AC_WARN(--with-$feature ignored: Not valid without X support) - fi - eval "with_$feature=no" + eval "with_${feature}=no" done -elif test -z "${with_toolbars}" ; then - with_toolbars='yes' +else + test -z "$with_toolbars" && with_toolbars=yes fi +if false; then # obsolete runtime_arg="-R${dash_r_space}" -case "${canonical}" in - *-sun-solaris* | *-sun-sunos5* ) +case "$canonical" in + *-sun-solaris* | *-sun-sunos5* ) add_runtime_flag=yes ;; *-sgi-irix5.* ) - # In the IRIX 5.3 ld, only the last -rpath arg has any effect. This is - # fundamentaly incompatible with having separate LD_SWITCH_X_SITE - # and LD_SWITCH_SITE variables. Fortunately, SGI fixed this by 6.2. - if test -n "${x_libraries}" || test -n "${site_runtime_libraries}" ; then + dnl In the IRIX 5.3 ld, only the last -rpath arg has any effect. This is + dnl fundamentaly incompatible with having separate LD_SWITCH_X_SITE + dnl and LD_SWITCH_SITE variables. Fortunately, SGI fixed this by 6.2. + if test -n "$x_libraries" || test -n "$site_runtime_libraries" ; then (echo "WARNING: The IRIX 5 ld ignores all but the last -rpath argument,"; echo " so if you need to specify more than one additional"; echo " runtime library directory, you will have to do so"; @@ -1850,884 +2002,362 @@ fi runtime_arg="-rpath " ;; *-sgi-irix* ) - # Note that IRIX gcc (as of 2.7.2) doesn't accept -rpath, so - # using it can cause trouble. Specifying --use-gcc=no will work - # around this, but the real problem is that configure uses $LDFLAGS - # as arguments to $(CC), instead of using prefix-args like the - # src/Makefile does. + dnl Note that IRIX gcc (as of 2.7.2) does not accept -rpath, so + dnl using it can cause trouble. Specifying --use-gcc=no will work + dnl around this, but the real problem is that configure uses $LDFLAGS + dnl as arguments to $(CC), instead of using prefix-args like the + dnl src/Makefile does. add_runtime_flag=yes; runtime_arg="-rpath " ;; esac - -if test -n "${x_libraries}" ; then - if test "${add_runtime_flag}" = "yes" ; then - LD_SWITCH_X_SITE="-L${x_libraries} ${runtime_arg}${x_libraries}" - else - LD_SWITCH_X_SITE="-L${x_libraries}" - fi fi -# LD_SWITCH_X_SITE_AUX (from FSF) is ill-conceived. See s/sol2*.h. -# test -n "${x_libraries}" -a LD_SWITCH_X_SITE_AUX="-R${x_libraries}" -test -n "${x_includes}" && C_SWITCH_X_SITE="-I${x_includes}" - -if test -n "${site_libraries}" ; then - for arg in ${site_libraries} - do - LD_SWITCH_SITE="${LD_SWITCH_SITE} -L${arg}" + +dnl --site-libraries (multiple dirs) +if test -n "$site_libraries"; then + for arg in $site_libraries; do + test -d "$arg" && arg="-L${arg}" + ld_switch_site="$ld_switch_site $arg" done fi -if test -n "${site_runtime_libraries}" ; then - for arg in ${site_runtime_libraries} - do - LD_SWITCH_SITE="${LD_SWITCH_SITE} -L${arg}" - LD_SWITCH_SITE="${LD_SWITCH_SITE} ${runtime_arg}${arg}" + +dnl --site-runtime-libraries (multiple dirs) +if test -n "$site_runtime_libraries" ; then + LD_RUN_PATH="`echo $site_runtime_libraries | sed 's/ */:/'`" + export LD_RUN_PATH +fi + +dnl --site-includes (multiple dirs) +if test -n "$site_includes" ; then + for arg in $site_includes; do + test -d "$arg" && arg="-I${arg}" + c_switch_site="$c_switch_site $arg" done fi -if test -n "${site_includes}" ; then - for arg in ${site_includes} - do - C_SWITCH_SITE="${C_SWITCH_SITE} -I${arg}" - CPP="${CPP} -I${arg}" - done -fi - -# FSF 19.29 has some bitmapdir stuff here. + + +dnl FSF 19.29 has some bitmapdir stuff here. bitmapdir= -# Avoid forcing the search of /usr/include before fixed include files. -test "$C_SWITCH_X_SITE" = "-I/usr/include" && C_SWITCH_X_SITE=" " - -# Need for check for audio/Xtutil.h. -CPP="${CPP} ${C_SWITCH_X_SITE}" - -case "${window_system}" in +case "$window_system" in x11 ) HAVE_X_WINDOWS=yes; echo " Using X11." ;; none ) HAVE_X_WINDOWS=no ; echo " Using no window system." ;; esac -if test "${opsys}" = "hpux9"; then - case "${x_libraries}" in - *X11R4* ) opsysfile="s/hpux9-x11r4.h" ;; - esac -fi - -if test "${opsys}" = "hpux9-shr"; then - case "${x_libraries}" in - *X11R4* ) opsysfile="s/hpux9shxr4.h" ;; - esac -fi - -############################################################################ -# # -# Extract some information from the operating system and machine files # -# # -############################################################################ - -echo "examining the machine- and system-dependent files to find out" -echo " - which libraries the lib-src programs will want, and" -echo " - whether the GNU malloc routines are usable." - -### First figure out CFLAGS (which we use for running the compiler here) -### and REAL_CFLAGS (which we use for real compilation). -### The two are the same except on a few systems, where they are made -### different to work around various lossages. For example, -### GCC 2.5 on Linux needs them to be different because it treats -g -### as implying static linking. - -### If the CFLAGS env var is specified, we use that value -### instead of the default. - -### It's not important that this name contain the PID; you can't run -### two configures in the same directory and have anything work -### anyway. -tempcname="conftest.c" - -echo ' -#define NOT_C_CODE -#include "'${srcdir}'/src/'${opsysfile}'" -#include "'${srcdir}'/src/'${machfile}'" -#ifndef LIBS_MACHINE -#define LIBS_MACHINE -#endif -#ifndef LIBS_SYSTEM -#define LIBS_SYSTEM -#endif -#ifndef C_SWITCH_SYSTEM -#define C_SWITCH_SYSTEM -#endif -#ifndef C_SWITCH_X_SYSTEM -#define C_SWITCH_X_SYSTEM -#endif -#ifndef C_SWITCH_MACHINE -#define C_SWITCH_MACHINE -#endif -#ifndef LD_SWITCH_X_SYSTEM -#define LD_SWITCH_X_SYSTEM -#endif -#ifndef LIB_STANDARD -#define LIB_STANDARD -#endif -configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM LIB_STANDARD -configure___ c_switch_system=C_SWITCH_SYSTEM -configure___ c_switch_x_system=C_SWITCH_X_SYSTEM -configure___ ld_switch_x_system=LD_SWITCH_X_SYSTEM -configure___ c_switch_machine=C_SWITCH_MACHINE - -#ifndef LIB_X11_LIB -#define LIB_X11_LIB -lX11 -#endif - -#ifndef LIBX11_MACHINE -#define LIBX11_MACHINE -#endif - -#ifndef LIBX11_SYSTEM -#define LIBX11_SYSTEM -#endif -configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM - -#ifdef UNEXEC -configure___ unexec=UNEXEC -#else -configure___ unexec=unexec.o -#endif - -#ifdef SYSTEM_MALLOC -configure___ system_malloc=yes -#else -configure___ system_malloc=no -#endif - -#ifndef C_DEBUG_SWITCH -#define C_DEBUG_SWITCH -g -#endif - -#ifndef C_OPTIMIZE_SWITCH -#define C_OPTIMIZE_SWITCH -O -#endif - -#ifdef THIS_IS_CONFIGURE - -/* Get the CFLAGS for tests in configure. */ -#ifdef __GNUC__ -configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}' -#else -configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}' -#endif - -#else /* not THIS_IS_CONFIGURE */ - -/* Get the CFLAGS for real compilation. */ -#ifdef __GNUC__ -configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}' -#else -configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}' -#endif - -#endif /* not THIS_IS_CONFIGURE */ -' > ${tempcname} -# The value of CPP is a quoted variable reference, so we need to do this -# to get its actual value... -CPP=`eval "echo $CPP"` -eval `${CPP} -Isrc ${tempcname} \ - | grep 'configure___' \ - | sed -n -e 's/^configure___ \([[^=]]*=\)\(.*\)$/\1"\2"/p'` -if test "x$SPECIFIED_CFLAGS" = x ; then - eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \ - | grep 'configure___' \ - | sed -n -e 's/^configure___ \([[^=]]*=\)\(.*\)$/\1"\2"/p'` -else - REAL_CFLAGS="$CFLAGS" -fi -rm ${tempcname} - -# override CFLAGS if user wishes -if test "${cflags}" != "NO_CFLAGS_DEFINED" ; then - REAL_CFLAGS=${cflags} -fi - -### Compute the unexec source name from the object name. -UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`" - -# Do the opsystem or machine files prohibit the use of the GNU malloc? -# Assume not, until told otherwise. -GNU_MALLOC=yes -if test "${system_malloc}" = "yes" ; then - GNU_MALLOC=no - GNU_MALLOC_reason=" - (The GNU allocators don't work with this system configuration.)" -elif test "${use_system_malloc}" = "yes" ; then - GNU_MALLOC=no - GNU_MALLOC_reason=" - (User chose not to use GNU allocators.)" +case "$x_libraries" in *X11R4* ) + test "$opsys" = "hpux9" && opsysfile="s/hpux9-x11r4.h" + test "$opsys" = "hpux9-shr" && opsysfile="s/hpux9shxr4.h" +esac + +AC_DEFINE(LISP_FLOAT_TYPE) dnl Uhconditional + +dnl Used by getloadavg() - does not require root priveleges +AC_CHECK_LIB(kstat, kstat_open) + +dnl Another way to get the load average +AC_CHECK_LIB(kvm, kvm_read) + +AC_CHECK_LIB(pthreads, cma_open) +if test "$ac_cv_lib_pthreads_cma_open" = "yes"; then + case "$opsys" in decosf*) c_switch_site="$c_switch_site -threads";; esac fi -LISP_FLOAT_TYPE=yes - - -#### Add the libraries to LIBS and check for some functions. - -CPPFLAGS="${C_SWITCH_SITE} $c_switch_system $c_switch_machine $c_switch_x_system $CPPFLAGS" -DEFS="${C_SWITCH_SITE} $c_switch_system $c_switch_machine $c_switch_x_system $DEFS" -LIBS="${LD_SWITCH_SITE} $ld_switch_x_system $libsrc_libs $LIBS" - -dnl If found, this defines HAVE_LIBDNET, which m/pmax.h checks, -dnl and also adds -ldnet to LIBS, which Autoconf uses for checks. -dnl FSF 19.29 also checks for function dnet_ntoa. -test "${with_dnet}" != "no" -a \ - "${with_dnet}" != "yes" && { AC_HAVE_LIBRARY(-ldnet, with_dnet="yes") } -IF_YES_AC_DEFINE(with_dnet, HAVE_LIBDNET) - -dnl This causes -lresolv to get used in subsequent tests, -dnl which causes failures on some systems such as HPUX 9. -dnl FSF 19.29 also checks for function gethostbyname. -dnl AC_HAVE_LIBRARY(-lresolv) - -dnl Alternative to getloadavg() that doesn't require root priveleges -AC_HAVE_LIBRARY(-lkstat) - -dnl Use -lintl if Mule available. -AC_HAVE_LIBRARY(-lintl, AC_DEFINE(HAVE_LIBINTL)) - -AC_HAVE_LIBRARY(-lXbsd, LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd") - -dnl FSF 19.29 also checks for function cma_open. -AC_HAVE_LIBRARY(-lpthreads, HAVE_PTHREADS=yes) -if test -n "${HAVE_PTHREADS}" ; then - AC_DEFINE(HAVE_PTHREADS) - case "${opsys}" in - decosf* ) CFLAGS="${CFLAGS} -threads" ;; - esac -fi - -if test "${window_system}" != "none" ; then - AC_CHECKING(for XFree86) - if test -d /usr/X386/include; then - HAVE_XFREE386=yes - test -z "${C_SWITCH_X_SITE}" && C_SWITCH_X_SITE="-I/usr/X386/include" - elif test -f /etc/XF86Config -o \ - -f /etc/X11/XF86Config -o \ - -f /usr/X11R6/lib/X11/XF86Config; then - HAVE_XFREE386=yes - test -z "${C_SWITCH_X_SITE}" && C_SWITCH_X_SITE="-I/usr/X11R6/include" - else - HAVE_XFREE386=no - fi - AC_VERBOSE(${HAVE_XFREE386}) -else - HAVE_XFREE386=no -fi - -############################################################################ -# # -# Test for various X-specific features # -# # -############################################################################ - -# Change CFLAGS temporarily for damn binutils 2.6.0.10 check. -if test "${HAVE_X_WINDOWS}" = "yes"; then - case "${opsys}" in - linux* ) - CFLAGS="-Wl,-rpath-link,/usr/X11R6/lib $CFLAGS" - AC_COMPILE_CHECK(whether path-link option is needed, [], - [;], - [need_path_link=yes], - [need_path_link=no]) - if test "${need_path_link}" = "no"; then - CFLAGS="$REAL_CFLAGS" - AC_VERBOSE(no) - else - AC_VERBOSE(yes) - fi - ;; - esac -fi - -# Change CFLAGS temporarily so that C_SWITCH_X_SITE gets used -# for the tests that follow. We set it back to REAL_CFLAGS later on. - -if test "${HAVE_X_WINDOWS}" = "yes"; then - DEFS="$C_SWITCH_X_SITE $DEFS" - LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE" - LIBS="$LIBX $LIBS" - CFLAGS="$C_SWITCH_X_SITE $CFLAGS" - - # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests. - # This is handled by LD_SWITCH_X_SITE_AUX during the real build, - # but it's more convenient here to set LD_RUN_PATH - # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX. - if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then - LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH - export LD_RUN_PATH - fi - - if test "${HAVE_XFREE386}" = "yes" ; then - case "${opsys}" in - linux* ) - AC_COMPILE_CHECK(whether XFree86 needs -b to link, [], - [XOpenDisplay ("foo");], - [xfree86_first_failure=no], - [xfree86_first_failure=yes]) - if test "${xfree86_first_failure}" = "yes"; then - OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE" - OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE" - OLD_CPPFLAGS="$CPPFLAGS" - OLD_LIBS="$LIBS" - LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout" - C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout" - CPPFLAGS="$CPPFLAGS -b i486-linuxaout" - LIBS="$LIBS -b i486-linuxaout" - AC_COMPILE_CHECK(,[], - [XOpenDisplay ("foo");], - [xfree86_second_failure=no], - [xfree86_second_failure=yes]) - if test "${xfree86_second_failure}" = "yes"; then - # If we get the same failure with -b, there is no use adding -b. - # So take it out. This plays safe. - LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE" - C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE" - CPPFLAGS="$OLD_CPPFLAGS" - LIBS="$OLD_LIBS" - AC_VERBOSE(no) - else - AC_VERBOSE(yes) - fi - else - AC_VERBOSE(no) - fi - ;; - esac - fi - -# A C_CHECK_FUNCS(XrmSetDatabase XScreenResourceString \ -#XScreenNumberOfScreen XSetWMProtocols) -fi - -# -# make sure we can find libX11.* -# -if test "${window_system}" != "none" ; then - internal_xlibs_found='no' - AC_HAVE_LIBRARY(-lX11, internal_xlibs_found='yes') - if test "${internal_xlibs_found}" = "no" ; then - echo "Unable to find X11 libraries." >&2 - exit 1 - else - AC_VERBOSE(yes) - fi -fi - -# -# make sure we can find Intrinsic.h -# -if test "${window_system}" != "none" ; then - internal_xincludes_found='no' - for arg in ${DEFS} /usr/include - do - if test -f `echo "${arg}/X11/Intrinsic.h" | sed 's/^\-I//'` ; then - internal_xincludes_found='yes' - fi - done - if test "${internal_xincludes_found}" = "no" ; then - echo "Unable to find X11 header files." >&2 - exit 1 - fi -fi - -# -# Sun OS 4 systems need the following kludge -# -if test "${window_system}" != "none" ; then - case "${canonical}" in *-sunos4* ) - LIBS="$LIBS -u _XtToolkitInitialize -u _get_applicationShellWidgetClass" ;; - esac -fi - -# -# See if we can find Xauth. -# -with_xauth='no' -if test "${window_system}" != "none" ; then - internal_xauth_lib_found='no' - AC_HAVE_LIBRARY(-lXau, internal_xauth_lib_found='yes') - if test "${internal_xauth_lib_found}" = "yes" ; then - internal_xauth_includes_found='no' - for arg in ${DEFS} /usr/include - do - if test -f `echo "${arg}/X11/Xauth.h" | sed 's/^\-I//'` ; then - internal_xauth_includes_found='yes' - fi - done - if test "${internal_xauth_includes_found}" = "yes" ; then - with_xauth='yes' - fi - fi -fi -IF_YES_AC_DEFINE(with_xauth, HAVE_XAUTH) - -# -# See if we can find CDE. -# -if test "${window_system}" != "none" -a \ - "${with_cde}" != "no" -a \ - "${with_cde}" != "yes" ; then - internal_cde_lib_found='no' - AC_HAVE_LIBRARY(-lDtSvc, internal_cde_lib_found='yes') - if test "${internal_cde_lib_found}" = "no" -a -f "/usr/dt/lib/libDtSvc.a"; then - internal_cde_lib_found="yes" +AC_MSG_CHECKING(whether the -xildoff compiler flag is required) +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 AC_MSG_RESULT(no); + else AC_MSG_RESULT(yes); ld_switch_site="$ld_switch_site -xildoff" fi - if test "${internal_cde_lib_found}" = "yes" ; then - internal_cde_includes_found='no' - for arg in ${DEFS} /usr/include /usr/dt/include ; do - if test -f `echo "${arg}/Dt/Dt.h" | sed 's/^\-I//'` ; then - internal_cde_includes_found='yes' - fi - done - if test "${internal_cde_includes_found}" = "yes" ; then - with_cde='yes' - fi - fi + else AC_MSG_RESULT(no) fi -IF_YES_AC_DEFINE(with_cde, HAVE_CDE) - -# having CDE implies Tooltalk -if test "${with_cde}" = "yes" -a \ - "${with_tooltalk}" != "no" -a \ - "${with_tooltalk}" != "none" ; then - with_tooltalk='yes' + +dnl Autodetect Xauth +test -z "$with_xauth" && test "$window_system" = "none" && with_xauth=no +test -z "$with_xauth" && { AC_CHECK_HEADER(X11/Xauth.h, ,with_xauth=no) } +test -z "$with_xauth" && { AC_CHECK_LIB(Xau, XauGetAuthByAddr,[:],with_xauth=no) } +test -z "$with_xauth" && with_xauth=yes +if test "$with_xauth" = "yes"; then + AC_DEFINE(HAVE_XAUTH) + libs_x="-lXau $libs_x" fi -# having CDE requires Motif -if test "${with_cde}" = "yes" ; then - motif_libs="-lXm -lXt" +dnl Autodetect OffiX +test -z "$with_offix" && { AC_CHECK_HEADER(OffiX/DragAndDrop.h, , with_offix=no) } +test -z "$with_offix" && { AC_CHECK_LIB(Dnd, DndInitialize, [:] , with_offix=no) } +test -z "$with_offix" && with_offix=yes +if test "$with_offix" = "yes"; then + AC_DEFINE(HAVE_OFFIX_DND) + libs_x="-lDnd $libs_x" fi -# -# See if we can find OffiX. -# -if test "${window_system}" != "none" -a \ - "${with_offix}" != "no" -a \ - "${with_offix}" != "yes" ; then - internal_offix_lib_found='no' - AC_HAVE_LIBRARY(-lDnd, internal_offix_lib_found='yes') - if test "${internal_offix_lib_found}" = "yes" ; then - internal_offix_includes_found='no' - for arg in ${DEFS} /usr/include ; do - if test -f `echo "${arg}/OffiX/DragAndDrop.h" | sed 's/^\-I//'` ; then - internal_offix_includes_found='yes' - fi - done - test "${internal_offix_includes_found}" = "yes" && with_offix='yes' - fi -fi -IF_YES_AC_DEFINE(with_offix, HAVE_OFFIX_DND) - -# X window options -if test "${window_system}" != "none" ; then - AC_FIND_X_VERSION - AC_HAVE_HEADERS(X11/Xlocale.h) +dnl Autodetect tooltalk +test "$with_cde" = "yes" && with_tooltalk=yes # CDE requires tooltalk +if test "$with_tooltalk" != "no" ; then + dnl autodetect the location of tt_c.h + dnl tt_c.h might be in Tt or desktop include directories + for dir in "" "Tt/" "desktop/" ; do + AC_CHECK_HEADER(${dir}tt_c.h, tt_c_h_path="${dir}tt_c.h" && break) + done + test -z "$tt_c_h_path" && with_tooltalk=no fi - -# -# if Energize specified, make sure we can find its need libraries/headers -# -if test "${with_energize}" = "yes" ; then - AC_HAVE_LIBRARY(-lenergize, energize_version='3.X') - if test "${energize_version}" = "no" ; then - AC_HAVE_LIBRARY(-lconn, energize_version='2.X') - if test "${energize_version}" = "no" ; then - echo "Unable to find Energize library." >&2 - exit 1 - fi - fi - - internal_eincludes_found='no' - for arg in ${DEFS} /usr/include - do - if test -f `echo "${arg}/editorconn.h" | sed 's/^\-I//'` ; then - internal_eincludes_found='yes' - fi +if test "$with_tooltalk" != "no" ; then + for extra_libs in "" "-lI18N -lce" "-lcxx"; do + AC_CHECK_LIB(tt, tt_message_create, + with_tooltalk=yes tt_libs="-ltt $extra_libs"; break, [:],$extra_libs) done - if test "${internal_eincludes_found}" = "no" ; then - echo "Unable to find Energize editorconn.h header file." >&2 - exit 1 - fi +fi +test -z "$with_tooltalk" && with_tooltalk=no +if test "$with_tooltalk" = "yes"; then + AC_DEFINE(TOOLTALK) + AC_DEFINE_UNQUOTED(TT_C_H_PATH, "$tt_c_h_path") + libs_x="$tt_libs $libs_x" + extra_objs="$extra_objs tooltalk.o" fi -# -# logb and frexp are found in -lm on most systems. -# -AC_HAVE_LIBRARY(-lm) - -# -# see if XPM is hanging around somewhere -# -test "${window_system}" != "none" -a \ - "${with_xpm}" != "no" -a \ - "${with_xpm}" != "yes" && { AC_HAVE_LIBRARY(-lXpm, with_xpm="yes") } - -IF_YES_AC_DEFINE(with_xpm, HAVE_XPM) - -# -# see if Xmu is hanging around somewhere -# -# FSF 19.31 has this: -#dnl If using toolkit, check whether libXmu.a exists. -#dnl tranle@intellicorp.com says libXmu.a can need XtMalloc in libXt.a to link. -# OLDLIBS="$LIBS" -# if test x$HAVE_X11XTR6 = xyes; then -# LIBS="-lXt -lSM -lICE $LIBS" -# else -# LIBS="-lXt $LIBS" -# fi -# A C_CHECK_LIB(Xmu, XmuConvertStandardSelection) -# LIBS="$OLDLIBS" - -if test "${window_system}" != "none" ; then - if test "${with_xmu}" != "no" ; then - test "${with_xmu}" != "yes" && { AC_HAVE_LIBRARY(-lXmu, with_xmu="yes") } - # On SunOS4 (and 5!) we must kludge harder to try to detect Xmu - # Upgrade to autoconf 2 and use ac_check_lib - mrb - if test "${with_xmu}" != "yes" ; then - # begin expansion of ac_have_library - ac_save_LIBS="${LIBS}" - LIBS="${LIBS} -lXmu -lXt -lXext -lX11 -lm" - if test ${machine} = sparc -a ${opsys} = linux; then - LIBS="${LIBS} -lICE -lSM" - fi - ac_have_lib="" - cat > conftest.${ac_ext} <<EOF -int main() { return 0; } -EOF - if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - fi - rm -f conftest* - LIBS="${ac_save_LIBS}" - test -n "${ac_have_lib}" && with_xmu="yes" - # end expansion of ac_have_library +dnl Autodetect CDE +test -z "$with_cde" && { AC_CHECK_HEADER(Dt/Dt.h, , with_cde=no) } +test -z "$with_cde" && { AC_CHECK_LIB(DtSvc, DtDndDragStart, [:], with_cde=no) } +test -z "$with_cde" && with_cde=yes +if test "$with_cde" = "yes" ; then + AC_DEFINE(HAVE_CDE) + libs_x="-lDtSvc $libs_x" + with_tooltalk=yes # CDE requires Tooltalk + with_motif=yes # CDE requires Motif +fi + +dnl if Energize specified, make sure we can find its need libraries/headers +if test "$with_energize" = "yes" ; then + AC_DEFINE(ENERGIZE) + AC_CHECK_LIB(energize, main, [ + LIBS="$LIBS -lenergize" + energize_version="3.X" + AC_DEFINE(ENERGIZE_3)]) + if test -z "$energize_version"; then + AC_CHECK_LIB(conn, main, [ + LIBS="$LIBS -lconn" + energize_version="2.X" + AC_DEFINE(ENERGIZE_2)], + [AC_MSG_ERROR(Unable to find Energize library.)]) fi - # Sparc/Linux test - fp - if test "${with_xmu}" != "yes" -a ${machine} = sparc -a ${opsys} = linux; then - # begin expansion of ac_have_library - ac_save_LIBS="${LIBS}" - LIBS="${LIBS} -lXmu -lXt -lXext -lX11 -lm -lICE -lSM" - ac_have_lib="" - cat > conftest.${ac_ext} <<EOF -int main() { return 0; } -EOF - if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - fi - rm -f conftest* - LIBS="${ac_save_LIBS}" - test -n "${ac_have_lib}" && with_xmu="yes" - # end expansion of ac_have_library - fi - # On UnixWare 2.1 we must kludge harder to try to detect Xmu - # Upgrade to autoconf 2 and use ac_check_lib - mrb - if test "${with_xmu}" != "yes" && test -f "/.UpgradeVer2.1" ; then - # begin expansion of ac_have_library - ac_save_LIBS="${LIBS}" - if test x$HAVE_XFREE386 = xyes; then - LIBS="-lXt -lSM -lICE ${LIBS}" - else - LIBS="${LIBS} -lXmu -lXt -lXext -lX11" - fi - ac_have_lib="" - cat > conftest.${ac_ext} <<EOF -int main() { return 0; } -EOF - if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - fi - rm -f conftest* - LIBS="${ac_save_LIBS}" - test -n "${ac_have_lib}" && with_xmu="yes" - # end expansion of ac_have_library - fi - fi + AC_CHECK_HEADER(editorconn.h, , + [AC_MSG_ERROR(Unable to find Energize editorconn.h header file.)]) + + test "$energize_version" = "2.X" && AC_DEFINE(ENERGIZE_2) + test "$energize_version" = "3.X" && AC_DEFINE(ENERGIZE_3) +fi + +dnl ------------------ +dnl Graphics libraries +dnl ------------------ + +AC_CHECKING(for graphics libraries) +dnl Built-in GIF support defaults to yes +test -z "$with_gif" && with_gif=yes; +if test "$with_gif" = "yes"; then + AC_DEFINE(HAVE_GIF) + extra_objs="$extra_objs dgif_lib.o gif_err.o gifalloc.o" +fi + +dnl Autodetect Xpm +test -z "$with_xpm" && { AC_CHECK_HEADER(X11/xpm.h, ,with_xpm=no) } +test -z "$with_xpm" && { AC_CHECK_LIB(Xpm, XpmReadFileToData,[:],with_xpm=no) } +test -z "$with_xpm" && with_xpm=yes +if test "$with_xpm" = "yes"; then + AC_DEFINE(HAVE_XPM) + libs_x="-lXpm $libs_x" +fi + +dnl Autodetect XFACE +test -z "$with_xface" && { AC_CHECK_HEADER(compface.h, ,with_xface=no) } +test -z "$with_xface" && { AC_CHECK_LIB(compface, UnGenFace,[:] ,with_xface=no) } +test -z "$with_xface" && with_xface=yes +if test "$with_xface" = "yes"; then + AC_DEFINE(HAVE_XFACE) + libs_x="-lcompface $libs_x" fi -IF_YES_AC_DEFINE(with_xmu, HAVE_XMU) - -# -# see if COMPFACE is hanging around somewhere -# -if test "${window_system}" != "none" -a \ - "${with_xface}" != "no" -a \ - "${with_xface}" != "yes" ; then - AC_HEADER_CHECK(compface.h, compface_incl="yes", with_xface="no") - if test "${compface_incl}" = "yes" ; then - AC_HAVE_LIBRARY(-lcompface, with_xface="yes") - fi + +dnl autodetect JPEG +test -z "$with_jpeg" && { AC_CHECK_HEADER(jpeglib.h, ,with_jpeg=no) } +test -z "$with_jpeg" && { AC_CHECK_LIB(jpeg, jpeg_destroy_decompress,[:],with_jpeg=no) } +test -z "$with_jpeg" && with_jpeg=yes +if test "$with_jpeg" = "yes"; then + AC_DEFINE(HAVE_JPEG) + libs_x="-ljpeg $libs_x" fi -IF_YES_AC_DEFINE(with_xface, HAVE_XFACE) - -# -# check whether we're using GIF support -# -if test "${window_system}" = "none" ; then - if test -z "${with_gif}" ; then - with_gif=no - elif test "${with_gif}" != "no" ; then - echo "GIF support cannot be specified without a window system." - exit 1 - fi -elif test -z "${with_gif}" ; then - with_gif=yes + +dnl autodetect PNG +test -z "$with_png" && { AC_CHECK_HEADER(png.h, , with_png=no) } +test -z "$with_png" && { AC_CHECK_FUNC(pow, , with_png=no) } +if test "$with_png" != "no"; then + for extra_libs in "" "-lz" "-lgz"; do + AC_CHECK_LIB(png, png_read_image, + png_libs="-lpng $extra_libs" with_png=yes; break,[:],$extra_libs) + done +fi +test -z "$with_png" && with_png=no +if test "$with_png" = "yes"; then + AC_DEFINE(HAVE_PNG) + libs_x="$png_libs $libs_x" fi -IF_YES_AC_DEFINE(with_gif, HAVE_GIF) - -dnl # autodetect JPEG -if test "${window_system}" = "none" ; then - if test -z "${with_jpeg}" ; then - with_jpeg=no - elif test "${with_jpeg}" != "no" ; then - echo "JPEG support cannot be specified without a window system." - exit 1 - fi -else - if test "${with_jpeg}" != "no" -a \ - "${with_jpeg}" != "yes" ; then - AC_HEADER_CHECK(jpeglib.h, jpeglib_incl="yes", with_jpeg="no") - test "${jpeglib_incl}" = "yes" && { AC_HAVE_LIBRARY(-ljpeg, with_jpeg="yes") } - fi + +dnl autodetect TIFF (not yet implemented) +if test "$with_tiff" = "yes"; then + AC_DEFINE(HAVE_TIFF) + libs_x="-ltiff $libs_x" fi -IF_YES_AC_DEFINE(with_jpeg, HAVE_JPEG) - -dnl ### autodetect PNG -if test "${window_system}" = "none" ; then - if test -z "${with_png}" ; then - with_png=no - elif test "${with_png}" != "no" ; then - echo "PNG support cannot be specified without a window system." - exit 1 - fi -fi -test -z "${with_png}" && { AC_HEADER_CHECK(png.h, , with_png="no") } -test -z "${with_png}" && { AC_FUNC_CHECK(pow, , with_png="no") } -if test -z "${with_png}" ; then - AC_HAVE_LIBRARY(-lz, with_png="yes") - test -z "${with_png}" && { AC_HAVE_LIBRARY(-lgz, with_png="gnuz", with_png="no") } - if test "${with_png}" != "no"; then - png_save_libs="${LIBS}" - case "${with_png}" in - yes ) LIBS="${LIBS} -lz" ;; - gnuz ) LIBS="${LIBS} -lgz" ;; - esac - AC_HAVE_LIBRARY(-lpng, , with_png="no") - LIBS="$png_save_libs" - fi -fi -case "${with_png}" in - yes ) AC_DEFINE(HAVE_PNG) ;; - gnuz ) AC_DEFINE(HAVE_PNG) AC_DEFINE(HAVE_PNG_GNUZ) ;; + +dnl Finish ensuring that we have values for the various toolkit items. +dnl Not all toolkits support all widgets +dnl if Motif is available we use it for the dialog boxes. + +case "$with_menubars" in "" | "yes" | "athena" ) + with_menubars="lucid" ;; +esac +case "$with_dialogs" in "" | "yes" | "lucid" ) + if test "$have_motif" = "yes"; then with_dialogs="motif" + elif test "$have_xaw" = "yes"; then with_dialogs="athena" + else with_dialogs=no + fi ;; +esac +case "$with_scrollbars" in "" | "yes" ) + with_scrollbars="lucid" ;; +esac + +all_widgets="$with_menubars $with_scrollbars $with_dialogs $with_toolbars" + +case "$all_widgets" in *athena* ) + AC_DEFINE(LWLIB_USES_ATHENA) + libs_x="-lXaw $libs_x" ;; esac -dnl ### autodetect TIFF (not yet implemented) -IF_YES_AC_DEFINE(with_tiff, HAVE_TIFF) - -# We use Lucid toolkit defaults for the menubars and scrollbars, but -# if Motif is available we use it for the dialog boxes. -if test "${window_system}" != "none" ; then - save_libs="${LIBS}" - if test "x${with_dialogs}" = "x" ; then - # We can't use ac_have_library because it simply appends -lXm to the - # end of the link line which is insufficient since -lXm will generate - # dependencies on -lXt -# begin expansion of ac_have_library -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lXm -lXt ${LIBS}" -ac_have_lib="" -test -n "$silent" || echo "checking for -lXm" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_dialogs="motif" motif_libs="-lXm -lXt" -else - :; -fi -# end expansion of ac_have_library - # Sigh. My Motif (MoTeeth) under Linux also depends on Xpm and Xext. - if test "${with_dialogs}" != "motif" ; then -# begin expansion of ac_have_library -ac_save_LIBS="${LIBS}" -LIBS="${LIBS} -lXm -lXt -lXpm -lXext ${LIBS}" -ac_have_lib="" -test -n "$silent" || echo "checking for -lXm in another way" -cat > conftest.${ac_ext} <<EOF -#include "confdefs.h" - -int main() { return 0; } -int t() { main();; return 0; } -EOF -if eval $ac_compile; then - rm -rf conftest* - ac_have_lib="1" - -fi -rm -f conftest* -LIBS="${ac_save_LIBS}" -if test -n "${ac_have_lib}"; then - :; with_dialogs="motif" motif_libs="-lXm -lXt -lXpm -lXext" -else - :; +case "$all_widgets" in *motif* ) + AC_DEFINE(LWLIB_USES_MOTIF) + need_motif=yes ;; +esac + +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) + +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_menubars" = "lucid" && AC_DEFINE(LWLIB_MENUBARS_LUCID) +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_menubars" != "no" && extra_objs="$extra_objs menubar.o" +test "$with_scrollbars" != "no" && extra_objs="$extra_objs scrollbar.o" +test "$with_dialogs" != "no" && extra_objs="$extra_objs dialog.o" +test "$with_toolbars" != "no" && extra_objs="$extra_objs toolbar.o" +test "$all_widgets" != "no no no no" && extra_objs="$extra_objs gui.o" + +if test "$with_x11" = "yes"; then + test "$with_menubars" != "no" && extra_objs="$extra_objs menubar-x.o" + test "$with_scrollbars" != "no" && extra_objs="$extra_objs scrollbar-x.o" + test "$with_dialogs" != "no" && extra_objs="$extra_objs dialog-x.o" + test "$with_toolbars" != "no" && extra_objs="$extra_objs toolbar-x.o" + test "$all_widgets" != "no no no no" && extra_objs="$extra_objs gui-x.o" fi -# end expansion of ac_have_library - fi - test "${with_dialogs}" = "motif" && AC_VERBOSE(Found Motif) - fi -fi - -# Finish ensuring that we have values for the various toolkit items. - -test "${with_menubars}" = "motif" -o \ - "${with_scrollbars}" = "motif" -o \ - "${with_dialogs}" = "motif" && with_motif="yes" -test "${with_menubars}" = "athena" -o \ - "${with_scrollbars}" = "athena" -o \ - "${with_dialogs}" = "athena" && with_athena="yes" -test "${with_menubars}" = "athena3d" -o \ - "${with_scrollbars}" = "athena3d" -o \ - "${with_dialogs}" = "athena3d" && with_athena="yes" -test "${with_menubars}" = "" && with_menubars="lucid" -test "${with_menubars}" = "athena" && with_menubars="lucid" -test "${with_scrollbars}" = "" && with_scrollbars="lucid" -test "${with_dialogs}" = "" && with_dialogs="athena" -test "${with_dialogs}" = "lucid" && with_dialogs="athena" - -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_menubars}" = "lucid" && AC_DEFINE(LWLIB_MENUBARS_LUCID) -test "${with_menubars}" = "motif" && AC_DEFINE(LWLIB_MENUBARS_MOTIF) -test "${with_scrollbars}" = "lucid" && AC_DEFINE(LWLIB_SCROLLBARS_LUCID) -test "${with_scrollbars}" = "motif" && AC_DEFINE(LWLIB_SCROLLBARS_MOTIF) -test "${with_scrollbars}" = "athena" && AC_DEFINE(LWLIB_SCROLLBARS_ATHENA) -if test "${with_scrollbars}" = "athena3d"; then - AC_DEFINE(LWLIB_SCROLLBARS_ATHENA) - AC_DEFINE(LWLIB_SCROLLBARS_ATHENA3D) -fi -test "${with_dialogs}" = "motif" && AC_DEFINE(LWLIB_DIALOGS_MOTIF) -test "${with_dialogs}" = "athena" && AC_DEFINE(LWLIB_DIALOGS_ATHENA) -if test "${with_dialogs}" = "athena3d"; then - AC_DEFINE(LWLIB_DIALOGS_ATHENA) - AC_DEFINE(LWLIB_DIALOGS_ATHENA3D) -fi - -############################################################################ -# # -# Misc other feature tests # -# # -############################################################################ - -# Mule-dependent option processing + +dnl ------------------------ +dnl Misc other feature tests +dnl ------------------------ + +dnl Mule-dependent option processing +test -z "$with_mule" && with_mule=no + if test "$with_mule" = "yes" ; then - # Do we have the XmIm* routines? And if so, do we want to use them? - test "$with_xim" != no && AC_CHECKING(for XIM) - if test -z "$with_xim" -o "$with_xim" = "yes" ; then - xim_save_libs="$LIBS" - LIBS="${motif_libs} ${LIBS}" - AC_FUNC_CHECK(XmImMbLookupString, have_XmIm=yes, have_XmIm=no) - LIBS="$xim_save_libs" - if test "$with_xim" = "yes" -a "$have_XmIm" = "yes"; then with_xim=motif - elif test "$with_xim" = "yes"; then with_xim=xlib - else with_xim=no - fi - fi + AC_DEFINE(MULE) + extra_objs="$extra_objs mule.o mule-ccl.o mule-charset.o mule-coding.o" + + dnl Use -lintl to get internationalized strerror for Mule + AC_CHECK_LIB(intl, strerror) + + AC_CHECKING(for Mule input methods) + dnl Do we have the XmIm* routines? And if so, do we want to use them? + case "$with_xim" in "" | "yes" ) + AC_CHECKING(for XIM) + AC_CHECK_LIB(Xm, XmImMbLookupString, with_xim=motif, with_xim=xlib) + esac if test "$with_xim" != "no" ; then AC_DEFINE(HAVE_XIM) - test "$with_xim" = "xlib" && AC_DEFINE(XIM_XLIB) - test "$with_xim" = "motif" && AC_DEFINE(XIM_MOTIF) + if test "$with_xim" = "xlib"; then + AC_DEFINE(XIM_XLIB) + extra_objs="$extra_objs input-method-xlib.o" fi - # wnn6 implies wnn support - if test "$with_wnn6" = "yes" ; then - with_wnn=yes + if test "$with_xim" = "motif"; then + AC_DEFINE(XIM_MOTIF) + need_motif=yes + extra_objs="$extra_objs input-method-motif.o" fi -else # Other internationalization features depend on Mule - with_mule="no" - for feature in xim canna wnn wnn6 ; do - if eval "test -n \"\$with_$feature\" -a \"\$with_$feature\" != no" ; then - AC_WARN(--with-$feature ignored: Not valid without Mule support) fi - eval "with_$feature=no" - done -fi - -# -# set defaults for finding WNN includes and libs -# -if test "${with_wnn}" = "yes" ; then - for arg in "-I${wnn_includes}" "-I/usr/X11R6/include/wnn" "-I/usr/include/wnn" - do - if test -f `echo "${arg}/wnnerror.h" | sed 's/^\-I//'` ; then - C_SWITCH_SITE="${C_SWITCH_SITE} ${arg}" - wnn_includes=${arg} - break + + dnl Autodetect WNN + test "$with_wnn6" = "yes" && with_wnn=yes # wnn6 implies wnn support + test -z "$with_wnn" && { AC_CHECK_HEADER(wnn/wnnerror.h, ,with_wnn=no) } + test -z "$with_wnn" && { AC_CHECK_LIB(wnn,jl_dic_list,[:],with_wnn=no) } + test -z "$with_wnn" && with_wnn=yes + if test "$with_wnn" = "yes"; then + AC_DEFINE(HAVE_WNN) + libs_x="-lwnn $libs_x" + extra_objs="$extra_objs mule-wnnfns.o" + AC_CHECK_LIB(wnn, jl_fi_dic_list, with_wnn6=yes) + test "$with_wnn6" = "yes" && AC_DEFINE(HAVE_WNN6) fi - done - for arg in "-L${wnn_libraries}" "-L/usr/X11R6/lib" "-L/usr/lib" - do - if test -f `echo "${arg}/libwnn.a" | sed 's/^\-L//'` ; then - LD_SWITCH_SITE="${LD_SWITCH_SITE} ${arg}" - wnn_libraries=${arg} - break + + dnl Autodetect canna + test -z "$with_canna" && { AC_CHECK_HEADER(canna/RK.h, , with_canna=no) } + test -z "$with_canna" && { AC_CHECK_LIB(RKC, RkBgnBun, [:],with_canna=no) } + test -z "$with_canna" && { AC_CHECK_LIB(canna,jrKanjiControl,[:],with_canna=no) } + test -z "$with_canna" && with_canna=yes + if test "$with_canna" = "yes"; then + AC_DEFINE(HAVE_CANNA) + libs_x="-lcanna -lRKC $libs_x" + extra_objs="$extra_objs mule-canna.o" fi +else # "$with_mule" = "no" + for feature in xim canna wnn; do + if eval "test -n \"\$with_${feature}\" -a \"\$with_${feature}\" != no" ; then + AC_MSG_WARN("--with-${feature} ignored: Not valid without Mule support") + fi + eval "with_${feature}=no" done fi -# -# set defaults for finding Canna includes and libs -# -if test "${with_canna}" = "yes" ; then - for arg in "-I${canna_includes}" "-I/usr/X11R6/include" - do - if test -f `echo "${arg}/canna/RK.h" | sed 's/^\-I//'` ; then - C_SWITCH_SITE="${C_SWITCH_SITE} ${arg}" - canna_includes=${arg} - break - fi - done - for arg in "-L${canna_libraries}" "-L/usr/X11R6/lib" - do - if test -f `echo "${arg}/libcanna.a" | sed 's/^\-L//'` ; then - LD_SWITCH_SITE="${LD_SWITCH_SITE} ${arg}" - canna_libraries=${arg} - break - fi - done -fi - -# If netdb.h doesn't declare h_errno, we must declare it by hand. -AC_COMPILE_CHECK(declaration of h_errno in netdb.h, - [#include <netdb.h>], - [int i = h_errno;], - AC_DEFINE(HAVE_H_ERRNO)) - -AC_COMPILE_CHECK(sigsetjmp, - [#include <setjmp.h>], + +dnl At this point, we know whether we need the motif lib or not. +test "$need_motif" = "yes" && libs_x="-lXm $libs_x" + +AC_CHECK_FUNCS(acosh asinh atanh cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random realpath rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask strcasecmp strerror tzset utimes waitpid) + +test "$ac_cv_func_realpath" = "yes" && extra_objs="$extra_objs realpath.o" + +dnl If netdb.h does not declare h_errno, we must declare it by hand. +AC_MSG_CHECKING(whether netdb declares h_errno) +AC_TRY_LINK([#include <netdb.h>], + [return h_errno;], + [AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_H_ERRNO)], + [AC_MSG_RESULT(no)]) + +AC_MSG_CHECKING(for sigsetjmp) +AC_TRY_COMPILE([#include <setjmp.h>], [sigjmp_buf bar; sigsetjmp (bar, 0);], - AC_DEFINE(HAVE_SIGSETJMP)) - -AC_CHECKING(whether localtime caches TZ) -emacs_cv_localtime_cache= -AC_TEST_PROGRAM([#include <time.h> -#if 1 /* STDC_HEADERS */ + [AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_SIGSETJMP)], + [AC_MSG_RESULT(no)]) + +AC_MSG_CHECKING(whether localtime caches TZ) +AC_CACHE_VAL(emacs_cv_localtime_cache, +[if test "$ac_cv_func_tzset" = "yes"; then +AC_TRY_RUN([#include <time.h> +#if STDC_HEADERS # include <stdlib.h> #endif extern char **environ; @@ -2738,16 +2368,18 @@ if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '=')) to++; } +char TZ_GMT0[] = "TZ=GMT0"; +char TZ_PST8[] = "TZ=PST8"; main() { time_t now = time ((time_t *) 0); int hour_GMT0, hour_unset; - if (putenv ("TZ=GMT0") != 0) + if (putenv (TZ_GMT0) != 0) exit (1); hour_GMT0 = localtime (&now)->tm_hour; unset_TZ (); hour_unset = localtime (&now)->tm_hour; - if (putenv ("TZ=PST8") != 0) + if (putenv (TZ_PST8) != 0) exit (1); if (localtime (&now)->tm_hour == hour_GMT0) exit (1); @@ -2758,14 +2390,19 @@ }], emacs_cv_localtime_cache=no, emacs_cv_localtime_cache=yes, [# If we have tzset, assume the worst when cross-compiling. emacs_cv_localtime_cache=yes]) -AC_VERBOSE("$emacs_cv_localtime_cache") -if test x$emacs_cv_localtime_cache = xyes; then +else + # If we lack tzset, report that localtime does not cache TZ, + # since we can't invalidate the cache if we don't have tzset. + emacs_cv_localtime_cache=no +fi],[:])dnl +AC_MSG_RESULT($emacs_cv_localtime_cache) +if test $emacs_cv_localtime_cache = yes; then AC_DEFINE(LOCALTIME_CACHE) fi -if test "x$HAVE_TIMEVAL" = xyes; then -AC_COMPILE_CHECK(whether gettimeofday can't accept two arguments, -[ +if test "$HAVE_TIMEVAL" = "yes"; then +AC_MSG_CHECKING(whether gettimeofday cannot accept two arguments) +AC_TRY_LINK([ #ifdef TIME_WITH_SYS_TIME #include <sys/time.h> #include <time.h> @@ -2782,279 +2419,434 @@ struct timezone dummy; gettimeofday (&time, &dummy); ], - [AC_VERBOSE(no)], - [AC_VERBOSE(yes) + [AC_MSG_RESULT(no)], + [AC_MSG_RESULT(yes) AC_DEFINE(GETTIMEOFDAY_ONE_ARGUMENT)]) fi -AC_COMPILE_CHECK(whether inline functions are supported, - , - [ -inline int -foo () -{ - return 0; -} -], - AC_DEFINE(HAVE_INLINE)) - -# This does all sorts of magic to make sure alloca() works OK. -# It might even add some junk to the top of <config.h>. -# (I don't understand what goes on here, but it seems to work.) -AC_ALLOCA - -# Check whether vfork exists and works correctly. (This does more -# than just check for its existence.) If so, it defines HAVE_VFORK_H. -# If not, it defines vfork to be fork. -AC_VFORK - -# Check whether mmap exists and works correctly. (This does more -# than just check for its existence.) If so, it defines HAVE_MMAP. -# Actually, this seems to rule out some cases where mmap() can -# work fine for our purposes (e.g. HPUX). We get a big win out -# of using mmap(), so let's go back to the old way. -dnl AC_MMAP - -# Check whether strcoll exists and works correctly. (This does more -# than just check for its existence.) If so, it defines HAVE_STRCOLL. -AC_STRCOLL - -AC_SIZEOF_TYPE(short) -AC_SIZEOF_TYPE(int) -AC_SIZEOF_TYPE(long) - -# FSF 19.29 does this: -# # fmod, logb, and frexp are found in -lm on most systems. -# # On HPUX 9.01, -lm does not contain logb, so check for sqrt. -# A C_CHECK_LIB(m, sqrt) - -AC_HAVE_FUNCS(acosh asinh atanh cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random realpath rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask strcasecmp strerror tzset utimes waitpid) - -# Check for mmap. -found_mmap=true -AC_FUNC_CHECK(mmap, , found_mmap=) -test -n "$found_mmap" && AC_DEFINE(HAVE_MMAP) - -dnl # rel_alloc requires either GNU malloc or system malloc with mmap -dnl # We only turn rel_alloc on by default if mmap is available. -test "${GNU_MALLOC}" != "yes" -a "${found_mmap}" != "true" && rel_alloc=no -test "${rel_alloc}" = "default" -a "${found_mmap}" = "true" && rel_alloc=yes - -# Check for Internet sockets. - -ok_so_far=true -AC_FUNC_CHECK(socket, , ok_so_far=) -test -n "$ok_so_far" && { AC_HEADER_CHECK(netinet/in.h, , ok_so_far=) } -test -n "$ok_so_far" && { AC_HEADER_CHECK(arpa/inet.h, , ok_so_far=) } -if test -n "$ok_so_far"; then + +AC_C_INLINE +test "$ac_cv_c_inline" != "no" && AC_DEFINE(HAVE_INLINE) + + +AC_FUNC_ALLOCA +test -n "$ALLOCA" && extra_objs="$extra_objs $ALLOCA" + +dnl Check whether vfork exists and works correctly. (This does more +dnl than just check for its existence.) If so, it defines HAVE_VFORK_H. +dnl If not, it defines vfork to be fork. +AC_FUNC_VFORK + +dnl Check whether strcoll exists and works correctly. (This does more +dnl than just check for its existence.) If so, it defines HAVE_STRCOLL. +AC_FUNC_STRCOLL + +AC_CHECK_SIZEOF(short) +AC_CHECK_SIZEOF(int) +AC_CHECK_SIZEOF(long) + +AC_FUNC_MMAP + +dnl rel_alloc requires either GNU malloc or system malloc with mmap +dnl We only turn rel_alloc on by default if mmap is available. +test "$GNU_MALLOC" != "yes" -a "$ac_cv_func_mmap_fixed_mapped" != "yes" && rel_alloc=no +test "$rel_alloc" = "default" -a "$ac_cv_func_mmap_fixed_mapped" = "yes" && rel_alloc=yes +test "$rel_alloc" = "yes" && AC_DEFINE(REL_ALLOC) + +dnl Check for Internet sockets. +AC_CHECK_FUNC(socket, + [AC_CHECK_HEADER(netinet/in.h, + [AC_CHECK_HEADER(arpa/inet.h, [ AC_DEFINE(HAVE_SOCKETS) - # Check for the sun_len member in struct sockaddr_un. - - AC_COMPILE_CHECK(sun_len member in struct sockaddr_un, - [#include <sys/types.h> - #include <sys/socket.h> - #include <sys/un.h>], [static struct sockaddr_un x; x.sun_len = 1;], - AC_DEFINE(HAVE_SOCKADDR_SUN_LEN)) -fi - -# Check for SYS V IPC. (Inferior to sockets.) - -if test -z "$ok_so_far"; then - ok_so_far=true - AC_FUNC_CHECK(msgget, , ok_so_far=) - test -n "$ok_so_far" && { AC_HEADER_CHECK(sys/ipc.h, , ok_so_far=) } - test -n "$ok_so_far" && { AC_HEADER_CHECK(sys/msg.h, , ok_so_far=) } - test -n "$ok_so_far" && AC_DEFINE(HAVE_SYSVIPC) -fi - -# Check for directory variants - -sysv_system_dir= -nonsystem_dir_library= -AC_HEADER_CHECK(dirent.h, sysv_system_dir=yes, ) -test -z "$sysv_system_dir" && - { AC_HEADER_CHECK(sys/dir.h, , nonsystem_dir_library=yes) } -if test -n "$sysv_system_dir" ; then AC_DEFINE(SYSV_SYSTEM_DIR) -elif test -n "$nonsystem_dir_library" ; then AC_DEFINE(NONSYSTEM_DIR_LIBRARY) -fi - -dnl # Check for terminal I/O variants - -echo "checking how to do terminal I/O" - -have_termios= -have_termio= -AC_HEADER_CHECK(termios.h, have_termios=yes, ) -dnl # TERMIOS systems may have termio.h, but not vice-versa, I think. -test -z "$have_termios" && { AC_HEADER_CHECK(termio.h, have_termio=yes, ) } -if test -n "$have_termios" ; then AC_DEFINE(HAVE_TERMIOS) -elif test -n "$have_termio" ; then AC_DEFINE(HAVE_TERMIO) -fi - -# Check for nlist.h -AC_HEADER_CHECK(nlist.h, AC_DEFINE(NLIST_STRUCT), ) - -# AIX export list -if test -f /usr/lpp/X11/bin/smt.exp ; then - AC_DEFINE(AIX_SMT_EXP, -bI:/usr/lpp/X11/bin/smt.exp) -elif test -f /usr/bin/X11/smt.exp ; then - AC_DEFINE(AIX_SMT_EXP, -bI:/usr/bin/X11/smt.exp) -fi - -dnl # Set up the CFLAGS for real compilation, so we can substitute it. + AC_MSG_CHECKING("for sun_len member in struct sockaddr_un") + AC_TRY_LINK([ +#include <sys/types.h> +#include <sys/socket.h> +#include <sys/un.h> + ], + [static struct sockaddr_un x; x.sun_len = 1;], + [AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SOCKADDR_SUN_LEN)], + [AC_MSG_RESULT(no)])])])]) + +dnl Check for SYS V IPC. (Inferior to sockets.) +AC_CHECK_FUNC(msgget, + [AC_CHECK_HEADER(sys/ipc.h, + [AC_CHECK_HEADER(sys/msg.h, + [AC_DEFINE(HAVE_SYSVIPC)])])]) + +dnl Check for directory variants +AC_CHECK_HEADER(dirent.h, [AC_DEFINE(SYSV_SYSTEM_DIR)], + [AC_CHECK_HEADER(sys/dir.h, , [AC_DEFINE(NONSYSTEM_DIR_LIBRARY)])]) + +dnl Check for nlist.h +AC_CHECK_HEADER(nlist.h, AC_DEFINE(NLIST_STRUCT), ) + +dnl AIX export list +for f in "/usr/lpp/X11/bin/smt.exp" "/usr/bin/X11/smt.exp" ; do + if test -r $f; then AC_DEFINE_UNQUOTED(AIX_SMT_EXP, -bI:$f) break; fi +done + +dnl Set up the CFLAGS for real compilation, so we can substitute it. CFLAGS="$REAL_CFLAGS" -dnl # Find out which version of XEmacs this is. -file="${srcdir}/lisp/version.el" +dnl Find out which version of XEmacs this is. +file="$srcdir/lisp/version.el" version=`sed -ne 's/^(defconst emacs-version "\(.*\)".*/\1/p' "$file"` -if test -z "${version}"; then - echo "${progname}: can't find current emacs version in \"$file\"." >&2 +if test -z "$version"; then + echo "$progname: can't find current emacs version in \"$file\"." >&2 exit 1 fi beta=`sed -ne 's/^.*XEmacs Lucid (beta\([[0-9]][[0-9]]*\)).*$/\1/p' "$file"` test -n "$beta" && version="${version}-b${beta}" -dnl # Check for sound of various sorts. - -# the following needs to be fixed for SGI. -if test -z "${native_sound_lib}" ; then - if test -r /usr/demo/SOUND/lib/libaudio.a; then - native_sound_lib=/usr/demo/SOUND/lib/libaudio.a - elif test -r /usr/demo/SOUND/libaudio.a ; then - native_sound_lib=/usr/demo/SOUND/libaudio.a +dnl Check for sound of various sorts. + +dnl Autodetect native sound +AC_CHECKING("for sound support") +case "$with_sound" in + native | both ) with_native_sound=yes;; + nas | no ) with_native_sound=no;; +esac +if test "$with_native_sound" != "no"; then + dnl Autodetect Sun native sound from SUNWaudmo package + if test -d "/usr/demo/SOUND"; then + sound_found="yes" extra_objs="$extra_objs sunplay.o" + if test -d "/usr/demo/SOUND/include" + then sound_cflags="-I/usr/demo/SOUND/include" + else sound_cflags="-I/usr/demo/SOUND" + fi + if test -z "$native_sound_lib" ; then + if test -r "/usr/demo/SOUND/lib/libaudio.a" + then native_sound_lib="/usr/demo/SOUND/lib/libaudio.a" + else native_sound_lib="/usr/demo/SOUND/libaudio.a" + fi + fi else - case "${canonical}" in - *-sgi-* ) AC_HAVE_LIBRARY(-laudio, native_sound_lib="-laudio") ;; - hppa*-hp-hpux* ) AC_HAVE_LIBRARY(-lAlib, native_sound_lib="-lAlib") ;; + case "$canonical" in \ + *-sgi-* ) + AC_CHECK_LIB(audio, ALopenport, native_sound_lib="-laudio") + if test "$native_sound_lib" = "-laudio"; then + sound_found="yes" extra_objs="$extra_objs sgiplay.o" sound_cflags="" + fi ;; + hppa*-hp-hpux* ) + AC_CHECK_LIB(Alib, AOpenAudio, native_sound_lib="-lAlib") + if test "$native_sound_lib" = "-lAlib"; then + sound_found="yes" extra_objs="$extra_objs hpplay.o" + if test "$with_gcc" = "yes" # Kludge city + then sound_cflags="-Dconst= -Dvolatile= -I/usr/audio/examples" + else sound_cflags="+e -I/usr/audio/examples" + fi + fi ;; esac fi + + if test -z "$sound_found"; then + for dir in "machine" "sys" "linux"; do + AC_CHECK_HEADER(${dir}/soundcard.h, + sound_found=yes + extra_objs="$extra_objs linuxplay.o" + [AC_DEFINE_UNQUOTED(SOUNDCARD_H_PATH, "${dir}/soundcard.h")] + break) + done + fi + + test "$sound_found" = "yes" && with_native_sound=yes fi -test -z "${with_sound}" -a -n "${native_sound_lib}" && with_sound="native"; - -#### If the nas library doesn't contain the error jump point, then -#### we force safer behaviour. - -if test "${with_sound}" = "nas" -o \ - "${with_sound}" = "both"; then - AC_HEADER_EGREP(AuXtErrorJump,audio/Xtutil.h, , old_nas=true) -fi - -if test "${with_cde}" = "yes" ; then - if test -f "/usr/dt/include/Dt/Dt.h" ; then - C_SWITCH_X_SITE="${C_SWITCH_X_SITE} -I/usr/dt/include" - fi - if test -f "/usr/dt/lib/libDtSvc.a" ; then - LD_SWITCH_X_SITE="${LD_SWITCH_X_SITE} -L/usr/dt/lib" + +if test -z "$with_sound"; then + if test "$with_native_sound" = "yes" -o -n "$native_sound_lib"; then + with_sound=native fi fi -if test "${with_tooltalk}" = "yes" ; then - for arg in "-I/usr/include/desktop" "-I${OPENWINHOME-/usr/openwin}/include/desktop" "-I/usr/dt/include/Tt" - do - if test -f `echo "${arg}/tt_c.h" | sed 's/^\-I//'` ; then - C_SWITCH_X_SITE="${C_SWITCH_X_SITE} ${arg}" - fi - done - for arg in "-L/usr/lib" "-L${OPENWINHOME-/usr/openwin}/lib" "-L/usr/dt/lib" - do - case "${arg}" in - -L*) if test -f `echo "${arg}/libtt.a" | sed 's/^\-L//'` ; then - dash_r='' - if test "${add_runtime_flag}" = "yes" ; then - dash_r=`echo ${arg} | sed "s/^-L */${runtime_arg}/"` - fi - LD_SWITCH_X_SITE="${LD_SWITCH_X_SITE} ${arg} ${dash_r}" - fi - ;; - esac - done +if test "$with_native_sound" = "yes"; then + AC_DEFINE(HAVE_NATIVE_SOUND) + test -n "$native_sound_lib" && LIBS="$LIBS $native_sound_lib" fi -dnl Check for ncurses. - -if test "${with_tty}" != "no" ; then - AC_HAVE_LIBRARY(-lncurses, have_ncurses=yes, have_ncurses=no) - if test "${have_ncurses}" = "yes" ; then +case "$with_sound" in both | nas ) + AC_DEFINE(HAVE_NAS_SOUND) + extra_objs="$extra_objs nas.o" + LIBS="$LIBS -laudio" + dnl If the nas library does not contain the error jump point, + dnl then we force safer behaviour. + AC_EGREP_HEADER(AuXtErrorJump,audio/Xtutil.h,,[AC_DEFINE(NAS_NO_ERROR_JUMP)]) +esac + + +dnl TTY-dependent options + + +AC_CHECKING("how to do terminal I/O") + +test -z "$with_tty" && with_tty=yes + +if test "$with_tty" = "yes" ; then + AC_DEFINE(HAVE_TTY) + + dnl Check for terminal I/O variants + dnl TERMIOS systems may have termio.h, but not vice-versa, I think. + AC_CHECK_HEADER(termios.h, [AC_DEFINE(HAVE_TERMIOS)], + [AC_CHECK_HEADER(termio.h, [AC_DEFINE(HAVE_TERMIO)])]) + + dnl Autodetect gpm + #### Attn: Bill Perry: Remove next line when GPM support is added + test -z "$with_gpm" && with_gpm=no + + test -z "$with_gpm" && { AC_CHECK_HEADER(gpm.h, , with_gpm=no) } + test -z "$with_gpm" && { AC_CHECK_LIB(gpm, connect_to_gpm, with_gpm=yes, with_gpm=no) } + if test "$with_gpm" = "yes"; then + AC_DEFINE(HAVE_GPM) + extra_objs="$extra_objs gpmevent.o" + LIBS="$LIBS -lgpm" + fi + + dnl Autodetect ncurses. + if test -z "$with_ncurses"; then + AC_CHECK_LIB(ncurses, tparm, with_ncurses=yes, with_ncurses=no) + fi + if test "$with_ncurses" = "yes"; then AC_DEFINE(HAVE_NCURSES) - AC_HEADER_CHECK(ncurses/term.h, have_ncurses_term_h=yes, have_ncurses_term_h=no) - IF_YES_AC_DEFINE(have_ncurses_term_h, HAVE_NCURSES_TERM_H) - AC_HEADER_CHECK(ncurses/curses.h, have_ncurses_curses_h=yes, have_ncurses_curses_h=no) - if test "${have_ncurses_curses_h}" = "no" ; then + AC_CHECK_HEADER(ncurses/curses.h, curses_h_path=ncurses/curses.h) + AC_CHECK_HEADER(ncurses/term.h, term_h_path=ncurses/term.h) + extra_objs="$extra_objs terminfo.o" + LIBS="$LIBS -lncurses" + + if test "$ac_cv_header_ncurses_curses_h" != "yes" ; then dnl Try again, and check for the bogus ncurses/ include bug. dnl (i.e. ncurses/curses.h bogusly includes <unctrl.h> instead of dnl <ncurses/unctrl.h>) - OLD_CPP="${CPP}" - CPP="${CPP} -I/usr/include/ncurses" - AC_HEADER_CHECK(ncurses/curses.h, have_ncurses_curses_h=yes, have_ncurses_curses_h=no) - if test "${have_ncurses_curses_h}" = "yes" ; then - site_includes="${site_includes} /usr/include/ncurses" - C_SWITCH_SITE="${C_SWITCH_SITE} -I/usr/include/ncurses" - AC_VERBOSE(Your system has the bogus ncurses include bug.) - else - CPP="${OLD_CPP}" + save_c_switch_site="$c_switch_site" + c_switch_site="$c_switch_site -I/usr/include/ncurses" + AC_CHECK_HEADER(ncurses/curses.h, curses_h_path=ncurses/curses.h) + if test "$ac_cv_header_ncurses_curses_h" = "yes"; + then AC_MSG_WARN("Your system has the bogus ncurses include bug.") + else c_switch_site="$save_c_switch_site" fi fi - IF_YES_AC_DEFINE(have_ncurses_curses_h, HAVE_NCURSES_CURSES_H) + else dnl "$with_ncurses" = "no" + dnl Autodetect terminfo/-ltermlib/-ltermcap/-lcurses + AC_CHECK_LIB(termlib, tgoto, have_libtermlib=yes, have_libtermlib=no) + AC_CHECK_LIB(termcap, tgoto, have_libtermcap=yes, have_libtermcap=no) + AC_CHECK_LIB(curses, tparm, have_libcurses=yes, have_libcurses=no) + + if test "$have_terminfo" = "yes"; then + extra_objs="$extra_objs terminfo.o" + if test -n "$libs_termcap"; then LIBS="$LIBS $libs_termcap" + elif test "$have_libcurses" = "yes"; then LIBS="$LIBS -lcurses" + elif test "$have_libtermlib" = "yes"; then LIBS="$LIBS -ltermlib" + elif test "$have_libtermcap" = "yes"; then LIBS="$LIBS -ltermcap" + fi + else dnl "$have_terminfo" = "no" && "with_ncurses" = "no" + extra_objs="$extra_objs tparam.o" + if test -n "$libs_termcap"; then LIBS="$LIBS $libs_termcap" + elif test "$have_libtermcap" = "yes"; then LIBS="$LIBS -ltermcap" + elif test "$have_libcurses" = "yes"; then LIBS="$LIBS -lcurses" + else extra_objs="$extra_objs termcap.o" + fi + fi fi + AC_DEFINE_UNQUOTED(CURSES_H_PATH, "${curses_h_path-curses.h}") + AC_DEFINE_UNQUOTED(TERM_H_PATH, "${term_h_path-term.h}") +else # "$with_tty" = "no" + for feature in ncurses gpm; do + if eval "test -n \"\$with_${feature}\" -a \"\$with_${feature}\" != no" ; then + AC_MSG_WARN("--with-${feature} ignored: Not valid without TTY support") + fi + eval "with_${feature}=no" + done fi -dnl Check for database support. - -dnl <mdiers@logware.de> -dnl We don't necessarily have to have libdb/lib(g)dbm for DB/(G)DBM support. +dnl Database support +dnl <mdiers@logware.de> +dnl We do not necessarily have to have libdb/lib(g)dbm for DB/(G)DBM support. dnl On FreeBSD, both DB and DBM are part of libc. dnl Note that unless support for DB/(G)DBM is explicitly disabled, we always -dnl want to check for libdb/lib(g)dbm. Also note that libc will not be +dnl want to check for libdb/lib(g)dbm. Also note that libc will not be dnl checked if we have the libraries. dnl If support for DB/(G)DBM is requested, but we neither have libdb/lib(g)dbm, dnl nor does libc implement it, we are a bit lost :) -if test "${with_database_berkdb}" != "no" ; then - AC_HAVE_LIBRARY(-ldb, have_libdb=yes, have_libdb=no) - IF_YES_AC_DEFINE(have_libdb, HAVE_LIBDB) - if test "${with_database_berkdb}" != "yes" ; then - if test "${have_libdb}" = "yes" ; then - with_database_berkdb=yes - else - AC_FUNC_CHECK(dbopen, with_database_berkdb=yes, with_database_berkdb=no) +AC_CHECKING(for database support) + +if test "$with_database_gnudbm" != "no" ; then + AC_CHECK_LIB(gdbm, dbm_open, with_database_gnudbm=yes have_libgdbm=yes) + if test "$with_database_gnudbm" != "yes"; then + AC_CHECK_FUNC(dbm_open, with_database_gnudbm=yes) + fi + if test "$with_database_gnudbm" = "yes" ; then + AC_DEFINE(HAVE_DBM) + test "$have_libgdbm" = "yes" && LIBS="$LIBS -lgdbm" + with_database_dbm=no + else with_database_gnudbm=no + fi +fi + +if test "$with_database_dbm" != "no" ; then + AC_CHECK_FUNC(dbm_open, with_database_dbm=yes need_libdbm=no) + if test "$need_libdbm" != "no"; then + AC_CHECK_LIB(dbm, dbm_open, with_database_dbm=yes need_libdbm=yes) + fi + if test "$with_database_dbm" = "yes" ; then + AC_DEFINE(HAVE_DBM) + test "$need_libdbm" = "yes" && LIBS="$LIBS -ldbm" + else with_database_dbm=no + fi +fi + +if test "$with_database_berkdb" != "no"; then + AC_CHECK_FUNC(dbopen, with_database_berkdb=yes need_libdb=no) + if test "$need_libdb" != "no"; then + AC_CHECK_LIB(db, dbopen, with_database_berkdb=yes need_libdb=yes) fi + if test "$with_database_berkdb" = "yes"; then + for path in "db/db.h" "db.h"; do +AC_TRY_COMPILE([#ifdef HAVE_INTTYPES_H +#define __BIT_TYPES_DEFINED__ +#include <inttypes.h> +typedef uint8_t u_int8_t; +typedef uint16_t u_int16_t; +typedef uint32_t u_int32_t; +#ifdef WE_DONT_NEED_QUADS +typedef uint64_t u_int64_t; +#endif +#endif +#include <$path> +],[], db_h_path="$path"; break) + done + test -z "$db_h_path" && with_database_berkdb=no + fi + if test "$with_database_berkdb" = "yes"; then + AC_DEFINE_UNQUOTED(DB_H_PATH, "$db_h_path") + AC_DEFINE(HAVE_BERKELEY_DB) + test "$need_libdb" = "yes" && LIBS="$LIBS -ldb" + else with_database_berkdb=no fi fi -IF_YES_AC_DEFINE(with_database_berkdb, HAVE_BERKELEY_DB) - -if test "${with_database_gnudbm}" != "no" ; then - AC_HAVE_LIBRARY(-lgdbm, have_libgdbm=yes, have_libgdbm=no) - IF_YES_AC_DEFINE(have_libgdbm, HAVE_LIBGDBM) - test -z "${with_database_gnudbm}" && with_database_gnudbm="${have_libgdbm}" + +if test "$with_database_gnudbm" = "yes" -o \ + "$with_database_dbm" = "yes" -o \ + "$with_database_berkdb" = "yes"; then + AC_DEFINE(HAVE_DATABASE) + extra_objs="$extra_objs database.o" +fi + +dnl Socks support +if test "$with_socks" = "yes"; then + AC_CHECK_LIB(socks, SOCKSinit) + test -n "$ac_cv_lib_socks_SOCKSinit" && AC_DEFINE(HAVE_SOCKS) +fi + +dnl Usage tracking (undocumented and likely unused option) +if test "$usage_tracking" = "yes"; then + AC_DEFINE(USAGE_TRACKING) + LIBS="$LIBS -Bstatic -lut -Bdynamic" fi -if test "${with_database_gnudbm}" = "yes" ; then - AC_DEFINE(HAVE_DBM) - AC_DEFINE(HAVE_GNU_DBM) - with_database_dbm=no + +dnl ------------------------------------- +dnl Compute runtime library path +dnl ------------------------------------- + +if test "$dynamic" = "no"; then add_runtime_path=no +elif test -n "$LD_RUN_PATH"; then add_runtime_path=yes +else case "$canonical" in + *-solaris2.* | *-sgi-irix* ) add_runtime_path=yes ;; + * ) add_runtime_path=no ;; + esac fi -if test "${with_database_dbm}" != "no" ; then - AC_HAVE_LIBRARY(-ldbm, have_libdbm=yes, have_libdbm=no) - IF_YES_AC_DEFINE(have_libdbm, HAVE_LIBDBM) - if test "${with_database_dbm}" != "yes" ; then - if test "${have_libdbm}" = "yes" ; then - with_database_dbm=yes - else - AC_FUNC_CHECK(dbm_open, with_database_dbm=yes, with_database_dbm=no) - fi +if test "$add_runtime_path" = "yes"; then + dnl Try to autodetect runtime library flag (usually -R), + dnl and whether it works (or at least does no harm) + AC_MSG_CHECKING("for runtime libraries flag") + dash_r="" + for try_dash_r in "-R" "-R " "-rpath "; do + xe_check_libs="${try_dash_r}/no/such/file-or-directory" + AC_TRY_LINK(, , dash_r="$try_dash_r") + xe_check_libs="" + test -n "$dash_r" && break + done + if test -n "$dash_r"; + then AC_MSG_RESULT("\"${dash_r}\"") + else AC_MSG_RESULT(NONE) fi fi -IF_YES_AC_DEFINE(with_database_dbm, HAVE_DBM) - - -############################################################################ -# # -# Substitute into Makefile and config.h # -# # -############################################################################ - -dnl what sort of things we'll be editing into Makefile and config.h. + +if test "$add_runtime_path" = "yes" -a -n "$dash_r"; then + dnl Remove runtime paths from current ld switches + ld_switch_site="`echo $ld_switch_site | sed \"s/${dash_r}[[^ ]]*//\"`" + ld_switch_x_site="`echo $ld_switch_x_site | sed \"s/${dash_r}[[^ ]]*//\"`" + dnl PRINT_VAR(ld_switch_site, ld_switch_x_site) + + dnl Fix up Runtime path + dnl If LD_RUN_PATH is set in environment, use that. + dnl In this case, assume user has set the right value. + if test -n "$LD_RUN_PATH"; then + runpath="$LD_RUN_PATH" + else + dnl Add all directories with .so files to runpath + runpath="" + for arg in $ld_switch_site $ld_switch_x_site; do + case "$arg" in -L* ) + dir=`echo $arg | sed 's/^-L//'` + if test -n "`ls ${dir}/*.so 2>/dev/null`"; then + test -n "$runpath" && runpath="${runpath}:" + runpath="${runpath}${dir}" + fi + ;; + esac + done + dnl Sometimes /opt/SUNWdt/lib is the only installed Motif available + case "$canonical" in *-solaris2.* ) + test "$have_motif" = "yes" && runpath="${runpath}:/opt/SUNWdt/lib" ;; + esac + fi + + if test -n "$runpath"; then + ld_switch_site="$ld_switch_site ${dash_r}${runpath}" + test "$extra_verbose" = "yes" && echo "Setting runpath to $runpath" + fi +fi + +dnl -------------------------------- +dnl Compute SUBST-itutable variables +dnl -------------------------------- +dnl We ignore (C|LD)_SWITCH_X_(MACHINE|SYSTEM) +c_switch_general="-DHAVE_CONFIG_H $c_switch_site $c_switch_machine $c_switch_system" +c_switch_window_system="$c_switch_x_site $X_CFLAGS" +c_switch_all="$c_switch_general $c_switch_window_system" +ld_switch_general="$ld_switch_site $ld_switch_machine $ld_switch_system" +ld_switch_window_system="$ld_switch_x_site" +ld_switch_all="$ld_switch_general $ld_switch_window_system" +ld_libs_general="$LIBS $libs_machine $libs_system $libs_standard" +ld_libs_window_system="$X_PRE_LIBS $libs_x $X_EXTRA_LIBS" +ld_libs_all="$ld_libs_window_system $ld_libs_general" + +dnl Compute lists of Makefiles +internal_makefile_list="Makefile" +SUBDIR_MAKEFILES='' +for dir in $MAKE_SUBDIR; do + SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $dir/Makefile" + internal_makefile_list="$internal_makefile_list $dir/Makefile.in" +done +AC_SUBST(MAKE_SUBDIR) +AC_SUBST(SUBDIR_MAKEFILES) + +if test "$extra_verbose" = "yes"; then + echo "" + PRINT_VAR(extra_objs, + c_switch_general, c_switch_window_system, c_switch_all, + ld_switch_general, ld_switch_window_system, ld_switch_all, + ld_libs_general, ld_libs_window_system, ld_libs_all) + echo "" +fi + +dnl ------------------------------------- +dnl Substitute into Makefile and config.h +dnl ------------------------------------- + +dnl what sort of things to edit into Makefile and config.h. dnl configuration here uncanonicalized to avoid exceeding size limits. AC_SUBST(version) @@ -3081,31 +2873,48 @@ AC_SUBST(archlibdir_user_defined) AC_SUBST(docdir) AC_SUBST(bitmapdir) -AC_SUBST(c_switch_system) -AC_SUBST(c_switch_machine) -AC_SUBST(libsrc_libs) -AC_SUBST(LD_SWITCH_X_SITE) -AC_SUBST(LD_SWITCH_X_SITE_AUX) -AC_SUBST(C_SWITCH_X_SITE) -AC_SUBST(LD_SWITCH_SITE) -AC_SUBST(C_SWITCH_SITE) -AC_SUBST(CFLAGS) -AC_SUBST(native_sound_lib) +AC_SUBST(extra_objs) + +dnl The following flags combine all the information from: +dnl - command line options (user always gets priority) +dnl - user environment variables +dnl - determined by configure +dnl - the s&m header files (deprecated) AC_SUBST(machfile) AC_SUBST(opsysfile) +AC_SUBST(c_switch_general) +AC_SUBST(c_switch_window_system) +AC_SUBST(c_switch_all) +AC_SUBST(ld_switch_general) +AC_SUBST(ld_switch_window_system) +AC_SUBST(ld_switch_all) +AC_SUBST(ld_libs_general) +AC_SUBST(ld_libs_window_system) +AC_SUBST(ld_libs_all) +AC_SUBST(libsrc_libs) +AC_SUBST(CFLAGS) +AC_SUBST(CPPFLAGS) +AC_SUBST(LDFLAGS) + +AC_SUBST(native_sound_lib) +AC_SUBST(sound_cflags) AC_SUBST(RANLIB) AC_SUBST(dynodump_arch) -AC_DEFINE_UNQUOTED(EMACS_VERSION, "${version}") -AC_DEFINE_UNQUOTED(EMACS_CONFIGURATION, "\"${canonical}\"") -AC_DEFINE_UNQUOTED(config_machfile, "\"${machfile}\"") -AC_DEFINE_UNQUOTED(config_opsysfile, "\"${opsysfile}\"") -AC_DEFINE_UNQUOTED(LD_SWITCH_X_SITE, ${LD_SWITCH_X_SITE}) -AC_DEFINE_UNQUOTED(LD_SWITCH_X_SITE_AUX, ${LD_SWITCH_X_SITE_AUX}) -AC_DEFINE_UNQUOTED(C_SWITCH_X_SITE, ${C_SWITCH_X_SITE}) -AC_DEFINE_UNQUOTED(LD_SWITCH_SITE, ${LD_SWITCH_SITE}) -AC_DEFINE_UNQUOTED(C_SWITCH_SITE, ${C_SWITCH_SITE}) -AC_DEFINE_UNQUOTED(UNEXEC_SRC, ${UNEXEC_SRC}) +AC_DEFINE_UNQUOTED(EMACS_VERSION, $version) +AC_DEFINE_UNQUOTED(EMACS_CONFIGURATION, "$canonical") +AC_DEFINE_UNQUOTED(config_machfile, "$machfile") +AC_DEFINE_UNQUOTED(config_opsysfile, "$opsysfile") +AC_DEFINE_UNQUOTED(UNEXEC_SRC, $UNEXEC_SRC) + +dnl Following are deprecated + +null_string="" +AC_DEFINE_UNQUOTED(LD_SWITCH_X_SITE, $null_string) +AC_DEFINE_UNQUOTED(LD_SWITCH_X_SITE_AUX, $null_string) +AC_DEFINE_UNQUOTED(C_SWITCH_X_SITE, $null_string) +AC_DEFINE_UNQUOTED(LD_SWITCH_SITE, $null_string) +AC_DEFINE_UNQUOTED(C_SWITCH_SITE, $null_string) dnl Note: as a general rule, *only* define things here that are not dnl autodetected. For things that are autodetected, define them @@ -3113,136 +2922,106 @@ dnl so that the user gets immediate feedback on the results of the dnl autodetection. -test -n "${puresize}" && AC_DEFINE_UNQUOTED(RAW_PURESIZE, ${puresize}) -IF_YES_AC_DEFINE(HAVE_X_WINDOWS,HAVE_X_WINDOWS) -IF_YES_AC_DEFINE(HAVE_XFREE386, HAVE_XFREE386) - -if test "${GNU_MALLOC}" = yes; then AC_DEFINE(GNU_MALLOC) -elif test "${use_system_malloc}" = yes; then AC_DEFINE(USE_SYSTEM_MALLOC) +test -n "$puresize" && AC_DEFINE_UNQUOTED(RAW_PURESIZE, $puresize) + +if test "$GNU_MALLOC" = "yes"; then AC_DEFINE(GNU_MALLOC) +elif test "$use_system_malloc" = "yes"; then AC_DEFINE(USE_SYSTEM_MALLOC) fi -IF_YES_AC_DEFINE(rel_alloc, REL_ALLOC) -IF_YES_AC_DEFINE(LISP_FLOAT_TYPE, LISP_FLOAT_TYPE) -IF_YES_AC_DEFINE(with_motif, LWLIB_USES_MOTIF) -IF_YES_AC_DEFINE(with_athena, LWLIB_USES_ATHENA) -IF_YES_AC_DEFINE(with_toolbars, HAVE_TOOLBARS) -IF_YES_AC_DEFINE(with_tty, HAVE_TTY) -IF_YES_AC_DEFINE(with_tooltalk, TOOLTALK) -IF_YES_AC_DEFINE(with_i18n3, I18N3) -IF_YES_AC_DEFINE(with_mule, MULE) -IF_YES_AC_DEFINE(with_canna, HAVE_CANNA) -IF_YES_AC_DEFINE(with_wnn, HAVE_WNN) -IF_YES_AC_DEFINE(with_wnn6, WNN6) -IF_YES_AC_DEFINE(with_mock, MOCKLISP_SUPPORT) -IF_YES_AC_DEFINE(with_sparcworks,SUNPRO) -IF_YES_AC_DEFINE(usage_tracking, USAGE_TRACKING) -IF_YES_AC_DEFINE(need_dynodump, DYNODUMP) -IF_YES_AC_DEFINE(need_xildoff, NEED_XILDOFF) -IF_YES_AC_DEFINE(with_gcc, USE_GCC) -IF_YES_AC_DEFINE(with_lcc, USE_LCC) -IF_YES_AC_DEFINE(with_socks, HAVE_SOCKS) -IF_YES_AC_DEFINE(with_term, HAVE_TERM) -IF_YES_AC_DEFINE(external_widget,EXTERNAL_WIDGET) -IF_YES_AC_DEFINE(with_gnu_make, USE_GNU_MAKE) -IF_YES_AC_DEFINE(no_doc_file, NO_DOC_FILE) -IF_YES_AC_DEFINE(const_is_losing,CONST_IS_LOSING) -IF_YES_AC_DEFINE(use_assertions, USE_ASSERTIONS) -IF_YES_AC_DEFINE(debug, DEBUG_XEMACS) -IF_YES_AC_DEFINE(quantify, QUANTIFY) -IF_YES_AC_DEFINE(memory_usage_stats, MEMORY_USAGE_STATS) -IF_YES_AC_DEFINE(with_pop, MAIL_USE_POP) -IF_YES_AC_DEFINE(with_kerberos, KERBEROS) -IF_YES_AC_DEFINE(with_hesiod, HESIOD) - -IF_YES_AC_DEFINE(error_check_extents, ERROR_CHECK_EXTENTS) -IF_YES_AC_DEFINE(error_check_typecheck, ERROR_CHECK_TYPECHECK) -IF_YES_AC_DEFINE(error_check_bufpos, ERROR_CHECK_BUFPOS) -IF_YES_AC_DEFINE(error_check_gc, ERROR_CHECK_GC) -IF_YES_AC_DEFINE(error_check_malloc, ERROR_CHECK_MALLOC) - -if test "${with_energize}" = yes; then - AC_DEFINE(ENERGIZE) - test "${energize_version}" = "2.X" && AC_DEFINE(ENERGIZE_2) - test "${energize_version}" = "3.X" && AC_DEFINE(ENERGIZE_3) -fi - -test "${with_sound}" = "native" -o "${with_sound}" = "both" && AC_DEFINE(HAVE_NATIVE_SOUND) -test "${with_sound}" = "nas" -o "${with_sound}" = "both" && AC_DEFINE(HAVE_NAS_SOUND) -test "${old_nas}" = "true" && AC_DEFINE(NAS_NO_ERROR_JUMP) - -test "${use_union_type}" != yes && AC_DEFINE(NO_UNION_TYPE) - -dnl ############################################################################ -dnl # Report on what we decided to do # -dnl ############################################################################ +test "$with_motif" = "yes" && AC_DEFINE(LWLIB_USES_MOTIF) +test "$with_i18n3" = "yes" && AC_DEFINE(I18N3) +test "$with_mocklisp" = "yes" && AC_DEFINE(MOCKLISP_SUPPORT) +test "$with_gcc" = "yes" && AC_DEFINE(USE_GCC) +test "$with_term" = "yes" && AC_DEFINE(HAVE_TERM) +test "$external_widget" = "yes" && AC_DEFINE(EXTERNAL_WIDGET) +test "$with_gnu_make" = "yes" && AC_DEFINE(USE_GNU_MAKE) +test "$no_doc_file" = "yes" && AC_DEFINE(NO_DOC_FILE) +test "$const_is_losing" = "yes" && AC_DEFINE(CONST_IS_LOSING) +test "$use_assertions" = "yes" && AC_DEFINE(USE_ASSERTIONS) +test "$debug" = "yes" && AC_DEFINE(DEBUG_XEMACS) +test "$with_quantify" = "yes" && AC_DEFINE(QUANTIFY) +test "$memory_usage_stats" = "yes" && AC_DEFINE(MEMORY_USAGE_STATS) +test "$with_pop" = "yes" && AC_DEFINE(MAIL_USE_POP) +test "$with_kerberos" = "yes" && AC_DEFINE(KERBEROS) +test "$with_hesiod" = "yes" && AC_DEFINE(HESIOD) + +test "$error_check_extents" = "yes" && AC_DEFINE(ERROR_CHECK_EXTENTS) +test "$error_check_typecheck" = "yes" && AC_DEFINE(ERROR_CHECK_TYPECHECK) +test "$error_check_bufpos" = "yes" && AC_DEFINE(ERROR_CHECK_BUFPOS) +test "$error_check_gc" = "yes" && AC_DEFINE(ERROR_CHECK_GC) +test "$error_check_malloc" = "yes" && AC_DEFINE(ERROR_CHECK_MALLOC) + +test "$use_union_type" != yes && AC_DEFINE(NO_UNION_TYPE) + +dnl ------------------------------- +dnl Report on what we decided to do +dnl ------------------------------- ( -if test -f /etc/osversion; then - # SONY NEWS-OS - echo "osversion: `cat /etc/osversion`" -eles - echo "uname -a: `uname -a`" +dnl /etc/osversion is on SONY NEWS-OS +if test -f /etc/osversion; then dnl SONY NEWS-OS + echo "osversion: `cat /etc/osversion`" +else + echo "uname -a: `uname -a`" fi -echo "" -echo "$0 $quoted_arguments" +echo "" +echo "$0 $quoted_arguments" ) >> Installation -# Start stdout redirection to '| tee -a Installation' + +dnl Start stdout redirection to '| tee -a Installation' ( echo " -Configured for \`${canonical}'. - - Where should the build process find the source code? ${srcdir} - What installation prefix should install use? ${prefix} +Configured for \`$canonical'. + + Where should the build process find the source code? $srcdir + What installation prefix should install use? $prefix What operating system and machine description files should XEmacs use? - \`${opsysfile}' and \`${machfile}' - What compiler should XEmacs be built with? ${CC} ${CFLAGS} + \`$opsysfile' and \`$machfile' + What compiler should XEmacs be built with? $CC $CFLAGS Should XEmacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason} - Should XEmacs use the relocating allocator for buffers? ${rel_alloc} - What window system should XEmacs use? ${window_system}${x_includes+ - Where do we find X Windows header files? }${x_includes}${x_libraries+ - Where do we find X Windows libraries? }${x_libraries}" - -if test -n "$site_includes"; then - echo " Additional header files: ${site_includes}" + Should XEmacs use the relocating allocator for buffers? $rel_alloc + What window system should XEmacs use? ${window_system}" +if test "$with_x11" = "yes"; then + echo " Where do we find X Windows header files? $x_includes" + echo " Where do we find X Windows libraries? $x_libraries" fi - -if test -n "$site_libraries" -a -n "$site_runtime_libraries"; then - echo " Additional libraries: ${site_libraries} ${site_runtime_libraries}" -elif test -n "$site_libraries"; then - echo " Additional libraries: ${site_libraries}" -elif test -n "$site_runtime_libraries"; then - echo " Additional libraries: ${site_runtime_libraries}" +if test -n "$site_includes"; then + echo " Additional header files: $site_includes" +fi +if test -n "$site_libraries"; then + echo " Additional libraries: $site_libraries" +fi +if test -n "$runpath"; then + echo " Runtime library search path: $runpath" fi test "$with_dnet" = yes && echo " Compiling in support for DNET." test "$with_socks" = yes && echo " Compiling in support for SOCKS." test "$with_term" = yes && echo " Compiling in support for TERM." test "$with_xauth" = yes && echo " Compiling in support for XAUTH." -test "$with_xpm" = yes && echo " Compiling in support for XPM." -if test "$with_xmu" != yes -a "$window_system" != none; then +if test "$with_xmu" != yes -a "$with_x11" = yes; then echo " No Xmu; substituting equivalent routines." fi -test "$with_xface" = yes && echo " Compiling in support for X-Face headers." + test "$with_gif" = yes && echo " Compiling in support for GIF image conversion." +test "$with_xpm" = yes && echo " Compiling in support for XPM images." +test "$with_xface" = yes && echo " Compiling in support for X-Face message headers." test "$with_jpeg" = yes && echo " Compiling in support for JPEG image conversion." -if test "$with_png" = yes -o "$with_png" = gnuz; then - echo " Compiling in support for PNG image conversion." -fi -if test "$with_png" = gnuz; then - echo " (Using -lgz instead of -lz.)" -fi +test "$with_png" = yes && echo " Compiling in support for PNG image conversion." test "$with_tiff" = yes && echo " Compiling in support for TIFF image conversion (not implemented)." -test "$with_sound" = nas && echo " Compiling in network sound support." -test "$with_sound" = native && echo " Compiling in native sound support." -test "$with_sound" = both && echo " Compiling in both network and native sound support." -test "$old_nas" = true && echo " nas library lacks error trapping, will play synchronously" +case "$with_sound" in + nas ) echo " Compiling in network sound (NAS) support." ;; + native ) echo " Compiling in native sound support." ;; + both ) echo " Compiling in both network and native sound support." ;; +esac +test "$old_nas" = yes && echo " nas library lacks error trapping, will play synchronously" test "$with_database_berkdb" = yes && echo " Compiling in support for Berkeley DB." test "$with_database_dbm" = yes && echo " Compiling in support for DBM." test "$with_database_gnudbm" = yes && echo " Compiling in support for GNU DBM." -test "$have_ncurses" = yes && echo " Compiling in support for ncurses." -test "$with_socks" = yes && echo " Compiling in support for SOCKS." +test "$with_ncurses" = yes && echo " Compiling in support for ncurses." +test "$with_gpm" = yes && echo " Compiling in support for GPM (General Purpose Mouse)." test "$with_mule" = yes && echo " Compiling in Mule (multi-lingual) support." test "$with_xim" != no && echo " Compiling in XIM (X11R5+ I18N input method) support." @@ -3252,8 +3031,6 @@ if test "$with_wnn" = yes; then echo " Compiling in support for the WNN input method on Mule." test "$with_wnn6" = yes && echo " WNN support for version 6." - echo " Finding WNN includes with: ${wnn_includes}" - echo " Finding WNN libs with: ${wnn_libraries}" fi test "$with_i18n3" = yes && echo " Compiling in I18N support, level 3 (doesn't currently work)." @@ -3261,215 +3038,93 @@ test "$with_tooltalk" = yes && echo " Compiling in support for ToolTalk." test "$with_offix" = yes && echo " Compiling in support for OffiX." test "$with_mocklisp" = yes && echo " Compiling in support for Mocklisp." -test "$with_sparcworks" = yes && echo " Compiling in support for SparcWorks." +test "$with_workshop" = yes && echo " Compiling in support for Sun WorkShop." test "$with_energize" = yes && echo " Compiling in support for Lucid Energize (doesn't currently work)." -test "$with_menubars" = "lucid" && echo " Using the Lucid menubar." -if test "$with_menubars" = "motif"; then - echo " Using the Motif menubar." - echo " *WARNING* The Motif menubar is currently buggy. We recommend" - echo " that you use the Lucid menubar instead. Re-run" - echo " configure with --with-menubars='lucid'." -fi -test "$with_scrollbars" = lucid && echo " Using the Lucid scrollbar." -test "$with_scrollbars" = motif && echo " Using the Motif scrollbar." -test "$with_scrollbars" = athena && echo " Using the Athena scrollbar." -test "$with_scrollbars" = athena3d && echo " Using the Athena-3d scrollbar." -test "$with_dialogs" = motif && echo " Using the Motif dialog boxes." -test "$with_dialogs" = athena && echo " Using the Athena dialog boxes." -test "$with_dialogs" = athena3d && echo " Using the Athena-3d dialog boxes." +case "$with_menubars" in + lucid ) echo " Using the Lucid menubar." ;; + motif ) echo " Using the Motif menubar." + echo " *WARNING* The Motif menubar is currently buggy." + echo " We recommend using the Lucid menubar instead." + echo " Re-run configure with --with-menubars='lucid'." ;; +esac +case "$with_scrollbars" in + lucid ) echo " Using the Lucid scrollbar." ;; + motif ) echo " Using the Motif scrollbar." ;; + athena ) echo " Using the Athena scrollbar." ;; + athena3d ) echo " Using the Athena-3d scrollbar." ;; +esac +case "$with_dialogs" in + motif ) echo " Using the Motif dialog boxes." ;; + athena ) echo " Using the Athena dialog boxes." ;; + athena3d ) echo " Using the Athena-3d dialog boxes." ;; +esac 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 "${memory_usage_stats}" = yes && echo " Compiling in code for checking XEmacs memory usage." -test "$usage_tracking" = yes && echo " Compiling with usage tracking active (Sun internal)." +test "$use_union_type" = yes && echo " Using the union type for Lisp_Objects." +test "$debug" = yes && echo " Compiling in extra code for debugging." +test "$memory_usage_stats" = yes && echo " Compiling in code for checking XEmacs memory usage." +test "$usage_tracking" = yes && echo " Compiling with usage tracking active (Sun internal)." echo "" ) | tee -a Installation echo 'The above configure report is appended to "Installation" file.' echo "" -dnl ############################################################################ -dnl # Now generate! # -dnl ############################################################################ +dnl ----------------------------------- +dnl Now generate config.h and Makefiles +dnl ----------------------------------- dnl This has to be called in order for this variable to get into config.status AC_SUBST(internal_makefile_list) # Remove any trailing slashes in these variables. -test -n "${prefix}" && - prefix=`echo "${prefix}" | sed 's,\([[^/]]\)/*$,\1,'` -test -n "${exec_prefix}" && - exec_prefix=`echo "${exec_prefix}" | sed 's,\([[^/]]\)/*$,\1,'` - -AC_OUTPUT($internal_makefile_list) -# Build: -# src/Makefile from ${srcdir}/src/Makefile.in -# lwlib/Makefile from ${srcdir}/lwlib/Makefile.in -# lib-src/Makefile from ${srcdir}/lib-src/Makefile.in -# dynodump/Makefile from ${srcdir}/dynodump/Makefile.in -# and possibly -# lwlib/energize/Makefile from ${srcdir}/lwlib/energize/Makefile.in. -# This must be done after src/config.h is built, since we rely on that -# file. Only do the build if "config.status" is present, since its -# non-presence indicates an error occured. -status=$? -if test ! -f ./config.status ; then - exit $status -fi -topsrcdir=${srcdir} - # We discard all lines in Makefile.in that start with `# Generated' or /**/# - # because some cpps get confused by them. - # Really we should preserve them somehow into Makefile, - # but that is beyond my level of shell programming. -makefile_command='echo "creating src/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./src; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[[ \f\t]][[ \f\t]]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $makefile_command` -lwlib_makefile_command='echo "creating lwlib/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./lwlib; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[[ \f\t]][[ \f\t]]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $lwlib_makefile_command` -lib_src_makefile_command='echo "creating lib-src/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./lib-src; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[[ \f\t]][[ \f\t]]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $lib_src_makefile_command` - -# Mule utilitity programs - currently disabled -if test "${with_mule_util}" = "yes"; then -lib_src_mule_makefile_command='echo "creating lib-src/mule/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./lib-src/mule; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[[ \f\t]][[ \f\t]]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $lib_src_mule_makefile_command` -fi # Mule - -dynodump_makefile_command='echo "creating dynodump/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./dynodump; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[[ \f\t]][[ \f\t]]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $dynodump_makefile_command` -if test "${with_energize}" = "yes" ; then -energize_makefile_command='echo "creating lwlib/energize/Makefile"; - topsrcdir='"${topsrcdir}"'; -( cd ./lwlib/energize; - rm -f junk.c; - sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c; - eval `echo ${CPP} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`; - < junk.cpp '\ -' sed -e '\''s/^#.*//'\'' '\ -' -e '\''s/^[[ \f\t]][[ \f\t]]*$//'\'' '\ -' -e '\''s/^ / /'\'' '\ -' | sed -n -e '\''/^..*$/p'\'' '\ -' > Makefile.new; - chmod 444 Makefile.new; - mv -f Makefile.new Makefile; - rm -f junk.c junk.cpp; -)' -eval `echo $energize_makefile_command` -fi -# AC-OUTPUT has created `config.status' already. We need to add the -# above commands to re-create `src/Makefile', `lwlib/Makefile', -# `lib-src/Makefile', `dynodump/Makefile', and possibly -# `lwlib/energize/Makefile', and we need to insert them before the final -# "exit 0" which appears at the end of `config.status'. -<config.status sed -e 's/^exit 0$//' >config.new -echo $makefile_command >>config.new -echo $lwlib_makefile_command >>config.new -echo $lib_src_makefile_command >>config.new -if test "${with_mule_util}" = "yes"; then - echo $lib_src_mule_makefile_command >>config.new -fi -echo $dynodump_makefile_command >>config.new -echo $man_makefile_command >>config.new -if test "${with_energize}" = "yes" ; then - echo $energize_makefile_command >>config.new -fi -echo exit 0 >>config.new -mv -f config.new config.status -chmod +x config.status -# Don't let the fact that we just rewrote config.status make Makefile think -# that it is now newer. We have just rewritten all of the Makefiles as well. -MFS="Makefile \ - src/Makefile src/Makefile.in \ - lib-src/Makefile lib-src/Makefile.in \ - dynodump/Makefile dynodump/Makefile.in \ - lwlib/Makefile lwlib/Makefile.in" -chmod a+w $MFS -touch $MFS -chmod 444 $MFS +test -n "$prefix" && + prefix=`echo "$prefix" | sed 's,\([[^/]]\)/*$,\1,'` +test -n "$exec_prefix" && + exec_prefix=`echo "$exec_prefix" | sed 's,\([[^/]]\)/*$,\1,'` + +dnl Build Makefile.in's from Makefile.in.in's +dnl except ./Makefile from $srcdir/Makefile.in + +AC_OUTPUT($internal_makefile_list,[ +for dir in $MAKE_SUBDIR; do + echo creating $dir/Makefile + ( set -e + cd $dir + rm -f junk.c + sed -e 's/^# Generated.*//' -e 's%/\*\*/#.*%%' < Makefile.in > junk.c; + $CPP -I. -I${top_srcdir}/src $CPPFLAGS junk.c > junk.cpp; + < junk.cpp \ + sed -e 's/^#.*//' \ + -e 's/^[[ \f\t]][[ \f\t]]*$//' \ + -e 's/^ / /' \ + | sed -n -e '/^..*$/p' \ + > Makefile.new + chmod 444 Makefile.new + mv -f Makefile.new Makefile + rm -f junk.c junk.cpp + ) + test "$?" != 0 && exit "$?" # For debugging +done +], +[CPP="$CPP" + CPPFLAGS="$CPPFLAGS" + top_srcdir="$srcdir" + MAKE_SUBDIR="$MAKE_SUBDIR" +]) if test ! -f src/gdbinit && test -f $topsrcdir/src/gdbinit; then - echo creating src/gdbinit - echo source $topsrcdir/src/gdbinit > src/gdbinit + echo "creating src/gdbinit" + echo "source $topsrcdir/src/gdbinit" > src/gdbinit fi -exit 0 - - -# Local Variables: -# eval: (modify-syntax-entry ?\" "\"") -# End: +if test "$sunpro_c" = "yes"; then dnl create useful .sbinit file + cat < EOF > .sbinit +# For use with Sun WorkShop's Source browser. +# See sbquery(1) and sbinit(4) for more information +import src +import lwlib +import lib-src +import dynodump +EOF +fi
--- a/etc/README Mon Aug 13 09:35:15 2007 +0200 +++ b/etc/README Mon Aug 13 09:36:16 2007 +0200 @@ -20,7 +20,7 @@ MH-E-NEWS List of changes to MH-E to version 5.0. MORE.STUFF List of useful unbundled packages MSDOS Status of MSDOS port -NEWS XEmacs 20.2 release information +NEWS XEmacs 20.3 release information ORDERS ORDERS.EUROPE ORDERS.JAPAN
--- a/etc/app-defaults/ja/Emacs Mon Aug 13 09:35:15 2007 +0200 +++ b/etc/app-defaults/ja/Emacs Mon Aug 13 09:36:16 2007 +0200 @@ -1,65 +1,66 @@ -!! Japanese localization resources for XEmacs. -!! @(#)Emacs 1.3 96/09/22 -!! Copyright (C) 1996 Sun Microsystems, Inc. +! Japanese localization resources for XEmacs. +! @(#)Emacs 1.3 96/09/22 +! Copyright (C) 1996 Sun Microsystems, Inc. !! -!! This file is part of XEmacs. -!! -!! XEmacs is free software; you can redistribute it and/or modify it -!! under the terms of the GNU General Public License as published by the -!! Free Software Foundation; either version 2, or (at your option) any -!! later version. -!! XEmacs is distributed in the hope that it will be useful, but WITHOUT -!! ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -!! FITNESS FOR A PARTICULAR PURPOSE. See the GNU 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 -!! Free Software Foundation, Inc., 59 Temple Place - Suite 330, -!! Boston, MA 02111-1307, USA. -!! Copyright (C) 1996 Sun Microsystems Inc. -!! Japanese Resources to be placed in etc/app-defaults/ja/Emacs -!! for xemacs-mule. -!! pulldown menu internationalization. The first line of the file -!! "Emacs*XlwMenu.resourceLabels: True" has to be there to make sure -!! all the labelString will be read and displayed by X. +! This file is part of XEmacs. +! +! XEmacs is free software; you can redistribute it and/or modify it +! under the terms of the GNU General Public License as published by the +! Free Software Foundation; either version 2, or (at your option) any +! later version. +! XEmacs is distributed in the hope that it will be useful, but WITHOUT +! ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +! FITNESS FOR A PARTICULAR PURPOSE. See the GNU 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 +! Free Software Foundation, Inc., 59 Temple Place - Suite 330, +! Boston, MA 02111-1307, USA. +! Copyright (C) 1996 Sun Microsystems Inc. +! Japanese Resources to be placed in etc/app-defaults/ja/Emacs +! for xemacs-mule. +! pulldown menu internationalization. The first line of the file +! "Emacs*XlwMenu.resourceLabels: True" has to be there to make sure +! all the labelString will be read and displayed by X. Emacs*XlwMenu.resourceLabels: True -!! Starting below here are menu label string which can be translated to -!! different languages. -!! Example: Emacs*XlwMenu.file.labelString: File -!! Characters before the ":" sign, "Example: Emacs*XlwMenu.file.labelString" -!! can not be changed. They must stay exactly the way they are. -!! The only string to be translated is the string, "File". -!! Some resource names such as "file", "quit" have been used in several -!! places. However, each of them only has to be translated once in this X -!! resource file. -!! Fonts for the window frame and menus +! CDE doesn't require this but OpenWindows does. Emacs*fontList: \ -*-gothic-medium-r-normal--14-120-75-75-c-*-*-*: !! FontSet for the window frame and menus when you use USE_XFONTSET Emacs*fontSet: -*-fixed-medium-r-normal--14-* -!!!! Default Menubar Top Level +! Starting below here are menu label string which can be translated to +! different languages. +! Example: Emacs*XlwMenu.file.labelString: File +! Characters before the ":" sign, "Example: Emacs*XlwMenu.file.labelString" +! can not be changed. They must stay exactly the way they are. +! The only string to be translated is the string, "File". +! Some resource names such as "file", "quit" have been used in several +! places. However, each of them only has to be translated once in this X +! resource file. + +!!! Default Menubar Top Level ! Emacs*XlwMenu.file.labelString: File Emacs*XlwMenu.file.labelString: ¥Õ¥¡¥¤¥ë ! Emacs*XlwMenu.edit.labelString: Edit Emacs*XlwMenu.edit.labelString: ÊÔ½¸ ! Emacs*XlwMenu.apps.labelString: Apps -! Emacs*XlwMenu.apps.labelString: +Emacs*XlwMenu.apps.labelString: ¥¢¥×¥ê ! Emacs*XlwMenu.options.labelString: Options Emacs*XlwMenu.options.labelString: ¥ª¥×¥·¥ç¥ó ! Emacs*XlwMenu.buffers.labelString: Buffers -Emacs*XlwMenu.buffers.labelString: ¥Ð¥Ã¥Õ¥¡¡¼´Ö... +Emacs*XlwMenu.buffers.labelString: ¥Ð¥Ã¥Õ¥¡ ! Emacs*XlwMenu.tools.labelString: Tools Emacs*XlwMenu.tools.labelString: ¥Ä¡¼¥ë ! Emacs*XlwMenu.help.labelString: Help Emacs*XlwMenu.help.labelString: ¥Ø¥ë¥× ! Emacs*XlwMenu.load_emacs.labelString: Load .emacs -! Emacs*XlwMenu.load_emacs.labelString: +Emacs*XlwMenu.load_emacs.labelString: .emacs Æɤ߹þ¤ß -!!! File menu +!! File menu ! Emacs*XlwMenu.open___.labelString: Open... Emacs*XlwMenu.open___.labelString: ³«¤¯... @@ -72,19 +73,19 @@ ! Emacs*XlwMenu.viewFile___.labelString: View File... Emacs*XlwMenu.viewFile___.labelString: ¥Õ¥¡¥¤¥ëɽ¼¨... ! Emacs*XlwMenu.save.labelString: Save -Emacs*XlwMenu.save.labelString: Êݸ +Emacs*XlwMenu.save.labelString: Êݸ: ! Emacs*XlwMenu.saveAs___.labelString: Save As... Emacs*XlwMenu.saveAs___.labelString: ¿·µ¬Êݸ... ! Emacs*XlwMenu.saveSomeBuffers.labelString: Save Some Buffers -Emacs*XlwMenu.saveSomeBuffers.labelString: ¥Ð¥Ã¥Õ¥¡¡¼¤Î¤¤¤¯¤Ä¤«¤òÊݸ +Emacs*XlwMenu.saveSomeBuffers.labelString: ¥Ð¥Ã¥Õ¥¡¤ò¤¤¤¯¤Ä¤«Êݸ ! Emacs*XlwMenu.printBuffer.labelString: Print Buffer -Emacs*XlwMenu.printBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¡¼¤ò°õºþ +Emacs*XlwMenu.printBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¤ò°õºþ: ! Emacs*XlwMenu.prettyPrintBuffer.labelString: Pretty-Print Buffer -Emacs*XlwMenu.prettyPrintBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¡¼¤òÀ¶½ñ°õºþ +Emacs*XlwMenu.prettyPrintBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¤òÀ¶½ñ°õºþ: ! Emacs*XlwMenu.newFrame.labelString: New Frame Emacs*XlwMenu.newFrame.labelString: ¿·µ¬¥Õ¥ì¡¼¥à ! Emacs*XlwMenu.frameOnOtherDisplay___.labelString: Frame on Other Display... -Emacs*XlwMenu.frameOnOtherDisplay___.labelString: ¾¤Î¥Ç¥£¥¹¥×¥ì¡¼¤Ë¥Õ¥ì¡¼¥à +Emacs*XlwMenu.frameOnOtherDisplay___.labelString: ¾¤Î¥Ç¥£¥¹¥×¥ì¡¼¤Ë¥Õ¥ì¡¼¥à... ! Emacs*XlwMenu.deleteFrame.labelString: Delete Frame Emacs*XlwMenu.deleteFrame.labelString: ¥Õ¥ì¡¼¥àºï½ü ! Emacs*XlwMenu.splitWindow.labelString: Split Window @@ -94,13 +95,13 @@ ! Emacs*XlwMenu.unSplitKeepOthers.labelString: Un-Split (Keep Others) Emacs*XlwMenu.unSplitKeepOthers.labelString: ¥¦¥£¥ó¥É¥¦Ê¬³ä²ò½ü¡¢Â¾Êý¤òÊÝ»ý ! Emacs*XlwMenu.revertBuffer.labelString: Revert Buffer -Emacs*XlwMenu.revertBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¡¼Éü¸µ +Emacs*XlwMenu.revertBuffer.labelString: ¥Ð¥Ã¥Õ¥¡Éü¸µ: ! Emacs*XlwMenu.deleteBuffer.labelString: Delete Buffer -Emacs*XlwMenu.deleteBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¡¼ºï½ü +Emacs*XlwMenu.deleteBuffer.labelString: ¥Ð¥Ã¥Õ¥¡ºï½ü: ! Emacs*XlwMenu.exitXEmacs.labelString: Exit XEmacs Emacs*XlwMenu.exitXEmacs.labelString: XEmacs ½ªÎ» -!!! Edit menu +!! Edit menu ! Emacs*XlwMenu.undo.labelString: Undo Emacs*XlwMenu.undo.labelString: ¸µ¤ËÌ᤹ @@ -113,7 +114,7 @@ ! Emacs*XlwMenu.clear.labelString: Clear Emacs*XlwMenu.clear.labelString: ¾Ãµî ! Emacs*XlwMenu.search___.labelString: Search... -Emacs*XlwMenu.search___.labelString: ¸¡º÷ +Emacs*XlwMenu.search___.labelString: ¸¡º÷... ! Emacs*XlwMenu.searchBackward___.labelString: Search Backward... Emacs*XlwMenu.searchBackward___.labelString: ¸åÊý¸¡º÷... ! Emacs*XlwMenu.replace___.labelString: Replace... @@ -157,61 +158,61 @@ ! Emacs*XlwMenu.loadABookmarkFile.labelString: Load a bookmark file Emacs*XlwMenu.loadABookmarkFile.labelString: ¤·¤ª¤ê¥Õ¥¡¥¤¥ëÆɤ߹þ¤ß -!!! Apps menu +!! Apps menu ! Emacs*XlwMenu.readMailVM___.labelString: Read Mail (VM)... -! Emacs*XlwMenu.readMailVM___.labelString: +Emacs*XlwMenu.readMailVM___.labelString: ¥á¡¼¥ë¤òÆɤà (VM)... ! Emacs*XlwMenu.readMailMH___.labelString: Read Mail (MH)... -! Emacs*XlwMenu.readMailMH___.labelString: +Emacs*XlwMenu.readMailMH___.labelString: ¥á¡¼¥ë¤òÆɤà (MH)... ! Emacs*XlwMenu.sendMail___.labelString: Send mail... -! Emacs*XlwMenu.sendMail___.labelString: +Emacs*XlwMenu.sendMail___.labelString: ¥á¡¼¥ë¤òÁ÷¤ë... ! Emacs*XlwMenu.usenetNews.labelString: Usenet News -! Emacs*XlwMenu.usenetNews.labelString: +Emacs*XlwMenu.usenetNews.labelString: ¥Í¥Ã¥È¥Ë¥å¡¼¥¹ ! Emacs*XlwMenu.browseTheWeb.labelString: Browse the Web -! Emacs*XlwMenu.browseTheWeb.labelString: +Emacs*XlwMenu.browseTheWeb.labelString: WWW ¤ò¥Ö¥é¥¦¥º ! Emacs*XlwMenu.gopher.labelString: Gopher -! Emacs*XlwMenu.gopher.labelString: +Emacs*XlwMenu.gopher.labelString: Gopher ! Emacs*XlwMenu.hyperbole___.labelString: Hyperbole... -! Emacs*XlwMenu.hyperbole___.labelString: +Emacs*XlwMenu.hyperbole___.labelString: Hyperbole... ! Emacs*XlwMenu.spellCheckBuffer.labelString: Spell-Check Buffer -! Emacs*XlwMenu.spellCheckBuffer.labelString: +Emacs*XlwMenu.spellCheckBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¤ò¥¹¥Ú¥ë¥Á¥§¥Ã¥¯ ! Emacs*XlwMenu.emulateVI.labelString: Emulate VI -! Emacs*XlwMenu.emulateVI.labelString: +Emacs*XlwMenu.emulateVI.labelString: vi ¤òÌÏÊï ! Emacs*XlwMenu.calendar.labelString: Calendar -! Emacs*XlwMenu.calendar.labelString: +Emacs*XlwMenu.calendar.labelString: ¥«¥ì¥ó¥À¡¼ ! Emacs*XlwMenu.games.labelString: Games -! Emacs*XlwMenu.games.labelString: +Emacs*XlwMenu.games.labelString: ¥²¡¼¥à ! Emacs*XlwMenu.3MonthCalendar.labelString: 3-Month Calendar -! Emacs*XlwMenu.3MonthCalendar.labelString: +Emacs*XlwMenu.3MonthCalendar.labelString: 3 ¤«·î¥«¥ì¥ó¥À¡¼ ! Emacs*XlwMenu.diary.labelString: Diary -! Emacs*XlwMenu.diary.labelString: +Emacs*XlwMenu.diary.labelString: Æüµ ! Emacs*XlwMenu.holidays.labelString: Holidays -! Emacs*XlwMenu.holidays.labelString: +Emacs*XlwMenu.holidays.labelString: ½ËÆü ! Emacs*XlwMenu.phasesOfTheMoon.labelString: Phases of the Moon -! Emacs*XlwMenu.phasesOfTheMoon.labelString: +Emacs*XlwMenu.phasesOfTheMoon.labelString: ·îÎð ! Emacs*XlwMenu.sunriseSunset.labelString: Sunrise/Sunset -! Emacs*XlwMenu.sunriseSunset.labelString: +Emacs*XlwMenu.sunriseSunset.labelString: Æü¤Î½Ð¤ÈÆü¤ÎÆþ¤ê ! Emacs*XlwMenu.quoteFromZippy.labelString: Quote from Zippy -! Emacs*XlwMenu.quoteFromZippy.labelString: +Emacs*XlwMenu.quoteFromZippy.labelString: Zippy ¤Î³Ê¸À ! Emacs*XlwMenu.psychoanalyst.labelString: Psychoanalyst -! Emacs*XlwMenu.psychoanalyst.labelString: +Emacs*XlwMenu.psychoanalyst.labelString: Àº¿ÀʬÀÏ ! Emacs*XlwMenu.psychoanalyzeZippy.labelString: Psychoanalyze Zippy! -! Emacs*XlwMenu.psychoanalyzeZippy.labelString: +Emacs*XlwMenu.psychoanalyzeZippy.labelString: Zippy ¤òÀº¿ÀʬÀÏ! ! Emacs*XlwMenu.randomFlames.labelString: Random Flames -! Emacs*XlwMenu.randomFlames.labelString: +Emacs*XlwMenu.randomFlames.labelString: ÈðëîÃæ½ý ! Emacs*XlwMenu.dunnetAdventure.labelString: Dunnet (Adventure) -! Emacs*XlwMenu.dunnetAdventure.labelString: +Emacs*XlwMenu.dunnetAdventure.labelString: Dunnet (¥¢¥É¥Ù¥ó¥Á¥ã¡¼) ! Emacs*XlwMenu.towersOfHanoi.labelString: Towers of Hanoi -! Emacs*XlwMenu.towersOfHanoi.labelString: +Emacs*XlwMenu.towersOfHanoi.labelString: ¥Ï¥Î¥¤¤ÎÅã ! Emacs*XlwMenu.gameOfLife.labelString: Game of Life -! Emacs*XlwMenu.gameOfLife.labelString: +Emacs*XlwMenu.gameOfLife.labelString: ¥é¥¤¥Õ ! Emacs*XlwMenu.multiplicationPuzzle.labelString: Multiplication Puzzle -! Emacs*XlwMenu.multiplicationPuzzle.labelString: +Emacs*XlwMenu.multiplicationPuzzle.labelString: ³Ý¤±»»¥Ñ¥º¥ë -!!! Options menu +!! Options menu ! Emacs*XlwMenu.readOnly.labelString: Read Only -Emacs*XlwMenu.readOnly.labelString: Æɤ߹þ¤ßÀìÍÑ +Emacs*XlwMenu.readOnly.labelString: Æɤ߼è¤êÀìÍÑ ! Emacs*XlwMenu.editingOptions.labelString: Editing Options Emacs*XlwMenu.editingOptions.labelString: ÊÔ½¸¥ª¥×¥·¥ç¥ó ! Emacs*XlwMenu.generalOptions.labelString: General Options @@ -219,7 +220,7 @@ ! Emacs*XlwMenu.printingOptions.labelString: Printing Options Emacs*XlwMenu.printingOptions.labelString: °õºþ¥ª¥×¥·¥ç¥ó ! Emacs*XlwMenu.otherWindowLocation.labelString: "Other Window" Location -Emacs*XlwMenu.otherWindowLocation.labelString: ¡Ö¾¥¦¥£¥ó¥É¥¦¡×¤Îɽ¼¨°ÌÃÖ +Emacs*XlwMenu.otherWindowLocation.labelString: ¡Ö¾¥¦¥£¥ó¥É¥¦¡×ɽ¼¨°ÌÃÖ ! Emacs*XlwMenu.syntaxHighlighting.labelString: Syntax Highlighting Emacs*XlwMenu.syntaxHighlighting.labelString: ¹½Ê¸¶¯Ä´É½¼¨ ! Emacs*XlwMenu.parenHighlighting.labelString: Paren Highlighting @@ -245,7 +246,7 @@ ! Emacs*XlwMenu.saveOptions.labelString: Save Options Emacs*XlwMenu.saveOptions.labelString: ¥ª¥×¥·¥ç¥ó¤òÊݸ -!!! Options -> Editing +!! Options -> Editing ! Emacs*XlwMenu.overstrike.labelString: Overstrike Emacs*XlwMenu.overstrike.labelString: ¾å½ñ¤ @@ -256,11 +257,11 @@ ! Emacs*XlwMenu.autoDeleteSelection.labelString: Auto Delete Selection Emacs*XlwMenu.autoDeleteSelection.labelString: ¥»¥ì¥¯¥·¥ç¥ó¤Î¼«Æ°ºï½ü ! Emacs*XlwMenu.activeRegions.labelString: Active Regions -Emacs*XlwMenu.activeRegions.labelString: ³èÀÎΰè(?) +Emacs*XlwMenu.activeRegions.labelString: ³èÆ°¾õÂÖÎΰè ! Emacs*XlwMenu.mousePasteAtTextCursor.labelString: Mouse Paste At Text Cursor Emacs*XlwMenu.mousePasteAtTextCursor.labelString: ¥Æ¥¥¹¥È¥«¡¼¥½¥ë°ÌÃ֤˥ڡ¼¥¹¥È -!!! Options -> General +!! Options -> General ! Emacs*XlwMenu.teachExtendedCommands.labelString: Teach Extended Commands Emacs*XlwMenu.teachExtendedCommands.labelString: ³ÈÄ¥¥³¥Þ¥ó¥É¤Î¥¡¼³äÅöɽ¼¨ @@ -269,7 +270,7 @@ ! Emacs*XlwMenu.debugOnQuit.labelString: Debug On Quit Emacs*XlwMenu.debugOnQuit.labelString: ½ªÎ»»þ¤Ë¥Ç¥Ð¥Ã¥° -!!! Options -> Printing Options +!! Options -> Printing Options ! Emacs*XlwMenu.commandLineSwitchesForLprLp___.labelString: Command-Line Switches for `lpr'/`lp'... Emacs*XlwMenu.commandLineSwitchesForLprLp___.labelString: lp/lpr ÍÑ¥³¥Þ¥ó¥É¥ª¥×¥·¥ç¥ó @@ -278,14 +279,14 @@ ! Emacs*XlwMenu.prettyPrintPaperSize.labelString: Pretty-Print Paper Size Emacs*XlwMenu.prettyPrintPaperSize.labelString: À¶½ñÍѻ極¥¤¥º -!!! Options -> Printing Options -> Pretty-Print Paper Size +!! Options -> Printing Options -> Pretty-Print Paper Size ! Emacs*XlwMenu.letter.labelString: Letter Emacs*XlwMenu.letter.labelString: ¥ì¥¿¡¼ ! Emacs*XlwMenu.legal.labelString: Legal Emacs*XlwMenu.legal.labelString: ¥ê¡¼¥¬¥ë -!!! Options -> Other Window +!! Options -> Other Window ! Emacs*XlwMenu.alwaysInSameFrame.labelString: Always in Same Frame Emacs*XlwMenu.alwaysInSameFrame.labelString: ¾ï¤ËƱ°ì¥Õ¥ì¡¼¥à @@ -300,20 +301,20 @@ ! Emacs*XlwMenu.alwaysCreateNewFrame.labelString: Always Create New Frame Emacs*XlwMenu.alwaysCreateNewFrame.labelString: ¾ï¤Ë¿·µ¬¥Õ¥ì¡¼¥à¤òºîÀ® ! Emacs*XlwMenu.tempBuffersAlwaysInSameFrame.labelString: Temp Buffers Always in Same Frame -Emacs*XlwMenu.tempBuffersAlwaysInSameFrame.labelString: °ì»þ¥Ð¥Ã¥Õ¥¡¡¼¤Ï¾ï¤ËƱ°ì¥Õ¥ì¡¼¥à +Emacs*XlwMenu.tempBuffersAlwaysInSameFrame.labelString: °ì»þ¥Ð¥Ã¥Õ¥¡¤Ï¾ï¤ËƱ°ì¥Õ¥ì¡¼¥à ! Emacs*XlwMenu.tempBuffersLikeOtherBuffers.labelString: Temp Buffers Like Other Buffers -Emacs*XlwMenu.tempBuffersLikeOtherBuffers.labelString: °ì»þ¥Ð¥Ã¥Õ¥¡¡¼¤â¾¥Ð¥Ã¥Õ¥¡¡¼¤ÈƱÍÍ +Emacs*XlwMenu.tempBuffersLikeOtherBuffers.labelString: °ì»þ¥Ð¥Ã¥Õ¥¡¤â¾¥Ð¥Ã¥Õ¥¡¤ÈƱÍÍ -!!! Options -> Syntax Highlighting +!! Options -> Syntax Highlighting ! Emacs*XlwMenu.inThisBuffer.labelString: In This Buffer -Emacs*XlwMenu.inThisBuffer.labelString: ¤³¤Î¥Ð¥Ã¥Õ¥¡¡¼Æâ¤Ç +Emacs*XlwMenu.inThisBuffer.labelString: ¤³¤Î¥Ð¥Ã¥Õ¥¡Æâ¤Ç ! Emacs*XlwMenu.automatic.labelString: Automatic Emacs*XlwMenu.automatic.labelString: ¼«Æ° ! Emacs*XlwMenu.fonts.labelString: Fonts Emacs*XlwMenu.fonts.labelString: ¥Õ¥©¥ó¥È ! Emacs*XlwMenu.colors.labelString: Colors -Emacs*XlwMenu.colors.labelString: ¥«¥é¡¼ +Emacs*XlwMenu.colors.labelString: ¿§ ! Emacs*XlwMenu.least.labelString: Least Emacs*XlwMenu.least.labelString: ºÇÄã ! Emacs*XlwMenu.more.labelString: More @@ -327,18 +328,18 @@ ! Emacs*XlwMenu.caching.labelString: Caching Emacs*XlwMenu.caching.labelString: ¥¥ã¥Ã¥·¥å -!!! Options -> Paren Highlighting +!! Options -> Paren Highlighting ! Emacs*XlwMenu.none.labelString: None Emacs*XlwMenu.none.labelString: ¤Ê¤· ! Emacs*XlwMenu.blinkingParen.labelString: Blinking Paren -Emacs*XlwMenu.blinkingParen.labelString: ³ç¸Ì¤òÅÀÌÇ +Emacs*XlwMenu.blinkingParen.labelString: ÅÀÌǤ¹¤ë³ç¸Ì ! Emacs*XlwMenu.steadyParen.labelString: Steady Paren -Emacs*XlwMenu.steadyParen.labelString: ¶¯¸Ç¤Ê(?)³ç¸Ì +Emacs*XlwMenu.steadyParen.labelString: °ÂÄꤷ¤¿³ç¸Ì ! Emacs*XlwMenu.expression.labelString: Expression Emacs*XlwMenu.expression.labelString: ¼° -!!! Options -> Frame Appearance +!! Options -> Frame Appearance ! Emacs*XlwMenu.scrollbars.labelString: Scrollbars Emacs*XlwMenu.scrollbars.labelString: ¥¹¥¯¥í¡¼¥ë¥Ð¡¼ @@ -351,22 +352,22 @@ ! Emacs*XlwMenu.blinkingCursor.labelString: Blinking Cursor Emacs*XlwMenu.blinkingCursor.labelString: ¥«¡¼¥½¥ëÅÀÌÇ -!!! Options -> Menubar Appearance +!! Options -> Menubar Appearance ! Emacs*XlwMenu.buffersMenuLength___.labelString: Buffers Menu Length... -Emacs*XlwMenu.buffersMenuLength___.labelString: ¥Ð¥Õ¥¡¡¼¥á¥Ë¥å¡¼¤ÎŤµ... +Emacs*XlwMenu.buffersMenuLength___.labelString: ¥Ð¥Ã¥Õ¥¡¥á¥Ë¥å¡¼¤ÎŤµ... ! Emacs*XlwMenu.multiOperationBuffersSubMenus.labelString: Multi-Operation Buffers Sub-Menus -Emacs*XlwMenu.multiOperationBuffersSubMenus.labelString: Ê£¿ôÁàºî¥Ð¥Ã¥Õ¥¡¡¼¥µ¥Ö¥á¥Ë¥å¡¼ +Emacs*XlwMenu.multiOperationBuffersSubMenus.labelString: Ê£¿ôÁàºî¥Ð¥Ã¥Õ¥¡¥µ¥Ö¥á¥Ë¥å¡¼ ! Emacs*XlwMenu.buffersMenuSorting.labelString: Buffers Menu Sorting -Emacs*XlwMenu.buffersMenuSorting.labelString: ¥Ð¥Ã¥Õ¥¡¡¼¥á¥Ë¥å¡¼É½¼¨½ç +Emacs*XlwMenu.buffersMenuSorting.labelString: ¥Ð¥Ã¥Õ¥¡¥á¥Ë¥å¡¼É½¼¨½ç ! Emacs*XlwMenu.submenusForBufferGroups.labelString: Submenus for Buffer Groups -Emacs*XlwMenu.submenusForBufferGroups.labelString: ¥Ð¥Ã¥Õ¥¡¡¼¥°¥ë¡¼¥×Ëè¤Ë¥µ¥Ö¥á¥Ë¥å¡¼ +Emacs*XlwMenu.submenusForBufferGroups.labelString: ¥Ð¥Ã¥Õ¥¡¥°¥ë¡¼¥×Ëè¤Ë¥µ¥Ö¥á¥Ë¥å¡¼ ! Emacs*XlwMenu.frameLocalFontMenu.labelString: Frame-Local Font Menu Emacs*XlwMenu.frameLocalFontMenu.labelString: ¥Õ¥ì¡¼¥àÉÕ°¥Õ¥©¥ó¥È¥á¥Ë¥å¡¼ ! Emacs*XlwMenu.ignoreScaledFonts.labelString: Ignore Scaled Fonts Emacs*XlwMenu.ignoreScaledFonts.labelString: ¥¹¥±¡¼¥ë¤µ¤ì¤¿¥Õ¥©¥ó¥È¤ò̵»ë -!!! Options -> Menubar Appearance -> Buffers Menu Sorting +!! Options -> Menubar Appearance -> Buffers Menu Sorting ! Emacs*XlwMenu.mostRecentlyUsed.labelString: Most Recently Used Emacs*XlwMenu.mostRecentlyUsed.labelString: ºÇ¶á¤ÎÍøÍѽç @@ -375,7 +376,7 @@ ! Emacs*XlwMenu.byMajorModeThenAlphabetically.labelString: By Major Mode, Then Alphabetically Emacs*XlwMenu.byMajorModeThenAlphabetically.labelString: ¼ç¥â¡¼¥ÉËè¤Ë̾Á°½ç -!!! Options -> Toolbar Appearance +!! Options -> Toolbar Appearance ! Emacs*XlwMenu.visible.labelString: Visible Emacs*XlwMenu.visible.labelString: ɽ¼¨ @@ -392,7 +393,7 @@ ! Emacs*XlwMenu.right.labelString: Right Emacs*XlwMenu.right.labelString: ±¦ -!!! Options -> Open URLs with +!! Options -> Open URLs with ! Emacs*XlwMenu.emacsW3.labelString: Emacs-W3 ! Emacs*XlwMenu.emacsW3.labelString: @@ -411,7 +412,7 @@ ! Emacs*XlwMenu.grail.labelString: Grail ! Emacs*XlwMenu.grail.labelString: -!!! Options -> Language Environment +!! Options -> Language Environment ! Emacs*XlwMenu.arabic.labelString: Arabic Emacs*XlwMenu.arabic.labelString: ¥¢¥é¥Ó¥¢¸ì @@ -436,28 +437,28 @@ ! Emacs*XlwMenu.vietnamese.labelString: Vietnamese Emacs*XlwMenu.vietnamese.labelString: ¥Ù¥È¥Ê¥à¸ì -!!! Buffers menu +!! Buffers menu ! Emacs*XlwMenu.listAllBuffers.labelString: List All Buffers -Emacs*XlwMenu.listAllBuffers.labelString: ¥Ð¥Ã¥Õ¥¡¡¼°ìÍ÷ɽ¼¨ +Emacs*XlwMenu.listAllBuffers.labelString: ¥Ð¥Ã¥Õ¥¡°ìÍ÷ɽ¼¨ -!!! below are Buffers submenus +!! below are Buffers submenus ! Emacs*XlwMenu.switchToBuffer.labelString: Switch to Buffer -Emacs*XlwMenu.switchToBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¡¼¤ËÀÚ¤êÂؤ¨ +Emacs*XlwMenu.switchToBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¤ËÀÚ¤êÂؤ¨ ! Emacs*XlwMenu.switchToBufferOtherFrame.labelString: Switch to Buffer, Other Frame -Emacs*XlwMenu.switchToBufferOtherFrame.labelString: ¾¥Õ¥ì¡¼¥à¤Î¥Ð¥Ã¥Õ¥¡¡¼¤ËÀÚ¤êÂؤ¨ +Emacs*XlwMenu.switchToBufferOtherFrame.labelString: ¾¥Õ¥ì¡¼¥à¤Î¥Ð¥Ã¥Õ¥¡¤ËÀÚ¤êÂؤ¨ ! Emacs*XlwMenu.saveBuffer.labelString: Save Buffer -Emacs*XlwMenu.saveBuffer.labelString: ¥Ð¥Ã¥Õ¥¡¡¼Êݸ +Emacs*XlwMenu.saveBuffer.labelString: ¥Ð¥Ã¥Õ¥¡Êݸ -!!! Tools menu +!! Tools menu ! Emacs*XlwMenu.startWorkShop.labelString: Start WorkShop Emacs*XlwMenu.startWorkShop.labelString: WorkShop µ¯Æ° ! Emacs*XlwMenu.grep___.labelString: Grep... -! Emacs*XlwMenu.grep___.labelString: +Emacs*XlwMenu.grep___.labelString: grep... ! Emacs*XlwMenu.compile___.labelString: Compile... -Emacs*XlwMenu.compile___.labelString: ¥³¥ó¥Ñ¥¤¥ë +Emacs*XlwMenu.compile___.labelString: ¥³¥ó¥Ñ¥¤¥ë... ! Emacs*XlwMenu.shell.labelString: Shell Emacs*XlwMenu.shell.labelString: ¥·¥§¥ë ! Emacs*XlwMenu.shellCommand___.labelString: Shell Command... @@ -469,7 +470,7 @@ ! Emacs*XlwMenu.debugDBX___.labelString: Debug (DBX)... Emacs*XlwMenu.debugDBX___.labelString: ¥Ç¥Ð¥Ã¥° (dbx)... ! Emacs*XlwMenu.vC.labelString: VC -! Emacs*XlwMenu.vC.labelString: +Emacs*XlwMenu.vC.labelString: ¥Ð¡¼¥¸¥ç¥ó´ÉÍý (VC) ! Emacs*XlwMenu.compare.labelString: Compare Emacs*XlwMenu.compare.labelString: Èæ³Ó ! Emacs*XlwMenu.merge.labelString: Merge @@ -481,53 +482,57 @@ ! Emacs*XlwMenu.tags.labelString: Tags Emacs*XlwMenu.tags.labelString: ¥¿¥° -!!! Tools -> VC +!! Tools -> VC ! Emacs*XlwMenu.registerFile.labelString: Register File -! Emacs*XlwMenu.registerFile.labelString: +Emacs*XlwMenu.registerFile.labelString: ¥Õ¥¡¥¤¥ëÅÐÏ¿: +! Emacs*XlwMenu.checkInFile.labelString: Check in File +Emacs*XlwMenu.checkInFile.labelString: ¥Á¥§¥Ã¥¯¥¤¥ó: +! Emacs*XlwMenu.checkOutFile.labelString: Check out File +Emacs*XlwMenu.checkOutFile.labelString: ¥Á¥§¥Ã¥¯¥¢¥¦¥È: ! Emacs*XlwMenu.showStatusOf.labelString: Show status of -! Emacs*XlwMenu.showStatusOf.labelString: +Emacs*XlwMenu.showStatusOf.labelString: ¾õÂÖɽ¼¨ ! Emacs*XlwMenu.revertToLastRevision.labelString: Revert to Last Revision -! Emacs*XlwMenu.revertToLastRevision.labelString: +Emacs*XlwMenu.revertToLastRevision.labelString: ºÇ¸å¤ÎÈǤòÉü¸µ ! Emacs*XlwMenu.cancelLastCheckin.labelString: Cancel Last Checkin -! Emacs*XlwMenu.cancelLastCheckin.labelString: +Emacs*XlwMenu.cancelLastCheckin.labelString: ºÇ¸å¤Î¥Á¥§¥Ã¥¯¥¤¥ó¼è¤ê¾Ã¤· ! Emacs*XlwMenu.renameFile.labelString: Rename File -! Emacs*XlwMenu.renameFile.labelString: +Emacs*XlwMenu.renameFile.labelString: ¥Õ¥¡¥¤¥ë̾¾ÎÊѹ¹: ! Emacs*XlwMenu.diffAgainstLastVersion.labelString: Diff Against Last Version -! Emacs*XlwMenu.diffAgainstLastVersion.labelString: +Emacs*XlwMenu.diffAgainstLastVersion.labelString: ºÇ¿·¤ÎÈǤȤκ¹Ê¬ ! Emacs*XlwMenu.diffBetweenRevisions___.labelString: Diff Between Revisions... -! Emacs*XlwMenu.diffBetweenRevisions___.labelString: +Emacs*XlwMenu.diffBetweenRevisions___.labelString: ÈǤδ֤κ¹Ê¬... ! Emacs*XlwMenu.visitOtherVersion___.labelString: Visit Other Version... -! Emacs*XlwMenu.visitOtherVersion___.labelString: +Emacs*XlwMenu.visitOtherVersion___.labelString: ¾¤ÎÈǤòˬÌä... ! Emacs*XlwMenu.showEditHistory.labelString: Show Edit History -! Emacs*XlwMenu.showEditHistory.labelString: +Emacs*XlwMenu.showEditHistory.labelString: ÊÔ½¸ÍúÎò¤òɽ¼¨ ! Emacs*XlwMenu.listLockedFilesAnyUser.labelString: List Locked Files Any User -! Emacs*XlwMenu.listLockedFilesAnyUser.labelString: +Emacs*XlwMenu.listLockedFilesAnyUser.labelString: ¥í¥Ã¥¯¤µ¤ì¤¿¥Õ¥¡¥¤¥ë¤ò¥ê¥¹¥È ! Emacs*XlwMenu.createSnapshot.labelString: Create Snapshot -! Emacs*XlwMenu.createSnapshot.labelString: +Emacs*XlwMenu.createSnapshot.labelString: ¥¹¥Ê¥Ã¥×¥·¥ç¥Ã¥ÈºîÀ® ! Emacs*XlwMenu.retrieveSnapshot.labelString: Retrieve Snapshot -! Emacs*XlwMenu.retrieveSnapshot.labelString: +Emacs*XlwMenu.retrieveSnapshot.labelString: ¥¹¥Ê¥Ã¥×¥·¥ç¥Ã¥È¼èÆÀ ! Emacs*XlwMenu.cVSUpdateDirectory.labelString: CVS Update Directory -! Emacs*XlwMenu.cVSUpdateDirectory.labelString: +Emacs*XlwMenu.cVSUpdateDirectory.labelString: CVS ¹¹¿·¥Ç¥£¥ì¥¯¥È¥ê -!!! Tools -> Compare +!! Tools -> Compare ! Emacs*XlwMenu.twoFiles___.labelString: Two Files... Emacs*XlwMenu.twoFiles___.labelString: 2 ¥Õ¥¡¥¤¥ë´Ö... ! Emacs*XlwMenu.twoBuffers___.labelString: Two Buffers... -Emacs*XlwMenu.twoBuffers___.labelString: 2 ¥Ð¥Ã¥Õ¥¡¡¼´Ö... +Emacs*XlwMenu.twoBuffers___.labelString: 2 ¥Ð¥Ã¥Õ¥¡´Ö... ! Emacs*XlwMenu.threeFiles___.labelString: Three Files... Emacs*XlwMenu.threeFiles___.labelString: 3 ¥Õ¥¡¥¤¥ë´Ö... ! Emacs*XlwMenu.threeBuffers___.labelString: Three Buffers... -Emacs*XlwMenu.threeBuffers___.labelString: 3 ¥Ð¥Ã¥Õ¥¡¡¼´Ö... +Emacs*XlwMenu.threeBuffers___.labelString: 3 ¥Ð¥Ã¥Õ¥¡´Ö... ! Emacs*XlwMenu.twoDirectories___.labelString: Two Directories... Emacs*XlwMenu.twoDirectories___.labelString: 2 ¥Ç¥£¥ì¥¯¥È¥ê´Ö... ! Emacs*XlwMenu.threeDirectories___.labelString: Three Directories... Emacs*XlwMenu.threeDirectories___.labelString: 3 ¥Ç¥£¥ì¥¯¥È¥ê´Ö... ! Emacs*XlwMenu.fileWithRevision___.labelString: File with Revision... -Emacs*XlwMenu.fileWithRevision___.labelString: ²þÄûÈÇ¥Õ¥¡¥¤¥ë... +Emacs*XlwMenu.fileWithRevision___.labelString: ¥Õ¥¡¥¤¥ë¤ÈÈÇ... ! Emacs*XlwMenu.directoryRevisions___.labelString: Directory Revisions... -Emacs*XlwMenu.directoryRevisions___.labelString: ²þÄûÈǥǥ£¥ì¥¯¥È¥ê... +Emacs*XlwMenu.directoryRevisions___.labelString: Èǥǥ£¥ì¥¯¥È¥ê... ! Emacs*XlwMenu.windowsWordByWord___.labelString: Windows Word-by-word... Emacs*XlwMenu.windowsWordByWord___.labelString: ¥¦¥£¥ó¥É¥¦¤òñ¸ì¤´¤È¤Ë... ! Emacs*XlwMenu.windowsLineByLine___.labelString: Windows Line-by-line... @@ -536,65 +541,74 @@ Emacs*XlwMenu.regionsWordByWord___.labelString: Îΰè¤òñ¸ì¤´¤È¤Ë... ! Emacs*XlwMenu.regionsLineByLine___.labelString: Regions Line-by-line... Emacs*XlwMenu.regionsLineByLine___.labelString: Îΰè¤ò¹Ô¤´¤È¤Ë... -! Emacs*XlwMenu.listEdiffSessions___.labelString: List Ediff Sessions... -Emacs*XlwMenu.listEdiffSessions___.labelString: ediff ¥»¥Ã¥·¥ç¥ó°ìÍ÷... -! Emacs*XlwMenu.ediffManual___.labelString: Ediff Manual... -Emacs*XlwMenu.ediffManual___.labelString: ediff ¥Þ¥Ë¥å¥¢¥ë... -!!! Tools -> Merge +!! Tools -> Merge ! Emacs*XlwMenu.files___.labelString: Files... Emacs*XlwMenu.files___.labelString: ¥Õ¥¡¥¤¥ë´Ö... ! Emacs*XlwMenu.filesWithAncestor___.labelString: Files with Ancestor... Emacs*XlwMenu.filesWithAncestor___.labelString: ¶¦ÄÌÁÄÀè¤Î¥Õ¥¡¥¤¥ë... ! Emacs*XlwMenu.buffers___.labelString: Buffers... -Emacs*XlwMenu.buffers___.labelString: ¥Ð¥Ã¥Õ¥¡¡¼´Ö... +Emacs*XlwMenu.buffers___.labelString: ¥Ð¥Ã¥Õ¥¡´Ö... ! Emacs*XlwMenu.buffersWithAncestor___.labelString: Buffers with Ancestor... -Emacs*XlwMenu.buffersWithAncestor___.labelString: ¥Ð¥Ã¥Õ¥¡¡¼¤òÀèÁĤÈ... +Emacs*XlwMenu.buffersWithAncestor___.labelString: ¥Ð¥Ã¥Õ¥¡¤òÀèÁĤÈ... ! Emacs*XlwMenu.directories___.labelString: Directories... Emacs*XlwMenu.directories___.labelString: ¥Ç¥£¥ì¥¯¥È¥ê´Ö... ! Emacs*XlwMenu.directoriesWithAncestor___.labelString: Directories with Ancestor... Emacs*XlwMenu.directoriesWithAncestor___.labelString: ¥Ç¥£¥ì¥¯¥È¥ê¤òÀèÁĤÈ... ! Emacs*XlwMenu.revisions___.labelString: Revisions... -Emacs*XlwMenu.revisions___.labelString: ²þÄûÈÇ´Ö... +Emacs*XlwMenu.revisions___.labelString: ÈÇ´Ö... ! Emacs*XlwMenu.revisionsWithAncestor___.labelString: Revisions with Ancestor... -Emacs*XlwMenu.revisionsWithAncestor___.labelString: ²þÄûÈǤòÀèÁĤÈ... +Emacs*XlwMenu.revisionsWithAncestor___.labelString: ÈǤòÀèÁĤÈ... ! Emacs*XlwMenu.directoryRevisionsWithAncestor___.labelString: Directory Revisions with Ancestor... -Emacs*XlwMenu.directoryRevisionsWithAncestor___.labelString: ²þÄûÈǥǥ£¥ì¥¯¥È¥ê¤òÀèÁĤÈ... +Emacs*XlwMenu.directoryRevisionsWithAncestor___.labelString: Èǥǥ£¥ì¥¯¥È¥ê¤òÀèÁĤÈ... -!!! Tools -> Apply Patch +!! Tools -> Apply Patch ! Emacs*XlwMenu.toAFile___.labelString: To a file... Emacs*XlwMenu.toAFile___.labelString: ¥Õ¥¡¥¤¥ë¤ËÂФ·¤Æ... ! Emacs*XlwMenu.toABuffer___.labelString: To a buffer... -Emacs*XlwMenu.toABuffer___.labelString: ¥Ð¥Ã¥Õ¥¡¡¼¤ËÂФ·¤Æ... +Emacs*XlwMenu.toABuffer___.labelString: ¥Ð¥Ã¥Õ¥¡¤ËÂФ·¤Æ... + +!! Tools -> Ediff Miscellanea -!!! Tools -> Tags +! Emacs*XlwMenu.ediffMiscellanea.labelString: Ediff Miscellanea +Emacs*XlwMenu.ediffMiscellanea.labelString: Ediff ´Ø·¸ +! Emacs*XlwMenu.listEdiffSessions___.labelString: List Ediff Sessions... +Emacs*XlwMenu.listEdiffSessions___.labelString: Ediff ¥»¥Ã¥·¥ç¥ó°ìÍ÷... +! Emacs*XlwMenu.ediffManual___.labelString: Ediff Manual... +Emacs*XlwMenu.ediffManual___.labelString: Ediff ¥Þ¥Ë¥å¥¢¥ë... +! Emacs*XlwMenu.useSeparateFrameForEdiffControlBuffer___.labelString: Use separate frame for Ediff control buffer... +Emacs*XlwMenu.useSeparateFrameForEdiffControlBuffer___.labelString: Ediff À©¸æ¥Ð¥Ã¥Õ¥¡ÍѤËÊ̥ե졼¥à¤ò»ÈÍÑ +! Emacs*XlwMenu.useAToolbarWithEdiffControlBuffer.labelString: Use a toolbar with Ediff control buffer +Emacs*XlwMenu.useAToolbarWithEdiffControlBuffer.labelString: ¥Ä¡¼¥ë¥Ð¡¼¤ò Ediff À©¸æ¥Ð¥Ã¥Õ¥¡¤È¶¦¤Ë»ÈÍÑ + +!! Tools -> Tags ! Emacs*XlwMenu.findTag___.labelString: Find Tag... -! Emacs*XlwMenu.findTag___.labelString: +Emacs*XlwMenu.findTag___.labelString: ¥¿¥°¤òõ¤¹... ! Emacs*XlwMenu.findOtherWindow___.labelString: Find Other Window... -! Emacs*XlwMenu.findOtherWindow___.labelString: +Emacs*XlwMenu.findOtherWindow___.labelString: ¾¥¦¥£¥ó¥É¥¦¤Çõ¤¹... ! Emacs*XlwMenu.nextTag___.labelString: Next Tag... -! Emacs*XlwMenu.nextTag___.labelString: +Emacs*XlwMenu.nextTag___.labelString: ¼¡¤Î¥¿¥°... ! Emacs*XlwMenu.nextOtherWindow___.labelString: Next Other Window... -! Emacs*XlwMenu.nextOtherWindow___.labelString: +Emacs*XlwMenu.nextOtherWindow___.labelString: ¾¥¦¥£¥ó¥É¥¦¤Ç¼¡¤ò... ! Emacs*XlwMenu.nextFile.labelString: Next File -! Emacs*XlwMenu.nextFile.labelString: +Emacs*XlwMenu.nextFile.labelString: ¼¡¤Î¥Õ¥¡¥¤¥ë ! Emacs*XlwMenu.tagsSearch___.labelString: Tags Search... -! Emacs*XlwMenu.tagsSearch___.labelString: +Emacs*XlwMenu.tagsSearch___.labelString: ¥¿¥°¤ò¸¡º÷... ! Emacs*XlwMenu.tagsReplace___.labelString: Tags Replace... -! Emacs*XlwMenu.tagsReplace___.labelString: +Emacs*XlwMenu.tagsReplace___.labelString: ¥¿¥°¤òÃÖ´¹... ! Emacs*XlwMenu.continueSearchReplace.labelString: Continue Search/Replace -! Emacs*XlwMenu.continueSearchReplace.labelString: +Emacs*XlwMenu.continueSearchReplace.labelString: ¸¡º÷/ÃÖ´¹¤ò³¹Ô ! Emacs*XlwMenu.popStack.labelString: Pop stack -! Emacs*XlwMenu.popStack.labelString: +Emacs*XlwMenu.popStack.labelString: ¥¹¥¿¥Ã¥¯¤ò¥Ý¥Ã¥× ! Emacs*XlwMenu.apropos___.labelString: Apropos... -! Emacs*XlwMenu.apropos___.labelString: +Emacs*XlwMenu.apropos___.labelString: ŬÀÚ¸¡º÷... ! Emacs*XlwMenu.setTagsTableFile___.labelString: Set Tags Table File... -! Emacs*XlwMenu.setTagsTableFile___.labelString: +Emacs*XlwMenu.setTagsTableFile___.labelString: ¥¿¥°¥Æ¡¼¥Ö¥ë¥Õ¥¡¥¤¥ë¤òÀßÄê... -!!! Help menu +!! Help menu ! Emacs*XlwMenu.aboutXEmacs___.labelString: About XEmacs... Emacs*XlwMenu.aboutXEmacs___.labelString: XEmacs ¤Ë¤Ä¤¤¤Æ... @@ -609,7 +623,7 @@ ! Emacs*XlwMenu.xEmacsNews.labelString: XEmacs News Emacs*XlwMenu.xEmacsNews.labelString: XEmacs ¥Ë¥å¡¼¥¹ ! Emacs*XlwMenu.sample.labelString: Sample -Emacs*XlwMenu.sample.labelString: ¤ÎÎã +Emacs*XlwMenu.sample.labelString: Îã: ! Emacs*XlwMenu.infoDetailedDocs.labelString: Info (Detailed Docs) Emacs*XlwMenu.infoDetailedDocs.labelString: Info (¾ÜºÙ¥É¥¥å¥á¥ó¥È) ! Emacs*XlwMenu.lookupInInfo.labelString: Lookup in Info @@ -619,7 +633,7 @@ ! Emacs*XlwMenu.describeMode.labelString: Describe Mode Emacs*XlwMenu.describeMode.labelString: ¥â¡¼¥Éµ½Ò ! Emacs*XlwMenu.aproposDocumentation___.labelString: Apropos Documentation... -Emacs*XlwMenu.aproposDocumentation___.labelString: ¥É¥¥å¥á¥ó¥È¤ËÂФ¹¤ë apropos... +Emacs*XlwMenu.aproposDocumentation___.labelString: ¥É¥¥å¥á¥ó¥È¤ÇŬÀÚ¸¡º÷... ! Emacs*XlwMenu.recentKeystrokesMessages.labelString: Recent Keystrokes/Messages Emacs*XlwMenu.recentKeystrokesMessages.labelString: ºÇ¿·¥¡¼¥¹¥È¥í¡¼¥¯/¥á¥Ã¥»¡¼¥¸ ! Emacs*XlwMenu.describeKeyMouse___.labelString: Describe Key/Mouse... @@ -638,8 +652,10 @@ Emacs*XlwMenu.unixManual___.labelString: Unix ¥Þ¥Ë¥å¥¢¥ë... ! Emacs*XlwMenu.misc.labelString: Misc Emacs*XlwMenu.misc.labelString: ¤½¤Î¾ +! Emacs*XlwMenu.customize___.labelString: Customize.. +Emacs*XlwMenu.customize___.labelString: ¥«¥¹¥¿¥à²½... -!!! Help -> Lookup in Info +!! Help -> Lookup in Info ! Emacs*XlwMenu.keyMouseBinding___.labelString: Key/Mouse Binding... Emacs*XlwMenu.keyMouseBinding___.labelString: ¥¡¼/¥Þ¥¦¥¹ ³ä¤êÅö¤Æ... @@ -650,18 +666,18 @@ ! Emacs*XlwMenu.topic___.labelString: Topic... Emacs*XlwMenu.topic___.labelString: ¥È¥Ô¥Ã¥¯... -!!! Help -> Misc +!! Help -> Misc ! Emacs*XlwMenu.describeNoWarranty.labelString: Describe No Warranty -! Emacs*XlwMenu.describeNoWarranty.labelString: +Emacs*XlwMenu.describeNoWarranty.labelString: ̵Êݾã¤Îµ½Ò ! Emacs*XlwMenu.describeXEmacsLicense.labelString: Describe XEmacs License -! Emacs*XlwMenu.describeXEmacsLicense.labelString: +Emacs*XlwMenu.describeXEmacsLicense.labelString: XEmacs ¥é¥¤¥»¥ó¥¹¤òɽ¼¨ ! Emacs*XlwMenu.gettingTheLatestVersion.labelString: Getting the Latest Version -! Emacs*XlwMenu.gettingTheLatestVersion.labelString: +Emacs*XlwMenu.gettingTheLatestVersion.labelString: ºÇ¿·ÈǤÎÆþ¼êÊýË¡ -!!!! WorkShop +!!! WorkShop -!!! WorkShop menu +!! WorkShop menu ! Emacs*XlwMenu.workShop.labelString: WorkShop ! Emacs*XlwMenu.workShop.labelString: @@ -672,80 +688,80 @@ ! Emacs*XlwMenu.program.labelString: Program Emacs*XlwMenu.program.labelString: ¥×¥í¥°¥é¥à ! Emacs*XlwMenu.step.labelString: Step -! Emacs*XlwMenu.step.labelString: +Emacs*XlwMenu.step.labelString: ¥¹¥Æ¥Ã¥× ! Emacs*XlwMenu.stack.labelString: Stack -! Emacs*XlwMenu.stack.labelString: +Emacs*XlwMenu.stack.labelString: ¥¹¥¿¥Ã¥¯ ! Emacs*XlwMenu.evaluate.labelString: Evaluate -! Emacs*XlwMenu.evaluate.labelString: +Emacs*XlwMenu.evaluate.labelString: ɾ²Á ! Emacs*XlwMenu.browse.labelString: Browse -! Emacs*XlwMenu.browse.labelString: +Emacs*XlwMenu.browse.labelString: ¥Ö¥é¥¦¥º ! Emacs*XlwMenu.fix.labelString: Fix -! Emacs*XlwMenu.fix.labelString: +Emacs*XlwMenu.fix.labelString: ½¤Àµ ! Emacs*XlwMenu.quitWorkShop.labelString: Quit WorkShop -! Emacs*XlwMenu.quitWorkShop.labelString: +Emacs*XlwMenu.quitWorkShop.labelString: WorkShop ½ªÎ» -!!! WorkShop -> Build +!! WorkShop -> Build ! Emacs*XlwMenu.currentTarget.labelString: Current Target -! Emacs*XlwMenu.currentTarget.labelString: +Emacs*XlwMenu.currentTarget.labelString: ¸½¥¿¡¼¥²¥Ã¥È¤ò ! Emacs*XlwMenu.buildThisFile.labelString: Build This File -! Emacs*XlwMenu.buildThisFile.labelString: +Emacs*XlwMenu.buildThisFile.labelString: ¤³¤Î¥Õ¥¡¥¤¥ë¤ò -!!! WorkShop -> Breakpoints +!! WorkShop -> Breakpoints ! Emacs*XlwMenu.stopAt.labelString: Stop At -! Emacs*XlwMenu.stopAt.labelString: +Emacs*XlwMenu.stopAt.labelString: ÁªÂò¹Ô ! Emacs*XlwMenu.stopInSelected.labelString: Stop In Selected -! Emacs*XlwMenu.stopInSelected.labelString: +Emacs*XlwMenu.stopInSelected.labelString: ÁªÂò´Ø¿ôÆâ ! Emacs*XlwMenu.deleteBreakpointAt.labelString: Delete Breakpoint At -! Emacs*XlwMenu.deleteBreakpointAt.labelString: +Emacs*XlwMenu.deleteBreakpointAt.labelString: ÁªÂò¹Ô¤«¤éºï½ü -!!! WorkShop -> Program +!! WorkShop -> Program ! Emacs*XlwMenu.start.labelString: Start -! Emacs*XlwMenu.start.labelString: +Emacs*XlwMenu.start.labelString: ³«»Ï ! Emacs*XlwMenu.go.labelString: Go -! Emacs*XlwMenu.go.labelString: +Emacs*XlwMenu.go.labelString: ·Ñ³ ! Emacs*XlwMenu.interrupt.labelString: Interrupt -! Emacs*XlwMenu.interrupt.labelString: +Emacs*XlwMenu.interrupt.labelString: ³ä¤ê¹þ¤ß -!!! WorkShop -> Step +!! WorkShop -> Step ! Emacs*XlwMenu.into.labelString: Into -! Emacs*XlwMenu.into.labelString: +Emacs*XlwMenu.into.labelString: ¥¤¥ó (step) ! Emacs*XlwMenu.over.labelString: Over -! Emacs*XlwMenu.over.labelString: +Emacs*XlwMenu.over.labelString: ¥ª¡¼¥Ð¡¼ (next) ! Emacs*XlwMenu.out.labelString: Out -! Emacs*XlwMenu.out.labelString: +Emacs*XlwMenu.out.labelString: ¥¢¥¦¥È (step out) -!!! WorkShop -> Stack +!! WorkShop -> Stack ! Emacs*XlwMenu.up.labelString: Up -! Emacs*XlwMenu.up.labelString: +Emacs*XlwMenu.up.labelString: ¾å¤Ø ! Emacs*XlwMenu.down.labelString: Down -! Emacs*XlwMenu.down.labelString: +Emacs*XlwMenu.down.labelString: ²¼¤Ø ! Emacs*XlwMenu.pop.labelString: Pop -! Emacs*XlwMenu.pop.labelString: +Emacs*XlwMenu.pop.labelString: ¥Ý¥Ã¥× ! Emacs*XlwMenu.popToCurrentFrame.labelString: Pop to Current Frame -! Emacs*XlwMenu.popToCurrentFrame.labelString: +Emacs*XlwMenu.popToCurrentFrame.labelString: ¸½¥Õ¥ì¡¼¥à¤Þ¤Ç¥Ý¥Ã¥× -!!! WorkShop -> Evaluate +!! WorkShop -> Evaluate ! Emacs*XlwMenu.selected.labelString: Selected -! Emacs*XlwMenu.selected.labelString: +Emacs*XlwMenu.selected.labelString: ÁªÂò¹àÌÜ ! Emacs*XlwMenu.asPointer.labelString: As Pointer -! Emacs*XlwMenu.asPointer.labelString: +Emacs*XlwMenu.asPointer.labelString: ¥Ý¥¤¥ó¥¿¤È¤·¤Æ -!!! WorkShop -> Browse +!! WorkShop -> Browse ! Emacs*XlwMenu.referencesToSelected.labelString: References to Selected -! Emacs*XlwMenu.referencesToSelected.labelString: +Emacs*XlwMenu.referencesToSelected.labelString: ÁªÂò¹àÌܤؤλ²¾È ! Emacs*XlwMenu.definitionOfSelected.labelString: Definition of Selected -! Emacs*XlwMenu.definitionOfSelected.labelString: +Emacs*XlwMenu.definitionOfSelected.labelString: ÁªÂò¹àÌܤÎÄêµÁ -!!!! Modes: +!!! Modes: -!!!! Lisp-interaction mode and Lisp mode +!!! Lisp-interaction mode and Lisp mode ! Emacs*XlwMenu.lispInteractionMenu.labelString: Lisp Interaction Menu ! Emacs*XlwMenu.lispInteractionMenu.labelString: @@ -778,7 +794,7 @@ ! Emacs*XlwMenu.byteRecompileDirectory___.labelString: Byte-recompile Directory... ! Emacs*XlwMenu.byteRecompileDirectory___.labelString: -!!! C mode +!! C mode ! Emacs*XlwMenu.c.labelString: C ! Emacs*XlwMenu.c.labelString: @@ -801,17 +817,17 @@ ! Emacs*XlwMenu.forwardStatement.labelString: Forward Statement ! Emacs*XlwMenu.forwardStatement.labelString: -!!! C++ mode +!! C++ mode ! Emacs*XlwMenu.cPP.labelString: C++ ! Emacs*XlwMenu.cPP.labelString: -!!! Java mode +!! Java mode ! Emacs*XlwMenu.java.labelString: Java ! Emacs*XlwMenu.java.labelString: -!!! Ada mode +!! Ada mode ! Emacs*XlwMenu.ada.labelString: Ada ! Emacs*XlwMenu.ada.labelString: @@ -857,7 +873,7 @@ ! Emacs*XlwMenu.otherFile.labelString: Other File ! Emacs*XlwMenu.otherFile.labelString: -!!! Default edit popup menu +!! Default edit popup menu ! Emacs*XlwMenu.xEmacsCommands.labelString: XEmacs Commands Emacs*XlwMenu.xEmacsCommands.labelString: XEmacs ¥³¥Þ¥ó¥É @@ -866,7 +882,7 @@ ! Emacs*XlwMenu.unsplitWindow.labelString: Unsplit Window Emacs*XlwMenu.unsplitWindow.labelString: ¥¦¥£¥ó¥É¥¦Ê¬³ä²ò½ü -!!! Default modeline popup menu +!! Default modeline popup menu ! Emacs*XlwMenu.windowCommandsFor.labelString: Window Commands for ! Emacs*XlwMenu.windowCommandsFor.labelString: @@ -885,7 +901,7 @@ ! Emacs*XlwMenu.f90.labelString: F90 ! Emacs*XlwMenu.f90.labelString: -!!! F90 menu +!! F90 menu ! Emacs*XlwMenu.indentSubprogram.labelString: Indent Subprogram ! Emacs*XlwMenu.indentSubprogram.labelString: @@ -924,7 +940,7 @@ ! Emacs*XlwMenu.toggleAutoFill.labelString: Toggle auto-fill ! Emacs*XlwMenu.toggleAutoFill.labelString: -!!!! Makefile mode +!!! Makefile mode ! Emacs*XlwMenu.makefile.labelString: Makefile ! Emacs*XlwMenu.makefile.labelString: @@ -939,7 +955,7 @@ ! Emacs*XlwMenu.popUpMakefileBrowser.labelString: Pop up Makefile Browser ! Emacs*XlwMenu.popUpMakefileBrowser.labelString: -!!!! Shell mode main menubar +!!! Shell mode main menubar ! Emacs*XlwMenu.comint1.labelString: Comint1 ! Emacs*XlwMenu.comint1.labelString: @@ -948,7 +964,7 @@ ! Emacs*XlwMenu.history.labelString: History ! Emacs*XlwMenu.history.labelString: -!!! (Shell mode) Comint1 menu +!! (Shell mode) Comint1 menu ! Emacs*XlwMenu.previousMatchingCurrentInput.labelString: Previous Matching Current Input ! Emacs*XlwMenu.previousMatchingCurrentInput.labelString: @@ -1007,14 +1023,14 @@ ! Emacs*XlwMenu.sendEOF.labelString: Send EOF ! Emacs*XlwMenu.sendEOF.labelString: -!!! (Shell mode) History menu +!! (Shell mode) History menu ! Emacs*XlwMenu.expandHistoryBeforePoint.labelString: Expand History Before Point ! Emacs*XlwMenu.expandHistoryBeforePoint.labelString: ! Emacs*XlwMenu.listInputHistory.labelString: List Input History ! Emacs*XlwMenu.listInputHistory.labelString: -!!! Info mode menu +!! Info mode menu ! Emacs*XlwMenu.info.labelString: Info ! Emacs*XlwMenu.info.labelString: @@ -1034,16 +1050,16 @@ Emacs*XlwMenu.___more___.labelString: ¤â¤Ã¤È -!!!! Gnus +!!! Gnus -!!! (Gnus Group mode) Main menu +!! (Gnus Group mode) Main menu ! Emacs*XlwMenu.group.labelString: Group ! Emacs*XlwMenu.group.labelString: ! Emacs*XlwMenu.groups.labelString: Groups ! Emacs*XlwMenu.groups.labelString: -!!! (Gnus Group mode) Group menu +!! (Gnus Group mode) Group menu ! Emacs*XlwMenu.read.labelString: Read ! Emacs*XlwMenu.read.labelString: @@ -1076,7 +1092,7 @@ ! Emacs*XlwMenu.selectQuick.labelString: Select quick ! Emacs*XlwMenu.selectQuick.labelString: -!!! (Gnus Group mode) Groups menu +!! (Gnus Group mode) Groups menu ! Emacs*XlwMenu.listing.labelString: Listing ! Emacs*XlwMenu.listing.labelString: @@ -1099,7 +1115,7 @@ ! Emacs*XlwMenu.readADirectoryAsAGroup___.labelString: Read a directory as a group... ! Emacs*XlwMenu.readADirectoryAsAGroup___.labelString: -!!! (Gnus Group mode) Groups -> Listing +!! (Gnus Group mode) Groups -> Listing ! Emacs*XlwMenu.listUnreadSubscribedGroups.labelString: List unread subscribed groups ! Emacs*XlwMenu.listUnreadSubscribedGroups.labelString: @@ -1124,7 +1140,7 @@ ! Emacs*XlwMenu.listActiveFile.labelString: List active file ! Emacs*XlwMenu.listActiveFile.labelString: -!!! (Gnus Group mode) Groups -> Sort +!! (Gnus Group mode) Groups -> Sort ! Emacs*XlwMenu.defaultSort.labelString: Default sort ! Emacs*XlwMenu.defaultSort.labelString: @@ -1141,7 +1157,7 @@ ! Emacs*XlwMenu.sortByName.labelString: Sort by name ! Emacs*XlwMenu.sortByName.labelString: -!!! (Gnus Group mode) Groups -> Mark +!! (Gnus Group mode) Groups -> Mark ! Emacs*XlwMenu.markGroup.labelString: Mark group ! Emacs*XlwMenu.markGroup.labelString: @@ -1158,7 +1174,7 @@ ! Emacs*XlwMenu.executeCommand.labelString: Execute command ! Emacs*XlwMenu.executeCommand.labelString: -!!! (Gnus Group mode) Groups -> Subscribe +!! (Gnus Group mode) Groups -> Subscribe ! Emacs*XlwMenu.subscribeToAGroup.labelString: Subscribe to a group ! Emacs*XlwMenu.subscribeToAGroup.labelString: @@ -1169,7 +1185,7 @@ ! Emacs*XlwMenu.killAllGroupsOnLevel___.labelString: Kill all groups on level... ! Emacs*XlwMenu.killAllGroupsOnLevel___.labelString: -!!! (Gnus Group mode) Groups -> Foreign groups +!! (Gnus Group mode) Groups -> Foreign groups ! Emacs*XlwMenu.makeAForeignGroup.labelString: Make a foreign group ! Emacs*XlwMenu.makeAForeignGroup.labelString: @@ -1192,19 +1208,19 @@ ! Emacs*XlwMenu.deleteGroup.labelString: Delete group ! Emacs*XlwMenu.deleteGroup.labelString: -!!! (Gnus Group mode) Groups -> Editing groups +!! (Gnus Group mode) Groups -> Editing groups ! Emacs*XlwMenu.parameters.labelString: Parameters ! Emacs*XlwMenu.parameters.labelString: ! Emacs*XlwMenu.selectMethod.labelString: Select method ! Emacs*XlwMenu.selectMethod.labelString: -!!! (Gnus Group mode) Groups -> Score file +!! (Gnus Group mode) Groups -> Score file ! Emacs*XlwMenu.flushCache.labelString: Flush cache ! Emacs*XlwMenu.flushCache.labelString: -!!! (Gnus Group mode) Groups -> Move +!! (Gnus Group mode) Groups -> Move ! Emacs*XlwMenu.next.labelString: Next ! Emacs*XlwMenu.next.labelString: @@ -1225,7 +1241,7 @@ ! Emacs*XlwMenu.bestUnreadGroup.labelString: Best unread group ! Emacs*XlwMenu.bestUnreadGroup.labelString: -!!! (Gnus Group mode) Misc menu +!! (Gnus Group mode) Misc menu ! Emacs*XlwMenu.sendABugReport.labelString: Send a bug report ! Emacs*XlwMenu.sendABugReport.labelString: @@ -1276,7 +1292,7 @@ ! Emacs*XlwMenu.exitWithoutSaving.labelString: Exit without saving ! Emacs*XlwMenu.exitWithoutSaving.labelString: -!!! (Gnus Group mode) Misc -> SOUP +!! (Gnus Group mode) Misc -> SOUP ! Emacs*XlwMenu.packReplies.labelString: Pack replies ! Emacs*XlwMenu.packReplies.labelString: @@ -1289,7 +1305,7 @@ ! Emacs*XlwMenu.brewSOUP.labelString: Brew SOUP ! Emacs*XlwMenu.brewSOUP.labelString: -!!!! (Gnus Article mode) Main menubar +!!! (Gnus Article mode) Main menubar ! Emacs*XlwMenu.score.labelString: Score ! Emacs*XlwMenu.score.labelString: @@ -1300,7 +1316,7 @@ ! Emacs*XlwMenu.post.labelString: Post ! Emacs*XlwMenu.post.labelString: -!!! (Gnus Article mode) Misc menu +!! (Gnus Article mode) Misc menu ! Emacs*XlwMenu.scrollArticle.labelString: Scroll article ! Emacs*XlwMenu.scrollArticle.labelString: @@ -1325,7 +1341,7 @@ ! Emacs*XlwMenu.exit.labelString: Exit ! Emacs*XlwMenu.exit.labelString: -!!! (Gnus Article mode) Misc -> Mark +!! (Gnus Article mode) Misc -> Mark ! Emacs*XlwMenu.various.labelString: Various ! Emacs*XlwMenu.various.labelString: @@ -1334,7 +1350,7 @@ ! Emacs*XlwMenu.processMark.labelString: Process mark ! Emacs*XlwMenu.processMark.labelString: -!!! (Gnus Article mode) Misc -> Mark -> Read +!! (Gnus Article mode) Misc -> Mark -> Read ! Emacs*XlwMenu.markAsRead.labelString: Mark as read ! Emacs*XlwMenu.markAsRead.labelString: @@ -1353,7 +1369,7 @@ ! Emacs*XlwMenu.markExcluded.labelString: Mark excluded ! Emacs*XlwMenu.markExcluded.labelString: -!!! (Gnus Article mode) Misc -> Mark -> Various +!! (Gnus Article mode) Misc -> Mark -> Various ! Emacs*XlwMenu.tick.labelString: Tick ! Emacs*XlwMenu.tick.labelString: @@ -1366,7 +1382,7 @@ ! Emacs*XlwMenu.removeBookmark.labelString: Remove bookmark ! Emacs*XlwMenu.removeBookmark.labelString: -!!! (Gnus Article mode) Misc -> Mark -> Limit +!! (Gnus Article mode) Misc -> Mark -> Limit ! Emacs*XlwMenu.marks___.labelString: Marks... ! Emacs*XlwMenu.marks___.labelString: @@ -1389,7 +1405,7 @@ ! Emacs*XlwMenu.showExpunged.labelString: Show expunged ! Emacs*XlwMenu.showExpunged.labelString: -!!! (Gnus Article mode) Misc -> Mark -> Process mark +!! (Gnus Article mode) Misc -> Mark -> Process mark ! Emacs*XlwMenu.setMark.labelString: Set mark ! Emacs*XlwMenu.setMark.labelString: @@ -1412,7 +1428,7 @@ ! Emacs*XlwMenu.unmarkThread.labelString: Unmark thread ! Emacs*XlwMenu.unmarkThread.labelString: -!!! (Gnus Article mode) Misc -> Scroll Article +!! (Gnus Article mode) Misc -> Scroll Article ! Emacs*XlwMenu.pageForward.labelString: Page forward ! Emacs*XlwMenu.pageForward.labelString: @@ -1421,7 +1437,7 @@ ! Emacs*XlwMenu.lineForward.labelString: Line forward ! Emacs*XlwMenu.lineForward.labelString: -!!! (Gnus Article mode) Misc -> Move +!! (Gnus Article mode) Misc -> Move ! Emacs*XlwMenu.nextUnreadArticle.labelString: Next unread article ! Emacs*XlwMenu.nextUnreadArticle.labelString: @@ -1452,7 +1468,7 @@ ! Emacs*XlwMenu.popArticleOffHistory.labelString: Pop article off history ! Emacs*XlwMenu.popArticleOffHistory.labelString: -!!! (Gnus Article mode) Misc -> Sort +!! (Gnus Article mode) Misc -> Sort ! Emacs*XlwMenu.sortByNumber.labelString: Sort by number ! Emacs*XlwMenu.sortByNumber.labelString: @@ -1463,28 +1479,28 @@ ! Emacs*XlwMenu.sortByDate.labelString: Sort by date ! Emacs*XlwMenu.sortByDate.labelString: -!!! (Gnus Article mode) Misc -> Help +!! (Gnus Article mode) Misc -> Help ! Emacs*XlwMenu.fetchGroupFAQ.labelString: Fetch group FAQ ! Emacs*XlwMenu.fetchGroupFAQ.labelString: ! Emacs*XlwMenu.describeGroup.labelString: Describe group ! Emacs*XlwMenu.describeGroup.labelString: -!!! (Gnus Article mode) Misc -> Cache +!! (Gnus Article mode) Misc -> Cache ! Emacs*XlwMenu.enterArticle.labelString: Enter article ! Emacs*XlwMenu.enterArticle.labelString: ! Emacs*XlwMenu.removeArticle.labelString: Remove article ! Emacs*XlwMenu.removeArticle.labelString: -!!! (Gnus Article mode) Misc -> Modes +!! (Gnus Article mode) Misc -> Modes ! Emacs*XlwMenu.pickAndRead.labelString: Pick and read ! Emacs*XlwMenu.pickAndRead.labelString: ! Emacs*XlwMenu.binary.labelString: Binary ! Emacs*XlwMenu.binary.labelString: -!!! (Gnus Article mode) Misc -> Exit +!! (Gnus Article mode) Misc -> Exit ! Emacs*XlwMenu.catchupAndExit.labelString: Catchup and exit ! Emacs*XlwMenu.catchupAndExit.labelString: @@ -1505,7 +1521,7 @@ ! Emacs*XlwMenu.rescanGroup.labelString: Rescan group ! Emacs*XlwMenu.rescanGroup.labelString: -!!! (Gnus Article mode) Score menu +!! (Gnus Article mode) Score menu ! Emacs*XlwMenu.enterScore___.labelString: Enter score... ! Emacs*XlwMenu.enterScore___.labelString: @@ -1532,7 +1548,7 @@ ! Emacs*XlwMenu.lowerScore___.labelString: Lower score... ! Emacs*XlwMenu.lowerScore___.labelString: -!!! (Gnus Article mode) Score -> Mark +!! (Gnus Article mode) Score -> Mark ! Emacs*XlwMenu.killBelow.labelString: Kill below ! Emacs*XlwMenu.killBelow.labelString: @@ -1541,7 +1557,7 @@ ! Emacs*XlwMenu.clearAbove.labelString: Clear above ! Emacs*XlwMenu.clearAbove.labelString: -!!! (Gnus Article mode) Article menu +!! (Gnus Article mode) Article menu ! Emacs*XlwMenu.hide.labelString: Hide ! Emacs*XlwMenu.hide.labelString: @@ -1578,7 +1594,7 @@ ! Emacs*XlwMenu.redisplay.labelString: Redisplay ! Emacs*XlwMenu.redisplay.labelString: -!!! (Gnus Article mode) Article -> Hide +!! (Gnus Article mode) Article -> Hide ! Emacs*XlwMenu.all.labelString: All ! Emacs*XlwMenu.all.labelString: @@ -1593,10 +1609,10 @@ ! Emacs*XlwMenu.boringHeaders.labelString: Boring headers ! Emacs*XlwMenu.boringHeaders.labelString: -!!! (Gnus Article mode) Article -> Highlight +!! (Gnus Article mode) Article -> Highlight -!!! (Gnus Article mode) Article -> Date +!! (Gnus Article mode) Article -> Date ! Emacs*XlwMenu.local.labelString: Local ! Emacs*XlwMenu.local.labelString: @@ -1607,7 +1623,7 @@ ! Emacs*XlwMenu.lapsed.labelString: Lapsed ! Emacs*XlwMenu.lapsed.labelString: -!!! (Gnus Article mode) Article -> Filter +!! (Gnus Article mode) Article -> Filter ! Emacs*XlwMenu.wordWrap.labelString: Word wrap ! Emacs*XlwMenu.wordWrap.labelString: @@ -1634,7 +1650,7 @@ ! Emacs*XlwMenu.toggleHeader.labelString: Toggle header ! Emacs*XlwMenu.toggleHeader.labelString: -!!! (Gnus Article mode) Article -> Output +!! (Gnus Article mode) Article -> Output ! Emacs*XlwMenu.saveInDefaultFormat.labelString: Save in default format ! Emacs*XlwMenu.saveInDefaultFormat.labelString: @@ -1655,7 +1671,7 @@ ! Emacs*XlwMenu.addToSOUPPacket.labelString: Add to SOUP packet ! Emacs*XlwMenu.addToSOUPPacket.labelString: -!!! (Gnus Article mode) Article -> Backend +!! (Gnus Article mode) Article -> Backend ! Emacs*XlwMenu.respoolArticle___.labelString: Respool article... ! Emacs*XlwMenu.respoolArticle___.labelString: @@ -1676,7 +1692,7 @@ ! Emacs*XlwMenu.deleteExpirableArticles.labelString: Delete expirable articles ! Emacs*XlwMenu.deleteExpirableArticles.labelString: -!!! (Gnus Article mode) Article -> Extract +!! (Gnus Article mode) Article -> Extract ! Emacs*XlwMenu.uudecode.labelString: Uudecode ! Emacs*XlwMenu.uudecode.labelString: @@ -1691,7 +1707,7 @@ ! Emacs*XlwMenu.postscript.labelString: Postscript ! Emacs*XlwMenu.postscript.labelString: -!!! (Gnus Article mode) Threads menu +!! (Gnus Article mode) Threads menu ! Emacs*XlwMenu.toggleThreading.labelString: Toggle threading ! Emacs*XlwMenu.toggleThreading.labelString: @@ -1722,7 +1738,7 @@ ! Emacs*XlwMenu.rethreadCurrent.labelString: Rethread current ! Emacs*XlwMenu.rethreadCurrent.labelString: -!!! (Gnus Article mode) Post menu +!! (Gnus Article mode) Post menu ! Emacs*XlwMenu.postAnArticle.labelString: Post an article ! Emacs*XlwMenu.postAnArticle.labelString: @@ -1755,14 +1771,14 @@ ! Emacs*XlwMenu.customize___.labelString: Customize... ! Emacs*XlwMenu.customize___.labelString: -!!! Message mode main menu +!! Message mode main menu ! Emacs*XlwMenu.message.labelString: Message ! Emacs*XlwMenu.message.labelString: ! Emacs*XlwMenu.mIMEEdit.labelString: MIME-Edit ! Emacs*XlwMenu.mIMEEdit.labelString: -!!! (Message mode) Message menu +!! (Message mode) Message menu ! Emacs*XlwMenu.goToField.labelString: Go to Field: ! Emacs*XlwMenu.goToField.labelString: @@ -1807,7 +1823,7 @@ ! Emacs*XlwMenu.abortMessage.labelString: Abort Message ! Emacs*XlwMenu.abortMessage.labelString: -!!! (Tools for MIME) MIME-editmenu +!! (Tools for MIME) MIME-editmenu ! Emacs*XlwMenu.describeMIMEEditorMode.labelString: Describe MIME editor mode ! Emacs*XlwMenu.describeMIMEEditorMode.labelString: @@ -1853,9 +1869,9 @@ ! Emacs*XlwMenu.toggleTransferLevel.labelString: -!!!! VM +!!! VM -!!! (VM send-mode) Mail menu +!! (VM send-mode) Mail menu ! Emacs*XlwMenu.mail.labelString: Mail ! Emacs*XlwMenu.mail.labelString: @@ -1877,7 +1893,7 @@ ! Emacs*XlwMenu.insertBuffer___.labelString: Insert Buffer... ! Emacs*XlwMenu.insertBuffer___.labelString: -!!! (VM view-mail) Main menu +!! (VM view-mail) Main menu ! Emacs*XlwMenu.folder.labelString: Folder ! Emacs*XlwMenu.folder.labelString: @@ -1894,7 +1910,7 @@ ! Emacs*XlwMenu.xEmacs.labelString: XEmacs ! Emacs*XlwMenu.xEmacs.labelString: -!!! (VM view-mail) Folder menu +!! (VM view-mail) Folder menu ! Emacs*XlwMenu.manipulateFolders.labelString: Manipulate Folders ! Emacs*XlwMenu.manipulateFolders.labelString: @@ -1922,7 +1938,7 @@ ! Emacs*XlwMenu.visit.labelString: Visit: ! Emacs*XlwMenu.visit.labelString: -!!! (VM view-mail) Motion menu +!! (VM view-mail) Motion menu ! Emacs*XlwMenu.pageUp.labelString: Page Up ! Emacs*XlwMenu.pageUp.labelString: @@ -1955,7 +1971,7 @@ ! Emacs*XlwMenu.goToParentMessage.labelString: Go to Parent Message ! Emacs*XlwMenu.goToParentMessage.labelString: -!!! (VM view-mail) Send menu +!! (VM view-mail) Send menu ! Emacs*XlwMenu.compose.labelString: Compose ! Emacs*XlwMenu.compose.labelString: @@ -1979,7 +1995,7 @@ ! Emacs*XlwMenu.sendDigestRFC1153.labelString: Send Digest (RFC1153) ! Emacs*XlwMenu.sendDigestRFC1153.labelString: -!!! (VM view-mail) Mark menu +!! (VM view-mail) Mark menu ! Emacs*XlwMenu.nextCommandUsesMarks___.labelString: Next Command Uses Marks... ! Emacs*XlwMenu.nextCommandUsesMarks___.labelString: @@ -2004,14 +2020,14 @@ ! Emacs*XlwMenu.unmarkThreadSubtree.labelString: Unmark Thread Subtree ! Emacs*XlwMenu.unmarkThreadSubtree.labelString: -!!! (VM view-mail) Label menu +!! (VM view-mail) Label menu ! Emacs*XlwMenu.addLabel.labelString: Add Label ! Emacs*XlwMenu.addLabel.labelString: ! Emacs*XlwMenu.removeLabel.labelString: Remove Label ! Emacs*XlwMenu.removeLabel.labelString: -!!! (VM view-mail) Sort menu +!! (VM view-mail) Sort menu ! Emacs*XlwMenu.byMultipleFields___.labelString: By Multiple Fields... ! Emacs*XlwMenu.byMultipleFields___.labelString: @@ -2042,7 +2058,7 @@ ! Emacs*XlwMenu.revertToPhysicalOrder.labelString: Revert to Physical Order ! Emacs*XlwMenu.revertToPhysicalOrder.labelString: -!!! (VM view-mail) Virtual menu +!! (VM view-mail) Virtual menu ! Emacs*XlwMenu.visitVirtualFolder.labelString: Visit Virtual Folder ! Emacs*XlwMenu.visitVirtualFolder.labelString: @@ -2051,7 +2067,7 @@ ! Emacs*XlwMenu.applyVirtualFolder.labelString: Apply Virtual Folder ! Emacs*XlwMenu.applyVirtualFolder.labelString: -!!! (VM view-mail) Dispose menu +!! (VM view-mail) Dispose menu ! Emacs*XlwMenu.forward.labelString: Forward ! Emacs*XlwMenu.forward.labelString: @@ -2074,7 +2090,7 @@ ! Emacs*XlwMenu.burstMessageAsDigest.labelString: Burst Message as Digest ! Emacs*XlwMenu.burstMessageAsDigest.labelString: -!!! (VM view-mail) Help menu +!! (VM view-mail) Help menu ! Emacs*XlwMenu.whatNow.labelString: What Now? ! Emacs*XlwMenu.whatNow.labelString: @@ -2084,34 +2100,34 @@ ! Emacs*XlwMenu.quitWithoutSaving.labelString: -!!!! W3 +!!! W3 -!!! W3 File Menu +!! W3 File Menu ! Emacs*XlwMenu.view.labelString: View -! Emacs*XlwMenu.view.labelString: +Emacs*XlwMenu.view.labelString: ɽ¼¨ ! Emacs*XlwMenu.bookmark.labelString: Bookmark Emacs*XlwMenu.bookmark.labelString: ¤·¤ª¤ê ! Emacs*XlwMenu.style.labelString: Style -! Emacs*XlwMenu.style.labelString: +Emacs*XlwMenu.style.labelString: ¥¹¥¿¥¤¥ë ! Emacs*XlwMenu.openLocation___.labelString: Open Location... -! Emacs*XlwMenu.openLocation___.labelString: +Emacs*XlwMenu.openLocation___.labelString: »ØÄê¾ì½ê¤ò³«¤¯... ! Emacs*XlwMenu.openFile___.labelString: Open File... -! Emacs*XlwMenu.openFile___.labelString: +Emacs*XlwMenu.openFile___.labelString: ¥Õ¥¡¥¤¥ë¤ò³«¤¯... ! Emacs*XlwMenu.openInNewWindow___.labelString: Open in New Window... Emacs*XlwMenu.openInNewWindow___.labelString: ¿·µ¬¥¦¥£¥ó¥É¥¦¤Ë³«¤¯... ! Emacs*XlwMenu.newWindow.labelString: New Window -! Emacs*XlwMenu.newWindow.labelString: +Emacs*XlwMenu.newWindow.labelString: ¿·µ¬¥¦¥£¥ó¥É¥¦ ! Emacs*XlwMenu.printAs___.labelString: Print As... -! Emacs*XlwMenu.printAs___.labelString: +Emacs*XlwMenu.printAs___.labelString: »ØÄê½ñ¼°¤Ç°õºþ... ! Emacs*XlwMenu.mailDocument___.labelString: Mail Document... -! Emacs*XlwMenu.mailDocument___.labelString: +Emacs*XlwMenu.mailDocument___.labelString: ¥É¥¥å¥á¥ó¥È¤ò¥á¡¼¥ë... ! Emacs*XlwMenu.addAnnotation.labelString: Add Annotation -! Emacs*XlwMenu.addAnnotation.labelString: +Emacs*XlwMenu.addAnnotation.labelString: Ãí¼á¤òÄɲà ! Emacs*XlwMenu.close.labelString: Close -! Emacs*XlwMenu.close.labelString: +Emacs*XlwMenu.close.labelString: ÊĤ¸¤ë -!!! (W3) File -> Save As +!! (W3) File -> Save As ! Emacs*XlwMenu.hTML.labelString: HTML ! Emacs*XlwMenu.hTML.labelString: @@ -2122,24 +2138,24 @@ ! Emacs*XlwMenu.postScript.labelString: PostScript ! Emacs*XlwMenu.postScript.labelString: -!!! (W3) File -> Print As +!! (W3) File -> Print As ! Emacs*XlwMenu.hTMLSource.labelString: HTML Source ! Emacs*XlwMenu.hTMLSource.labelString: ! Emacs*XlwMenu.laTeXD.labelString: LaTeX'd ! Emacs*XlwMenu.laTeXD.labelString: -!!! (W3) File -> Mail Document +!! (W3) File -> Mail Document ! Emacs*XlwMenu.laTeXSource.labelString: LaTeX Source ! Emacs*XlwMenu.laTeXSource.labelString: -!!! (W3) Edit menu +!! (W3) Edit menu ! Emacs*XlwMenu.searchAgain___.labelString: Search Again... ! Emacs*XlwMenu.searchAgain___.labelString: -!!! (W3) View menu +!! (W3) View menu ! Emacs*XlwMenu.documentInformation.labelString: Document Information ! Emacs*XlwMenu.documentInformation.labelString: @@ -2156,7 +2172,7 @@ ! Emacs*XlwMenu.showURLAtPoint.labelString: Show URL At Point ! Emacs*XlwMenu.showURLAtPoint.labelString: -!!! (W3) Go menu +!! (W3) Go menu ! Emacs*XlwMenu.backward.labelString: Backward ! Emacs*XlwMenu.backward.labelString: @@ -2167,18 +2183,20 @@ ! Emacs*XlwMenu.links.labelString: Links ! Emacs*XlwMenu.links.labelString: -!!! (W3) Bookmarks menu +!! (W3) Bookmarks menu ! Emacs*XlwMenu.viewBookmarks___.labelString: View Bookmarks... Emacs*XlwMenu.viewBookmarks___.labelString: ¤·¤ª¤ê¥ê¥¹¥È¤òɽ¼¨... ! Emacs*XlwMenu.addBookmark.labelString: Add Bookmark Emacs*XlwMenu.addBookmark.labelString: ¤·¤ª¤ê¤òÄɲà ! Emacs*XlwMenu.deleteBookmark.labelString: Delete Bookmark +Emacs*XlwMenu.deleteBookmark.labelString: ¤·¤ª¤ê¤òºï½ü ! Emacs*XlwMenu.renameBookmark.labelString: Rename Bookmark +Emacs*XlwMenu.renameBookmark.labelString: ¤·¤ª¤ê¤Î̾¾ÎÊѹ¹ ! Emacs*XlwMenu.appendBookmarkList.labelString: Append Bookmark List Emacs*XlwMenu.appendBookmarkList.labelString: ¤·¤ª¤ê¥ê¥¹¥È¤òÄɲà -!!! (W3) Options menu +!! (W3) Options menu ! Emacs*XlwMenu.editPreferences.labelString: Edit Preferences ! Emacs*XlwMenu.editPreferences.labelString: @@ -2201,7 +2219,7 @@ ! Emacs*XlwMenu.useCacheOnly.labelString: Use Cache Only ! Emacs*XlwMenu.useCacheOnly.labelString: -!!! (W3) Style menu +!! (W3) Style menu ! Emacs*XlwMenu.allowDocumentStylesheets.labelString: Allow Document Stylesheets ! Emacs*XlwMenu.allowDocumentStylesheets.labelString: @@ -2212,7 +2230,7 @@ ! Emacs*XlwMenu.reloadStylesheets.labelString: Reload Stylesheets ! Emacs*XlwMenu.reloadStylesheets.labelString: -!!! (W3) Help menu +!! (W3) Help menu ! Emacs*XlwMenu.aboutEmacsW3.labelString: About Emacs-w3 ! Emacs*XlwMenu.aboutEmacsW3.labelString:
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/etc/xemacs-ja.1 Mon Aug 13 09:36:16 2007 +0200 @@ -0,0 +1,776 @@ +.TH XEMACS 1 "1997 ǯ 3 ·î 11 Æü" +.UC 4 +.SH "̾Á°" +xemacs \- ¼¡À¤Âå Emacs +.SH "·Á¼°" +.B xemacs +[ +.I <¥³¥Þ¥ó¥É¹Ô¥ª¥×¥·¥ç¥ó> +] [ +.I <¥Õ¥¡¥¤¥ë̾>... +] +.br +.\"°Ê²¼¡¢bold ¤Ë¤¹¤Ù¤¥³¥Þ¥ó¥É̾¤Ê¤É¤¬±Ñ¸ì¤Ç¤Ï italic ¤Ë¤Ê¤Ã¤Æ¤¤¤ë¤Î¤Ç¡¢½¤Àµ¡£ +.SH "µ¡Ç½ÀâÌÀ" +.B XEmacs +¤Ï¡¢Free Software Foundation ¤Î Richard Stallman ¤Ë¤è¤Ã¤Æ½ñ¤«¤ì¤¿¤â¤Î¤Ç¡¢ +.B Emacs +¤È¤Î¸ß´¹À¤òÊÝ»ý¤·¤¿¤Þ¤Þ¿¤¯¤Î²þÎɤ¬²Ã¤¨¤é¤ì¤¿¥Ð¡¼¥¸¥ç¥ó¤Ç¤¹¡£ +.B "GNU Emacs " +¥Ð¡¼¥¸¥ç¥ó 19 ¤ÎÁá´ü¥ê¥ê¡¼¥¹¤ò¤â¤È¤Ë³«È¯¤µ¤ì¡¢ +.B "GNU Emacs " +¤Î¸å³¥ê¥ê¡¼¥¹¤ÈƱ´ü¤¬¤È¤é¤ì¤Æ¤¤¤Þ¤¹¡£ +.PP +.B XEmacs +¤Î¼ç¤Ê¥Þ¥Ë¥å¥¢¥ë¤Ï¡¢ +.B XEmacs +¥µ¥Ö¥·¥¹¥Æ¥à¤Î 1 ¤Ä¤Ç¤¢¤ë Info ¤ò»È¤Ã¤Æ¥ª¥ó¥é¥¤¥ó¤Ç»²¾È¤¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +´°À®¤µ¤ì¤¿ºÇ¿·¤Î¥Þ¥Ë¥å¥¢¥ë¤Ï¡¢¤½¤Á¤é¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤ +(¤¿¤À¤·¸½»þÅÀ¤Ç¤Ï¡¢Info ·Á¼°¥É¥¥å¥á¥ó¥È¤Ï±Ñ¸ìÈǤΤߤ¬ÍÑ°Õ¤µ¤ì¤Æ¤¤¤Þ¤¹)¡£ +Emacs Lisp »ÈÍÑÊýË¡¤Ë¤Ä¤¤¤Æ¤Î´°Á´¤Ê¥Þ¥Ë¥å¥¢¥ë¤È¤·¤Æ¤Ï +¡ØXEmacs Lisp Programmer's Manual¡Ù¤ò¡¢ +¥ª¥ó¥é¥¤¥ó¤Ç»²¾È¤¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£¤É¤Á¤é¤Î¥Þ¥Ë¥å¥¢¥ë¤â +.B TeX +½ñ¼°¥Ñ¥Ã¥±¡¼¥¸¤ò»ÈÍѤ¹¤ì¤Ð¡¢¤¤ì¤¤¤Ë°õºþ¤¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +.PP +»ÈÍѤǤ¤ë +.B XEmacs +¤Îµ¡Ç½¤Ï¡¢¤Û¤«¤Î +.B Emacs +¥¨¥Ç¥£¥¿¤Ç¤Ç¤¤ë¤¹¤Ù¤Æ¤Îµ¡Ç½¤¬´Þ¤Þ¤ì¤Æ¤ª¤ê¡¢ +ÊÔ½¸¥³¥Þ¥ó¥É¤Ï Lisp ¤Çµ½Ò¤µ¤ì¤Æ¤¤¤ë¤¿¤á¡¢Íưפ˳ÈÄ¥¤¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +.PP +.B XEmacs +¤Ë¤Ï³ÈÄ¥ÂÐÏ÷¿¥Ø¥ë¥×µ¡Ç½¤¬ÍÑ°Õ¤µ¤ì¤Æ¤¤¤Þ¤¹¤¬¡¢¤³¤Îµ¡Ç½¤ò»ÈÍѤ¹¤ë¤Ë¤Ï¡¢ +.B XEmacs +¥¦¥£¥ó¥É¥¦¤È¥Ð¥Ã¥Õ¥¡¤Ë¤Ä¤¤¤Æ¤Î°·¤¤Êý¤òÃΤäƤ¤¤ë¤³¤È¤¬Á°Äó¤È¤Ê¤ê¤Þ¤¹¡£ +CTRL-h ¤Ç¥Ø¥ë¥×µ¡Ç½¤ò¼Â¹Ô¤·¤Þ¤¹¡£¡ÖXEmacs ¼«½¬½ñ(CTRL-h t)¡×¤Ï¡¢ +½é¿´¼Ô¤¬¿ôʬ´Ö¤Ç +.B XEmacs +¤Î´ðÁäòÃΤ뤳¤È¤¬¤Ç¤¤ëÂÐÏ÷¿¤Î¥Á¥å¡¼¥È¥ê¥¢¥ë¤ò¸Æ¤Ó½Ð¤·¤Þ¤¹¡£ +¡ÖŬÀÚ¸¡º÷...(CTRL-h a)¡×¤Ï¡¢»ØÄꤷ¤¿µ¡Ç½¤ò¼Â¹Ô¤¹¤ë¥³¥Þ¥ó¥É¤ò +õ¤¹¼ê½õ¤±¤ò¤·¤Þ¤¹¡£ +¡Ö¥¡¼/¥Þ¥¦¥¹µ½Ò...(CTRL-h k)¡×¤Ï¡¢»ØÄꤷ¤¿¥¡¼Áàºî¤Î¼Â¹ÔÆâÍƤòɽ¼¨¤·¤Þ¤¹¡£ +¡Ö´Ø¿ôµ½Ò...(CTRL-h f)¡×¤Ï¡¢»ØÄꤷ¤¿Ì¾Á°¤Î Lisp ´Ø¿ô¤òɽ¼¨¤·¤Þ¤¹¡£ +¤µ¤é¤Ë¡Ö¥¡¼/¥Þ¥¦¥¹³ä¤êÅö¤Æ...(CTRL-h CTRL-k)¡×¤ò»ÈÍѤ¹¤ë¤È¡¢ +.B XEmacs +¥ê¥Õ¥¡¥ì¥ó¥¹¥Þ¥Ë¥å¥¢¥ë¾å¤Î¥¡¼Áàºî¤ò»²¾È¤Ç¤¡¢ +¡ÖElisp ´Ø¿ô...(CTRL-h CTRL-f)¡×¤ò»ÈÍѤ¹¤ë¤È¡¢ +¡ØXEmacs Lisp Programmer's Manual¡Ù¾å¤Î Lisp ´Ø¿ô¤ò»²¾È¤Ç¤¤Þ¤¹¡£ +¥æ¡¼¥¶¡¼¤¬¥¦¥£¥ó¥É¥¦¥·¥¹¥Æ¥à¤ò»ÈÍѤ·¤Æ¤¤¤ë¾ì¹ç¤Ï¡¢ +¤³¤ì¤é¤Î¥Ø¥ë¥×µ¡Ç½¤Ï¤¹¤Ù¤Æ¥Ø¥ë¥×¥á¥Ë¥å¡¼¤«¤é»ÈÍѤ¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +.PP +Ê£¿ô¥Õ¥ì¡¼¥à(¥È¥Ã¥×¥ì¥Ù¥ë¥¦¥£¥ó¥É¥¦)¡¢¥á¥Ë¥å¡¼¥Ð¡¼¡¢¥Ä¡¼¥ë¥Ð¡¼¡¢ +¿åÊ¿¡¦¿âľ¥¹¥¯¥í¡¼¥ë¥Ð¡¼¡¢¥À¥¤¥¢¥í¥°¥Ü¥Ã¥¯¥¹¡¢³ÈÄ¥¥Þ¥¦¥¹µ¡Ç½ +¤Ê¤É¤ò»ý¤Ä X ¤Î¤è¤¦¤Ê¥¦¥£¥ó¥É¥¦¥·¥¹¥Æ¥à´Ä¶²¼¤Ç¤Ï¡¢ +.B XEmacs +¤Ï +³ÈÄ¥ GUI(¥°¥é¥Õ¥£¥«¥ë¥æ¡¼¥¶¡¼¥¤¥ó¥¿¥Õ¥§¡¼¥¹)¤ò¥µ¥Ý¡¼¥È¤·¤Þ¤¹¡£ +.PP +.B XEmacs +¤Ï¡¢Ê£¿ô¤Î¥Õ¥©¥ó¥È¤ä¥«¥é¡¼¡¢²ÄÊÑÉý¥Õ¥©¥ó¥È¡¢²ÄÊѹԴֳ֤ò +´°Á´¤Ë¥µ¥Ý¡¼¥È¤·¤Æ¤ª¤ê¡¢ +¥Ô¥Ã¥¯¥¹¥Þ¥Ã¥×¤ò¥Ð¥Ã¥Õ¥¡¤Ë¼è¤ê¹þ¤à¤³¤È¤â²Äǽ¤Ç¤¹ +(¤³¤ì¤ÏÆäˡ¢W3 Web ¥Ö¥é¥¦¥¸¥ó¥°¥Ñ¥Ã¥±¡¼¥¸¤ä°ìÉô¤Î +¥Ç¥Ð¥Ã¥¬¡¢¥¢¥¦¥È¥é¥¤¥óµ¡Ç½¤Î¥¤¥ó¥¿¥Õ¥§¡¼¥¹¤ËÍѤ¤¤é¤ì¤Þ¤¹)¡£ +.PP +.B XEmacs +¤Î¡Ö¸µ¤ËÌ᤹¡×¤Ï¡¢¥Ð¥Ã¥Õ¥¡¤ËÈ¿±Ç¤µ¤ì¤¿¿ô¥¹¥Æ¥Ã¥×Á°¤Þ¤Ç¤ÎÊѹ¹¤ò +¼è¤ê¾Ã¤¹¤³¤È¤¬¤Ç¤¡¢ÊÔ½¸¤Î¥ß¥¹¤ò´Êñ¤Ë½¤Éü¤¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +.PP +.B XEmacs +¤Ë¤Ï¡¢Â¿¤¯¤ÎÀìÍѥѥ屡¼¥¸¤¬ÍÑ°Õ¤µ¤ì¤Æ¤¤¤Þ¤¹¡£¥á¡¼¥ë¤ÎÆɤ߽Ф· (VM¡¢MH-E¡¢ +RMail) ¤äȯ¿® (Mail)¡¢¥Í¥Ã¥È¥Ë¥å¡¼¥¹¤ÎÆɤ߽Ф·¤ÈÅêÈ¡ (GNUS)¡¢ +World Wide Web ¤Î¥Ö¥é¥¦¥º (W3)¡¢¤¹¤Ù¤Æ¤Î¼çÍ×¤Ê¥×¥í¥°¥é¥ß¥ó¥°¸À¸ì¤Ë +¤Ç½ñ¤«¤ì¤¿¥½¡¼¥¹¥³¡¼¥É¤òÊÔ½¸¤¹¤ë¤¿¤á¤ÎÆò½¤µ¤ì¤¿¥â¡¼¥É¡¢ +¿¤¯¤Î¸À¸ìÍѤι½Ê¸¶¯Ä´É½¼¨ (Font-Lock)¡¢¥³¥ó¥Ñ¥¤¥ë (Compile)¡¢ +.B XEmacs +¥¦¥£¥ó¥É¥¦Æâ¤ÇÆ°ºî¤¹¤ë¥µ¥Ö¥·¥§¥ë (Shell)¡¢¥¢¥¦¥È¥é¥¤¥óÊÔ½¸ (Outline)¡¢ +Lisp ¤Î¡ÖÆɤ߹þ¤ß¡¢É¾²Á¡¢É½¼¨¡×¥ë¡¼¥×¤Î¼Â¹Ô (Lisp-Interaction-Mode)¡¢ +¥²¡¼¥àÀº¿ÀʬÀÏ°å (Doctor) ¤Ê¤É¤Ç¤¹¡£ +.PP +¾ÜºÙ¤Ê¥ê¥Õ¥¡¥ì¥ó¥¹¥Þ¥Ë¥å¥¢¥ë¤Ï¤¢¤ê¤Þ¤¹¤¬¡¢ +¾¤Î¥Ð¡¼¥¸¥ç¥ó¤Î Emacs ¤ò»ÈÍѤ·¤¿¤³¤È¤¬¤¢¤ì¤Ð¡¢ +¥Þ¥Ë¥å¥¢¥ë¤Ê¤·¤Ç¤âÌäÂê¤Ê¤¯Âбþ¤Ç¤¤ë¤È»×¤ï¤ì¤Þ¤¹¡£ +½é¤á¤Æ Emacs ¤ò»ÈÍѤ¹¤ë¿Í¤Ç¤â¡¢¥Á¥å¡¼¥È¥ê¥¢¥ë¤ò³Ø½¬¤·¤¿¤ê¼«Æ° +¥Þ¥Ë¥å¥¢¥ëµ¡Ç½¤òÍøÍѤ¹¤ë¤³¤È¤Ç¡¢¤¹¤°¤Ë´ðËܵ¡Ç½¤ò»È¤¦¤³¤È¤¬¤Ç¤¤ë¤è¤¦¤Ë +¤Ê¤ë¤Ç¤·¤ç¤¦¡£ +.PP +.SM "XEmacs ¥ª¥×¥·¥ç¥ó" +.PP +XEmacs ¤Ï¡¢X ¥¦¥£¥ó¥É¥¦¤¬Æ°ºî¤¹¤ë´Ä¶²¼¤Ç¤Ï¡¢¤¹¤Ù¤Æ¤Îɸ½à X ¥Ä¡¼¥ë¥¥Ã¥È¤Î +¥³¥Þ¥ó¥É¥ª¥×¥·¥ç¥ó¤òǧ¼±¤·¤Þ¤¹¡£¤½¤ì¤Ë²Ã¤¨¤Æ¡¢°Ê²¼¤Î¥ª¥×¥·¥ç¥ó¤òǧ¼± +¤·¤Þ¤¹ +(¥ª¥×¥·¥ç¥ó¤¬°ìÏ¢¤ÎÊ£¿ô¤Î½èÍý¤ò°ÕÌ£¤¹¤ë¾ì¹ç¤Ï¡¢»ØÄꤵ¤ì¤¿½ç¤Ë¼Â¹Ô¤µ¤ì¤Þ¤¹)¡£ +.TP +.BI \-t " ¥Ç¥Ð¥¤¥¹Ì¾" +»ÈÍÑÃæ¤Îɸ½àÆþ½ÐÎϤÎÂå¤ï¤ê¤Ë¡¢»ØÄꤵ¤ì¤¿¥Ç¥Ð¥¤¥¹¤ò»È¤¤¤Þ¤¹¡£¤³¤ì¤Ï +.BR \-nw +¥ª¥×¥·¥ç¥ó¤ò´Þ°Õ¤·¤Æ¤¤¤Þ¤¹¡£ +.TP +.BI \-batch +¥Ð¥Ã¥Á¥â¡¼¥É¤ÇÊÔ½¸¤ò¹Ô¤¤¤Þ¤¹¡£¥¨¥Ç¥£¥¿¤Ïɸ½à½ÐÎϤ˥á¥Ã¥»¡¼¥¸¤òÁ÷½Ð¤·¤Þ¤¹¡£ +¼Â¹Ô¥Õ¥¡¥¤¥ë¤ò»ØÄꤷ¤¿¤ê´Ø¿ô¤ò¸Æ¤Ó½Ð¤¹¾ì¹ç¤Ï¡¢É¬¤º +.BR \-l +¡¢ +.BR \-f +¡¢ +.B \-eval +¥ª¥×¥·¥ç¥ó¤ò»ÈÍѤ·¤Æ¤¯¤À¤µ¤¤¡£ +.TP +.B \-nw\ +¥¦¥£¥ó¥É¥¦¥·¥¹¥Æ¥àÆÃͤÎɽ¼¨ÍÑ¥³¡¼¥É¤Î»ÈÍѤò¤¹¤Ù¤Æ¶Ø»ß¤·¤Þ¤¹¡£ +¸½ºß¤Î TTY ¤ò»ÈÍѤ·¤Þ¤¹¡£ +.TP +.B \-debug\-init +½é´ü²½¥Õ¥¡¥¤¥ë¤ÎÆɤ߹þ¤ßÃæ¤Ë¥¨¥é¡¼¤¬È¯À¸¤·¤¿¾ì¹ç¡¢¥Ç¥Ð¥Ã¥¬¤òµ¯Æ°¤·¤Þ¤¹¡£ +.TP +.B \-unmapped +½é´ü¥Õ¥ì¡¼¥à¤ò¥Þ¥Ã¥Ô¥ó¥°¤·¤Þ¤»¤ó¡£ +.TP +.B \-no\-site\-file +¥µ¥¤¥È¸Çͤνé´ü²½¥Õ¥¡¥¤¥ë(site-init.el)¤òÆɤ߹þ¤ß¤Þ¤»¤ó¡£ +.TP +.BR \-q "¡¢" \-no\-init\-file +½é´ü²½¥Õ¥¡¥¤¥ë¤òÆɤ߹þ¤ß¤Þ¤»¤ó¡£ +.TP +.BI \-u " ¥æ¡¼¥¶¡¼Ì¾¡¢" \-user " ¥æ¡¼¥¶¡¼Ì¾" +»ØÄꤷ¤¿¥æ¡¼¥¶¡¼¸Çͤνé´ü²½¥Õ¥¡¥¤¥ë¤òÆɤ߹þ¤ß¤Þ¤¹¡£ +.TP +.I ¥Õ¥¡¥¤¥ë̾ +»ØÄꤷ¤¿¥Õ¥¡¥¤¥ë¤òÊÔ½¸¤·¤Þ¤¹¡£ +.TP +.BI \+ "¹ÔÈÖ¹æ" +.I ¹ÔÈÖ¹æ +¤Ë»ØÄꤷ¤¿¹Ô¤Ë°ÜÆ°¤·¤Þ¤¹ +.br +(+ Éä¹æ¤È¹ÔÈÖ¹æ¤Î´Ö¤Ë¶õÇòʸ»ú¤ÏÆþ¤ì¤Ê¤¤¤Ç¤¯¤À¤µ¤¤)¡£ +.TP +.BR \-help "¡¢" \-flags "¡¢" \-? +¥Ø¥ë¥×¥á¥Ã¥»¡¼¥¸¤ò½ÐÎϤ·¤Æ½ªÎ»¤·¤Þ¤¹¡£ +.TP +.BR \-V "¡¢" \-version +¥Ð¡¼¥¸¥ç¥óÈÖ¹æ¤ò½ÐÎϤ·¤Æ½ªÎ»¤·¤Þ¤¹¡£ +.TP +.BI \-f " ´Ø¿ô̾¡¢ " \-funcall " ´Ø¿ô̾" +.I "´Ø¿ô̾ " +¤Ë»ØÄꤷ¤¿ Lisp ´Ø¿ô¤ò¼Â¹Ô¤·¤Þ¤¹¡£ +.TP +.BI \-l " ¥Õ¥¡¥¤¥ë̾¡¢ " \-load " ¥Õ¥¡¥¤¥ë̾" +.I ¥Õ¥¡¥¤¥ë̾ +¤Ë»ØÄꤷ¤¿¥Õ¥¡¥¤¥ëÃæ¤Î Lisp ¥³¡¼¥É¤òÆɤ߹þ¤ß¤Þ¤¹¡£ +.TP +.BI \-eval " ¥Õ¥©¡¼¥à" +.I ¥Õ¥©¡¼¥à +¤Ë»ØÄꤷ¤¿ Lisp ¤Î¥Õ¥©¡¼¥à¤òɾ²Á¤·¤Þ¤¹¡£ +.TP +.BI \-i " ¥Õ¥¡¥¤¥ë̾¡¢" \-insert " ¥Õ¥¡¥¤¥ë̾" +¸½ºß¤Î¥Ð¥Ã¥Õ¥¡¤Ë¡¢ +.I ¥Õ¥¡¥¤¥ë̾ +¤Ë»ØÄꤷ¤¿¥Õ¥¡¥¤¥ë¤ò¼è¤ê¹þ¤ß¤Þ¤¹¡£ +.TP +.B \-kill +.B XEmacs +¤ò½ªÎ»¤·¤Þ¤¹( +.BR \-batch +¤Ç͸ú¤Ç¤¹)¡£ +.PP +.SM "X ¤Ç¤Î XEmacs ¤Î»ÈÍÑ" +.PP +.B XEmacs +¤Ï¡¢X ¥¦¥£¥ó¥É¥¦¥·¥¹¥Æ¥à¾å¤ÇÀµ¤·¤¯Æ°ºî¤¹¤ë¤è¤¦¤Ë³«È¯¤µ¤ì¤Æ¤¤Þ¤·¤¿¡£ +X ¥¦¥£¥ó¥É¥¦¤Ç +.B XEmacs +¤òµ¯Æ°¤¹¤ë¤È¡¢¥Ç¥£¥¹¥×¥ì¥¤Æâ¤ËÆȼ«¤Î X ¥¦¥£¥ó¥É¥¦¤ò³«¤¤Þ¤¹¡£ +¥æ¡¼¥¶¡¼¤Î¥ª¥ê¥¸¥Ê¥ë¤Î¥¦¥£¥ó¥É¥¦¤ò¤½¤Î¤Þ¤Þ»È¤¤Â³¤±¤ë¤³¤È¤¬¤Ç¤¤ë¤è¤¦¤Ë¡¢ +¥¨¥Ç¥£¥¿¤Ï¥Ð¥Ã¥¯¥°¥é¥¦¥ó¥É¤Î¥¸¥ç¥Ö¤È¤·¤Æµ¯Æ°¤·¤¿¤Û¤¦¤¬¤è¤¤¤Ç¤·¤ç¤¦¡£ +.PP +.B XEmacs +¤Ï¡¢°Ê²¼¤Îɸ½à X ¥ª¥×¥·¥ç¥ó¤òÉÕ¤±¤Æµ¯Æ°¤¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +.TP +.BI \-geometry " ##x##+##+##" +½é´ü¥¦¥£¥ó¥É¥¦¤Î¥¸¥ª¥á¥È¥ê¤ò»ØÄꤷ¤Þ¤¹¡£## ¤Ë¤Ï¡¢Éý(ʸ»ú¿ô)¡¢ +¹â¤µ(ʸ»ú¿ô)¡¢X ¥ª¥Õ¥»¥Ã¥È(¥Ô¥¯¥»¥ë¿ô)¡¢Y ¥ª¥Õ¥»¥Ã¥È(¥Ô¥¯¥»¥ë¿ô) +¤ò¿ô»ú¤Ç»ØÄꤷ¤Æ¤¯¤À¤µ¤¤¡£ +.I ##x## +¤ä +.I +##+## +¤Ê¤É¤Î½ñ¼°¤ÎÉôʬ»ØÄê¤â͸ú¤Ç¤¹¡£(¥¸¥ª¥á¥È¥ê»ÅÍͤϡ¢É¸½à X ¥Õ¥©¡¼¥Þ¥Ã¥È¤Ë +½àµò¤·¤Æ¤¤¤Þ¤¹¡£¾ÜºÙ¤Ï +.BR X (1) +¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£) +.TP +.B \-iconic +µ¯Æ°»þ¤Î½é´ü¥¦¥£¥ó¥É¥¦¤ò¥¢¥¤¥³¥ó¤Çɽ¼¨¤·¤Þ¤¹¡£ +.TP +.BI \-name " ¥×¥í¥°¥é¥à̾" +¥æ¡¼¥¶¡¼¤Î X ¥ê¥½¡¼¥¹Æâ¤Ë¤¢¤ë¥Ç¥Õ¥©¥ë¥È¤ò»²¾È¤¹¤ë¤¿¤á¤Ë»ÈÍѤµ¤ì¤ë +¥×¥í¥°¥é¥à̾¤ò»ØÄꤷ¤Þ¤¹¡£ +.TP +.BI \-title " ¥¿¥¤¥È¥ë̾¡¢" \-T " ¥¿¥¤¥È¥ë̾¡¢" \-wn " ¥¿¥¤¥È¥ë̾" +.B XEmacs +¥¦¥£¥ó¥É¥¦¤Î¥¿¥¤¥È¥ë̾¤ò»ØÄꤷ¤Þ¤¹¡£ +.TP +.BI \-d " ¥Ç¥£¥¹¥×¥ì¥¤Ì¾¡¢" \-display " ¥Ç¥£¥¹¥×¥ì¥¤Ì¾" +.IR ¥Ç¥£¥¹¥×¥ì¥¤Ì¾ +¤Ë»ØÄꤷ¤¿¥Ç¥£¥¹¥×¥ì¥¤¾å¤Ë +.B XEmacs +¥¦¥£¥ó¥É¥¦¤òºîÀ®¤·¤Þ¤¹¡£ +¤³¤Î¥ª¥×¥·¥ç¥ó¤Ï¡¢¥³¥Þ¥ó¥É¹Ô¤ÇºÇ½é (ÀèƬ) ¤Ë»ØÄꤷ¤Æ¤¯¤À¤µ¤¤¡£ +.TP +.BI \-font " ¥Õ¥©¥ó¥È̾¡¢" \-fn " ¥Õ¥©¥ó¥È̾" +.B XEmacs +¥¦¥£¥ó¥É¥¦¤Î¥Õ¥©¥ó¥È¤È¤·¤Æ¡¢ +.I ¥Õ¥©¥ó¥È̾ +¤Ë»ØÄꤷ¤¿¥Õ¥©¥ó¥È¤ò»ÈÍѤ·¤Þ¤¹¡£X ¥Õ¥©¥ó¥È¤Ï +.B "/usr/lib/X11/fonts" +¥Ç¥£¥ì¥¯¥È¥ê¤«¤éÁªÂò¤·¤Æ¤¯¤À¤µ¤¤¡£ +.B XEmacs +¤Ï¡¢¸ÇÄêÉý¥Õ¥©¥ó¥È¤È²ÄÊÑÉý¥Õ¥©¥ó¥È¤Î¤É¤Á¤é¤Ç¤âÆ°ºî¤·¤Þ¤¹¤¬¡¢ +¸ÇÄêÉý¥Õ¥©¥ó¥È¤ò»ÈÍѤ¹¤ë¤³¤È¤ò¤ª´«¤á¤·¤Þ¤¹¡£ +.TP +.BI \-scrollbar\-width " ¥Ô¥¯¥»¥ë¿ô" +¿âľ¥¹¥¯¥í¡¼¥ë¥Ð¡¼¤ÎÉý¤ò»ØÄꤷ¤Þ¤¹¡£ +.TP +.BI \-scrollbar\-height " ¥Ô¥¯¥»¥ë¿ô" +¿åÊ¿¥¹¥¯¥í¡¼¥ë¥Ð¡¼¤Î¹â¤µ¤ò»ØÄꤷ¤Þ¤¹¡£ +.TP +.BI \-bw " ¥Ô¥¯¥»¥ë¿ô¡¢ " \-borderwidth " ¥Ô¥¯¥»¥ë¿ô" +.B XEmacs +¥¦¥£¥ó¥É¥¦¤Î¶³¦Éý¤ò»ØÄꤷ¤Þ¤¹¡£ +¥¦¥£¥ó¥É¥¦Î¾Â¦¤Î¥Ç¥Õ¥©¥ë¥ÈÃÍ¤Ï 1 ¥Ô¥¯¥»¥ë¤Ç¤¹¡£ +.TP +.BI \-ib " ¥Ô¥¯¥»¥ë¿ô¡¢ " \-internal\-border\-width " ¥Ô¥¯¥»¥ë¿ô" +¥Õ¥ì¡¼¥à¤Î¶³¦¤È¥Æ¥¥¹¥È¤È¤Î´Ö³Ö¤ò»ØÄꤷ¤Þ¤¹¡£ +¥¦¥£¥ó¥É¥¦Î¾Â¦¤Î¥Ç¥Õ¥©¥ë¥ÈÃÍ¤Ï 1 ¥Ô¥¯¥»¥ë¤Ç¤¹¡£ +.TP +.BI \-fg " ¥«¥é¡¼Ì¾¡¢ " \-foreground " ¥«¥é¡¼Ì¾" +¥Æ¥¥¹¥È¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£¥«¥é¡¼Ì¾¤Ë¤Ä¤¤¤Æ¤Ï¡¢ +.B "/usr/lib/X11/rgb.txt" +¥Õ¥¡¥¤¥ëÃæ¤Î¥ê¥¹¥È¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ +.TP +.BI \-bg " ¥«¥é¡¼Ì¾¡¢ " \-background " ¥«¥é¡¼Ì¾" +¥¦¥£¥ó¥É¥¦¤ÎÇطʤ理òÀßÄꤷ¤Þ¤¹¡£ +.TP +.BI \-bd " ¥«¥é¡¼Ì¾¡¢ " \-bordercolor " ¥«¥é¡¼Ì¾" +¥¦¥£¥ó¥É¥¦¶³¦¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.BI \-mc " ¥«¥é¡¼Ì¾" +¥Þ¥¦¥¹¥Ý¥¤¥ó¥¿¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.BI \-cr " ¥«¥é¡¼Ì¾" +¥Æ¥¥¹¥È¥«¡¼¥½¥ë¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.BR \-rv "¡¢" \-reverse +Á°·Ê¤ÈÇطʤ理òȿž¤·¤Þ¤¹(ȿžɽ¼¨)¡£ +¤³¤Î¥ª¥×¥·¥ç¥ó¤ò»ÈÍѤ»¤º¤Ë¡¢ +Á°·Ê¿§¤ÈÇØ·Ê¿§¤òÌÀ¼¨Åª¤ËÀßÄꤹ¤ë¤³¤È¤ò¤ª´«¤á¤·¤Þ¤¹¡£ +.TP +.BI \-xrm " °ú¿ô" +¥³¥Þ¥ó¥É¹Ô¤ÇǤ°Õ¤Î¥ê¥½¡¼¥¹¤òÀßÄꤹ¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +.B \.Xresource +¤ä +.B \.Xdefaults +¥Õ¥¡¥¤¥ëÃæ¤Ë»ØÄꤵ¤ì¤ë¤Î¤ÈƱÍͤˡ¢ +.I °ú¿ô +¤Ë»ØÄꤷ¤¿Ãͤ¬¥ê¥½¡¼¥¹¤È¤·¤Æ²ò¼á¤µ¤ì¤Þ¤¹¡£ +.PP +¥æ¡¼¥¶¡¼¤Ï¡¢¤¿¤È¤¨¤Ð +.B \.Xresources +¤ä +.B \.Xdefaults +¥Õ¥¡¥¤¥ë¤Ç¡¢ +.B XEmacs +¥¦¥£¥ó¥É¥¦ÍѤΥ꥽¡¼¥¹¤Î¥Ç¥Õ¥©¥ë¥ÈÃͤòÀßÄꤹ¤ë¤³¤È¤â¤Ç¤¤Þ¤¹( +.BR xrdb (1) +»²¾È)¡£ +½ñ¼°¤Ï°Ê²¼¤Î¤è¤¦¤Ë¤Ê¤ê¤Þ¤¹¡£ +.IP +\f3Emacs.\f2¥¡¼¥ï¡¼¥É\f3:\f2ÃÍ\f1 +.PP +¤Þ¤¿¤Ï +.IP +\f3Emacs*EmacsFrame.\f2¥¡¼¥ï¡¼¥É\f3:\f2ÃÍ\f1 +.PP +¤Ç¤¹ (¤É¤Á¤é¤Î·Á¼°¤«¤Ï¡¢¥ê¥½¡¼¥¹¤Ë¤è¤ë)¡£ +.PP +°Ê²¼¤Î½ñ¼°¤ò»ÈÍѤ·¤Æ¡¢ÆÃÄê¤Î¥Õ¥ì¡¼¥à¤Î¥ê¥½¡¼¥¹¤òÀßÄꤹ¤ë¤³¤È¤â¤Ç¤¤Þ¤¹¡£ +.IP +\f3Emacs*\f2¥Õ¥ì¡¼¥à̾\f3.\f2¥¡¼¥ï¡¼¥É\f3:\f2ÃÍ\f1 +.PP +(VM ¤Î¤è¤¦¤Ê´°À®¤µ¤ì¤¿¥Ñ¥Ã¥±¡¼¥¸¤Ï¡¢¤½¤ì¤é¤Î¥Õ¥ì¡¼¥à¤Ë¸ÇͤΠ+¥ê¥½¡¼¥¹Ì¾¤òÍ¿¤¨¤Þ¤¹¡£¤³¤Î¾ì¹ç¤Ï VM ¤Ë¤Ê¤ê¤Þ¤¹¡£) +.PP +.B XEmacs +¤Ç¤Ï¡¢°Ê²¼¤Î¥¡¼¥ï¡¼¥É¤ËÂФ¹¤ë¥Ç¥Õ¥©¥ë¥ÈÀßÄê¤ò¥æ¡¼¥¶¡¼¤¬¹Ô¤¦¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +.TP +.B default.attributeFont (\fPclass\fB Face.AttributeFont) +¥¦¥£¥ó¥É¥¦¤Î¥Æ¥¥¹¥È¥Õ¥©¥ó¥È¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B default.attributeForeground (\fPclass\fB Face.AttributeForeground) +¥¦¥£¥ó¥É¥¦¥Æ¥¥¹¥È¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B default.attributeBackground (\fPclass\fB Face.AttributeBackground) +¥¦¥£¥ó¥É¥¦¤ÎÇØ·Ê¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B \fI¥Õ¥§¥¤¥¹\fB.attributeFont (\fPclass\fB Face.AttributeFont) +¥Õ¥§¥¤¥¹Ì¾¤Î¥Õ¥©¥ó¥È¤òÀßÄꤷ¤Þ¤¹¡£ +¤è¤¯»ÈÍѤµ¤ì¤ë¥Õ¥§¥¤¥¹Ì¾¤ò¡¢°Ê²¼¤Ë¼¨¤·¤Þ¤¹¡£ +.PP +.in +\w'right-margin'u+12n +.ta \w'right-margin'u+4n +.ti -\w'right-margin'u+4n +¥Õ¥§¥¤¥¹ ÌÜŪ +.br +.ti -\w'right-margin'u+4n +default Ä̾ï¤Î¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +bold ¥Ü¡¼¥ë¥É (ÂÀ»ú) ¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +italic ¥¤¥¿¥ê¥Ã¥¯ (¼ÐÂÎ) ¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +bold-italic ¥Ü¡¼¥ë¥É¥¤¥¿¥ê¥Ã¥¯¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +modeline ¥â¡¼¥É¹Ô¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +zmacs-region ¥Þ¥¦¥¹ÁªÂò¤µ¤ì¤¿¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +highlight ¥Þ¥¦¥¹Ä̲á»þ¤Î¶¯Ä´¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +left-margin º¸¥Þ¡¼¥¸¥óÆâ¤Î¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +right-margin ±¦¥Þ¡¼¥¸¥óÆâ¤Î¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +isearch ¸¡º÷»þ¤Î¶¯Ä´¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +info-node Info ¥á¥Ë¥å¡¼¤Î¥Æ¥¥¹¥È¡£ +.br +.ti -\w'right-margin'u+4n +info-xref Info Áê¸ß»²¾È¤Î¥Æ¥¥¹¥È¡£ +.TP +.B \fI¥Õ¥§¥¤¥¹\fB.attributeForeground(\f1class\fB Face.AttributeForeground) +»ØÄê¥Õ¥§¥¤¥¹ÍѤÎÁ°·Ê¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B \fI¥Õ¥§¥¤¥¹\fB.attributeBackground(\f1class\fB Face.AttributeBackground) +»ØÄê¥Õ¥§¥¤¥¹ÍѤÎÇØ·Ê¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B \fI¥Õ¥§¥¤¥¹\fB.attributeBackgroundPixmap +.B (\f1class\fB Face.AttributeBackgroundPixmap)\f1 +.br +»ØÄê¥Õ¥§¥¤¥¹ÍѤÎÇطʥԥ寥¹¥Þ¥Ã¥×¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B \fI¥Õ¥§¥¤¥¹\fB.attributeUnderline (\f1class\fB Face.AttributeUnderline) +»ØÄê¥Õ¥§¥¤¥¹ÍѤβ¼Àþ¤ÎÍ̵¤ò·è¤á¤Þ¤¹¡£ +.TP +.B reverseVideo (\f1class\fB ReverseVideo) +.IR on +¤ËÀßÄꤵ¤ì¤¿¾ì¹ç¤Ï¡¢¥¦¥£¥ó¥É¥¦¤Ïȿžɽ¼¨¤·¤Þ¤¹¡£ +¤³¤Î¥ê¥½¡¼¥¹¤ò»ÈÍѤ»¤º¤Ë¡¢Á°·Ê¿§¤ÈÇØ·Ê¿§¤ò +ÌÀ¼¨Åª¤ËÀßÄꤹ¤ë¤³¤È¤ò¤ª´«¤á¤·¤Þ¤¹¡£ +.TP +.B borderWidth (\fPclass\fB BorderWidth) +¥¦¥£¥ó¥É¥¦¤Î¶³¦Éý¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +.TP +.B internalBorderWidth (\fPclass\fB InternalBorderWidth) +¥¦¥£¥ó¥É¥¦¤ÎÆ⦶³¦Éý¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +.TP +.B borderColor (\fPclass\fB BorderColor) +¥¦¥£¥ó¥É¥¦¶³¦¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B cursorColor (\fPclass\fB Foreground) +¥¦¥£¥ó¥É¥¦¤Î¥Æ¥¥¹¥È¥«¡¼¥½¥ë¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B pointerColor (\fPclass\fB Foreground) +¥¦¥£¥ó¥É¥¦¤Î¥Þ¥¦¥¹¥«¡¼¥½¥ë¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B geometry (\fPclass\fB Geometry) +.B XEmacs +¥¦¥£¥ó¥É¥¦¤Î¥¸¥ª¥á¥È¥ê¤òÀßÄꤷ¤Þ¤¹(¾å½Ò)¡£ +.TP +.B iconic (\fPclass\fB Iconic) +on ¤ËÀßÄꤵ¤ì¤Æ¤¤¤ë¾ì¹ç¤Ï¡¢ +.B XEmacs +¥¦¥£¥ó¥É¥¦¤ÏºÇ½é¤Ë¥¢¥¤¥³¥ó²½¤µ¤ì¤Æɽ¼¨¤µ¤ì¤Þ¤¹¡£ +.TP +.B menubar (\fPclass\fB Menubar) +.B XEmacs +¥¦¥£¥ó¥É¥¦¤Ë¥á¥Ë¥å¡¼¥Ð¡¼¤òɽ¼¨¤µ¤»¤ë¤«¤É¤¦¤«¤òÀßÄꤷ¤Þ¤¹¡£½é´üÃÍ¤Ï true ¤Ç¤¹¡£ +.TP +.B initiallyUnmapped (\fPclass\fB InitiallyUnmapped) +.B XEmacs +¤¬µ¯Æ°»þ¤Ë¥¢¥ó¥Þ¥Ã¥×¤µ¤ì¤¿½é´ü¥Õ¥ì¡¼¥à¤ò»Ä¤¹¤«¤É¤¦¤«¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B barCursor (\fPclass\fB BarCursor) +¥«¡¼¥½¥ë¤Î·Á¾õ¤ò¡¢È¢·¿¤Þ¤¿¤Ï¥Ð¡¼¤ËÀßÄꤷ¤Þ¤¹¡£ +.TP +.B title (\fPclass\fB Title) +.B XEmacs +¥¦¥£¥ó¥É¥¦¤Î¥¿¥¤¥È¥ë̾¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B iconName (\fPclass\fB Title) +.B XEmacs +¥¦¥£¥ó¥É¥¦¥¢¥¤¥³¥ó¤Î̾Á°¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B scrollBarWidth (\fPclass\fB ScrollBarWidth) +¿âľ¥¹¥¯¥í¡¼¥ë¥Ð¡¼¤ÎÉý¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +Ãͤò 0 ¤Ë¤¹¤ë¤È¡¢¿âľ¥¹¥¯¥í¡¼¥ë¥Ð¡¼¤Ïɽ¼¨¤µ¤ì¤Þ¤»¤ó¡£ +.TP +.B scrollBarHeight (\fPclass\fB ScrollBarHeight) +¿åÊ¿¥¹¥¯¥í¡¼¥ë¥Ð¡¼¤Î¹â¤µ¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +Ãͤò 0 ¤Ë¤¹¤ë¤È¡¢¿åÊ¿¥¹¥¯¥í¡¼¥ë¥Ð¡¼¤Ïɽ¼¨¤µ¤ì¤Þ¤»¤ó¡£ +.TP +.B scrollBarPlacement (\fPclass\fB ScrollBarPlacement) +¿âľ¡¦¿åÊ¿¥¹¥¯¥í¡¼¥ë¥Ð¡¼¤Î°ÌÃÖ¤òÀßÄꤷ¤Þ¤¹¡£"top-left"¡¢"bottom-left"¡¢ +"top-right"¡¢"bottom-right"¤Î¤¤¤º¤ì¤«¤òÁªÂò¤·¤Þ¤¹¡£ +¥Ç¥Õ¥©¥ë¥È¤Ç¤Ï¡¢Motif ¤È Lucid ÍÑ¤Ë¤Ï "bottom-right" ¤¬¡¢ +Athena ÍÑ¤Ë¤Ï "buttom-left" ¤¬ÀßÄꤵ¤ì¤Æ¤¤¤Þ¤¹¡£ +.TP +.B topToolBarHeight (\fPclass\fB TopToolBarHeight) +¾åÉô¤Î¥Ä¡¼¥ë¥Ð¡¼¤Î¹â¤µ¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +Ãͤò 0 ¤Ë¤¹¤ë¤È¡¢¥Ä¡¼¥ë¥Ð¡¼¤Ïɽ¼¨¤µ¤ì¤Þ¤»¤ó¡£ +.TP +.B bottomToolBarHeight (\fPclass\fB BottomToolBarHeight) +²¼Éô¥Ä¡¼¥ë¥Ð¡¼ ¤Î¹â¤µ¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +Ãͤò 0 ¤Ë¤¹¤ë¤È¡¢²¼Éô¥Ä¡¼¥ë¥Ð¡¼¤Ïɽ¼¨¤µ¤ì¤Þ¤»¤ó¡£ +.TP +.B leftToolBarWidth (\fPclass\fB LeftToolBarWidth) +º¸Â¦¤Î¥Ä¡¼¥ë¥Ð¡¼¤ÎÉý¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +Ãͤò 0 ¤Ë¤¹¤ë¤È¡¢º¸Â¦¤Î¥Ä¡¼¥ë¥Ð¡¼¤Ïɽ¼¨¤µ¤ì¤Þ¤»¤ó¡£ +.TP +.B rightToolBarWidth (\fPclass\fB RightToolBarWidth) +±¦Â¦¤Î¥Ä¡¼¥ë¥Ð¡¼¤ÎÉý¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +Ãͤò 0 ¤Ë¤¹¤ë¤È¡¢±¦Â¦¤Î¥Ä¡¼¥ë¥Ð¡¼¤Ïɽ¼¨¤µ¤ì¤Þ¤»¤ó¡£ +.TP +.B topToolBarShadowColor (\fPclass\fB TopToolBarShadowColor) +¥Ä¡¼¥ë¥Ð¡¼¤Î¾åÉô¥·¥ã¥É¥¦¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +(¤¹¤Ù¤Æ¤Î¥Ä¡¼¥ë¥Ð¡¼¤Ë͸ú¡£¾åÉô¥Ä¡¼¥ë¥Ð¡¼°Ê³°¤Ë¤â͸ú¤Ç¤¹¡£) +.TP +.B bottomToolBarShadowColor (\fPclass\fB BottomToolBarShadowColor) +¥Ä¡¼¥ë¥Ð¡¼¤Î²¼Éô¥·¥ã¥É¥¦¤Î¿§¤òÀßÄꤷ¤Þ¤¹¡£ +(¤¹¤Ù¤Æ¤Î¥Ä¡¼¥ë¥Ð¡¼¤Ë͸ú¡£¾åÉô¥Ä¡¼¥ë¥Ð¡¼°Ê³°¤Ë¤â͸ú¤Ç¤¹¡£) +.TP +.B topToolBarShadowPixmap (\fPclass\fB TopToolBarShadowPixmap) +¥Ä¡¼¥ë¥Ð¡¼¤Î¾åÉô¥·¥ã¥É¥¦¤Î¥Ô¥Ã¥¯¥¹¥Þ¥Ã¥×¤òÀßÄꤷ¤Þ¤¹¡£ +(¤¹¤Ù¤Æ¤Î¥Ä¡¼¥ë¥Ð¡¼¤Ë͸ú¡£¾åÉô¥Ä¡¼¥ë¥Ð¡¼°Ê³°¤Ë¤â͸ú¤Ç¤¹¡£) +ÀßÄꤵ¤ì¤Æ¤¤¤ì¤Ð¡¢¤³¤Î¥ê¥½¡¼¥¹¤ÏÂбþ¤¹¤ë¥«¥é¡¼¥ê¥½¡¼¥¹¤ò̵¸ú¤Ë¤·¤Þ¤¹¡£ +.TP +.B bottomToolBarShadowPixmap (\fPclass\fB BottomToolBarShadowPixmap) +¥Ä¡¼¥ë¥Ð¡¼¤Î²¼Éô¥·¥ã¥É¥¦¤Î¥Ô¥Ã¥¯¥¹¥Þ¥Ã¥×¤òÀßÄꤷ¤Þ¤¹¡£ +(¤¹¤Ù¤Æ¤Î¥Ä¡¼¥ë¥Ð¡¼¤Ë͸ú¡£¾åÉô¥Ä¡¼¥ë¥Ð¡¼°Ê³°¤Ë¤â͸ú¤Ç¤¹¡£) +ÀßÄꤵ¤ì¤Æ¤¤¤ì¤Ð¡¢¤³¤Î¥ê¥½¡¼¥¹¤ÏÂбþ¤¹¤ë¥«¥é¡¼¥ê¥½¡¼¥¹¤ò̵¸ú¤Ë¤·¤Þ¤¹¡£ +.TP +.B toolBarShadowThickness (\fPclass\fB ToolBarShadowThickness) +¥Ä¡¼¥ë¥Ð¡¼¤ò°Ï¤à¥·¥ã¥É¥¦Ç»ÅÙ¤ò¥Ô¥¯¥»¥ë¿ô¤ÇÀßÄꤷ¤Þ¤¹¡£ +.TP +.B visualBell (\fPclass\fB VisualBell) +¥¹¥¯¥ê¡¼¥óÅÀÌǤޤ¿¤Ï¥Ó¡¼¥×²»¤Î¤É¤Á¤é¤ò»ÈÍѤ¹¤ë¤«¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B bellVolume (\fPclass\fB BellVolume) +¥Ó¡¼¥×²»¤Î²»Î̤òÀßÄꤷ¤Þ¤¹¡£ÀßÄêÈÏ°Ï¤Ï 0 ¤«¤é 100 ¤Ç¤¹¡£ +.TP +.B useBackingStore (\fPclass\fB UseBackingStore) +.B XEmacs +X ¥¦¥£¥ó¥É¥¦¤Î¥Ð¥Ã¥¥ó¥°¥¹¥È¥¢Â°À¤òÀßÄꤹ¤ë¤«¤É¤¦¤«¤ò·èÄꤷ¤Þ¤¹¡£ +¤³¤Î°À¤òÀßÄꤹ¤ë¤È¡¢ +X ¥µ¡¼¥Ð¡¼¤¬»ÈÍѤ¹¤ë¥á¥â¥ê¡¼¤¬Â¿¤¯¤Ê¤ê¤Þ¤¹¤¬¡¢ +¥¹¥¯¥ê¡¼¥ó¤ò¹¹¿·¤¹¤ëºÝ¤Î X ¥È¥é¥Õ¥£¥Ã¥¯¤¬¾¯¤Ê¤¯¤Ê¤ê¤Þ¤¹¡£ +¤Þ¤¿¡¢¥â¥Ç¥àÀܳ¤Î¤è¤¦¤ÊÄ㮲óÀþ¤ò»È¤Ã¤¿ +.I X +¥µ¡¼¥Ð¡¼¤È¤ÎÀܳ¤Ë͸ú¤Ç¤¹¡£ +.TP +.B textPointer (\fPclass\fB Cursor) +¥Æ¥¥¹¥È¾å¤Ë¥Þ¥¦¥¹¤¬¤¢¤ë¤È¤¤Ë»ÈÍѤ¹¤ë¥«¡¼¥½¥ë¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B selectionPointer (\fPclass\fB Cursor) +¥Þ¥¦¥¹ÁªÂò¤µ¤ì¤¿¥Æ¥¥¹¥ÈÈϰϾå¤Ë¥Þ¥¦¥¹¤¬¤¢¤ë¤È¤¤Ë»ÈÍѤ¹¤ë +¥«¡¼¥½¥ë¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B spacePointer (\fPclass\fB Cursor) +¥Ð¥Ã¥Õ¥¡Æâ¤Î¶õÇò¥¹¥Ú¡¼¥¹¾å¤Ë¥Þ¥¦¥¹¤¬¤¢¤ë¤È¤¤Ë(¤Ä¤Þ¤ê¡¢ +¹ÔËö¤ä¥Õ¥¡¥¤¥ë¤ÎºÇ¸å¤Ç) »ÈÍѤ¹¤ë¥«¡¼¥½¥ë¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B modeLinePointer (\fPclass\fB Cursor) +¥â¡¼¥É¥é¥¤¥ó¾å¤Ë¥Þ¥¦¥¹¤¬¤¢¤ë¤È¤¤Ë»ÈÍѤ¹¤ë¥«¡¼¥½¥ë¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B gcPointer (\fPclass\fB Cursor) +¥¬¡¼¥Ù¥Ã¥¸¥³¥ì¥¯¥·¥ç¥óÃæ¤Ëɽ¼¨¤¹¤ë¥«¡¼¥½¥ë¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B scrollbarPointer (\fPclass\fB Cursor) +¥¹¥¯¥í¡¼¥ë¥Ð¡¼¾å¤Ë¥Þ¥¦¥¹¤¬¤¢¤ë¤È¤¤Ë»ÈÍѤ¹¤ë¥«¡¼¥½¥ë¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B pointerColor (\fPclass\fB Foreground) +¥Þ¥¦¥¹¥«¡¼¥½¥ë¤ÎÁ°·Ê¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.TP +.B pointerBackground (\fPclass\fB Background) +¥Þ¥¦¥¹¥«¡¼¥½¥ë¤ÎÇØ·Ê¿§¤òÀßÄꤷ¤Þ¤¹¡£ +.PP +.SM "¥Þ¥¦¥¹¤Î»ÈÍÑ" +.PP +°Ê²¼¤Î¥ê¥¹¥È¤Ï¡¢X11 ¤Ë¤ª¤±¤ë +.B XEmacs +¥¦¥£¥ó¥É¥¦¤Ç¤Î¡¢¥Þ¥¦¥¹¥Ü¥¿¥ó¤Î³ä¤êÅö¤Æ¤Ç¤¹¡£ + +.in +\w'CTRL-SHIFT-middle'u+4n +.ta \w'CTRL-SHIFT-middle'u+4n +.ti -\w'CTRL-SHIFT-middle'u+4n +¥Þ¥¦¥¹¥Ü¥¿¥ó µ¡Ç½ +.br +.ti -\w'CTRL-SHIFT-middle'u+4n +º¸ ¥Ý¥¤¥ó¥È¤Î°ÌÃÖ·è¤á¤È¡¢¥Æ¥¥¹¥È¤ÎÁªÂò¡£ +.br +.ti -\w'CTRL-SHIFT-middle'u+4n +Ãæ±û ¥Æ¥¥¹¥È¤Î¥Ú¡¼¥¹¥È¡£ +.br +.ti -\w'CTRL-SHIFT-middle'u+4n +±¦ ¥ª¥×¥·¥ç¥ó¥á¥Ë¥å¡¼¤Î¥Ý¥Ã¥×¥¢¥Ã¥× +.br +.ti -\w'CTRL-SHIFT-middle'u+4n +SHIFT-º¸ ÁªÂòÈϰϤγÈÄ¥¡£ +.br +.ti -\w'CTRL-SHIFT-middle'u+4n +CTRL-º¸ ÁªÂò¤·¤¿ÆâÍƤò¥Ý¥¤¥ó¥È°ÌÃÖ¤ËÁÞÆþ¡£ +.br +.ti -\w'CTRL-SHIFT-middle'u+4n +CTRL-Ãæ±û ¥Ý¥¤¥ó¥È¤Î°ÌÃÖ·è¤á¤È¤½¤Î°ÌÃ֤ǤΥƥ¥¹¥È¤ÎÁªÂò¡£ +.br +.ti -\w'CTRL-SHIFT-middle'u+4n +CTRL-SHIFT-º¸ ÁªÂò¤·¤¿ÆâÍƤòºï½ü¤·¤½¤ÎÆâÍƤò¥Ý¥¤¥ó¥È°ÌÃÖ¤ËÁÞÆþ¡£ +.br +.ti -\w'CTRL-SHIFT-middle'u+4n +META-º¸ È¢·¿ÁªÂò¡£ +.SH "¥Õ¥¡¥¤¥ë" +.LP +Lisp ¥³¡¼¥É¤¬¡¢µ¯Æ°»þ¤Ë¥æ¡¼¥¶¡¼¤Î½é´ü²½¥Õ¥¡¥¤¥ë \fB$HOME/.emacs\fP ¤«¤é +Æɤ߹þ¤Þ¤ì¤Þ¤¹¡£ +.LP +\f3/usr/local/info\f1 +.br +Info ʸ½ñ¥Ö¥é¥¦¥¶ +( +.BR XEmacs +¤Î¥µ¥Ö¥·¥¹¥Æ¥à)¤Î»²¾È¤¹¤ë¥Õ¥¡¥¤¥ë¡£ +¡ØXEmacs Reference Manual¡Ù¤È¡ØXEmacs Lisp Programmer's Manual¡Ù +¤Î´°Á´¤Ê¥Æ¥¥¹¥È¤¬¡¢½êÄê¤Î³¬Áع½Â¤¤Ç¼ý¤á¤é¤ì¤Æ¤¤¤Þ¤¹¡£ +.LP +\f3/usr/local/lib/xemacs-$VERSION/info\f1 +.br +Info ¥Õ¥¡¥¤¥ë(¤³¤Î°ÌÃ֤ȤϤ«¤®¤é¤Ê¤¤) +.LP +\f3/usr/local/lib/xemacs-$VERSION/src\f1 +.br +C ¥½¡¼¥¹¥Õ¥¡¥¤¥ë¤È¥ª¥Ö¥¸¥§¥¯¥È¥Õ¥¡¥¤¥ë(¸ºß¤·¤Ê¤¤¾ì¹ç¤â¤¢¤ë) +.LP +\f3/usr/local/lib/xemacs-$VERSION/lisp/*\f1 +.br +¿¤¯¤ÎÊÔ½¸¥³¥Þ¥ó¥É¤òÄêµÁ¤¹¤ë Lisp ¥½¡¼¥¹¥Õ¥¡¥¤¥ë¤È¥³¥ó¥Ñ¥¤¥ëºÑ¤ß¥Õ¥¡¥¤¥ë¡£ +¤³¤ì¤é¤Î¥Õ¥¡¥¤¥ë¤Ïµ¡Ç½¤ä¸Ä¡¹¤Î¥Ñ¥Ã¥±¡¼¥¸Ê̤˥µ¥Ö¥Ç¥£¥ì¥¯¥È¥êÆâ¤Ë +ʬÎव¤ì¡¢ÃÖ¤«¤ì¤Æ¤¤¤Þ¤¹¡£¤¤¤¯¤Ä¤«¤Î¥Õ¥¡¥¤¥ë¤Ï +Á°¤â¤Ã¤ÆÆɤ߹þ¤Þ¤ì¤Æ¤¤¤Þ¤¹¡£¤½¤ì°Ê³°¤Î¤â¤Î¤Ï¡¢»ÈÍÑ»þ¤Ë¤³¤ì¤é¤Î¥Ç¥£¥ì¥¯¥È¥ê¤«¤é¡¢ +¼«Æ°Åª¤ËÆɤ߹þ¤Þ¤ì¤Þ¤¹¡£ +.LP +\f3/usr/local/lib/xemacs-$VERSION/etc\f1 +.br +¤¤¤¯¤Ä¤«¤Î¾ðÊó¥Õ¥¡¥¤¥ë¡¢¥Ô¥Ã¥¯¥¹¥Þ¥Ã¥×¥Õ¥¡¥¤¥ë¡¢ +¥Ñ¥Ã¥±¡¼¥¸¤Ë»ÈÍѤµ¤ì¤ë¥Ç¡¼¥¿¥Õ¥¡¥¤¥ë¤Ê¤É¡£ +.LP +\f3/usr/local/lib/xemacs-$VERSION/$CONFIGURATION\f1 +.br +XEmacs ¤Ë»ÈÍѤµ¤ì¤ë¤µ¤Þ¤¶¤Þ¤Ê¥×¥í¥°¥é¥à¥Õ¥¡¥¤¥ë¡£ +.LP +\f3/usr/local/lib/xemacs-$VERSION/$CONFIGURATION/DOC\f1 +.br +Lisp ¥×¥ê¥ß¥Æ¥£¥Ö (´ðËÜ´Ø¿ô) ¤È \fBXEmacs\fP ¤Ë¤¢¤é¤«¤¸¤á +Æɤ߹þ¤Þ¤ì¤¿ Lisp ´Ø¿ô¤Î¥É¥¥å¥á¥ó¥Èʸ»úÎó¡£ +¤³¤ì¤é¤Î¥Õ¥¡¥¤¥ë¤Ï¡¢\fBXEmacs\fP ËÜÂΤΥµ¥¤¥º¤ò¸º¤é¤¹¤¿¤á¤Ë¤³¤³¤ËÊÝ´É +¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ +.LP +\f3/usr/local/lib/xemacs-$VERSION/etc/SERVICE\f1 +.br +\fBXEmacs\fP ¥æ¡¼¥¶¡¼¤Î¤¿¤á¤Î¡¢³Ø½¬¡¢Êݼ顢°Ü¿¢¡¢ +¥«¥¹¥¿¥Þ¥¤¥º¤Ê¤É¤Î¤µ¤Þ¤¶¤Þ¤Ê¥µ¡¼¥Ó¥¹¤òÄ󶡤¹¤ë¿Í¡¹¤Ë¤Ä¤¤¤Æ¤Þ¤È¤á¤Æ¤¤¤Þ¤¹¡£ +.LP +\f3/usr/local/lib/xemacs/lock\f1 +.br +2 ¿Í¤Î¥æ¡¼¥¶¡¼¤¬ 1 ¤Ä¤Î¥Õ¥¡¥¤¥ë¤òƱ»þ¤Ë¹¹¿·¤Ç¤¤Ê¤¤¤è¤¦¤Ë¡¢ +.BR XEmacs +¤Ç¹¹¿·Ãæ¤Î¤¹¤Ù¤Æ¤Î¥Õ¥¡¥¤¥ë¤ËÂФ·¤Æ¤Ç¤¤ë¥í¥Ã¥¯¥Õ¥¡¥¤¥ë¤òÊÝ»ý¤·¤Þ¤¹¡£ +.LP +\f3/usr/local/lib/xemacs/site-lisp\f1 +.br +¥í¡¼¥«¥ë¤ËºîÀ®¤¹¤ë Lisp ¥Õ¥¡¥¤¥ë¡£ +.LP +\f3/usr/lib/X11/rgb.txt\f1 +.br +Àµ¼°¤Î X ¥«¥é¡¼Ì¾¤¬¥ê¥¹¥È¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ +.PP +.SH "»ÈÍѾå¤Îα°ÕÅÀ¤ÈÌ䤤¹ç¤ï¤»Àè" +.B XEmacs +¤Ë´Ø¤¹¤ë¥Ð¥°¤ä½¤Àµ¤ÎÊó¹ðÀè¤È¤·¤Æ¡¢¤Þ¤¿½õ¸À¤òµá¤á¤ë°¸Àè¤È¤·¤Æ¡¢ +comp.emacs.xemacs ¥Ë¥å¡¼¥¹¥°¥ë¡¼¥×¤¬¤¢¤ê¤Þ¤¹¡£ +¤¿¤À¤·¡¢ÌäÂêÅÀ¤ò¥Ð¥°¤È¤·¤ÆÊó¹ð¤¹¤ëÁ°¤Ë¡¢ +ËÜÅö¤Ë¤½¤ì¤¬¥Ð¥°¤Ç¤¢¤ë¤«¡¢¸í²ò¤ä°Õ¿ÞŪ¤Êµ¡Ç½¤Ç¤Ï¤Ê¤¤¤« +¤È¤¤¤¦¤³¤È¤ò¤ª³Î¤«¤á¤¯¤À¤µ¤¤¡£¥Ð¥°¥ì¥Ý¡¼¥È¤ÎÊýË¡¤ä»þ´ü¤Ë¤Ä¤¤¤Æ¤Ï¡¢ +¥ê¥Õ¥¡¥ì¥ó¥¹¥Þ¥Ë¥å¥¢¥ë(¤Þ¤¿¤Ï Into ¥·¥¹¥Æ¥à) ¤Î¸åȾ¶á¤¯¤¢¤ë +¡ÖReporting XEmacs Bugs¡×¤È¤¤¤¦¾Ï¤ò¤ªÆɤߤ¯¤À¤µ¤¤¡£ +¤Þ¤¿¡¢Êó¹ð¤¹¤ë¥Ð¥°¥ì¥Ý¡¼¥È¤Ë¤Ï¡¢Æ°ºîÃæ¤Î +.B XEmacs +¤Î¥Ð¡¼¥¸¥ç¥óÈÖ¹æ¤È¤½¤ì¤¬Æ°ºî¤·¤Æ¤¤¤ë¥·¥¹¥Æ¥à¤òµÆþ¤·¤Æ¤¯¤À¤µ¤¤¡£ +ºÇ¸å¤Ë¡¢¥Ð¥°¤Î¸¶°ø¤È¤½¤ì¤¬È¯À¸¤·¤¿¾õ¶·¤ò¡¢¤Ç¤¤ë¤À¤±¤½¤Î¤Þ¤ÞÊݸ¤·¤Æ¤ª¤¤¤Æ +¤¯¤À¤µ¤¤¡£¤½¤ÎÊݸ¾õÂÖ¤¬Îɤ±¤ì¤Ð´Êñ¤Ë½¤Àµ¤Ç¤¤ë²ÄǽÀ¤¬¹â¤¯¤Ê¤ê¤Þ¤¹¡£ +¤Ç¤¤ë¤À¤±¤´¶¨ÎϤò¤ª´ê¤¤¤·¤Þ¤¹¡£ + +¤³¤Î¥Ë¥å¡¼¥¹¥°¥ë¡¼¥×¤Ï¡¢xemacs@xemacs.org ¤È¤¤¤¦¥á¡¼¥ë¥ê¥¹¥È¤«¤é¤Îȯ¿®¡¢¼õ¿®¤ò +ÁÐÊý¸þ¤Ë¹Ô¤¦¤³¤È¤¬¤Ç¤¤Þ¤¹¡£¥Í¥Ã¥È¥Ë¥å¡¼¥¹¤Ë´Êñ¤Ë¥¢¥¯¥»¥¹¤Ç¤¤Ê¤¤¤è¤¦¤Ê¾ì¹ç¤Ï¡¢ +newsgroup ¤ËÂå¤ï¤Ã¤Æ¥á¡¼¥ë¥ê¥¹¥È¤òÆɤळ¤È¤¬¤Ç¤¤Þ¤¹¡£¥á¡¼¥ë¥ê¥¹¥È¤Ø¤ÎÄɲà +¤´´õ˾¤ÎÊý¤Ï¡¢xemacs-request@xemacs.org ¤Ø¥á¡¼¥ë¤ò¤ªÁ÷¤ê¤¯¤À¤µ¤¤¡£ +(ľÀܥꥹ¥È¤Ë¥á¡¼¥ë¤òÁ÷¿®¤·¤Ê¤¤¤Ç¤¯¤À¤µ¤¤¡£) + +.B XEmacs +¤ÎÊݼéôÅö¼Ô¤Ï¡¢Äê´üŪ¤Ë¥Ë¥å¡¼¥¹¥°¥ë¡¼¥×¤òÆɤó¤Ç¤¤¤Þ¤¹¡£¤½¤·¤ÆÊó¹ð¤µ¤ì¤¿ +¥Ð¥°¤ËÂФ·¤Æ¿×®¤Ë½¤Àµ¤ò¤¹¤ë¤è¤¦¤ËÅؤá¤Æ¤¤¤Þ¤¹¡£¤·¤«¤·¤Ê¤¬¤é¡¢¤¹¤Ù¤Æ¤Î +¥á¥Ã¥»¡¼¥¸¤¬ÊݼéôÅö¼Ô¤«¤éÊÖÅú¤ò¼õ¤±¤ë¤³¤È¤¬¤Ç¤¤ë¤ï¤±¤Ç¤Ï¤¢¤ê¤Þ¤»¤ó¡£ +ÊݼéôÅö¼Ô°Ê³°¤Ë¿¿ô¤Î¿Í㤬¥Ë¥å¡¼¥¹¥°¥ë¡¼¥×¤òÆɤó¤Ç¤ª¤ê¡¢Ä̾ïÈà¤é¤«¤é¤â +½Ð¤¯¤ï¤·¤¿ÌäÂê¤ò²ò·è¤¹¤ë¤¿¤á¤Î½õ¸À¤òÆÀ¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ + +¥Ë¥å¡¼¥¹¥°¥ë¡¼¥×¤«¤éÆÀ¤é¤ì¤ë¾ðÊó°Ê¾å¤Ë¡¢¾ÜºÙ¤Ê¥µ¥Ý¡¼¥È¤¬É¬Íפʾì¹ç¤Ï¡¢ +SERVICE ¥Õ¥¡¥¤¥ë(¾å½Ò)¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ +¤½¤Î¥Õ¥¡¥¤¥ë¤Ë¡¢Ã´Åö¼Ô¤¬¥ê¥¹¥È¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ + +XEmacs ¤Î¥á¡¼¥ë¥ê¥¹¥È¤Ë¤Ä¤¤¤Æ¤Î¾ÜºÙ¤Ï¡¢ +.B /usr/local/lib/xemacs-$VERSION/etc/MAILINGLISTS +¤Î¥Õ¥¡¥¤¥ë¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ +.SH "ÈóÀ©Ìó»ö¹à" +.PP +.B XEmacs +¤Ï¡¢¥Õ¥ê¡¼¤Î¥½¥Õ¥È¥¦¥§¥¢¤Ç¤¹¡£ +.B XEmacs +General Public License ¤Ë½Ò¤Ù¤é¤ì¤Æ¤¤¤ë¸Â¤ê¤Ë¤ª¤¤¤Æ¡¢¤À¤ì¤Ç¤â +.B XEmacs +¤ä¤½¤ì¤ËÉտ路¤¿¤â¤Î¤Î¥³¥Ô¡¼¡¢¤ª¤è¤Ó¥ê¥Õ¥¡¥ì¥ó¥¹¥Þ¥Ë¥å¥¢¥ë¤Ëɽ¼¨¤µ¤ì¤Æ¤¤¤ë +ÆâÍƤΥ³¥Ô¡¼¤ò¡¢Ç¤°Õ¤Î¿Í¤ËÄ󶡤¹¤ë¤³¤È¤¬µö¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ +.PP +.B XEmacs +¤Ï¡¢UNIX ¥·¥¹¥Æ¥à¤ÎÇÛÉÛʪ¤È¤È¤â¤Ë¥Ñ¥Ã¥±¡¼¥¸¤µ¤ì¤ÆÄ󶡤µ¤ì¤ë¤³¤È¤¬¤¢¤ê¤Þ¤¹¤¬¡¢ +.B XEmacs +¤Ï¾ï¤Ë¤½¤ì¤é¤Î¥·¥¹¥Æ¥à¤Ë´Ø¤¹¤ë¥é¥¤¥»¥ó¥¹¤ÎÈϰϳ°¤Ç¤¹¡£¤â¤· +.B XEmacs +¤â¤½¤Î¥é¥¤¥»¥ó¥¹¤Ë´Þ¤Þ¤ì¤Æ¤¤¤ë¤È¤¹¤ì¤Ð¡¢¤½¤ì¤ÏÇÛÉÛµö²ÄÍ×¹à¤ËÈ¿¤·¤Þ¤¹¡£ +¤¤¤«¤Ê¤ë¿Í¤â +.B XEmacs +¤ÎÇÛÉۤ˴ؤ·¤Æ¤Ï²¿¤ÎÀ©Ìó¤â¼õ¤±¤Æ¤Ï¤Ê¤é¤Ê¤¤¡¢¤È¤¤¤¦¤Î¤¬ +General Public License ¤ÎËÜÍè¤ÎÌÜŪ¤Ç¤¹¡£ +.SH "´ØÏ¢¹àÌÜ" +.BR X (1), +.BR xlsfonts (1), +.BR xterm (1), +.BR xrdb (1), +.BR emacs (1), +.BR vi (1) +.SH "Ãø¼Ô" +.PP +.B XEmacs +¤Ï¡¢Chuck Thompson <cthomp@xemacs.org>¡¢Ben Wing <wing@666.com>¡¢ +Jamie Zawinski <jwz@netscape.com>¡¢Richard Mlynarik <mly@adoc.xerox.com>¡¢ +Martin Buchholz <mrb@eng.sun.com> ¾¡¢¤Ë¤è¤Ã¤Æ½ñ¤«¤ì¤Þ¤·¤¿¡£ +Free Software Foundation ¤Î Richard Stallman ¤Î½ñ¤¤¤¿ +.B "GNU Emacs " +¥Ð¡¼¥¸¥ç¥ó +.I 19 +¤ÎÁá´ü¥Ð¡¼¥¸¥ç¥ó¤ò¤â¤È¤Ë¤·¤Æ¤¤¤Þ¤·¤¿¤¬¡¢ +.B GNU Emacs +¤¬»ÈÍѲÄǽ¤È¤Ê¤Ã¤¿¸å¤Ç¤Ï¡¢¤½¤Î¸å³¥ê¥ê¡¼¥¹¤ËƱ´ü¤µ¤ì¤Æ¤¤¤Þ¤¹¡£ +¤â¤È¤â¤È¤Ï¡¢(º£¤ä¸ºß¤·¤Ê¤¤) Lucid, Inc. ¤Ë¤è¤Ã¤Æ½ñ¤«¤ì¤¿¤â¤Î¤Ç¡¢ +.B "Lucid Emacs " +¤È¸Æ¤Ð¤ì¤Æ¤¤¤Þ¤·¤¿¡£ +.PP +Chuck Thompson ¤¬ +.B XEmacs +¤ÎºÆɽ¼¨¤Î´ðËÜÉôʬ¤ò½ñ¤¡¢ +.B XEmacs +¤Î FTP ¤È WWW ¥µ¥¤¥È¤òÊÝ»ý¤·¡¢ +¥Ð¡¼¥¸¥ç¥ó 19.11 ( +.B XEmacs +¤È¤è¤Ð¤ì¤¿ºÇ½é¤Î¥ê¥ê¡¼¥¹) ¤«¤é¤¹¤Ù¤Æ¤Î +.B XEmacs +¤Îµ¡Ç½¤¬¥ê¥ê¡¼¥¹¤µ¤ì¤Þ¤·¤¿¡£ +Ben Wing ¤Ï¡¢¥¢¥¸¥¢¸À¸ì¤Î¥µ¥Ý¡¼¥È¡¢¥ª¥ó¥é¥¤¥ó¥Þ¥Ë¥å¥¢¥ë (¥Þ¥Ë¥å¥¢¥ë +¥Ú¡¼¥¸¤È¿¤¯¤Î FAQ ¤ò´Þ¤à)¡¢³°Éô¥¦¥£¥¸¥§¥Ã¥È¥³¡¼¥É¤ò½ñ¤¡¢Äã¥ì¥Ù¥ë¤À¤Ã¤¿ +.B XEmacs +¥µ¥Ö¥·¥¹¥Æ¥à¤Î¿¤¯¤Î´ðËÜÉôʬ¤ò¶¯²½¤·¡¢½ñ¤Ä¾¤·¤Þ¤·¤¿¡£ +Jamie Zawinski ¤Ï¡¢ +.B "Lucid Emacs " +¤Î½é´ü¥Ð¡¼¥¸¥ç¥ó (19.0) ¤«¤éºÇ½ª¥Ð¡¼¥¸¥ç¥ó (19.10) ¤Þ¤Ç¤Î¤¹¤Ù¤Æ¤ò +¥ê¥ê¡¼¥¹¤·¡¢¤³¤ì¤é¤¹¤Ù¤Æ¤Î¥ê¥ê¡¼¥¹¤Î¼ç¥³¡¼¥É¹×¸¥¼Ô¤Ç¤·¤¿¡£ +Richard Mlynarik ¤Ï¡¢ +.B XEmacs +Lisp ¥ª¥Ö¥¸¥§¥¯¥È³ä¤êÅö¤Æ¥·¥¹¥Æ¥à¤ò½ñ¤Ä¾¤·¤È¡¢¥¡¼¥Þ¥Ã¥×¥³¡¼¥É¤È +¥ß¥Ë¥Ð¥Ã¥Õ¥¡¥³¡¼¥É¤Î½¤Àµ¡¢¤½¤·¤Æ +.B XEmacs +¤È +.B GNU Emacs +¥Ð¡¼¥¸¥ç¥ó +.IR 19 +¤Î½é´ü¤ÎƱ´ü¤ò¹Ô¤¤¤Þ¤·¤¿¡£ +.PP +¤½¤Î¾¿¤¯¤Î¿Í¤â¡¢Â¿Âç¤Ê¹×¸¥¤ò³¤±¤Æ¤¤Þ¤·¤¿¡£¾ÜºÙ¤ÊÆâÍÆ(Ê̤δÑÅÀ +¤«¤é¸«¤¿ \fBXEmacs\fP ¤ÎŤ¤Îò»Ë¤äÁ¯ÌÀ¤Ê²èÁü¡¢\fBXEmacs\fP ¹×¸¥¼Ô¤¿¤Á +¤Î¿Íʪ¾Ò²ð¤Ê¤É)¤Ë¤Ä¤¤¤Æ¤Ï¡¢ +¥Ø¥ë¥×¥á¥Ë¥å¡¼¤Î¡ÖXEmacs ¤Ë¤Ä¤¤¤Æ¡×¤ò»²¾È¤·¤Æ¤¯¤À¤µ¤¤¡£ +.SH "ÄɲþðÊó" +\fBXEmacs\fP ¤ÎÄɲþðÊó¤Ë¤Ä¤¤¤Æ¤Ï¡¢ +¥Ø¥ë¥×¥á¥Ë¥å¡¼¤Î¡ÖXEmacs ¤Ë¤Ä¤¤¤Æ¡×(¾å½Ò)¤ò»²¾È¤¹¤ë¤«¡¢ +.B /usr/local/lib/xemacs-$VERSION/etc/NEWS +¥Õ¥¡¥¤¥ë¤ò¤ªÆɤߤ¯¤À¤µ¤¤¡£¤Þ¤¿¤Ï Web ¥Ö¥é¥¦¥¶¤Ç +.PP +http://www.xemacs.org/ +.PP +¤ò»ØÄꤷ¤Æ¤¹¤ë¤È¡¢\fBXEmacs\fP ¤Ë¤Ä¤¤¤Æ¤ÎºÇ¿·¾ðÊó¤¬ÆÀ¤é¤ì¤Þ¤¹¡£ +.PP +.B XEmacs +¤Ë¤Ä¤¤¤Æ¤Î FAQ (¤è¤¯¿Ò¤Í¤é¤ì¤ë¼ÁÌä) ¤â¡¢¤³¤Î URL ¤Ç¸«¤Ä¤±¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +\fBXEmacs\fP Æâ¤Î Info ¥·¥¹¥Æ¥à¤«¤é¤Ï¡¢»ÈÍѲÄǽ¤Êµì¥Ð¡¼¥¸¥ç¥ó¤Ë +¥¢¥¯¥»¥¹¤¹¤ë¤³¤È¤â²Äǽ¤Ç¤¹¡£ +.PP +ºÇ¿·¥Ð¡¼¥¸¥ç¥ó¤Î \fBXEmacs\fP ¤Ï¡¢ +.B "ftp://ftp.xemacs.org/pub/xemacs/" +¤Þ¤¿¤Ï¤ª¶á¤¯¤Î¥ß¥é¡¼¥µ¥¤¥È¤«¤éƿ̾ (anonymous) FTP ¤Ç +¥À¥¦¥ó¥í¡¼¥É¤¹¤ë¤³¤È¤¬¤Ç¤¤Þ¤¹¡£ +°Ê²¼¤Ë¥ß¥é¡¼¥µ¥¤¥È¤Î°ìÍ÷¤òµ½Ò¤·¤Þ¤¹¡£ +¤¿¤À¤·¡¢¥ß¥é¡¼¥µ¥¤¥È¤¬Êѹ¹¤µ¤ì¤Æ¥¢¥¯¥»¥¹¤Ç¤¤Ê¤¤¾ì¹ç¤â¤¢¤ê¤Þ¤¹¡£ +.PP +ftp://ftp.ai.mit.edu/pub/xemacs/ +.br +ftp://ftp.uu.net/systems/gnu/xemacs/ +.br +ftp://ftp.sunet.se/pub/gnu/xemacs/ +.br +ftp://ftp.cenatls.cena.dgac.fr/pub/Emacs/xemacs/ +.br +ftp://liasun3.epfl.ch/pub/gnu/xemacs/ +.br +ftp://ftp.th-darmstadt.de/pub/editors/xemacs/ +.br +ftp://audrey.levels.unisa.edu.au/xemacs/ +.br +ftp://sunsite.doc.ic.ac.uk/gnu/xemacs/ +.br +ftp://ftp.ibp.fr/pub/emacs/xemacs/ +.br +ftp://uiarchive.cso.uiuc.edu/pub/packages/xemacs/ +.br +ftp://ftp.technion.ac.il/pub/unsupported/gnu/xemacs/ +.br +ftp://thphys.irb.hr/pub/xemacs/ +.PP +¥ß¥é¡¼¥µ¥¤¥È¤ÎºÇ¿·¥ê¥¹¥È¤Ë¤Ä¤¤¤Æ¤Ï¡¢Web ¥µ¥¤¥È¤ò¤´Í÷¤¯¤À¤µ¤¤¡£ +
--- a/info/dir Mon Aug 13 09:35:15 2007 +0200 +++ b/info/dir Mon Aug 13 09:36:16 2007 +0200 @@ -36,12 +36,12 @@ * Info:: Documentation browsing system. * XEmacs:: The extensible user-friendly self-documenting text editor. - This manual is for XEmacs 20.2. + This manual is for XEmacs 20.3. * Lispref:: XEmacs Lisp technical reference. - This manual is for XEmacs 20.2. + This manual is for XEmacs 20.3. * New-Users-Guide:: - XEmacs User's Guide for XEmacs 20.2. -* XEmacs-FAQ:: XEmacs Frequently Asked Questions for 20.2. + XEmacs User's Guide for XEmacs 20.3. +* XEmacs-FAQ:: XEmacs Frequently Asked Questions for 20.3. * Internals:: Guide to the internals of XEmacs. * send-pr:: Submitting Bug Reports * gnats:: GNU Problem Report Management System
--- a/lib-src/Makefile.in.in Mon Aug 13 09:35:15 2007 +0200 +++ b/lib-src/Makefile.in.in Mon Aug 13 09:36:16 2007 +0200 @@ -37,11 +37,15 @@ #undef NeXT #undef mips #undef i386 +#undef linux /* ==================== Things "configure" will edit ==================== */ CC=@CC@ +CPP=@CPP@ CFLAGS=@CFLAGS@ +CPPFLAGS=@CPPFLAGS@ +LDFLAGS=@LDFLAGS@ ALLOCA=@ALLOCA@ YACC=@YACC@ LN_S=@LN_S@ @@ -101,13 +105,13 @@ /* Things that a user might actually run, which should be installed in bindir. */ -INSTALLABLES = etags ctags emacsclient b2m gnuclient gnuattach gnudoit +INSTALLABLES = etags ctags b2m gnuclient gnuattach gnudoit INSTALLABLE_SCRIPTS = rcs-checkin pstogif install-sid send-pr /* Things that Emacs runs internally, or during the build process, which should not be installed in bindir. */ UTILITIES= make-path wakeup profile make-docfile digest-doc \ - sorted-doc movemail cvtmail fakemail yow emacsserver hexl \ + sorted-doc movemail cvtmail fakemail yow hexl \ gnuserv mmencode /* These need to be conditional on I18N3 make-msgfile make-po */ @@ -241,41 +245,54 @@ #define BLESSMAIL #endif -#if defined (HAVE_SOCKS) -#define LIB_SOCKS -lsocks -#else -#define LIB_SOCKS -#endif +/* #if defined (HAVE_SOCKS) */ +/* #define LIB_SOCKS -lsocks */ +/* #else */ +/* #define LIB_SOCKS */ +/* #endif */ -LOADLIBES=LIBS_SYSTEM LIBS_MACHINE LIB_SOCKS LD_SWITCH_SITE -LOAD_X_LIBES=LD_SWITCH_X_SITE LD_SWITCH_X_SYSTEM -C_SWITCH_X=C_SWITCH_X_SITE C_SWITCH_X_SYSTEM C_SWITCH_SITE +c_switch_general=@c_switch_general@ +c_switch_window_system=@c_switch_window_system@ +c_switch_all=@c_switch_all@ +ld_switch_general=@ld_switch_general@ +ld_switch_window_system=@ld_switch_window_system@ +ld_switch_all=@ld_switch_all@ +ld_libs_general=@ld_libs_general@ +ld_libs_window_system=@ld_libs_window_system@ +ld_libs_all=@ld_libs_all@ -/* We need to #define emacs to get the right versions of some files. - Some other files - those shared with other GNU utilities - need - HAVE_CONFIG_H #defined before they know they can take advantage of - the information in ../src/config.h. */ -ALL_CFLAGS = C_SWITCH_SYSTEM C_SWITCH_MACHINE -Demacs -DHAVE_CONFIG_H \ - -DSTDC_HEADERS -I. -I../src -I${srcdir} -I${srcdir}/../src \ - ${LDFLAGS} ${CPPFLAGS} ${CFLAGS} -BASE_CFLAGS = C_SWITCH_SYSTEM C_SWITCH_MACHINE -DHAVE_CONFIG_H -DSTDC_HEADERS \ - -I. -I../src -I${srcdir} -I${srcdir}/../src ${CPPFLAGS} ${CFLAGS} -LINK_CFLAGS = C_SWITCH_SYSTEM C_SWITCH_MACHINE -Demacs -DHAVE_CONFIG_H \ - -I. -I../src -I${srcdir} -I${srcdir}/../src ${LDFLAGS} ${CFLAGS} -CPP_CFLAGS = C_SWITCH_SYSTEM C_SWITCH_MACHINE -Demacs -DHAVE_CONFIG_H \ - -I. -I../src -I${srcdir} -I${srcdir}/../src ${CPPFLAGS} ${CFLAGS} -/* Formerly -Demacs was missing, but it is needed to suppress the - defining of malloc to xmalloc. [Yes it is fucked up. Blame FSF - for this.] */ -ALLOCA_CFLAGS = C_SWITCH_SYSTEM C_SWITCH_MACHINE -Demacs -DHAVE_CONFIG_H \ - -I. -I../src -I${srcdir} -I${srcdir}/../src ${CPPFLAGS} ${CFLAGS} +/* LOADLIBES=LIBS_SYSTEM LIBS_MACHINE LIB_SOCKS LD_SWITCH_SITE */ +/* LOAD_X_LIBES=LD_SWITCH_X_SITE LD_SWITCH_X_SYSTEM */ +/* C_SWITCH_X=C_SWITCH_X_SITE C_SWITCH_X_SYSTEM C_SWITCH_SITE */ +LOADLIBES=$(ld_switch_general) $(ld_libs_general) +LOAD_X_LIBES=$(ld_switch_window_system) +C_SWITCH_X=$(c_switch_window_system) + +/* We need to #define emacs to get the right versions of some files. */ + +lib_src_cppflags = -Demacs -I../src -I${srcdir} -I${srcdir}/../src $(CPPFLAGS) +cflags = $(CFLAGS) $(lib_src_cppflags) $(c_switch_general) +ldflags = $(ld_switch_general) $(LDFLAGS) $(ld_libs_general) + +/* CPP_CFLAGS = $(c_switch_general) -Demacs -DHAVE_CONFIG_H \ */ +/* -I. -I../src -I${srcdir} -I${srcdir}/../src ${CPPFLAGS} ${CFLAGS} */ +/* BASE_CFLAGS = -DHAVE_CONFIG_H \ */ +/* -I. -I../src -I${srcdir} -I${srcdir}/../src ${CPPFLAGS} ${CFLAGS} */ +/* ALL_CFLAGS = $(BASE_CFLAGS) -Demacs */ +/* LINK_CFLAGS = $(ALL_CFLAGS) -Demacs -DHAVE_CONFIG_H \ */ +/* -I. -I../src -I${srcdir} -I${srcdir}/../src ${LDFLAGS} ${CFLAGS} */ +/* Formerly -Demacs was missing, but it is needed to suppress the */ +/* defining of malloc to xmalloc. [Yes it is fucked up. Blame FSF */ +/* for this.] */ +/* ALLOCA_CFLAGS = -Demacs -DHAVE_CONFIG_H \ */ +/* -I. -I../src -I${srcdir} -I${srcdir}/../src ${CPPFLAGS} ${CFLAGS} */ /* This is the default compilation command. But we should never rely on it, because some make version failed to find it for getopt.o. Using an explicit command made it work. */ .c.o: - ${CC} -c ${CPP_CFLAGS} $< + ${CC} -c $(cflags) $< all: ${UTILITIES} ${INSTALLABLES} ${SCRIPTS} @@ -394,9 +411,9 @@ GETOPTOBJS = getopt.o getopt1.o $(ALLOCA) GETOPTDEPS = $(GETOPTOBJS) ${srcdir}/getopt.h getopt.o: ${srcdir}/getopt.c ${srcdir}/getopt.h - ${CC} -c ${CPP_CFLAGS} ${srcdir}/getopt.c + ${CC} -c $(cflags) ${srcdir}/getopt.c getopt1.o: ${srcdir}/getopt1.c ${srcdir}/getopt.h - ${CC} -c ${CPP_CFLAGS} ${srcdir}/getopt1.c + ${CC} -c $(cflags) ${srcdir}/getopt1.c alloca.o: ${srcdir}/../src/alloca.c ${CC} -c ${ALLOCA_CFLAGS} ${srcdir}/../src/alloca.c @@ -409,124 +426,92 @@ #endif regex.o: ${srcdir}/../src/regex.c ${srcdir}/../src/regex.h - $(CC) -c ${BASE_CFLAGS} -DCONFIG_BROKETS -DINHIBIT_STRING_HEADER ${srcdir}/../src/regex.c + $(CC) -c `echo ${cflags} | sed 's/-Demacs/ /'` \ + -DCONFIG_BROKETS -DINHIBIT_STRING_HEADER ${srcdir}/../src/regex.c etags: ${srcdir}/etags.c $(GETOPTDEPS) $(REGEXDEPS) ../src/config.h - $(CC) ${ALL_CFLAGS} -DVERSION="\"${version}\"" -DETAGS_REGEXPS ${srcdir}/etags.c $(GETOPTOBJS) $(REGEXOBJ) $(LOADLIBES) -o etags + $(CC) ${cflags} -DVERSION="\"${version}\"" -DETAGS_REGEXPS ${srcdir}/etags.c $(GETOPTOBJS) $(REGEXOBJ) $(ldflags) -o etags /* We depend on etags to assure that parallel makes do not write two etags.o files on top of each other. */ ctags: ${srcdir}/etags.c $(GETOPTDEPS) etags - $(CC) ${ALL_CFLAGS} -DCTAGS -DVERSION="\"${version}\"" ${srcdir}/etags.c $(GETOPTOBJS) $(LOADLIBES) -o ctags + $(CC) ${cflags} -DCTAGS -DVERSION="\"${version}\"" ${srcdir}/etags.c $(GETOPTOBJS) $(ldflags) -o ctags wakeup: ${srcdir}/wakeup.c - $(CC) ${ALL_CFLAGS} ${srcdir}/wakeup.c $(LOADLIBES) -o wakeup + $(CC) ${cflags} ${srcdir}/wakeup.c $(ldflags) -o wakeup profile: ${srcdir}/profile.c - $(CC) ${ALL_CFLAGS} ${srcdir}/profile.c $(LOADLIBES) -o profile + $(CC) ${cflags} ${srcdir}/profile.c $(ldflags) -o profile make-docfile: ${srcdir}/make-docfile.c - $(CC) ${ALL_CFLAGS} ${srcdir}/make-docfile.c $(LOADLIBES) -o make-docfile + $(CC) ${cflags} ${srcdir}/make-docfile.c $(ldflags) -o make-docfile digest-doc: ${srcdir}/digest-doc.c - $(CC) ${ALL_CFLAGS} ${srcdir}/digest-doc.c $(LOADLIBES) -o digest-doc + $(CC) ${cflags} ${srcdir}/digest-doc.c $(ldflags) -o digest-doc sorted-doc: ${srcdir}/sorted-doc.c ${ALLOCA} - $(CC) ${ALL_CFLAGS} ${srcdir}/sorted-doc.c ${ALLOCA} $(LOADLIBES) -o sorted-doc + $(CC) ${cflags} ${srcdir}/sorted-doc.c ${ALLOCA} $(ldflags) -o sorted-doc b2m: ${srcdir}/b2m.c ../src/config.h - $(CC) ${ALL_CFLAGS} ${srcdir}/b2m.c $(LOADLIBES) -o b2m + $(CC) ${cflags} ${srcdir}/b2m.c $(ldflags) -o b2m movemail: ${srcdir}/movemail.c ${srcdir}/pop.c ${srcdir}/pop.h ../src/config.h - $(CC) ${ALL_CFLAGS} ${MOVE_FLAGS} ${srcdir}/movemail.c ${srcdir}/pop.c $(LOADLIBES) ${MOVE_LIBS} -o movemail + $(CC) ${cflags} ${MOVE_FLAGS} ${srcdir}/movemail.c ${srcdir}/pop.c $(ldflags) ${MOVE_LIBS} -o movemail cvtmail: ${srcdir}/cvtmail.c - $(CC) ${ALL_CFLAGS} ${srcdir}/cvtmail.c $(LOADLIBES) -o cvtmail + $(CC) ${cflags} ${srcdir}/cvtmail.c $(ldflags) -o cvtmail fakemail: ${srcdir}/fakemail.c ../src/config.h - $(CC) ${ALL_CFLAGS} ${srcdir}/fakemail.c $(LOADLIBES) -o fakemail + $(CC) ${cflags} ${srcdir}/fakemail.c $(ldflags) -o fakemail yow: ${srcdir}/yow.c ../src/paths.h - $(CC) ${ALL_CFLAGS} ${srcdir}/yow.c $(LOADLIBES) -o yow - -emacsserver: ${srcdir}/emacsserver.c ../src/config.h - $(CC) ${ALL_CFLAGS} ${srcdir}/emacsserver.c $(LOADLIBES) -o emacsserver - -emacsclient: ${srcdir}/emacsclient.c ../src/config.h - $(CC) ${ALL_CFLAGS} ${srcdir}/emacsclient.c $(LOADLIBES) -o emacsclient + $(CC) ${cflags} ${srcdir}/yow.c $(ldflags) -o yow hexl: ${srcdir}/hexl.c - $(CC) ${ALL_CFLAGS} ${srcdir}/hexl.c $(LOADLIBES) -o hexl + $(CC) ${cflags} ${srcdir}/hexl.c $(ldflags) -o hexl make-msgfile: ${srcdir}/make-msgfile.c - $(CC) ${CPP_CFLAGS} ${srcdir}/make-msgfile.c $(LOADLIBES) -o make-msgfile + $(CC) $(cflags) ${srcdir}/make-msgfile.c $(ldflags) -o make-msgfile make-po: ${srcdir}/make-po.c - $(CC) ${CPP_CFLAGS} ${srcdir}/make-po.c $(LOADLIBES) -o make-po + $(CC) $(cflags) ${srcdir}/make-po.c $(ldflags) -o make-po /* Why oh why does HP not include half of the standard X distribution? */ -#if defined (HAVE_XAUTH) +#ifdef HAVE_XAUTH +cflags_gnuserv = $(CFLAGS) $(c_switch_all) $(lib_src_cppflags) +ldflags_gnuserv = $(ld_switch_all) $(LDFLAGS) $(ld_libs_all) +#else +cflags_gnuserv = ${cflags} +ldflags_gnuserv = ${ldflags} +#endif gnuslib.o: ${srcdir}/gnuslib.c ${srcdir}/gnuserv.h ../src/config.h - $(CC) -c ${CPP_CFLAGS} ${C_SWITCH_X} ${srcdir}/gnuslib.c - + $(CC) -c ${cflags_gnuserv} ${srcdir}/gnuslib.c gnuclient: ${srcdir}/gnuclient.c gnuslib.o ${srcdir}/gnuserv.h - $(CC) ${ALL_CFLAGS} -o gnuclient ${srcdir}/gnuclient.c gnuslib.o $(LOADLIBES) $(LOAD_X_LIBES) -lXau + $(CC) ${cflags_gnuserv} -o gnuclient ${srcdir}/gnuclient.c gnuslib.o $(ldflags_gnuserv) gnuattach: ${srcdir}/gnuclient.c gnuslib.o ${srcdir}/gnuserv.h gnuclient - $(CC) ${ALL_CFLAGS} -o gnuattach -DGNUATTACH ${srcdir}/gnuclient.c gnuslib.o $(LOADLIBES) $(LOAD_X_LIBES) -lXau + $(CC) ${cflags_gnuserv} -o gnuattach -DGNUATTACH ${srcdir}/gnuclient.c gnuslib.o $(ldflags_gnuserv) gnudoit: ${srcdir}/gnudoit.c gnuslib.o ${srcdir}/gnuserv.h - $(CC) ${ALL_CFLAGS} -o gnudoit ${srcdir}/gnudoit.c gnuslib.o $(LOADLIBES) $(LOAD_X_LIBES) -lXau + $(CC) ${cflags_gnuserv} -o gnudoit ${srcdir}/gnudoit.c gnuslib.o $(ldflags_gnuserv) gnuserv: ${srcdir}/gnuserv.c gnuslib.o ${srcdir}/gnuserv.h - $(CC) ${ALL_CFLAGS} ${C_SWITCH_X} -o gnuserv ${srcdir}/gnuserv.c gnuslib.o $(LOADLIBES) $(LOAD_X_LIBES) -lXau - -#else /* !HAVE_XAUTH */ - -gnuclient: ${srcdir}/gnuclient.c gnuslib.o ${srcdir}/gnuserv.h - $(CC) ${ALL_CFLAGS} -o gnuclient ${srcdir}/gnuclient.c gnuslib.o $(LOADLIBES) -gnuattach: ${srcdir}/gnuclient.c gnuslib.o ${srcdir}/gnuserv.h gnuclient - $(CC) ${ALL_CFLAGS} -o gnuattach -DGNUATTACH ${srcdir}/gnuclient.c gnuslib.o $(LOADLIBES) -gnudoit: ${srcdir}/gnudoit.c gnuslib.o ${srcdir}/gnuserv.h - $(CC) ${ALL_CFLAGS} -o gnudoit ${srcdir}/gnudoit.c gnuslib.o $(LOADLIBES) -gnuserv: ${srcdir}/gnuserv.c gnuslib.o ${srcdir}/gnuserv.h - $(CC) ${ALL_CFLAGS} -o gnuserv ${srcdir}/gnuserv.c gnuslib.o $(LOADLIBES) -#endif /* !HAVE_XAUTH */ - + $(CC) ${cflags_gnuserv} -o gnuserv ${srcdir}/gnuserv.c gnuslib.o $(ldflags_gnuserv) /* mmencode binary is used by tm - but is really part of the metamail package */ /* mmencode.c was merged copy of mmencode.c and codes.c of metamail */ mmencode : ${srcdir}/mmencode.c - $(CC) ${ALL_CFLAGS} ${srcdir}/mmencode.c -o mmencode + $(CC) ${cflags} ${srcdir}/mmencode.c -o mmencode /* The timer utility (timer.c, getdate.y) is not used in XEmacs because XEmacs provides built-in timer facilities. */ make-path: ${srcdir}/make-path.c ../src/config.h - $(CC) $(ALL_CFLAGS) ${srcdir}/make-path.c -o make-path + $(CC) $(cflags) ${srcdir}/make-path.c -o make-path /* These are NOT included in INSTALLABLES or UTILITIES. See ../src/Makefile.in.in. */ -emacstool: ${srcdir}/emacstool.c - $(CC) ${srcdir}/emacstool.c -o emacstool ${ALL_CFLAGS} \ - -lsuntool -lsunwindow -lpixrect $(LOADLIBES) - -/* For SUN Japanese Language Environment. */ -nemacstool: ${srcdir}/emacstool.c - $(CC) -o nemacstool -DJLE ${ALL_CFLAGS} ${srcdir}/emacstool.c \ - -lsuntool -lmle -lsunwindow -lpixrect $(LOADLIBES) - -xvetool: ${srcdir}/emacstool.c - $(CC) -o xvetool -DXVIEW ${ALL_CFLAGS} ${srcdir}/emacstool.c \ - -lxview -lX -I$(OPENWINHOME)/include -L$(OPENWINHOME)/lib \ - $(LOADLIBES) - -xveterm: ${srcdir}/emacstool.c - $(CC) -o xveterm -DXVIEW -DTTERM ${ALL_CFLAGS} ${srcdir}/emacstool.c \ - -lxview -lolgx -lX -I$(OPENWINHOME)/include -L$(OPENWINHOME)/lib \ - $(LOADLIBES) - aixcc: ${srcdir}/aixcc.c - $(CC) $(ALL_CFLAGS) -o aixcc ${srcdir}/aixcc.c + $(CC) $(cflags) -o aixcc ${srcdir}/aixcc.c aixcc.c: ${srcdir}/aixcc.lex lex ${srcdir}/aixcc.lex
--- a/lib-src/emacsclient.c Mon Aug 13 09:35:15 2007 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,343 +0,0 @@ -/* Client process that communicates with GNU Emacs acting as server. - Copyright (C) 1986, 1987, 1993, 1994 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -Boston, MA 02111-1307, USA. */ - -/* Synched up with: FSF 19.28. */ - -#define NO_SHORTNAMES -#include <../src/config.h> -#undef read -#undef write -#undef open -#undef close -#undef signal - -#if __STDC__ || defined(STDC_HEADERS) -#include <stdlib.h> -#include <unistd.h> -#include <fcntl.h> /* for creat() */ -#include <string.h> -#endif - -#if !defined(HAVE_SOCKETS) && !defined(HAVE_SYSVIPC) -#include <stdio.h> - -int -main (int argc, char *argv[]) -{ - fprintf (stderr, "%s: Sorry, the Emacs server is supported only\n", - argv[0]); - fprintf (stderr, "on systems with Berkeley sockets or System V IPC.\n"); - return 1; -} - -#else /* HAVE_SOCKETS or HAVE_SYSVIPC */ - -#if ! defined (HAVE_SYSVIPC) -/* BSD code is very different from SYSV IPC code */ - -#include <sys/types.h> -#include <sys/socket.h> -#include <sys/un.h> -#include <sys/stat.h> -#include <stdio.h> -#include <errno.h> - -extern char *strerror (); -extern int errno; - -int -main (int argc, char *argv[]) -{ - char system_name[256]; - int s, i; - FILE *out; - struct sockaddr_un server; - char *cwd, *str; - char string[BUFSIZ]; - - if (argc < 2) - { - fprintf (stderr, "Usage: %s [+linenumber] filename\n", argv[0]); - exit (1); - } - - /* - * Open up an AF_UNIX socket in this person's home directory - */ - - if ((s = socket (AF_UNIX, SOCK_STREAM, 0)) < 0) - { - fprintf (stderr, "%s: ", argv[0]); - perror ("socket"); - exit (1); - } - server.sun_family = AF_UNIX; -#ifndef SERVER_HOME_DIR - { - struct stat statbfr; - - gethostname (system_name, sizeof (system_name)); - sprintf (server.sun_path, "/tmp/esrv%d-%s", (int) geteuid (), system_name); - - if (stat (server.sun_path, &statbfr) == -1) - { - if (errno == ENOENT) - fprintf (stderr, - "Can't find socket; have you started the server?\n"); - else - perror ("stat"); - exit (1); - } - if (statbfr.st_uid != geteuid()) - { - fprintf (stderr, "Illegal socket owner\n"); - exit (1); - } - } -#else - if (getenv ("HOME") == NULL) - { - fprintf (stderr, "%s: No home directory\n", argv[0]); - exit (1); - } - sprintf (server.sun_path, "/tmp/esrv%d", geteuid ()); -#if 0 - strcpy (server.sun_path, getenv ("HOME")); - strcat (server.sun_path, "/.emacs_server"); -#endif -#endif /* SERVER_HOME_DIR */ - if (connect (s, (struct sockaddr *) &server, strlen (server.sun_path) + 2) - < 0) - { - fprintf (stderr, "%s: ", argv[0]); - perror ("connect"); - exit (1); - } - if ((out = (FILE *) fdopen (s, "r+")) == NULL) - { - fprintf (stderr, "%s: ", argv[0]); - perror ("fdopen"); - exit (1); - } - -#ifdef BSD - cwd = (char *) getwd (string); -#else - cwd = (char *) getcwd (string, sizeof (string)); -#endif - - if (cwd == 0) - { - /* getwd puts message in STRING if it fails. */ - fprintf (stderr, "%s: %s (%s)\n", argv[0], string, strerror (errno)); - exit (1); - } - - for (i = 1; i < argc; i++) - { - if (*argv[i] == '+') - { - char *p = argv[i] + 1; - while (*p >= '0' && *p <= '9') p++; - if (*p != 0) - fprintf (out, "%s/", cwd); - } - else if (*argv[i] != '/') - fprintf (out, "%s/", cwd); - fprintf (out, "%s ", argv[i]); - } - fprintf (out, "\n"); - fflush (out); - - printf ("Waiting for Emacs..."); - fflush (stdout); - - rewind (out); /* re-read the output */ - str = fgets (string, BUFSIZ, out); - - /* Now, wait for an answer and print any messages. */ - - while ((str = fgets (string, BUFSIZ, out))) - printf ("%s", str); - - return 0; -} - -#else /* This is the SYSV IPC section */ - -#include <sys/types.h> -#include <sys/ipc.h> -#include <sys/msg.h> -#include <stdio.h> - -char *getwd (); -#if !__STDC__ && !defined(STDC_HEADERS) -char *getcwd (), *getenv (); -#endif - -int -main (int argc, char *argv[]) -{ - int s; - key_t key; - /* Size of text allocated in MSGP. */ - int size_allocated = BUFSIZ; - /* Amount of text used in MSGP. */ - int used; - struct msgbuf *msgp - = (struct msgbuf *) malloc (sizeof (struct msgbuf) + size_allocated); -#if 0 - struct msqid_ds * msg_st; -#endif /* 0 */ - char *homedir, buf[BUFSIZ]; - char gwdirb[BUFSIZ]; - char *cwd; - char *temp; - char progname[BUFSIZ]; - - strcpy (progname, argv[0]); - - if (argc < 2) - { - fprintf (stderr, "Usage: %s [+linenumber] filename\n", argv[0]); - exit (1); - } - - /* - * Create a message queue using ~/.emacs_server as the path for ftok - */ - if ((homedir = getenv ("HOME")) == NULL) - { - fprintf (stderr, "%s: No home directory\n", argv[0]); - exit (1); - } - strcpy (buf, homedir); - strcat (buf, "/.emacs_server"); - creat (buf, 0600); - key = ftok (buf, 1); /* unlikely to be anyone else using it */ - s = msgget (key, 0600 | IPC_CREAT); - if (s == -1) - { - fprintf (stderr, "%s: ", argv[0]); - perror ("msgget"); - exit (1); - } - - /* Determine working dir, so we can prefix it to all the arguments. */ -#ifdef BSD - temp = getwd (gwdirb); -#else - temp = getcwd (gwdirb, sizeof gwdirb); -#endif - - cwd = gwdirb; - if (temp != 0) - { - /* On some systems, cwd can look like `@machine/...'; - ignore everything before the first slash in such a case. */ - while (*cwd && *cwd != '/') - cwd++; - strcat (cwd, "/"); - } - else - { - fprintf (stderr, cwd); - exit (1); - } - - msgp->mtext[0] = 0; - used = 0; - argc--; argv++; - while (argc) - { - int need_cwd = 0; - char *modified_arg = argv[0]; - if (*modified_arg == '+') - { - char *p = modified_arg + 1; - while (*p >= '0' && *p <= '9') p++; - if (*p != 0) - need_cwd = 1; - } - else if (*modified_arg != '/') - need_cwd = 1; - - if (need_cwd) - used += strlen (cwd); - used += strlen (modified_arg) + 1; - while (used + 2 > size_allocated) - { - size_allocated *= 2; - msgp = (struct msgbuf *) realloc (msgp, - (sizeof (struct msgbuf) - + size_allocated)); - } - if (need_cwd) - strcat (msgp->mtext, cwd); - - strcat (msgp->mtext, modified_arg); - strcat (msgp->mtext, " "); - argv++; argc--; - } - strcat (msgp->mtext, "\n"); -#ifdef HPUX /* HPUX has a bug. */ - if (strlen (msgp->mtext) >= 512) - { - fprintf (stderr, "emacsclient: args too long for msgsnd\n"); - exit (1); - } -#endif - msgp->mtype = 1; - if (msgsnd (s, msgp, strlen (msgp->mtext)+1, 0) < 0) - { - fprintf (stderr, "%s: ", progname); - perror ("msgsnd"); - exit (1); - } - /* - * Now, wait for an answer - */ - printf ("Waiting for Emacs..."); - fflush (stdout); - - msgrcv (s, msgp, BUFSIZ, getpid (), 0); /* wait for anything back */ - strcpy (buf, msgp->mtext); - - printf ("\n%s\n", buf); - return 0; -} - -#endif /* HAVE_SYSVIPC */ - -#endif /* HAVE_SOCKETS or HAVE_SYSVIPC */ - -#ifndef HAVE_STRERROR -char * -strerror (int errnum) -{ - extern char *sys_errlist[]; - extern int sys_nerr; - - if (errnum >= 0 && errnum < sys_nerr) - return sys_errlist[errnum]; - return (char *) "Unknown error"; -} - -#endif /* ! HAVE_STRERROR */
--- a/lib-src/emacsserver.c Mon Aug 13 09:35:15 2007 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,420 +0,0 @@ -/* Communication subprocess for GNU Emacs acting as server. - Copyright (C) 1986, 1987, 1993 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -Boston, MA 02111-1307, USA. */ - -/* Synched up with: FSF 19.28. */ - -/* The GNU Emacs edit server process is run as a subprocess of Emacs - under control of the file lisp/server.el. - This program accepts communication from client (program emacsclient.c) - and passes their commands (consisting of keyboard characters) - up to the Emacs which then executes them. */ - -#define NO_SHORTNAMES -#include <../src/config.h> -#undef read -#undef write -#undef open -#undef close -#undef signal - -#if __STDC__ || defined(STDC_HEADERS) -# include <stdlib.h> -# include <unistd.h> -# include <fcntl.h> /* for creat() */ -# include <string.h> -#else -extern int errno; -#endif - -#if !defined(HAVE_SOCKETS) && !defined(HAVE_SYSVIPC) -#include <stdio.h> - -void -main () -{ - fprintf (stderr, "Sorry, the Emacs server is supported only on systems\n"); - fprintf (stderr, "with Berkeley sockets or System V IPC.\n"); - exit (1); -} - -#else /* HAVE_SOCKETS or HAVE_SYSVIPC */ - -#if ! defined (HAVE_SYSVIPC) -/* BSD code is very different from SYSV IPC code */ - -#include "../src/sysproc.h" /* Needed for select */ -#ifndef SOCK_STREAM -/* this is normally included by src/sysproc.h. might be safe to omit - * it entirely. lousy ultrix's sys/socket.h chokes if it's included - * twice, so we can't include unconditionally. */ -#include <sys/socket.h> -#endif -#include <sys/types.h> -#include <sys/file.h> -#include <sys/signal.h> -#include <sys/stat.h> /* Needed for chmod, at least on Linux */ -#include <sys/un.h> -#include <stdio.h> -#include <errno.h> - -void -main () -{ - char system_name[256]; - int s, infd, fromlen; - struct sockaddr_un server, fromunix; - char *str, string[BUFSIZ], code[BUFSIZ]; - FILE *infile; - FILE **openfiles; - int openfiles_size; - - openfiles_size = 20; - openfiles = (FILE **) malloc (openfiles_size * sizeof (FILE *)); - if (openfiles == 0) - abort (); - - /* - * Open up an AF_UNIX socket in this person's home directory - */ - - if ((s = socket (AF_UNIX, SOCK_STREAM, 0)) < 0) - { - perror ("socket"); - exit (1); - } - memset (&server, 0, sizeof (server)); - server.sun_family = AF_UNIX; -#ifndef SERVER_HOME_DIR - gethostname (system_name, sizeof (system_name)); - sprintf (server.sun_path, "/tmp/esrv%d-%s", (int) geteuid (), system_name); - - if (unlink (server.sun_path) == -1 && errno != ENOENT) - { - perror ("unlink"); - exit (1); - } -#else - { - char *homedir; - - if ((homedir = getenv ("HOME")) == NULL) - { - fprintf (stderr,"No home directory\n"); - exit (1); - } - sprintf (server.sun_path, "/tmp/esrv%d", geteuid ()); -#if 0 - strcpy (server.sun_path, homedir); - strcat (server.sun_path, "/.emacs_server"); -#endif - /* Delete anyone else's old server. */ - unlink (server.sun_path); - } -#endif /* SERVER_HOME_DIR */ - - { - int bindlen; - -#ifdef HAVE_SOCKADDR_SUN_LEN - /* See W. R. Stevens "Advanced Programming in the Unix Environment" - p. 502 */ - bindlen = (sizeof (server.sun_len) + sizeof (server.sun_family) - + strlen (server.sun_path) + 1); - server.sun_len = bindlen; -#else - bindlen = strlen (server.sun_path) + sizeof (server.sun_family); -#endif - - if (bind (s, (struct sockaddr *) &server, bindlen) < 0) - { - perror ("bind"); - exit (1); - } - } - /* Only this user can send commands to this Emacs. */ - chmod (server.sun_path, 0600); - /* - * Now, just wait for everything to come in.. - */ - if (listen (s, 5) < 0) - { - perror ("listen"); - exit (1); - } - - /* Disable sigpipes in case luser kills client... */ - signal (SIGPIPE, SIG_IGN); - for (;;) - { - int rmask = (1 << s) + 1; - if (select (s + 1, (fd_set *)&rmask, 0, 0, 0) < 0) - perror ("select"); - if (rmask & (1 << s)) /* client sends list of filenames */ - { - fromlen = sizeof (fromunix); - fromunix.sun_family = AF_UNIX; - infd = accept (s, (struct sockaddr *) &fromunix, -#ifdef HAVE_POSIX_ACCEPT - /* Posix dictates that this arg should be - a size_t *, but all known existing - implementations want an int *. */ - (size_t *) &fromlen -#else - &fromlen -#endif -); - if (infd < 0) - { - if (errno == EMFILE || errno == ENFILE) - printf ("Too many clients.\n"); - else - perror ("accept"); - continue; - } - - if (infd >= openfiles_size) - { - openfiles_size *= 2; - openfiles = (FILE **) realloc (openfiles, - openfiles_size * sizeof (FILE *)); - if (openfiles == 0) - abort (); - } - - infile = (FILE *) fdopen (infd, "r+"); /* open stream */ - if (infile == NULL) - { - printf ("Too many clients.\n"); - write (infd, "Too many clients.\n", 18); - close (infd); /* Prevent descriptor leak.. */ - continue; - } - str = fgets (string, BUFSIZ, infile); - if (str == NULL) - { - perror ("fgets"); - close (infd); /* Prevent descriptor leak.. */ - continue; - } - openfiles[infd] = infile; - printf ("Client: %d %s", infd, string); - /* If what we read did not end in a newline, - it means there is more. Keep reading from the socket - and outputting to Emacs, until we get the newline. */ - while (string[strlen (string) - 1] != '\n') - { - if (fgets (string, BUFSIZ, infile) == 0) - break; - printf ("%s", string); - } - fflush (stdout); - fflush (infile); - continue; - } - else if (rmask & 1) /* emacs sends codeword, fd, and string message */ - { - /* Read command codeword and fd */ - clearerr (stdin); - scanf ("%s %d%*c", code, &infd); - - if (ferror (stdin) || feof (stdin)) - { - fprintf (stderr, "server: error reading from standard input\n"); - exit (1); - } - - /* Transfer text from Emacs to the client, up to a newline. */ - infile = openfiles[infd]; - while (1) - { - if (fgets (string, BUFSIZ, stdin) == 0) - break; - fprintf (infile, "%s", string); - if (string[strlen (string) - 1] == '\n') - break; - } - fflush (infile); - - /* If command is close, close connection to client. */ - if (strncmp (code, "Close:", 6) == 0) - if (infd > 2) - { - fclose (infile); - close (infd); - } - continue; - } - } -} - -#else /* This is the SYSV IPC section */ - -#include <sys/types.h> -#include <sys/signal.h> -#include <sys/ipc.h> -#include <sys/msg.h> -#include <setjmp.h> - -jmp_buf msgenv; - -static SIGTYPE -msgcatch (int arg) -{ - longjmp (msgenv, 1); -} - - -/* "THIS has to be fixed. Remember, stderr may not exist...-rlk." - Incorrect. This program runs as an inferior of Emacs. - Its stderr always exists--rms. */ -#include <stdio.h> - -#if !__STDC__ && !defined(STDC_HEADERS) -#ifndef convex -char *getenv (); -#endif -#endif - -void -main () -{ - int s, fromlen, ioproc; -#if 0 - int infd; -#endif /* 0 */ - key_t key; - struct msgbuf * msgp = - (struct msgbuf *) malloc (sizeof *msgp + BUFSIZ); - struct msqid_ds msg_st; - int p; - char *homedir; - char string[BUFSIZ]; -#if 0 - FILE *infile; -#endif /* 0 */ - - /* - * Create a message queue using ~/.emacs_server as the path for ftok - */ - if ((homedir = getenv ("HOME")) == NULL) - { - fprintf (stderr,"No home directory\n"); - exit (1); - } - strcpy (string, homedir); - strcat (string, "/.emacs_server"); - creat (string, 0600); - key = ftok (string, 1); /* unlikely to be anyone else using it */ - s = msgget (key, 0600 | IPC_CREAT); - if (s == -1) - { - perror ("msgget"); - exit (1); - } - - /* Fork so we can close connection even if parent dies */ - p = fork (); - if (setjmp (msgenv)) - { - msgctl (s, IPC_RMID, 0); - kill (p, SIGKILL); - exit (0); - } - signal (SIGTERM, msgcatch); - signal (SIGINT, msgcatch); - if (p > 0) - { - /* This is executed in the original process that did the fork above. */ - /* Get pid of Emacs itself. */ - p = getppid (); - setpgrp (); /* Gnu kills process group on exit */ - while (1) - { - /* Is Emacs still alive? */ - if (kill (p, 0) < 0) - { - msgctl (s, IPC_RMID, 0); - exit (0); - } - sleep (10); - } - } - - /* This is executed in the child made by forking above. - Call it c1. Make another process, ioproc. */ - - ioproc = fork (); - if (ioproc == 0) - { - /* In process ioproc, wait for text from Emacs, - and send it to the process c1. - This way, c1 only has to wait for one source of input. */ - while (fgets (msgp->mtext, BUFSIZ, stdin)) - { - msgp->mtype = 1; - msgsnd (s, msgp, strlen (msgp->mtext) + 1, 0); - } - exit (1); - } - - /* In the process c1, - listen for messages from clients and pass them to Emacs. */ - while (1) - { - if ((fromlen = msgrcv (s, msgp, BUFSIZ - 1, 1, 0)) < 0) - { - perror ("msgrcv"); - exit (1); - } - else - { - msgctl (s, IPC_STAT, &msg_st); - - /* Distinguish whether the message came from a client, or from - ioproc. */ - if (msg_st.msg_lspid == ioproc) - { - char code[BUFSIZ]; - int inproc; - - /* Message from ioproc: tell a client we are done. */ - msgp->mtext[strlen (msgp->mtext)-1] = 0; - sscanf (msgp->mtext, "%s %d", code, &inproc); - msgp->mtype = inproc; - msgsnd (s, msgp, strlen (msgp->mtext) + 1, 0); - continue; - } - - /* This is a request from a client: copy to stdout - so that Emacs will get it. Include msg_lspid - so server.el can tell us where to send the reply. */ - strncpy (string, msgp->mtext, fromlen); - string[fromlen] = 0; /* make sure */ - /* Newline is part of string.. */ - printf ("Client: %d %s", (int) msg_st.msg_lspid, string); - fflush (stdout); - /* Now, wait for a wakeup */ - } - } -} - -#endif /* HAVE_SYSVIPC */ - -#endif /* HAVE_SOCKETS or HAVE_SYSVIPC */
--- a/lib-src/emacstool.c Mon Aug 13 09:35:15 2007 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,498 +0,0 @@ -/* - Copyright (C) 1986, 1988, 1990, 1991 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2, or (at your option) - any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; see the file COPYING. If not, write to - the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. */ - -/* - * For Emacs in SunView/Sun-Windows: (supported by Sun Unix v3.2 or greater) - * Insert a notifier filter-function to convert all useful input - * to "key" sequences that emacs can understand. See: Emacstool(1). - * - * Author: Jeff Peck, Sun Microsystems, Inc. <peck@eng.sun.com> - * - * Original Idea: Ian Batten - * Updated 15-Mar-88, Jeff Peck: set IN_EMACSTOOL, TERM, TERMCAP - * Updated 10-Sep-88, Jeff Peck: add XVIEW and JLE support - * Updated 8-Oct-90, Jeff Peck: add Meta-bit for Xview - * Updated 6-Mar-91, Jeff Peck: Hack to detect -Wt invocation - * [note, TTYSW limitation means you must Click-To-Type in Openwin] - * [fixed in OW3 or use local/tty.o] - * for better results, this should move to using TERMSW. - * Updated 10-Mar-91, Jeff Peck, et al: support for TERMSW (TTERM) - * allows point-to-type even in OW2 - * - * [note: xvetool should be started with the "-nw" flag for emacs!] - */ - -#ifdef XVIEW -#include <xview/xview.h> -#include <xview/panel.h> -#include <xview/attr.h> -#include <xview/tty.h> -#include <xview/ttysw.h> /* private defines */ -#include <xview/termsw.h> /* -DTTERM */ -#include <xview/font.h> /* for testing */ -#else -#include <suntool/sunview.h> -#include <suntool/tty.h> -#include <suntool/ttysw.h> -#endif XVIEW - -#ifdef JLE -# include <locale.h> -#endif JLE - -#include <stdio.h> -#include <sys/file.h> - -#define BUFFER_SIZE 128 /* Size of all the buffers */ - -/* define WANT_CAPS_LOCK to make f-key T1 (aka F1) behave as CapsLock */ -#define WANT_CAPS_LOCK -#ifdef WANT_CAPS_LOCK -int caps_lock; /* toggle indicator for f-key T1 caps lock */ -static char *Caps = "[CAPS] "; /* Caps Lock prefix string */ -#define CAPS_LEN 7 /* strlen (Caps) */ -#endif - -static char *mouse_prefix = "\030\000"; /* C-x C-@ */ -static int m_prefix_length = 2; /* mouse_prefix length */ - -static char *key_prefix = "\030*"; /* C-x * */ -static int k_prefix_length = 2; /* key_prefix length */ - -#ifdef JLE -static char *emacs_name = "nemacs"; /* default run command */ -static char *title = "NEmacstool - "; /* initial title */ -#else -static char *emacs_name = "emacs"; /* default run command */ -static char *title = "Emacstool - "; /* initial title */ -#endif JLE - -static char buffer[BUFFER_SIZE]; /* send to ttysw_input */ -static char *bold_name = 0; /* for -bold option */ - -Frame frame; /* Base frame for system */ - -#ifndef TTERM -#define SWTYPE TTY -Tty tty_win; /* Where emacs is reading */ -#else -#define SWTYPE TERMSW -Termsw tty_win; /* Termsw does follow-mouse */ -#endif TTERM - -#ifdef XVIEW -Xv_Window tty_view; /* Where the events are in Xview*/ -#else -Tty tty_view; /* SunView place filler */ -#endif XVIEW - -int font_width, font_height; /* For translating pixels to chars */ -int left_margin = 0; /* default window -- frame offset */ - -int console_fd = 0; /* for debugging: setenv DEBUGEMACSTOOL */ -FILE *console; /* for debugging: setenv DEBUGEMACSTOOL */ - -Icon frame_icon; -/* make an icon_image for the default frame_icon */ -static short default_image[258] = -{ -#include <images/terminal.icon> -}; -mpr_static(icon_image, 64, 64, 1, default_image); - -/* - * Assign a value to a set of keys - */ -int -button_value (event) - Event *event; -{ - int retval = 0; - /* - * Code up the current situation: - * - * 1 = MS_LEFT; - * 2 = MS_MIDDLE; - * 4 = MS_RIGHT; - * 8 = SHIFT; - * 16 = CONTROL; - * 32 = META; - * 64 = DOUBLE; - * 128 = UP; - */ - - if (MS_LEFT == (event_id (event))) retval = 1; - if (MS_MIDDLE == (event_id (event))) retval = 2; - if (MS_RIGHT == (event_id (event))) retval = 4; - - if (event_shift_is_down (event)) retval += 8; - if (event_ctrl_is_down (event)) retval += 16; - if (event_meta_is_down (event)) retval += 32; - if (event_is_up (event)) retval += 128; - return retval; -} - -/* - * Variables to store the time of the previous mouse event that was - * sent to emacs. - * - * The theory is that to time double clicks while ignoreing UP buttons, - * we must keep track of the accumulated time. - * - * If someone writes a SUN-SET-INPUT-MASK for emacstool, - * That could be used to selectively disable UP events, - * and then this cruft wouldn't be necessary. - */ -static long prev_event_sec = 0; -static long prev_event_usec = 0; - -/* - * Give the time difference in milliseconds, where one second - * is considered infinite. - */ -int -time_delta (now_sec, now_usec, prev_sec, prev_usec) - long now_sec, now_usec, prev_sec, prev_usec; -{ - long sec_delta = now_sec - prev_sec; - long usec_delta = now_usec - prev_usec; - - if (usec_delta < 0) { /* "borrow" a second */ - usec_delta += 1000000; - --sec_delta; - } - - if (sec_delta >= 10) - return (9999); /* Infinity */ - else - return ((sec_delta * 1000) + (usec_delta / 1000)); -} - - -/* - * Filter function to translate selected input events for emacs - * Mouse button events become ^X^@(button x-col y-line time-delta) . - * Function keys: ESC-*{c}{lrt} l,r,t for Left, Right, Top; - * {c} encodes the keynumber as a character [a-o] - */ -static Notify_value -input_event_filter_function (window, event, arg, type) -#ifdef XVIEW - Xv_Window window; -#else - Window window; -#endif XVIEW - Event *event; - Notify_arg arg; - Notify_event_type type; -{ - struct timeval time_stamp; - - if (console_fd) fprintf(console, "Event: %d\n", event_id(event)); - - /* UP L1 is the STOP key */ - if (event_id(event) == WIN_STOP) { - ttysw_input(tty_win, "\007\007\007\007\007\007\007", 7); - return NOTIFY_IGNORED; - } - - /* UP L5 & L7 is Expose & Open, let them pass to sunview */ - if (event_id(event) == KEY_LEFT(5) || event_id(event) == KEY_LEFT(7)) - if(event_is_up (event)) - return notify_next_event_func (window, event, arg, type); - else return NOTIFY_IGNORED; - - if (event_is_button (event)) { /* do Mouse Button events */ -/* Commented out so that we send mouse up events too. - if (event_is_up (event)) - return notify_next_event_func (window, event, arg, type); -*/ - time_stamp = event_time (event); - ttysw_input (tty_win, mouse_prefix, m_prefix_length); - sprintf (buffer, "(%d %d %d %d)\015", - button_value (event), - (event_x (event) - left_margin) / font_width, - event_y (event) / font_height, - time_delta (time_stamp.tv_sec, time_stamp.tv_usec, - prev_event_sec, prev_event_usec) - ); - ttysw_input (tty_win, buffer, strlen(buffer)); - prev_event_sec = time_stamp.tv_sec; - prev_event_usec = time_stamp.tv_usec; - return NOTIFY_IGNORED; - } - - { /* Do the function key events */ - int d; - char c = (char) 0; - if ((event_is_key_left (event)) ? - ((d = event_id(event) - KEY_LEFT(1) + 'a'), c='l') : - ((event_is_key_right (event)) ? - ((d = event_id(event) - KEY_RIGHT(1) + 'a'), c='r') : - ((event_is_key_top (event)) ? - ((d = event_id(event) - KEY_TOP(1) + 'a'), c='t') : 0))) - { - if (event_is_up(event)) return NOTIFY_IGNORED; - if (event_shift_is_down (event)) c = c - 32; - /* this will give a non-{lrt} for unshifted keys */ - if (event_ctrl_is_down (event)) c = c - 64; - if (event_meta_is_down (event)) c = c + 128; -#ifdef WANT_CAPS_LOCK -/* set a toggle and relabel window so T1 can act like caps-lock */ - if (event_id(event) == KEY_TOP(1)) - { - /* make a frame label with and without CAPS */ - strcpy (buffer, Caps); - title = &buffer[CAPS_LEN]; - strncpy (title, (char *)window_get (frame, FRAME_LABEL), - BUFFER_SIZE - CAPS_LEN); - buffer[BUFFER_SIZE] = (char) 0; - if (strncmp (title, Caps, CAPS_LEN) == 0) - title += CAPS_LEN; /* already Caps */ - caps_lock = (caps_lock ? 0 : CAPS_LEN); - window_set(frame, FRAME_LABEL, (title -= caps_lock), 0); - return NOTIFY_IGNORED; - } -#endif - ttysw_input (tty_win, key_prefix, k_prefix_length); - sprintf (buffer, "%c%c", d, c); - ttysw_input(tty_win, buffer, strlen(buffer)); - - return NOTIFY_IGNORED; - } - } - if ((event_is_ascii(event) || event_is_meta(event)) - && event_is_up(event)) return NOTIFY_IGNORED; -#ifdef WANT_CAPS_LOCK -/* shift alpha chars to upper case if toggle is set */ - if ((caps_lock) && event_is_ascii(event) - && (event_id(event) >= 'a') && (event_id(event) <= 'z')) - event_set_id(event, (event_id(event) - 32)); -/* crufty, but it works for now. is there an UPCASE(event)? */ -#endif -#ifndef NO_META_BIT -/* under Openwindows/X, the meta bit is not set in the key event, - * emacs expects this so we add it in here: - */ - if (event_is_ascii(event) && event_meta_is_down(event)) - event_set_id(event, 128 | event_id(event)); -#endif - return notify_next_event_func (window, event, arg, type); -} - -main (argc, argv) - int argc; - char **argv; -{ - int error_code; /* Error codes */ - -#ifdef JLE - setlocale(LC_ALL, ""); -#endif JLE - - if(getenv("DEBUGEMACSTOOL")) - console = fdopen (console_fd = open("/dev/console",O_WRONLY), "w"); - - putenv("IN_EMACSTOOL=t"); /* notify subprocess that it is in emacstool */ - - if (putenv("TERM=sun") != 0) /* TTY_WIN will be a TERM=sun window */ - {fprintf (stderr, "%s: Could not set TERM=sun, using `%s'\n", - argv[0], (char *)getenv("TERM")) ;}; - /* - * If TERMCAP starts with a slash, it is the pathname of the - * termcap file, not an entry extracted from it, so KEEP it! - * Otherwise, it may not relate to the new TERM, so Nuke-It. - * If there is no TERMCAP environment variable, don't make one. - */ - { - char *termcap ; /* Current TERMCAP value */ - termcap = (char *)getenv("TERMCAP") ; - if (termcap && (*termcap != '/')) - { - if (putenv("TERMCAP=") != 0) - {fprintf (stderr, "%s: Could not clear TERMCAP\n", argv[0]) ;} ; - } ; - } ; - - /* find command to run as subprocess in window */ - if (!(argv[0] = (char *)getenv("EMACSTOOL"))) /* Set emacs command name */ - argv[0] = emacs_name; - /* Emacstool recognizes two special args: -rc <file> and -bold <bold-name> */ - for (argc = 1; argv[argc]; argc++) /* Use last one on line */ - { - if(!(strcmp ("-rc", argv[argc]))) /* Override if -rc given */ - {int i = argc; - argv[argc--]=0; /* kill the -rc argument */ - if (argv[i+1]) { /* move to argv[0] and squeeze the rest */ - argv[0]=argv[i+1]; - for (; argv[i+2]; (argv[i]=argv[i+2],argv[++i]=0)); - } - } - - if (!(strcmp ("-bold", argv[argc]))) - {int i = argc; - argv[argc--]=0; /* kill the -bold argument */ - if (argv[i+1]) { /* move to bold_name and squeeze the rest */ - bold_name = argv[i+1]; - for (; argv[i+2]; (argv[i]=argv[i+2],argv[++i]=0)); - } - } - }; - - strcpy (buffer, title); - strncat (buffer, argv[0], /* append run command name */ - (BUFFER_SIZE - (strlen (buffer)) - (strlen (argv[0]))) - 1); - - error_code = interpose_on_window(argc,argv); - if (error_code != 0) { /* Barf */ - fprintf (stderr, "notify_interpose_event_func returns %d.\n", error_code); - exit (1); - } - -#ifdef XVIEW - xv_main_loop (frame); /* And away we go */ -#else - window_main_loop (frame); -#endif XVIEW -} - -#ifdef XVIEW -int interpose_on_window(argc,argv) - int argc; - char **argv; -{ -#ifndef TTERM - int i, font_width_adjust = 1; /* hackery, and hueristics */ - /* if -Wt is not supplied, then font comes out as lucida-14 (width=8) - * rather than the screen.r.12 (width=7) typically used - * this hack attempts to workaround it. - * could use a env var EMACSTOOL_DEFAULT_FONT_WIDTH instead */ - for (i = 1; argv[i]; i++) { - if (!(strcmp ("-Wt", argv[i]))) - {font_width_adjust = 0; - if (console_fd) fprintf(console, "-Wt = %d\n", font_width_adjust); - break;} - } -#endif TTERM - /* initialize Xview, and strip window args */ - xv_init(XV_INIT_ARGC_PTR_ARGV, &argc, argv, 0); - - /* do this first, so arglist can override it */ - frame_icon = icon_create (ICON_LABEL, "Emacstool", - ICON_IMAGE, &icon_image, - 0); - - /* Build a frame to run in */ - frame = xv_create ((Xv_Window)NULL, FRAME, - FRAME_LABEL, buffer, - FRAME_ICON, frame_icon, - 0); - - /* Create a tty with emacs in it */ - tty_win = xv_create (frame, SWTYPE, WIN_IS_CLIENT_PANE, - TTY_QUIT_ON_CHILD_DEATH, TRUE, - TTY_BOLDSTYLE, TTYSW_BOLD_INVERT, - TTY_ARGV, argv, - 0); - - if (bold_name) { - (void)xv_set(tty_win, TTY_BOLDSTYLE_NAME, bold_name, 0); - } - - { - Xv_font font; /* declare temp font variable */ - font = (Xv_font)xv_get (tty_win, XV_FONT); - font_height = (int)xv_get (font, FONT_DEFAULT_CHAR_HEIGHT); - font_width = (int)xv_get (font, FONT_DEFAULT_CHAR_WIDTH); - } - if (console_fd) fprintf(console, "Width = %d\n", font_width); - -#ifndef TTERM - font_width -= font_width_adjust; /* A guess! font bug in ttysw*/ -#else - /* make the termsw act as a tty */ - xv_set(tty_win, TERMSW_MODE, TTYSW_MODE_TYPE, 0); - /* termsw has variable offset depending on scrollbar size/location */ - left_margin = (int)xv_get (tty_win, TEXTSW_LEFT_MARGIN); -#endif TTERM - - tty_view = (Xv_Window) xv_get (tty_win, OPENWIN_NTH_VIEW, 0); - xv_set(tty_view, - WIN_CONSUME_EVENTS, - WIN_MOUSE_BUTTONS, WIN_UP_EVENTS, - ACTION_ADJUST, ACTION_MENU, - WIN_ASCII_EVENTS, - WIN_LEFT_KEYS, WIN_TOP_KEYS, WIN_RIGHT_KEYS, - 0, - 0); - /* Interpose my event function */ - return (int) notify_interpose_event_func - (tty_view, input_event_filter_function, NOTIFY_SAFE); -} -#else -int interpose_on_window (argc, argv) - int argc; - char **argv; -{ - /* do this first, so arglist can override it */ - frame_icon = icon_create (ICON_LABEL, "Emacstool", - ICON_IMAGE, &icon_image, - 0); - - /* Build a frame to run in */ - frame = window_create ((Window)NULL, FRAME, - FRAME_LABEL, buffer, - FRAME_ICON, frame_icon, - FRAME_ARGC_PTR_ARGV, &argc, argv, - 0); - - /* Create a tty with emacs in it */ - tty_win = window_create (frame, TTY, - TTY_QUIT_ON_CHILD_DEATH, TRUE, - TTY_BOLDSTYLE, TTYSW_BOLD_INVERT, - TTY_ARGV, argv, - 0); - - if (bold_name) { - (void)window_set(tty_win, TTY_BOLDSTYLE_NAME, bold_name, 0); - } - - /* ttysw uses pf_default, one must set WIN_FONT explicitly */ - window_set (tty_win, WIN_FONT, pf_default(), 0); - font_height = (int)window_get (tty_win, WIN_ROW_HEIGHT); - font_width = (int)window_get (tty_win, WIN_COLUMN_WIDTH); - - tty_view = tty_win; - window_set(tty_view, - WIN_CONSUME_PICK_EVENTS, - WIN_STOP, - WIN_MOUSE_BUTTONS, WIN_UP_EVENTS, - /* LOC_WINENTER, LOC_WINEXIT, LOC_MOVE, */ - 0, - WIN_CONSUME_KBD_EVENTS, - WIN_STOP, - WIN_ASCII_EVENTS, - WIN_LEFT_KEYS, WIN_TOP_KEYS, WIN_RIGHT_KEYS, - /* WIN_UP_ASCII_EVENTS, */ - 0, - 0); - /* Interpose my event function */ - return (int) notify_interpose_event_func - (tty_view, input_event_filter_function, NOTIFY_SAFE); -} -#endif XVIEW
--- a/lib-src/etags.c Mon Aug 13 09:35:15 2007 +0200 +++ b/lib-src/etags.c Mon Aug 13 09:36:16 2007 +0200 @@ -31,7 +31,7 @@ * Francesco Potorti` (F.Potorti@cnuce.cnr.it) is the current maintainer. */ -char pot_etags_version[] = "@(#) pot revision number is 11.86"; +char pot_etags_version[] = "@(#) pot revision number is 11.90"; #define TRUE 1 #define FALSE 0 @@ -111,6 +111,7 @@ /* C extensions. */ #define C_PLPL 0x00001 /* C++ */ #define C_STAR 0x00003 /* C* */ +#define C_JAVA 0x00005 /* JAVA */ #define YACC 0x10000 /* yacc file */ #define streq(s,t) ((DEBUG && (s) == NULL && (t) == NULL \ @@ -176,6 +177,7 @@ Lang_function default_C_entries; Lang_function C_entries; Lang_function Cplusplus_entries; +Lang_function Cjava_entries; Lang_function Cstar_entries; Lang_function Erlang_functions; Lang_function Fortran_functions; @@ -183,6 +185,7 @@ Lang_function Lisp_functions; Lang_function Pascal_functions; Lang_function Perl_functions; +Lang_function Postscript_functions; Lang_function Prolog_functions; Lang_function Scheme_functions; Lang_function TeX_functions; @@ -192,6 +195,7 @@ void C_entries (); void default_C_entries (); void plain_C_entries (); +void Cjava_entries (); void Cplusplus_entries (); void Cstar_entries (); void Erlang_functions (); @@ -200,6 +204,7 @@ void Lisp_functions (); void Pascal_functions (); void Perl_functions (); +void Postscript_functions (); void Prolog_functions (); void Scheme_functions (); void TeX_functions (); @@ -213,6 +218,7 @@ long readline (); long readline_internal (); #ifdef ETAGS_REGEXPS +void analyse_regex (); void add_regex (); #endif void add_node (); @@ -361,9 +367,14 @@ char *default_C_suffixes [] = { "c", "h", NULL }; -/* .M is for Objective C++ files. */ char *Cplusplus_suffixes [] = - { "C", "H", "c++", "cc", "cpp", "cxx", "h++", "hh", "hpp", "hxx", "M", NULL}; + { "C", "H", "c++", "cc", "cpp", "cxx", "h++", "hh", "hpp", "hxx", + "M", /* Objective C++ */ + "pdb", /* Postscript with C syntax */ + NULL }; + +char *Cjava_suffixes [] = + { "java", NULL }; char *Cstar_suffixes [] = { "cs", "hs", NULL }; @@ -391,6 +402,9 @@ "lm", /* Objective lex file */ NULL }; +char *Postscript_suffixes [] = + { "ps", NULL }; + char *Prolog_suffixes [] = { "prolog", NULL }; @@ -418,20 +432,22 @@ struct lang_entry lang_names [] = { - { "asm", Asm_labels, Asm_suffixes, NULL }, - { "c", default_C_entries, default_C_suffixes, NULL }, - { "c++", Cplusplus_entries, Cplusplus_suffixes, NULL }, - { "c*", Cstar_entries, Cstar_suffixes, NULL }, - { "erlang", Erlang_functions, Erlang_suffixes, NULL }, - { "fortran", Fortran_functions, Fortran_suffixes, NULL }, - { "lisp", Lisp_functions, Lisp_suffixes, NULL }, - { "pascal", Pascal_functions, Pascal_suffixes, NULL }, - { "perl", Perl_functions, Perl_suffixes, Perl_interpreters }, - { "proc", plain_C_entries, plain_C_suffixes, NULL }, - { "prolog", Prolog_functions, Prolog_suffixes, NULL }, - { "scheme", Scheme_functions, Scheme_suffixes, NULL }, - { "tex", TeX_functions, TeX_suffixes, NULL }, - { "yacc", Yacc_entries, Yacc_suffixes, NULL }, + { "asm", Asm_labels, Asm_suffixes, NULL }, + { "c", default_C_entries, default_C_suffixes, NULL }, + { "c++", Cplusplus_entries, Cplusplus_suffixes, NULL }, + { "c*", Cstar_entries, Cstar_suffixes, NULL }, + { "erlang", Erlang_functions, Erlang_suffixes, NULL }, + { "fortran", Fortran_functions, Fortran_suffixes, NULL }, +/*{ "java", Cjava_entries, Cjava_suffixes, NULL },*/ + { "lisp", Lisp_functions, Lisp_suffixes, NULL }, + { "pascal", Pascal_functions, Pascal_suffixes, NULL }, + { "perl", Perl_functions, Perl_suffixes, Perl_interpreters }, + { "postscript", Postscript_functions, Postscript_suffixes, NULL }, + { "proc", plain_C_entries, plain_C_suffixes, NULL }, + { "prolog", Prolog_functions, Prolog_suffixes, NULL }, + { "scheme", Scheme_functions, Scheme_suffixes, NULL }, + { "tex", TeX_functions, TeX_suffixes, NULL }, + { "yacc", Yacc_entries, Yacc_suffixes, NULL }, { "auto", NULL }, /* default guessing scheme */ { "none", just_read_file }, /* regexp matching only */ { NULL, NULL } /* end of list */ @@ -517,9 +533,10 @@ } #ifdef ETAGS_REGEXPS - puts ("-r /REGEXP/, --regex=/REGEXP/\n\ + puts ("-r /REGEXP/, --regex=/REGEXP/ or --regex=@regexfile\n\ Make a tag for each line matching pattern REGEXP in the\n\ - following files. REGEXP is anchored (as if preceded by ^).\n\ + following files. regexfile is a file containing one REGEXP\n\ + per line. REGEXP is anchored (as if preceded by ^).\n\ The form /REGEXP/NAME/ creates a named tag. For example Tcl\n\ named tags can be created with:\n\ --regex=/proc[ \\t]+\\([^ \\t]+\\)/\\1/."); @@ -883,7 +900,11 @@ tagfile = CTAGS ? "tags" : "TAGS"; cwd = etags_getcwd (); /* the current working directory */ if (cwd[strlen (cwd) - 1] != '/') - cwd = concat (cwd, "/", ""); + { + char *oldcwd = cwd; + cwd = concat (oldcwd, "/", ""); + free (oldcwd); + } if (streq (tagfile, "-")) tagfiledir = cwd; else @@ -927,7 +948,7 @@ break; #ifdef ETAGS_REGEXPS case at_regexp: - add_regex (argbuffer[i].what); + analyse_regex (argbuffer[i].what); break; #endif case at_filename: @@ -1517,7 +1538,8 @@ enum sym_type { st_none, st_C_objprot, st_C_objimpl, st_C_objend, st_C_gnumacro, - st_C_struct, st_C_enum, st_C_define, st_C_typedef, st_C_typespec + st_C_struct, st_C_enum, st_C_define, st_C_typedef, st_C_typespec, + st_C_jstruct }; /* Feed stuff between (but not including) %[ and %] lines to: @@ -1529,6 +1551,8 @@ @protocol, 0, st_C_objprot @implementation,0, st_C_objimpl @end, 0, st_C_objend +extends, C_JAVA, st_C_jstruct +implements, C_JAVA, st_C_jstruct class, C_PLPL, st_C_struct namespace, C_PLPL, st_C_struct domain, C_STAR, st_C_struct @@ -1575,33 +1599,33 @@ #define MIN_WORD_LENGTH 3 #define MAX_WORD_LENGTH 15 -#define MIN_HASH_VALUE 34 -#define MAX_HASH_VALUE 121 +#define MIN_HASH_VALUE 33 +#define MAX_HASH_VALUE 126 /* - 34 keywords - 88 is the maximum key range + 36 keywords + 94 is the maximum key range */ -static int +int hash (str, len) register char *str; register unsigned int len; { static unsigned char hash_table[] = { - 121, 121, 121, 121, 121, 121, 121, 121, 121, 121, - 121, 121, 121, 121, 121, 121, 121, 121, 121, 121, - 121, 121, 121, 121, 121, 121, 121, 121, 121, 121, - 121, 121, 121, 121, 121, 121, 121, 121, 121, 121, - 121, 121, 121, 121, 121, 121, 121, 121, 121, 121, - 121, 121, 121, 121, 121, 121, 121, 121, 121, 121, - 121, 121, 121, 121, 45, 121, 121, 121, 16, 19, - 61, 121, 121, 121, 121, 121, 121, 121, 121, 121, - 10, 121, 121, 20, 53, 121, 121, 121, 121, 121, - 121, 121, 121, 121, 121, 121, 121, 41, 45, 22, - 60, 47, 37, 28, 121, 55, 121, 121, 20, 14, - 29, 30, 5, 121, 50, 59, 30, 54, 6, 121, - 121, 121, 121, 121, 121, 121, 121, 121, + 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 15, 126, 126, 126, 53, 24, + 41, 126, 126, 126, 126, 126, 126, 126, 126, 126, + 51, 126, 126, 26, 47, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, 126, 126, 11, 36, 26, + 35, 13, 22, 39, 126, 34, 126, 126, 43, 21, + 36, 6, 49, 126, 47, 61, 28, 57, 35, 126, + 126, 126, 126, 126, 126, 126, 126, 126, }; return len + hash_table[str[2]] + hash_table[str[0]]; } @@ -1617,56 +1641,61 @@ {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, + {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, + {"float", 0, st_C_typespec}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, - {"volatile", 0, st_C_typespec}, - {"PSEUDO", 0, st_C_gnumacro}, - {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, - {"typedef", 0, st_C_typedef}, - {"typename", C_PLPL, st_C_typespec}, - {"",}, {"",}, {"",}, - {"SYSCALL", 0, st_C_gnumacro}, - {"",}, {"",}, {"",}, - {"mutable", C_PLPL, st_C_typespec}, - {"namespace", C_PLPL, st_C_struct}, - {"long", 0, st_C_typespec}, - {"",}, {"",}, - {"const", 0, st_C_typespec}, - {"",}, {"",}, {"",}, - {"explicit", C_PLPL, st_C_typespec}, - {"",}, {"",}, {"",}, {"",}, - {"void", 0, st_C_typespec}, - {"",}, {"char", 0, st_C_typespec}, {"class", C_PLPL, st_C_struct}, + {"auto", 0, st_C_typespec}, + {"",}, {"",}, + {"bool", C_PLPL, st_C_typespec}, + {"extern", 0, st_C_typespec}, + {"extends", C_JAVA, st_C_jstruct}, + {"",}, {"",}, + {"@implementation", 0, st_C_objimpl}, {"",}, {"",}, {"",}, - {"float", 0, st_C_typespec}, + {"@end", 0, st_C_objend}, + {"mutable", C_PLPL, st_C_typespec}, + {"",}, {"",}, + {"SYSCALL", 0, st_C_gnumacro}, {"",}, - {"@implementation", 0, st_C_objimpl}, - {"auto", 0, st_C_typespec}, + {"@interface", 0, st_C_objprot}, + {"domain", C_STAR, st_C_struct}, + {"define", 0, st_C_define}, + {"",}, + {"int", 0, st_C_typespec}, + {"namespace", C_PLPL, st_C_struct}, + {"const", 0, st_C_typespec}, + {"",}, {"",}, + {"explicit", C_PLPL, st_C_typespec}, + {"@protocol", 0, st_C_objprot}, + {"short", 0, st_C_typespec}, + {"void", 0, st_C_typespec}, + {"enum", 0, st_C_enum}, {"",}, {"ENTRY", 0, st_C_gnumacro}, - {"@end", 0, st_C_objend}, - {"bool", C_PLPL, st_C_typespec}, - {"domain", C_STAR, st_C_struct}, + {"",}, + {"static", 0, st_C_typespec}, + {"",}, {"",}, + {"PSEUDO", 0, st_C_gnumacro}, {"",}, + {"long", 0, st_C_typespec}, + {"typedef", 0, st_C_typedef}, + {"typename", C_PLPL, st_C_typespec}, + {"volatile", 0, st_C_typespec}, + {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, + {"implements", C_JAVA, st_C_jstruct}, + {"",}, {"",}, + {"union", 0, st_C_struct}, + {"",}, + {"double", 0, st_C_typespec}, {"DEFUN", 0, st_C_gnumacro}, - {"extern", 0, st_C_typespec}, - {"@interface", 0, st_C_objprot}, - {"",}, {"",}, {"",}, - {"int", 0, st_C_typespec}, - {"",}, {"",}, {"",}, {"",}, + {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"signed", 0, st_C_typespec}, - {"short", 0, st_C_typespec}, - {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, - {"define", 0, st_C_define}, - {"@protocol", 0, st_C_objprot}, - {"enum", 0, st_C_enum}, - {"static", 0, st_C_typespec}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, - {"union", 0, st_C_struct}, {"struct", 0, st_C_struct}, - {"",}, {"",}, {"",}, {"",}, - {"double", 0, st_C_typespec}, + {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, {"",}, + {"",}, {"",}, {"unsigned", 0, st_C_typespec}, }; @@ -1921,6 +1950,11 @@ */ switch (toktype) { + case st_C_jstruct: + if (structdef == stagseen) + structdef = scolonseen; + return FALSE; + break; case st_C_struct: case st_C_enum: if (typdef == ttypedseen @@ -2155,7 +2189,7 @@ int cblev; /* current curly brace level */ int parlev; /* current parenthesis level */ logical incomm, inquote, inchar, quotednl, midtoken; - logical cplpl; + logical cplpl, cjava; TOKEN savetok; /* token saved during preprocessor handling */ @@ -2173,6 +2207,7 @@ cblev = 0; parlev = 0; cplpl = c_ext & C_PLPL; + cjava = c_ext & C_JAVA; while (!feof (inf)) { @@ -2429,7 +2464,7 @@ funcdef = fnone; break; } - if (structdef == stagseen) + if (structdef == stagseen && !cjava) structdef = snone; break; case dsharpseen: @@ -2732,6 +2767,13 @@ C_entries (C_PLPL, inf); } +/* Always do Java. */ +void +Cjava_entries (FILE *inf) +{ + C_entries (C_JAVA, inf); +} + /* Always do C*. */ void Cstar_entries (inf) @@ -3259,6 +3301,36 @@ } /* + * Postscript tag functions + * Just look for lines where the first character is '/' + */ +void +Postscript_functions (inf) + FILE *inf; +{ + lineno = 0; + charno = 0; + while (!feof (inf)) + { + lineno++; + linecharno = charno; + charno += readline (&lb, inf); + dbp = lb.buffer; + if (dbp[0] == '/') + { + register char *cp; + for (cp = dbp+1; + *cp != '\0' && *cp != ' ' && *cp != '{'; + cp++) + continue; + pfnote ((CTAGS) ? savenstr (dbp, cp-dbp) : NULL, TRUE, + lb.buffer, cp - lb.buffer + 1, lineno, linecharno); + } + } +} + + +/* * Scheme tag functions * look for (def... xyzzy * look for (def... (xyzzy @@ -3381,7 +3453,7 @@ charno += readline (&lb, inf); dbp = lb.buffer; lasthit = dbp; - while (dbp = etags_strchr (dbp, TEX_esc)) /* Look at each esc in line */ + while (dbp = etags_strchr (dbp, TEX_esc)) /* Look at each esc in line */ { register int i; @@ -3456,7 +3528,11 @@ if (!env) env = defenv; else - env = concat (env, defenv, ""); + { + char *oldenv = env; + env = concat (oldenv, defenv, ""); + free (oldenv); + } /* Allocate a token table */ for (size = 1, p = env; p;) @@ -3976,6 +4052,53 @@ return name; } +/* Look at the argument of --regex or --no-regex and do the right + thing. */ +void +analyse_regex (regex_arg) + char *regex_arg; +{ + struct stat stat_buf; + + if (regex_arg == NULL) + { + /* Remove existing regexps. */ + num_patterns = 0; + patterns = NULL; + return; + } + if (regex_arg[0] == '\0') + { + error ("missing regexp", (char *)NULL); + return; + } + if (regex_arg[0] == '@' + && stat (regex_arg + 1, &stat_buf) == 0 + && S_ISREG (stat_buf.st_mode)) + { + FILE *regexfp; + struct linebuffer regexbuf; + char *regexfile = regex_arg + 1; + + /* regexfile is a file containing regexps, one per line. */ + regexfp = fopen (regexfile, "r"); + if (regexfp == NULL) + { + perror (regexfile); + return; + } + initbuffer (®exbuf); + while (readline_internal (®exbuf, regexfp)) + add_regex (regexbuf.buffer); + free (regexbuf.buffer); + fclose (regexfp); + } + else + { + add_regex (regex_arg); + } +} + /* Turn a name, which is an ed-style (but Emacs syntax) regular expression, into a real regular expression by compiling it. */ void @@ -3986,19 +4109,7 @@ const char *err; struct re_pattern_buffer *patbuf; - if (regexp_pattern == NULL) - { - /* Remove existing regexps. */ - num_patterns = 0; - patterns = NULL; - return; - } - - if (regexp_pattern[0] == '\0') - { - error ("missing regexp", (char *)NULL); - return; - } + if (regexp_pattern[strlen(regexp_pattern)-1] != regexp_pattern[0]) { error ("%s: unterminated regexp", regexp_pattern); @@ -4238,7 +4349,7 @@ { ++lineno; linecharno = charno; - charno += readline (&lb, inf) + 1; + charno += readline (&lb, inf); } }
--- a/lib-src/gnuclient.c Mon Aug 13 09:35:15 2007 +0200 +++ b/lib-src/gnuclient.c Mon Aug 13 09:36:16 2007 +0200 @@ -2,6 +2,7 @@ Client code to allow local and remote editing of files by XEmacs. Copyright (C) 1989 Free Software Foundation, Inc. Copyright (C) 1995 Sun Microsystems, Inc. + Copyright (C) 1997 Free Software Foundation, Inc. This file is part of XEmacs. @@ -46,9 +47,15 @@ #include <stdio.h> #include <stdlib.h> +#ifdef HAVE_STRING_H #include <string.h> +#endif /* HAVE_STRING_H */ #include <sys/types.h> +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif /* HAVE_UNISTD_H */ +#include <signal.h> + #if !defined(SYSV_IPC) && !defined(UNIX_DOMAIN_SOCKETS) && \ !defined(INTERNET_DOMAIN_SOCKETS) @@ -66,27 +73,27 @@ static char cwd[MAXPATHLEN+2]; /* current working directory when calculated */ static char *cp = NULL; /* ptr into valid bit of cwd above */ -#ifdef GNUATTACH -#include <signal.h> - static pid_t emacs_pid; /* Process id for emacs process */ -void tell_emacs_to_resume(int sig) +void initialize_signals (void); + +void +tell_emacs_to_resume (int sig) { - char buffer[GSERV_BUFSZ+1]; - int s; /* socket / msqid to server */ - int connect_type; /* CONN_UNIX, CONN_INTERNET, or - * CONN_IPC */ + char buffer[GSERV_BUFSZ+1]; + int s; /* socket / msqid to server */ + int connect_type; /* CONN_UNIX, CONN_INTERNET, or + ONN_IPC */ /* Why is SYSV so retarded? */ /* We want emacs to realize that we are resuming */ - signal(SIGCONT, tell_emacs_to_resume); + signal(SIGCONT, tell_emacs_to_resume); - connect_type = make_connection (NULL, (u_short) 0, &s); + connect_type = make_connection (NULL, (u_short) 0, &s); - sprintf(buffer,"(server-eval '(resume-pid-console %d))", getpid()); - send_string(s, buffer); - + sprintf(buffer,"(gnuserv-eval '(resume-pid-console %d))", getpid()); + send_string(s, buffer); + #ifdef SYSV_IPC if (connect_type == (int) CONN_IPC) disconnect_from_ipc_server (s, msgp, FALSE); @@ -96,37 +103,32 @@ #endif /* !SYSV_IPC */ } -void pass_signal_to_emacs(int sig) +void +pass_signal_to_emacs (int sig) { - if (kill(emacs_pid, sig) == -1) { - fprintf(stderr, "gnuattach: Could not pass signal to emacs process\n"); - exit(1); - } + if (kill (emacs_pid, sig) == -1) + { + fprintf (stderr, "gnuattach: Could not pass signal to emacs process\n"); + exit (1); + } + initialize_signals (); } -void initialize_signals() +void +initialize_signals () { - /* Set up signal handler to pass relevant signals to emacs process */ - signal(SIGHUP, pass_signal_to_emacs); - signal(SIGQUIT, pass_signal_to_emacs); - signal(SIGILL, pass_signal_to_emacs); - signal(SIGTRAP, pass_signal_to_emacs); - signal(SIGSEGV, pass_signal_to_emacs); - signal(SIGPIPE, pass_signal_to_emacs); - signal(SIGTERM, pass_signal_to_emacs); -#ifdef SIGBUS - signal(SIGBUS, pass_signal_to_emacs); -#endif -#ifdef SIGIOT - signal(SIGIOT, pass_signal_to_emacs); -#endif + /* Set up signal handler to pass relevant signals to emacs process. + We used to send SIGSEGV, SIGBUS, SIGPIPE, SIGILL and others to + Emacs, but I think it's better not to. I can see no reason why + Emacs should SIGSEGV whenever gnuclient SIGSEGV-s, etc. */ + signal (SIGHUP, pass_signal_to_emacs); + signal (SIGQUIT, pass_signal_to_emacs); + signal (SIGINT, pass_signal_to_emacs); /* We want emacs to realize that we are resuming */ - signal(SIGCONT, tell_emacs_to_resume); + signal (SIGCONT, tell_emacs_to_resume); } -#endif /* GNUATTACH */ - /* get_current_working_directory -- return the cwd. @@ -192,17 +194,18 @@ main (int argc, char *argv[]) { int starting_line = 1; /* line to start editing at */ - char command[MAXPATHLEN+50]; /* emacs command buffer */ + char command[MAXPATHLEN+50]; /* emacs command buffer */ char fullpath[MAXPATHLEN+1]; /* full pathname to file */ -#ifndef GNUATTACH int qflg = 0; /* quick edit, don't wait for * user to finish */ -#endif + int view = 0; /* view only. */ int errflg = 0; /* option error */ int c; /* char from getopt */ int s; /* socket / msqid to server */ int connect_type; /* CONN_UNIX, CONN_INTERNET, or * CONN_IPC */ + int suppress_windows_system = 0; + char *display; #ifdef INTERNET_DOMAIN_SOCKETS char *hostarg = NULL; /* remote hostname */ char thishost[HOSTNAMSZ]; /* this hostname */ @@ -214,10 +217,8 @@ #ifdef SYSV_IPC struct msgbuf *msgp; /* message */ #endif /* SYSV_IPC */ -#ifdef GNUATTACH char *tty; char buffer[GSERV_BUFSZ+1]; /* buffer to read pid */ -#endif #ifdef INTERNET_DOMAIN_SOCKETS memset (remotepath, 0, sizeof (remotepath)); @@ -225,26 +226,33 @@ progname = argv[0]; + display = getenv ("DISPLAY"); + if (!display) + suppress_windows_system = 1; + while ((c = getopt (argc, argv, #ifdef INTERNET_DOMAIN_SOCKETS - "h:p:r:q" + "n:h:p:r:qv" #else /* !INTERNET_DOMAIN_SOCKETS */ -# ifdef GNUATTACH - "" -# else - "q" -# endif + "n:qv" #endif /* !INTERNET_DOMAIN_SOCKETS */ )) != EOF) switch (c) { -#ifndef GNUATTACH + case 'n': + if (*optarg == 'w') + suppress_windows_system++; + else + errflg++; + break; case 'q': /* quick mode specified */ qflg++; break; -#endif + case 'v': + view++; + break; #ifdef INTERNET_DOMAIN_SOCKETS case 'h': /* server host name specified */ @@ -270,41 +278,38 @@ "usage: %s [-q] [-h hostname] [-p port] [-r pathname] " "[[+line] path] ...\n", #else /* !INTERNET_DOMAIN_SOCKETS */ -# ifdef GNUATTACH - "usage: %s [[+line] path] ...\n", -# else - "usage: %s [-q] [[+line] path] ...\n", -# endif + "usage: %s [-nw] [-q] [[+line] path] ...\n", #endif /* !INTERNET_DOMAIN_SOCKETS */ progname); exit (1); } /* if */ -#ifdef GNUATTACH - tty = ttyname (0); - if (!tty) + if (suppress_windows_system) { - fprintf (stderr, "%s: Not connected to a tty", progname); - exit (1); + tty = ttyname (0); + if (!tty) + { + fprintf (stderr, "%s: Not connected to a tty", progname); + exit (1); + } } - - /* This next stuff added in an attempt to make handling of - the tty do the right thing when dealing with signals. - Idea is to pass all the appropriate signals to the emacs process - */ + /* This next stuff added in an attempt to make handling of the tty + do the right thing when dealing with signals. The idea is to + pass all the appropriate signals to the emacs process. */ connect_type = make_connection (NULL, (u_short) 0, &s); - send_string(s,"(server-eval '(emacs-pid))"); - send_string(s,EOT_STR); - - if (read_line(s,buffer) == 0) { - fprintf(stderr, "%s: Could not establish emacs procces id\n",progname); - exit(1); - } - /* don't do disconnect_from_server becasue we have already read data, - and disconnect doesn't do anything else - */ + send_string (s, "(gnuserv-eval '(emacs-pid))"); + send_string (s, EOT_STR); + + if (read_line (s, buffer) == 0) + { + fprintf (stderr, "%s: Could not establish emacs procces id\n", + progname); + exit (1); + } + /* Don't do disconnect_from_server becasue we have already read + data, and disconnect doesn't do anything else. */ #ifdef SYSV_IPC if (connect_type == (int) CONN_IPC) disconnect_from_ipc_server (s, msgp, FALSE); @@ -312,8 +317,6 @@ emacs_pid = (pid_t)atol(buffer); initialize_signals(); - -#endif /*GNUATTACH */ #if defined(INTERNET_DOMAIN_SOCKETS) && !defined(GNUATTACH) connect_type = make_connection (hostarg, portarg, &s); @@ -360,48 +363,53 @@ msgp->mtext[0] = '\0'; /* ready for later strcats */ #endif /* SYSV_IPC */ -#ifdef GNUATTACH - ptr = getenv ("TERM"); - if (!ptr) + if (suppress_windows_system) { - fprintf (stderr, "%s: unknown terminal type\n", progname); - exit (1); + ptr = getenv ("TERM"); + if (!ptr) + { + fprintf (stderr, "%s: unknown terminal type\n", progname); + exit (1); + } + sprintf (command, + "(gnuserv-edit-files '(tty \"%s\" \"%s\" %d) '(", + tty, ptr, getpid ()); } - sprintf (command, "(server-tty-edit-files \"%s\" \"%s\" %d '(", - tty, ptr, getpid()); + else /* !suppress_windows_system */ + { + sprintf (command, "(gnuserv-edit-files '(x \"%s\") '(", + display); + } /* !suppress_windows_system */ send_string (s, command); -#else - if (qflg) - { - send_string (s, "(server-edit-files-quickly '("); - } - else - { - send_string (s, "(server-edit-files '("); - } -#endif + + if (!suppress_windows_system && (optind == argc)) + qflg = 1; for (; optind < argc; optind++) { - if (*argv[optind] == '+') - starting_line = atoi (argv[optind]); + if (optind < argc - 1 && *argv[optind] == '+') + starting_line = atoi (argv[optind++]); else + starting_line = 1; + /* If the last argument is +something, treat it as a file. */ + if (optind == argc) { - filename_expand (fullpath, argv[optind]); - sprintf (command, "(%d . \"%s%s\")", starting_line, - + starting_line = 1; + --optind; + } + filename_expand (fullpath, argv[optind]); + sprintf (command, "(%d . \"%s%s\")", starting_line, #ifdef INTERNET_DOMAIN_SOCKETS - remotepath, + remotepath, #else /* !INTERNET_DOMAIN_SOCKETS */ - "", + "", #endif - fullpath); - send_string (s,command); - starting_line = 1; - } /* else */ + fullpath); + send_string (s, command); } /* for */ - send_string (s,"))"); + sprintf (command, ") %s)", qflg ? "'quick" : (view ? "'view" : "")); + send_string (s, command); #ifdef SYSV_IPC if (connect_type == (int) CONN_IPC)
--- a/lib-src/gnudoit.c Mon Aug 13 09:35:15 2007 +0200 +++ b/lib-src/gnudoit.c Mon Aug 13 09:36:16 2007 +0200 @@ -32,7 +32,9 @@ #include <stdlib.h> #include <stdio.h> #include <sys/types.h> +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif /* HAVE_UNISTD_H */ #if !defined(SYSV_IPC) && !defined(UNIX_DOMAIN_SOCKETS) && !defined(INTERNET_DOMAIN_SOCKETS) int @@ -115,10 +117,10 @@ #endif /* SYSV_IPC */ if (qflg) { - send_string(s,"(server-eval-quickly '(progn "); + send_string(s,"(gnuserv-eval-quickly '(progn "); } else { - send_string(s,"(server-eval '(progn "); + send_string(s,"(gnuserv-eval '(progn "); }; if (optind < argc) {
--- a/lib-src/gnuserv.c Mon Aug 13 09:35:15 2007 +0200 +++ b/lib-src/gnuserv.c Mon Aug 13 09:36:16 2007 +0200 @@ -51,8 +51,13 @@ #include <stdio.h> #include <sys/types.h> #include <sys/stat.h> + +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif /* HAVE_UNISTD_H */ +#ifdef HAVE_STRING_H #include <string.h> +#endif /* HAVE_STRING_H */ #if !defined(SYSV_IPC) && !defined(UNIX_DOMAIN_SOCKETS) && \ !defined(INTERNET_DOMAIN_SOCKETS) @@ -74,25 +79,25 @@ ipc_exit -- clean up the queue id and queue, then kill the watchdog task if it exists. exit with the given status. */ -void ipc_exit(stat) - int stat; +void +ipc_exit (int stat) { - msgctl(ipc_qid,IPC_RMID,0); + msgctl (ipc_qid,IPC_RMID,0); - if (ipc_wpid != 0) - kill(ipc_wpid,SIGKILL); + if (ipc_wpid != 0) + kill (ipc_wpid, SIGKILL); - exit(stat); + exit (stat); } /* ipc_exit */ /* ipc_handle_signal -- catch the signal given and clean up. */ -void ipc_handle_signal(sig) - int sig; +void +ipc_handle_signal(int sig) { - ipc_exit(0); + ipc_exit (0); } /* ipc_handle_signal */ @@ -100,21 +105,26 @@ ipc_spawn_watchdog -- spawn a watchdog task to clean up the message queue should the server process die. */ -void ipc_spawn_watchdog() +void +ipc_spawn_watchdog (void) { - if ((ipc_wpid = fork()) == 0) { /* child process */ - int ppid = getppid(); /* parent's process id */ + if ((ipc_wpid = fork ()) == 0) + { /* child process */ + int ppid = getppid (); /* parent's process id */ + + setpgrp(); /* gnu kills process group on exit */ - setpgrp(); /* gnu kills process group on exit */ - - while (1) { - if (kill(ppid,0) < 0) { /* ppid is no longer valid, parent may have died */ - ipc_exit(0); - } /* if */ + while (1) + { + if (kill (ppid, 0) < 0) /* ppid is no longer valid, parent + may have died */ + { + ipc_exit (0); + } /* if */ - sleep(10); /* have another go later */ - } /* while */ - } /* if */ + sleep(10); /* have another go later */ + } /* while */ + } /* if */ } /* ipc_spawn_watchdog */ @@ -122,34 +132,35 @@ /* ipc_init -- initialize server, setting the global msqid that can be listened on. */ -void ipc_init(msgpp) - struct msgbuf **msgpp; +void +ipc_init (struct msgbuf **msgpp) { key_t key; /* messge key */ char buf[GSERV_BUFSZ]; /* pathname for key */ - sprintf(buf,"/tmp/gsrv%d",(int)geteuid()); - creat(buf,0600); - key = ftok(buf,1); + sprintf (buf,"/tmp/gsrv%d",(int)geteuid ()); + creat (buf,0600); + key = ftok (buf,1); - if ((ipc_qid = msgget(key,0600|IPC_CREAT)) == -1) { - perror(progname); - fprintf(stderr,"%s: unable to create msg queue\n",progname); - ipc_exit(1); - } /* if */ + if ((ipc_qid = msgget (key,0600|IPC_CREAT)) == -1) + { + perror (progname); + fprintf (stderr, "%s: unable to create msg queue\n", progname); + ipc_exit (1); + } /* if */ - ipc_spawn_watchdog(); + ipc_spawn_watchdog (); - signal(SIGTERM,ipc_handle_signal); - signal(SIGINT,ipc_handle_signal); + signal (SIGTERM,ipc_handle_signal); + signal (SIGINT,ipc_handle_signal); - if ((*msgpp = (struct msgbuf *) - malloc(sizeof **msgpp + GSERV_BUFSZ)) == NULL) { - fprintf(stderr, - "%s: unable to allocate space for message buffer\n",progname); - ipc_exit(1); - } /* if */ - + if ((*msgpp = (struct msgbuf *) + malloc (sizeof **msgpp + GSERV_BUFSZ)) == NULL) + { + fprintf (stderr, + "%s: unable to allocate space for message buffer\n", progname); + ipc_exit(1); + } /* if */ } /* ipc_init */ @@ -158,8 +169,8 @@ to the GNU Emacs process, then wait for its reply and pass that on to the client. */ -void handle_ipc_request(msgp) - struct msgbuf *msgp; /* message buffer */ +void +handle_ipc_request (struct msgbuf *msgp) { struct msqid_ds msg_st; /* message status */ char buf[GSERV_BUFSZ]; @@ -168,91 +179,100 @@ int offset = 0; int total = 1; /* # bytes that will actually be sent off */ - if ((len = msgrcv(ipc_qid,msgp,GSERV_BUFSZ-1,1,0)) < 0) { - perror(progname); - fprintf(stderr,"%s: unable to receive\n",progname); - ipc_exit(1); - } /* if */ + if ((len = msgrcv (ipc_qid, msgp, GSERV_BUFSZ - 1, 1, 0)) < 0) + { + perror (progname); + fprintf (stderr, "%s: unable to receive\n", progname); + ipc_exit (1); + } /* if */ - msgctl(ipc_qid,IPC_STAT,&msg_st); - strncpy(buf,msgp->mtext,len); + msgctl (ipc_qid, IPC_STAT, &msg_st); + strncpy (buf, msgp->mtext, len); buf[len] = '\0'; /* terminate */ - printf("%d %s",ipc_qid,buf); - fflush(stdout); + printf ("%d %s", ipc_qid, buf); + fflush (stdout); /* now for the response from gnu */ msgp->mtext[0] = '\0'; #if 0 - if ((len = read(0,buf,GSERV_BUFSZ-1)) < 0) { - perror(progname); - fprintf(stderr,"%s: unable to read\n",progname); - ipc_exit(1); + if ((len = read(0,buf,GSERV_BUFSZ-1)) < 0) + { + perror (progname); + fprintf (stderr, "%s: unable to read\n", progname); + ipc_exit (1); } /* if */ - - sscanf(buf,"%d:%[^\n]\n",&junk,msgp->mtext); -#else + + sscanf (buf, "%d:%[^\n]\n", &junk, msgp->mtext); +#else /* read in "n/m:" (n=client fd, m=message length) */ while (offset < (GSERV_BUFSZ-1) && - ((len = read(0,buf+offset,1)) > 0) && - buf[offset] != ':') { - offset += len; - } + ((len = read (0, buf + offset, 1)) > 0) && + buf[offset] != ':') + { + offset += len; + } - if (len < 0) { - perror(progname); - fprintf(stderr,"%s: unable to read\n",progname); - exit(1); - } - - /* parse the response from emacs, getting client fd & result length */ - buf[offset] = '\0'; - sscanf(buf,"%d/%d", &s, &result_len); - - while (result_len > 0) { - if ((len = read(0,buf,min2(result_len, GSERV_BUFSZ - 1))) < 0) { - perror(progname); - fprintf(stderr,"%s: unable to read\n",progname); + if (len < 0) + { + perror (progname); + fprintf (stderr, "%s: unable to read\n", progname); exit(1); } - /* Send this string off, but only if we have enough space */ + /* parse the response from emacs, getting client fd & result length */ + buf[offset] = '\0'; + sscanf (buf, "%d/%d", &s, &result_len); + + while (result_len > 0) + { + if ((len = read(0, buf, min2 (result_len, GSERV_BUFSZ - 1))) < 0) + { + perror (progname); + fprintf (stderr, "%s: unable to read\n", progname); + exit (1); + } - if (GSERV_BUFSZ > total) { - if (total + len <= GSERV_BUFSZ) - buf[len] = 0; - else - buf[GSERV_BUFSZ - total] = 0; + /* Send this string off, but only if we have enough space */ - send_string(s,buf); - total += strlen(buf); + if (GSERV_BUFSZ > total) + { + if (total + len <= GSERV_BUFSZ) + buf[len] = 0; + else + buf[GSERV_BUFSZ - total] = 0; + + send_string(s,buf); + total += strlen(buf); + } + + result_len -= len; } - result_len -= len; - } - /* eat the newline */ - while ((len = read(0,buf,1)) == 0) + while ((len = read (0,buf,1)) == 0) ; - if (len < 0) { - perror(progname); - fprintf(stderr,"%s: unable to read\n",progname); - exit(1); - } - if (buf[0] != '\n') { - fprintf(stderr,"%s: garbage after result [%c]\n",progname, buf[0]); - exit(1); - } + if (len < 0) + { + perror(progname); + fprintf (stderr,"%s: unable to read\n", progname); + exit (1); + } + if (buf[0] != '\n') + { + fprintf (stderr,"%s: garbage after result [%c]\n", progname, buf[0]); + exit (1); + } #endif /* Send a response back to the client. */ msgp->mtype = msg_st.msg_lspid; - if (msgsnd(ipc_qid,msgp,strlen(msgp->mtext)+1,0) < 0) - perror("msgsend(gnuserv)"); + if (msgsnd (ipc_qid,msgp,strlen(msgp->mtext)+1,0) < 0) + perror ("msgsend(gnuserv)"); } /* handle_ipc_request */ #endif /* SYSV_IPC */ @@ -336,15 +356,17 @@ /* eat the newline */ while ((len = read(0,buf,1)) == 0) ; - if (len < 0) { - perror(progname); - fprintf(stderr,"%s: unable to read\n",progname); - exit(1); - } - if (buf[0] != '\n') { - fprintf(stderr,"%s: garbage after result\n",progname); - exit(1); - } + if (len < 0) + { + perror(progname); + fprintf(stderr,"%s: unable to read\n",progname); + exit(1); + } + if (buf[0] != '\n') + { + fprintf(stderr,"%s: garbage after result\n",progname); + exit(1); + } /* send the newline */ buf[1] = '\0'; send_string(s,buf); @@ -384,30 +406,40 @@ FD_ZERO(&rmask); FD_SET(fd, &rmask); - do { - r = select(fd + 1, &rmask, NULL, NULL, &tv); + do + { + r = select(fd + 1, &rmask, NULL, NULL, &tv); - if (r > 0) { - if (read (fd, &c, 1) == 1 ){ - *buf++ = c; - ++nbytes; - } else { - printf ("read error on socket\004\n"); - return -1; - } - } else if (r == 0) { - printf ("read timed out\004\n"); - return -1; - } else { - printf ("error in select\004\n"); - return -1; - } - } while ((nbytes < max) && !(one_line && (c == '\n'))); + if (r > 0) + { + if (read (fd, &c, 1) == 1 ) + { + *buf++ = c; + ++nbytes; + } + else + { + printf ("read error on socket\004\n"); + return -1; + } + } + else if (r == 0) + { + printf ("read timed out\004\n"); + return -1; + } + else + { + printf ("error in select\004\n"); + return -1; + } + } while ((nbytes < max) && !(one_line && (c == '\n'))); --buf; - if (one_line && *buf == '\n') { - *buf = 0; - } + if (one_line && *buf == '\n') + { + *buf = 0; + } return nbytes; } @@ -427,44 +459,48 @@ char buf[1024]; int auth_data_len; - if (fd > 0) { - /* we are checking permission on a real connection */ - - /* Read auth protocol name */ - - if (timed_read(fd, auth_protocol, AUTH_NAMESZ, AUTH_TIMEOUT, 1) <= 0) - return FALSE; + if (fd > 0) + { + /* we are checking permission on a real connection */ - if (strcmp (auth_protocol, DEFAUTH_NAME) && - strcmp (auth_protocol, MCOOKIE_NAME)) { - printf ("authentication protocol (%s) from client is invalid...\n", - auth_protocol); - printf ("... Was the client an old version of gnuclient/gnudoit?\004\n"); - - return FALSE; - } - - if (!strcmp(auth_protocol, MCOOKIE_NAME)) { - - /* - * doing magic cookie auth - */ - - if (timed_read(fd, buf, 10, AUTH_TIMEOUT, 1) <= 0) + /* Read auth protocol name */ + + if (timed_read(fd, auth_protocol, AUTH_NAMESZ, AUTH_TIMEOUT, 1) <= 0) return FALSE; - auth_data_len = atoi(buf); + if (strcmp (auth_protocol, DEFAUTH_NAME) && + strcmp (auth_protocol, MCOOKIE_NAME)) + { + printf ("authentication protocol (%s) from client is invalid...\n", + auth_protocol); + printf ("... Was the client an old version of gnuclient/gnudoit?\004\n"); + + return FALSE; + } - if (timed_read(fd, buf, auth_data_len, AUTH_TIMEOUT, 0) != auth_data_len) - return FALSE; + if (!strcmp(auth_protocol, MCOOKIE_NAME)) + { + + /* + * doing magic cookie auth + */ + + if (timed_read(fd, buf, 10, AUTH_TIMEOUT, 1) <= 0) + return FALSE; + + auth_data_len = atoi(buf); + + if (timed_read(fd, buf, auth_data_len, AUTH_TIMEOUT, 0) != auth_data_len) + return FALSE; #ifdef AUTH_MAGIC_COOKIE - if (server_xauth && server_xauth->data && - !memcmp(buf, server_xauth->data, auth_data_len)) { - return TRUE; - } + if (server_xauth && server_xauth->data && + !memcmp(buf, server_xauth->data, auth_data_len)) + { + return TRUE; + } #else - printf ("client tried Xauth, but server is not compiled with Xauth\n"); + printf ("client tried Xauth, but server is not compiled with Xauth\n"); #endif /* @@ -472,15 +508,15 @@ * protocol.... */ - printf ("Xauth authentication failed, trying GNU_SECURE auth...\004\n"); + printf ("Xauth authentication failed, trying GNU_SECURE auth...\004\n"); + + } + + /* Other auth protocols go here, and should execute only if the + * auth_protocol name matches. + */ } - - /* Other auth protocols go here, and should execute only if the - * auth_protocol name matches. - */ - - } /* Now, try the old GNU_SECURE stuff... */ @@ -508,19 +544,20 @@ int key; struct entry *new_entry; - if (!permitted(host_addr, -1)) { - if ((new_entry = (struct entry *) malloc(sizeof(struct entry))) == NULL) { - fprintf(stderr,"%s: unable to malloc space for permitted host entry\n", - progname); - exit(1); + if (!permitted(host_addr, -1)) + { + if ((new_entry = (struct entry *) malloc(sizeof(struct entry))) == NULL) { + fprintf(stderr,"%s: unable to malloc space for permitted host entry\n", + progname); + exit(1); + } /* if */ + + new_entry->host_addr = host_addr; + key = HASH(host_addr) % TABLE_SIZE; + new_entry->next = permitted_hosts[key]; + permitted_hosts[key] = new_entry; } /* if */ - new_entry->host_addr = host_addr; - key = HASH(host_addr) % TABLE_SIZE; - new_entry->next = permitted_hosts[key]; - permitted_hosts[key] = new_entry; - } /* if */ - } /* add_host */ @@ -547,11 +584,12 @@ gethostname(hostname,HOSTNAMSZ); - if ((host_addr = internet_addr(hostname)) == -1) { - fprintf(stderr,"%s: unable to find %s in /etc/hosts or from YP", - progname,hostname); - exit(1); - } /* if */ + if ((host_addr = internet_addr(hostname)) == -1) + { + fprintf(stderr,"%s: unable to find %s in /etc/hosts or from YP", + progname,hostname); + exit(1); + } /* if */ #ifdef AUTH_MAGIC_COOKIE @@ -569,14 +607,16 @@ #endif if (((file_name = getenv("GNU_SECURE")) != NULL && /* security file */ - (host_file = fopen(file_name,"r")) != NULL)) { /* opened ok */ - while ((fscanf(host_file,"%s",hostname) != EOF)) /* find a host */ - if ((host_addr = internet_addr(hostname)) != -1) {/* get its addr */ - add_host(host_addr); /* add the addr */ - hosts++; - } - fclose(host_file); - } /* if */ + (host_file = fopen(file_name,"r")) != NULL)) /* opened ok */ + { + while ((fscanf(host_file,"%s",hostname) != EOF)) /* find a host */ + if ((host_addr = internet_addr(hostname)) != -1)/* get its addr */ + { + add_host(host_addr); /* add the addr */ + hosts++; + } + fclose(host_file); + } /* if */ return hosts; } /* setup_table */ @@ -615,27 +655,30 @@ server.sin_port = sp->s_port; /* Create the listen socket. */ - if ((ls = socket (AF_INET,SOCK_STREAM, 0)) == -1) { - perror(progname); - fprintf(stderr,"%s: unable to create socket\n",progname); - exit(1); - } /* if */ + if ((ls = socket (AF_INET,SOCK_STREAM, 0)) == -1) + { + perror(progname); + fprintf(stderr,"%s: unable to create socket\n",progname); + exit(1); + } /* if */ /* Bind the listen address to the socket. */ - if (bind(ls,(struct sockaddr *) &server,sizeof(struct sockaddr_in)) == -1) { - perror(progname); - fprintf(stderr,"%s: unable to bind socket\n",progname); - exit(1); - } /* if */ + if (bind(ls,(struct sockaddr *) &server,sizeof(struct sockaddr_in)) == -1) + { + perror(progname); + fprintf(stderr,"%s: unable to bind socket\n",progname); + exit(1); + } /* if */ /* Initiate the listen on the socket so remote users * can connect. */ - if (listen(ls,20) == -1) { - perror(progname); - fprintf(stderr,"%s: unable to listen\n",progname); - exit(1); - } /* if */ + if (listen(ls,20) == -1) + { + perror(progname); + fprintf(stderr,"%s: unable to listen\n",progname); + exit(1); + } /* if */ return(ls); @@ -655,20 +698,22 @@ memset((char *)&peer,0,sizeof(struct sockaddr_in)); - if ((s = accept(ls,(struct sockaddr *)&peer,&addrlen)) == -1) { - perror(progname); - fprintf(stderr,"%s: unable to accept\n",progname); - exit(1); - } /* if */ + if ((s = accept(ls,(struct sockaddr *)&peer,&addrlen)) == -1) + { + perror(progname); + fprintf(stderr,"%s: unable to accept\n",progname); + exit(1); + } /* if */ /* Check that access is allowed - if not return crud to the client */ - if (!permitted(peer.sin_addr.s_addr, s)) { - send_string(s,"gnudoit: Connection refused\ngnudoit: unable to connect to remote"); - close(s); + if (!permitted(peer.sin_addr.s_addr, s)) + { + send_string(s,"gnudoit: Connection refused\ngnudoit: unable to connect to remote"); + close(s); - printf("Refused connection from %s\004\n", inet_ntoa(peer.sin_addr)); - return; - } /* if */ + printf("Refused connection from %s\004\n", inet_ntoa(peer.sin_addr)); + return; + } /* if */ echo_request(s); @@ -688,24 +733,27 @@ struct sockaddr_un server; /* unix socket address */ int bindlen; - if ((ls = socket(AF_UNIX,SOCK_STREAM, 0)) < 0) { - perror(progname); - fprintf(stderr,"%s: unable to create socket\n",progname); - exit(1); - } /* if */ + if ((ls = socket(AF_UNIX,SOCK_STREAM, 0)) < 0) + { + perror(progname); + fprintf(stderr,"%s: unable to create socket\n",progname); + exit(1); + } /* if */ /* Set up address structure for the listen socket. */ #ifdef HIDE_UNIX_SOCKET sprintf(server.sun_path,"/tmp/gsrvdir%d",(int)geteuid()); - if (mkdir(server.sun_path, 0700) < 0) { - /* assume it already exists, and try to set perms */ - if (chmod(server.sun_path, 0700) < 0) { - perror(progname); - fprintf(stderr,"%s: can't set permissions on %s\n", - progname, server.sun_path); - exit(1); + if (mkdir(server.sun_path, 0700) < 0) + { + /* assume it already exists, and try to set perms */ + if (chmod(server.sun_path, 0700) < 0) + { + perror(progname); + fprintf(stderr,"%s: can't set permissions on %s\n", + progname, server.sun_path); + exit(1); + } } - } strcat(server.sun_path,"/gsrv"); unlink(server.sun_path); /* remove old file if it exists */ #else /* HIDE_UNIX_SOCKET */ @@ -724,11 +772,12 @@ bindlen = strlen (server.sun_path) + sizeof (server.sun_family); #endif - if (bind(ls,(struct sockaddr *)&server,bindlen) < 0) { - perror(progname); - fprintf(stderr,"%s: unable to bind socket\n",progname); - exit(1); - } /* if */ + if (bind(ls,(struct sockaddr *)&server,bindlen) < 0) + { + perror(progname); + fprintf(stderr,"%s: unable to bind socket\n",progname); + exit(1); + } /* if */ chmod(server.sun_path,0700); /* only this user can send commands */ @@ -769,10 +818,11 @@ server.sun_family = AF_UNIX; - if ((s = accept(ls,(struct sockaddr *)&server,&len)) < 0) { - perror(progname); - fprintf(stderr,"%s: unable to accept\n",progname); - } /* if */ + if ((s = accept(ls,(struct sockaddr *)&server,&len)) < 0) + { + perror(progname); + fprintf(stderr,"%s: unable to accept\n",progname); + } /* if */ echo_request(s); @@ -834,11 +884,12 @@ FD_SET(ils, &rmask); if (select(max2(fileno(stdin),max2(uls,ils)) + 1, &rmask, - (fd_set *)NULL, (fd_set *)NULL, (struct timeval *)NULL) < 0) { - perror(progname); - fprintf(stderr,"%s: unable to select\n",progname); - exit(1); - } /* if */ + (fd_set *)NULL, (fd_set *)NULL, (struct timeval *)NULL) < 0) + { + perror(progname); + fprintf(stderr,"%s: unable to select\n",progname); + exit(1); + } /* if */ #ifdef UNIX_DOMAIN_SOCKETS if (uls > 0 && FD_ISSET(uls, &rmask))
--- a/lib-src/gnuslib.c Mon Aug 13 09:35:15 2007 +0200 +++ b/lib-src/gnuslib.c Mon Aug 13 09:36:16 2007 +0200 @@ -63,8 +63,12 @@ #include <stdio.h> #include <sys/types.h> #include <sys/stat.h> +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif /* HAVE_UNISTD_H */ +#ifdef HAVE_STRING_H #include <string.h> +#endif /* HAVE_STRING_H */ #include <arpa/inet.h>
--- a/lib-src/movemail.c Mon Aug 13 09:35:15 2007 +0200 +++ b/lib-src/movemail.c Mon Aug 13 09:36:16 2007 +0200 @@ -134,7 +134,7 @@ #endif char *strerror (); -void fatal (); +void fatal (char *, char*); void error (); void pfatal_with_name (); void pfatal_and_delete ();
--- a/lib-src/profile.c Mon Aug 13 09:35:15 2007 +0200 +++ b/lib-src/profile.c Mon Aug 13 09:36:16 2007 +0200 @@ -73,8 +73,8 @@ return time_string; } -void -main (void) +int +main (int argc, char *argv[]) { int c; while ((c = getchar ()) != EOF) @@ -94,5 +94,5 @@ while (c != '\n' && c != EOF) c = getchar (); } - exit (1); + return 1; }
--- a/lisp/ChangeLog Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/ChangeLog Mon Aug 13 09:36:16 2007 +0200 @@ -1,3 +1,40 @@ +Fri Apr 25 13:21:46 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * apropos.el (apropos): Add support for customization groups. + (apropos-print): Ditto. + +Sat May 17 19:56:31 1997 Glynn Clements <glynn@sensei.co.uk> + + * packages/man.el (manual-entry): Strip out stderr output. + +Sun May 11 18:24:25 1997 Kyle Jones <kyle@crystal.WonderWorks.COM> + + * lisp/prim/modeline.el: new mouse-drag-modeline function. + Allows bottommost modeline to be dragged. + +Sat May 17 03:41:11 1997 Steven L Baur <steve@altair.xemacs.org> + + * cl/cl-macs.el: A whole bunch of XEmacs specific setf methods + from Hrvoje Niksic. + + * prim/files.el (auto-mode-alist): Don't copy to purespace. + (interpreter-mode-alist): Ditto. + +Fri May 16 21:43:35 1997 Steven L Baur <steve@altair.xemacs.org> + + * packages/info.el (Info-button1-follows-hyperlink): New variable. + (Info-maybe-follow-clicked-node): Use it. + + * prim/simple.el (transpose-preceding-chars): New function. + +Wed Apr 23 16:04:22 1997 Hrvoje Niksic <hniksic@srce.hr> + + * prim/loaddefs.el (debug-ignored-errors): Initialize. + +Fri May 16 20:37:35 1997 Steven L Baur <steve@altair.xemacs.org> + + * version.el: Update minor version number. + Mon May 12 13:47:37 1997 Oscar Figueiredo <Oscar.Figueiredo@di.epfl.ch> * tm/tm-vm.el: Provide for vm-unsaved-message having been removed
--- a/lisp/bytecomp/byte-optimize.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/bytecomp/byte-optimize.el Mon Aug 13 09:36:16 2007 +0200 @@ -2,7 +2,7 @@ ;;; Copyright (c) 1991, 1994 Free Software Foundation, Inc. -;; Author: Jamie Zawinski <jwz@lucid.com> +;; Author: Jamie Zawinski <jwz@netscape.com> ;; Hallvard Furuseth <hbf@ulrik.uio.no> ;; Keywords: internal
--- a/lisp/bytecomp/bytecomp-runtime.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/bytecomp/bytecomp-runtime.el Mon Aug 13 09:36:16 2007 +0200 @@ -2,7 +2,7 @@ ;; Copyright (C) 1992 Free Software Foundation, Inc. -;; Author: Jamie Zawinski <jwz@lucid.com> +;; Author: Jamie Zawinski <jwz@netscape.com> ;; Hallvard Furuseth <hbf@ulrik.uio.no> ;; Keywords: internal
--- a/lisp/bytecomp/bytecomp.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/bytecomp/bytecomp.el Mon Aug 13 09:36:16 2007 +0200 @@ -1746,7 +1746,7 @@ (char-to-string 255))) (eq (point) (point-max))) (setq buffer-file-coding-system 'no-conversion) - (insert ";;;###coding system: escape-quoted\n") + (insert "(require 'mule)\n;;;###coding system: escape-quoted\n") (setq buffer-file-coding-system 'escape-quoted) ;; Lazy loading not yet implemented for MULE files ;; mrb - Fix this someday.
--- a/lisp/bytecomp/disass.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/bytecomp/disass.el Mon Aug 13 09:36:16 2007 +0200 @@ -3,8 +3,8 @@ ;;; Copyright (C) 1986, 1991-1994 Free Software Foundation, Inc. ;; Author: Doug Cutting <doug@csli.stanford.edu> -;; Jamie Zawinski <jwz@lucid.com> -;; Maintainer: Jamie Zawinski <jwz@lucid.com> +;; Jamie Zawinski <jwz@netscape.com> +;; Maintainer: Jamie Zawinski <jwz@netscape.com> ;; Keywords: internal ;; This file is part of XEmacs. @@ -34,7 +34,7 @@ ;; ;; Original version by Doug Cutting (doug@csli.stanford.edu) -;; Substantially modified by Jamie Zawinski <jwz@lucid.com> for +;; Substantially modified by Jamie Zawinski for ;; the new lapcode-based byte compiler. ;;; Code:
--- a/lisp/cl/cl-macs.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/cl/cl-macs.el Mon Aug 13 09:36:16 2007 +0200 @@ -1623,6 +1623,27 @@ (defsetf frame-parameters modify-frame-parameters t) (defsetf frame-visible-p cl-set-frame-visible-p) (defsetf frame-width set-screen-width t) + +;; XEmacs: new stuff +(defsetf selected-console select-console t) +(defsetf selected-device select-device t) +(defsetf device-baud-rate (&optional d) (v) + `(set-device-baud-rate ,d ,v)) +(defsetf current-frame-configuration set-frame-configuration) +(defsetf frame-properties (&optional f) (p) + `(progn (set-frame-properties ,f ,p) ,p)) +(defsetf frame-property (f p &optional d) (v) + `(progn (set-frame-property ,f ,v) ,p)) +(defsetf specifier-instance (spec &optional dom def nof) (val) + `(set-specifier ,spec ,val ,dom)) +(defsetf annotation-glyph set-annotation-glyph) +(defsetf annotation-down-glyph set-annotation-down-glyph) +(defsetf annotation-face set-annotation-face) +(defsetf annotation-layout set-annotation-layout) +(defsetf annotation-data set-annotation-data) +(defsetf annotation-action set-annotation-action) +(defsetf annotation-menu set-annotation-menu) + (defsetf getenv setenv t) (defsetf get-register set-register) (defsetf global-key-binding global-set-key)
--- a/lisp/comint/comint.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/comint/comint.el Mon Aug 13 09:36:16 2007 +0200 @@ -645,7 +645,7 @@ (append menu (comint-make-history-menu))) (defun comint-make-history-menu () - (if (or (not (ring-p comint-input-ring)) + (if (or (not (ringp comint-input-ring)) (ring-empty-p comint-input-ring)) nil (let ((menu nil) @@ -904,7 +904,7 @@ (defun comint-dynamic-list-input-ring () "List in help buffer the buffer's input history." (interactive) - (if (or (not (ring-p comint-input-ring)) + (if (or (not (ringp comint-input-ring)) (ring-empty-p comint-input-ring)) (message "No history") (let ((history nil) @@ -991,7 +991,7 @@ (defun comint-previous-matching-input-string-position (regexp arg &optional start) "Return the index matching REGEXP ARG places along the input ring. Moves relative to START, or `comint-input-ring-index'." - (if (or (not (ring-p comint-input-ring)) + (if (or (not (ringp comint-input-ring)) (ring-empty-p comint-input-ring)) (error "No history")) (let* ((len (ring-length comint-input-ring)) @@ -1258,7 +1258,7 @@ (let ((argpart "[^ \n\t\"'`]+\\|\\(\"[^\"]*\"\\|'[^']*'\\|`[^`]*`\\)") (args ()) (pos 0) (count 0) - beg str value quotes) + beg str quotes) ;; Build a list of all the args until we have as many as we want. (while (and (or (null mth) (<= count mth)) (string-match argpart string pos)) @@ -1385,7 +1385,7 @@ (insert ?\n)) (if (and (funcall comint-input-filter history) (or (null comint-input-ignoredups) - (not (ring-p comint-input-ring)) + (not (ringp comint-input-ring)) (ring-empty-p comint-input-ring) (not (string-equal (ring-ref comint-input-ring 0) history)))) @@ -2149,9 +2149,19 @@ (progn (store-match-data (list (point) here)) (match-string 0)))))) +(defun comint-extract-current-pathname () + "Return the file name at point. +`@' or `.' are not valid characters at the end of the filename." + (save-excursion + (re-search-forward "@?\\([^-A-Za-z0-9_,/+%.~]\\|$\\)") + (goto-char (match-beginning 0)) + (re-search-backward + "[^-A-Za-z0-9_,/+%.@~][-A-Za-z0-9_,/+%.@~]+[-A-Za-z0-9_+%~]" + nil t) + (buffer-substring (1+ (match-beginning 0)) (match-end 0)))) (defun comint-match-partial-filename () - "Return the filename at point, or nil if non is found. + "Return the filename at point, or nil if none is found. Environment variables are substituted. See `comint-word'." (let ((filename (comint-word "~/A-Za-z0-9+@:_.$#%,={}-"))) (and filename (substitute-in-file-name (comint-unquote-filename filename))))) @@ -2636,7 +2646,6 @@ (point))) (end (save-excursion (end-of-line) (point))) (res (or (comint-extract-source-location beg end) - ;; #### comint-extract-current-pathname doesn't exist (let ((file (comint-extract-current-pathname))) (and file (list file nil nil nil
--- a/lisp/custom/ChangeLog Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/custom/ChangeLog Mon Aug 13 09:36:16 2007 +0200 @@ -1,3 +1,365 @@ +Tue May 13 16:05:34 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * Version 1.97 released. + +Fri May 9 12:33:34 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * wid-edit.el (widget-field-value-get): Add workaround for XEmacs + bug with `buffer-substring-no-properties'. + + * widget.texi (atoms): Documented `function', `variable', and + `regexp' widgets. + +Thu May 8 14:35:48 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * custom.el (defcustom): Don't wrap in `eval-and-compile'. + + * wid-edit.el (widget-value-convert-widget): Don't convert :value + here. + + * cus-edit.el (custom-buffer-create-internal): New kludge for + making bib and eob read-only in XEmacs. + Kludge by Hrvoje Niksic <hniksic@srce.hr>. + + * wid-edit.el: Also allow prompt when field value is invalid. + + * cus-edit.el (custom-redraw): Fix repositioning for when column + is zero. + +Mon May 5 12:55:14 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * cus-edit.el (x): New group. + +Mon Apr 28 13:10:48 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * wid-edit.el (widget-boolean-prompt-value): Always ask. + + * cus-edit.el (custom-variable-value-create): Remove unreferenced + variable. + * wid-edit.el (widget-field-action): Ditto. + (widget-regexp-match): Ditto. + + * Version 1.96 released. + +Mon Apr 28 12:19:24 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * cus-edit.el (custom-variable-action): Don't update state if it + is modified. + + * widget.el (:mouse-down-action): New keyword. + * wid-edit.el (button-release-event-p): New function. + (widget-keymap): Don't bind mouse up events. + (widget-button-pressed-face): New face. + (widget-button-click): Wait for up event, give feedback. + (default): Use `:mouse-down-action'. + (menu-choice): Ditto. + (widget-choice-mouse-down-action): New function. + (widget-info-link-action): Removed kludge to steal up event. + * cus-edit.el (widget-magic-mouse-down-action): New function. + (custom-magic-value-create): Use it. + (custom-buffer-create-internal): Removed kludge to steal up event. + +Sun Apr 27 12:05:12 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * Version 1.95 released. + +Sun Apr 27 11:10:03 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * widget.el (:glyph-up, :glyph-down, :glyph-inactive): New + keywords. + * wid-edit.el (widget-glyph-insert-glyph): Support optional `down' + and `inactive' glyphs. + (widget-push-button-value-create): Ditto. + (widget-glyph-click): New function. + (widget-button1-click): Use it. + (widget-button-click): Use it. + +Sat Apr 26 19:26:45 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * Version 1.94 released. + +Sat Apr 26 16:39:58 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * cus-edit.el (custom-buffer-create): Accept optional buffer NAME. + (custom-buffer-create-other-window): ditto. + (customize, customize-other-window, customize-variable, + customize-variable-other-window, customize-face, + customize-face-other-window, customize-customized, + customize-saved, customize-apropos, custom-face-menu-create, + custom-variable-menu-create, boolean, custom-menu-create): Updated + caller. + + * Version 1.93 released. + + * cus-edit.el (custom-variable-action): Reset magic state. + (custom-variable-menu): Allow `Reset to Current' on `changed' + items. + + * wid-edit.el (widget-choice-toggle): New option. + (widget-choice-action): Use it. + + * cus-edit.el (custom-group-menu): Only test state to see if the + item is enabled. + + * cus-face.el (custom-background-mode): Use `const', not + `choice-item'. + (custom-face-attributes): Use tags for toggling booleans, not the + value. + + * wid-edit.el (character): Use `characterp' when available. + +Fri Apr 25 17:05:52 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * widget.el (:prompt-match): New keyword. + (:prompt-history): New keyword. + (:prompt-internal): New keyword. + * wid-edit.el (widget-field-prompt-internal): New function. + (widget-field-prompt-value): New function. + (editable-field): Use them. + (widget-field-action): Ditto. + (widget-symbol-prompt-value-history): New variable. + (widget-symbol-prompt-internal): New function. + (symbol): Use them. + (widget-variable-prompt-value-history): New variable. + (variable): Use them. + (widget-function-prompt-value-history): New variable. + (function): Use them. + + * wid-edit.el (boolean): Use tag to toggle. + (character, sexp, symbol, file, string): Inactive tag. + + * wid-edit.el (widget-choice-prompt-value): New function. + (choice, radio): Use it. + (widget-prompt-value): Prepend widget type to prompt. + + * wid-edit.el (widget-parent-action): Renamed from + `widget-choice-item-action'. + (choice-item): Updated widget. + * cus-edit.el (custom-magic): Ditto. + * widget.texi (Defining New Widgets): Documented it. + + * wid-edit.el (widget-children-validate): Renamed from + `widget-editable-list-validate'. + (editable-list, group): Updated widgets. + * cus-edit.el (custom, face): Ditto. + * widget.texi (Basic Types): Documented it. + + * wid-edit.el (widget-value-value-get): Renamed from + `widget-item-value-get'. + (item): Updated widget. + * cus-edit.el (face, custom): Ditto. + * widget.texi (Defining New Widgets): Documented it. + + * wid-edit.el (widget-value-convert-widget): Renamed from + `widget-item-convert-widget'. + (item, editable-field): Updated widgets. + * cus-edit.el (face): Ditto. + * widget.texi (Defining New Widgets): Documented it. + + * widget.texi (Defining New Widgets): Documented + `widget-types-convert-widget' and `widget-children-value-delete'. + + * custom.texi (User Commands): Documented new commands. + +Thu Apr 24 18:58:54 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * all: Synched with FSF. + +Wed Apr 23 20:16:09 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * widget.el (define-widget): Return name. + Patch by Simon Marshall <Simon.Marshall@esrin.esa.it>. + +Tue Apr 22 14:36:09 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * wid-edit.el, cus-edit.el: Replaced `copy-list' with + `copy-sequence'. + Patch by Simon Marshall <Simon.Marshall@esrin.esa.it>. + +Mon Apr 21 19:01:20 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * Version 1.90 released. + +Mon Apr 21 09:03:34 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * cus-edit.el: (custom-set-value): New command. + (custom-set-variable): New command. + (customize-saved): Renamed from `customize-customized'. + (customize-customized): New command. + (custom-save-customized): New command. + + * widget.el (:prompt-value): New keyword. + + * wid-edit.el (widget-prompt-value): New function. + (default): Use it. + (widget-default-prompt-value): New function. + (const): Use it. + (widget-const-prompt-value): New function. + (string): Use it. + (widget-string-prompt-value-history): New variable. + (widget-string-prompt-value): New function. + (file): Use it. + (widget-file-prompt-value): New function. + (sexp): Use it. + (widget-sexp-prompt-value-history): New variable. + (widget-sexp-prompt-value): New function. + (boolean): Use it. + (widget-boolean-prompt-value): New function. + +Sat Apr 19 10:08:56 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * cus-edit.el (custom-variable-prompt): Limit completion to user + options. Allow non-match input. + + * wid-edit.el (character): Give error if the length of the field + isn't exactly 1. + +Fri Apr 18 19:55:04 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * widget.el, wid-edit.el, wid-browse.el, custom.el, cus-face.el, + cus-edit.el (cl): Require cl inside an `eval-when-compile'. + +Thu Apr 17 18:55:15 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * wid-edit.el (widget-regexp-validate): New function. + (regexp): Use it. + (widget-regexp-match): New function. + (regexp): Use it. + + * cus-edit.el (custom-variable-action): Use `custom-toggle-hide'. + (custom-face-action): Ditto. + (custom-group-action): Ditto. + + * Version 1.89 released. + +Thu Apr 17 11:23:20 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * cus-edit.el (custom-toggle-hide): New function. + (custom-level-action): Use it. + (custom-group-menu): Ditto. + (custom-face-menu): Ditto. + (custom-variable-menu): Ditto. + + * cus-edit.el (custom-redraw): Goto old line and column instead of + old character position. This is more tolerant for changes. + + * wid-edit.el (widget-choice-action): Only notify parent if + something was chosen. + + * widget.texi (Sexp Types): Documented `function-item' and + `variable-item'. + (group): New subsection. + (Widget Browser): New section. + (Widget Minor Mode): New sextion. + + * wid-edit.el: Moved widget minor mode support to + `wid-browse.el'. + + * custom.el (custom-declare-group): Make sure initial members + aren't duplicated even if the `defgroup' is evaluated twice. + + * custom.el (custom-declare-variable): Use `append' instead of + `copy-list'. + + * widget.texi (checklist): Documented `:greedy'. + +Wed Apr 16 19:24:47 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * Version 1.88 released. + +Wed Apr 16 13:28:37 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * wid-edit.el (widget-minor-mode): New variable and command. + (widget-minor-mode-map): New variable. + Add to `'minor-mode-alist' and `minor-mode-map-alist'. + * widget.el: Added autoload. + + * wid-edit.el (widget-specify-inactive): Set priority. + + * wid-edit.el (widget-move): Skip inactive widgets. + + * cus-edit.el (custom-display-unselected-match): Matched too many + displays. + + * Version 1.87 released. + +Wed Apr 16 00:15:26 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * wid-edit.el (widget-field-face): Changed default background + color. + + * custom.el (custom-declare-variable): Set `custom-get' the right + place. + + * cus-edit.el (custom-magic): Don't notify the parent. + + * cus-edit.el (custom-variable-menu): Allow more actions on + `changed' and `rogue' states. + + * custom.el (custom-initialize-set): New function. + (custom-initialize-reset): New function. + (custom-initialize-changed): New function. + (custom-declare-variable): Use `custom-initialize-set' as + default for `:initialize'. + + * Version 1.86 released. + +Wed Apr 16 00:02:19 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * cus-edit.el (custom-save-variables): Save :require symbols. + + * Version 1.85 released. + +Tue Apr 15 11:56:16 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * custom.el (:initialize, :set, :get, :request): New keywords. + (custom-declare-variable): Support them. + (custom-set-variables): Ditto. + (defcustom): Document them. + (custom-initialize-default): New function. + * custom.texi (Declaring Variables): Documented them. + * cus-edit.el (custom-variable-value-create): Support them. + (custom-variable-set): Ditto. + (custom-variable-save): Ditto. + (custom-variable-reset-saved): Ditto. + (custom-variable-reset-factory): Ditto. + (custom-variable-state-set): Ditto. + + * cus-edit.el (custom-menu-filter): New function. + (custom-variable-menu): New format. + (custom-variable-action): Use it. + (custom-face-menu): New format. + (custom-face-action): Use it. + (custom-group-menu): New format. + (custom-group-action): Use it. + + * wid-edit.el (widget-choose): Accept unselectable items. + + * wid-edit.el (widget-default-create): Clear undo buffer. + (widget-default-delete): Ditto. + + * cus-edit.el (customize-other-window): New function. + + * cus-face.el (custom-frame-parameter): Replace + `frame-parameter'. + (custom-background-mode, custom-extract-frame-properties, + custom-get-frame-properties): Updated callers. + + * custom.el: Minor doc fixes from RMS. + + * cus-face.el (custom-declare-face): Protest when dumping defface + in Emacs. + + * wid-edit.el (widget-info-link-action): Steal mouse up event. + + * wid-edit.el (widget-specify-insert): Use old style backquote. + Patch by "William M. Perry" <wmperry@aventail.com>. + +Sun Apr 13 19:19:33 1997 Per Abrahamsen <abraham@dina.kvl.dk> + + * custom.texi (Declaring Faces): Documentation property symbol is + `face-documentation'. + Sat Apr 12 18:31:22 1997 Per Abrahamsen <abraham@dina.kvl.dk> * Version 1.84 released.
--- a/lisp/custom/cus-edit.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/custom/cus-edit.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,11 +4,30 @@ ;; ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> ;; Keywords: help, faces -;; Version: 1.84 +;; Version: 1.97 ;; X-URL: http://www.dina.kvl.dk/~abraham/custom/ +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; Boston, MA 02111-1307, USA. + ;;; Commentary: ;; +;; This file implements the code to create and edit customize buffers. +;; ;; See `custom.el'. ;;; Code: @@ -16,6 +35,11 @@ (require 'cus-face) (require 'wid-edit) (require 'easymenu) +(eval-when-compile (require 'cl)) + +(condition-case nil + (require 'cus-load) + (error nil)) (define-widget-keywords :custom-prefixes :custom-menu :custom-show :custom-magic :custom-state :custom-level :custom-form @@ -168,6 +192,10 @@ :group 'environment :group 'editing) +(defgroup x nil + "The X Window system." + :group 'environment) + (defgroup frames nil "Support for Emacs frames and window systems." :group 'environment) @@ -330,12 +358,32 @@ val) (setq val (completing-read (if v - (format "Customize variable (default %s): " v) + (format "Customize variable: (default %s) " v) "Customize variable: ") - obarray 'boundp t)) + obarray (lambda (symbol) + (and (boundp symbol) + (or (get symbol 'custom-type) + (user-variable-p symbol)))))) (list (if (equal val "") v (intern val))))) +(defun custom-menu-filter (menu widget) + "Convert MENU to the form used by `widget-choose'. +MENU should be in the same format as `custom-variable-menu'. +WIDGET is the widget to apply the filter entries of MENU on." + (let ((result nil) + current name action filter) + (while menu + (setq current (car menu) + name (nth 0 current) + action (nth 1 current) + filter (nth 2 current) + menu (cdr menu)) + (if (or (null filter) (funcall filter widget)) + (push (cons name action) result) + (push name result))) + (nreverse result))) + ;;; Unlispify. (defvar custom-prefix-list nil @@ -529,6 +577,74 @@ ;;; The Customize Commands +(defun custom-prompt-variable (prompt-var prompt-val) + "Prompt for a variable and a value and return them as a list. +PROMPT-VAR is the prompt for the variable, and PROMPT-VAL is the +prompt for the value. The %s escape in PROMPT-VAL is replaced with +the name of the variable. + +If the variable has a `variable-interactive' property, that is used as if +it were the arg to `interactive' (which see) to interactively read the value. + +If the variable has a `custom-type' property, it must be a widget and the +`:prompt-value' property of that widget will be used for reading the value." + (let* ((var (read-variable prompt-var)) + (minibuffer-help-form '(describe-variable var))) + (list var + (let ((prop (get var 'variable-interactive)) + (type (get var 'custom-type)) + (prompt (format prompt-val var))) + (unless (listp type) + (setq type (list type))) + (cond (prop + ;; Use VAR's `variable-interactive' property + ;; as an interactive spec for prompting. + (call-interactively (list 'lambda '(arg) + (list 'interactive prop) + 'arg))) + (type + (widget-prompt-value type + prompt + (if (boundp var) + (symbol-value var)) + (not (boundp var)))) + (t + (eval-minibuffer prompt))))))) + +;;;###autoload +(defun custom-set-value (var val) + "Set VARIABLE to VALUE. VALUE is a Lisp object. + +If VARIABLE has a `variable-interactive' property, that is used as if +it were the arg to `interactive' (which see) to interactively read the value. + +If VARIABLE has a `custom-type' property, it must be a widget and the +`:prompt-value' property of that widget will be used for reading the value." + (interactive (custom-prompt-variable "Set variable: " + "Set %s to value: ")) + + (set var val)) + +;;;###autoload +(defun custom-set-variable (var val) + "Set the default for VARIABLE to VALUE. VALUE is a Lisp object. + +If VARIABLE has a `custom-set' property, that is used for setting +VARIABLE, otherwise `set-default' is used. + +The `customized-value' property of the VARIABLE will be set to a list +with a quoted VALUE as its sole list member. + +If VARIABLE has a `variable-interactive' property, that is used as if +it were the arg to `interactive' (which see) to interactively read the value. + +If VARIABLE has a `custom-type' property, it must be a widget and the +`:prompt-value' property of that widget will be used for reading the value. " + (interactive (custom-prompt-variable "Set variable: " + "Set customized value for %s to: ")) + (funcall (or (get var 'custom-set) 'set-default) var val) + (put var 'customized-value (list (custom-quote val)))) + ;;;###autoload (defun customize (symbol) "Customize SYMBOL, which must be a customization group." @@ -542,20 +658,43 @@ (if (string-equal "" symbol) (setq symbol 'emacs) (setq symbol (intern symbol)))) - (custom-buffer-create (list (list symbol 'custom-group)))) + (custom-buffer-create (list (list symbol 'custom-group)) + (format "*Customize Group: %s*" + (custom-unlispify-tag-name symbol)))) + +;;;###autoload +(defun customize-other-window (symbol) + "Customize SYMBOL, which must be a customization group." + (interactive (list (completing-read "Customize group: (default emacs) " + obarray + (lambda (symbol) + (get symbol 'custom-group)) + t))) + + (when (stringp symbol) + (if (string-equal "" symbol) + (setq symbol 'emacs) + (setq symbol (intern symbol)))) + (custom-buffer-create-other-window + (list (list symbol 'custom-group)) + (format "*Customize Group: %s*" (custom-unlispify-tag-name symbol)))) ;;;###autoload (defun customize-variable (symbol) "Customize SYMBOL, which must be a variable." (interactive (custom-variable-prompt)) - (custom-buffer-create (list (list symbol 'custom-variable)))) + (custom-buffer-create (list (list symbol 'custom-variable)) + (format "*Customize Variable: %s*" + (custom-unlispify-tag-name symbol)))) ;;;###autoload (defun customize-variable-other-window (symbol) "Customize SYMBOL, which must be a variable. Show the buffer in another window, but don't select it." (interactive (custom-variable-prompt)) - (custom-buffer-create-other-window (list (list symbol 'custom-variable)))) + (custom-buffer-create-other-window + (list (list symbol 'custom-variable)) + (format "*Customize Variable: %s*" (custom-unlispify-tag-name symbol)))) ;;;###autoload (defun customize-face (&optional symbol) @@ -572,12 +711,14 @@ (sort (mapcar 'symbol-name (face-list)) 'string<)))) - (custom-buffer-create found)) + (custom-buffer-create found "*Customize Faces*")) (if (stringp symbol) (setq symbol (intern symbol))) (unless (symbolp symbol) (error "Should be a symbol %S" symbol)) - (custom-buffer-create (list (list symbol 'custom-face))))) + (custom-buffer-create (list (list symbol 'custom-face)) + (format "*Customize Face: %s*" + (custom-unlispify-tag-name symbol))))) ;;;###autoload (defun customize-face-other-window (&optional symbol) @@ -590,11 +731,30 @@ (setq symbol (intern symbol))) (unless (symbolp symbol) (error "Should be a symbol %S" symbol)) - (custom-buffer-create-other-window (list (list symbol 'custom-face))))) + (custom-buffer-create-other-window + (list (list symbol 'custom-face)) + (format "*Customize Face: %s*" (custom-unlispify-tag-name symbol))))) ;;;###autoload (defun customize-customized () - "Customize all already customized user options." + "Customize all user options set since the last save in this session." + (interactive) + (let ((found nil)) + (mapatoms (lambda (symbol) + (and (get symbol 'customized-face) + (custom-facep symbol) + (setq found (cons (list symbol 'custom-face) found))) + (and (get symbol 'customized-value) + (boundp symbol) + (setq found + (cons (list symbol 'custom-variable) found))))) + (if found + (custom-buffer-create found "*Customize Customized*") + (error "No customized user options")))) + +;;;###autoload +(defun customize-saved () + "Customize all already saved user options." (interactive) (let ((found nil)) (mapatoms (lambda (symbol) @@ -606,8 +766,8 @@ (setq found (cons (list symbol 'custom-variable) found))))) (if found - (custom-buffer-create found) - (error "No customized user options")))) + (custom-buffer-create found "*Customize Saved*") + (error "No saved user options")))) ;;;###autoload (defun customize-apropos (regexp &optional all) @@ -631,27 +791,34 @@ (setq found (cons (list symbol 'custom-variable) found)))))) (if found - (custom-buffer-create found) + (custom-buffer-create found "*Customize Apropos*") (error "No matches")))) +;;; Buffer. + ;;;###autoload -(defun custom-buffer-create (options) +(defun custom-buffer-create (options &optional name) "Create a buffer containing OPTIONS. +Optional NAME is the name of the buffer. OPTIONS should be an alist of the form ((SYMBOL WIDGET)...), where SYMBOL is a customization option, and WIDGET is a widget for editing that option." - (kill-buffer (get-buffer-create "*Customization*")) - (switch-to-buffer (get-buffer-create "*Customization*")) + (unless name (setq name "*Customization*")) + (kill-buffer (get-buffer-create name)) + (switch-to-buffer (get-buffer-create name)) (custom-buffer-create-internal options)) -(defun custom-buffer-create-other-window (options) +;;;###autoload +(defun custom-buffer-create-other-window (options &optional name) "Create a buffer containing OPTIONS. +Optional NAME is the name of the buffer. OPTIONS should be an alist of the form ((SYMBOL WIDGET)...), where SYMBOL is a customization option, and WIDGET is a widget for editing that option." - (kill-buffer (get-buffer-create "*Customization*")) + (unless name (setq name "*Customization*")) + (kill-buffer (get-buffer-create name)) (let ((window (selected-window))) - (switch-to-buffer-other-window (get-buffer-create "*Customization*")) + (switch-to-buffer-other-window (get-buffer-create name)) (custom-buffer-create-internal options) (select-window window))) @@ -720,22 +887,19 @@ :tag "Done" :help-echo "Bury the buffer." :action (lambda (widget &optional event) - (bury-buffer) - ;; Steal button release event. - (if (and (fboundp 'button-press-event-p) - (fboundp 'next-command-event)) - ;; XEmacs - (and event - (button-press-event-p event) - (next-command-event)) - ;; Emacs - (when (memq 'down (event-modifiers event)) - (read-event))))) + (bury-buffer))) (widget-insert "\n") (message "Creating customization setup...") (widget-setup) (goto-char (point-min)) - (forward-char) ;Kludge: bob is writable in XEmacs. + (when (fboundp 'map-extents) + ;; This horrible kludge should make bob and eob read-only in XEmacs. + (map-extents (lambda (extent &rest junk) + (set-extent-property extent 'start-closed t)) + nil (point-min) (1+ (point-min))) + (map-extents (lambda (extent &rest junk) + (set-extent-property extent 'end-closed t)) + nil (1- (point-max)) (point-max))) (message "Creating customization buffer...done")) ;;; Modification of Basic Widgets. @@ -916,11 +1080,18 @@ (define-widget 'custom-magic 'default "Show and manipulate state for a customization option." :format "%v" - :action 'widget-choice-item-action + :action 'widget-parent-action + :notify 'ignore :value-get 'ignore :value-create 'custom-magic-value-create :value-delete 'widget-children-value-delete) +(defun widget-magic-mouse-down-action (widget &optional event) + ;; Non-nil unless hidden. + (not (eq (widget-get (widget-get (widget-get widget :parent) :parent) + :custom-state) + 'hidden))) + (defun custom-magic-value-create (widget) ;; Create compact status report for WIDGET. (let* ((parent (widget-get widget :parent)) @@ -932,11 +1103,13 @@ (lisp (eq (widget-get parent :custom-form) 'lisp)) children) (when custom-magic-show - (push (widget-create-child-and-convert widget 'choice-item - :help-echo "\ + (push (widget-create-child-and-convert + widget 'choice-item + :help-echo "\ Change the state of this item." - :format "%[%t%]" - :tag "State") + :format "%[%t%]" + :mouse-down-action 'widget-magic-mouse-down-action + :tag "State") children) (insert ": ") (if (eq custom-magic-show 'long) @@ -950,13 +1123,15 @@ (let ((indent (widget-get parent :indent))) (when indent (insert-char ? indent)))) - (push (widget-create-child-and-convert widget 'choice-item - :button-face face - :help-echo "Change the state." - :format "%[%t%]" - :tag (if lisp - (concat "(" magic ")") - (concat "[" magic "]"))) + (push (widget-create-child-and-convert + widget 'choice-item + :mouse-down-action 'widget-magic-mouse-down-action + :button-face face + :help-echo "Change the state." + :format "%[%t%]" + :tag (if lisp + (concat "(" magic ")") + (concat "[" magic "]"))) children) (insert " ")) (widget-put widget :children children))) @@ -976,15 +1151,7 @@ (defun custom-level-action (widget &optional event) "Toggle visibility for parent to WIDGET." - (let* ((parent (widget-get widget :parent)) - (state (widget-get parent :custom-state))) - (cond ((memq state '(invalid modified)) - (error "There are unset changes")) - ((eq state 'hidden) - (widget-put parent :custom-state 'unknown)) - (t - (widget-put parent :custom-state 'hidden))) - (custom-redraw parent))) + (custom-toggle-hide (widget-get widget :parent))) ;;; The `custom' Widget. @@ -999,8 +1166,8 @@ :documentation-property 'widget-subclass-responsibility :value-create 'widget-subclass-responsibility :value-delete 'widget-children-value-delete - :value-get 'widget-item-value-get - :validate 'widget-editable-list-validate + :value-get 'widget-value-value-get + :validate 'widget-children-validate :match (lambda (widget value) (symbolp value))) (defun custom-convert-widget (widget) @@ -1072,14 +1239,22 @@ (defun custom-redraw (widget) "Redraw WIDGET with current settings." - (let ((pos (point)) + (let ((line (count-lines (point-min) (point))) + (column (current-column)) + (pos (point)) (from (marker-position (widget-get widget :from))) (to (marker-position (widget-get widget :to)))) (save-excursion (widget-value-set widget (widget-value widget)) (custom-redraw-magic widget)) (when (and (>= pos from) (<= pos to)) - (goto-char pos)))) + (condition-case nil + (progn + (if (> column 0) + (goto-line line) + (goto-line (1+ line))) + (move-to-column column)) + (error nil))))) (defun custom-redraw-magic (widget) "Redraw WIDGET state with current settings." @@ -1128,6 +1303,17 @@ "Load all dependencies for WIDGET." (custom-load-symbol (widget-value widget))) +(defun custom-toggle-hide (widget) + "Toggle visibility of WIDGET." + (let ((state (widget-get widget :custom-state))) + (cond ((memq state '(invalid modified)) + (error "There are unset changes")) + ((eq state 'hidden) + (widget-put widget :custom-state 'unknown)) + (t + (widget-put widget :custom-state 'hidden))) + (custom-redraw widget))) + ;;; The `custom-variable' Widget. (defface custom-variable-sample-face '((t (:underline t))) @@ -1164,7 +1350,7 @@ 'sexp)) (options (get symbol 'custom-options)) (tmp (if (listp type) - (copy-list type) + (copy-sequence type) (list type)))) (when options (widget-put tmp :options options)) @@ -1181,8 +1367,9 @@ (tag (widget-get widget :tag)) (type (custom-variable-type symbol)) (conv (widget-convert type)) + (get (or (get symbol 'custom-get) 'default-value)) (value (if (default-boundp symbol) - (default-value symbol) + (funcall get symbol) (widget-get conv :value)))) ;; If the widget is new, the child determine whether it is hidden. (cond (state) @@ -1212,7 +1399,7 @@ ((get symbol 'factory-value) (car (get symbol 'factory-value))) ((default-boundp symbol) - (custom-quote (default-value symbol))) + (custom-quote (funcall get symbol))) (t (custom-quote (widget-get conv :value)))))) (push (widget-create-child-and-convert @@ -1244,8 +1431,9 @@ (defun custom-variable-state-set (widget) "Set the state of WIDGET." (let* ((symbol (widget-value widget)) + (get (or (get symbol 'custom-get) 'default-value)) (value (if (default-boundp symbol) - (default-value symbol) + (funcall get symbol) (widget-get widget :value))) tmp (state (cond ((setq tmp (get symbol 'customized-value)) @@ -1270,29 +1458,55 @@ (widget-put widget :custom-state state))) (defvar custom-variable-menu - '(("Edit" . custom-variable-edit) - ("Edit Lisp" . custom-variable-edit-lisp) - ("Set" . custom-variable-set) - ("Save" . custom-variable-save) - ("Reset to Current" . custom-redraw) - ("Reset to Saved" . custom-variable-reset-saved) - ("Reset to Factory Settings" . custom-variable-reset-factory)) + '(("Hide" custom-toggle-hide + (lambda (widget) + (not (memq (widget-get widget :custom-state) '(modified invalid))))) + ("Edit" custom-variable-edit + (lambda (widget) + (not (eq (widget-get widget :custom-form) 'edit)))) + ("Edit Lisp" custom-variable-edit-lisp + (lambda (widget) + (not (eq (widget-get widget :custom-form) 'lisp)))) + ("Set" custom-variable-set + (lambda (widget) + (eq (widget-get widget :custom-state) 'modified))) + ("Save" custom-variable-save + (lambda (widget) + (memq (widget-get widget :custom-state) '(modified set changed rogue)))) + ("Reset to Current" custom-redraw + (lambda (widget) + (and (default-boundp (widget-value widget)) + (memq (widget-get widget :custom-state) '(modified changed))))) + ("Reset to Saved" custom-variable-reset-saved + (lambda (widget) + (and (get (widget-value widget) 'saved-value) + (memq (widget-get widget :custom-state) + '(modified set changed rogue))))) + ("Reset to Factory Settings" custom-variable-reset-factory + (lambda (widget) + (and (get (widget-value widget) 'factory-value) + (memq (widget-get widget :custom-state) + '(modified set changed saved rogue)))))) "Alist of actions for the `custom-variable' widget. -The key is a string containing the name of the action, the value is a -lisp function taking the widget as an element which will be called -when the action is chosen.") +Each entry has the form (NAME ACTION FILTER) where NAME is the name of +the menu entry, ACTION is the function to call on the widget when the +menu is selected, and FILTER is a predicate which takes a `custom-variable' +widget as an argument, and returns non-nil if ACTION is valid on that +widget. If FILTER is nil, ACTION is always valid.") (defun custom-variable-action (widget &optional event) "Show the menu for `custom-variable' WIDGET. Optional EVENT is the location for the menu." (if (eq (widget-get widget :custom-state) 'hidden) - (progn - (widget-put widget :custom-state 'unknown) - (custom-redraw widget)) + (custom-toggle-hide widget) + (unless (eq (widget-get widget :custom-state) 'modified) + (custom-variable-state-set widget)) + (custom-redraw-magic widget) (let* ((completion-ignore-case t) (answer (widget-choose (custom-unlispify-tag-name (widget-get widget :value)) - custom-variable-menu + (custom-menu-filter custom-variable-menu + widget) event))) (if answer (funcall answer widget))))) @@ -1311,32 +1525,34 @@ (defun custom-variable-set (widget) "Set the current value for the variable being edited by WIDGET." - (let ((form (widget-get widget :custom-form)) - (state (widget-get widget :custom-state)) - (child (car (widget-get widget :children))) - (symbol (widget-value widget)) - val) + (let* ((form (widget-get widget :custom-form)) + (state (widget-get widget :custom-state)) + (child (car (widget-get widget :children))) + (symbol (widget-value widget)) + (set (or (get symbol 'custom-set) 'set-default)) + val) (cond ((eq state 'hidden) (error "Cannot set hidden variable.")) ((setq val (widget-apply child :validate)) (goto-char (widget-get val :from)) (error "%s" (widget-get val :error))) ((eq form 'lisp) - (set-default symbol (eval (setq val (widget-value child)))) + (funcall set symbol (eval (setq val (widget-value child)))) (put symbol 'customized-value (list val))) (t - (set-default symbol (setq val (widget-value child))) + (funcall set symbol (setq val (widget-value child))) (put symbol 'customized-value (list (custom-quote val))))) (custom-variable-state-set widget) (custom-redraw-magic widget))) (defun custom-variable-save (widget) "Set the default value for the variable being edited by WIDGET." - (let ((form (widget-get widget :custom-form)) - (state (widget-get widget :custom-state)) - (child (car (widget-get widget :children))) - (symbol (widget-value widget)) - val) + (let* ((form (widget-get widget :custom-form)) + (state (widget-get widget :custom-state)) + (child (car (widget-get widget :children))) + (symbol (widget-value widget)) + (set (or (get symbol 'custom-set) 'set-default)) + val) (cond ((eq state 'hidden) (error "Cannot set hidden variable.")) ((setq val (widget-apply child :validate)) @@ -1344,12 +1560,12 @@ (error "%s" (widget-get val :error))) ((eq form 'lisp) (put symbol 'saved-value (list (widget-value child))) - (set-default symbol (eval (widget-value child)))) + (funcall set symbol (eval (widget-value child)))) (t (put symbol 'saved-value (list (custom-quote (widget-value child)))) - (set-default symbol (widget-value child)))) + (funcall set symbol (widget-value child)))) (put symbol 'customized-value nil) (custom-save-all) (custom-variable-state-set widget) @@ -1357,10 +1573,11 @@ (defun custom-variable-reset-saved (widget) "Restore the saved value for the variable being edited by WIDGET." - (let ((symbol (widget-value widget))) + (let* ((symbol (widget-value widget)) + (set (or (get symbol 'custom-set) 'set-default))) (if (get symbol 'saved-value) (condition-case nil - (set-default symbol (eval (car (get symbol 'saved-value)))) + (funcall set symbol (eval (car (get symbol 'saved-value)))) (error nil)) (error "No saved value for %s" symbol)) (put symbol 'customized-value nil) @@ -1369,9 +1586,10 @@ (defun custom-variable-reset-factory (widget) "Restore the factory setting for the variable being edited by WIDGET." - (let ((symbol (widget-value widget))) + (let* ((symbol (widget-value widget)) + (set (or (get symbol 'custom-set) 'set-default))) (if (get symbol 'factory-value) - (set-default symbol (eval (car (get symbol 'factory-value)))) + (funcall set symbol (eval (car (get symbol 'factory-value)))) (error "No factory default for %S" symbol)) (put symbol 'customized-value nil) (when (get symbol 'saved-value) @@ -1528,9 +1746,7 @@ (defun custom-display-unselected-match (widget value) "Non-nil if VALUE is an unselected display specification." - (and (listp value) - (eq (length value) 2) - (not (custom-display-match-frame value (selected-frame))))) + (not (face-spec-set-match-display value (selected-frame)))) (define-widget 'custom-face-selected 'group "Edit the attributes of the selected display in a face specification." @@ -1554,7 +1770,7 @@ (custom-load-widget widget) (let* ((symbol (widget-value widget)) (spec (or (get symbol 'saved-face) - (get symbol 'factory-face) + (get symbol 'face-defface-spec) ;; Attempt to construct it. (list (list t (custom-face-attributes-get symbol (selected-frame)))))) @@ -1578,17 +1794,32 @@ (message "Creating face editor...done"))) (defvar custom-face-menu - '(("Edit Selected" . custom-face-edit-selected) - ("Edit All" . custom-face-edit-all) - ("Edit Lisp" . custom-face-edit-lisp) - ("Set" . custom-face-set) - ("Save" . custom-face-save) - ("Reset to Saved" . custom-face-reset-saved) - ("Reset to Factory Setting" . custom-face-reset-factory)) + '(("Hide" custom-toggle-hide + (lambda (widget) + (not (memq (widget-get widget :custom-state) '(modified invalid))))) + ("Edit Selected" custom-face-edit-selected + (lambda (widget) + (not (eq (widget-get widget :custom-form) 'selected)))) + ("Edit All" custom-face-edit-all + (lambda (widget) + (not (eq (widget-get widget :custom-form) 'all)))) + ("Edit Lisp" custom-face-edit-lisp + (lambda (widget) + (not (eq (widget-get widget :custom-form) 'lisp)))) + ("Set" custom-face-set) + ("Save" custom-face-save) + ("Reset to Saved" custom-face-reset-saved + (lambda (widget) + (get (widget-value widget) 'saved-face))) + ("Reset to Factory Setting" custom-face-reset-factory + (lambda (widget) + (get (widget-value widget) 'face-defface-spec)))) "Alist of actions for the `custom-face' widget. -The key is a string containing the name of the action, the value is a -lisp function taking the widget as an element which will be called -when the action is chosen.") +Each entry has the form (NAME ACTION FILTER) where NAME is the name of +the menu entry, ACTION is the function to call on the widget when the +menu is selected, and FILTER is a predicate which takes a `custom-face' +widget as an argument, and returns non-nil if ACTION is valid on that +widget. If FILTER is nil, ACTION is always valid.") (defun custom-face-edit-selected (widget) "Edit selected attributes of the value of WIDGET." @@ -1615,7 +1846,7 @@ 'set) ((get symbol 'saved-face) 'saved) - ((get symbol 'factory-face) + ((get symbol 'face-defface-spec) 'factory) (t 'rogue))))) @@ -1624,13 +1855,13 @@ "Show the menu for `custom-face' WIDGET. Optional EVENT is the location for the menu." (if (eq (widget-get widget :custom-state) 'hidden) - (progn - (widget-put widget :custom-state 'unknown) - (custom-redraw widget)) + (custom-toggle-hide widget) (let* ((completion-ignore-case t) (symbol (widget-get widget :value)) (answer (widget-choose (custom-unlispify-tag-name symbol) - custom-face-menu event))) + (custom-menu-filter custom-face-menu + widget) + event))) (if answer (funcall answer widget))))) @@ -1640,8 +1871,6 @@ (child (car (widget-get widget :children))) (value (widget-value child))) (put symbol 'customized-face value) - (when (fboundp 'copy-face) - (copy-face 'custom-face-empty symbol)) (custom-face-display-set symbol value) (custom-face-state-set widget) (custom-redraw-magic widget))) @@ -1651,8 +1880,6 @@ (let* ((symbol (widget-value widget)) (child (car (widget-get widget :children))) (value (widget-value child))) - (when (fboundp 'copy-face) - (copy-face 'custom-face-empty symbol)) (custom-face-display-set symbol value) (put symbol 'saved-face value) (put symbol 'customized-face nil) @@ -1667,8 +1894,6 @@ (unless value (error "No saved value for this face")) (put symbol 'customized-face nil) - (when (fboundp 'copy-face) - (copy-face 'custom-face-empty symbol)) (custom-face-display-set symbol value) (widget-value-set child value) (custom-face-state-set widget) @@ -1678,15 +1903,13 @@ "Restore WIDGET to the face's factory settings." (let* ((symbol (widget-value widget)) (child (car (widget-get widget :children))) - (value (get symbol 'factory-face))) + (value (get symbol 'face-defface-spec))) (unless value (error "No factory default for this face")) (put symbol 'customized-face nil) (when (get symbol 'saved-face) (put symbol 'saved-face nil) (custom-save-all)) - (when (fboundp 'copy-face) - (copy-face 'custom-face-empty symbol)) (custom-face-display-set symbol value) (widget-value-set child value) (custom-face-state-set widget) @@ -1696,14 +1919,14 @@ (define-widget 'face 'default "Select and customize a face." - :convert-widget 'widget-item-convert-widget + :convert-widget 'widget-value-convert-widget :format "%[%t%]: %v" :tag "Face" :value 'default :value-create 'widget-face-value-create :value-delete 'widget-face-value-delete - :value-get 'widget-item-value-get - :validate 'widget-editable-list-validate + :value-get 'widget-value-value-get + :validate 'widget-children-validate :action 'widget-face-action :match '(lambda (widget value) (symbolp value))) @@ -1851,27 +2074,41 @@ (message "Creating group... done"))))) (defvar custom-group-menu - '(("Set" . custom-group-set) - ("Save" . custom-group-save) - ("Reset to Current" . custom-group-reset-current) - ("Reset to Saved" . custom-group-reset-saved) - ("Reset to Factory" . custom-group-reset-factory)) + '(("Hide" custom-toggle-hide + (lambda (widget) + (not (memq (widget-get widget :custom-state) '(modified invalid))))) + ("Set" custom-group-set + (lambda (widget) + (eq (widget-get widget :custom-state) 'modified))) + ("Save" custom-group-save + (lambda (widget) + (memq (widget-get widget :custom-state) '(modified set)))) + ("Reset to Current" custom-group-reset-current + (lambda (widget) + (memq (widget-get widget :custom-state) '(modified)))) + ("Reset to Saved" custom-group-reset-saved + (lambda (widget) + (memq (widget-get widget :custom-state) '(modified set)))) + ("Reset to Factory" custom-group-reset-factory + (lambda (widget) + (memq (widget-get widget :custom-state) '(modified set saved))))) "Alist of actions for the `custom-group' widget. -The key is a string containing the name of the action, the value is a -lisp function taking the widget as an element which will be called -when the action is chosen.") +Each entry has the form (NAME ACTION FILTER) where NAME is the name of +the menu entry, ACTION is the function to call on the widget when the +menu is selected, and FILTER is a predicate which takes a `custom-group' +widget as an argument, and returns non-nil if ACTION is valid on that +widget. If FILTER is nil, ACTION is always valid.") (defun custom-group-action (widget &optional event) "Show the menu for `custom-group' WIDGET. Optional EVENT is the location for the menu." (if (eq (widget-get widget :custom-state) 'hidden) - (progn - (widget-put widget :custom-state 'unknown) - (custom-redraw widget)) + (custom-toggle-hide widget) (let* ((completion-ignore-case t) (answer (widget-choose (custom-unlispify-tag-name (widget-get widget :value)) - custom-group-menu + (custom-menu-filter custom-group-menu + widget) event))) (if answer (funcall answer widget))))) @@ -1972,17 +2209,26 @@ (princ "\n")) (princ "(custom-set-variables") (mapatoms (lambda (symbol) - (let ((value (get symbol 'saved-value))) + (let ((value (get symbol 'saved-value)) + (requests (get symbol 'custom-requests)) + (now (not (or (get symbol 'factory-value) + (and (not (boundp symbol)) + (not (get symbol 'force-value))))))) (when value (princ "\n '(") (princ symbol) (princ " ") (prin1 (car value)) - (if (or (get symbol 'factory-value) - (and (not (boundp symbol)) - (not (get symbol 'force-value)))) - (princ ")") - (princ " t)")))))) + (cond (requests + (if now + (princ " t ") + (princ " nil ")) + (prin1 requests) + (princ ")")) + (now + (princ " t)")) + (t + (princ ")"))))))) (princ ")") (unless (looking-at "\n") (princ "\n"))))) @@ -2000,7 +2246,7 @@ (when value (princ "\n '(default ") (prin1 value) - (if (or (get 'default 'factory-face) + (if (or (get 'default 'face-defface-spec) (and (not (custom-facep 'default)) (not (get 'default 'force-face)))) (princ ")") @@ -2014,7 +2260,7 @@ (princ symbol) (princ " ") (prin1 value) - (if (or (get symbol 'factory-face) + (if (or (get symbol 'face-defface-spec) (and (not (custom-facep symbol)) (not (get symbol 'force-face)))) (princ ")") @@ -2024,6 +2270,22 @@ (princ "\n"))))) ;;;###autoload +(defun custom-save-customized () + "Save all user options which have been set in this session." + (interactive) + (mapatoms (lambda (symbol) + (let ((face (get symbol 'customized-face)) + (value (get symbol 'customized-value))) + (when face + (put symbol 'saved-face face) + (put symbol 'customized-face nil)) + (when value + (put symbol 'saved-value value) + (put symbol 'customized-value nil))))) + ;; We really should update all custom buffers here. + (custom-save-all)) + +;;;###autoload (defun custom-save-all () "Save all customizations in `custom-file'." (custom-save-variables) @@ -2075,7 +2337,7 @@ (defun custom-face-menu-create (widget symbol) "Ignoring WIDGET, create a menu entry for customization face SYMBOL." (vector (custom-unlispify-menu-entry symbol) - `(custom-buffer-create '((,symbol custom-face))) + `(customize-face ',symbol) t)) (defun custom-variable-menu-create (widget symbol) @@ -2086,15 +2348,14 @@ (if (and type (widget-get type :custom-menu)) (widget-apply type :custom-menu symbol) (vector (custom-unlispify-menu-entry symbol) - `(custom-buffer-create '((,symbol custom-variable))) + `(customize-variable ',symbol) t)))) ;; Add checkboxes to boolean variable entries. (widget-put (get 'boolean 'widget-type) :custom-menu (lambda (widget symbol) (vector (custom-unlispify-menu-entry symbol) - `(custom-buffer-create - '((,symbol custom-variable))) + `(customize-variable ',symbol) ':style 'toggle ':selected symbol))) @@ -2117,7 +2378,7 @@ "Create menu for customization group SYMBOL. The menu is in a format applicable to `easy-menu-define'." (let* ((item (vector (custom-unlispify-menu-entry symbol) - `(custom-buffer-create '((,symbol custom-group))) + `(customize ',symbol) t))) (if (and (or (not (boundp 'custom-menu-nesting)) (>= custom-menu-nesting 0)) @@ -2164,7 +2425,7 @@ (easy-menu-define custom-mode-customize-menu custom-mode-map - "Menu used in customization buffers." + "Menu used to customize customization buffers." (customize-menu-create 'customize)) (easy-menu-define custom-mode-menu
--- a/lisp/custom/cus-face.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/custom/cus-face.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,7 +4,7 @@ ;; ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> ;; Keywords: help, faces -;; Version: 1.84 +;; Version: 1.97 ;; X-URL: http://www.dina.kvl.dk/~abraham/custom/ ;;; Commentary: @@ -15,7 +15,7 @@ (require 'custom) -(eval-and-compile (require 'cl)) +(eval-when-compile (require 'cl)) ;;; Compatibility. @@ -38,12 +38,18 @@ 'face-font)) (eval-and-compile - (unless (fboundp 'frame-property) - ;; XEmacs function missing in Emacs. - (defun frame-property (frame property &optional default) - "Return FRAME's value for property PROPERTY." - (or (cdr (assq property (frame-parameters frame))) - default))) + (cond ((fboundp 'frame-property) + ;; XEmacs. + (defalias 'custom-frame-parameter 'frame-property)) + ((fboundp 'frame-parameter) + ;; Emacs 19.35. + (defalias 'custom-frame-parameter 'frame-parameter)) + (t + ;; Old emacsen. + (defun custom-frame-parameter (frame property &optional default) + "Return FRAME's value for property PROPERTY." + (or (cdr (assq property (frame-parameters frame))) + default)))) (unless (fboundp 'face-doc-string) ;; XEmacs function missing in Emacs. @@ -146,12 +152,12 @@ ;; (interactive (list (read-face-name "Reverse face: "))) ;; (let ((fg (or (face-foreground face frame) ;; (face-foreground 'default frame) -;; (frame-property (or frame (selected-frame)) +;; (custom-frame-parameter (or frame (selected-frame)) ;; 'foreground-color) ;; "black")) ;; (bg (or (face-background face frame) ;; (face-background 'default frame) -;; (frame-property (or frame (selected-frame)) +;; (custom-frame-parameter (or frame (selected-frame)) ;; 'background-color) ;; "white"))) ;; (set-face-foreground face bg frame) @@ -163,9 +169,9 @@ your background is light, or nil (default) if you want Emacs to examine the brightness for you." :group 'customize - :type '(choice (choice-item dark) - (choice-item light) - (choice-item :tag "default" nil))) + :type '(choice (const dark) + (const light) + (const :tag "default" nil))) (defun custom-background-mode (frame) "Kludge to detect background mode for FRAME." @@ -177,7 +183,7 @@ (mode (cond (bg-resource (intern (downcase bg-resource))) ((and (setq color (condition-case () - (or (frame-property + (or (custom-frame-parameter frame 'background-color) (custom-face-background @@ -201,16 +207,16 @@ (list 'type (device-type (frame-device frame)) 'class (device-class (frame-device frame)) 'background (or custom-background-mode - (frame-property frame + (custom-frame-parameter frame 'background-mode) (custom-background-mode frame)))) ;; Emacs. (defun custom-extract-frame-properties (frame) "Return a plist with the frame properties of FRAME used by custom." (list 'type window-system - 'class (frame-property frame 'display-type) + 'class (custom-frame-parameter frame 'display-type) 'background (or custom-background-mode - (frame-property frame 'background-mode) + (custom-frame-parameter frame 'background-mode) (custom-background-mode frame)))))) ;;; Declaring a face. @@ -218,11 +224,13 @@ ;;;###autoload (defun custom-declare-face (face spec doc &rest args) "Like `defface', but FACE is evaluated as a normal argument." - (when (fboundp 'load-gc) + (when (or (fboundp 'load-gc) ;XEmacs. + ;; Emacs. + (and (boundp purify-flag) purify-flag)) ;; This should be allowed, somehow. (error "Attempt to declare a face during dump")) - (unless (get face 'factory-face) - (put face 'factory-face spec) + (unless (get face 'face-defface-spec) + (put face 'face-defface-spec spec) (when (fboundp 'facep) (unless (custom-facep face) ;; If the user has already created the face, respect that. @@ -247,16 +255,16 @@ ;;; Font Attributes. (defconst custom-face-attributes - '((:bold (toggle :format "Bold: %[%v%]\n" + '((:bold (toggle :format "%[Bold%]: %v\n" :help-echo "Control whether a bold font should be used.") custom-set-face-bold custom-face-bold) - (:italic (toggle :format "Italic: %[%v%]\n" + (:italic (toggle :format "%[Italic%]: %v\n" :help-echo "\ Control whether an italic font should be used.") custom-set-face-italic custom-face-italic) - (:underline (toggle :format "Underline: %[%v%]\n" + (:underline (toggle :format "%[Underline%]: %v\n" :help-echo "\ Control whether the text should be underlined.") set-face-underline-p @@ -405,7 +413,7 @@ Text size (e.g. 9pt or 2mm).") custom-set-face-font-size custom-face-font-size) - (:strikethru (toggle :format "Strikethru: %[%v%]\n" + (:strikethru (toggle :format "%[Strikethru%]: %v\n" :help-echo "\ Control whether the text should be strikethru.") set-face-strikethru-p @@ -414,6 +422,16 @@ ;;; Frames. +(defun face-spec-set (face spec &optional frame) + "Set FACE to the attributes to the first matching entry in SPEC. +Iff optional FRAME is non-nil, set it for that frame only. +See `defface' for information about SPEC. + +Clear all existing attributes first." + (when (fboundp 'copy-face) + (copy-face 'custom-face-empty face frame)) + (custom-face-display-set face spec frame)) + (defun custom-face-display-set (face spec &optional frame) "Set FACE to the attributes to the first matching entry in SPEC. Iff optional FRAME is non-nil, set it for that frame only. @@ -424,7 +442,7 @@ (display (nth 0 entry)) (atts (nth 1 entry))) (setq spec (cdr spec)) - (when (custom-display-match-frame display frame) + (when (face-spec-set-match-display display frame) ;; Avoid creating frame local duplicates of the global face. (unless (and frame (eq display (get face 'custom-face-display))) (apply 'custom-face-attributes-set face frame atts)) @@ -443,7 +461,7 @@ If FRAME is nil, return the default frame properties." (cond (frame ;; Try to get from cache. - (let ((cache (frame-property frame 'custom-properties))) + (let ((cache (custom-frame-parameter frame 'custom-properties))) (unless cache ;; Oh well, get it then. (setq cache (custom-extract-frame-properties frame)) @@ -456,7 +474,7 @@ (setq custom-default-frame-properties (custom-extract-frame-properties (selected-frame)))))) -(defun custom-display-match-frame (display frame) +(defun face-spec-set-match-display (display frame) "Non-nil iff DISPLAY matches FRAME. If FRAME is nil, the current FRAME is used." ;; This is a kludge to get started, we really should use specifiers! @@ -503,7 +521,7 @@ If FRAME is nil or omitted, initialize them for all frames." (mapcar (lambda (symbol) (let ((spec (or (get symbol 'saved-face) - (get symbol 'factory-face)))) + (get symbol 'face-defface-spec)))) (when spec (custom-face-display-set symbol spec frame) (initialize-face-resources symbol frame)))) @@ -545,9 +563,7 @@ (when now (put face 'force-face t)) (when (or now (custom-facep face)) - (when (fboundp 'copy-face) - (copy-face 'custom-face-empty face)) - (custom-face-display-set face spec)) + (face-spec-set face spec)) (setq args (cdr args))) ;; Old format, a plist of FACE SPEC pairs. (let ((face (nth 0 args))
--- a/lisp/custom/custom.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/custom/custom.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,9 +4,26 @@ ;; ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> ;; Keywords: help, faces -;; Version: 1.84 +;; Version: 1.97 ;; X-URL: http://www.dina.kvl.dk/~abraham/custom/ +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; Boston, MA 02111-1307, USA. + ;;; Commentary: ;; ;; If you want to use this code, please visit the URL above. @@ -21,18 +38,23 @@ (require 'widget) -(define-widget-keywords :prefix :tag :load :link :options :type :group) +(define-widget-keywords :initialize :set :get :require :prefix :tag + :load :link :options :type :group) ;; These autoloads should be deleted eventually. (unless (fboundp 'load-gc) ;; From cus-edit.el + (autoload 'custom-set-value "cus-edit" nil t) + (autoload 'custom-set-variable "cus-edit" nil t) (autoload 'customize "cus-edit" nil t) + (autoload 'customize-other-window "cus-edit" nil t) (autoload 'customize-variable "cus-edit" nil t) (autoload 'customize-variable-other-window "cus-edit" nil t) (autoload 'customize-face "cus-edit" nil t) (autoload 'customize-face-other-window "cus-edit" nil t) (autoload 'customize-apropos "cus-edit" nil t) (autoload 'customize-customized "cus-edit" nil t) + (autoload 'customize-saved "cus-edit" nil t) (autoload 'custom-buffer-create "cus-edit") (autoload 'custom-make-dependencies "cus-edit") (autoload 'custom-menu-create "cus-edit") @@ -48,14 +70,62 @@ ;;; The `defcustom' Macro. -(defun custom-declare-variable (symbol value doc &rest args) - "Like `defcustom', but SYMBOL and VALUE are evaluated as normal arguments." - ;; Bind this variable unless it already is bound. +(defun custom-initialize-default (symbol value) + "Initialize SYMBOL with VALUE. +This will do nothing if symbol already has a default binding. +Otherwise, if symbol has a `saved-value' property, it will evaluate +the car of that and used as the default binding for symbol. +Otherwise, VALUE will be evaluated and used as the default binding for +symbol." (unless (default-boundp symbol) ;; Use the saved value if it exists, otherwise the factory setting. (set-default symbol (if (get symbol 'saved-value) (eval (car (get symbol 'saved-value))) - (eval value)))) + (eval value))))) + +(defun custom-initialize-set (symbol value) + "Initialize SYMBOL with VALUE. +Like `custom-initialize-default', but use the function specified by +`:set' to initialize SYMBOL." + (unless (default-boundp symbol) + (funcall (or (get symbol 'custom-set) 'set-default) + symbol + (if (get symbol 'saved-value) + (eval (car (get symbol 'saved-value))) + (eval value))))) + +(defun custom-initialize-reset (symbol value) + "Initialize SYMBOL with VALUE. +Like `custom-initialize-set', but use the function specified by +`:get' to reinitialize SYMBOL if it is already bound." + (funcall (or (get symbol 'custom-set) 'set-default) + symbol + (cond ((default-boundp symbol) + (funcall (or (get symbol 'custom-get) 'default-value) + symbol)) + ((get symbol 'saved-value) + (eval (car (get symbol 'saved-value)))) + (t + (eval value))))) + +(defun custom-initialize-changed (symbol value) + "Initialize SYMBOL with VALUE. +Like `custom-initialize-reset', but only use the `:set' function if the +not using the factory setting. Otherwise, use the `set-default'." + (cond ((default-boundp symbol) + (funcall (or (get symbol 'custom-set) 'set-default) + symbol + (funcall (or (get symbol 'custom-get) 'default-value) + symbol))) + ((get symbol 'saved-value) + (funcall (or (get symbol 'custom-set) 'set-default) + symbol + (eval (car (get symbol 'saved-value))))) + (t + (set-default symbol (eval value))))) + +(defun custom-declare-variable (symbol value doc &rest args) + "Like `defcustom', but SYMBOL and VALUE are evaluated as normal arguments." ;; Remember the factory setting. (put symbol 'factory-value (list value)) ;; Maybe this option was rogue in an earlier version. It no longer is. @@ -64,29 +134,42 @@ (put symbol 'force-value nil)) (when doc (put symbol 'variable-documentation doc)) - (while args - (let ((arg (car args))) - (setq args (cdr args)) - (unless (symbolp arg) - (error "Junk in args %S" args)) - (let ((keyword arg) - (value (car args))) - (unless args - (error "Keyword %s is missing an argument" keyword)) + (let ((initialize 'custom-initialize-set) + (requests nil)) + (while args + (let ((arg (car args))) (setq args (cdr args)) - (cond ((eq keyword :type) - (put symbol 'custom-type value)) - ((eq keyword :options) - (if (get symbol 'custom-options) - ;; Slow safe code to avoid duplicates. - (mapcar (lambda (option) - (custom-add-option symbol option)) - value) - ;; Fast code for the common case. - (put symbol 'custom-options (copy-list value)))) - (t - (custom-handle-keyword symbol keyword value - 'custom-variable)))))) + (unless (symbolp arg) + (error "Junk in args %S" args)) + (let ((keyword arg) + (value (car args))) + (unless args + (error "Keyword %s is missing an argument" keyword)) + (setq args (cdr args)) + (cond ((eq keyword :initialize) + (setq initialize value)) + ((eq keyword :set) + (put symbol 'custom-set value)) + ((eq keyword :get) + (put symbol 'custom-get value)) + ((eq keyword :require) + (push value requests)) + ((eq keyword :type) + (put symbol 'custom-type value)) + ((eq keyword :options) + (if (get symbol 'custom-options) + ;; Slow safe code to avoid duplicates. + (mapcar (lambda (option) + (custom-add-option symbol option)) + value) + ;; Fast code for the common case. + (put symbol 'custom-options (copy-sequence value)))) + (t + (custom-handle-keyword symbol keyword value + 'custom-variable)))))) + (put symbol 'custom-requests requests) + ;; Do the actual initialization. + (funcall initialize symbol value)) (run-hooks 'custom-define-hook) symbol) @@ -102,15 +185,29 @@ The following KEYWORD's are defined: -:type VALUE should be a widget type. +:type VALUE should be a widget type for editing the symbols value. + The default is `sexp'. :options VALUE should be a list of valid members of the widget type. :group VALUE should be a customization group. Add SYMBOL to that group. +:initialize VALUE should be a function used to initialize the + variable. It takes two arguments, the symbol and value + given in the `defcustom' call. The default is + `custom-initialize-default' +:set VALUE should be a function to set the value of the symbol. + It takes two arguments, the symbol to set and the value to + give it. The default is `set-default'. +:get VALUE should be a function to extract the value of symbol. + The function takes one argument, a symbol, and should return + the current value for that symbol. The default is + `default-value'. +:require VALUE should be a feature symbol. Each feature will be + required after initialization, of the the user have saved this + option. -Read the section about customization in the emacs lisp manual for more +Read the section about customization in the Emacs Lisp manual for more information." - `(eval-and-compile - (custom-declare-variable (quote ,symbol) (quote ,value) ,doc ,@args))) + `(custom-declare-variable (quote ,symbol) (quote ,value) ,doc ,@args)) ;;; The `defface' Macro. @@ -157,7 +254,7 @@ `background' (what color is used for the background text) Should be one of `light' or `dark'. -Read the section about customization in the emacs lisp manual for more +Read the section about customization in the Emacs Lisp manual for more information." `(custom-declare-face (quote ,face) ,spec ,doc ,@args)) @@ -165,6 +262,9 @@ (defun custom-declare-group (symbol members doc &rest args) "Like `defgroup', but SYMBOL is evaluated as a normal argument." + (while members + (apply 'custom-add-to-group symbol (car members)) + (setq members (cdr members))) (put symbol 'custom-group (nconc members (get symbol 'custom-group))) (when doc (put symbol 'group-documentation doc)) @@ -206,7 +306,7 @@ :group VALUE should be a customization group. Add SYMBOL to that group. -Read the section about customization in the emacs lisp manual for more +Read the section about customization in the Emacs Lisp manual for more information." `(custom-declare-group (quote ,symbol) ,members ,doc ,@args)) @@ -287,17 +387,22 @@ (while args (let ((entry (car args))) (if (listp entry) - (let ((symbol (nth 0 entry)) - (value (nth 1 entry)) - (now (nth 2 entry))) + (let* ((symbol (nth 0 entry)) + (value (nth 1 entry)) + (now (nth 2 entry)) + (requests (nth 3 entry)) + (set (or (get symbol 'custom-set) 'set-default))) (put symbol 'saved-value (list value)) (cond (now ;; Rogue variable, set it now. (put symbol 'force-value t) - (set-default symbol (eval value))) + (funcall set symbol (eval value))) ((default-boundp symbol) ;; Something already set this, overwrite it. - (set-default symbol (eval value)))) + (funcall set symbol (eval value)))) + (when requests + (put symbol 'custom-requests requests) + (mapcar 'require requests)) (setq args (cdr args))) ;; Old format, a plist of SYMBOL VALUE pairs. (message "Warning: old format `custom-set-variables'")
--- a/lisp/custom/wid-browse.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/custom/wid-browse.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,9 +4,26 @@ ;; ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> ;; Keywords: extensions -;; Version: 1.84 +;; Version: 1.97 ;; X-URL: http://www.dina.kvl.dk/~abraham/custom/ +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; Boston, MA 02111-1307, USA. + ;;; Commentary: ;; ;; Widget browser. See `widget.el'. @@ -16,7 +33,7 @@ (require 'easymenu) (require 'custom) (require 'wid-edit) -(require 'cl) +(eval-when-compile (require 'cl)) (defgroup widget-browse nil "Customization support for browsing widgets." @@ -245,6 +262,37 @@ (put :button 'widget-keyword-printer 'widget-browse-widget) (put :args 'widget-keyword-printer 'widget-browse-sexps) +;;; Widget Minor Mode. + +(defvar widget-minor-mode nil + "I non-nil, we are in Widget Minor Mode.") + (make-variable-buffer-local 'widget-minor-mode) + +(defvar widget-minor-mode-map nil + "Keymap used in Widget Minor Mode.") + +(unless widget-minor-mode-map + (setq widget-minor-mode-map (make-sparse-keymap)) + (set-keymap-parent widget-minor-mode-map widget-keymap)) + +;;;###autoload +(defun widget-minor-mode (&optional arg) + "Togle minor mode for traversing widgets. +With arg, turn widget mode on if and only if arg is positive." + (interactive "P") + (cond ((null arg) + (setq widget-minor-mode (not widget-minor-mode))) + ((<= 0 arg) + (setq widget-minor-mode nil)) + (t + (setq widget-minor-mode t))) + (force-mode-line-update)) + +(add-to-list 'minor-mode-alist '(widget-minor-mode " Widget")) + +(add-to-list 'minor-mode-map-alist + (cons 'widget-minor-mode widget-minor-mode-map)) + ;;; The End: (provide 'wid-browse)
--- a/lisp/custom/wid-edit.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/custom/wid-edit.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,9 +4,26 @@ ;; ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> ;; Keywords: extensions -;; Version: 1.84 +;; Version: 1.97 ;; X-URL: http://www.dina.kvl.dk/~abraham/custom/ +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; Boston, MA 02111-1307, USA. + ;;; Commentary: ;; ;; See `widget.el'. @@ -15,8 +32,7 @@ (require 'widget) -(eval-and-compile - (require 'cl)) +(eval-when-compile (require 'cl)) ;;; Compatibility. @@ -49,6 +65,16 @@ "Make text between FROM and TO intangible." (put-text-property from to 'intangible 'front))) + (if (string-match "XEmacs" emacs-version) + (defun widget-event-point (event) + "Character position of the end of event if that exists, or nil." + (if (mouse-event-p event) + (event-point event) + nil)) + (defun widget-event-point (event) + "Character position of the end of event if that exists, or nil." + (posn-point (event-end event)))) + ;; The following should go away when bundled with Emacs. (condition-case () (require 'custom) @@ -58,7 +84,7 @@ ;; We have the old custom-library, hack around it! (defmacro defgroup (&rest args) nil) (defmacro defcustom (var value doc &rest args) - `(defvar ,var ,value ,doc)) + (` (defvar (, var) (, value) (, doc)))) (defmacro defface (&rest args) nil) (define-widget-keywords :prefix :tag :load :link :options :type :group) (when (fboundp 'copy-face) @@ -66,14 +92,14 @@ (copy-face 'bold 'widget-button-face) (copy-face 'italic 'widget-field-face))) - (unless (fboundp 'event-point) - ;; XEmacs function missing in Emacs. - (defun event-point (event) - "Return the character position of the given mouse-motion, button-press, -or button-release event. If the event did not occur over a window, or did -not occur over text, then this returns nil. Otherwise, it returns an index -into the buffer visible in the event's window." - (posn-point (event-start event)))) + (unless (fboundp 'button-release-event-p) + ;; XEmacs function missing from Emacs. + (defun button-release-event-p (event) + "Non-nil if EVENT is a mouse-button-release event object." + (and (eventp event) + (memq (event-basic-type event) '(mouse-1 mouse-2 mouse-3)) + (or (memq 'click (event-modifiers event)) + (memq 'drag (event-modifiers event)))))) (unless (fboundp 'error-message-string) ;; Emacs function missing in XEmacs. @@ -117,7 +143,7 @@ (defface widget-field-face '((((class grayscale color) (background light)) - (:background "light gray")) + (:background "gray85")) (((class grayscale color) (background dark)) (:background "dark gray")) @@ -126,12 +152,6 @@ "Face used for editable fields." :group 'widgets) -(defcustom widget-menu-max-size 40 - "Largest number of items allowed in a popup-menu. -Larger menus are read through the minibuffer." - :group 'widgets - :type 'integer) - ;;; Utility functions. ;; ;; These are not really widget specific. @@ -163,11 +183,19 @@ (buffer-disable-undo (current-buffer)) (buffer-enable-undo)) +(defcustom widget-menu-max-size 40 + "Largest number of items allowed in a popup-menu. +Larger menus are read through the minibuffer." + :group 'widgets + :type 'integer) + (defun widget-choose (title items &optional event) "Choose an item from a list. First argument TITLE is the name of the list. -Second argument ITEMS is an alist (NAME . VALUE). +Second argument ITEMS is an list whose members are either + (NAME . VALUE), to indicate selectable items, or just strings to + indicate unselectable items. Optional third argument EVENT is an input event. The user is asked to choose between each NAME from the items alist, @@ -188,7 +216,9 @@ (mapcar (function (lambda (x) - (vector (car x) (list (car x)) t))) + (if (stringp x) + (vector x nil nil) + (vector (car x) (list (car x)) t)))) items))))) (setq val (and val (listp (event-object val)) @@ -196,6 +226,7 @@ (car (event-object val)))) (cdr (assoc val items)))) (t + (setq items (remove-if 'stringp items)) (let ((val (completing-read (concat title ": ") items nil t))) (if (stringp val) (let ((try (try-completion val items))) @@ -204,20 +235,6 @@ (cdr (assoc val items))) nil))))) -(defun widget-get-sibling (widget) - "Get the item WIDGET is assumed to toggle. -This is only meaningful for radio buttons or checkboxes in a list." - (let* ((parent (widget-get widget :parent)) - (children (widget-get parent :children)) - child) - (catch 'child - (while children - (setq child (car children) - children (cdr children)) - (when (eq (widget-get child :button) widget) - (throw 'child child))) - nil))) - ;;; Widget text specifications. ;; ;; These functions are for specifying text properties. @@ -371,7 +388,8 @@ (defmacro widget-specify-insert (&rest form) ;; Execute FORM without inheriting any text properties. - `(save-restriction + (` + (save-restriction (let ((inhibit-read-only t) result after-change-functions) @@ -379,11 +397,11 @@ (narrow-to-region (- (point) 2) (point)) (widget-specify-none (point-min) (point-max)) (goto-char (1+ (point-min))) - (setq result (progn ,@form)) + (setq result (progn (,@ form))) (delete-region (point-min) (1+ (point-min))) (delete-region (1- (point-max)) (point-max)) (goto-char (point-max)) - result))) + result)))) (defface widget-inactive-face '((((class grayscale color) (background dark)) @@ -401,7 +419,8 @@ (unless (widget-get widget :inactive) (let ((overlay (make-overlay from to nil t nil))) (overlay-put overlay 'face 'widget-inactive-face) - (overlay-put overlay 'evaporate 't) + (overlay-put overlay 'evaporate t) + (overlay-put overlay 'priority 100) (overlay-put overlay (if (string-match "XEmacs" emacs-version) 'read-only 'modification-hooks) '(widget-overlay-inactive)) @@ -486,7 +505,38 @@ (if (widget-apply widget :active) (widget-apply widget :action event) (error "Attempt to perform action on inactive widget"))) - + +;;; Helper functions. +;; +;; These are widget specific. + +;;;###autoload +(defun widget-prompt-value (widget prompt &optional value unbound) + "Prompt for a value matching WIDGET, using PROMPT. +The current value is assumed to be VALUE, unless UNBOUND is non-nil." + (unless (listp widget) + (setq widget (list widget))) + (setq prompt (format "[%s] %s" (widget-type widget) prompt)) + (setq widget (widget-convert widget)) + (let ((answer (widget-apply widget :prompt-value prompt value unbound))) + (unless (widget-apply widget :match answer) + (error "Value does not match %S type." (car widget))) + answer)) + +(defun widget-get-sibling (widget) + "Get the item WIDGET is assumed to toggle. +This is only meaningful for radio buttons or checkboxes in a list." + (let* ((parent (widget-get widget :parent)) + (children (widget-get parent :children)) + child) + (catch 'child + (while children + (setq child (car children) + children (cdr children)) + (when (eq (widget-get child :button) widget) + (throw 'child child))) + nil))) + ;;; Glyphs. (defcustom widget-glyph-directory (concat data-directory "custom/") @@ -533,14 +583,23 @@ ;; File not readable, give up. (insert tag)))))) -(defun widget-glyph-insert-glyph (widget tag glyph) +(defun widget-glyph-insert-glyph (widget tag glyph &optional down inactive) "In WIDGET, with alternative text TAG, insert GLYPH." (set-glyph-image glyph (cons 'tty tag)) (set-glyph-property glyph 'widget widget) + (when down + (set-glyph-image down (cons 'tty tag)) + (set-glyph-property down 'widget widget)) + (when inactive + (set-glyph-image inactive (cons 'tty tag)) + (set-glyph-property inactive 'widget widget)) (insert "*") (add-text-properties (1- (point)) (point) (list 'invisible t 'end-glyph glyph)) + (widget-put widget :glyph-up glyph) + (when down (widget-put widget :glyph-down down)) + (when inactive (widget-put widget :glyph-inactive inactive)) (let ((help-echo (widget-get widget :help-echo))) (when help-echo (let ((extent (extent-at (1- (point)) nil 'end-glyph)) @@ -575,7 +634,7 @@ (defun widget-create-child (parent type) "Create widget of TYPE." - (let ((widget (copy-list type))) + (let ((widget (copy-sequence type))) (widget-put widget :parent parent) (unless (widget-get widget :indent) (widget-put widget :indent (+ (or (widget-get parent :indent) 0) @@ -586,7 +645,7 @@ (defun widget-create-child-value (parent type value) "Create widget of TYPE with value VALUE." - (let ((widget (copy-list type))) + (let ((widget (copy-sequence type))) (widget-put widget :value (widget-apply widget :value-to-internal value)) (widget-put widget :parent parent) (unless (widget-get widget :indent) @@ -607,7 +666,7 @@ ;; Don't touch the type. (let* ((widget (if (symbolp type) (list type) - (copy-list type))) + (copy-sequence type))) (current widget) (keys args)) ;; First set the :args keyword. @@ -667,11 +726,11 @@ (define-key widget-keymap "\M-\t" 'widget-backward) (define-key widget-keymap [(shift tab)] 'widget-backward) (define-key widget-keymap [backtab] 'widget-backward) - (if (string-match "XEmacs" (emacs-version)) + (if (string-match "XEmacs" emacs-version) (progn - (define-key widget-keymap [button2] 'widget-button-click) - (define-key widget-keymap [button1] 'widget-button1-click)) - (define-key widget-keymap [mouse-2] 'ignore) + ;;Glyph support. + (define-key widget-keymap [button1] 'widget-button1-click) + (define-key widget-keymap [button2] 'widget-button-click)) (define-key widget-keymap [down-mouse-2] 'widget-button-click)) (define-key widget-keymap "\C-m" 'widget-button-press)) @@ -711,19 +770,56 @@ (call-interactively (lookup-key widget-global-map (this-command-keys)))))) +(defface widget-button-pressed-face + '((((class color)) + (:foreground "red")) + (t + (:bold t :underline t))) + "Face used for pressed buttons." + :group 'widgets) + (defun widget-button-click (event) "Activate button below mouse pointer." (interactive "@e") (cond ((and (fboundp 'event-glyph) (event-glyph event)) - (let ((widget (glyph-property (event-glyph event) 'widget))) - (if widget - (widget-apply-action widget event) - (message "You clicked on a glyph.")))) - ((event-point event) - (let ((button (get-text-property (event-point event) 'button))) + (widget-glyph-click event)) + ((widget-event-point event) + (let* ((pos (widget-event-point event)) + (button (get-text-property pos 'button))) (if button - (widget-apply-action button event) + (let ((begin (previous-single-property-change (1+ pos) 'button)) + (end (next-single-property-change pos 'button)) + overlay) + (unwind-protect + (let ((track-mouse t)) + (setq overlay (make-overlay begin end)) + (overlay-put overlay 'face 'widget-button-pressed-face) + (overlay-put overlay + 'mouse-face 'widget-button-pressed-face) + (unless (widget-apply button :mouse-down-action event) + (while (not (button-release-event-p event)) + (setq event (if (fboundp 'read-event) + (read-event) + (next-event)) + pos (widget-event-point event)) + (if (and pos + (eq (get-text-property pos 'button) + button)) + (progn + (overlay-put overlay + 'face + 'widget-button-pressed-face) + (overlay-put overlay + 'mouse-face + 'widget-button-pressed-face)) + (overlay-put overlay 'face nil) + (overlay-put overlay 'mouse-face nil)))) + + (when (and pos + (eq (get-text-property pos 'button) button)) + (widget-apply-action button event))) + (delete-overlay overlay))) (call-interactively (or (lookup-key widget-global-map [ button2 ]) (lookup-key widget-global-map [ down-mouse-2 ]) @@ -736,11 +832,35 @@ (interactive "@e") (if (and (fboundp 'event-glyph) (event-glyph event)) + (widget-glyph-click event) + (call-interactively (lookup-key widget-global-map (this-command-keys))))) + +(defun widget-glyph-click (event) + "Handle click on a glyph." + (let* ((glyph (event-glyph event)) + (widget (glyph-property glyph 'widget)) + (extent (event-glyph-extent event)) + (down-glyph (or (and widget (widget-get widget :glyph-down)) glyph)) + (up-glyph (or (and widget (widget-get widget :glyph-up)) glyph)) + (last event)) + ;; Wait for the release. + (while (not (button-release-event-p last)) + (if (eq extent (event-glyph-extent last)) + (set-extent-property extent 'end-glyph down-glyph) + (set-extent-property extent 'end-glyph up-glyph)) + (setq last (next-event event))) + ;; Release glyph. + (when down-glyph + (set-extent-property extent 'end-glyph up-glyph)) + ;; Apply widget action. + (when (eq extent (event-glyph-extent last)) (let ((widget (glyph-property (event-glyph event) 'widget))) - (if widget - (widget-apply-action widget event) - (message "You clicked on a glyph."))) - (call-interactively (lookup-key widget-global-map (this-command-keys))))) + (cond ((null widget) + (message "You clicked on a glyph.")) + ((not (widget-apply widget :active)) + (message "This glyph is inactive.")) + (t + (widget-apply-action widget event))))))) (defun widget-button-press (pos &optional event) "Activate button at POS." @@ -783,8 +903,9 @@ (t (error "No buttons or fields found")))))) (setq button (widget-at (point))) - (if (and button (widget-get button :tab-order) - (< (widget-get button :tab-order) 0)) + (if (or (and button (widget-get button :tab-order) + (< (widget-get button :tab-order) 0)) + (and button (not (widget-apply button :active)))) (setq arg (1+ arg)))))) (while (< arg 0) (if (= (point-min) (point)) @@ -821,8 +942,9 @@ (button (goto-char button)) (field (goto-char field))) (setq button (widget-at (point))) - (if (and button (widget-get button :tab-order) - (< (widget-get button :tab-order) 0)) + (if (or (and button (widget-get button :tab-order) + (< (widget-get button :tab-order) 0)) + (and button (not (widget-apply button :active)))) (setq arg (1- arg))))) (widget-echo-help (point)) (run-hooks 'widget-move-hook)) @@ -966,6 +1088,11 @@ ;; ;; These functions are used in the definition of multiple widgets. +(defun widget-parent-action (widget &optional event) + "Tell :parent of WIDGET to handle the :action. +Optional EVENT is the event that triggered the action." + (widget-apply (widget-get widget :parent) :action event)) + (defun widget-children-value-delete (widget) "Delete all :children and :buttons in WIDGET." (mapcar 'widget-delete (widget-get widget :children)) @@ -973,11 +1100,36 @@ (mapcar 'widget-delete (widget-get widget :buttons)) (widget-put widget :buttons nil)) +(defun widget-children-validate (widget) + "All the :children must be valid." + (let ((children (widget-get widget :children)) + child found) + (while (and children (not found)) + (setq child (car children) + children (cdr children) + found (widget-apply child :validate))) + found)) + (defun widget-types-convert-widget (widget) "Convert :args as widget types in WIDGET." (widget-put widget :args (mapcar 'widget-convert (widget-get widget :args))) widget) +(defun widget-value-convert-widget (widget) + "Initialize :value from :args in WIDGET." + (let ((args (widget-get widget :args))) + (when args + (widget-put widget :value (car args)) + ;; Don't convert :value here, as this is done in `widget-convert'. + ;; (widget-put widget :value (widget-apply widget + ;; :value-to-internal (car args))) + (widget-put widget :args nil))) + widget) + +(defun widget-value-value-get (widget) + "Return the :value property of WIDGET." + (widget-get widget :value)) + ;;; The `default' Widget. (define-widget 'default nil @@ -998,8 +1150,10 @@ :active 'widget-default-active :activate 'widget-specify-active :deactivate 'widget-default-deactivate + :mouse-down-action (lambda (widget event) nil) :action 'widget-default-action - :notify 'widget-default-notify) + :notify 'widget-default-notify + :prompt-value 'widget-default-prompt-value) (defun widget-default-create (widget) "Create WIDGET at point in the current buffer." @@ -1070,7 +1224,8 @@ (set-marker-insertion-type from t) (set-marker-insertion-type to nil) (widget-put widget :from from) - (widget-put widget :to to)))) + (widget-put widget :to to))) + (widget-clear-undo)) (defun widget-default-format-handler (widget escape) ;; We recognize the %h escape by default. @@ -1132,7 +1287,8 @@ ;; Kludge: this doesn't need to be true for empty formats. (delete-region from to)) (set-marker from nil) - (set-marker to nil))) + (set-marker to nil)) + (widget-clear-undo)) (defun widget-default-value-set (widget value) ;; Recreate widget with new value. @@ -1177,28 +1333,27 @@ ;; Pass notification to parent. (widget-default-action widget event)) +(defun widget-default-prompt-value (widget prompt value unbound) + ;; Read an arbitrary value. Stolen from `set-variable'. +;; (let ((initial (if unbound +;; nil +;; ;; It would be nice if we could do a `(cons val 1)' here. +;; (prin1-to-string (custom-quote value)))))) + (eval-minibuffer prompt )) + ;;; The `item' Widget. (define-widget 'item 'default "Constant items for inclusion in other widgets." - :convert-widget 'widget-item-convert-widget + :convert-widget 'widget-value-convert-widget :value-create 'widget-item-value-create :value-delete 'ignore - :value-get 'widget-item-value-get + :value-get 'widget-value-value-get :match 'widget-item-match :match-inline 'widget-item-match-inline :action 'widget-item-action :format "%t\n") -(defun widget-item-convert-widget (widget) - ;; Initialize :value from :args in WIDGET. - (let ((args (widget-get widget :args))) - (when args - (widget-put widget :value (widget-apply widget - :value-to-internal (car args))) - (widget-put widget :args nil))) - widget) - (defun widget-item-value-create (widget) ;; Insert the printed representation of the value. (let ((standard-output (current-buffer))) @@ -1221,10 +1376,6 @@ ;; Just notify itself. (widget-apply widget :notify widget event)) -(defun widget-item-value-get (widget) - ;; Items are simple. - (widget-get widget :value)) - ;;; The `push-button' Widget. (defcustom widget-push-button-gui t @@ -1258,7 +1409,9 @@ (setq gui (make-gui-button tag 'widget-gui-action widget)) (push (cons tag gui) widget-push-button-cache)) (widget-glyph-insert-glyph widget text - (make-glyph (car (aref gui 1))))) + (make-glyph (nth 0 (aref gui 1))) + (make-glyph (nth 1 (aref gui 1))) + (make-glyph (nth 2 (aref gui 1))))) (insert text)))) (defun widget-gui-action (widget) @@ -1297,10 +1450,13 @@ (define-widget 'editable-field 'default "An editable text field." - :convert-widget 'widget-item-convert-widget + :convert-widget 'widget-value-convert-widget :keymap widget-field-keymap :format "%v" :value "" + :prompt-internal 'widget-field-prompt-internal + :prompt-history 'widget-field-history + :prompt-value 'widget-field-prompt-value :action 'widget-field-action :validate 'widget-field-validate :valid-regexp "" @@ -1310,24 +1466,34 @@ :value-get 'widget-field-value-get :match 'widget-field-match) -;; History of field minibuffer edits. -(defvar widget-field-history nil) +(defvar widget-field-history nil + "History of field minibuffer edits.") + +(defun widget-field-prompt-internal (widget prompt initial history) + ;; Read string for WIDGET promptinhg with PROMPT. + ;; INITIAL is the initial input and HISTORY is a symbol containing + ;; the earlier input. + (read-string prompt initial history)) + +(defun widget-field-prompt-value (widget prompt value unbound) + ;; Prompt for a string. + (let ((initial (if unbound + nil + (cons (widget-apply widget :value-to-internal + value) 0))) + (history (widget-get widget :prompt-history))) + (let ((answer (widget-apply widget + :prompt-internal prompt initial history))) + (widget-apply widget :value-to-external answer)))) (defun widget-field-action (widget &optional event) ;; Edit the value in the minibuffer. - (let ((tag (widget-apply widget :menu-tag-get)) - (invalid (widget-apply widget :validate))) - (when invalid - (error (widget-get invalid :error))) - (widget-value-set widget - (widget-apply widget - :value-to-external - (read-string (concat tag ": ") - (widget-apply - widget - :value-to-internal - (widget-value widget)) - 'widget-field-history))) + (let ((invalid (widget-apply widget :validate))) + (let ((prompt (concat (widget-apply widget :menu-tag-get) ": ")) + (value (unless invalid + (widget-value widget)))) + (let ((answer (widget-apply widget :prompt-value prompt value invalid) )) + (widget-value-set widget answer))) (widget-apply widget :notify widget event) (widget-setup))) @@ -1387,6 +1553,9 @@ (eq (char-after (1- to)) ?\ )) (setq to (1- to))) (let ((result (buffer-substring-no-properties from to))) + (when (string-match "XEmacs" emacs-version) + ;; XEmacs 20.1 bug: b-s-n-p doesn't clear all properties. + (setq result (format "%s" result))) (when secret (let ((index 0)) (while (< (+ from index) to) @@ -1420,6 +1589,7 @@ :value-delete 'widget-children-value-delete :value-get 'widget-choice-value-get :value-inline 'widget-choice-value-inline + :mouse-down-action 'widget-choice-mouse-down-action :action 'widget-choice-action :error "Make a choice" :validate 'widget-choice-validate @@ -1454,6 +1624,39 @@ ;; Get value of the child widget. (widget-apply (car (widget-get widget :children)) :value-inline)) +(defcustom widget-choice-toggle nil + "If non-nil, a binary choice will just toggle between the values. +Otherwise, the user will explicitly have to choose between the values +when he activate the menu." + :type 'boolean + :group 'widgets) + +(defun widget-choice-mouse-down-action (widget &optional event) + ;; Return non-nil if we need a menu. + (let ((args (widget-get widget :args)) + (old (widget-get widget :choice))) + (cond ((not window-system) + ;; No place to pop up a menu. + nil) + ((not (or (fboundp 'x-popup-menu) (fboundp 'popup-menu))) + ;; No way to pop up a menu. + nil) + ((< (length args) 2) + ;; Empty or singleton list, just return the value. + nil) + ((> (length args) widget-menu-max-size) + ;; Too long, prompt. + nil) + ((> (length args) 2) + ;; Reasonable sized list, use menu. + t) + ((and widget-choice-toggle (memq old args)) + ;; We toggle. + nil) + (t + ;; Ask which of the two. + t)))) + (defun widget-choice-action (widget &optional event) ;; Make a choice. (let ((args (widget-get widget :args)) @@ -1472,7 +1675,8 @@ nil) ((= (length args) 1) (nth 0 args)) - ((and (= (length args) 2) + ((and widget-choice-toggle + (= (length args) 2) (memq old args)) (if (eq old (nth 0 args)) (nth 1 args) @@ -1490,11 +1694,8 @@ (widget-value-set widget (widget-apply current :value-to-external (widget-get current :value))) - (widget-apply widget :notify widget event) - (widget-setup))) - ;; Notify parent. - (widget-apply widget :notify widget event) - (widget-clear-undo)) + (widget-apply widget :notify widget event) + (widget-setup)))) (defun widget-choice-validate (widget) ;; Valid if we have made a valid choice. @@ -1550,7 +1751,7 @@ ;; Toggle value. (widget-value-set widget (not (widget-value widget))) (widget-apply widget :notify widget event)) - + ;;; The `checkbox' Widget. (define-widget 'checkbox 'toggle @@ -1650,7 +1851,7 @@ (defun widget-checklist-match-inline (widget values) ;; Find the values which match a type in the checklist. (let ((greedy (widget-get widget :greedy)) - (args (copy-list (widget-get widget :args))) + (args (copy-sequence (widget-get widget :args))) found rest) (while values (let ((answer (widget-checklist-match-up args values))) @@ -1671,7 +1872,7 @@ ;; Find the vals which match a type in the checklist. ;; Return an alist of (TYPE MATCH). (let ((greedy (widget-get widget :greedy)) - (args (copy-list (widget-get widget :args))) + (args (copy-sequence (widget-get widget :args))) found) (while vals (let ((answer (widget-checklist-match-up args vals))) @@ -1730,13 +1931,9 @@ (define-widget 'choice-item 'item "Button items that delegate action events to their parents." - :action 'widget-choice-item-action + :action 'widget-parent-action :format "%[%t%] \n") -(defun widget-choice-item-action (widget &optional event) - ;; Tell parent what happened. - (widget-apply (widget-get widget :parent) :action event)) - ;;; The `radio-button' Widget. (define-widget 'radio-button 'toggle @@ -1958,7 +2155,7 @@ :value-create 'widget-editable-list-value-create :value-delete 'widget-children-value-delete :value-get 'widget-editable-list-value-get - :validate 'widget-editable-list-validate + :validate 'widget-children-validate :match 'widget-editable-list-match :match-inline 'widget-editable-list-match-inline :insert-before 'widget-editable-list-insert-before @@ -2003,16 +2200,6 @@ (apply 'append (mapcar (lambda (child) (widget-apply child :value-inline)) (widget-get widget :children)))) -(defun widget-editable-list-validate (widget) - ;; All the chilren must be valid. - (let ((children (widget-get widget :children)) - child found) - (while (and children (not found)) - (setq child (car children) - children (cdr children) - found (widget-apply child :validate))) - found)) - (defun widget-editable-list-match (widget value) ;; Value must be a list and all the members must match the type. (and (listp value) @@ -2058,7 +2245,7 @@ (defun widget-editable-list-delete-at (widget child) ;; Delete child from list of children. (save-excursion - (let ((buttons (copy-list (widget-get widget :buttons))) + (let ((buttons (copy-sequence (widget-get widget :buttons))) button (inhibit-read-only t) after-change-functions) @@ -2136,7 +2323,7 @@ :value-create 'widget-group-value-create :value-delete 'widget-children-value-delete :value-get 'widget-editable-list-value-get - :validate 'widget-editable-list-validate + :validate 'widget-children-validate :match 'widget-group-match :match-inline 'widget-group-match-inline) @@ -2205,9 +2392,14 @@ (define-widget 'const 'item "An immutable sexp." + :prompt-value 'widget-const-prompt-value :format "%t\n%d") -(define-widget 'function-item 'item +(defun widget-const-prompt-value (widget prompt value unbound) + ;; Return the value of the const. + (widget-value widget)) + +(define-widget 'function-item 'const "An immutable function name." :format "%v\n%h" :documentation-property (lambda (symbol) @@ -2215,28 +2407,62 @@ (documentation symbol t) (error nil)))) -(define-widget 'variable-item 'item +(define-widget 'variable-item 'const "An immutable variable name." :format "%v\n%h" :documentation-property 'variable-documentation) +(defvar widget-string-prompt-value-history nil + "History of input to `widget-string-prompt-value'.") + (define-widget 'string 'editable-field "A string" :tag "String" - :format "%[%t%]: %v") + :format "%{%t%}: %v" + :prompt-history 'widget-string-prompt-value-history) (define-widget 'regexp 'string "A regular expression." - ;; Should do validation. + :match 'widget-regexp-match + :validate 'widget-regexp-validate :tag "Regexp") +(defun widget-regexp-match (widget value) + ;; Match valid regexps. + (and (stringp value) + (condition-case nil + (prog1 t + (string-match value "")) + (error nil)))) + +(defun widget-regexp-validate (widget) + "Check that the value of WIDGET is a valid regexp." + (let ((val (widget-value widget))) + (condition-case data + (prog1 nil + (string-match val "")) + (error (widget-put widget :error (error-message-string data)) + widget)))) + (define-widget 'file 'string "A file widget. It will read a file name from the minibuffer when activated." - :format "%[%t%]: %v" + :prompt-value 'widget-file-prompt-value + :format "%{%t%}: %v" :tag "File" :action 'widget-file-action) +(defun widget-file-prompt-value (widget prompt value unbound) + ;; Read file from minibuffer. + (abbreviate-file-name + (if unbound + (read-file-name prompt) + (let ((prompt2 (format "%s (default %s) " prompt value)) + (dir (file-name-directory value)) + (file (file-name-nondirectory value)) + (must-match (widget-get widget :must-match))) + (read-file-name prompt2 dir nil must-match file))))) + (defun widget-file-action (widget &optional event) ;; Read a file name from the minibuffer. (let* ((value (widget-value widget)) @@ -2255,11 +2481,18 @@ It will read a directory name from the minibuffer when activated." :tag "Directory") -(define-widget 'symbol 'string +(defvar widget-symbol-prompt-value-history nil + "History of input to `widget-symbol-prompt-value'.") + +(define-widget 'symbol 'editable-field "A lisp symbol." :value nil :tag "Symbol" + :format "%{%t%}: %v" :match (lambda (widget value) (symbolp value)) + :prompt-internal 'widget-symbol-prompt-internal + :prompt-match 'symbolp + :prompt-history 'widget-symbol-prompt-value-history :value-to-internal (lambda (widget value) (if (symbolp value) (symbol-name value) @@ -2269,24 +2502,49 @@ (intern value) value))) +(defun widget-symbol-prompt-internal (widget prompt initial history) + ;; Read file from minibuffer. + (let ((answer (completing-read prompt obarray + (widget-get widget :prompt-match) + nil initial history))) + (if (and (stringp answer) + (not (zerop (length answer)))) + answer + (error "No value")))) + +(defvar widget-function-prompt-value-history nil + "History of input to `widget-function-prompt-value'.") + (define-widget 'function 'sexp - ;; Should complete on functions. "A lisp function." + :prompt-value 'widget-field-prompt-value + :prompt-internal 'widget-symbol-prompt-internal + :prompt-match 'fboundp + :prompt-history 'widget-function-prompt-value-history + :action 'widget-field-action :tag "Function") +(defvar widget-variable-prompt-value-history nil + "History of input to `widget-variable-prompt-value'.") + (define-widget 'variable 'symbol ;; Should complete on variables. "A lisp variable." + :prompt-match 'boundp + :prompt-history 'widget-variable-prompt-value-history :tag "Variable") -(define-widget 'sexp 'string +(define-widget 'sexp 'editable-field "An arbitrary lisp expression." :tag "Lisp expression" + :format "%{%t%}: %v" :value nil :validate 'widget-sexp-validate :match (lambda (widget value) t) :value-to-internal 'widget-sexp-value-to-internal - :value-to-external (lambda (widget value) (read value))) + :value-to-external (lambda (widget value) (read value)) + :prompt-history 'widget-sexp-prompt-value-history + :prompt-value 'widget-sexp-prompt-value) (defun widget-sexp-value-to-internal (widget value) ;; Use pp for printer representation. @@ -2320,6 +2578,25 @@ (error (widget-put widget :error (error-message-string data)) widget))))) +(defvar widget-sexp-prompt-value-history nil + "History of input to `widget-sexp-prompt-value'.") + +(defun widget-sexp-prompt-value (widget prompt value unbound) + ;; Read an arbitrary sexp. + (let ((found (read-string prompt + (if unbound nil (cons (prin1-to-string value) 0)) + (widget-get widget :prompt-history)))) + (save-excursion + (let ((buffer (set-buffer (get-buffer-create " *Widget Scratch*")))) + (erase-buffer) + (insert found) + (goto-char (point-min)) + (let ((answer (read buffer))) + (unless (eobp) + (error "Junk at end of expression: %s" + (buffer-substring (point) (point-max)))) + answer))))) + (define-widget 'integer 'sexp "An integer." :tag "Integer" @@ -2331,22 +2608,26 @@ value)) :match (lambda (widget value) (integerp value))) -(define-widget 'character 'string +(define-widget 'character 'editable-field "An character." :tag "Character" :value 0 :size 1 :format "%{%t%}: %v\n" - :type-error "This field should contain a character" + :valid-regexp "\\`.\\'" + :error "This field should contain a single character" :value-to-internal (lambda (widget value) - (if (integerp value) - (char-to-string value) - value)) + (if (stringp value) + value + (char-to-string value))) :value-to-external (lambda (widget value) (if (stringp value) (aref value 0) value)) - :match (lambda (widget value) (integerp value))) + :match (lambda (widget value) + (if (fboundp 'characterp) + (characterp value) + (integerp value)))) (define-widget 'number 'sexp "A floating point number." @@ -2395,12 +2676,56 @@ (define-widget 'choice 'menu-choice "A union of several sexp types." :tag "Choice" - :format "%[%t%]: %v") + :format "%[%t%]: %v" + :prompt-value 'widget-choice-prompt-value) + +(defun widget-choice-prompt-value (widget prompt value unbound) + "Make a choice." + (let ((args (widget-get widget :args)) + (completion-ignore-case (widget-get widget :case-fold)) + current choices old) + ;; Find the first arg that match VALUE. + (let ((look args)) + (while look + (if (widget-apply (car look) :match value) + (setq old (car look) + look nil) + (setq look (cdr look))))) + ;; Find new choice. + (setq current + (cond ((= (length args) 0) + nil) + ((= (length args) 1) + (nth 0 args)) + ((and (= (length args) 2) + (memq old args)) + (if (eq old (nth 0 args)) + (nth 1 args) + (nth 0 args))) + (t + (while args + (setq current (car args) + args (cdr args)) + (setq choices + (cons (cons (widget-apply current :menu-tag-get) + current) + choices))) + (let ((val (completing-read prompt choices nil t))) + (if (stringp val) + (let ((try (try-completion val choices))) + (when (stringp try) + (setq val try)) + (cdr (assoc val choices))) + nil))))) + (if current + (widget-prompt-value current prompt nil t) + value))) (define-widget 'radio 'radio-button-choice "A union of several sexp types." :tag "Choice" - :format "%{%t%}:\n%v") + :format "%{%t%}:\n%v" + :prompt-value 'widget-choice-prompt-value) (define-widget 'repeat 'editable-list "A variable length homogeneous list." @@ -2415,7 +2740,12 @@ (define-widget 'boolean 'toggle "To be nil or non-nil, that is the question." :tag "Boolean" - :format "%{%t%}: %[%v%]\n") + :prompt-value 'widget-boolean-prompt-value + :format "%[%t%]: %v\n") + +(defun widget-boolean-prompt-value (widget prompt value unbound) + ;; Toggle a boolean. + (y-or-n-p prompt)) ;;; The `color' Widget.
--- a/lisp/custom/widget-example.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/custom/widget-example.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,7 +4,7 @@ ;; ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> ;; Keywords: help, extensions, faces, hypermedia -;; Version: 1.84 +;; Version: 1.97 ;; X-URL: http://www.dina.kvl.dk/~abraham/custom/ (require 'widget)
--- a/lisp/custom/widget.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/custom/widget.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,9 +4,26 @@ ;; ;; Author: Per Abrahamsen <abraham@dina.kvl.dk> ;; Keywords: help, extensions, faces, hypermedia -;; Version: 1.84 +;; Version: 1.97 ;; X-URL: http://www.dina.kvl.dk/~abraham/custom/ +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; Boston, MA 02111-1307, USA. + ;;; Commentary: ;; ;; If you want to use this code, please visit the URL above. @@ -27,8 +44,11 @@ (set (car keywords) (car keywords))) (setq keywords (cdr keywords))))))) -(define-widget-keywords :text-format :deactivate :active :inactive - :activate :sibling-args :delete-button-args +(define-widget-keywords :mouse-down-action :glyph-up :glyph-down + :glyph-inactive + :prompt-internal :prompt-history :prompt-match + :prompt-value :text-format :deactivate :active + :inactive :activate :sibling-args :delete-button-args :insert-button-args :append-button-args :button-args :tag-glyph :off-glyph :on-glyph :valid-regexp :secret :sample-face :sample-face-get :case-fold :widget-doc @@ -49,9 +69,11 @@ (autoload 'widget-apply "wid-edit") (autoload 'widget-create "wid-edit") (autoload 'widget-insert "wid-edit") + (autoload 'widget-prompt-value "wid-edit") (autoload 'widget-browse "wid-browse" nil t) (autoload 'widget-browse-other-window "wid-browse" nil t) - (autoload 'widget-browse-at "wid-browse" nil t)) + (autoload 'widget-browse-at "wid-browse" nil t) + (autoload 'widget-minor-mode "wid-browse" nil t)) (defun define-widget (name class doc &rest args) "Define a new widget type named NAME from CLASS. @@ -68,7 +90,8 @@ The third argument DOC is a documentation string for the widget." (put name 'widget-type (cons class args)) - (put name 'widget-documentation doc)) + (put name 'widget-documentation doc) + name) ;;; The End.
--- a/lisp/efs/efs-ti-explorer.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/efs/efs-ti-explorer.el Mon Aug 13 09:36:16 2007 +0200 @@ -6,7 +6,7 @@ ;; Version: #Revision: 1.1 $ ;; RCS: ;; Description: Explorer support for efs -;; Author: Jamie Zawinski <jwz@lucid.com> +;; Author: Jamie Zawinski <jwz@netscape.com> ;; Created: Thu Dec 17 15:04:14 1992 ;; Modified: Sun Nov 27 18:42:47 1994 by sandy on gandalf ;; Language: Emacs-Lisp
--- a/lisp/eos/sun-eos-menubar.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/eos/sun-eos-menubar.el Mon Aug 13 09:36:16 2007 +0200 @@ -106,7 +106,7 @@ (add-menu-button '("Help") ["SPARCworks..." eos::sw-intro t]) (add-submenu nil (append '("SPARCworks") (copy-tree eos::short-menu)) - "VC" + "Version Control" ) )))
--- a/lisp/locale/ja/locale-start.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/locale/ja/locale-start.el Mon Aug 13 09:36:16 2007 +0200 @@ -1,119 +1,161 @@ +;;; @(#)locale-start.el.euc 1.7 97/03/06 13:43:21 +;;; locale/ja/locale-start.el --- startup.el customized for ja locale. +;;; This file, being an .el file, +;;; must be in ISO 2022 encoding after installation. +;; Copyright (C) 1985-1986, 1990, 1992-1995 Free Software Foundation, Inc. +;; Copyright (c) 1993-1997 Sun Microsystems, Inc. +;; Copyright (C) 1995 Board of Trustees, University of Illinois + +;; Maintainer: XEmacs +;; Keywords: internal + +;; This file is part of XEmacs. + +;; XEmacs is free software; you can redistribute it and/or modify it +;; under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; XEmacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; 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 Free +;; Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. + (defun startup-splash-frame-body () `("\n" ,(emacs-version) "\n" (face bold-italic "\ Copyright (C) 1985-1996 Free Software Foundation, Inc. Copyright (C) 1990-1994 Lucid, Inc. -Copyright (C) 1993-1996 Sun Microsystems, Inc. All Rights Reserved. +Copyright (C) 1993-1997 Sun Microsystems, Inc. All Rights Reserved. Copyright (C) 1994-1996 Board of Trustees, University of Illinois Copyright (C) 1995-1996 Ben Wing\n\n") ,@(if (featurep 'sparcworks) `( "\ -Sun provides support for the WorkShop/XEmacs integration package only. -All other XEmacs packages are provided to you \"AS IS\". -For full details, type " (key describe-no-warranty) -" to refer to the GPL Version 2, dated June 1991.\n\n" -,@(let ((lang (or (getenv "LC_ALL") (getenv "LC_MESSAGES") (getenv "LANG")))) - (if (and - (not (featurep 'mule)) ; Already got mule? - (not (eq 'tty (console-type))) ; No Mule support on tty's yet - lang ; Non-English locale? - (not (string-equal lang "C")) - (not (string-match "^en" lang)) - (locate-file "xemacs-mule" exec-path)) ; Comes with Sun WorkShop - '( "\ -This version of XEmacs has been built with support for Latin-1 languages only. -To handle other languages you need to run a Multi-lingual (`Mule') version of -XEmacs, by either running the command `xemacs-mule', or by using the X resource -`ESERVE*defaultXEmacsPath: xemacs-mule' when starting XEmacs from Sun WorkShop.\n\n")))) +$(B%5%s$O!"(BWorkShop/Emacs $(BE}9g2=%Q%C%1!<%8$N$_$r%5%]!<%H$7$^$9!#(B +$(BB>$N(B XEmacs $(B%Q%C%1!<%8$O$9$Y$F!"!V8=>u$N$^$^!W$G6!5k$5$l$^$9!#(B +$(B>\:Y(B ($(B1QJ8(B) $(B$O(B" (key describe-no-warranty) "$(B$H%?%$%W$7$F!"(B +1991 $(BG/(B 6 $(B7nHG(B GPL $(B%P!<%8%g%s(B 2 $(B$r$4Mw$/$@$5$$!#(B +$(BK\(B XEmacs $(B$O4pK\%a%K%e!<$K8B$jF|K\8l2=$5$l$F$$$^$9!#AH$_9~$^$l$?(B +$(B%a!<%k(B (VM$(B!"(BMH) $(B$d%K%e!<%9$rFI$`$?$a$N%Q%C%1!<%8(B (Gnus) $(BEy$O!"(B +$(BF|K\8l$r40`z$K$O=hM}$G$-$^$;$s$N$G!"$4;HMQ$K$J$k>l9g$O==J,$4Cm0U(B +$(B$/$@$5$$!#(B\n") + + '("XEmacs $(B$K$O(B *$(B$^$C$?$/2?$N(B* $(BJ]>c$b$"$j$^$;$s!#>\:Y$O!"(B" + (key describe-no-warranty) "$(B$r%?%$%W$7$F$/$@$5$$!#(B\n")) - '("XEmacs comes with ABSOLUTELY NO WARRANTY; type " - (key describe-no-warranty) " for full details.\n")) + "XEmacs $(B$NJ#@=$O5v2D$5$l$F$$$^$9!#5v2D$N>r7o$r8+$k$K$O!"(B\n" + (key describe-copying) " $(B$H%?%$%W$7$F$/$@$5$$!#(B\n" + "$(B:G?7HG$N<hF@J}K!$K$D$$$F$O!"(B" (key describe-distribution) + " $(B$H%?%$%W$7$F$/$@$5$$!#(B\n\n" - "You may give out copies of XEmacs; type " - (key describe-copying) " to see the conditions.\n" - "Type " (key describe-distribution) - " for information on getting the latest version.\n\n" - - "Type " (key help-command) " or use the " (face bold "Help") " menu to get help.\n" - "Type " (key advertised-undo) " to undo changes (`C-' means use the Control key).\n" - "To get out of XEmacs, type " (key save-buffers-kill-emacs) ".\n" - "Type " (key help-with-tutorial) " for a tutorial on using XEmacs.\n" - "Type " (key info) " to enter Info, " - "which you can use to read online documentation.\n\n" + "$(B%X%k%W>pJs$r8+$k$K$O!"(B" (key help-command) " $(B$H%?%$%W!"$^$?$O(B" + (face bold "$(B%X%k%W(B") "$(B%a%K%e!<$r;HMQ(B\n" + "$(B$7$F$/$@$5$$(B\n" + (key advertised-undo) " $(B$K$h$jJQ99$r<h$j>C$;$^$;$9!#(B(C- $(B$O!"(BControl $(B%-!<$G$9!#(B)\n" + "XEmacs $(B$r=*N;$9$k$K$O!"(B" (key save-buffers-kill-emacs) " $(B$H%?%$%W$7$F$/$@$5$$!#(B\n" + (key help-with-tutorial) " $(B$G(B XEmacs $(B$N;HMQJ}K!$N<B=,$r3+;O$G$-$^$9!#(B\n" + (key info) " $(B$K$h$j!"(BInfo $(B%b!<%I$KF~$j!"%*%s%i%$%s$N%I%-%e%a%s%H$r(B\n" + "$(BFI$`$3$H$,$G$-$^$9!#(B\n" (face (bold red) ( "\ -For tips and answers to frequently asked questions, see the XEmacs FAQ. -\(It's on the Help menu, or type " (key xemacs-local-faq) " [a capital F!].\)")))) +$(BIQHK$K?R$M$i$l$k<ALd$H$=$NEz$($O!"(BXEmacs $(BLdEz=8$K$"$j$^$9!#(B\n" + "$(B%X%k%W%a%K%e!<$r;HMQ$9$k$+!"(B"(key xemacs-local-faq) " $(B$H%?%$%W$7$F$/$@$5$$!#(B")))) (defun command-line-do-help (arg) - "Print the $(BF|K\(B XEmacs usage message and exit." + "Print the XEmacs usage message and exit." (let ((standard-output 'external-debugging-output)) (princ (concat "\n" (emacs-version) "\n\n")) (princ (if (featurep 'x) - (concat "XEmacs accepts all standard X Toolkit command line options.\n" - "In addition, the") - "The")) - (princ " following options are accepted: + "XEmacs $(B$O!"(BX $(B%D!<%k%-%C%H$NI8=`%3%^%s%I%*%W%7%g%s$r$9$Y$FG'<1$7$^$9!#(B\n$(B$=$l$K2C$($F!"(B" + "XEmacs $(B$O!"(B ")) + (princ " $(B0J2<$N%*%W%7%g%s$rG'<1$7!"=P8==g$K=hM}$7$^$9(B: - -t <device> Use TTY <device> instead of the terminal for input - and output. This implies the -nw option. - -nw Inhibit the use of any window-system-specific - display code: use the current tty. - -batch Execute noninteractively (messages go to stderr). - -debug-init Enter the debugger if an error in the init file occurs. - -unmapped Do not map the initial frame. - -no-site-file Do not load the site-specific init file (site-start.el). - -no-init-file Do not load the user-specific init file (~/.emacs). - -q Same as -no-init-file. - -user <user> Load user's init file instead of your own. - -u <user> Same as -user.\n") - (let ((l command-switch-alist) - (insert (lambda (&rest x) - (princ " ") - (let ((len 2)) - (while x - (princ (car x)) - (incf len (length (car x))) - (setq x (cdr x))) - (when (>= len 24) - (terpri) (setq len 0)) - (while (< len 24) - (princ " ") - (incf len)))))) - (while l - (let ((name (car (car l))) - (fn (cdr (car l))) - doc arg cons) - (cond - ((and (symbolp fn) (get fn 'undocumented)) nil) - (t - (setq doc (documentation fn)) - (if (member doc '(nil "")) (setq doc "(undocumented)")) - (cond ((string-match "\n\\(<.*>\\)\n?\\'" doc) - ;; Doc of the form "The frobber switch\n<arg1> <arg2>" - (setq arg (substring doc (match-beginning 1) (match-end 1)) - doc (substring doc 0 (match-beginning 0)))) - ((string-match "\n+\\'" doc) - (setq doc (substring doc 0 (match-beginning 0))))) - (if (and (setq cons (rassq fn command-switch-alist)) - (not (eq cons (car l)))) - (setq doc (format "Same as %s." (car cons)))) - (if arg - (funcall insert name " " arg) - (funcall insert name)) - (princ doc) - (terpri)))) - (setq l (cdr l)))) - (princ "\ - +N <file> Start displaying <file> at line N. + -t $(B%G%P%$%9L>(B $(BC<Kv$NBe$o$j$K;XDj$N(B TTY $(B%G%P%$%9$r;HMQ$7$FF~=PNO$r(B + $(B9T$J$&!#(B-nw $(B$,<+F0E*$K2>Dj$5$l$k!#(B + -nw $(B%&%#%s%I%&%7%9%F%`$r;HMQ$;$:!"8=(B TTY $(B$r;HMQ!#(B($(BCm(B: TTY + $(B%b!<%I$G$NF|K\8lI=<($O!"K\%P!<%8%g%s$N(B XEmacs $(B$G$O$G$-(B + $(B$^$;$s!#(B) + -batch $(BHsBPOCE*;HMQ!#%a%C%;!<%8$O!"I8=`%(%i!<(B (stderr) $(B%X!#(B + -debug-init $(B=i4|2=%U%!%$%k$G$N%(%i!<H/@8;~$K$O%G%P%C%,$r5/F0!#(B + -unmapped $(B=i4|%U%l!<%`$N%^%C%W$r$7$J$$!#(B + -no-site-file $(B%5%$%HFC2==i4|2=%U%!%$%k(B (site-start.el) $(B$rFI$_9~$^$J$$!#(B + -no-init-file $(B%f!<%6!<FC2==i4|2=%U%!%$%k(B (~/.emacs) $(B$rFI$_9~$^$J$$!#(B + -q -no-init-file $(B$HF15A!#(B + -user $(B%f!<%6!<L>(B $(B<+J,$N=i4|2=%U%!%$%k$NBe$o$j$K;XDj%f!<%6!<$N%U%!%$%k$r;HMQ!#(B + -u $(B%f!<%6!<L>(B -user $(B$HF15A!#(B\n") +;; $(B1Q8lHG$G$O!"0J2<$N$h$&$J%3!<%I$K$h$j!"%I%-%e%a%s%H$N0lIt$,I=<($5$l$F$$$?$,!"(B +;; $(B$3$l$G$O!"1Q8l$N%I%-%e%a%s%H$7$+I=<($G$-$J$$$N$G!"$3$N%3!<%I$O%3%a%s%H%"%&%H$7!"(B +;; $(BC1=c$K@bL@$r0u;z$9$k%3!<%I$HCV$-49$($k!#(B +;; (let ((l command-switch-alis\nt) +;; (insert (lambda (&rest x) +;; (princ " ") +;; (let ((len 2)) +;; (while x +;; (princ (car x)) +;; (incf len (length (car x))) +;; (setq x (cdr x))) +;; (when (>= len 24) +;; (terpri) (setq len 0)) +;; (while (< len 24) +;; (princ " ") +;; (incf len)))))) +;; (while l +;; (let ((name (car (car l))) +;; (fn (cdr (car l))) +;; doc arg cons) +;; (cond +;; ((and (symbolp fn) (get fn 'undocumented)) nil) +;; (t +;; (setq doc (documentation fn)) +;; (if (member doc '(nil "")) (setq doc "(undocumented)")) +;; (cond ((string-match "\n\\(<.*>\\)\n?\\'" doc) +;; ;; Doc of the form "The frobber switch\n<arg1> <arg2>" +;; (setq arg (substring doc (match-beginning 1) (match-end 1)) +;; doc (substring doc 0 (match-beginning 0)))) +;; ((string-match "\n+\\'" doc) +;; (setq doc (substring doc 0 (match-beginning 0))))) +;; (if (and (setq cons (rassq fn command-switch-alist)) +;; (not (eq cons (car l)))) +;; (setq doc (format "Same as %s." (car cons)))) +;; +;; (if arg +;; (funcall insert name " " arg) +;; (funcall insert name)) +;; (princ doc) +;; (terpri)))) +;; (setq l (cdr l)))) +;; $(BCV$-49$(ItJ,3+;O(B + (princ "\ + -help XEmacs $(B;HMQK!$rI=<($7$F=*N;!#(B + -flags -help $(B$HF15A!#(B + -h -help $(B$HF15A!#(B + -? -help $(B$HF15A!#(B + -version $(B%P!<%8%g%s>pJs$rI=<($7$F=*N;!#(B + -V -version $(B$HF15A!#(B + -funcall $(B4X?tL>(B $(B;XDj$N(B lisp $(B4X?t$r0z?t$J$7$G5/F0!#(B + -f $(B4X?tL>(B -funcall $(B$HF15A!#(B + -eval $(B%U%)!<%`(B lisp $(B$N%U%)!<%`$rI>2A!#0zMQ(B (quote) $(B$OCm0U?<$/9T$J$C$F$/$@$5$$!#(B + -load $(B%U%!%$%kL>(B $(B;XDj$N(B lisp $(B%3!<%I$r(B XEmacs $(B$KFI$_9~$`!#(B + -l $(B%U%!%$%kL>(B -load $(B$HF15A!#(B + -insert $(B%U%!%$%kL>(B $(B8=%P%C%U%!$K%U%!%$%k$rA^F~!#(B + -i $(B%U%!%$%kL>(B -insert $(B$HF15A!#(B + -kill XEmacs $(B$r=*N;!#(B + -tooltalk ToolTalk $(B%5!<%P!<$K@\B3!#(B\n") +;; $(BCV$-49$(ItJ,=*N;(B + (princ "\ + +N $(B%U%!%$%kL>(B $(B;XDj%U%!%$%k$r(B N $(B9TL\$+$iI=<(!#(B -Anything else is considered a file name, and is placed into a buffer for -editing. +$(BB>$N$9$Y$F7A<0$N0z?t$O%U%!%$%kL>$H2r<a$5$l!"JT=8$N$?$a$K%P%C%U%!$KFI$_9~$^(B +$(B$l$^$9!#(B -XEmacs has an online tutorial and manuals. Type ^Ht (Control-h t) after -starting XEmacs to run the tutorial. Type ^Hi to enter the manual browser. -Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n") - +XEmacs $(B$K$O!"%*%s%i%$%s$N<+=,=q$H%^%K%e%"%k(B ($(BN>J}$H$b1Q8lHG$N$_(B) $(B$,IUB0$7(B +$(B$F$$$^$9!#<+=,=q$r3+;O$9$k$K$O!"(BXEmacs $(B3+;O8e$K!"(B^Ht (Control-h t) $(B$r%?%$%W(B +$(B$7$F$/$@$5$$!#%^%K%e%"%k$rFI$`$K$O!"(B^Hi$(B!"$5$i$K>\$7$$%X%k%W>pJs$O!"(B^H^H^H +(Control-h $(B$r(B 3 $(B2s(B) $(B$r%?%$%W$7$F$/$@$5$$!#(B\n") (kill-emacs 0)))
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lisp/modes/autoconf-mode.el Mon Aug 13 09:36:16 2007 +0200 @@ -0,0 +1,83 @@ +;;; autoconf-mode.el --- autoconf code editing commands for Emacs + +;; Author: Martin Buchholz (mrb@eng.sun.com) +;; Maintainer: Martin Buchholz +;; Keywords: languages, faces, m4, configure + +;; This file is part of XEmacs + +;; XEmacs is free software; you can redistribute it and/or modify it +;; under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; XEmacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; 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 Free +;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA +;; 02111-1307, USA. + +;;; Synched up with: not in FSF. + +;;; Commentary: + +;; A major mode for editing autoconf input (like configure.in). +;; Derived from m4-mode.el by Andrew Csillag (drew@staff.prodigy.com) + +;;; Code: + +;;thank god for make-regexp.el! +(defvar autoconf-font-lock-keywords + `(("\\bdnl \\(.*\\)" 1 font-lock-comment-face t) + ("\\$[0-9*#@]" . font-lock-variable-name-face) + ("\\b\\(m4_\\)?\\(builtin\\|change\\(com\\|quote\\|word\\)\\|d\\(e\\(bug\\(file\\|mode\\)\\|cr\\|f\\(ine\\|n\\)\\)\\|iv\\(ert\\|num\\)\\|nl\\|umpdef\\)\\|e\\(rrprint\\|syscmd\\|val\\)\\|f\\(ile\\|ormat\\)\\|gnu\\|i\\(f\\(def\\|else\\)\\|n\\(c\\(lude\\|r\\)\\|d\\(ex\\|ir\\)\\)\\)\\|l\\(en\\|ine\\)\\|m\\(4\\(exit\\|wrap\\)\\|aketemp\\)\\|p\\(atsubst\\|opdef\\|ushdef\\)\\|regexp\\|s\\(hift\\|include\\|ubstr\\|ys\\(cmd\\|val\\)\\)\\|tra\\(ceo\\(ff\\|n\\)\\|nslit\\)\\|un\\(d\\(efine\\|ivert\\)\\|ix\\)\\)\\b" . font-lock-keyword-face) + "default font-lock-keywords") +) + +(defvar autoconf-mode-syntax-table nil + "syntax table used in autoconf mode") +(setq autoconf-mode-syntax-table (make-syntax-table)) +(modify-syntax-entry ?\" "\"" autoconf-mode-syntax-table) +(modify-syntax-entry ?\' "\"" autoconf-mode-syntax-table) +(modify-syntax-entry ?# "<\n" autoconf-mode-syntax-table) +(modify-syntax-entry ?\n ">#" autoconf-mode-syntax-table) +(modify-syntax-entry ?\( "." autoconf-mode-syntax-table) +(modify-syntax-entry ?\) "." autoconf-mode-syntax-table) +(modify-syntax-entry ?\[ "(]" autoconf-mode-syntax-table) +(modify-syntax-entry ?\] ")[" autoconf-mode-syntax-table) +(modify-syntax-entry ?* "." autoconf-mode-syntax-table) +(modify-syntax-entry ?_ "_" autoconf-mode-syntax-table) + +(defvar autoconf-mode-map + (let ((map (make-sparse-keymap))) + (define-key map "\C-c\C-c" 'comment-region) + map)) + +;;;###autoload +(defun autoconf-mode () + "A major-mode to edit autoconf input files like configure.in +\\{autoconf-mode-map} +" + (interactive) + (kill-all-local-variables) + (use-local-map autoconf-mode-map) + + (make-local-variable 'comment-start) + (setq comment-start "dnl") + (make-local-variable 'parse-sexp-ignore-comments) + (setq parse-sexp-ignore-comments t) + + (make-local-variable 'font-lock-defaults) + (setq major-mode 'autoconf-mode) + (setq mode-name "Autoconf") + (setq font-lock-defaults `(autoconf-font-lock-keywords nil)) + (set-syntax-table autoconf-mode-syntax-table) + (run-hooks 'autoconf-mode-hook)) + +(provide 'autoconf-mode) + +;;; autoconf-mode.el ends here
--- a/lisp/modes/m4-mode.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/modes/m4-mode.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,7 +4,7 @@ ;; Maintainer: Andrew Csillag (drew@staff.prodigy.com) ;; Keywords: languages, faces -;; This file is (not yet) part of GNU Emacs. +;; This file is part of GNU Emacs. ;; GNU Emacs is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by @@ -28,7 +28,7 @@ ;; It also sets the font-lock syntax stuff for colorization ;; By Drew Csillag (drew@staff.prodigy.com) -;; $Id: m4-mode.el,v 1.2 1997/01/23 05:29:30 steve Exp $ +;; $Id: m4-mode.el,v 1.3 1997/05/18 03:39:57 steve Exp $ ;; History: @@ -47,6 +47,16 @@ ;; fixed syntax table so _define_ isn't keywordified ;; 10/29/96 1.8 DC fixed a problem where comments go fontified incorrectly ;; if they had quotes in them +;; 11/21/96 1.9 DC collapsed 4 regexps into 1 and removed a duplicate, +;; removed a duplicate backslash +;; 05/16/97 1.10 DC added contributed fixes and enhancements from +;; Martin Buchholz +;; Can now specify options to m4 via m4-program-options +;; Now terminates m4 processes when the buffer send +is +;; done +;; dnl and m4_dnl recognized as comment starters + ;; To Do's: ;; * want to make m4-m4-(buffer|region) look sorta like M-x compile look&feel ? @@ -62,26 +72,42 @@ ;; (cons '(".*\\.m4$" . m4-mode) ;; auto-mode-alist)) - ;;; Thanks: ;;; to Akim Demaille and Terry Jones for the bug reports +;;; to Simon Marshall for the regexp tip +;;; to Martin Buchholz for some general fixes ;;; Code: ;;path to the m4 program -(defvar m4-program "/usr/bin/m4") +(defvar m4-program + (cond + ((file-exists-p "/usr/local/bin/m4") "/usr/local/bin/m4") + ((file-exists-p "/usr/bin/m4") "/usr/bin/m4") + ((file-exists-p "/bin/m4") "/bin/m4") + ((file-exists-p "/usr/ccs/bin/m4") "/usr/ccs/bin/m4") + ) +) + +;;options to m4 +(defconst m4-program-options nil) +;;to use --prefix-builtins, you can use +;;(defconst m4-program-options '("-P")) +;;or +;;(defconst m4-program-options '("--prefix-builtins")) ;;thank god for make-regexp.el! (defvar m4-font-lock-keywords `( - ("^\\\#.*" . font-lock-comment-face) - ("\\\$\\\*" . font-lock-variable-name-face) - ("\\\$[0-9]" . font-lock-variable-name-face) - ("\\\$\\\#" . font-lock-variable-name-face) - ("\\\$\\\@" . font-lock-variable-name-face) - ("\\\$\\\*" . font-lock-variable-name-face) - ("\\b\\(builtin\\|change\\(com\\|quote\\|word\\)\\|d\\(e\\(bug\\(file\\|mode\\)\\|cr\\|f\\(ine\\|n\\)\\)\\|iv\\(ert\\|num\\)\\|nl\\|umpdef\\)\\|e\\(rrprint\\|syscmd\\|val\\)\\|f\\(ile\\|ormat\\)\\|gnu\\|i\\(f\\(def\\|else\\)\\|n\\(c\\(lude\\|r\\)\\|d\\(ex\\|ir\\)\\)\\)\\|l\\(en\\|ine\\)\\|m\\(4\\(exit\\|wrap\\)\\|aketemp\\)\\|p\\(atsubst\\|opdef\\|ushdef\\)\\|regexp\\|s\\(hift\\|include\\|ubstr\\|ys\\(cmd\\|val\\)\\)\\|tra\\(ceo\\(ff\\|n\\)\\|nslit\\)\\|un\\(d\\(efine\\|ivert\\)\\|ix\\)\\)\\b" . font-lock-keyword-face) - ("\\b\\(m4_\\(builtin\\|change\\(com\\|quote\\|word\\)\\|d\\(e\\(bug\\(file\\|mode\\)\\|cr\\|f\\(ine\\|n\\)\\)\\|iv\\(ert\\|num\\)\\|nl\\|umpdef\\)\\|e\\(rrprint\\|syscmd\\|val\\)\\|f\\(ile\\|ormat\\)\\|i\\(f\\(def\\|else\\)\\|n\\(c\\(lude\\|r\\)\\|d\\(ex\\|ir\\)\\)\\)\\|l\\(en\\|ine\\)\\|m\\(4\\(_undefine\\|exit\\|wrap\\)\\|aketemp\\)\\|p\\(atsubst\\|opdef\\|ushdef\\)\\|regexp\\|s\\(hift\\|include\\|ubstr\\|ys\\(cmd\\|val\\)\\)\\|tra\\(ceo\\(ff\\|n\\)\\|nslit\\)\\|undivert\\)\\)\\b" . font-lock-keyword-face) + ("\\(\\bdnl\\b\\|\\bm4_dnl\\b\\|^\\#\\).*$" . +font-lock-comment-face) + ("\\$[*#@0-9]" . font-lock-variable-name-face) + +("\\b\\(builtin\\|change\\(com\\|quote\\|word\\)\\|d\\(e\\(bug\\(file\\|mode\\)\\|cr\\|f\\(ine\\|n\\)\\)\\|iv\\(ert\\|num\\)\\|nl\\|umpdef\\)\\|e\\(rrprint\\|syscmd\\|val\\)\\|f\\(ile\\|ormat\\)\\|gnu\\|i\\(f\\(def\\|else\\)\\|n\\(c\\(lude\\|r\\)\\|d\\(ex\\|ir\\)\\)\\)\\|l\\(en\\|ine\\)\\|m\\(4\\(exit\\|wrap\\)\\|aketemp\\)\\|p\\(atsubst\\|opdef\\|ushdef\\)\\|regexp\\|s\\(hift\\|include\\|ubstr\\|ys\\(cmd\\|val\\)\\)\\|tra\\(ceo\\(ff\\|n\\)\\|nslit\\)\\|un\\(d\\(efine\\|ivert\\)\\|ix\\)\\)\\b" +. font-lock-keyword-face) + +("\\b\\(m4_\\(builtin\\|change\\(com\\|quote\\|word\\)\\|d\\(e\\(bug\\(file\\|mode\\)\\|cr\\|f\\(ine\\|n\\)\\)\\|iv\\(ert\\|num\\)\\|nl\\|umpdef\\)\\|e\\(rrprint\\|syscmd\\|val\\)\\|f\\(ile\\|ormat\\)\\|i\\(f\\(def\\|else\\)\\|n\\(c\\(lude\\|r\\)\\|d\\(ex\\|ir\\)\\)\\)\\|l\\(en\\|ine\\)\\|m\\(4\\(_undefine\\|exit\\|wrap\\)\\|aketemp\\)\\|p\\(atsubst\\|opdef\\|ushdef\\)\\|regexp\\|s\\(hift\\|include\\|ubstr\\|ys\\(cmd\\|val\\)\\)\\|tra\\(ceo\\(ff\\|n\\)\\|nslit\\)\\|undivert\\)\\)\\b" +. font-lock-keyword-face) "default font-lock-keywords") ) @@ -106,25 +132,38 @@ (define-key map "\C-c\C-c" 'comment-region) map)) +(defun m4-end-m4 (process event) + (cond ((equal event "kill\n") (princ "m4 process done")) + (t (princ + (format "Process: %s had the event `%s'" process event))))) + +(defun m4-start-m4 () + (eval (append (append '(start-process "m4process" "*m4 output*" +m4-program) + m4-program-options) '("-e"))) + (set-process-sentinel (get-process "m4process") 'm4-end-m4) +) + (defun m4-m4-buffer () "send contents of the current buffer to m4" (interactive) - (start-process "m4process" "*m4 output*" m4-program "-e") + (m4-start-m4) (process-send-region "m4process" (point-min) (point-max)) (process-send-eof "m4process") - (switch-to-buffer "*m4 output*") + (switch-to-buffer-other-window "*m4 output*") + (delete-process "m4process") ) + (defun m4-m4-region () "send contents of the current region to m4" (interactive) - (start-process "m4process" "*m4 output*" m4-program "-e") + (m4-start-m4) (process-send-region "m4process" (point) (mark)) (process-send-eof "m4process") - (switch-to-buffer "*m4 output*") + (switch-to-buffer-other-window "*m4 output*") ) -;;;###autoload (defun m4-mode () "A major-mode to edit m4 macro files \\{m4-mode-map} @@ -142,7 +181,7 @@ (make-local-variable 'font-lock-defaults) (setq major-mode 'm4-mode mode-name "m4" - font-lock-defaults `(m4-font-lock-keywords nil) + font-lock-defaults '(m4-font-lock-keywords nil) ) (set-syntax-table m4-mode-syntax-table) (run-hooks 'm4-mode-hook))
--- a/lisp/modes/mail-abbrevs.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/modes/mail-abbrevs.el Mon Aug 13 09:36:16 2007 +0200 @@ -1,6 +1,6 @@ ;;; Abbrev-expansion of mail aliases. ;;; Copyright (C) 1985-1994 Free Software Foundation, Inc. -;;; Created: 19 oct 90, Jamie Zawinski <jwz@lucid.com> +;;; Created: 19 oct 90, Jamie Zawinski <jwz@netscape.com> ;;; Modified: 5 apr 92, Roland McGrath <roland@gnu.ai.mit.edu> ;;; Last change 4-may-94. jwz
--- a/lisp/modes/sendmail.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/modes/sendmail.el Mon Aug 13 09:36:16 2007 +0200 @@ -1005,10 +1005,8 @@ t) (or soft (progn (goto-char end) - ;; #### FSF has the next two clauses reversed. - ;; which is correct? - (skip-chars-backward "\n") - (insert "\n" field ": "))) + (insert "\n" field ": ") + (skip-chars-backward "\n"))) nil))) (defun mail-text ()
--- a/lisp/mule/mule-files.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/mule/mule-files.el Mon Aug 13 09:36:16 2007 +0200 @@ -65,7 +65,7 @@ (defvar buffer-file-coding-system-alist '(("\\.\\(el\\|emacs\\|info\\(-[0-9]+\\)?\\|texi\\)$" . iso-2022-8) ("\\(ChangeLog\\|CHANGES-beta\\)$" . iso-2022-8) - ("\\.\\(gz\\|Z\\)$" . no-conversion) + ("\\.\\(gz\\|Z\\)$" . binary) ("/spool/mail/.*$" . convert-mbox-coding-system)) "Alist specifying the coding system used for particular files. Each element of the alist is a cons of a regexp, specifying the files
--- a/lisp/packages/apropos.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/apropos.el Mon Aug 13 09:36:16 2007 +0200 @@ -252,7 +252,13 @@ (if (setq doc (face-doc-string symbol)) (substring doc 0 (string-match "\n" doc)) - "(not documented)")))) + "(not documented)")) + (when (get symbol 'custom-group) + (if (setq doc (documentation-property + symbol 'group-documentation t)) + (substring doc 0 + (string-match "\n" doc)) + "(not documented)")))) (setq p (cdr p))))) nil)) @@ -576,6 +582,7 @@ "User Option" do-keys) (apropos-print-doc 'describe-variable 2 "Variable" do-keys)) + (apropos-print-doc 'customize-other-window 6 "Group" do-keys) (apropos-print-doc 'customize-face-other-window 5 "Face" do-keys) (apropos-print-doc 'widget-browse-other-window 4 "Widget" do-keys) (apropos-print-doc 'apropos-describe-plist 3
--- a/lisp/packages/auto-save.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/auto-save.el Mon Aug 13 09:36:16 2007 +0200 @@ -2,7 +2,7 @@ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; ;; File: auto-save.el -;; Version: $Revision: 1.4 $ +;; Version: $Revision: 1.5 $ ;; RCS: ;; Description: Safer autosaving with support for efs and /tmp. ;; This version of auto-save is designed to work with efs, @@ -11,7 +11,7 @@ ;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -(defconst auto-save-version (substring "$Revision: 1.4 $" 11 -2) +(defconst auto-save-version (substring "$Revision: 1.5 $" 11 -2) "Version number of auto-save.") ;;; Copyright (C) 1992 by Sebastian Kremer <sk@thp.uni-koeln.de> @@ -84,7 +84,7 @@ ;;;; ACKNOWLEDGEMENT =================================================== ;;; This code is loosely derived from autosave-in-tmp.el by Jamie -;;; Zawinski <jwz@lucid.com> (the version I had was last modified 22 +;;; Zawinski <jwz@netscape.com> (the version I had was last modified 22 ;;; dec 90 jwz) and code submitted to ange-ftp-lovers on Sun, 5 Apr ;;; 92 23:20:47 EDT by drw@BOURBAKI.MIT.EDU (Dale R. Worley). ;;; auto-save.el tries to cover the functionality of those two
--- a/lisp/packages/font-lock.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/font-lock.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,7 +4,7 @@ ;; Copyright (C) 1995 Amdahl Corporation. ;; Copyright (C) 1996 Ben Wing. -;; Author: Jamie Zawinski <jwz@lucid.com>, for the LISPM Preservation Society. +;; Author: Jamie Zawinski <jwz@netscape.com>, for the LISPM Preservation Society. ;; Minimally merged with FSF 19.34 by Barry Warsaw <bwarsaw@python.org> ;; Then (partially) synched with FSF 19.30, leading to: ;; Next Author: RMS
--- a/lisp/packages/gnuserv.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/gnuserv.el Mon Aug 13 09:36:16 2007 +0200 @@ -1,695 +1,653 @@ -; Lisp Interface code between GNU Emacs and gnuserv. -; -; This file is part of GNU Emacs. -; -; Copying is permitted under those conditions described by the GNU -; General Public License. -; -; Copyright (C) 1989-1996 Free Software Foundation, Inc. -; -; Author: Andy Norman (ange@hplb.hpl.hp.com) based on -; 'lisp/server.el' from the 18.52 GNU Emacs distribution. -; -; Please mail bugs and suggestions to the author at the above address. -; +;;; gnuserv.el --- Lisp interface code between Emacs and gnuserv +;; Copyright (C) 1989-1997 Free Software Foundation, Inc. + +;; Version: 3.1 +;; Author: Andy Norman (ange@hplb.hpl.hp.com), originally based on server.el +;; Hrvoje Niksic <hniksic@srce.hr> +;; Keywords: environment, processes, terminals + +;; This file is part of XEmacs. + +;; XEmacs is free software; you can redistribute it and/or modify it +;; under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; XEmacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; 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 +;; Free Software Foundation, 59 Temple Place - Suite 330, +;; Boston, MA 02111-1307, USA. + ;;; Synched up with: Not in FSF. -; Updated for XEmacs, GNU Emacs 19 and Epoch V4 to use multiple frames -; by Bob Weiner, <weiner@mot.com>, 1/20/94. (Still works with Emacs V18, too.) -; Modified 'server-process-filter' to use \^D as end of request terminator -; as gnuclient and gnudoit have been modified to send. This permits -; multi-line requests. -; Modified 'server-make-window-visible' to work with multiple frames. -; Modified 'server-find-file' to display in a separate frame when possible. -; Modified 'server-edit' to delete newly created frame when used to -; terminate an edit and to signal an error if called within a -; non-server-edit buffer. -; Bob Weiner, <weiner@mot.com>, 5/9/94. -; Added 'server-done-function' variable. Made default value 'kill-buffer' -; instead of 'bury-buffer' as in original gnuserv.el. -; -; Darrell Kindred <dkindred+@cmu.edu> May/1994 -; Updated to allow multi-line return values: -; - output to gnuserv is "m/n:xxx" where m is the client number, -; n is the length of the data, and xxx is the data itself, followed -; by newline -; -; Arup Mukherjee <arup+@cmu.edu> May/1994 -; Updated for XEmacs 19.10, and others: -; - use find-file-other-screen if present -; - new variable gnuserv-frame can be set to a frame or screen which -; is used for all edited files. -; - check to see if server.el is already loaded and complain if it is, since -; gnuserv.el can't coexist with server.el -; - rename server-start to gnuserv-start, although server-start remains as -; an alias. This allows gnuserv-start to be autoloaded from gnuserv.el -; - changed server-get-buffer to take into account that in newer emacsen, -; get buffer returns nil on deleted buffers. -; - only try to create/delete frames or screens if window-system is non-nil -; (otherwise things don't work w/ emacs19 on a dumb terminal) -; -; Ben Wing <wing@666.com> sometime in 1995 -; Updated to allow `gnuattach'-type connections to the existing TTY -; -; Ben Wing <wing@666.com> May/1996 -; patch to get TTY terminal type correct. -; -; Jan Vroonhof <vroonhof@math.ethz.ch> July/1996 -; ported the server-temp-file-regexp feature from server.el -; ported server hooks from server.el -; ported kill-*-query functions from server.el (and made it optional) -; synced other behaviour with server.el +;;; Commentary: + +;; Gnuserv is run when Emacs needs to operate as a server for other +;; processes. Specifically, any number of files can be attached for +;; editing to a running XEmacs process using the `gnuclient' program. + +;; Use `M-x gnuserv-start' to start the server and `gnuclient files' +;; to load them to XEmacs. When you are done with a buffer, press +;; `C-x #' (`M-x gnuserv-edit'). You can put (gnuserv-start) to your +;; .emacs, and enable `gnuclient' as your Unix "editor". When all the +;; buffers for a client have been edited and exited with +;; `gnuserv-edit', the client "editor" will return to the program that +;; invoked it. + +;; Your editing commands and Emacs' display output go to and from the +;; terminal or X display in the usual way. If you are running under +;; X, a new X frame will be open for each gnuclient. If you are on a +;; TTY, this TTY will be attached as a new device to the running +;; XEmacs, and will be removed once you are done with the buffer. + +;; To evaluate a Lisp form in a running Emacs, use the `gnudoit' +;; utility. For example `gnudoit "(+ 2 3)"' will print `5', whereas +;; `gnudoit "(gnus)"' will fire up your favorite newsreader. Like +;; gnuclient, `gnudoit' requires the server to be started prior to +;; using it. + +;; For more information you can refer to man pages of gnuclient, +;; gnudoit and gnuserv, distributed with XEmacs. + +;; gnuserv.el was originally written by Andy Norman as an improvement +;; ver William Sommerfeld's server.el. Since then, a number of people +;; have worked on it, including Bob Weiner, Darell Kindred, Arup +;; Mukherjee, Ben Wing and Jan Vroonhof. It was completely rewritten +;; (labeled as version 3) by Hrvoje Niksic in May 1997. + +;; Jan Vroonhof <vroonhof@math.ethz.ch> July/1996 +;; ported the server-temp-file-regexp feature from server.el +;; ported server hooks from server.el +;; ported kill-*-query functions from server.el (and made it optional) +;; synced other behaviour with server.el +;; +;; Jan Vroonhof +;; Customized. +;; +;; Hrvoje Niksic <hniksic@srce.hr> May/1997 +;; Completely rewritten. Now uses `defstruct' and other CL stuff +;; to define clients cleanly. Dave, thanks! +;;; Code: + +(defconst gnuserv-rcs-version + "$Id: gnuserv.el,v 1.8 1997/05/18 03:40:06 steve Exp $") (defgroup gnuserv nil - "Lisp interface between Emacs and gnuserv" - :prefix "server-" + "The gnuserv suite of programs to talk to Emacs from outside." + :group 'environment :group 'processes :group 'terminals) -(defconst gnuserv-rcs-header-id "!Header: gnuserv.el,v 2.1 95/02/16 12:00:16 arup alpha !") - - -;; server.el and gnuserv.el can't coexist because of conflicting defvar's and -;; function names. - -(if (and (boundp 'server-buffer-clients) - (not (featurep 'gnuserv))) - (error "Can't run gnuserv because server.el appears to be loaded already")) +;;;###autoload +(defcustom gnuserv-frame nil + "*The frame to be used to display all edited files. +If nil, then a new frame is created for each file edited. +If t, then the currently selected frame will be used. +If a function, then this will be called with a symbol `x' or `tty' as the +only argument, and its return value will be interpreted as above." + :tag "Gnuserv Frame" + :type '(radio (const :tag "Create new frame each time" nil) + (const :tag "Use selected frame" t) + (function-item :tag "Use main Emacs frame" + gnuserv-main-frame-function) + (function-item :tag "Use visible frame, otherwise create new" + gnuserv-visible-frame-function) + (function-item :tag "Create special Gnuserv frame and use it" + gnuserv-special-frame-function) + (function :tag "Other")) + :group 'gnuserv) -;;;###autoload -(defvar gnuserv-frame nil - "*If non-nil, the frame to be used to display all edited files. -If nil, then a new frame is created for each file edited. -This variable has no effect in XEmacs versions older than 19.9.") +(defcustom gnuserv-done-function 'kill-buffer + "*Function used to remove a buffer after editing. +It is called with one BUFFER argument. Functions such as 'kill-buffer' and +'bury-buffer' are good values. See also `gnuserv-done-temp-file-function'." + :type '(radio (function-item kill-buffer) + (function-item bury-buffer) + (function :tag "Other")) + :group 'gnuserv) -(defcustom server-done-function 'kill-buffer - "*A function of one argument, a buffer, which removes the buffer after editing. -Functions such as 'kill-buffer' and 'bury-buffer' are good values. See also -`server-done-temp-file-function'" +(defcustom gnuserv-done-temp-file-function 'kill-buffer + "*Function used to remove a temporary buffer after editing. +It is called with one BUFFER argument. Functions such as 'kill-buffer' and + 'bury-buffer' are good values. See also `gnuserv-done-temp-file-function'." + :type '(radio (function-item kill-buffer) + (function-item bury-buffer) + (function :tag "Other")) + :group 'gnuserv) + +(defcustom gnuserv-find-file-function 'find-file + "*Function to visit a file with. +It takes one argument, a file name to visit." :type 'function :group 'gnuserv) -(defcustom server-done-temp-file-function 'kill-buffer - "*A function of one argument, a buffer, which removes the buffer after editing a -temporary file. Functions such as 'kill-buffer' and 'bury-buffer' are -good values. See also `server-done-function'" - :type 'function +(defcustom gnuserv-view-file-function 'view-file + "*Function to view a file with. +It takes one argument, a file name to view." + :type '(radio (function-item view-file) + (function-item find-file-read-only) + (function :tag "Other")) :group 'gnuserv) -(defcustom server-program "gnuserv" - "*The program to use as the edit server" +(defcustom gnuserv-program "gnuserv" + "*Program to use as the editing server." :type 'string :group 'gnuserv) +(defcustom gnuserv-visit-hook nil + "*Hook run after visiting a file." + :type 'hook + :group 'gnuserv) -(defcustom server-visit-hook nil - "*List of hooks to call when visiting a file for the Emacs server." +(defcustom gnuserv-done-hook nil + "*Hook run when done editing a buffer for the Emacs server. +The hook functions are called after the file has been visited, with the +current buffer set to the visiting buffer." :type 'hook :group 'gnuserv) -;; defined by server.el but obsolete? -;; (defvar server-switch-hook nil -;; "*List of hooks to call when switching to a buffer for the Emacs server.") - -(defcustom server-done-hook nil - "*List of hooks to call when done editing a buffer for the Emacs server." - :type 'hook +(defcustom gnuserv-kill-quietly nil + "*Non-nil means to kill buffers with clients attached without requiring confirmation." + :type 'boolean :group 'gnuserv) - -(defvar server-process nil - "The current server process") - -(defvar server-string "" - "The last input string from the server") - -(defvar server-kill-last-frame nil - "set to t to kill last frame") +(defcustom gnuserv-temp-file-regexp "^/tmp/Re\\|/draft$" + "*Regexp which should match filenames of temporary files deleted +and reused by the programs that invoke the Emacs server." + :type 'regexp + :group 'gnuserv) -(defvar current-client nil - "The client we are currently talking to") - -(defvar server-clients nil - "List of current server clients. -Each element is (CLIENTID BUFFER...) where CLIENTID is an integer -that can be given to the server process to identify a client. -When a buffer is killed, it is removed from this list.") - -(defcustom server-kill-quietly nil - "If this variable is set then don't confirm kills of buffers with -clients attached" +(defcustom gnuserv-make-temp-file-backup nil + "*Non-nil makes the server backup temporary files also." :type 'boolean :group 'gnuserv) + +;; The old functions are provided as aliases, to avoid breaking .emacs +;; files. However, they are obsolete and should be avoided. -(defvar server-buffer-clients nil - "List of client ids for clients requesting editing of the current buffer.") +(defvaralias 'server-frame 'gnuserv-frame) +(defvaralias 'server-done-function 'gnuserv-done-function) +(defvaralias 'server-done-temp-file-function 'gnuserv-done-temp-file-function) +(defvaralias 'server-find-file-function 'gnuserv-find-file-function) +(defvaralias 'server-program 'gnuserv-program) +(defvaralias 'server-visit-hook 'gnuserv-visit-hook) +(defvaralias 'server-done-hook 'gnuserv-done-hook) +(defvaralias 'server-kill-quietly 'gnuserv-kill-quietly) +(defvaralias 'server-temp-file-regexp 'gnuserv-temp-file-regexp) +(defvaralias 'server-make-temp-file-backup 'gnuserv-make-temp-file-backup) + + +;;; Internal variables: + +(defstruct gnuclient + "An object that encompasses several buffers in one. +Normally, a client connecting to Emacs will be assigned an id, and +will request editing of several files. + +ID - Client id (integer). +BUFFERS - List of buffers that \"belong\" to the client. + NOTE: one buffer can belong to several clients. +DEVICE - The device this client is on. If the device was also created. + by a client, it will be placed to `gnuserv-devices' list. +FRAME - Frame created by the client, or nil if the client didn't + create a frame. + +All the slots default to nil." + (id nil) + (buffers nil) + (device nil) + (frame nil)) + +(defvar gnuserv-process nil + "The current gnuserv process.") + +(defvar gnuserv-string "" + "The last input string from the server.") + +(defvar gnuserv-current-client nil + "The client we are currently talking to.") + +(defvar gnuserv-clients nil + "List of current gnuserv clients. +Each element is a gnuclient structure that identifies a client.") + +(defvar gnuserv-devices nil + "List of devices created by clients.") + +(defvar gnuserv-special-frame nil + "Frame created specially for Server.") + +;; We want the client-infested buffers to have some modeline +;; identification, so we'll make a "minor mode". +(defvar gnuserv-minor-mode nil) +(make-variable-buffer-local 'gnuserv-mode) +(pushnew '(gnuserv-minor-mode " Server") minor-mode-alist) + + +;; Sample gnuserv-frame functions + +(defun gnuserv-main-frame-function (type) + "Returns a sensible value for the main Emacs frame." + (if (eq type 'x) + (car (frame-list)) + nil)) -(defcustom server-temp-file-regexp "^/tmp/Re\\|/draft$" - "*Regexp which should match filenames of temporary files -which are deleted and reused after each edit -by the programs that invoke the emacs server." - :type 'regexp - :group 'gnuserv) +(defun gnuserv-visible-frame-function (type) + "Returns a frame if there is a frame that is truly visible, nil otherwise. +This is meant in the X sense, so it will not return frames that are on another +visual screen. Totally visible frames are preferred. If none found, return nil." + (if (eq type 'x) + (cond ((car (filtered-frame-list 'frame-totally-visible-p + (selected-device)))) + ((car (filtered-frame-list (lambda (frame) + ;; eq t as in not 'hidden + (eq t (frame-visible-p frame))) + (selected-device))))) + nil)) + +(defun gnuserv-special-frame-function (type) + "Creates a special frame for Gnuserv and returns it on later invocations." + (unless (frame-live-p gnuserv-special-frame) + (setq gnuserv-special-frame (make-frame))) + gnuserv-special-frame) + + +;;; Communication functions + +(defun gnuserv-sentinel (proc msg) + (case (process-status proc) + (exit (message "Gnuserv subprocess exited; restarting") + ;; This will also kill all the existing clients. + (gnuserv-start-1)) + (closed (message "Gnuserv subprocess closed")) + (signal (message "Gnuserv subprocess killed")))) + +(defun gnuserv-process-filter (proc string) + "Process gnuserv client requests to execute Emacs commands." + (setq gnuserv-string (concat gnuserv-string string)) + ;; C-d means end of request. + (when (string-match "\C-d$" gnuserv-string) + (cond ((string-match "^[0-9]+" gnuserv-string) ; client request id + (let ((header (read-from-string gnuserv-string))) + ;; Set the client we are talking to. + (setq gnuserv-current-client (car header)) + ;; Evaluate the expression + (condition-case oops + (eval (car (read-from-string gnuserv-string (cdr header)))) + ;; In case of an error, write the description to the + ;; client, and then signal it. + (error (setq gnuserv-string "") + (gnuserv-write-to-client gnuserv-current-client oops) + (setq gnuserv-current-client nil) + (signal (car oops) (cdr oops))) + (quit (setq gnuserv-string "") + (gnuserv-write-to-client gnuserv-current-client oops) + (setq gnuserv-current-client nil) + (signal 'quit nil))) + (setq gnuserv-string ""))) + (t + (error "%s: invalid response from gnuserv" gnuserv-string) + (setq gnuserv-string ""))))) + +(defun gnuserv-write-to-client (client-id form) + "Write the given form to the given client via the gnuserv process." + (when (eq (process-status gnuserv-process) 'run) + (let* ((result (format "%s" form)) + (s (format "%s/%d:%s\n" client-id + (length result) result))) + (process-send-string gnuserv-process s)))) + + +;; The following two functions are helper functions, used by +;; gnuclient. + +(defun gnuserv-eval (form) + "Evaluate form and return result to client." + (gnuserv-write-to-client gnuserv-current-client (eval form)) + (setq gnuserv-current-client nil)) + +(defun gnuserv-eval-quickly (form) + "Let client know that we've received the request, and then eval the form. +This order is important as not to keep the client waiting." + (gnuserv-write-to-client gnuserv-current-client nil) + (setq gnuserv-current-client nil) + (eval form)) -(defcustom server-make-temp-file-backup nil - "Non-nil makes the server backup temporary files also" - :type 'regexp - :group 'gnuserv) + +;; "Execute" a client connection, called by gnuclient. This is the +;; backbone of gnuserv.el. +(defun gnuserv-edit-files (type list &optional flags) + "For each (line-number . file) pair in LIST, edit the file at line-number. +The visited buffers are memorized, so that when \\[gnuserv-edit] is invoked +in such a buffer, or when it is killed, or the client's device deleted, the +client will be invoked that the edit is finished. -(make-variable-buffer-local 'server-buffer-clients) -(setq-default server-buffer-clients nil) -(or (assq 'server-buffer-clients minor-mode-alist) - (setq minor-mode-alist (cons '(server-buffer-clients " Server") - minor-mode-alist))) +TYPE should either be a (tty TTY TERM PID) list, or (x DISPLAY) list. +If FLAGS is `quick', just edit the files in Emacs. +If FLAGS is `view', view the files read-only." + (or (not flags) + (memq flags '(quick view)) + (error "Invalid flag %s" flags)) + (let* ((old-device-num (length (device-list))) + (new-frame nil) + (dest-frame (if (functionp gnuserv-frame) + (funcall gnuserv-frame (car type)) + gnuserv-frame)) + ;; The gnuserv-frame dependencies are ugly. + (device (cond ((frame-live-p dest-frame) + (frame-device dest-frame)) + ((null dest-frame) + (case (car type) + (tty (apply 'make-tty-device (cdr type))) + (x (make-x-device (cadr type))) + (t (error "Invalid device type")))) + (t + (selected-device)))) + (frame (cond ((frame-live-p dest-frame) + dest-frame) + ((null dest-frame) + (setq new-frame (make-frame nil device)) + new-frame) + (t (selected-frame)))) + (client (make-gnuclient :id gnuserv-current-client + :device device + :frame new-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))) + (push device gnuserv-devices)) + ;; Visit all the listed files. + (while list + (let ((line (caar list)) (path (cdar list))) + (select-frame frame) + ;; Visit the file. + (funcall (if (eq flags 'view) + gnuserv-view-file-function + gnuserv-find-file-function) + path) + (goto-line line) + (run-hooks 'gnuserv-visit-hook) + ;; Don't memorize the quick and view buffers. + (when (null flags) + (pushnew (current-buffer) (gnuclient-buffers client)) + (setq gnuserv-minor-mode t)) + (pop list))) + (cond ((and flags (device-on-window-system-p device)) + ;; Exit if on X device, and quick or view. + ;; NOTE: if the client is to finish now, it must absolutely + ;; /not/ be included to the list of clients. This way the + ;; client-ids should be unique. + (gnuserv-write-to-client (gnuclient-id client) nil)) + (t + ;; Else, the client gets a vote. + (push client gnuserv-clients) + ;; Explain buffer exit options. If dest-frame is nil, the + ;; user can exit via `delete-frame'. OTOH, if FLAGS are + ;; nil and there are some buffers, the user can exit via + ;; `gnuserv-edit'. + (if (and (null flags) + (gnuclient-buffers client)) + (message (substitute-command-keys + "Type `\\[gnuserv-edit]' to finish editing")) + (or dest-frame + (message (substitute-command-keys + "Type `\\[delete-frame]' to finish editing")))))))) -(defun server-temp-file-p (buffer) + +;;; Functions that hook into Emacs in various way to enable operation + +;; Defined later. +(add-hook 'kill-emacs-hook 'gnuserv-kill-all-clients t) + +;; A helper function; used by others. +(defun gnuserv-buffer-clients (buffer) + "Returns a list of clients to which BUFFER belongs." + (let ((client gnuserv-clients) + res) + (while client + (if (memq buffer (gnuclient-buffers (car client))) + (push (car client) res)) + (pop client)) + res)) + +;; This function makes sure that a killed buffer is deleted off the +;; list for the particular client. +;; +;; This hooks into `kill-buffer-hook'. It is *not* a replacement for +;; `kill-buffer' (thanks God). +(defun gnuserv-kill-buffer-function () + "Remove the buffer from the buffer lists of all the clients it belongs to. +Any client that remains \"empty\" after the removal is informed that the +editing has ended." + (let* ((buf (current-buffer)) + (clients (gnuserv-buffer-clients buf))) + (while clients + (callf2 delq buf (gnuclient-buffers (car clients))) + ;; If no more buffers, kill the client. + (when (null (gnuclient-buffers (car clients))) + (gnuserv-kill-client (car clients))) + (pop clients)))) + +(add-hook 'kill-buffer-hook 'gnuserv-kill-buffer-function) + +;; Ask for confirmation before killing a buffer that belongs to a +;; living client. +(defun gnuserv-kill-buffer-query-function () + (or gnuserv-kill-quietly + (not (gnuserv-buffer-clients (current-buffer))) + (yes-or-no-p + (format "Buffer %s belongs to gnuserv client(s); kill anyway? " + (current-buffer))))) + +(add-hook 'kill-buffer-query-functions + 'gnuserv-kill-buffer-query-function) + +(defun gnuserv-kill-emacs-query-function () + (or gnuserv-kill-quietly + (not (some 'gnuclient-buffers gnuserv-clients)) + (yes-or-no-p "Gnuserv buffers still have clients; exit anyway? "))) + +(add-hook 'kill-emacs-query-functions + 'gnuserv-kill-emacs-query-function) + +;; If the device of a client is to be deleted, the client should die +;; as well. This is why we hook into `delete-device-hook'. +(defun gnuserv-check-device (device) + (when (memq device gnuserv-devices) + (let ((client gnuserv-clients)) + (while client + (when (eq device (gnuclient-device (car client))) + ;; we must make sure that the server kill doesn't result in + ;; killing the device, because it would cause a device-dead + ;; error when `delete-device' tries to do the job later. + (gnuserv-kill-client (car client) t)) + (pop client))) + (callf2 delq device gnuserv-devices))) + +(add-hook 'delete-device-hook 'gnuserv-check-device) + +(defun gnuserv-temp-file-p (buffer) "Return non-nil if BUFFER contains a file considered temporary. These are files whose names suggest they are repeatedly reused to pass information to another program. -The variable `server-temp-file-regexp' controls which filenames +The variable `gnuserv-temp-file-regexp' controls which filenames are considered temporary." (and (buffer-file-name buffer) - (string-match server-temp-file-regexp (buffer-file-name buffer)))) - - -(defun server-log (string) - "If a *server* buffer exists, write STRING to it for logging purposes." - (if (get-buffer "*server*") - (save-excursion - (set-buffer "*server*") - (goto-char (point-max)) - (insert string) - (or (bolp) (newline))))) - + (string-match gnuserv-temp-file-regexp (buffer-file-name buffer)))) -(defun server-sentinel (proc msg) - (cond ((eq (process-status proc) 'exit) - (server-log (message "Server subprocess exited"))) - ((eq (process-status proc) 'signal) - (server-log (message "Server subprocess killed"))))) - +(defun gnuserv-kill-client (client &optional leave-frame) + "Kill the gnuclient CLIENT. +This will do away with all the associated buffers. If LEAVE-FRAME, +the function will not remove the frames associated with the client." + ;; Order is important: first delete client from gnuserv-clients, to + ;; prevent gnuserv-buffer-done-1 calling us recursively. + (callf2 delq client gnuserv-clients) + ;; Process the buffers. + (mapc 'gnuserv-buffer-done-1 (gnuclient-buffers client)) + (unless leave-frame + (let ((device (gnuclient-device client))) + ;; kill frame created by this client (if any), unless + ;; specifically requested otherwise. + ;; + ;; note: last frame on a device will not be deleted here. + (when (and (gnuclient-frame client) + (frame-live-p (gnuclient-frame client)) + (second (device-frame-list device))) + (delete-frame (gnuclient-frame client))) + ;; If the device is live, created by a client, and no longer used + ;; by any client, delete it. + (when (and (device-live-p device) + (memq device gnuserv-devices) + (second (device-list)) + (not (member* device gnuserv-clients + :key 'gnuclient-device))) + ;; `gnuserv-check-device' will remove it from `gnuserv-devices'. + (delete-device device)))) + ;; Notify the client. + (gnuserv-write-to-client (gnuclient-id client) nil)) -(defun server-process-display-error (string) - "Whenever a gnuserv error is reported, display it in a pop-up window." - (let ((cur (selected-window)) - (pop-up-windows t)) - (pop-to-buffer (get-buffer-create "*server*")) - (set-window-start (selected-window) (point)) - (server-log string) - (select-window cur))) +;; Do away with the buffer. +(defun gnuserv-buffer-done-1 (buffer) + (let ((clients (gnuserv-buffer-clients buffer))) + (while clients + (callf2 delq buffer (gnuclient-buffers (car clients))) + (when (null (gnuclient-buffers (car clients))) + (gnuserv-kill-client (car clients))) + (pop clients)) + ;; Get rid of the buffer + (save-excursion + (set-buffer buffer) + (run-hooks 'gnuserv-done-hook) + (setq gnuserv-minor-mode nil) + (funcall (if (gnuserv-temp-file-p buffer) + gnuserv-done-temp-file-function + gnuserv-done-function) + buffer)))) + +;;; Higher-level functions -(defun server-process-filter (proc string) - "Process client gnuserv requests to execute Emacs commands." - (setq server-string (concat server-string string)) - (if (string-match "\^D$" server-string) ; requests end with ctrl-D - (if (string-match "^[0-9]+" server-string) ; client request id - (progn - (server-log server-string) - (let ((header (read-from-string server-string))) - (setq current-client (car header)) - (condition-case oops - (eval (car (read-from-string server-string - (cdr header)))) - (error (setq server-string "") - (server-write-to-client current-client oops) - (setq current-client nil) - (signal (car oops) (cdr oops))) - (quit (setq server-string "") - (server-write-to-client current-client oops) - (setq current-client nil) - (signal 'quit nil))) - (setq server-string ""))) - (progn ;error string from server - (server-process-display-error server-string) - (setq server-string ""))))) +;; Choose a `next' server buffer, according to several criteria, and +;; return it. If none appropriate are found, return nil. +(defun gnuserv-next-buffer () + (let* ((frame (selected-frame)) + (device (selected-device)) + client) + (cond + ;; If we have a client belonging to this frame, return + ;; the first buffer from it. + ((setq client + (car (member* frame gnuserv-clients :key 'gnuclient-frame))) + (car (gnuclient-buffers client))) + ;; Else, look for a device. + ((and + (memq (selected-device) gnuserv-devices) + (setq client + (car (member* device gnuserv-clients :key 'gnuclient-device)))) + (car (gnuclient-buffers client))) + ;; Else, try to find just any client, and return its first buffer. + (gnuserv-clients + (car (gnuclient-buffers (car gnuserv-clients)))) + ;; Oh, give up. + (t nil)))) +(defun gnuserv-buffer-done (buffer) + "Mark BUFFER as \"done\" for its client(s). +Calls `gnuserv-done-function' and returns another gnuserv buffer as a +suggestion for the new current buffer." + ;; Check whether this is the real thing. + (unless (gnuserv-buffer-clients buffer) + (error "%s does not belong to a gnuserv client" buffer)) + ;; Backup/ask query. + (if (gnuserv-temp-file-p buffer) + ;; For a temp file, save, and do NOT make a non-numeric backup + ;; Why does server.el explicitly back up temporary files? + (let ((version-control nil) + (buffer-backed-up (not gnuserv-make-temp-file-backup))) + (save-buffer)) + (if (and (buffer-modified-p) + (y-or-n-p (concat "Save file " buffer-file-name "? "))) + (save-buffer buffer))) + (gnuserv-buffer-done-1 buffer) + (gnuserv-next-buffer)) -(defun server-release-outstanding-buffers () - "Release all buffers that have clients waiting for them to be finished." - (interactive) - (while server-clients - (let ((buffer (nth 1 (car server-clients)))) ; for all buffers... - (server-buffer-done buffer)))) ; destructively modifies server-clients +;; Called by `gnuserv-start-1' to clean everything. Hooked into +;; `kill-emacs-hook', too. +(defun gnuserv-kill-all-clients () + "Kill all the gnuserv clients. Ruthlessly." + (mapc 'gnuserv-kill-client gnuserv-clients)) + +;; Actually start the process. Kills all the clients before-hand. +(defun gnuserv-start-1 (&optional leave-dead) + (gnuserv-kill-all-clients) + (when gnuserv-process + (set-process-sentinel gnuserv-process nil) + (condition-case () + (delete-process gnuserv-process) + (error nil))) + ;; If we already had a server, clear out associated status. + (unless leave-dead + (setq gnuserv-string "") + (setq gnuserv-current-client nil) + (let ((process-connection-type t)) + (setq gnuserv-process + (start-process "gnuserv" nil gnuserv-program))) + (set-process-sentinel gnuserv-process 'gnuserv-sentinel) + (set-process-filter gnuserv-process 'gnuserv-process-filter) + (process-kill-without-query gnuserv-process))) + + +;;; User-callable functions: ;;;###autoload (defun gnuserv-start (&optional leave-dead) "Allow this Emacs process to be a server for client processes. -This starts a server communications subprocess through which +This starts a gnuserv communications subprocess through which client \"editors\" (gnuclient and gnudoit) can send editing commands to -this Emacs job. See the gnuserv(1) manual page for more details. +this Emacs job. See the gnuserv(1) manual page for more details. Prefix arg means just kill any existing server communications subprocess." (interactive "P") ;; kill it dead! - (if server-process - (progn - (server-release-outstanding-buffers) - (set-process-sentinel server-process nil) - (condition-case () - (delete-process server-process) - (error nil)))) - ;; If we already had a server, clear out associated status. - (if leave-dead - nil - (if server-process - (server-log (message "Restarting server"))) - (setq server-string "") - (setq current-client nil) - (let ((process-connection-type t)) - (setq server-process - (start-process "server" nil server-program))) - (set-process-sentinel server-process 'server-sentinel) - (set-process-filter server-process 'server-process-filter) - (process-kill-without-query server-process))) - -;; make gnuserv-start an alias to server-start, for backward compatibility -(fset 'server-start (function gnuserv-start)) - -; Can gnuserv handle commands in close succesion? (See server.el line 283) JV -(defun server-write-to-client (client form) - "Write the given form to the given client via the server process." - (if (and client - (eq (process-status server-process) 'run)) - (let* ((result (format "%s" form)) - (s (format "%s/%d:%s\n" client (length result) result))) - (process-send-string server-process s) - (server-log s)))) - -(defun server-eval (form) - "Evaluate form and return result to client." - (server-write-to-client current-client (eval form)) - (setq current-client nil)) - - -(defun server-eval-quickly (form) - "Let client know that we've received the request, but eval the form -afterwards in order to not keep the client waiting." - (server-write-to-client current-client nil) - (setq current-client nil) - (eval form)) - -(defun server-make-window-visible () - "Try to make this window even more visible." - (cond - ;; XEmacs can (in theory) raise any kind of frame - ((fboundp 'raise-frame) - (raise-frame (selected-frame))) - ((not (and (boundp 'window-system) window-system)) - nil) - ((fboundp 'deiconify-screen) - (deiconify-screen (selected-screen)) - (raise-screen (selected-screen))) - ((fboundp 'mapraised-screen) - (mapraised-screen)) - ((fboundp 'x-remap-window) - (x-remap-window) - ;; give window chance to re-display text - (accept-process-output)))) - -(defun server-tty-find-file (tty termtype pid file) - (let ((device (make-tty-device tty termtype pid ))) - (select-frame (make-frame nil device)) - (if (not file) - (switch-to-buffer (get-buffer-create "*scratch*")) - (find-file file))) - (run-hooks 'server-visit-hook)) - -(defun server-find-file (file) - "Edit file FILENAME. -Switch to a buffer visiting file FILENAME, -creating one if none already exists." - (let ((obuf (get-file-buffer file)) - ;; XEmacs addition. - (force-dialog-box-use t)) - (if (and obuf (set-buffer obuf)) - (if (file-exists-p file) - (if (or (not (verify-visited-file-modtime obuf)) - (buffer-modified-p obuf)) - (revert-buffer t nil)) - (if (y-or-n-p - (concat "File no longer exists: " - file - ", write buffer to file? ")) - (write-file file)))) - (cond ((and window-system - gnuserv-frame (fboundp 'frame-live-p) ;; v19 & XEmacs 19.12+ - (frame-live-p gnuserv-frame)) - (select-frame gnuserv-frame) - (find-file file)) - - ((and window-system - gnuserv-frame (fboundp 'live-screen-p) ;; XEmacs 19.9+ - (live-screen-p gnuserv-frame)) - (select-screen gnuserv-frame) - (find-file file)) - - ((and window-system - (fboundp 'select-frame)) ;; v19 & XEmacs 19.12+ - (select-frame (make-frame)) - (find-file file)) + (and gnuserv-process + (not leave-dead) + (message "Restarting gnuserv")) + (gnuserv-start-1 leave-dead)) - ((and window-system - (fboundp 'select-screen) ;; XEmacs 19.10+ - (fboundp 'make-screen)) - (select-screen (make-screen)) - (find-file file)) - - ((and (eq window-system 'x) ;; XEmacs 19.9- - (fboundp 'select-screen) - (fboundp 'x-create-screen)) - (select-screen (x-create-screen nil)) - (find-file file)) - - ((and window-system - (fboundp 'create-screen)) ;; epoch - (if (screenp gnuserv-frame) - (progn (select-screen gnuserv-frame) - (find-file file)) - (select-screen (create-screen (find-file-noselect file))))) - - (t (find-file file)))) ;; emacs18+ - (run-hooks 'server-visit-hook)) - - -(defun server-edit-files-quickly (list) - "For each (line-number . file) pair in LIST, edit the file at line-number. -Unlike (server-edit-files), no information is saved about clients waiting on -edits to this buffer." - (server-write-to-client current-client nil) - (setq current-client nil) - (while list - (let ((line (car (car list))) - (path (cdr (car list)))) - (server-find-file path) - (server-make-window-visible) - (goto-line line)) - (setq list (cdr list)))) - +;;;###autoload +(defun gnuserv-edit (&optional arg) + "Mark the current gnuserv editing buffer as \"done\", and switch to next one. -(defun server-edit-files (list) - "For each (line-number . file) pair in LIST, edit the file at line-number. -Save enough information for (server-kill-buffer) to inform the client when -the edit is finished." - (while list - (let ((line (car (car list))) - (path (cdr (car list)))) - (server-find-file path) - (server-make-window-visible) - (let ((old-clients (assq current-client server-clients)) - (buffer (current-buffer))) - (goto-line line) - (setq server-buffer-clients - (cons current-client server-buffer-clients)) - (if old-clients ;client already waiting for buffers? - (nconc old-clients (list buffer)) ;yes -- append this one as well - (setq server-clients ;nope -- make a new record - (cons (list current-client buffer) - server-clients))))) - (setq list (cdr list))) - (message (substitute-command-keys - (if (and (boundp 'infodock-version) window-system) - "Type {\\[server-edit]} or select Frame/Delete to finish edit." - "When done with a buffer, type \\[server-edit].")))) - -(defun server-tty-edit-files (tty termtype pid list) - "For each (line-number . file) pair in LIST, edit the file at line-number. -Save enough information for (server-kill-buffer) to inform the client when -the edit is finished." - (or list (setq list '((1 . nil)))) - (while list - (let ((line (car (car list))) - (path (cdr (car list)))) - (server-tty-find-file tty termtype pid path) - (server-make-window-visible) - (let ((old-clients (assq current-client server-clients)) - (buffer (current-buffer))) - (goto-line line) - (setq server-buffer-clients - (cons current-client server-buffer-clients)) - (if old-clients ;client already waiting for buffers? - (nconc old-clients (list buffer)) ;yes -- append this one as well - (setq server-clients ;nope -- make a new record - (cons (list current-client buffer) - server-clients))))) - (setq list (cdr list))) - (message (substitute-command-keys - (if (and (boundp 'infodock-version) window-system) - "Type {\\[server-edit]} or select Frame/Delete to finish edit." - "When done with a buffer, type \\[server-edit].")))) - -(defun server-get-buffer (buffer) - "One arg, a BUFFER or a buffer name. Return the buffer object even if killed. -Signal an error if there is no record of BUFFER." - (if (null buffer) - (current-buffer) - (let ((buf (get-buffer buffer))) - (if (null buf) - (if (bufferp buffer) - buffer - (if (stringp buffer) - (error "No buffer named %s" buffer) - (error "Invalid buffer argument"))) - buf)))) - -(defun server-kill-buffer (buffer) - "Kill the BUFFER. The argument may be a buffer object or buffer name. -NOTE: This function has been enhanced to allow for remote editing -in the following way: +The `gnuserv-done-function' is used to dispose of the buffer after marking it +as done; it is `kill-buffer' by default. -If the buffer is waited upon by one or more clients, and a client is -not waiting for other buffers to be killed, then the client is told -that the buffer has been killed." - (interactive "bKill buffer ") - (setq buffer (server-get-buffer buffer)) - (if (buffer-name buffer) - (save-excursion - (set-buffer buffer) - (let ((old-clients server-clients)) - (server-real-kill-buffer buffer) ;try to kill it - (if (buffer-name buffer) ;succeeded in killing? - nil ;nope - (while old-clients - (let ((client (car old-clients))) - (delq buffer client) - (if (cdr client) ;pending buffers? - nil ;yep - (server-write-to-client (car client) nil) ;nope, tell client - (setq server-clients (delq client server-clients)))) - (setq old-clients (cdr old-clients))) - t))))) - - -;; Ask before killing a server buffer. -;; It was suggested to release its client instead, -;; but I think that is dangerous--the client would proceed -;; using whatever is on disk in that file. -- rms. -(defun server-kill-buffer-query-function () - (or server-kill-quietly - (not server-buffer-clients) - (yes-or-no-p (format "Buffer `%s' still has clients; kill it? " - (buffer-name (current-buffer)))))) - -(add-hook 'kill-buffer-query-functions - 'server-kill-buffer-query-function) - -(defun server-kill-emacs-query-function () - (let (live-client - (tail server-clients)) - ;; See if any clients have any buffers that are still alive. - (while tail - (if (memq t (mapcar 'stringp (mapcar 'buffer-name (cdr (car tail))))) - (setq live-client t)) - (setq tail (cdr tail))) - (or server-kill-quietly - (not live-client) - (yes-or-no-p "Server buffers still have clients; exit anyway? ")))) - -(add-hook 'kill-emacs-query-functions 'server-kill-emacs-query-function) - +Files that match `gnuserv-temp-file-regexp' are considered temporary and +are saved unconditionally and backed up if `gnuserv-make-temp-file-backup' +is non-nil. They are disposed of using `gnuserv-done-temp-file-function'. -(defun server-kill-all-local-variables () - "Eliminate all the buffer-local variable values of the current buffer. -This buffer will then see the default values of all variables. -NOTE: This function has been modified to ignore the variable -server-buffer-clients." - (let ((clients server-buffer-clients)) - (server-real-kill-all-local-variables) - (if clients - (setq server-buffer-clients clients)))) - - -(or (fboundp 'server-real-kill-buffer) - (fset 'server-real-kill-buffer (symbol-function 'kill-buffer))) - -(fset 'kill-buffer 'server-kill-buffer) - -(or (fboundp 'server-real-kill-all-local-variables) - (fset 'server-real-kill-all-local-variables - (symbol-function 'kill-all-local-variables))) - -(fset 'kill-all-local-variables 'server-kill-all-local-variables) - - -(defun server-buffer-done (buffer) - "Mark BUFFER as \"done\" for its client(s). -Buries the buffer, and returns another server buffer as a suggestion for the -new current buffer." - ; Note we do NOT return a list with a killed flag, doesn't seem usefull to me. JV - (let ((next-buffer nil) - (old-clients server-clients)) - (while old-clients - (let ((client (car old-clients))) - (or next-buffer - (setq next-buffer (nth 1 (memq buffer client)))) - (delq buffer client) - ;; Delete all dead buffers from CLIENT. (Why? JV , copyed from server.el) - (let ((tail client)) - (while tail - (and (bufferp (car tail)) - (null (buffer-name (car tail))) - (delq (car tail) client)) - (setq tail (cdr tail)))) - ;; If client now has no pending buffers, - ;; tell it that it is done, and forget it entirely. - (if (cdr client) - nil - (if (buffer-name buffer) - (save-excursion - (set-buffer buffer) - (setq server-buffer-clients nil) - (run-hooks 'server-done-hook))) - ; Order is important here -- - ; server-kill-buffer tries to notify clients that - ; they are done, too, but if we try and notify twice, - ; we are h0zed -- Hunter Kelly 3/3/97 - (setq server-clients (delq client server-clients)) - (if (server-temp-file-p buffer) - (funcall server-done-temp-file-function buffer) - (funcall server-done-function buffer)) - (server-write-to-client (car client) nil))) - (setq old-clients (cdr old-clients))) - next-buffer)) +When all of a client's buffers are marked as \"done\", the client is notified. - -(defun mh-draft-p (buffer) - "Return non-nil if this BUFFER is an mh <draft> file. Since MH deletes -draft *BEFORE* it is edited, the server treats them specially." - ;; This may not be appropriately robust for all cases. - (string= (buffer-name buffer) "draft")) - - -(defun server-done () - "Offer to save current buffer and mark it as \"done\" for clients. -Also bury it, and return a suggested new current buffer." - (let ((buffer (current-buffer))) - (if server-buffer-clients - (progn - (if (mh-draft-p buffer);; Does this comflict with temp-file ? JV - (progn (save-buffer) - (write-region (point-min) (point-max) - (concat buffer-file-name "~")) - (kill-buffer buffer)) - (if (server-temp-file-p buffer) - ;; For a temp file, save, and do NOT make a non-numeric backup - ;; Why does server.el explicitly back up temporary files? - (let ((version-control nil) - (buffer-backed-up (not server-make-temp-file-backup))) - (save-buffer)) - (if (and (buffer-modified-p) - (y-or-n-p (concat "Save file " buffer-file-name "? "))) - (save-buffer buffer)))) - (server-buffer-done buffer))))) - - -(defun server-edit (&optional arg) - "Switch to next server editing -buffer and mark current one as \"done\". If a server buffer is -current, it is marked \"done\" and optionally saved. MH <draft> files -are always saved and backed up, no questions asked. Files that match -server-temp-file-regexp are considered temporary and are saved -unconditionally and -backed up if server-make-temp-file-backup is non-nil. When all of a -client's buffers are marked as \"done\", the client is notified. - -If invoked with a prefix argument, or if there is no server process running, -starts server process and that is all. Invoked by \\[server-edit]. - -If `server-kill-last-frame' is t, then the final frame will be killed." +If invoked with a prefix argument, or if there is no gnuserv process +running, only starts server process. Invoked with \\[gnuserv-edit]." (interactive "P") - (if (or arg - (not server-process) - (memq (process-status server-process) '(signal exit))) - (server-start nil) - (if server-buffer-clients - (progn (server-done-and-switch) - (cond ((fboundp 'console-type) ;; XEmacs 19.14+ - (or (and (equal (console-type) 'x) - gnuserv-frame - (frame-live-p gnuserv-frame)) - (condition-case () - (delete-frame (selected-frame) - server-kill-last-frame) - (error - (message "Not deleting last visible frame..."))))) - ((or (not window-system) - (and gnuserv-frame - (or (and (fboundp 'frame-live-p) - (frame-live-p gnuserv-frame)) - (and (fboundp 'live-screen-p) - (live-screen-p gnuserv-frame)) - (and (fboundp 'create-screen) - (screenp gnuserv-frame))))) - ()) ;; do nothing - ((fboundp 'delete-frame) - (delete-frame (selected-frame) t)) - ((fboundp 'delete-screen) - (delete-screen)))) - (error - "(server-edit): Use only on buffers created by external programs.") - ))) + (if (or arg (not gnuserv-process) + (memq (process-status gnuserv-process) '(signal exit))) + (gnuserv-start) + (switch-to-buffer (or (gnuserv-buffer-done (current-buffer)) + (current-buffer))))) -(defun server-switch-buffer-internal (next-buffer always) - "Switch to NEXT-BUFFER if a live buffer, otherwise switch to another buffer -with gnuserv clients. If no such buffer is available, we switch to -another normal buffer if `always' is non-nil!" - ;; switching - (if next-buffer - (if (and (bufferp next-buffer) - (buffer-name next-buffer)) - (switch-to-buffer next-buffer) - ;; If NEXT-BUFFER is a dead buffer, - ;; remove the server records for it - ;; and try the next surviving server buffer. - (server-switch-buffer-internal - (server-buffer-done next-buffer) always)) - (if server-clients - (server-switch-buffer-internal (nth 1 (car server-clients)) always) - (if always - (switch-to-buffer (other-buffer)))))) - -;; For compatability -(defun server-switch-buffer (next-buffer) - (server-switch-buffer-internal next-buffer t)) - -;; The below function calles server-done and switches to the next -;; sensible buffer. This implementation works regardless of the values -;; of server-*-function and doens't need the tail recursion -;; variable passing of server.el. It is more transparant too. JV -(defun server-done-and-switch () - "Be done with the current buffer and switch to another server buffer - if there is one, otherwise just switch buffer" - (let ((old-current (current-buffer))) - (server-switch-buffer-internal (server-done) nil) - (if (eq old-current (current-buffer)) - (switch-to-buffer (other-buffer))))) - -(global-set-key "\C-x#" 'server-edit) +;;;###autoload +(global-set-key "\C-x#" 'gnuserv-edit) (provide 'gnuserv)
--- a/lisp/packages/info.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/info.el Mon Aug 13 09:36:16 2007 +0200 @@ -422,6 +422,11 @@ :type '(repeat file) :group 'info) +(defcustom Info-button1-follows-hyperlink nil + "*Non-nil means mouse button1 click will follow hyperlink." + :type 'boolean + :group 'info) + (defvar Info-standalone nil "Non-nil if Emacs was started solely as an Info browser.") @@ -1945,7 +1950,8 @@ Like M, F, N, P or U command. At end of the node's text, moves to the next node. No error is given if there is no node to follow." (interactive "@e") - (and (event-point event) + (and Info-button1-follows-hyperlink + (event-point event) (Info-follow-nearest-node (max (progn (select-window (event-window event))
--- a/lisp/packages/man.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/man.el Mon Aug 13 09:36:16 2007 +0200 @@ -243,7 +243,7 @@ (substring args-string (match-end 0)))) (message "%s (running...)" args-string) - (apply 'call-process Manual-program nil t nil args) + (apply 'call-process Manual-program nil '(t nil) nil args) (if (< (buffer-size) 200) (progn
--- a/lisp/packages/metamail.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/metamail.el Mon Aug 13 09:36:16 2007 +0200 @@ -3,7 +3,7 @@ ;; Copyright (C) 1993, 1996 Masanobu UMEDA ;; Author: Masanobu UMEDA <umerin@mse.kyutech.ac.jp> -;; Version: $Header: /afs/informatik.uni-tuebingen.de/local/web/xemacs/xemacs-cvs/XEmacs/xemacs/lisp/packages/Attic/metamail.el,v 1.3 1997/03/16 03:05:29 steve Exp $ +;; Version: $Header: /afs/informatik.uni-tuebingen.de/local/web/xemacs/xemacs-cvs/XEmacs/xemacs/lisp/packages/Attic/metamail.el,v 1.4 1997/05/18 03:40:08 steve Exp $ ;; Keywords: mail, news, mime, multimedia ;; This file is part of XEmacs. @@ -53,11 +53,21 @@ ;;; Code: -(defvar metamail-program-name "metamail" - "*Metamail program name.") +(defgroup metamail nil + "Metamail interface for Emacs." + :group 'mail + :group 'hypermedia + :group 'processes) -(defvar metamail-mailer-name "emacs" - "*Mailer name set to MM_MAILER environment variable.") +(defcustom metamail-program-name "metamail" + "*Metamail program name." + :type 'string + :group 'metamail) + +(defcustom metamail-mailer-name "emacs" + "*Mailer name set to MM_MAILER environment variable." + :type 'string + :group 'metamail) (defvar metamail-environment '("KEYHEADS=*" "MM_QUIET=1") "*Environment variables passed to `metamail'. @@ -65,13 +75,15 @@ It is not expected to be altered globally by `set' or `setq'. Instead, change its value temporary using `let' or `let*' form.") -(defvar metamail-switches '("-x" "-d" "-z") +(defcustom metamail-switches '("-x" "-d" "-z") "*Switches for `metamail' program. `-z' is required to remove zap file. It is not expected to be altered globally by `set' or `setq'. Instead, change its value temporary using `let' or `let*' form. `-m MAILER' argument is automatically generated from the -`metamail-mailer-name' variable.") +`metamail-mailer-name' variable." + :type '(repeat (string :tag "Switch")) + :group 'metamail) ;;;###autoload (defun metamail-interpret-header ()
--- a/lisp/packages/tar-mode.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/tar-mode.el Mon Aug 13 09:36:16 2007 +0200 @@ -3,7 +3,7 @@ ;;; File: tar-mode.el ;;; Description: simple editing of tar files from GNU emacs -;;; Author: Jamie Zawinski <jwz@lucid.com> +;;; Author: Jamie Zawinski <jwz@netscape.com> ;;; Created: 4 Apr 1990 ;;; Version: 1.31, 15 Dec 93
--- a/lisp/packages/vc-hooks.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/packages/vc-hooks.el Mon Aug 13 09:36:16 2007 +0200 @@ -458,7 +458,7 @@ ;; #### - sync with fsf menus (defconst vc-menu - '("VC" + '("Version Control" :filter vc-menu-filter ["" vc-next-action buffer-file-name nil] ;; ^^^ this gets changed to checkin, checkout, register, or steal
--- a/lisp/prim/auto-autoloads.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/prim/auto-autoloads.el Mon Aug 13 09:36:16 2007 +0200 @@ -711,11 +711,38 @@ ;;;*** -;;;### (autoloads (customize-menu-create custom-menu-create custom-save-all custom-buffer-create customize-apropos customize-customized customize-face-other-window customize-face customize-variable-other-window customize-variable customize) "cus-edit" "custom/cus-edit.el") +;;;### (autoloads (customize-menu-create custom-menu-create custom-save-all custom-save-customized custom-buffer-create-other-window custom-buffer-create customize-apropos customize-saved customize-customized customize-face-other-window customize-face customize-variable-other-window customize-variable customize-other-window customize custom-set-variable custom-set-value) "cus-edit" "custom/cus-edit.el") + +(autoload 'custom-set-value "cus-edit" "\ +Set VARIABLE to VALUE. VALUE is a Lisp object. + +If VARIABLE has a `variable-interactive' property, that is used as if +it were the arg to `interactive' (which see) to interactively read the value. + +If VARIABLE has a `custom-type' property, it must be a widget and the +`:prompt-value' property of that widget will be used for reading the value." t nil) + +(autoload 'custom-set-variable "cus-edit" "\ +Set the default for VARIABLE to VALUE. VALUE is a Lisp object. + +If VARIABLE has a `custom-set' property, that is used for setting +VARIABLE, otherwise `set-default' is used. + +The `customized-value' property of the VARIABLE will be set to a list +with a quoted VALUE as its sole list member. + +If VARIABLE has a `variable-interactive' property, that is used as if +it were the arg to `interactive' (which see) to interactively read the value. + +If VARIABLE has a `custom-type' property, it must be a widget and the +`:prompt-value' property of that widget will be used for reading the value. " t nil) (autoload 'customize "cus-edit" "\ Customize SYMBOL, which must be a customization group." t nil) +(autoload 'customize-other-window "cus-edit" "\ +Customize SYMBOL, which must be a customization group." t nil) + (autoload 'customize-variable "cus-edit" "\ Customize SYMBOL, which must be a variable." t nil) @@ -731,7 +758,10 @@ Show customization buffer for FACE in other window." t nil) (autoload 'customize-customized "cus-edit" "\ -Customize all already customized user options." t nil) +Customize all user options set since the last save in this session." t nil) + +(autoload 'customize-saved "cus-edit" "\ +Customize all already saved user options." t nil) (autoload 'customize-apropos "cus-edit" "\ Customize all user options matching REGEXP. @@ -740,10 +770,21 @@ (autoload 'custom-buffer-create "cus-edit" "\ Create a buffer containing OPTIONS. +Optional NAME is the name of the buffer. OPTIONS should be an alist of the form ((SYMBOL WIDGET)...), where SYMBOL is a customization option, and WIDGET is a widget for editing that option." nil nil) +(autoload 'custom-buffer-create-other-window "cus-edit" "\ +Create a buffer containing OPTIONS. +Optional NAME is the name of the buffer. +OPTIONS should be an alist of the form ((SYMBOL WIDGET)...), where +SYMBOL is a customization option, and WIDGET is a widget for editing +that option." nil nil) + +(autoload 'custom-save-customized "cus-edit" "\ +Save all user options which have been set in this session." t nil) + (autoload 'custom-save-all "cus-edit" "\ Save all customizations in `custom-file'." nil nil) @@ -781,7 +822,7 @@ ;;;*** -;;;### (autoloads (widget-browse-other-window widget-browse widget-browse-at) "wid-browse" "custom/wid-browse.el") +;;;### (autoloads (widget-minor-mode widget-browse-other-window widget-browse widget-browse-at) "wid-browse" "custom/wid-browse.el") (autoload 'widget-browse-at "wid-browse" "\ Browse the widget under point." t nil) @@ -792,14 +833,22 @@ (autoload 'widget-browse-other-window "wid-browse" "\ Show widget browser for WIDGET in other window." t nil) -;;;*** - -;;;### (autoloads (widget-delete widget-create widget-apply) "wid-edit" "custom/wid-edit.el") +(autoload 'widget-minor-mode "wid-browse" "\ +Togle minor mode for traversing widgets. +With arg, turn widget mode on if and only if arg is positive." t nil) + +;;;*** + +;;;### (autoloads (widget-delete widget-create widget-prompt-value widget-apply) "wid-edit" "custom/wid-edit.el") (autoload 'widget-apply "wid-edit" "\ Apply the value of WIDGET's PROPERTY to the widget itself. ARGS are passed as extra arguments to the function." nil nil) +(autoload 'widget-prompt-value "wid-edit" "\ +Prompt for a value matching WIDGET, using PROMPT. +The current value is assumed to be VALUE, unless UNBOUND is non-nil." nil nil) + (autoload 'widget-create "wid-edit" "\ Create widget of TYPE. The optional ARGS are additional keyword arguments." nil nil) @@ -2987,6 +3036,15 @@ ;;;*** +;;;### (autoloads (autoconf-mode) "autoconf-mode" "modes/autoconf-mode.el") + +(autoload 'autoconf-mode "autoconf-mode" "\ +A major-mode to edit autoconf input files like configure.in +\\{autoconf-mode-map} +" t nil) + +;;;*** + ;;;### (autoloads (awk-mode) "awk-mode" "modes/awk-mode.el") (autoload 'awk-mode "awk-mode" "\ @@ -3631,7 +3689,7 @@ ;;;### (autoloads (ksh-mode) "ksh-mode" "modes/ksh-mode.el") (autoload 'ksh-mode "ksh-mode" "\ -ksh-mode $Revision: 1.27 $ - Major mode for editing (Bourne, Korn or Bourne again) +ksh-mode $Revision: 1.28 $ - Major mode for editing (Bourne, Korn or Bourne again) shell scripts. Special key bindings and commands: \\{ksh-mode-map} @@ -3742,15 +3800,6 @@ ;;;*** -;;;### (autoloads (m4-mode) "m4-mode" "modes/m4-mode.el") - -(autoload 'm4-mode "m4-mode" "\ -A major-mode to edit m4 macro files -\\{m4-mode-map} -" t nil) - -;;;*** - ;;;### (autoloads (define-mail-alias build-mail-aliases mail-aliases-setup) "mail-abbrevs" "modes/mail-abbrevs.el") (defcustom mail-abbrev-mailrc-file nil "Name of file with mail aliases. If nil, ~/.mailrc is used." :type '(choice (const :tag "Default" nil) file) :group 'mail-abbrevs) @@ -4991,7 +5040,7 @@ (autoload 'vhdl-mode "vhdl-mode" "\ Major mode for editing VHDL code. -vhdl-mode $Revision: 1.27 $ +vhdl-mode $Revision: 1.28 $ To submit a problem report, enter `\\[vhdl-submit-bug-report]' from a vhdl-mode buffer. This automatically sets up a mail buffer with version information already added. You just need to add a description of the @@ -6337,21 +6386,35 @@ ;;;*** -;;;### (autoloads (gnuserv-start) "gnuserv" "packages/gnuserv.el") - -(defvar gnuserv-frame nil "\ -*If non-nil, the frame to be used to display all edited files. -If nil, then a new frame is created for each file edited. -This variable has no effect in XEmacs versions older than 19.9.") +;;;### (autoloads (gnuserv-edit gnuserv-start) "gnuserv" "packages/gnuserv.el") + +(defcustom gnuserv-frame nil "*The frame to be used to display all edited files.\nIf nil, then a new frame is created for each file edited.\nIf t, then the currently selected frame will be used.\nIf a function, then this will be called with a symbol `x' or `tty' as the\nonly argument, and its return value will be interpreted as above." :tag "Gnuserv Frame" :type '(radio (const :tag "Create new frame each time" nil) (const :tag "Use selected frame" t) (function-item :tag "Use main Emacs frame" gnuserv-main-frame-function) (function-item :tag "Use visible frame, otherwise create new" gnuserv-visible-frame-function) (function-item :tag "Create special Gnuserv frame and use it" gnuserv-special-frame-function) (function :tag "Other")) :group 'gnuserv) (autoload 'gnuserv-start "gnuserv" "\ Allow this Emacs process to be a server for client processes. -This starts a server communications subprocess through which +This starts a gnuserv communications subprocess through which client \"editors\" (gnuclient and gnudoit) can send editing commands to -this Emacs job. See the gnuserv(1) manual page for more details. +this Emacs job. See the gnuserv(1) manual page for more details. Prefix arg means just kill any existing server communications subprocess." t nil) +(autoload 'gnuserv-edit "gnuserv" "\ +Mark the current gnuserv editing buffer as \"done\", and switch to next one. + +The `gnuserv-done-function' is used to dispose of the buffer after marking it +as done; it is `kill-buffer' by default. + +Files that match `gnuserv-temp-file-regexp' are considered temporary and +are saved unconditionally and backed up if `gnuserv-make-temp-file-backup' +is non-nil. They are disposed of using `gnuserv-done-temp-file-function'. + +When all of a client's buffers are marked as \"done\", the client is notified. + +If invoked with a prefix argument, or if there is no gnuserv process +running, only starts server process. Invoked with \\[gnuserv-edit]." t nil) + +(global-set-key "#" 'gnuserv-edit) + ;;;*** ;;;### (autoloads (gopher-atpoint gopher) "gopher" "packages/gopher.el") @@ -8994,6 +9057,17 @@ ;;;*** +;;;### (autoloads (unhide-copyleft-region hide-copyleft-region) "hide-copyleft" "utils/hide-copyleft.el") + +(autoload 'hide-copyleft-region "hide-copyleft" "\ +Make the legal drivel at the front of this file invisible. Unhide it again +with C-u \\[hide-copyleft-region]." t nil) + +(autoload 'unhide-copyleft-region "hide-copyleft" "\ +If the legal nonsense at the top of this file is elided, make it visible again." nil nil) + +;;;*** + ;;;### (autoloads (highlight-headers-follow-url highlight-headers-follow-url-mosaic highlight-headers-follow-url-netscape highlight-headers) "highlight-headers" "utils/highlight-headers.el") (autoload 'highlight-headers "highlight-headers" "\
--- a/lisp/prim/console.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/prim/console.el Mon Aug 13 09:36:16 2007 +0200 @@ -1,7 +1,7 @@ ;;; console.el --- miscellaneous console functions not written in C -;;;; Copyright (C) 1994, 1995 Board of Trustees, University of Illinois -;;;; Copyright (C) 1995, 1996 Ben Wing +;; Copyright (C) 1994, 1995 Board of Trustees, University of Illinois +;; Copyright (C) 1995, 1996 Ben Wing ;; Keywords: internal @@ -24,6 +24,10 @@ ;;; Synched up with: Not in FSF. +;;; Commentary: + +;;; Code: + (defun quit-char (&optional console) "Return the character that causes a QUIT to happen. This is normally C-g. Optional arg CONSOLE specifies the console @@ -34,8 +38,10 @@ "Resume the consoles with a controlling process of PID." (mapc (lambda (c) (if (and (eq (console-type c) 'tty) - (= pid (console-tty-controlling-process c))) + (eq pid (console-tty-controlling-process c))) (resume-console c))) (console-list)) ; documentation for mapc lies! nil) + +;;; console.el ends here
--- a/lisp/prim/custom-load.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/prim/custom-load.el Mon Aug 13 09:36:16 2007 +0200 @@ -29,7 +29,7 @@ (put 'telnet 'custom-loads '("telnet")) (put 'widgets 'custom-loads '("wid-browse" "wid-edit")) (put 'minibuffer 'custom-loads '("minibuf" "detached-minibuf")) -(put 'environment 'custom-loads '("minibuf" "modeline" "x-toolbar" "cus-edit" "dired-faces" "sound")) +(put 'environment 'custom-loads '("minibuf" "modeline" "x-toolbar" "cus-edit" "dired-faces" "gnuserv" "sound")) (put 'shell 'custom-loads '("shell")) (put 'sound 'custom-loads '("sound")) (put 'gnus-article-buttons 'custom-loads '("gnus-art")) @@ -53,7 +53,7 @@ (put 'xrdb 'custom-loads '("xrdb-mode")) (put 'gnus-article-washing 'custom-loads '("gnus-xmas" "gnus-art")) (put 'ispell 'custom-loads '("ispell")) -(put 'mail 'custom-loads '("gnus" "message" "mh-e" "mail-abbrevs" "feedmail" "supercite" "highlight-headers" "smtpmail")) +(put 'mail 'custom-loads '("gnus" "message" "mh-e" "mail-abbrevs" "feedmail" "metamail" "supercite" "highlight-headers" "smtpmail")) (put 'gnus-summary-exit 'custom-loads '("gnus-sum")) (put 'fortran-indent 'custom-loads '("fortran")) (put 'ps-print-face 'custom-loads '("ps-print")) @@ -84,7 +84,7 @@ (put 'dabbrev 'custom-loads '("dabbrev")) (put 'help-appearance 'custom-loads '("help")) (put 'display-time 'custom-loads '("time")) -(put 'hypermedia 'custom-loads '("wid-edit" "gopher" "browse-url" "url-vars" "w3-cus")) +(put 'hypermedia 'custom-loads '("wid-edit" "gopher" "metamail" "browse-url" "url-vars" "w3-cus")) (put 'save-place 'custom-loads '("saveplace")) (put 'w3-advanced 'custom-loads '("w3-cus")) (put 'lisp 'custom-loads '("edebug" "cl-indent" "elp")) @@ -132,6 +132,7 @@ (put 'ps-print 'custom-loads '("ps-print")) (put 'cc-indent 'custom-loads '("cc-mode")) (put 'comm 'custom-loads '("ssl")) +(put 'ediff-window 'custom-loads '()) (put 'gnus 'custom-loads '("gnus-art" "gnus-async" "gnus-cache" "gnus-demon" "gnus-dup" "gnus-eform" "gnus-uu" "gnus-win" "gnus-xmas" "gnus" "nnmail")) (put 'ps-print-font 'custom-loads '("ps-print")) (put 'id-select 'custom-loads '("id-select")) @@ -144,7 +145,7 @@ (put 'psgml-html 'custom-loads '("psgml-html")) (put 'nnmail 'custom-loads '("nnmail")) (put 'gnus-article-hiding 'custom-loads '("gnus-art" "gnus-sum")) -(put 'customize 'custom-loads '("wid-edit" "cus-face" "cus-edit")) +(put 'customize 'custom-loads '("cus-face" "wid-edit" "cus-edit")) (put 'w3-printing 'custom-loads '("w3-cus")) (put 'nnmail-duplicate 'custom-loads '("nnmail")) (put 'verilog 'custom-loads '("verilog-mode")) @@ -157,12 +158,14 @@ (put 'abbrev 'custom-loads '("cus-edit" "dabbrev")) (put 'f90-indent 'custom-loads '("f90")) (put 'nnmail-retrieve 'custom-loads '("nnmail")) +(put 'ediff-ptch 'custom-loads '()) (put 'url-history 'custom-loads '("url-vars")) (put 'message-interface 'custom-loads '("message")) (put 'gnus-group 'custom-loads '("gnus-topic" "gnus")) (put 'remote-compile 'custom-loads '("rcompile")) (put 'programming 'custom-loads '("cus-edit" "compile")) (put 'gnus-article-signature 'custom-loads '("gnus-art")) +(put 'metamail 'custom-loads '("metamail")) (put 'toolbar 'custom-loads '("x-toolbar")) (put 'compilation 'custom-loads '("compile")) (put 'dired 'custom-loads '("dired-faces")) @@ -227,6 +230,7 @@ (put 'diary 'custom-loads '("calendar")) (put 'gnus-various 'custom-loads '("gnus-sum")) (put 'cc-syntax 'custom-loads '("cc-mode")) +(put 'smiley 'custom-loads '()) (put 'mh-compose 'custom-loads '("mh-comp")) (put 'xmine 'custom-loads '("xmine")) (put 'supercite-frames 'custom-loads '("supercite")) @@ -235,12 +239,13 @@ (put 'enriched 'custom-loads '("enriched")) (put 'gnus-article-highlight 'custom-loads '("gnus-art")) (put 'emacs 'custom-loads '("cus-edit")) -(put 'processes 'custom-loads '("background" "comint" "rlogin" "shell" "cus-edit" "executable" "gnuserv" "ispell" "rcompile" "passwd")) +(put 'processes 'custom-loads '("background" "comint" "rlogin" "shell" "cus-edit" "executable" "gnuserv" "ispell" "metamail" "rcompile" "passwd")) (put 'news 'custom-loads '("gnus" "message" "supercite" "highlight-headers")) (put 'rexx 'custom-loads '("rexx-mode")) (put 'w3-hooks 'custom-loads '("w3-cus")) (put 'executable 'custom-loads '("executable")) (put 'highlight-headers 'custom-loads '("highlight-headers")) +(put 'gnus-cache 'custom-loads '()) (put 'message-insertion 'custom-loads '("message")) (put 'hyper-apropos 'custom-loads '("hyper-apropos")) (put 'psgml-insert 'custom-loads '("psgml"))
--- a/lisp/prim/events.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/prim/events.el Mon Aug 13 09:36:16 2007 +0200 @@ -2,8 +2,8 @@ ;;;; Copyright (C) 1996 Ben Wing. -;; Maintainer: -;; Keywords: internal +;; Maintainer: Martin Buchholz +;; Keywords: internal event ;; This file is part of XEmacs. @@ -43,63 +43,68 @@ (fw-frame (event-channel event))) (defun event-buffer (event) - "Given a mouse-motion, button-press, or button-release event, return -the buffer on which that event occurred. This will be nil for non-mouse -events. If event-over-text-area-p is nil, this will also be nil." + "Return the buffer of the window over which mouse event EVENT occurred. +Return nil unless both (mouse-event-p EVENT) and +(event-over-text-area-p EVENT) are non-nil." (let ((window (event-window event))) (and (windowp window) (window-buffer window)))) (defalias 'allocate-event 'make-event) -(defun key-press-event-p (obj) - "True if OBJ is a key-press event object." - (and (event-live-p obj) (eq 'key-press (event-type obj)))) -(defun button-press-event-p (obj) - "True if OBJ is a mouse-button-press event object." - (and (event-live-p obj) (eq 'button-press (event-type obj)))) +(defun key-press-event-p (object) + "Return t if OBJECT is a key-press event." + (and (event-live-p object) (eq 'key-press (event-type object)))) + +(defun button-press-event-p (object) + "Return t if OBJECT is a mouse button-press event." + (and (event-live-p object) (eq 'button-press (event-type object)))) -(defun button-release-event-p (obj) - "True if OBJ is a mouse-button-release event object." - (and (event-live-p obj) (eq 'button-release (event-type obj)))) +(defun button-release-event-p (object) + "Return t if OBJECT is a mouse button-release event." + (and (event-live-p object) (eq 'button-release (event-type object)))) -(defun button-event-p (obj) - "True if OBJ is a button-press or button-release event object." - (or (button-press-event-p obj) (button-release-event-p obj))) +(defun button-event-p (object) + "Return t if OBJECT is a mouse button-press or button-release event." + (and (event-live-p object) + (memq (event-type object) '(button-press button-release)) + t)) -(defun motion-event-p (obj) - "True if OBJ is a mouse-motion event object." - (and (event-live-p obj) (eq 'motion (event-type obj)))) +(defun motion-event-p (object) + "Return t if OBJECT is a mouse motion event." + (and (event-live-p object) (eq 'motion (event-type object)))) -(defun mouse-event-p (obj) - "True if OBJ is a button-press, button-release, or mouse-motion event object." - (or (button-event-p obj) (motion-event-p obj))) +(defun mouse-event-p (object) + "Return t if OBJECT is a mouse button-press, button-release or motion event." + (and (event-live-p object) + (memq (event-type object) '(button-press button-release motion)) + t)) -(defun process-event-p (obj) - "True if OBJ is a process-output event object." - (and (event-live-p obj) (eq 'process (event-type obj)))) +(defun process-event-p (object) + "Return t if OBJECT is a process-output event." + (and (event-live-p object) (eq 'process (event-type object)))) -(defun timeout-event-p (obj) - "True if OBJ is a timeout event object." - (and (event-live-p obj) (eq 'timeout (event-type obj)))) +(defun timeout-event-p (object) + "Return t if OBJECT is a timeout event." + (and (event-live-p object) (eq 'timeout (event-type object)))) -(defun eval-event-p (obj) - "True if OBJ is an eval event object." - (and (event-live-p obj) (eq 'eval (event-type obj)))) +(defun eval-event-p (object) + "Return t if OBJECT is an eval event." + (and (event-live-p object) (eq 'eval (event-type object)))) -(defun misc-user-event-p (obj) - "True if OBJ is a misc-user event object. +(defun misc-user-event-p (object) + "Return t if OBJECT is a misc-user event. A misc-user event is a user event that is not a keypress or mouse click; normally this means a menu selection or scrollbar action." - (and (event-live-p obj) (eq 'misc-user (event-type obj)))) + (and (event-live-p object) (eq 'misc-user (event-type object)))) ;; You could just as easily use event-glyph but we include this for ;; consistency. -(defun event-over-glyph-p (event) - "Given a mouse-motion, button-press, or button-release event, return -t if the event is over a glyph. Otherwise, return nil." - (not (null (event-glyph event)))) +(defun event-over-glyph-p (object) + "Return t if OBJECT is a mouse event occurring over a glyph. +Mouse events are events of type button-press, button-release or motion." + (and (event-live-p object) (event-glyph object) t)) (defun keyboard-translate (&rest pairs) "Translate character or keysym FROM to TO at a low level. @@ -107,8 +112,7 @@ See `keyboard-translate-table' for more information." (while pairs - (puthash (car pairs) (car (cdr pairs)) keyboard-translate-table) - (setq pairs (cdr (cdr pairs))))) + (puthash (pop pairs) (pop pairs) keyboard-translate-table))) (put 'backspace 'ascii-character ?\b) (put 'delete 'ascii-character ?\177)
--- a/lisp/prim/files.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/prim/files.el Mon Aug 13 09:36:16 2007 +0200 @@ -314,7 +314,7 @@ (defun parse-colon-path (cd-path) "Explode a colon-separated list of paths into a string list." (and cd-path - (let (cd-list cd-list (cd-start 0) cd-colon) + (let (cd-list (cd-start 0) cd-colon) (setq cd-path (concat cd-path path-separator)) (while (setq cd-colon (string-match path-separator cd-path cd-start)) (setq cd-list @@ -1090,71 +1090,72 @@ (prin1-to-string err)))))) (defvar auto-mode-alist - (mapcar - 'purecopy - '(("\\.te?xt\\'" . text-mode) - ("\\.[ch]\\'" . c-mode) - ("\\.ltx\\'" . latex-mode) - ("\\.el\\'" . emacs-lisp-mode) - ("\\.l\\(i?sp\\)?\\'" . lisp-mode) - ("\\.f\\(or\\)?\\'" . fortran-mode) - ("\\.p\\(as\\)?\\'" . pascal-mode) - ("\\.ad[abs]\\'" . ada-mode) - ("\\.p[lm]\\'" . perl-mode) - ("\\.\\([CH]\\|cc\\|hh\\)\\'" . c++-mode) - ("\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\'" . c++-mode) - ("\\.java\\'" . java-mode) - ("\\.ma?k\\'" . makefile-mode) - ("[Mm]akefile\\(.in\\)?\\(.in\\)?\\'" . makefile-mode) + '(("\\.te?xt\\'" . text-mode) + ("\\.[ch]\\'" . c-mode) + ("\\.ltx\\'" . latex-mode) + ("\\.el\\'" . emacs-lisp-mode) + ("\\.l\\(i?sp\\)?\\'" . lisp-mode) + ("\\.f\\(or\\)?\\'" . fortran-mode) + ("\\.p\\(as\\)?\\'" . pascal-mode) + ("\\.ad[abs]\\'" . ada-mode) + ("\\.p[lm]\\'" . perl-mode) + ("\\.\\([CH]\\|cc\\|hh\\)\\'" . c++-mode) + ("\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\'" . c++-mode) + ("\\.java\\'" . java-mode) ;;; Less common extensions come here ;;; so more common ones above are found faster. - ("\\.texi\\(nfo\\)?\\'" . texinfo-mode) - ("\\.[sS]\\'" . asm-mode) - ("[Cc]hange.?[Ll]og?\\(.[0-9]+\\)?\\'" . change-log-mode) - ("\\$CHANGE_LOG\\$\\.TXT" . change-log-mode) - ("\\.scm\\(\\.[0-9]*\\)?\\'" . scheme-mode) - ("\\.py\\'" . python-mode) - ("\\.e\\'" . eiffel-mode) - ("\\.mss\\'" . scribe-mode) - ("\\.m\\([mes]\\|an\\)\\'" . nroff-mode) - ("\\.icn\\'" . icon-mode) + ("\\.texi\\(nfo\\)?\\'" . texinfo-mode) + ("\\.[sS]\\'" . asm-mode) + ("[Cc]hange.?[Ll]og?\\(.[0-9]+\\)?\\'" . change-log-mode) + ("\\$CHANGE_LOG\\$\\.TXT" . change-log-mode) + ("\\.scm\\(\\.[0-9]*\\)?\\'" . scheme-mode) + ("\\.py\\'" . python-mode) + ("\\.e\\'" . eiffel-mode) + ("\\.mss\\'" . scribe-mode) + ("\\.m\\([mes]\\|an\\)\\'" . nroff-mode) + ("\\.icn\\'" . icon-mode) ;;; The following should come after the ChangeLog pattern ;;; for the sake of ChangeLog.1, etc. ;;; and after the .scm.[0-9] pattern too. - ("\\.[12345678]\\'" . nroff-mode) - ("\\.[tT]e[xX]\\'" . tex-mode) - ("\\.\\(sty\\|cls\\|bbl\\)\\'" . latex-mode) - ("\\.bib\\'" . bibtex-mode) - ("\\.article\\'" . text-mode) - ("\\.letter\\'" . text-mode) - ("\\.\\(tcl\\|exp\\)\\'" . tcl-mode) - ("\\.wrl\\'" . vrml-mode) - ("\\.f90\\'" . f90-mode) - ("\\.awk\\'" . awk-mode) - ("\\.prolog\\'" . prolog-mode) - ("\\.tar\\'" . tar-mode) - ("\\.\\(arc\\|zip\\|lzh\\|zoo\\)\\'" . archive-mode) - ;; Mailer puts message to be edited in - ;; /tmp/Re.... or Message - ("^/tmp/Re" . text-mode) - ("/Message[0-9]*\\'" . text-mode) - ("/drafts/[0-9]+\\'" . mh-letter-mode) - ;; some news reader is reported to use this - ("^/tmp/fol/" . text-mode) - ("\\.y\\'" . c-mode) - ("\\.lex\\'" . c-mode) - ("\\.oak\\'" . scheme-mode) - ("\\.s?html?\\'" . html-mode) - ("\\.htm?l?3\\'" . html3-mode) - ("\\.\\(sgml?\\|dtd\\)\\'" . sgml-mode) - ("\\.c?ps\\'" . postscript-mode) - ;; .emacs following a directory delimiter - ;; in either Unix or VMS syntax. - ("[]>:/]\\..*emacs\\'" . emacs-lisp-mode) - ;; _emacs following a directory delimiter - ;; in MsDos syntax - ("[:/]_emacs\\'" . emacs-lisp-mode) - ("\\.ml\\'" . lisp-mode))) + ("\\.[12345678]\\'" . nroff-mode) + ("\\.[tT]e[xX]\\'" . tex-mode) + ("\\.\\(sty\\|cls\\|bbl\\)\\'" . latex-mode) + ("\\.bib\\'" . bibtex-mode) + ("\\.article\\'" . text-mode) + ("\\.letter\\'" . text-mode) + ("\\.\\(tcl\\|exp\\)\\'" . tcl-mode) + ("\\.wrl\\'" . vrml-mode) + ("\\.f90\\'" . f90-mode) + ("\\.awk\\'" . awk-mode) + ("\\.prolog\\'" . prolog-mode) + ("\\.tar\\'" . tar-mode) + ("\\.\\(arc\\|zip\\|lzh\\|zoo\\)\\'" . archive-mode) + ;; Mailer puts message to be edited in + ;; /tmp/Re.... or Message + ("^/tmp/Re" . text-mode) + ("/Message[0-9]*\\'" . text-mode) + ("/drafts/[0-9]+\\'" . mh-letter-mode) + ;; some news reader is reported to use this + ("^/tmp/fol/" . text-mode) + ("\\.y\\'" . c-mode) + ("\\.lex\\'" . c-mode) + ("\\.oak\\'" . scheme-mode) + ("\\.s?html?\\'" . html-mode) + ("\\.htm?l?3\\'" . html3-mode) + ("\\.\\(sgml?\\|dtd\\)\\'" . sgml-mode) + ("\\.c?ps\\'" . postscript-mode) + ;; .emacs following a directory delimiter + ;; in either Unix or VMS syntax. + ("[]>:/]\\..*emacs\\'" . emacs-lisp-mode) + ;; _emacs following a directory delimiter + ;; in MsDos syntax + ("[:/]_emacs\\'" . emacs-lisp-mode) + ("\\.m4\\'" . m4-mode) + ("configure\\.in\\'" . autoconf-mode) + ("\\.ml\\'" . lisp-mode) + ("\\.ma?k\\'" . makefile-mode) + ("[Mm]akefile\\(\\.\\|\\'\\)" . makefile-mode) + ) "Alist of filename patterns vs. corresponding major mode functions. Each element looks like (REGEXP . FUNCTION) or (REGEXP FUNCTION NON-NIL). \(NON-NIL stands for anything that is not nil; the value does not matter.) @@ -1166,17 +1167,15 @@ REGEXP and search the list again for another match.") (defconst interpreter-mode-alist - (mapcar 'purecopy - '(("^#!.*csh" . sh-mode) - ("^#!.*sh\\b" . ksh-mode) - ("^#!.*\\b\\(scope\\|wish\\|tcl\\|expect\\)" . tcl-mode) - ("perl" . perl-mode) - ("python" . python-mode) - ("awk\\b" . awk-mode) - ("rexx" . rexx-mode) - ("scm" . scheme-mode) - ("^:" . ksh-mode) - )) + '(("^#!.*csh" . sh-mode) + ("^#!.*sh\\b" . ksh-mode) + ("^#!.*\\b\\(scope\\|wish\\|tcl\\|expect\\)" . tcl-mode) + ("perl" . perl-mode) + ("python" . python-mode) + ("awk\\b" . awk-mode) + ("rexx" . rexx-mode) + ("scm" . scheme-mode) + ("^:" . ksh-mode)) "Alist mapping interpreter names to major modes. This alist is used to guess the major mode of a file based on the contents of the first line. This line often contains something like:
--- a/lisp/prim/modeline.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/prim/modeline.el Mon Aug 13 09:36:16 2007 +0200 @@ -46,86 +46,130 @@ :group 'modeline) (defun mouse-drag-modeline (event) - "Resize the window by dragging the modeline. -This should be bound to a mouse button in `modeline-map'." + "Resize a window by dragging its modeline. +This command should be bound to a button-press event in modeline-map. +Holding down a mouse button and moving the mouse up and down will +make the clicked-on window taller or shorter." (interactive "e") (or (button-press-event-p event) (error "%s must be invoked by a mouse-press" this-command)) (or (event-over-modeline-p event) (error "not over a modeline")) - (let ((depress-line (event-y event)) - (mouse-down t) - (window (event-window event)) - (old-window (selected-window)) - (def-line-height (face-height 'default)) - (prior-drag-modeline-event-time 0) - delta) - (while mouse-down + (let ((done nil) + (depress-line (event-y event)) + (start-event-frame (event-frame event)) + (start-event-window (event-window event)) + (start-nwindows (count-windows t)) + (last-timestamp 0) + default-line-height + modeline-height + should-enlarge-minibuffer + event min-height minibuffer y top bot edges wconfig growth) + (setq minibuffer (minibuffer-window start-event-frame) + default-line-height (face-height 'default start-event-window) + min-height (* window-min-height default-line-height) + modeline-height + (if (specifier-instance has-modeline-p start-event-window) + (+ (face-height 'modeline start-event-window) + (* 2 (specifier-instance modeline-shadow-thickness + start-event-window))) + (* 2 (specifier-instance modeline-shadow-thickness + start-event-window)))) + (if (not (eq (window-frame minibuffer) start-event-frame)) + (setq minibuffer nil)) + (if (and (null minibuffer) (one-window-p t)) + (error "Attempt to resize sole window")) + ;; if this is the bottommost ordinary window, then to + ;; move its modeline the minibuffer must be enlarged. + (setq should-enlarge-minibuffer + (and minibuffer (window-lowest-p start-event-window))) + ;; loop reading events + (while (not done) (setq event (next-event event)) - (cond ((motion-event-p event) - (if (window-lowest-p window) - (error "can't drag bottommost modeline")) - (cond ((> (- (event-timestamp event) - prior-drag-modeline-event-time) - drag-modeline-event-lag) - - (setq prior-drag-modeline-event-time (event-timestamp event)) - - (if (event-over-modeline-p event) - (setq delta 0) - (setq delta (- (event-y-pixel event) - (nth 3 (window-pixel-edges window)))) - (if (> delta 0) - (setq delta (+ delta def-line-height))) - (setq delta (/ delta def-line-height))) - - ;; cough sputter hack kludge. It shouldn't be possible - ;; to get in here when we are over the minibuffer. But - ;; it is happening and that cause next-vertical-window to - ;; return nil which does not lead to window-height returning - ;; anything remotely resembling a sensible value. So catch - ;; the situation and die a happy death. - ;; - ;; Oh, and the BLAT FOOP error messages suck as well but - ;; I don't know what should be there. This should be - ;; looked at again when the new redisplay is done. - (if (not (next-vertical-window window)) - (error "Try again: dragging in minibuffer does nothing")) - (cond ((and (> delta 0) - (<= (- (window-height (next-vertical-window window)) - delta) - window-min-height)) - (setq delta (- (window-height - (next-vertical-window window)) - window-min-height)) - (if (< delta 0) (error "BLAT"))) - ((and (< delta 0) - (< (+ (window-height window) delta) - window-min-height)) - (setq delta (- window-min-height - (window-height window))) - (if (> delta 0) (error "FOOP")))) - (if (= delta 0) - nil - (select-window window) - (enlarge-window delta) - ;; The call to enlarge-window may have caused the old - ;; window to disappear. Don't try and select it in - ;; that case. - (if (window-live-p old-window) - (select-window old-window)) - (sit-for 0) - )))) + ;; requeue event and quit if this is a misc-user, eval or + ;; keypress event. + ;; quit if this is a button press or release event, or if the event + ;; occurred in some other frame. + ;; drag if this is a mouse motion event and the time + ;; between this event and the last event is greater than + ;; drag-modeline-event-lag. + ;; do nothing if this is any other kind of event. + (cond ((or (misc-user-event-p event) + (key-press-event-p event) + (eval-event-p event)) + (setq unread-command-events (nconc unread-command-events + (list event)) + done t)) ((button-release-event-p event) - (setq mouse-down nil) + (setq done t) (if modeline-click-swaps-buffers (mouse-release-modeline event depress-line))) - ((or (button-press-event-p event) - (key-press-event-p event)) - (error "")) + ((button-event-p event) + (setq done t)) + ((timeout-event-p event) + nil) + ((not (motion-event-p event)) + (dispatch-event event)) + ((not (eq start-event-frame (event-frame event))) + (setq done t)) + ((< (abs (- (event-timestamp event) last-timestamp)) + drag-modeline-event-lag) + nil) (t - (dispatch-event event))) - ))) + (setq last-timestamp (event-timestamp event) + y (event-y-pixel event) + edges (window-pixel-edges start-event-window) + top (nth 1 edges) + bot (nth 3 edges)) + ;; scale back a move that would make the + ;; window too short. + (cond ((< (- y top (- modeline-height)) min-height) + (setq y (+ top min-height (- modeline-height))))) + ;; compute size change needed + (setq growth (- y bot (/ (- modeline-height) 2)) + wconfig (current-window-configuration)) + ;; grow/shrink minibuffer? + (if should-enlarge-minibuffer + (progn + ;; yes. scale back shrinkage if it + ;; would make the minibuffer less than 1 + ;; line tall. + ;; + ;; also flip the sign of the computed growth, + ;; since if we want to grow the window with the + ;; modeline we need to shrink the minibuffer + ;; and vice versa. + (if (and (> growth 0) + (< (- (window-pixel-height minibuffer) + growth) + default-line-height)) + (setq growth + (- (window-pixel-height minibuffer) + default-line-height))) + (setq growth (- growth)))) + ;; window grow and shrink by lines not pixels, so + ;; divide the pixel height by the height of the + ;; default face. + (setq growth (/ growth default-line-height)) + ;; grow/shrink the window + (enlarge-window growth nil (if should-enlarge-minibuffer + minibuffer + start-event-window)) + ;; if this window's growth caused another + ;; window to be deleted because it was too + ;; short, rescind the change. + ;; + ;; if size change caused space to be stolen + ;; from a window above this one, rescind the + ;; change, but only if we didn't grow/shrink + ;; the minibuffer. minibuffer size changes + ;; can cause all windows to shrink... no way + ;; around it. + (if (or (/= start-nwindows (count-windows t)) + (and (not should-enlarge-minibuffer) + (/= top (nth 1 (window-pixel-edges + start-event-window))))) + (set-window-configuration wconfig))))))) ;; from Bob Weiner (bob_weiner@pts.mot.com) (defun mouse-release-modeline (event line-num) @@ -389,7 +433,8 @@ "button2 cycles to the next buffer") (defconst modeline-buffer-identification - (list (cons modeline-buffer-id-left-extent (purecopy "XEmacs:")) + (list (cons modeline-buffer-id-left-extent (purecopy "XEmacs%N:")) + ; this used to be "XEmacs:" (cons modeline-buffer-id-right-extent (purecopy " %17b"))) "Modeline control for identifying the buffer being displayed. Its default value is \"XEmacs: %17b\" (NOT!). Major modes that edit things
--- a/lisp/prim/simple.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/prim/simple.el Mon Aug 13 09:36:16 2007 +0200 @@ -1825,6 +1825,17 @@ (and (null arg) (eolp) (forward-char -1)) (transpose-subr 'forward-char (prefix-numeric-value arg))) +;;; A very old implementation of transpose-chars from the old days ... +(defun transpose-preceding-chars (arg) + "Interchange characters before point. +With prefix arg ARG, effect is to take character before point +and drag it forward past ARG other characters (backward if ARG negative). +If no argument and not at start of line, the previous two chars are exchanged." + (interactive "*P") + (and (null arg) (not (bolp)) (forward-char -1)) + (transpose-subr 'forward-char (prefix-numeric-value arg))) + + (defun transpose-words (arg) "Interchange words around point, leaving point at end of them. With prefix arg ARG, effect is to take word before or around point
--- a/lisp/prim/window.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/prim/window.el Mon Aug 13 09:36:16 2007 +0200 @@ -343,7 +343,7 @@ window-list)) (defun buffer-in-multiple-windows-p (&optional buffer) - "Returns t if BUFFER is in multiple windows. + "Return t if BUFFER is in multiple windows. If BUFFER is not specified, the current buffer will be used." (setq buffer (or buffer (get-buffer buffer)
--- a/lisp/sunpro/sunpro-menubar.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/sunpro/sunpro-menubar.el Mon Aug 13 09:36:16 2007 +0200 @@ -171,7 +171,7 @@ (progn (if (equal sccs-or-vc-menus 'sccs) (delete-menu-item '("SCCS")) - (delete-menu-item '("VC"))) + (delete-menu-item '("Version Control"))) (delete-menu-item '("SPARCworks")) (delete-menu-item '("Options" "SPARCworks")) (delete-menu-item '("Options" "-----! before save options")) @@ -182,13 +182,13 @@ (eos::start) (if (equal sccs-or-vc-menus 'sccs) (progn - (delete-menu-item '("VC")) + (delete-menu-item '("Version Control")) (require 'sccs) (add-menu '() "SCCS" (cdr sccs-menu))) (progn (require 'vc) (delete-menu-item '("SCCS")) - (add-menu '() "VC" vc-default-menu))) + (add-menu '() "Version Control" vc-default-menu))) (setq programmer-menus-p t)))) (defun sunpro-build-buffers-menu-hook ()
--- a/lisp/utils/hide-copyleft.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/utils/hide-copyleft.el Mon Aug 13 09:36:16 2007 +0200 @@ -1,41 +1,63 @@ -;;; -*- Mode:Emacs-Lisp -*- +;;; hide-copyleft.el --- hide obnoxious copyright prologs + +;; Copyright (C) 1997 Sun Microsystems. + +;; This file is part of XEmacs. + +;; XEmacs is free software; you can redistribute it and/or modify it +;; under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 2, or (at your option) +;; any later version. + +;; XEmacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; 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 Free +;; Software Foundation, Inc. 59 Temple Place - Suite 330, Boston, MA +;; 02111-1307, USA. + +;;; Commentary: -;;; "hide-copyleft.el" by Jamie Zawinski <jwz@lucid.com>, 19-jan-91. -;;; Last modified 7-sep-91. -;;; -;;; I sometimes find it tiresome to have fifteen lines of copyright notice at -;;; the beginning of each file. Meta-< does not take you to the beginning of -;;; the code, it takes you a windowfull or two away, which can be tedious on -;;; slow terminal lines. -;;; -;;; I know what the copyright notice says; so this code makes all but the first -;;; line of it be invisible, by using Emacs's selective-display feature. The -;;; text is still present and unmodified, but it is invisible. -;;; -;;; Elide the copyright notice with "Meta-X hide-copyleft-region". Make it -;;; visible again with "Control-U Meta-X hide-copyleft-region". Or, if you're -;;; sure you're not gonna get sued, you can do something like this in your -;;; .emacs file: -;;; -;;; (autoload 'hide-copyleft-region "hide-copyleft" nil t) -;;; (autoload 'unhide-copyleft-region "hide-copyleft" nil t) -;;; (setq emacs-lisp-mode-hook 'hide-copyleft-region -;;; c-mode-hook 'hide-copyleft-region) -;;; -;;; This code (obviously) has quite specific knowledge of the wording of the -;;; various copyrights I've run across. Let me know if you find one on which -;;; it fails. +;; Written by Jamie Zawinski <jwz@netscape.com>, 19-jan-91. +;; Minor fixes by Martin Buchholz, 14-may-97. +;; Last modified 14-may-97. +;; +;; I sometimes find it tiresome to have fifteen lines of copyright notice at +;; the beginning of each file. Meta-< does not take you to the beginning of +;; the code, it takes you a windowfull or two away, which can be tedious on +;; slow terminal lines. +;; +;; I know what the copyright notice says; so this code makes all but the first +;; line of it be invisible, by using Emacs's selective-display feature. The +;; text is still present and unmodified, but it is invisible. +;; +;; Elide the copyright notice with "Meta-X hide-copyleft-region". Make it +;; visible again with "Control-U Meta-X hide-copyleft-region". Or, if you're +;; sure you're not gonna get sued, you can do something like this in your +;; .emacs file: +;; +;; (autoload 'hide-copyleft-region "hide-copyleft" nil t) +;; (autoload 'unhide-copyleft-region "hide-copyleft" nil t) +;; (add-hook 'emacs-lisp-mode-hook 'hide-copyleft-region) +;; (add-hook 'c-mode-hook 'hide-copyleft-region) +;; +;; This code (obviously) has quite specific knowledge of the wording of the +;; various copyrights I've run across. Let me know if you find one on which +;; it fails. (defvar copylefts-to-hide ;; There are some extra backslashes in these strings to prevent this code ;; from matching the definition of this list as the copyright notice! '(;; GNU ("free software\; you can redistribute it" . - "notice must be preserved on all") + "notice must be\ preserved on all") ("free software\; you can redistribute it" . - "copy of the GNU General Public License.*\n?.*\n?.*\n?.*\n?02139,") + "copy of the GNU General Public License.*\n?.*\n?.*\n?.*\n?.*\\(02139,\\|02111-1307\\)") ("distributed in the hope that it will be useful\," . - "notice must be preserved on all") + "notice must be\ preserved on all") ("free software\; you can redistribute it" . "General Public License for more details\\.") ;; X11 @@ -62,6 +84,7 @@ The first one found is hidden, so order is significant.") +;;;###autoload (defun hide-copyleft-region (&optional arg) "Make the legal drivel at the front of this file invisible. Unhide it again with C-u \\[hide-copyleft-region]." @@ -75,7 +98,7 @@ (let ((mod-p (buffer-modified-p)) (buffer-read-only nil) (rest copylefts-to-hide) - pair start end max) + pair start end) (widen) (goto-char (point-min)) (while (and rest (not pair)) @@ -107,6 +130,7 @@ (setq selective-display t) (set-buffer-modified-p mod-p))))))) +;;;###autoload (defun unhide-copyleft-region () "If the legal nonsense at the top of this file is elided, make it visible again." (save-excursion
--- a/lisp/utils/text-props.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/utils/text-props.el Mon Aug 13 09:36:16 2007 +0200 @@ -5,7 +5,7 @@ ;; Copyright (C) 1995 Ben Wing. ;; Keywords: extensions, wp, faces -;; Author: Jamie Zawinski <jwz@lucid.com> +;; Author: Jamie Zawinski <jwz@netscape.com> ;; Modified: Ben Wing <wing@666.com> -- many of the Lisp functions below ;; were completely broken. ;;
--- a/lisp/version.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/version.el Mon Aug 13 09:36:16 2007 +0200 @@ -22,10 +22,10 @@ ;;; Code: -(defconst emacs-version "20.2" +(defconst emacs-version "20.3" "Version numbers of this version of Emacs.") -(setq emacs-version (purecopy (concat emacs-version " XEmacs Lucid"))) +(setq emacs-version (purecopy (concat emacs-version " XEmacs Lucid (beta1)"))) (defconst emacs-major-version (progn (or (string-match "^[0-9]+" emacs-version)
--- a/lisp/x11/x-faces.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/x11/x-faces.el Mon Aug 13 09:36:16 2007 +0200 @@ -3,7 +3,7 @@ ;;; Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc. ;;; Copyright (C) 1995, 1996 Ben Wing. -;; Author: Jamie Zawinski <jwz@lucid.com> +;; Author: Jamie Zawinski <jwz@netscape.com> ;; Modified by: Chuck Thompson <cthomp@cs.uiuc.edu> ;; Modified by: Ben Wing <wing@spg.amdahl.com>
--- a/lisp/x11/x-font-menu.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/x11/x-font-menu.el Mon Aug 13 09:36:16 2007 +0200 @@ -4,7 +4,7 @@ ;; Copyright (C) 1995 Tinker Systems and INS Engineering Corp. ;; Copyright (C) 1997 Sun Microsystems -;; Author: Jamie Zawinski <jwz@lucid.com> +;; Author: Jamie Zawinski <jwz@netscape.com> ;; Restructured by: Jonathan Stigelman <Stig@hackvan.com> ;; Mule-ized by: Martin Buchholz
--- a/lisp/x11/x-init.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/x11/x-init.el Mon Aug 13 09:36:16 2007 +0200 @@ -179,13 +179,17 @@ (define-key global-map 'menu 'popup-mode-menu) ;;(define-key global-map '(shift menu) 'x-goto-menubar) ;NYI - ;; This runs after the first frame has been created (we can't - ;; talk to the X server before that) but before the - ;; site-start-file or .emacs file, so sites and users have a - ;; chance to override it. - (add-hook 'before-init-hook 'x-initialize-keyboard) + (setq post-x-win-initted t))) + - (setq post-x-win-initted t))) +(when (featurep 'x) + (add-hook + 'create-console-hook + (lambda (console) + (letf (((selected-console) console)) + (when (eq 'x (console-type console)) + (x-initialize-keyboard)))))) + (defun make-frame-on-display (display &optional props) "Create a frame on the X display named DISPLAY.
--- a/lisp/x11/x-win-sun.el Mon Aug 13 09:35:15 2007 +0200 +++ b/lisp/x11/x-win-sun.el Mon Aug 13 09:36:16 2007 +0200 @@ -37,7 +37,7 @@ ;; ;; for i in 0 1 2 3 4 5 6 7 8 9 Add Subtract Multiply Divide Decimal ; do ;; echo "keysym KP-$i = KP-$i" -;; done +;; done | xmodmap ;; ;; Clearly, as a good X11 citizen, we can't do this. ;;
--- a/lwlib/Makefile.in.in Mon Aug 13 09:35:15 2007 +0200 +++ b/lwlib/Makefile.in.in Mon Aug 13 09:36:16 2007 +0200 @@ -27,16 +27,22 @@ #undef unix #undef sgi #undef NeXT +#undef mips +#undef i386 +#undef linux srcdir=@srcdir@ -C_SWITCH_X_SITE=@C_SWITCH_X_SITE@ -C_SWITCH_SITE=@C_SWITCH_SITE@ +/* C_SWITCH_X_SITE=@C_SWITCH_X_SITE@ */ +/* C_SWITCH_SITE=@C_SWITCH_SITE@ */ + SHELL=/bin/sh CC=@CC@ +CPP=@CPP@ CFLAGS=@CFLAGS@ -CPP=@CPP@ +LDFLAGS=@LDFLAGS@ +CPPFLAGS=@CPPFLAGS@ RANLIB=@RANLIB@ RM = rm -f @@ -213,9 +219,17 @@ all:: #endif -ALL_CFLAGS = -I. C_SWITCH_MACHINE C_SWITCH_SITE C_SWITCH_X_SITE \ - C_SWITCH_X_MACHINE C_SWITCH_X_SYSTEM \ - C_SWITCH_SYSTEM NEED_LUCID NEED_MOTIF NEED_ATHENA \ +c_switch_general=@c_switch_general@ +c_switch_window_system=@c_switch_window_system@ +c_switch_all=@c_switch_all@ +ld_switch_general=@ld_switch_general@ +ld_switch_window_system=@ld_switch_window_system@ +ld_switch_all=@ld_switch_all@ +ld_libs_general=@ld_libs_general@ +ld_libs_window_system=@ld_libs_window_system@ +ld_libs_all=@ld_libs_all@ + +ALL_CFLAGS = -I. $(c_switch_all) NEED_LUCID NEED_MOTIF NEED_ATHENA \ LWLIB_MENUBARS LWLIB_SCROLLBARS LWLIB_DIALOGS \ $(ENERGIZEP) ${CFLAGS} CONST_FLAG .c.o:
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lwlib/config.h.in Mon Aug 13 09:36:16 2007 +0200 @@ -0,0 +1,41 @@ +/* XEmacs site configuration template file. -*- C -*- + Copyright (C) 1986, 1991, 1992, 1993, 1994 Free Software Foundation, Inc. + +This file is part of XEmacs. + +XEmacs is free software; you can redistribute it and/or modify it +under the terms of the GNU General Public License as published by the +Free Software Foundation; either version 2, or (at your option) any +later version. + +XEmacs is distributed in the hope that it will be useful, but WITHOUT +ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU 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 Free Software Foundation, Inc., 59 Temple Place - Suite 330, +Boston, MA 02111-1307, USA. */ + +/* Not in FSF. */ + +#ifndef _CONFIG_H_ +#define _CONFIG_H_ + +/* alloca twiddling belongs in one place, not the s&m headers + AIX requires this to be the first thing in the file. */ +#undef HAVE_ALLOCA_H + +#ifndef NOT_C_CODE +#ifdef __GNUC__ +#undef alloca +#define alloca __builtin_alloca +#elif defined(_AIX) +#pragma alloca +#elif HAVE_ALLOCA_H +#include <alloca.h> +#endif +#endif /* NOT C */ + +#endif /* _CONFIG_H_ */
--- a/lwlib/lwlib.c Mon Aug 13 09:35:15 2007 +0200 +++ b/lwlib/lwlib.c Mon Aug 13 09:36:16 2007 +0200 @@ -23,6 +23,7 @@ #undef __STRICT_BSD__ /* ick */ #endif +#include <config.h> #include <stdlib.h> #include <unistd.h> #include <sys/types.h> @@ -32,34 +33,6 @@ #include "lwlib-internal.h" #include "lwlib-utils.h" -#if defined(__GNUC__) && !defined(alloca) -#define alloca __builtin_alloca -#endif - -#if ((!__GNUC__) && !defined(__hpux)) && !defined(_AIX) && !defined (_SCO_DS) && !defined (__USLC__) && !defined(sinix) && !defined(WINDOWSNT) && !defined(_SEQUENT_) -#include <alloca.h> -#endif - -#ifdef WINDOWSNT -/* NT has an _alloca function prototyped in malloc.h --marcpa */ -#include <malloc.h> -#endif - - -#ifdef __SUNPRO_C -void *__builtin_alloca (unsigned int); -#endif - -#if defined(_AIX) -#pragma alloca -#endif - -#ifdef BROKEN_SUNOS_HEADERS -extern void * memset (void *, int, int); -extern int strcasecmp (char *, char *); -extern int fprintf (FILE *, CONST char *, ...); -#endif - #ifdef NEED_LUCID #include "lwlib-Xlw.h" #endif
--- a/man/custom.texi Mon Aug 13 09:35:15 2007 +0200 +++ b/man/custom.texi Mon Aug 13 09:36:16 2007 +0200 @@ -13,7 +13,7 @@ @comment node-name, next, previous, up @top The Customization Library -Version: 1.84 +Version: 1.97 @menu * Introduction:: @@ -76,8 +76,46 @@ @item customize-apropos Create a customization buffer containing all variables, faces, and groups that match a user specified regular expression. + +@item customize-saved +Create a customization buffer containing all variables and faces that +have been saved with customize. + +@item customize-customized +Create a customization buffer containing all variables and faces that +have been customized but not saved. @end table +You can also set variables without creating a customization buffer. + +@deffn Command customize-set-variable var val +Set the default for @var{variable} to @var{value}. +@var{value} is a Lisp object. + +If @var{variable} has a @code{custom-set} property, that is used for setting +@var{variable}, otherwise @code{set-default} is used. + +The @code{customized-value} property of the @var{variable} will be set +to a list with a quoted @var{value} as its sole list member. + +If @var{variable} has a @code{variable-interactive} property, that is +used as if it were the arg to `interactive' (which see) to interactively +read the value. + +If @var{variable} has a @code{custom-type} property, it must be a widget +and the @code{:prompt-value} property of that widget will be used for +reading the value. +@end deffn + +All variables that have been set either from a customization buffer or +with @code{customize-set-variable} can be saved with the command +@code{custom-save-customized}. + +@deffn Command custom-save-customized +Save all variables that have been set with customize in this session. +@end deffn + + @node The Customization Buffer, Declarations, User Commands, Top @comment node-name, next, previous, up @section The Customization Buffer. @@ -492,9 +530,50 @@ @table @code @item :type @var{value} should be a widget type. + @item :options @var{value} should be a list of possible members of the specified type. For hooks, this is a list of function names. + +@item :initialize +@var{value} should be a function used to initialize the variable. It +takes two arguments, the symbol and value given in the @code{defcustom} call. +Some predefined functions are: + +@table @code +@item custom-initialize-set +Use the @code{:set} method to initialize the variable. Do not +initialize it if already bound. This is the default @code{:initialize} +method. + +@item custom-initialize-default +Always use @code{set-default} to initialize the variable, even if a +@code{:set} method has been specified. + +@item custom-initialize-reset +If the variable is already bound, reset it by calling the @code{:set} +method with the value returned by the @code{:get} method. + +@item custom-initialize-changed +Like @code{custom-initialize-reset}, but use @code{set-default} to +initialize the variable if it is not bound and has not been set +already. +@end table + +@item :set +@var{value} should be a function to set the value of the symbol. It +takes two arguments, the symbol to set and the value to give it. The +default is @code{set-default}. + +@item :get +@var{value} should be a function to extract the value of symbol. The +function takes one argument, a symbol, and should return the current +value for that symbol. The default is @code{default-value}. + +@item :require +@var{value} should be a feature symbol. Each feature will be required +after initialization, of the the user have saved this option. + @end table @xref{Sexp Types,,,widget,The Widget Library}, for information about @@ -563,9 +642,9 @@ Should be one of @code{light} or @code{dark}. @end table -Internally, custom uses the symbol property @code{factory-face} for the -program specified default face properties, @code{saved-face} for -properties saved by the user, and @code{face-doc-string} for the +Internally, custom uses the symbol property @code{face-defface-spec} for +the program specified default face properties, @code{saved-face} for +properties saved by the user, and @code{face-documentation} for the documentation string.@refill @end defun @@ -634,11 +713,6 @@ @section Wishlist @itemize @bullet -@item -The menu items should be grayed out when the information is -missing. I.e. if a variable doesn't have a factory setting, the user -should not be allowed to select the @samp{Factory} menu item. - @item Better support for keyboard operations in the customize buffer. @@ -663,10 +737,6 @@ Make it possible to append to `choice', `radio', and `set' options. @item -Make it possible to customize code, for example to enable or disable a -global minor mode. - -@item Ask whether set or modified variables should be saved in @code{kill-buffer-hook}. @@ -689,6 +759,39 @@ Make it possible to include a comment/remark/annotation when saving an option. +@item +Add some direct support for meta variables, i.e. make it possible to +specify that this variable should be reset when that variable is +changed. + +@item +Add tutorial. + +@item +Describe the @code{:type} syntax in this manual. + +@item +Find a place is this manual for the following text: + +@strong{Radio vs. Buttons} + +Use a radio if you can't find a good way to describe the item in the +choice menu text. I.e. it is better to use a radio if you expect the +user would otherwise manually select each item from the choice menu in +turn to see what it expands too. + +Avoid radios if some of the items expands to complex structures. + +I mostly use radios when most of the items are of type +@code{function-item} or @code{variable-item}. + +@item +Update customize buffers when @code{custom-set-variable} or +@code{custom-save-customized} is called. + +@item +Better handling of saved but uninitialized items. + @end itemize @contents
--- a/man/internals/internals.texi Mon Aug 13 09:35:15 2007 +0200 +++ b/man/internals/internals.texi Mon Aug 13 09:36:16 2007 +0200 @@ -493,6 +493,10 @@ version 20.0 released February 9, 1997. @item version 19.15 released March 28, 1997. +@item +version 20.1 (not released to the net) April 15, 1997. +@item +version 20.2 released May 16, 1997. @end itemize @node GNU Emacs 19
--- a/man/lispref/commands.texi Mon Aug 13 09:35:15 2007 +0200 +++ b/man/lispref/commands.texi Mon Aug 13 09:36:16 2007 +0200 @@ -723,27 +723,29 @@ @end defvar @defvar last-command-char + If the value of @code{last-command-event} is a keyboard event, then this -is the nearest @sc{ASCII} equivalent to it. This is the value that -@code{self-insert-command} will put in the buffer. Remember that there -is @emph{not} a 1:1 mapping between keyboard events and @sc{ASCII} -characters: the set of keyboard events is much larger, so writing code -that examines this variable to determine what key has been typed is bad -practice, unless you are certain that it will be one of a small set of -characters. +is the nearest character equivalent to it (or @code{nil} if there is no +character equivalent). @code{last-command-char} is the character that +@code{self-insert-command} will insert in the buffer. Remember that +there is @emph{not} a one-to-one mapping between keyboard events and +XEmacs characters: many keyboard events have no corresponding character, +and when the Mule feature is available, most characters can not be input +on standard keyboards, except possibly with help from an input method. +So writing code that examines this variable to determine what key has +been typed is bad practice, unless you are certain that it will be one +of a small set of characters. -This function exists for compatibility with Emacs version 18. +This variable exists for compatibility with Emacs version 18. @example @group -last-command-char +last-command-char ;; @r{Now use @kbd{C-u C-x C-e} to evaluate that.} - @result{} 5 + @result{} ?\^E @end group @end example -@noindent -The value is 5 because that is the @sc{ASCII} code for @kbd{C-e}. @end defvar @defvar current-mouse-event @@ -820,7 +822,7 @@ or released, button events specify the modifier keys that were held down at the time and the position of the pointer at the time. -@item pointer-motion event +@item motion event The pointer was moved. Along with the position of the pointer, these events also specify the modifier keys that were held down at the time. @@ -954,38 +956,72 @@ @end table @end table +@defun event-type event +Return the type of @var{event}. + +This will be a symbol; one of + +@table @code +@item key-press +A key was pressed. +@item button-press +A mouse button was pressed. +@item button-release +A mouse button was released. +@item motion +The mouse moved. +@item misc-user +Some other user action happened; typically, this is +a menu selection or scrollbar action. +@item process +Input is available from a subprocess. +@item timeout +A timeout has expired. +@item eval +This causes a specified action to occur when dispatched. +@item magic +Some window-system-specific event has occurred. +@end table +@end defun + @node Event Predicates @subsection Event Predicates -The following predicates return whether an object is an event of a particular -type. - -@defun button-event-p object object -This is true if @var{object} is a button-press or button-release event. -@end defun - -@defun button-press-event-p object -This is true if @var{object} is a mouse-button-press event. -@end defun - -@defun button-release-event-p object -This is true if @var{object} is a mouse-button-release event. -@end defun - -@defun eval-event-p object -This is true if @var{object} is an eval or misc-user event. -@end defun +The following predicates return whether an object is an event of a +particular type. @defun key-press-event-p object This is true if @var{object} is a key-press event. @end defun -@defun misc-user-event-p object -This is true if @var{object} is a misc-user event. +@defun button-event-p object object +This is true if @var{object} is a mouse button-press or button-release +event. +@end defun + +@defun button-press-event-p object +This is true if @var{object} is a mouse button-press event. +@end defun + +@defun button-release-event-p object +This is true if @var{object} is a mouse button-release event. @end defun @defun motion-event-p object -This is true if @var{object} is a mouse-motion event. +This is true if @var{object} is a mouse motion event. +@end defun + +@defun mouse-event-p object +This is true if @var{object} is a mouse button-press, button-release +or motion event. +@end defun + +@defun eval-event-p object +This is true if @var{object} is an eval event. +@end defun + +@defun misc-user-event-p object +This is true if @var{object} is a misc-user event. @end defun @defun process-event-p object @@ -1003,7 +1039,7 @@ @node Accessing Mouse Event Positions @subsection Accessing the Position of a Mouse Event -Unlike other events, mouse events (i.e. mouse-motion, button-press, and +Unlike other events, mouse events (i.e. motion, button-press, and button-release events) occur in a particular location on the screen. Many primitives are provided for determining exactly where the event occurred and what is under that location. @@ -1032,15 +1068,13 @@ @defun event-x-pixel event This function returns the X position in pixels of the given mouse event. The value returned is relative to the frame the event occurred in. -This will signal an error if the event is not a mouse-motion, button-press, -or button-release event. +This will signal an error if the event is not a mouse event. @end defun @defun event-y-pixel event This function returns the Y position in pixels of the given mouse event. The value returned is relative to the frame the event occurred in. -This will signal an error if the event is not a mouse-motion, button-press, -or button-release event. +This will signal an error if the event is not a mouse event. @end defun @node Window-Level Event Position Info @@ -1053,16 +1087,16 @@ Given a mouse motion, button press, or button release event, compute and return the window on which that event occurred. This may be @code{nil} if the event occurred in the border or over a toolbar. The modeline is -considered to be in the window it represents. +considered to be within the window it describes. @end defun @defun event-buffer event Given a mouse motion, button press, or button release event, compute and return the buffer of the window on which that event occurred. This may be @code{nil} if the event occurred in the border or over a toolbar. -The modeline is considered to be in the window it represents. This is +The modeline is considered to be within the window it describes. This is equivalent to calling @code{event-window} and then calling -@code{event-buffer} on the result if it is a window. +@code{window-buffer} on the result if it is a window. @end defun @defun event-window-x-pixel event @@ -1206,8 +1240,8 @@ @end defun @defun event-button event -This function returns the button-number of the given mouse-button-press -event. +This function returns the button-number of the given button-press or +button-release event. @end defun @defun event-modifiers event
--- a/man/widget.texi Mon Aug 13 09:35:15 2007 +0200 +++ b/man/widget.texi Mon Aug 13 09:36:16 2007 +0200 @@ -13,7 +13,7 @@ @comment node-name, next, previous, up @top The Emacs Widget Library -Version: 1.84 +Version: 1.97 @menu * Introduction:: @@ -24,7 +24,10 @@ * Sexp Types:: * Widget Properties:: * Defining New Widgets:: -* Widget Wishlist.:: +* Widget Browser:: +* Widget Minor Mode:: +* Utilities:: +* Widget Wishlist:: @end menu @node Introduction, User Interface, Top, Top @@ -229,9 +232,10 @@ Activating one of these will convert it to the other. This is useful for implementing multiple-choice fields. You can create it wit @item The @samp{@b{( )}} and @samp{@b{(*)}} buttons. -Only one radio button in a @code{radio-button-choice} widget can be selected at any -time. When you push one of the unselected radio buttons, it will be -selected and the previous selected radio button will become unselected. +Only one radio button in a @code{radio-button-choice} widget can be +selected at any time. When you push one of the unselected radio +buttons, it will be selected and the previous selected radio button will +become unselected. @item The @samp{@b{[Apply Form]}} @samp{@b{[Reset Form]}} buttons. These are explicit buttons made with the @code{push-button} widget. The main difference from the @code{link} widget is that the buttons are will be @@ -528,6 +532,12 @@ return the widget containing the invalid data, and set that widgets @code{:error} property to a string explaining the error. +The following predefined function can be used: + +@defun widget-children-validate widget +All the @code{:children} of @var{widget} must be valid. +@end defun + @item :tab-order Specify the order in which widgets are traversed with @code{widget-forward} or @code{widget-backward}. This is only partially @@ -585,6 +595,7 @@ * checkbox:: * checklist:: * editable-list:: +* group:: @end menu @node link, url-link, Basic Types, Basic Types @@ -921,6 +932,13 @@ Insert a literal @samp{%}. @end table +@item :greedy +Usually, a checklist will only match if the items are in the exact +sequence given in the specification. By setting @code{:greedy} to +non-nil, it will allow the items to come in any sequence. However, if +you extract the value they will be in the sequence given in the +checklist. I.e. the original sequence is forgotten. + @item button-args A list of keywords to pass to the checkboxes. Useful for setting e.g. the @samp{:help-echo} for each checkbox. @@ -935,7 +953,7 @@ The list of types. @end table -@node editable-list, , checklist, Basic Types +@node editable-list, group, checklist, Basic Types @comment node-name, next, previous, up @subsection The @code{editable-list} Widget @@ -945,7 +963,7 @@ TYPE ::= (editable-list [KEYWORD ARGUMENT]... TYPE) @end example -The value is a list, where each member represent one widget of type +The value is a list, where each member represents one widget of type @var{type}. The following extra properties are recognized. @@ -987,30 +1005,43 @@ @end table +@node group, , editable-list, Basic Types +@comment node-name, next, previous, up +@subsection The @code{group} Widget + +This widget simply group other widget together. + +Syntax: + +@example +TYPE ::= (group [KEYWORD ARGUMENT]... TYPE...) +@end example + +The value is a list, with one member for each @var{type}. + @node Sexp Types, Widget Properties, Basic Types, Top @comment @section Sexp Types A number of widgets for editing s-expressions (lisp types) are also -available. These basically fall in three categories: @dfn{atoms}, -@dfn{composite types}, and @dfn{generic}. +available. These basically fall in the following categories. @menu +* constants:: * generic:: * atoms:: * composite:: @end menu -@node generic, atoms, Sexp Types, Sexp Types +@node constants, generic, Sexp Types, Sexp Types @comment node-name, next, previous, up -@subsection The Generic Widget. +@subsection The Constant Widgets. -The @code{const} and @code{sexp} widgets can contain any lisp -expression. In the case of the @code{const} widget the user is +The @code{const} widget can contain any lisp expression, but the user is prohibited from editing edit it, which is mainly useful as a component of one of the composite widgets. -The syntax for the generic widgets is +The syntax for the @code{const} widget is @example TYPE ::= (const [KEYWORD ARGUMENT]... [ VALUE ]) @@ -1024,6 +1055,33 @@ buffer. @end deffn +There are two variations of the @code{const} widget, namely +@code{variable-item} and @code{function-item}. These should contain a +symbol with a variable or function binding. The major difference from +the @code{const} widget is that they will allow the user to see the +variable or function documentation for the symbol. + +@deffn Widget variable-item +An immutable symbol that is bound as a variable. +@end deffn + +@deffn Widget function-item +An immutable symbol that is bound as a function. +@end deffn + +@node generic, atoms, constants, Sexp Types +@comment node-name, next, previous, up +@subsection Generic Sexp Widget. + +The @code{sexp} widget can contain any lisp expression, and allows the +user to edit it inline in the buffer. + +The syntax for the @code{sexp} widget is + +@example +TYPE ::= (sexp [KEYWORD ARGUMENT]... [ VALUE ]) +@end example + @deffn Widget sexp This will allow you to edit any valid s-expression in an editable buffer field. @@ -1057,6 +1115,10 @@ Allows you to edit a string in an editable field. @end deffn +@deffn Widget regexp +Allows you to edit a regular expression in an editable field. +@end deffn + @deffn Widget character Allows you to enter a character in an editable field. @end deffn @@ -1083,6 +1145,14 @@ Allows you to edit a lisp symbol in an editable field. @end deffn +@deffn Widget function +Allows you to edit a lambda expression, or a function name with completion. +@end deffn + +@deffn Widget variable +Allows you to edit a variable name, with completion. +@end deffn + @deffn Widget integer Allows you to edit an integer in an editable field. @end deffn @@ -1116,8 +1186,8 @@ component. There must be exactly two components. @end deffn -@deffn Widget lisp -The value of a @code{lisp} widget is a list containing the value of +@deffn Widget list +The value of a @code{list} widget is a list containing the value of each of its component. @end deffn @@ -1258,7 +1328,7 @@ @code{:deactivated} keywords instead. -@node Defining New Widgets, Widget Wishlist., Widget Properties, Top +@node Defining New Widgets, Widget Browser, Widget Properties, Top @comment node-name, next, previous, up @section Defining New Widgets @@ -1308,6 +1378,16 @@ widget type. When a widget is created, this function is called for the widget type and all the widgets parent types, most derived first. +The following predefined functions can be used here: + +@defun widget-types-convert-widget widget +Convert @code{:args} as widget types in @var{widget}. +@end defun + +@defun widget-value-convert-widget widget +Initialize @code{:value} from @code{:args} in @var{widget}. +@end defun + @item :value-to-internal Function to convert the value to the internal format. The function takes two arguments, a widget and an external value, and returns the @@ -1342,6 +1422,22 @@ remove the text, but it should release markers and delete nested widgets if such has been used. +The following predefined function can be used here: + +@defun widget-children-value-delete widget +Delete all @code{:children} and @code{:buttons} in @var{widget}. +@end defun + +@item :value-get +Function to extract the value of a widget, as it is displayed in the +buffer. + +The following predefined function can be used here: + +@defun widget-value-value-get widget +Return the @code{:value} property of @var{widget}. +@end defun + @item :format-handler Function to handle unknown @samp{%} escapes in the format string. It will be called with the widget and the escape character as arguments. @@ -1350,21 +1446,97 @@ You should end up calling @code{widget-default-format-handler} to handle unknown escape sequences, which will handle the @samp{%h} and any future escape sequences, as well as give an error for unknown escapes. + +@item :action +Function to handle user initiated events. By default, @code{:notify} +the parent. + +The following predefined function can be used here: + +@defun widget-parent-action widget &optional event +Tell @code{:parent} of @var{widget} to handle the @code{:action}.@br +Optional @var{event} is the event that triggered the action. +@end defun + +@item :prompt-value +Function to prompt for a value in the minibuffer. The function should +take four arguments, @var{widget}, @var{prompt}, @var{value}, and +@var{unbound} and should return a value for widget entered by the user. +@var{prompt} is the prompt to use. @var{value} is the default value to +use, unless @var{unbound} is non-nil in which case there are no default +value. The function should read the value using the method most natural +for this widget, and does not have to check that it matches. @end table If you want to define a new widget from scratch, use the @code{default} widget as its base. -@deffn Widget default [ keyword argument ] +@deffn Widget default Widget used as a base for other widgets. It provides most of the functionality that is referred to as ``by default'' in this text. @end deffn -@node Widget Wishlist., , Defining New Widgets, Top +@node Widget Browser, Widget Minor Mode, Defining New Widgets, Top +@comment node-name, next, previous, up +@section Widget Browser + +There is a separate package to browse widgets. This is intended to help +programmers who want to examine the content of a widget. The browser +shows the value of each keyword, but uses links for certain keywords +such as `:parent', which avoids printing cyclic structures. + +@deffn Command widget-browse WIDGET +Create a widget browser for WIDGET. +When called interactively, prompt for WIDGET. +@end deffn + +@deffn Command widget-browse-other-window WIDGET +Create a widget browser for WIDGET and show it in another window. +When called interactively, prompt for WIDGET. +@end deffn + +@deffn Command widget-browse-at POS +Create a widget browser for the widget at POS. +When called interactively, use the position of point. +@end deffn + +@node Widget Minor Mode, Utilities, Widget Browser, Top @comment node-name, next, previous, up -@section Wishlist. +@section Widget Minor Mode + +There is a minor mode for manipulating widgets in major modes that +doesn't provide any support for widgets themselves. This is mostly +intended to be useful for programmers doing experiments. + +@deffn Command widget-minor-mode +Togle minor mode for traversing widgets. +With arg, turn widget mode on if and only if arg is positive. +@end deffn + +@defvar widget-minor-mode-keymap +Keymap used in @code{widget-minor-mode}. +@end defvar + +@node Utilities, Widget Wishlist, Widget Minor Mode, Top +@comment node-name, next, previous, up +@section Utilities. + +@defun widget-prompt-value widget prompt [ value unbound ] +Prompt for a value matching @var{widget}, using @var{prompt}.@br +The current value is assumed to be @var{value}, unless @var{unbound} is +non-nil.@refill +@end defun + +@defun widget-get-sibling widget +Get the item @var{widget} is assumed to toggle.@br +This is only meaningful for radio buttons or checkboxes in a list. +@end defun + +@node Widget Wishlist, , Utilities, Top +@comment node-name, next, previous, up +@section Wishlist @itemize @bullet @item @@ -1378,57 +1550,43 @@ the ugly buttons, the dash is my idea). @item -Widgets such as @code{file} and @code{symbol} should prompt with completion. - -@item The @code{menu-choice} tag should be prettier, something like the abbreviated menus in Open Look. @item -The functions used in many widgets, like -@code{widget-item-convert-widget}, should not have names that are -specific to the first widget where I happended to use them. - -@item -Flag to make @code{widget-move} skip a specified button. - -@item -Document `helper' functions for defining new widgets. - -@item -Activate the item this is below the mouse when the button is -released, not the item this is below the mouse when the button is -pressed. Dired and grep gets this right. Give feedback if possible. - -@item -Use @samp{@@deffn Widget} to document widgets. - -@item -Document global keywords in one place. - -Document keywords particular to a specific widget in the widget -definition. - -Document the `default' widget first. - -Split, when needed, keywords into those useful for normal -customization, those primarily useful when deriving, and those who -represent runtime information. - -@item -Figure out terminology and @sc{api} for the class/type/object/super -stuff. - -Perhaps the correct model is delegation? - -@item -Document @code{widget-browse}. +Finish @code{:tab-order}. @item Make indentation work with glyphs and propertional fonts. @item -Add object and class hierarchies to the browser. +Add commands to show overview of object and class hierarchies to the +browser. + +@item +Find a way to disable mouse highlight for inactive widgets. + +@item +Find a way to make glyphs look inactive. + +@item +Add @code{property-list} widget. + +@item +Add @code{association-list} widget. + +@item +Add @code{key-binding} widget. + +@item +Add @code{widget} widget for editing widget specifications. + +@item +Find clean way to implement variable length list. +See @code{TeX-printer-list} for an explanation. + +@item +@kbd{C-h} in @code{widget-prompt-value} should give type specific help. @end itemize
--- a/src/ChangeLog Mon Aug 13 09:35:15 2007 +0200 +++ b/src/ChangeLog Mon Aug 13 09:36:16 2007 +0200 @@ -1,3 +1,26 @@ +Sun May 11 13:38:46 1997 Kyle Jones <kyle@crystal.WonderWorks.COM> + + * src/frame.c (change_frame_size_1): + return without doing anything if the frame has benn + initialized and the new frame size is same as the + current frame size. + +Sat May 17 19:35:48 1997 Steven L Baur <steve@altair.xemacs.org> + + * device-tty.c (tty_asynch_device_change): Make + `no-redraw-on-reenter' work. Patch from Hrvoje Niksic. + +Wed Apr 23 16:03:20 1997 Hrvoje Niksic <hniksic@srce.hr> + + * eval.c (skip_debugger): New function. + (signal_call_debugger): Use it. + +Sat May 17 23:39:03 1997 Hrvoje Niksic <hniksic@srce.hr> + + * frame-tty.c: Support multiple frames. + + * redisplay.c (decode_mode_spec): New coding `%N'. + Sun May 11 23:36:08 1997 Steven L Baur <steve@altair.xemacs.org> * buffer.c: Rename Vdelete_auto_save_files to coding standards.
--- a/src/ExternalClient.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/ExternalClient.c Mon Aug 13 09:36:16 2007 +0200 @@ -46,7 +46,7 @@ #include "extw-Xt.h" #ifdef TOOLTALK -#include <tt_c.h> +#include TT_C_H_PATH #endif /* This is the client widget, used to communicate with an ExternalShell
--- a/src/Makefile.in.in Mon Aug 13 09:35:15 2007 +0200 +++ b/src/Makefile.in.in Mon Aug 13 09:36:16 2007 +0200 @@ -32,29 +32,35 @@ #undef NeXT #undef i386 -#ifdef USE_GNU_MAKE /* For performance and consistency, no built-in rules */ .SUFFIXES: -#endif .SUFFIXES: .c .o .i .h dot = . /* On Xenix and the IBM RS6000, double-dot gets screwed up. */ lispdir = ${srcdir}/$(dot)$(dot)/lisp/ libsrc = $(dot)$(dot)/lib-src/ etcdir = $(dot)$(dot)/etc/ -/* This allows you to put the Mule files in a separate location. - Change this if you so desire. */ -muledirfromsrc = $(dot) -MULESRCDIR = ${srcdir}/${muledirfromsrc} /* Here are the things that we expect ../configure to edit. */ srcdir=@srcdir@ CC=@CC@ CPP=@CPP@ CFLAGS=@CFLAGS@ -C_SWITCH_SYSTEM=@c_switch_system@ +CPPFLAGS=@CPPFLAGS@ +LDFLAGS=@LDFLAGS@ + +c_switch_general=@c_switch_general@ +c_switch_window_system=@c_switch_window_system@ +c_switch_all=@c_switch_all@ +ld_switch_general=@ld_switch_general@ +ld_switch_window_system=@ld_switch_window_system@ +ld_switch_all=@ld_switch_all@ +ld_libs_general=@ld_libs_general@ +ld_libs_window_system=@ld_libs_window_system@ +ld_libs_all=@ld_libs_all@ + +extra_objs=@extra_objs@ LN_S=@LN_S@ -native_sound_lib=@native_sound_lib@ /* just to be sure the sh is used */ SHELL=/bin/sh @@ -88,23 +94,6 @@ VPATH=@srcdir@ #endif -#ifdef USE_LCC -/* Why is this here? -# undef LIB_STANDARD -# define LIB_STANDARD -*/ -# define LCCFLAGS -Xa -wucp -XW'[Oo]ld style func dcl' $(ENERGIZEP) -#ifdef NEW_LCC -# define LCCLINK -Xdbx -#else -# define LCCLINK -#endif -# define ORDINARY_LINK -#else -# define LCCFLAGS -# define LCCLINK -#endif - /* On some machines #define register is done in config; do not let it interfere with this file. */ #undef register @@ -114,10 +103,6 @@ MAKE = MAKE_COMMAND #endif -#ifdef C_COMPILER -CC = C_COMPILER -#endif - /* Some machines do not have the standard C libraries in the usual place. */ #ifndef ORDINARY_LINK #ifndef LIB_STANDARD @@ -134,33 +119,6 @@ #define LIBS_DEBUG -lg #endif -/* Some s/*.h files define this to request special libraries. */ -#ifndef LIBS_SYSTEM -#define LIBS_SYSTEM -#endif - -/* Some m/*.h files define this to request special libraries. */ -#ifndef LIBS_MACHINE -#define LIBS_MACHINE -#endif - -#ifndef LIB_MATH -# ifdef LISP_FLOAT_TYPE -# define LIB_MATH -lm -# else /* ! defined (LISP_FLOAT_TYPE) */ -# define LIB_MATH -# endif /* ! defined (LISP_FLOAT_TYPE) */ -#endif /* LIB_MATH */ - -/* Some s/*.h files define this to request special switches in ld. */ -#ifndef LD_SWITCH_SYSTEM -#if !defined (__GNUC__) && (defined(COFF_ENCAPSULATE) || (defined (BSD) && !defined (COFF))) -#define LD_SWITCH_SYSTEM -X -#else /* ! defined(COFF_ENCAPSULATE) || (defined (BSD) && !defined (COFF)) */ -#define LD_SWITCH_SYSTEM -#endif /* ! defined(COFF_ENCAPSULATE) || (defined (BSD) && !defined (COFF)) */ -#endif /* LD_SWITCH_SYSTEM */ - #ifndef LD_SWITCH_CALL_SHARED #define LD_SWITCH_CALL_SHARED #endif /* define a call_shared switch */ @@ -169,56 +127,10 @@ #define LD_SWITCH_SHARED -c #endif /* define a shared switch */ -/* Some m/*.h files define this to request special switches in ld. */ -#ifndef LD_SWITCH_MACHINE -#define LD_SWITCH_MACHINE -#endif - -/* Some m/*.h files define this to request special switches in cc. */ -#ifndef C_SWITCH_MACHINE -#define C_SWITCH_MACHINE -#endif - -/* Some s/*.h files define this to request special switches in cc. */ -#ifndef C_SWITCH_SYSTEM -#define C_SWITCH_SYSTEM -#endif - -/* These macros are for switches specifically related to X Windows. */ -#ifndef C_SWITCH_X_MACHINE -#define C_SWITCH_X_MACHINE -#endif - -#ifndef C_SWITCH_X_SYSTEM -#define C_SWITCH_X_SYSTEM -#endif - -#ifndef C_SWITCH_X_SITE -#define C_SWITCH_X_SITE -#endif - -#ifndef LD_SWITCH_X_SYSTEM -#define LD_SWITCH_X_SYSTEM -#endif - -#ifndef LD_SWITCH_X_SITE -#define LD_SWITCH_X_SITE -#endif - -/* These can be passed in from config.h to define special load and - compile switches needed by individual sites */ -#ifndef LD_SWITCH_SITE -#define LD_SWITCH_SITE -#endif - -#ifndef C_SWITCH_SITE -#define C_SWITCH_SITE -#endif - #ifndef ORDINARY_LINK #ifndef CRT0_COMPILE -#define CRT0_COMPILE $(CC) -c $(ALL_CFLAGS) C_SWITCH_ASM +#define CRT0_COMPILE $(CC) -c $(cflags) C_SWITCH_ASM #endif #ifndef START_FILES @@ -261,394 +173,62 @@ #define C_SWITCH_ASM #endif -ILD=/cadillac1/code/bin.sun4/ild - PURIFY_PROG=purify PURIFY_FLAGS=-chain-length=16 -ignore-signals=SIGPOLL -log-file=puremacs.log \ -messages=batch -show-directory=yes -windows=yes \ -cache-dir=. -always-use-cache-dir=yes -QUANTIFY_PROG=quantify -QUANTIFY_FLAGS=-windows=no -record-data=no PURECOV_PROG=purecov #ifdef QUANTIFY -#define QUANTIFY_INCLUDES -I/local/include -#define QUANTIFY_LIBS /local/lib/quantify_stubs.a -#else -#define QUANTIFY_INCLUDES -#define QUANTIFY_LIBS -#endif - -/* Figure out whether the system cpp can handle long names. - Do it by testing it right now. - If it loses, arrange to use the GNU cpp. */ - -#define LONGNAMEBBBFOOX -#ifdef LONGNAMEBBBARFOOX -/* Installed cpp fails to distinguish those names! */ -/* Arrange to compile the GNU cpp later on */ -#define NEED_CPP -/* Cause cc to invoke the cpp that comes with Emacs, - which will be in a file named localcpp. */ -MYCPPFLAG= -Blocal -/* LOCALCPP is the local one or nothing. - CPP is the local one or the standardone. */ -LOCALCPP= localcpp -#else -MYCPPFLAGS= -LOCALCPP= -#endif /* ! defined (LONGNAMEBBBARFOOX) */ +quantify_prog = quantify +quantify_flags = -windows=no -record-data=no +quantify_includes = -I/local/include +quantify_libs = /local/lib/quantify_stubs.a +#endif /* QUANTIFY */ #ifdef SHORTNAMES SHORT= shortnames -#else -SHORT= #endif #ifdef HAVE_NATIVE_SOUND -# if defined (SOLARIS2) -# define SOUND_CFLAGS C_SWITCH_SITE -I/usr/demo/SOUND/include -# define SOUND_OBJS sunplay.o -# elif defined (SPARC) -# define SOUND_CFLAGS C_SWITCH_SITE -I/usr/demo/SOUND -# define SOUND_OBJS sunplay.o -# elif defined (IRIX4) || defined (IRIX5) || defined (IRIX6) -# define SOUND_CFLAGS -# define SOUND_OBJS sgiplay.o -# elif defined (hp9000s800) -# ifdef USE_GCC -# define SOUND_CFLAGS -Dconst= -Dvolatile= -I/usr/audio/examples -# else /* ! USE_GCC */ -# define SOUND_CFLAGS +e -I/usr/audio/examples -# endif /* USE_GCC */ -# define SOUND_OBJS hpplay.o -# elif defined (LINUX) || defined(__FreeBSD__) || defined (__bsdi__) -# define SOUND_CFLAGS -# define SOUND_OBJS linuxplay.o -# else - ERROR!! HAVE\_NATIVE\_SOUND can only be defined on Solaris, SunOS, SGI, hp9000s800, or FreeBSD, BSD/I, Linux -# endif /* OS */ -#else /* !HAVE_NATIVE_SOUND */ -# define SOUND_CFLAGS -# define SOUND_OBJS -#endif /* ! HAVE_NATIVE_SOUND */ - -#ifdef HAVE_NAS_SOUND -# define NAS_CFLAGS C_SWITCH_SITE -# define NAS_LIBS -laudio -# define NAS_OBJS nas.o -#else -# define NAS_CFLAGS -# define NAS_LIBS -# define NAS_OBJS -#endif /* HAVE_NAS_SOUND */ - -#ifdef ENERGIZE -CONN_DIR=../connection -# define ENERGIZE_INCLUDES -I${I_DIR_PREFIX}${CONN_DIR} -# define ENERGIZE_LDFLAGS -L${CONN_DIR} -# if defined(ENERGIZE_3) -# define ENERGIZE_LIBS -lenergize -# elif defined (ENERGIZE_2) -# define ENERGIZE_LIBS -lconn -# else -# define ENERGIZE_LIBS -lconn -# endif -#else /* !ENERGIZE */ -# define ENERGIZE_INCLUDES -# define ENERGIZE_LDFLAGS -# define ENERGIZE_LIBS -#endif /* !ENERGIZE */ - -#ifdef HAVE_SOCKS -# define SOCKS_LIBS -lsocks -#else /* !HAVE_SOCKS */ -# define SOCKS_LIBS -#endif /* !HAVE_SOCKS */ - -#ifdef HAVE_GIF -# define GIF_OBJS dgif_lib.o gif_err.o gifalloc.o -#else -# define GIF_OBJS +sound_cflags=@sound_cflags@ #endif -#ifdef HAVE_PNG -# ifdef HAVE_PNG_GNUZ -PNG_LIBS = -lpng -lgz -# else -PNG_LIBS = -lpng -lz -# endif -#endif /* HAVE_PNG */ +LWLIB_SRCDIR = ${srcdir}/$(dot)$(dot)/lwlib -#if defined (HAVE_LIBKSTAT) && defined (HAVE_KSTAT_H) -LIB_KSTAT = -lkstat -#endif /* KSTAT */ - -#ifdef HAVE_DATABASE - -# define DATABASE_OBJS database.o +#ifdef HAVE_X_WINDOWS +LWLIB_BUILDDIR = $(dot)$(dot)/lwlib -# if !defined (DATABASE_DBM_LIBS) -# if defined (HAVE_GNU_DBM) && defined (HAVE_LIBGDBM) -# define DATABASE_DBM_LIBS -lgdbm -# elif defined (HAVE_DBM) && defined (HAVE_LIBDBM) -# define DATABASE_DBM_LIBS -ldbm -# else -# define DATABASE_DBM_LIBS -# endif -# endif - -# if !defined (DATABASE_DB_LIBS) -# if defined (HAVE_BERKELEY_DB) && defined (HAVE_LIBDB) -# define DATABASE_DB_LIBS -ldb -# else -# define DATABASE_DB_LIBS -# endif -# endif +LWLIB_LDFLAGS = -L$(LWLIB_BUILDDIR) +LWLIB_LIBS = -llw +LWLIB_CPPFLAGS = -I$(LWLIB_SRCDIR) +LWLIB_DEPS = $(LWLIB_BUILDDIR)/liblw.a -# define DATABASE_LIBS DATABASE_DBM_LIBS DATABASE_DB_LIBS - -#else /* not HAVE_DATABASE */ - -# define DATABASE_OBJS -# define DATABASE_LIBS - -#endif /* not HAVE_DATABASE */ - -#ifdef HAVE_JPEG -JPEG_LIBS = -ljpeg -#endif - -#define NO_GNU_LINKER +x_objs = balloon_help.o balloon-x.o console-x.o device-x.o event-Xt.o frame-x.o \ + glyphs-x.o objects-x.o redisplay-x.o xgccache.o xselect.o -#ifdef DYNODUMP -#ifdef __GNUC__ -#undef NO_GNU_LINKER -#define NO_GNU_LINKER -fno-gnu-linker -#endif -DYNODUMPBUILDDIR = $(dot)$(dot)/dynodump -#define DYNODUMP_DEPS $(DYNODUMPBUILDDIR)/dynodump.so -#else -#define DYNODUMP_DEPS -#endif +#ifdef AIX4 +LIBI18N = -li18n +#endif /* AIX4 */ -#ifdef MULE -#define MULE_INC -I${MULESRCDIR} -#else -#define MULE_INC -#endif - -/* If you want to debug, you can add C_DEBUG_SWITCH to this list. - If you want to optimize, you can add C_OPTIMIZE_SWITCH to the list. */ +X11_libs= $(LIBX11_LIBS) $(libx11_intl) $(LIBI18N) +#endif /* HAVE_X_WINDOWS */ /* -Demacs is needed to make some files produce the correct version - for use in Emacs. - - -DHAVE_CONFIG_H is needed for some other files to take advantage of - the information in "config.h". */ - -/* C_SWITCH_X_SITE must come before C_SWITCH_X_MACHINE and C_SWITCH_X_SYSTEM - since it may have -I options that should override those two. */ + for use in Emacs. */ -CPPFLAGS=-Demacs -DHAVE_CONFIG_H $(MYCPPFLAG) -I. \ - -I${srcdir} MULE_INC LCCFLAGS C_SWITCH_MACHINE C_SWITCH_SYSTEM \ - C_SWITCH_SITE C_SWITCH_X_SITE C_SWITCH_X_MACHINE \ - C_SWITCH_X_SYSTEM $(LIBX11_INCLUDES) QUANTIFY_INCLUDES -ALL_CFLAGS=$(CPPFLAGS) ${CFLAGS} +src_cppflags=-Demacs -I${srcdir} $(LWLIB_CPPFLAGS) $(CPPFLAGS) +cppflags = -I. $(c_switch_all) $(src_cppflags) -#ifdef NEED_XILDOFF -#define XILDOFF -xildoff -#else -#define XILDOFF -#endif +cflags= $(CFLAGS) $(cppflags) -LDFLAGS = LD_SWITCH_SITE LD_SWITCH_X_SITE LD_SWITCH_SYSTEM \ - LD_SWITCH_X_SYSTEM LD_SWITCH_MACHINE \ - -L. $(LIBX11_LDFLAGS) ENERGIZE_LDFLAGS XILDOFF NO_GNU_LINKER +ldflags = $(ld_switch_all) -L. $(no_gnu_linker) $(LWLIB_LDFLAGS) .c.o: - $(CC) -c $(ALL_CFLAGS) $< + $(CC) -c $(cflags) $< /* Create preprocessor output (debugging purposes only) */ .c.i: - $(CC) -P $(CPPFLAGS) $< - - -#ifndef LIBX11_MACHINE -#define LIBX11_MACHINE -#endif - -#ifndef LIBX11_SYSTEM -#define LIBX11_SYSTEM -#endif - -LWLIBSRCDIR = ${srcdir}/$(dot)$(dot)/lwlib - -#ifdef HAVE_X_WINDOWS - -#ifdef HAVE_TOOLBARS -#define TOOLBAR_X_OBJS toolbar-x.o -#else -#define TOOLBAR_X_OBJS -#endif - -#ifdef HAVE_MENUBARS -#define MENUBAR_X_OBJS menubar-x.o -#else -#define MENUBAR_X_OBJS -#endif - -#ifdef HAVE_SCROLLBARS -#define SCROLLBAR_X_OBJS scrollbar-x.o -#else -#define SCROLLBAR_X_OBJS -#endif - -#ifdef HAVE_DIALOGS -#define DIALOG_X_OBJS dialog-x.o -#else -#define DIALOG_X_OBJS -#endif - -#if defined (HAVE_MENUBARS) || defined (HAVE_SCROLLBARS) || defined (HAVE_DIALOGS) || defined (HAVE_TOOLBARS) -#define GUI_X_OBJS gui-x.o -#else -#define GUI_X_OBJS -#endif - -#ifndef HAVE_XIM -#define INPUT_METHOD_X_OBJS input-method-xfs.o -#elif defined(XIM_MOTIF) -#define INPUT_METHOD_X_OBJS input-method-motif.o -#else -#define INPUT_METHOD_X_OBJS input-method-xlib.o -#endif - -#define XOBJS console-x.o device-x.o DIALOG_X_OBJS event-Xt.o frame-x.o \ - glyphs-x.o GUI_X_OBJS MENUBAR_X_OBJS objects-x.o redisplay-x.o \ - SCROLLBAR_X_OBJS TOOLBAR_X_OBJS INPUT_METHOD_X_OBJS xgccache.o \ - xselect.o \ - balloon_help.o -#define BALLOONOBJS balloon-x.o -#ifdef HAVE_XMU -#define XMU_OBJS -XMU_LIB = -lXmu -#else -#define XMU_OBJS xmu.o -#endif - -/* LWLIBSRCDIR is defined above regardless of X being used or not. - This avoids having to conditionalize the dependencies on lwlib.h */ -LWLIBBUILDDIR = $(dot)$(dot)/lwlib - -LIBX11_LDFLAGS = -L$(LWLIBBUILDDIR) -LIBX11_INCLUDES = -I$(LWLIBSRCDIR) - -#ifdef HAVE_XPM -/* Force the Xpm library to be statically linked, always, if at Sun. */ -# ifdef USAGE_TRACKING - XPM_LIBS = -Bstatic -lXpm -Bdynamic -# else - XPM_LIBS = -lXpm -# endif /* at Sun */ -#endif /* HAVE_XPM */ - -#ifdef HAVE_XFACE -XFACE_LIBS = -lcompface -#endif /* HAVE_XFACE */ - -#ifdef USAGE_TRACKING -/* Force the ut library to be statically linked, always. */ -# if defined (SOLARIS2) || defined (SUNOS4) - USAGE_TRACKING_LIBS = -Bstatic -lut -Bdynamic -# else - USAGE_TRACKING_LIBS = -lut -# endif /* SOLARIS2 || SUNOS4 */ -#else -USAGE_TRACKING_LIBS = -#endif /* USAGE_TRACKING */ - - -#ifdef LWLIB_USES_MOTIF -TOOLKIT_LIBS = -lXm -#ifdef LWLIB_USES_ATHENA -TOOLKIT_LIBS = -lXm -lXaw -#endif /* LWLIB_USES_ATHENA */ -#else /* ! LWLIB_USES_MOTIF */ -TOOLKIT_LIBS = -lXaw -#endif /* ! LWLIB_USES_MOTIF */ - -LIBX11_LIBS = -llw $(TOOLKIT_LIBS) $(XPM_LIBS) $(XFACE_LIBS) $(JPEG_LIBS) $(PNG_LIBS) $(USAGE_TRACKING_LIBS) - -#ifdef AIX4 -# define LIBI18N -li18n -#else -# define LIBI18N -#endif /* AIX4 */ - -#if (defined(LINUX) && defined(HAVE_CDE)) -# define LIBX11_INTL -lXintl -#else -# define LIBX11_INTL -#endif - -#ifdef THIS_IS_X11R6 -#ifdef NEED_LIBW -LIBW= -lw -#else -LIBW= -#endif -LIBX= $(LIBX11_LIBS) $(XMU_LIB) -lXt -lSM -lICE $(LIBW) -lXext LIBX11_INTL -lX11 LIBX11_MACHINE LIBX11_SYSTEM LIBI18N -#else -LIBX= $(LIBX11_LIBS) $(XMU_LIB) -lXt -lXext LIBX11_INTL -lX11 LIBX11_MACHINE LIBX11_SYSTEM LIBI18N -#endif - -#else -# define XOBJS -# define XMU_OBJS -# define BALLOONOBJS -#endif /* HAVE_X_WINDOWS */ - -/* We should be able to deal with Canna and Wnn in tty mode once MULE is */ -/* ported to tty, right? */ -#ifdef MULE - -/* We ignore mule-mcpath.o for the moment. */ - -# ifdef HAVE_CANNA -# define CANNA_OBJS mule-canna.o -# define CANNA_OBJ_SRC ${muledirfromsrc}/mule-canna.c -# define LIB_CANNA -lcanna -lRKC -# else -# define CANNA_OBJS -# define CANNA_OBJ_SRC -# define LIB_CANNA -# endif -# ifdef HAVE_WNN -# define WNN_OBJS mule-wnnfns.o -# define WNN_OBJ_SRC ${muledirfromsrc}/mule-wnnfns.c -# define LIB_WNN -lwnn -# else -# define WNN_OBJS -# define WNN_OBJ_SRC -# define LIB_WNN -# endif -/* Chuck says that you have to have at least one specified actual - object file per line. */ -mule_objs= mule.o mule-ccl.o CANNA_OBJS \ - WNN_OBJS mule-charset.o mule-coding.o -mule_obj_src= ${muledirfromsrc}/mule.c \ - ${muledirfromsrc}/mule-ccl.c CANNA_OBJ_SRC \ - WNN_OBJ_SRC ${muledirfromsrc}/mule-charset.c \ - ${muledirfromsrc}/mule-coding.c - -#else /* not MULE */ - -mule_objs= -mule_obj_src= -#define LIB_CANNA -#define LIB_WNN - -#endif /* not MULE */ + $(CC) -P $(cppflags) $< #ifndef ORDINARY_LINK /* Fix linking if compiled with GCC. */ @@ -697,6 +277,13 @@ GNULIB_VAR = #endif /* not ORDINARY_LINK */ +/* A macro which other sections of the makefile can redefine to munge the + flags before they are passed to LD. This is helpful if you have + redefined LD to something odd, like "gcc". */ +#ifndef YMF_PASS_LDFLAGS +#define YMF_PASS_LDFLAGS(flags) flags +#endif + /* Specify address for ld to start loading at, if requested by configuration. */ #ifdef LD_TEXT_START_ADDR @@ -719,13 +306,6 @@ #endif /* ! defined (COFF_ENCAPSULATE) */ #endif /* not ORDINARY_LINK */ -/* A macro which other sections of the makefile can redefine to munge the - flags before they are passed to LD. This is helpful if you have - redefined LD to something odd, like "gcc". */ -#ifndef YMF_PASS_LDFLAGS -#define YMF_PASS_LDFLAGS(flags) flags -#endif - /* Allow config.h to specify a replacement file for unexec.c. */ #ifndef UNEXEC #define UNEXEC unexec.o @@ -736,167 +316,58 @@ #ifdef ENERGIZE # ifdef EMACS_BTL - BTLDIR=$(srcdir)/../btl -# define BTLOBJS cadillac-btl.o cadillac-btl-process.o cadillac-btl-asm.o \ - cadillac-btl-emacs.o -# else -# define BTLOBJS -# endif /* BTL */ +BTL_dir=$(srcdir)/../btl +BTL_objs = cadillac-btl.o cadillac-btl-process.o cadillac-btl-asm.o cadillac-btl-emacs.o +# endif /* EMACS_BTL */ # if defined(FREE_CHECKING) || defined(DEBUG_INPUT_BLOCKING) || defined(DEBUG_GCPRO) -# define FREECHECKOBJS free-hook.o -# else /* !FREE */ -# define FREECHECKOBJS -# endif /* !FREE */ -# define ENERGIZE_OBJS energize.o FREECHECKOBJS -#else /* !ENERGIZE */ -# define ENERGIZE_OBJS -# define BTLOBJS -#endif /* !ENERGIZE */ - -#ifdef HAVE_REALPATH -#define REALPATH_OBJS -#else -#define REALPATH_OBJS realpath.o -#endif - -#ifdef TOOLTALK -# define TOOLTALK_OBJS tooltalk.o -# if (defined (IRIX5) || defined (HPUX) || defined (POWERPC) || defined (AIX4) || defined (LINUX) || (defined (OSF1) && defined (DEC_ALPHA))) -# define LIB_TOOLTALK -ltt -# else -# if (defined (SPARC) && !defined (USG)) -# define LIB_TOOLTALK -ltt -lI18N -# else -# if ((defined (SPARC) || defined(INTEL386)) && defined (USG)) -# define LIB_TOOLTALK -ltt -lce -# else -# undef TOOLTALK -# define TOOLTALK_OBJS -# define LIB_TOOLTALK -# endif /* ((SPARC || INTEL386) && USG) */ -# endif /* ! (SPARC && !USG) */ -# endif /* !IRIX5 */ -#else /* !TOOLTALK */ -# define TOOLTALK_OBJS -# define LIB_TOOLTALK -#endif /* !TOOLTALK */ - -#ifdef HAVE_CDE -# if (defined (OSF1) && defined (DEC_ALPHA)) -# define LIB_CDE -lDtSvc -ltt -lcxx -# else -# define LIB_CDE -lDtSvc -ltt -# endif /* (defined (OSF1) && defined (DEC_ALPHA)) */ -#else -# define LIB_CDE -#endif - -#ifdef HAVE_OFFIX_DND -# define LIB_OFFIX_DND -lDnd -#else -# define LIB_OFFIX_DND -#endif - -#if (defined(LIB_INTL) && (!(defined(I18N3) || defined(I18N4)))) - /* this should be defined by s- files, but we should not use it unless - I18N3 or I18N4 are defined. */ -# undef LIB_INTL -#endif - -#ifndef LIB_INTL -# define LIB_INTL -#endif +freecheck_objs = free-hook.o +# endif /* FREE */ +energize_objs = energize.o $(freecheck_objs) +#endif /* ENERGIZE */ #ifdef MOCKLISP_SUPPORT -# define MOCKLISPOBJS mocklisp.o -#else -# define MOCKLISPOBJS -#endif - -#ifdef DEBUG_XEMACS -# define DEBUG_OBJS debug.o -#else -# define DEBUG_OBJS -#endif - -#ifdef SUNPRO -# define SUNPRO_OBJS sunpro.o -#else -# define SUNPRO_OBJS +mocklisp_objs = mocklisp.o #endif #ifdef HAVE_TTY -#define TTY_OBJS console-tty.o device-tty.o event-tty.o frame-tty.o \ +tty_objs = console-tty.o device-tty.o event-tty.o frame-tty.o \ objects-tty.o redisplay-tty.o cm.o -#else -#define TTY_OBJS -#endif - -#ifdef HAVE_TOOLBARS -#define TOOLBAR_OBJS toolbar.o -#else -#define TOOLBAR_OBJS -#endif -#ifdef HAVE_MENUBARS -#define MENUBAR_OBJS menubar.o -#else -#define MENUBAR_OBJS -#endif -#ifdef HAVE_SCROLLBARS -#define SCROLLBAR_OBJS scrollbar.o -#else -#define SCROLLBAR_OBJS -#endif -#ifdef HAVE_DIALOGS -#define DIALOG_OBJS dialog.o -#else -#define DIALOG_OBJS -#endif -#if defined (HAVE_MENUBARS) || defined (HAVE_SCROLLBARS) || defined (HAVE_DIALOGS) || defined (HAVE_TOOLBARS) -#define GUI_OBJS gui.o -#else -#define GUI_OBJS #endif #ifdef HAVE_UNIXOID_EVENT_LOOP -#define EVENT_UNIXOID_OBJS event-unixoid.o -#else -#define EVENT_UNIXOID_OBJS +event_unixoid_objs = event-unixoid.o #endif /* lastfile must follow all files whose initialized data areas should - be dumped as pure by dump-emacs. - */ + be dumped as pure by dump-emacs. */ /* NOTE: The last line cannot be all macros, because make will barf if they all come out null. */ -objs= abbrev.o alloc.o blocktype.o buffer.o bytecode.o \ - callint.o callproc.o casefiddle.o casetab.o chartab.o cmdloop.o \ - cmds.o console.o console-stream.o \ - data.o DATABASE_OBJS DEBUG_OBJS device.o DIALOG_OBJS dired.o doc.o \ - doprnt.o dynarr.o \ - editfns.o elhash.o emacs.o ENERGIZE_OBJS eval.o events.o \ - event-stream.o EVENT_UNIXOID_OBJS extents.o \ - faces.o fileio.o filelock.o filemode.o floatfns.o fns.o font-lock.o \ - frame.o \ - general.o getloadavg.o GIF_OBJS glyphs.o GUI_OBJS \ - hash.o \ - indent.o inline.o insdel.o intl.o \ - keymap.o $(RTC_PATCH_O) \ - lread.o lstream.o \ - macros.o marker.o md5.o MENUBAR_OBJS minibuf.o MOCKLISPOBJS \ - NAS_OBJS \ +objs = abbrev.o alloc.o blocktype.o buffer.o bytecode.o \ + callint.o callproc.o casefiddle.o casetab.o chartab.o \ + cmdloop.o cmds.o console.o console-stream.o data.o \ + device.o dired.o \ + doc.o doprnt.o dynarr.o editfns.o elhash.o emacs.o \ + $(energize_objs) eval.o events.o $(extra_objs) \ + event-stream.o $(event_unixoid_objs) extents.o faces.o \ + fileio.o filelock.o filemode.o floatfns.o fns.o font-lock.o \ + frame.o general.o getloadavg.o glyphs.o \ + $(gui_objs) hash.o indent.o inline.o insdel.o intl.o \ + keymap.o $(RTC_patch_objs) lread.o lstream.o macros.o \ + marker.o md5.o minibuf.o $(mocklisp_objs) \ objects.o opaque.o \ - print.o process.o profile.o pure.o \ - rangetab.o REALPATH_OBJS redisplay.o redisplay-output.o regex.o \ - SCROLLBAR_OBJS search.o signal.o sound.o SOUND_OBJS specifier.o \ - strftime.o SUNPRO_OBJS symbols.o syntax.o sysdep.o \ - TOOLBAR_OBJS TOOLTALK_OBJS TTY_OBJS \ - undo.o UNEXEC \ - XOBJS XMU_OBJS BALLOONOBJS \ - window.o + print.o process.o profile.o pure.o rangetab.o \ + redisplay.o redisplay-output.o regex.o \ + search.o signal.o sound.o \ + specifier.o strftime.o symbols.o syntax.o \ + sysdep.o $(tty_objs) undo.o \ + UNEXEC $(x_objs) window.o +/* The following is being done in configure.in now - mrb */ +#undef LIBS_TERMCAP +#define LIBS_TERMCAP +#if 0 #ifdef HAVE_TTY # ifdef HAVE_NCURSES /* If your machine needs -ltermcap, define LIBS_TERMCAP to include @@ -925,14 +396,11 @@ # undef LIBS_TERMCAP # define LIBS_TERMCAP #endif /* !HAVE_TTY */ - +#endif /* 0 */ #ifdef REL_ALLOC +rallocdocsrc = ralloc.c rallocobjs = ralloc.o -rallocdocsrc = ralloc.c -#else -rallocobjs = -rallocdocsrc = #endif #ifndef SYSTEM_MALLOC @@ -940,29 +408,23 @@ # ifdef ERROR_CHECK_MALLOC mallocobjs = gmalloc.o free-hook.o vm-limit.o mallocdocsrc = free-hook.c -# else +# else /* New GNU malloc, sans error checking */ mallocobjs = gmalloc.o vm-limit.o mallocdocsrc = -# endif +# endif /* ERROR_CHECK_MALLOC */ # else /* Old GNU malloc */ mallocobjs = malloc.o mallocdocsrc = # endif /* Old GNU malloc */ -#else +#else /* SYSTEM_MALLOC */ mallocobjs = mallocdocsrc = #endif /* SYSTEM_MALLOC */ -#ifdef FORCE_ALLOCA_H -allocaobjs = alloca.o -#else /* !FORCE_ALLOCA_H */ -allocaobjs = @ALLOCA@ -#endif /* !FORCE_ALLOCA_H */ - #ifdef HAVE_X_WINDOWS # ifdef EXTERNAL_WIDGET -# define EXTERNAL_WIDGET_OBJS ExternalShell.o extw-Xt-nonshared.o extw-Xlib-nonshared.o +external_widget_objs = ExternalShell.o extw-Xt-nonshared.o extw-Xlib-nonshared.o /* Now we try to figure out how to link a shared library. If we cannot figure it out, leave EXTW_LINK undefined and a shared @@ -983,7 +445,7 @@ # endif /* not IRIX */ # else /* not USG5 */ # if defined (DEC_ALPHA) && defined (OSF1) -# define EXTW_LINK(objs, output) $(LD) $(LDFLAGS) LD_SWITCH_SHARED -d objs -o output $(LIBES) +# define EXTW_LINK(objs, output) $(LD) $(ldflags) LD_SWITCH_SHARED -d objs -o output $(LIBES) # else /* !(DEC_ALPHA && OSF1) */ # define EXTW_LINK(objs, output) $(LD) -dc objs -assert pure-text -o output # endif /* !(DEC_ALPHA && OSF1) */ @@ -1007,21 +469,14 @@ # define OTHER_FILES MOTIF_OTHER_FILES \ libextcli_Xt.a libextcli_Xlib.a # endif -# else /* !EXTERNAL_WIDGET */ -# define EXTERNAL_WIDGET_OBJS -# endif /* !EXTERNAL_WIDGET */ +# endif /* EXTERNAL_WIDGET */ -# define LIBX11_OBJS EmacsFrame.o EmacsShell.o TopLevelEmacsShell.o TransientEmacsShell.o EmacsManager.o EXTERNAL_WIDGET_OBJS -# define LWLIB_DEPS $(LWLIBBUILDDIR)/liblw.a - -#else /* !X */ -# define LIBX11_OBJS -# define LWLIB_DEPS -#endif +X11_objs = EmacsFrame.o EmacsShell.o TopLevelEmacsShell.o TransientEmacsShell.o EmacsManager.o $(external_widget_objs) +#endif /* HAVE_X_WINDOWS */ /* define otherobjs as list of object files that make-docfile should not be told about. */ -otherobjs= $(termcapobjs) BTLOBJS lastfile.o $(mallocobjs) $(rallocobjs) $(allocaobjs) LIBX11_OBJS +otherobjs = $(termcapobjs) $(BTL_objs) lastfile.o $(mallocobjs) $(rallocobjs) $(X11_objs) #ifdef LISP_FLOAT_TYPE #define FLOAT_LISP ${lispdir}prim/float-sup.elc @@ -1246,12 +701,9 @@ ${lispdir}bytecomp/byte-optimize.elc \ ${lispdir}utils/advice.elc -LIBES = NAS_LIBS ${native_sound_lib} SOCKS_LIBS ENERGIZE_LIBS LIB_CDE LIB_OFFIX_DND \ - LIB_TOOLTALK $(LIBX) \ - LIBS_SYSTEM LIBS_MACHINE LIBS_TERMCAP \ - LIB_CANNA LIB_WNN LIB_INTL QUANTIFY_LIBS $(LIB_KSTAT) \ - DATABASE_LIBS LIBS_DEBUG $(GNULIB_VAR) LIB_MATH LIB_STANDARD \ - $(GNULIB_VAR) +LIBES = $(LWLIB_LIBS) $(energize_libs) $(quantify_libs) \ + LIBS_DEBUG $(GNULIB_VAR) LIB_STANDARD \ + $(GNULIB_VAR) $(ld_libs_all) /* Enable recompilation of certain other files depending on system type. */ @@ -1270,20 +722,15 @@ all: xemacs OTHER_FILES -/* "make release" to build "xemacs" with an incremented version number; - "make xemacs" to just build "xemacs" without incrementing the version. */ - #ifdef I18N3 -modir = ${etcdir} -# define MOFILE ${modir}emacs.mo -#else -# define MOFILE +mo_dir = ${etcdir} +mo_file = ${mo_dir}emacs.mo #endif LOADPATH = EMACSLOADPATH="${lispdir}prim" DUMPENV = $(LOADPATH) -release: temacs ${lisp} ${libsrc}DOC MOFILE OTHER_FILES +release: temacs ${lisp} ${libsrc}DOC $(mo_file) OTHER_FILES #ifdef CANNOT_DUMP ln temacs xemacs #else @@ -1311,7 +758,7 @@ touch release #endif /* ! defined (CANNOT_DUMP) */ -xemacs: temacs ${libsrc}DOC ${lisp} MOFILE OTHER_FILES +xemacs: temacs ${libsrc}DOC ${lisp} $(mo_file) OTHER_FILES @touch SATISFIED -$(DUMPENV) ./temacs -batch -l loadup.el dump @if [ ! -f SATISFIED ]; then \ @@ -1319,30 +766,29 @@ fi @/bin/rm -f SATISFIED -xemacs-no-site-file: temacs ${libsrc}DOC ${lisp} MOFILE OTHER_FILES +xemacs-no-site-file: temacs ${libsrc}DOC ${lisp} $(mo_file) OTHER_FILES @touch SATISFIED -$(DUMPENV) ./temacs -batch -l loadup.el dump no-site-file - @if [ ! -f SATISFIED ]; then \ - $(MAKE) xemacs-no-site-file; \ - fi + @test ! -f SATISFIED && $(MAKE) xemacs-no-site-file @/bin/rm -f SATISFIED obj_src = $(objs:.o=.c) #ifdef DYNODUMP -$(DYNODUMPBUILDDIR)/dynodump.so: force - cd ${DYNODUMPBUILDDIR} && ${MAKE} ${MFLAGS} -#endif +dynodump_builddir = $(dot)$(dot)/dynodump +dynodump_deps = $(dynodump_builddir)/dynodump.so +$(dynodump_builddir)/dynodump.so: force + cd ${dynodump_builddir} && ${MAKE} ${MFLAGS} +#endif /* DYNODUMP */ #ifdef NO_DOC_FILE ${libsrc}DOC: ${libsrc}make-docfile #else -${libsrc}DOC: ${libsrc}make-docfile ${obj_src} ${mule_obj_src} ${lisp} +${libsrc}DOC: ${libsrc}make-docfile ${obj_src} ${lisp} #endif rm -f ${libsrc}DOC ${libsrc}make-docfile -d ${srcdir} -i ${libsrc}../site-packages \ - ${obj_src} ${mule_obj_src} \ - ${mallocdocsrc} ${rallocdocsrc} ${lispdir}version.el \ + ${obj_src} ${mallocdocsrc} ${rallocdocsrc} ${lispdir}version.el \ ${lisp} > ${libsrc}DOC dump_elcs: dump-elcs @@ -1370,14 +816,14 @@ msgfmt= msgfmt #endif -${modir}emacs.po: ${libsrc}make-msgfile ${libsrc}make-po ${objs} ${mule_objs} ${lisp} - ${libsrc}make-msgfile -o ${libsrc}messages ${objs} ${mule_objs} ${lisp} ${otherlisp} +${mo_dir}emacs.po: ${libsrc}make-msgfile ${libsrc}make-po ${objs} ${lisp} + ${libsrc}make-msgfile -o ${libsrc}messages ${objs} ${lisp} ${otherlisp} cd ${libsrc} && ${xgettext} ${xgettext_args} - rm -f ${modir}emacs.po - cd ${libsrc} && ${libsrc}make-po -a ${modir}emacs.po DOC + rm -f ${mo_dir}emacs.po + cd ${libsrc} && ${libsrc}make-po -a ${mo_dir}emacs.po DOC -${modir}emacs.mo: ${modir}emacs.po - cd ${modir} && ${msgfmt} -o emacs.mo emacs.po +${mo_dir}emacs.mo: ${mo_dir}emacs.po + cd ${mo_dir} && ${msgfmt} -o emacs.mo emacs.po ${libsrc}make-msgfile: cd ${libsrc} && ${MAKE} ${MFLAGS} make-msgfile @@ -1393,10 +839,7 @@ /* Lint Section */ LINT.c=$(LINT) $(LINTFLAGS) $(LINTINCLUDES) LINTFILES= $(objs:.o=.ln) -LINTINCLUDES = -Demacs -DHAVE_CONFIG_H $(MYCPPFLAG) -I. \ - -I${srcdir} LCCFLAGS C_SWITCH_MACHINE C_SWITCH_SYSTEM \ - C_SWITCH_SITE C_SWITCH_X_SITE C_SWITCH_X_MACHINE \ - C_SWITCH_X_SYSTEM $(LIBX11_INCLUDES) +LINTINCLUDES = $(cppflags) /* LINTFLAGS= -fd -m -p -s -u -v -x */ LINTFLAGS= -fd -m -s -u -v -x lint: $(LINTFILES) @@ -1404,36 +847,37 @@ /* end of Lint Section */ force: -$(LWLIBBUILDDIR)/liblw.a: force - cd ${LWLIBBUILDDIR} && ${MAKE} ${MFLAGS} +$(LWLIB_BUILDDIR)/liblw.a: force + cd ${LWLIB_BUILDDIR} && ${MAKE} ${MFLAGS} /* Some systems define this to cause parallel Make-ing. */ #ifndef MAKE_PARALLEL #define MAKE_PARALLEL #endif -#define TEMACS_DEPS MAKE_PARALLEL $(LOCALCPP) $(SHORT) $(STARTFILES) \ - ${objs} ${mule_objs} ${otherobjs} OBJECTS_SYSTEM \ - OBJECTS_MACHINE LWLIB_DEPS DYNODUMP_DEPS prefix-args +temacs_deps = \ + MAKE_PARALLEL $(LOCALCPP) $(SHORT) $(STARTFILES) \ + ${objs} ${otherobjs} OBJECTS_SYSTEM OBJECTS_MACHINE \ + $(LWLIB_DEPS) $(dynodump_deps) prefix-args -#define TEMACS_LINK_ARGS YMF_PASS_LDFLAGS \ - (${STARTFLAGS} ${LDFLAGS} LD_SWITCH_CALL_SHARED) -o $@ \ - ${STARTFILES} ${objs} ${mule_objs} ${otherobjs} OBJECTS_SYSTEM \ - OBJECTS_MACHINE ${LIBES} +temacs_link_args = \ + YMF_PASS_LDFLAGS(${STARTFLAGS} ${ldflags} LD_SWITCH_CALL_SHARED) \ + -o $@ ${STARTFILES} ${objs} ${otherobjs} \ + OBJECTS_SYSTEM OBJECTS_MACHINE ${LIBES} -temacs_deps: TEMACS_DEPS +temacs_deps: $(temacs_deps) -temacs: TEMACS_DEPS - $(LD) LCCLINK TEMACS_LINK_ARGS +temacs: $(temacs_deps) + $(LD) $(temacs_link_args) -cemacs: TEMACS_DEPS - $(LD) $(ENERGIZEP) TEMACS_LINK_ARGS +cemacs: $(temacs_deps) + $(LD) $(temacs_link_args) rtc_patch.o: rtc_patch_area -o $@ -rtcmacs: TEMACS_DEPS rtc_patch.o - rm -f temacs; $(MAKE) $(MAKE_FLAGS) temacs RTC_PATCH_O=rtc_patch.o +rtcmacs: $(temacs_deps) rtc_patch.o + rm -f temacs; $(MAKE) $(MAKE_FLAGS) temacs RTC_patch_objs=rtc_patch.o mv temacs rtcmacs rtcrun: rtcmacs @@ -1446,35 +890,34 @@ runargs -batch -l loadup.el run-temacs -q; \ run' rtcmacs -puremacs: TEMACS_DEPS - $(PURIFY_PROG) $(PURIFY_FLAGS) $(LD) TEMACS_LINK_ARGS +puremacs: $(temacs_deps) + $(PURIFY_PROG) $(PURIFY_FLAGS) $(LD) $(temacs_link_args) -quantmacs: TEMACS_DEPS - $(QUANTIFY_PROG) $(QUANTIFY_FLAGS) $(LD) TEMACS_LINK_ARGS +quantmacs: $(temacs_deps) + $(quantify_prog) $(quantify_flags) $(LD) $(temacs_link_args) -covmacs: TEMACS_DEPS - $(PURECOV_PROG) $(LD) TEMACS_LINK_ARGS +covmacs: $(temacs_deps) + $(PURECOV_PROG) $(LD) $(temacs_link_args) TopLevelEmacsShell.o : ${srcdir}/EmacsShell-sub.c - $(CC) -c $(ALL_CFLAGS) -DDEFINE_TOP_LEVEL_EMACS_SHELL ${srcdir}/EmacsShell-sub.c + $(CC) -c $(cflags) -DDEFINE_TOP_LEVEL_EMACS_SHELL ${srcdir}/EmacsShell-sub.c mv EmacsShell-sub.o TopLevelEmacsShell.o TransientEmacsShell.o : ${srcdir}/EmacsShell-sub.c TopLevelEmacsShell.o - $(CC) -c $(ALL_CFLAGS) -DDEFINE_TRANSIENT_EMACS_SHELL ${srcdir}/EmacsShell-sub.c + $(CC) -c $(cflags) -DDEFINE_TRANSIENT_EMACS_SHELL ${srcdir}/EmacsShell-sub.c mv EmacsShell-sub.o TransientEmacsShell.o +/* Position-independent code for shared library creation */ +#if USE_GCC +pic_arg = -fpic +#elif defined (IRIX) +pic_arg = -KPIC +# else +pic_arg = -K pic +#endif + #ifdef EXTERNAL_WIDGET -#if USE_GCC -# define PIC_ARG -fpic -#else -# ifdef IRIX -# define PIC_ARG -KPIC -# else -# define PIC_ARG -K pic -# endif -#endif - # define EXTERNAL_CLIENT_MOTIF_OBJS_SHARED ExternalClient-Xm-shared.o extw-Xt-shared.o extw-Xlib-shared.o # define EXTERNAL_CLIENT_XT_OBJS_SHARED ExternalClient-Xt-shared.o extw-Xt-shared.o extw-Xlib-shared.o # define EXTERNAL_CLIENT_XLIB_OBJS_SHARED ExternalClient-Xlib-shared.o extw-Xlib-shared.o @@ -1484,46 +927,46 @@ /* Add dependencies so things work right with a parallel make */ ExternalClient-Xm-shared.o: ${srcdir}/ExternalClient.c ExternalClient-Xt-shared.o ExternalClient-Xm-nonshared.o - $(CC) -c PIC_ARG $(ALL_CFLAGS) -DEXTW_USES_MOTIF ${srcdir}/ExternalClient.c + $(CC) -c $(pic_arg) $(cflags) -DEXTW_USES_MOTIF ${srcdir}/ExternalClient.c mv ExternalClient.o ExternalClient-Xm-shared.o ExternalClient-Xt-shared.o: ${srcdir}/ExternalClient.c ExternalClient-Xt-nonshared.o - $(CC) -c PIC_ARG $(ALL_CFLAGS) ${srcdir}/ExternalClient.c + $(CC) -c $(pic_arg) $(cflags) ${srcdir}/ExternalClient.c mv ExternalClient.o ExternalClient-Xt-shared.o ExternalClient-Xlib-shared.o: ${srcdir}/ExternalClient-Xlib.c ExternalClient-Xlib-nonshared.o - $(CC) -c PIC_ARG $(ALL_CFLAGS) ${srcdir}/ExternalClient-Xlib.c + $(CC) -c $(pic_arg) $(cflags) ${srcdir}/ExternalClient-Xlib.c mv ExternalClient-Xlib.o ExternalClient-Xlib-shared.o ExternalClient-Xm-nonshared.o: ${srcdir}/ExternalClient.c ExternalClient-Xt-nonshared.o - $(CC) -c $(ALL_CFLAGS) -DEXTW_USES_MOTIF ${srcdir}/ExternalClient.c + $(CC) -c $(cflags) -DEXTW_USES_MOTIF ${srcdir}/ExternalClient.c mv ExternalClient.o ExternalClient-Xm-nonshared.o ExternalClient-Xt-nonshared.o: ${srcdir}/ExternalClient.c - $(CC) -c $(ALL_CFLAGS) ${srcdir}/ExternalClient.c + $(CC) -c $(cflags) ${srcdir}/ExternalClient.c mv ExternalClient.o ExternalClient-Xt-nonshared.o ExternalClient-Xlib-nonshared.o: ${srcdir}/ExternalClient-Xlib.c - $(CC) -c $(ALL_CFLAGS) ${srcdir}/ExternalClient-Xlib.c + $(CC) -c $(cflags) ${srcdir}/ExternalClient-Xlib.c mv ExternalClient-Xlib.o ExternalClient-Xlib-nonshared.o /* We compile the common files twice (once with PIC and once without) because on some systems, compiling with PIC but not linking into a shared library messes things up. */ extw-Xt-shared.o: ${srcdir}/extw-Xt.c extw-Xt-nonshared.o - $(CC) -c PIC_ARG $(ALL_CFLAGS) ${srcdir}/extw-Xt.c + $(CC) -c $(pic_arg) $(cflags) ${srcdir}/extw-Xt.c mv extw-Xt.o extw-Xt-shared.o extw-Xlib-shared.o: ${srcdir}/extw-Xlib.c extw-Xlib-nonshared.o - $(CC) -c PIC_ARG $(ALL_CFLAGS) ${srcdir}/extw-Xlib.c + $(CC) -c $(pic_arg) $(cflags) ${srcdir}/extw-Xlib.c mv extw-Xlib.o extw-Xlib-shared.o extw-Xt-nonshared.o: ${srcdir}/extw-Xt.c - $(CC) -c $(ALL_CFLAGS) ${srcdir}/extw-Xt.c + $(CC) -c $(cflags) ${srcdir}/extw-Xt.c mv extw-Xt.o extw-Xt-nonshared.o extw-Xlib-nonshared.o: ${srcdir}/extw-Xlib.c - $(CC) -c $(ALL_CFLAGS) ${srcdir}/extw-Xlib.c + $(CC) -c $(cflags) ${srcdir}/extw-Xlib.c mv extw-Xlib.o extw-Xlib-nonshared.o libextcli_Xm.a: EXTERNAL_CLIENT_MOTIF_OBJS_NONSHARED @@ -1546,19 +989,19 @@ libextcli_Xlib.so.1: EXTERNAL_CLIENT_XLIB_OBJS_SHARED EXTW_LINK(EXTERNAL_CLIENT_XLIB_OBJS_SHARED, libextcli_Xlib.so.1) -#endif +#endif /* EXTW_LINK */ #endif /* EXTERNAL_WIDGET */ prefix-args: ${srcdir}/prefix-args.c config.h - $(CC) $(ALL_CFLAGS) ${srcdir}/prefix-args.c -o prefix-args + $(CC) $(cflags) ${srcdir}/prefix-args.c -o prefix-args /* These are needed for C compilation, on the systems that need them */ #ifdef NEED_CPP CPP = ./localcpp localcpp: cd ${cppdir} && ${MAKE} ${MFLAGS} EMACS=-DEMACS - ln ${cppdir}cpp localcpp /* Name where ALL_CFLAGS will refer to it */ + ln ${cppdir}cpp localcpp /* Name where cflags will refer to it */ /* cc appears to be cretinous and require all of these to exist if -B is specified -- we cannot use one local pass and let the others be the standard ones. What a loser. @@ -1614,8 +1057,7 @@ whenever emacs was #defined, but that's not appropriate for all users of alloca in Emacs. Check out ../lib-src/getopt.c. */ alloca.o : ${srcdir}/alloca.c - $(CC) -c $(CPPFLAGS) -Dfree=xfree -Dmalloc=xmalloc \ - $(ALL_CFLAGS) $< + $(CC) -c -Dfree=xfree -Dmalloc=xmalloc $(cflags) $< #else #ifndef HAVE_ALLOCA alloca.o : ${srcdir}/alloca.s config.h @@ -1626,7 +1068,7 @@ since some assemblers barf on them. Use a different basename for the output file, since some stupid compilers (Green Hill) use that name for the intermediate assembler file. */ - $(CPP) $(CPPFLAGS) $(ALL_CFLAGS) allocatem.c | \ + $(CPP) $(cppflags) allocatem.c | \ sed -e 's///' -e 's/^#.*//' | \ sed -n -e '/^..*$$/p' > allocax.s -rm -f alloca.o @@ -1637,71 +1079,32 @@ #endif /* HAVE_ALLOCA */ #endif /* ! defined (C_ALLOCA) */ -#ifdef USE_LCC /* lcc doesn't do asm() yet */ -ecrt0.o: ${srcdir}/ecrt0.c - gcc -c -g -Demacs $< -#endif /* USE_LCC */ - #ifdef EMACS_BTL -BTL_INCLUDES=-I$(BTLDIR) -# define BTL_COMPILE \ - -DEMACS_BTL -D`lucid-arch` -I. $(BTL_INCLUDES) $(BTLDIR)/$(@:.o=.c) +BTL_includes = -I$(BTL_dir) +BTL_compile = -DEMACS_BTL -D`lucid-arch` -I. $(BTL_includes) $(BTL_dir)/$(@:.o=.c) cadillac-btl.o cadillac-btl-process.o cadillac-btl-emacs.o: - $(CC) $(CFLAGS) -c BTL_COMPILE -# ifndef USE_LCC + $(CC) $(CFLAGS) -c $(BTL_compile) cadillac-btl-asm.o: - $(CC) $(CFLAGS) -c BTL_COMPILE -# else /* lcc doesn't do asm() yet */ -cadillac-btl-asm.o: - gcc -O -g -c BTL_COMPILE -# endif /* lcc */ + $(CC) $(CFLAGS) -c $(BTL_compile) #endif /* EMACS_BTL */ #ifdef ENERGIZE energize.o: ${srcdir}/energize.c - $(CC) -c $(CPPFLAGS) $(ALL_CFLAGS) ENERGIZE_INCLUDES $(BTL_INCLUDES) $< + $(CC) -c $(cppflags) $(cflags) $(BTL_includes) $< #endif /* ENERGIZE */ #ifdef HAVE_NATIVE_SOUND -# if defined (SUNOS4) || defined (SOLARIS2) sunplay.o: ${srcdir}/sunplay.c - $(CC) -c $(ALL_CFLAGS) SOUND_CFLAGS $< -# endif /* SUNOS4 or SOLARIS2 */ -# ifdef hp9000s800 + $(CC) -c $(sound_cflags) $(cflags) $< hpplay.o: ${srcdir}/hpplay.c - $(CC) -c -Demacs $(ALL_CFLAGS) SOUND_CFLAGS $< -# endif /* hp9000s800 */ + $(CC) -c -Demacs $(sound_cflags) $(cflags) $< #endif /* HAVE_NATIVE_SOUND */ -#ifdef HAVE_NAS_SOUND -nas.o: ${srcdir}/nas.c - $(CC) -c $(ALL_CFLAGS) NAS_CFLAGS $< -#endif /* HAVE_NAS_SOUND */ - -#ifdef MULE - -mule-canna.o: ${MULESRCDIR}/mule-canna.c - $(CC) -c $(ALL_CFLAGS) ${MULESRCDIR}/mule-canna.c -mule-wnnfns.o: ${MULESRCDIR}/mule-wnnfns.c - $(CC) -c $(ALL_CFLAGS) ${MULESRCDIR}/mule-wnnfns.c -mule.o: ${MULESRCDIR}/mule.c - $(CC) -c $(ALL_CFLAGS) ${MULESRCDIR}/mule.c -mule-ccl.o: ${MULESRCDIR}/mule-ccl.c - $(CC) -c $(ALL_CFLAGS) ${MULESRCDIR}/mule-ccl.c -mule-charset.o: ${MULESRCDIR}/mule-charset.c - $(CC) -c $(ALL_CFLAGS) ${MULESRCDIR}/mule-charset.c -mule-coding.o: ${MULESRCDIR}/mule-coding.c - $(CC) -c $(ALL_CFLAGS) ${MULESRCDIR}/mule-coding.c - -#endif - /* System-specific programs to be made. OTHER_FILES, OBJECTS_SYSTEM and OBJECTS_MACHINE select which of these should be compiled. */ -${libsrc}emacstool: ${libsrc}emacstool.c - cd ${libsrc} && ${MAKE} ${MFLAGS} emacstool mostlyclean: rm -f temacs puremacs quantmacs prefix-args xmakefile* core depend.* \#* *.o rm -f ${libsrc}DOC @@ -1733,31 +1136,11 @@ /*** Dependency processing using GCC ***/ .c.dep: - $(CC) -MM $(ALL_CFLAGS) $< > $*.dep + $(CC) -MM $(cflags) $< > $*.dep .SUFFIXES: .dep obj_dep = $(objs:.o=.dep) -mule_obj_dep = $(mule_objs:.o=.dep) - -#ifdef MULE - -/* Ugh, there should be a better way of handling this. */ - -mule-canna.dep: ${MULESRCDIR}/mule-canna.c - $(CC) -MM $(ALL_CFLAGS) ${MULESRCDIR}/mule-canna.c > mule-canna.dep -mule-wnnfns.dep: ${MULESRCDIR}/mule-wnnfns.c - $(CC) -MM $(ALL_CFLAGS) ${MULESRCDIR}/mule-wnnfns.c > mule-wnnfns.dep -mule.dep: ${MULESRCDIR}/mule.c - $(CC) -MM $(ALL_CFLAGS) ${MULESRCDIR}/mule.c > mule.dep -mule-ccl.dep: ${MULESRCDIR}/mule-ccl.c - $(CC) -MM $(ALL_CFLAGS) ${MULESRCDIR}/mule-ccl.c > mule-ccl.dep -mule-charset.dep: ${MULESRCDIR}/mule-charset.c - $(CC) -MM $(ALL_CFLAGS) ${MULESRCDIR}/mule-charset.c > mule-charset.dep -mule-coding.dep: ${MULESRCDIR}/mule-coding.c - $(CC) -MM $(ALL_CFLAGS) ${MULESRCDIR}/mule-coding.c > mule-coding.dep - -#endif /* MULE */ gnu-depend: $(obj_dep) /* #### Needs a bit of work: it doesn't see the object files that @@ -1771,7 +1154,7 @@ depend: : > depend.tmp makedepend -f depend.tmp -Dsubprocesses -DMOCKLISP_SUPPORT \ - -DHAVE_X_WINDOWS -DMULE -- $(CPPFLAGS) $(ALL_CFLAGS) \ + -DHAVE_X_WINDOWS -DMULE -- $(cppflags) $(cflags) \ -- *.c sh ${libsrc}process-depends.sh < depend.tmp > depend.out egrep '^mule|[^a-zA-Z]mule' depend.out > /tmp/depend1.$$ @@ -1820,19 +1203,19 @@ extw-Xt-nonshared.o: config.h extw-Xt-nonshared.o: extw-Xlib.h extw-Xt-nonshared.o: extw-Xt.h -#endif +#endif /* EXTERNAL_WIDGET */ #ifdef EMACS_BTL -cadillac-btl.o: $(BTLDIR)/cadillac-btl.c -cadillac-btl.o: $(BTLDIR)/cadillac-btl.h -cadillac-btl.o: $(BTLDIR)/cadillac-btl-extern.h -cadillac-btl-asm.o: $(BTLDIR)/cadillac-btl-asm.c -cadillac-btl-asm.o: $(BTLDIR)/cadillac-btl.h -cadillac-btl-asm.o: $(BTLDIR)/cadillac-btl-extern.h -cadillac-btl-emacs.o: $(BTLDIR)/cadillac-btl-extern.h -cadillac-btl-process.o: $(BTLDIR)/cadillac-btl-process.c -cadillac-btl-process.o: $(BTLDIR)/cadillac-btl.h -cadillac-btl-process.o: $(BTLDIR)/cadillac-btl-extern.h +cadillac-btl.o: $(BTL_dir)/cadillac-btl.c +cadillac-btl.o: $(BTL_dir)/cadillac-btl.h +cadillac-btl.o: $(BTL_dir)/cadillac-btl-extern.h +cadillac-btl-asm.o: $(BTL_dir)/cadillac-btl-asm.c +cadillac-btl-asm.o: $(BTL_dir)/cadillac-btl.h +cadillac-btl-asm.o: $(BTL_dir)/cadillac-btl-extern.h +cadillac-btl-emacs.o: $(BTL_dir)/cadillac-btl-extern.h +cadillac-btl-process.o: $(BTL_dir)/cadillac-btl-process.c +cadillac-btl-process.o: $(BTL_dir)/cadillac-btl.h +cadillac-btl-process.o: $(BTL_dir)/cadillac-btl-extern.h #endif /* EMACS_BTL */ /* (makedepend definitely misbehaves on these) */ @@ -1915,12 +1298,14 @@ menubar-x.o: mule-charset.h minibuf.o: mule-charset.h mocklisp.o: mule-charset.h +#ifdef HAVE_CANNA mule-canna.o: blocktype.h mule-canna.o: buffer.h mule-canna.o: bufslots.h mule-canna.o: config.h mule-canna.o: dynarr.h mule-canna.o: mule-charset.h +#endif /* HAVE_CANNA */ mule-ccl.o: blocktype.h mule-ccl.o: buffer.h mule-ccl.o: bufslots.h @@ -1947,6 +1332,7 @@ mule-coding.o: lstream.h mule-coding.o: mule-charset.h mule-coding.o: mule-coding.h +#if 0 mule-mcpath.o: blocktype.h mule-mcpath.o: buffer.h mule-mcpath.o: bufslots.h @@ -1954,6 +1340,8 @@ mule-mcpath.o: dynarr.h mule-mcpath.o: mule-charset.h mule-mcpath.o: sysfile.h +#endif /* obsolete */ +#ifdef HAVE_WNN mule-wnnfns.o: blocktype.h mule-wnnfns.o: buffer.h mule-wnnfns.o: bufslots.h @@ -1963,6 +1351,7 @@ mule-wnnfns.o: redisplay.h mule-wnnfns.o: scrollbar.h mule-wnnfns.o: window.h +#endif /* HAVE_WNN */ mule.o: blocktype.h mule.o: config.h mule.o: dynarr.h @@ -1995,7 +1384,7 @@ xselect.o: mule-charset.h #endif /* MULE */ -EmacsFrame.o: $(LWLIBSRCDIR)/lwlib.h +EmacsFrame.o: $(LWLIB_SRCDIR)/lwlib.h EmacsFrame.o: EmacsFrame.h EmacsFrame.o: EmacsFrameP.h EmacsFrame.o: EmacsManager.h @@ -2283,10 +1672,12 @@ data.o: config.h data.o: dynarr.h data.o: sysfloat.h +#ifdef HAVE_DATABASE database.o: blocktype.h database.o: config.h database.o: database.h database.o: dynarr.h +#endif /* HAVE_DATABASE */ debug.o: blocktype.h debug.o: bytecode.h debug.o: config.h @@ -2314,7 +1705,7 @@ device-tty.o: systime.h device-tty.o: systty.h device-tty.o: toolbar.h -device-x.o: $(LWLIBSRCDIR)/lwlib.h +device-x.o: $(LWLIB_SRCDIR)/lwlib.h device-x.o: blocktype.h device-x.o: buffer.h device-x.o: bufslots.h @@ -2367,7 +1758,7 @@ device.o: window.h dgif_lib.o: config.h dgif_lib.o: gif_lib.h -dialog-x.o: $(LWLIBSRCDIR)/lwlib.h +dialog-x.o: $(LWLIB_SRCDIR)/lwlib.h dialog-x.o: EmacsFrame.h dialog-x.o: EmacsManager.h dialog-x.o: EmacsShell.h @@ -2480,7 +1871,7 @@ eval.o: console.h eval.o: dynarr.h eval.o: opaque.h -event-Xt.o: $(LWLIBSRCDIR)/lwlib.h +event-Xt.o: $(LWLIB_SRCDIR)/lwlib.h event-Xt.o: Emacs.ad.h event-Xt.o: EmacsFrame.h event-Xt.o: blocktype.h @@ -2723,7 +2114,7 @@ frame-tty.o: specifier.h frame-tty.o: systty.h frame-tty.o: toolbar.h -frame-x.o: $(LWLIBSRCDIR)/lwlib.h +frame-x.o: $(LWLIB_SRCDIR)/lwlib.h frame-x.o: EmacsFrame.h frame-x.o: EmacsFrameP.h frame-x.o: EmacsManager.h @@ -2794,7 +2185,7 @@ gif_err.o: gif_lib.h gifalloc.o: config.h gifalloc.o: gif_lib.h -glyphs-x.o: $(LWLIBSRCDIR)/lwlib.h +glyphs-x.o: $(LWLIB_SRCDIR)/lwlib.h glyphs-x.o: ${srcdir}/${etcdir}xemacs.xbm glyphs-x.o: bitmaps.h glyphs-x.o: blocktype.h @@ -2842,7 +2233,7 @@ glyphs.o: window.h gmalloc.o: config.h gmalloc.o: getpagesize.h -gui-x.o: $(LWLIBSRCDIR)/lwlib.h +gui-x.o: $(LWLIB_SRCDIR)/lwlib.h gui-x.o: blocktype.h gui-x.o: buffer.h gui-x.o: bufslots.h @@ -2893,7 +2284,7 @@ indent.o: specifier.h indent.o: toolbar.h indent.o: window.h -inline.o: $(LWLIBSRCDIR)/lwlib.h +inline.o: $(LWLIB_SRCDIR)/lwlib.h inline.o: blocktype.h inline.o: buffer.h inline.o: bufslots.h @@ -3053,7 +2444,7 @@ md5.o: config.h md5.o: dynarr.h md5.o: insdel.h -menubar-x.o: $(LWLIBSRCDIR)/lwlib.h +menubar-x.o: $(LWLIB_SRCDIR)/lwlib.h menubar-x.o: EmacsFrame.h menubar-x.o: EmacsManager.h menubar-x.o: EmacsShell.h @@ -3282,7 +2673,7 @@ redisplay-tty.o: systty.h redisplay-tty.o: toolbar.h redisplay-tty.o: window.h -redisplay-x.o: $(LWLIBSRCDIR)/lwlib.h +redisplay-x.o: $(LWLIB_SRCDIR)/lwlib.h redisplay-x.o: EmacsFrame.h redisplay-x.o: EmacsFrameP.h redisplay-x.o: blocktype.h @@ -3347,7 +2738,7 @@ regex.o: dynarr.h regex.o: regex.h regex.o: syntax.h -scrollbar-x.o: $(LWLIBSRCDIR)/lwlib.h +scrollbar-x.o: $(LWLIB_SRCDIR)/lwlib.h scrollbar-x.o: EmacsFrame.h scrollbar-x.o: EmacsManager.h scrollbar-x.o: blocktype.h @@ -3499,7 +2890,7 @@ termcap.o: device.h termcap.o: dynarr.h terminfo.o: config.h -toolbar-x.o: $(LWLIBSRCDIR)/lwlib.h +toolbar-x.o: $(LWLIB_SRCDIR)/lwlib.h toolbar-x.o: EmacsFrame.h toolbar-x.o: EmacsFrameP.h toolbar-x.o: EmacsManager.h
--- a/src/bytecode.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/bytecode.c Mon Aug 13 09:36:16 2007 +0200 @@ -27,7 +27,7 @@ FSF: long ago. -hacked on by jwz@lucid.com 17-jun-91 +hacked on by jwz@netscape.com 17-jun-91 o added a compile-time switch to turn on simple sanity checking; o put back the obsolete byte-codes for error-detection; o added a new instruction, unbind_all, which I will use for
--- a/src/config.h.in Mon Aug 13 09:35:15 2007 +0200 +++ b/src/config.h.in Mon Aug 13 09:36:16 2007 +0200 @@ -18,14 +18,29 @@ the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* Synched up with: FSF 19.30 (more or less). */ +/* Significantly divergent from FSF. */ /* No code in XEmacs #includes config.h twice, but some of the code - intended to work with other packages as well (like gmalloc.c) + intended to work with other packages as well (like gmalloc.c) think they can include it as many times as they like. */ #ifndef _CONFIG_H_ #define _CONFIG_H_ +/* alloca twiddling belongs in one place, not the s&m headers + AIX requires this to be the first thing in the file. */ +#undef HAVE_ALLOCA_H + +#ifndef NOT_C_CODE +#ifdef __GNUC__ +#undef alloca +#define alloca __builtin_alloca +#elif defined(_AIX) +#pragma alloca +#elif HAVE_ALLOCA_H +#include <alloca.h> +#endif +#endif /* NOT C */ + /* #### This will be removed in 19.15. */ #define LOSING_BYTECODE @@ -33,22 +48,19 @@ files so as to make it obvious where XEmacs changes are. */ #define XEMACS -/* These are all defined in the top-level Makefile by configure. - They're here only for reference. */ - /* Does XEmacs support floating-point numbers? */ #undef LISP_FLOAT_TYPE -/* Do you want to use the *new* GNU memory allocator? */ +/* Use the *new* GNU memory allocator? */ #undef GNU_MALLOC -/* Do you want to use the system malloc? */ +/* Use the system malloc? */ #undef USE_SYSTEM_MALLOC -/* Do you want TTY support compiled in? */ +/* Compile in TTY support? */ #undef HAVE_TTY -/* Do you have the X window system and want to use it? */ +/* Compile in support for the X window system? */ #undef HAVE_X_WINDOWS /* Slightly better type checking in X header files */ @@ -103,10 +115,10 @@ #undef HAVE_LOCALE_H #undef HAVE_X11_XLOCALE_H #undef HAVE_LINUX_VERSION_H +#undef HAVE_INTTYPES_H #undef STDC_HEADERS #undef TIME_WITH_SYS_TIME #undef WORDS_BIGENDIAN -#undef HAVE_ALLOCA_H #undef HAVE_VFORK_H #undef HAVE_KSTAT_H #undef HAVE_SYS_PSTAT_H @@ -119,6 +131,7 @@ #endif #undef HAVE_LIBKSTAT +#undef HAVE_LIBINTL #undef HAVE_LIBDNET #undef HAVE_LIBRESOLV @@ -218,80 +231,58 @@ #undef UNEXEC_SRC #undef AIX_SMT_EXP -/* Do you have the `socks' library and want XEmacs to use it? */ +/* Compile in support for SOCKS? */ #undef HAVE_SOCKS -/* Do you run the `term' program (e.g. under Linux) and want XEmacs to - use it? */ +/* Compile in support for using the `term' program (e.g. under Linux)? */ #undef HAVE_TERM -/* Do you have the `xpm' library and want XEmacs to use it? */ +/* Compile in support for X pixmaps via the `xpm' library? */ #undef HAVE_XPM -/* Do you have the `compface' library and want XEmacs to use it? - This will permit X-face pixmaps in mail and news messages to display - quickly. */ +/* Compile in support for "X faces" via the `compface' library? + This enables graphical display of X-face headers in mail/news messages */ #undef HAVE_XFACE -/* Do you want XEmacs to have native support for converting - GIF (Graphics Interchange Format) images? */ +/* Compile in support for GIF (Graphics Interchange Format) images? */ #undef HAVE_GIF -/* Do you have the JPEG library and want XEmacs to use it? - This is for converting JPEG images. */ +/* Compile in support for displaying JPEG images via the `jpeg' library? */ #undef HAVE_JPEG -/* Do you have the PNG library and want XEmacs to use it? - This is for converting PNG images. */ +/* Compile in support for displaying PNG images via the `png' library? */ #undef HAVE_PNG -/* Do you want to use -lgz instead of -lz for PNG. */ -#undef HAVE_PNG_GNUZ - -/* Do you have the TIFF library and want XEmacs to use it? - This is for converting TIFF images. */ +/* Compile in support for displaying TIFF images via the `tiff' library? */ #undef HAVE_TIFF /* Do you have the Xmu library? This should always be the case except on losing HP-UX systems. */ #undef HAVE_XMU -/* Do you have the DBM libraries and want XEmacs to use them? */ +/* Compile in support for DBM databases? May require libgdbm or libdbm. */ #undef HAVE_DBM -/* Do you have the GNU DBM libraries and want XEmacs to use them? - HAVE_GNU_DBM requires that HAVE_DBM be defined as well. */ -#undef HAVE_GNU_DBM - -/* Do you have the BerkDB libraries and want XEmacs to use them? */ +/* Compile in support for Berkeley DB style databases? May require libdb. */ #undef HAVE_BERKELEY_DB +/* Full #include file path for Berkeley DB's db.h */ +#undef DB_H_PATH -/* Do you have the -lgdbm library? (separated from HAVE_GNU_DBM stuff - because FreeBSD has the DBM routines in libc) */ -#undef HAVE_LIBGDBM - -/* Do you have the -ldbm library? */ -#undef HAVE_LIBDBM - -/* Do you have the -ldb library? */ -#undef HAVE_LIBDB - -#if defined (HAVE_DBM) || defined (HAVE_BERKELEY_DB) -# define HAVE_DATABASE -#endif +/* Do we have either DBM or Berkeley DB database support? */ +#undef HAVE_DATABASE /* Do you have the Xauth library present? This will add some extra functionality to gnuserv. */ #undef HAVE_XAUTH -/* Do you have the library -lncurses ? */ -#undef HAVE_NCURSES +/* Compile in support for gpm (General Purpose Mouse)? */ +#undef HAVE_GPM -/* Do you have ncurses or curses.h ? */ -#undef HAVE_NCURSES_CURSES_H - -/* Define HAVE_NCURSES_TERM_H if ncurses/term.h is present. */ -#undef HAVE_NCURSES_TERM_H +/* Compile in support for ncurses? */ +#undef HAVE_NCURSES +/* Full #include file paths for ncurses' curses.h and term.h. */ +#undef CURSES_H_PATH +#undef TERM_H_PATH #define LOWTAGS @@ -316,11 +307,9 @@ #undef ERROR_CHECK_TYPECHECK /* Make sure valid buffer positions are passed to BUF_* macros. */ #undef ERROR_CHECK_BUFPOS -/* Attempt to catch bugs related to garbage collection (e.g. - insufficient GCPRO'ing). */ +/* Attempt to catch bugs related to garbage collection (e.g. not GCPRO'ing). */ #undef ERROR_CHECK_GC -/* Attempt to catch freeing of a non-malloc()ed block, heap corruption, - etc. */ +/* Attempt to catch freeing of a non-malloc()ed block, heap corruption, etc. */ #undef ERROR_CHECK_MALLOC /* Define DEBUG_XEMACS if you want extra debugging code compiled in. @@ -328,16 +317,16 @@ #undef DEBUG_XEMACS /* Define MEMORY_USAGE_STATS if you want extra code compiled in to - determine where XEmacs's memory is going. */ + determine where XEmacs' memory is going. */ #undef MEMORY_USAGE_STATS -/* Define QUANTIFY if using Quantify from Pure Software. This adds - some additional calls to control data collection. This is only - intended for use by the developers. */ +/* Define QUANTIFY if using Quantify from Pure/Atria Software. + This adds some additional calls to control data collection. + It is only intended for use by the developers. */ #undef QUANTIFY /* Define EXTERNAL_WIDGET to compile support for using the editor as a - widget in another program. */ + widget within another program. */ #undef EXTERNAL_WIDGET /* There are some special-case defines for gcc and lcc. */ @@ -351,9 +340,9 @@ /* Define this if you want level 2 internationalization compliance (localized collation and formatting). Generally this should be - defined, unless your system doesn't have the strcoll() and - setlocale() library routines. This really should be defined in - the appropriate s/ or m/ file. */ + defined, unless your system doesn't have the strcoll() and + setlocale() library routines. This really should be (NOT! -mrb) + defined in the appropriate s/ or m/ file. */ #undef I18N2 /* Define this if you want level 3 internationalization compliance @@ -363,10 +352,11 @@ WARNING, this code is under construction. */ #undef I18N3 -/* Define this if you want to use the Common Desktop Environment. */ +/* Compile in support for CDE (Common Desktop Environment) drag and drop? + Requires libDtSvc, which typically must be present at runtime. */ #undef HAVE_CDE -/* Define this if you want to use the OffiX Drag and Drop. */ +/* Compile in support for OffiX Drag and Drop? Requires libdnd. */ #undef HAVE_OFFIX_DND /* Define this if you want Mule support (multi-byte character support). @@ -388,7 +378,7 @@ /* Mocklisp Support. */ #undef MOCKLISP_SUPPORT -/* enable special GNU Make features in the Makefiles. */ +/* Enable special GNU Make features in the Makefiles. */ #undef USE_GNU_MAKE /* Debugging option: Don't automatically rebuild the DOC file. @@ -422,7 +412,7 @@ configuration names to use for them. See s/template.h for documentation on writing s/...h files. */ -#undef config_opsysfile +#undef config_opsysfile #include config_opsysfile /* The configuration script defines machfile to be the name of the @@ -449,7 +439,7 @@ typedef unsigned long EMACS_UINT; #endif #endif -#endif +#endif /* 0 */ /* The configuration name. This is used as the install directory name for the lib-src programs. */ @@ -469,35 +459,10 @@ #endif /* not NO_SHORTNAMES */ #endif /* SHORTNAMES */ -/* Define REL_ALLOC if you want to use the relocating allocator for - buffer space. */ +/* Use the relocating allocator for buffer space? */ #undef REL_ALLOC -/* Define LD_SWITCH_SITE to contain any special flags your loader may need. */ -#undef LD_SWITCH_SITE - -/* Define C_SWITCH_SITE to contain any special flags your compiler needs. */ -#undef C_SWITCH_SITE - -/* Define LD_SWITCH_X_SITE to contain any special flags your loader - may need to deal with X Windows. For instance, if you've defined - HAVE_X_WINDOWS above and your X libraries aren't in a place that - your loader can find on its own, you might want to add "-L/..." or - something similar. */ -#undef LD_SWITCH_X_SITE - -/* Define LD_SWITCH_X_SITE_AUX with an -R option - in case it's needed (for Solaris, for example). */ -#undef LD_SWITCH_X_SITE_AUX - -/* Define C_SWITCH_X_SITE to contain any special flags your compiler - may need to deal with X Windows. For instance, if you've defined - HAVE_X_WINDOWS above and your X include files aren't in a place - that your compiler can find on its own, you might want to add - "-I/..." or something similar. */ -#undef C_SWITCH_X_SITE - -/* Define the return type of signal handlers if the s-xxx file +/* Define the return type of signal handlers if the s/xxx.h file did not already do so. */ #define RETSIGTYPE void @@ -508,14 +473,9 @@ #endif /* Define DYNODUMP if it is necessary to properly dump on this system. - Currently this is only Solaris. */ + Currently this is only Solaris 2.x, for x < 6. */ #undef DYNODUMP -/* Define NEED_XILDOFF if the -xildoff flag must be passed to cc to - avoid invoking the incremental linker ild which is incompatible - with dynodump. This is needed for recent Sun compilers. */ -#undef NEED_XILDOFF - /* Define ENERGIZE to compile with support for the Energize Programming System. If you do this, don't forget to define ENERGIZE in lwlib/Imakefile as well. You will need to set your C_SWITCH_SITE and LD_SWITCH_SITE to point at the @@ -524,30 +484,32 @@ #undef ENERGIZE_2 #undef ENERGIZE_3 -/* Define SUNPRO to compiled in support for Sun Sparcworks. */ +/* Compile in support for Sun Sparcworks/WorkShop? */ #undef SUNPRO -/* Sun SparcStations, SGI machines, and HP9000s700s have support for playing - different sound files as beeps. If you are on a SparcStation but do not - have the sound option installed for some reason, then undefine - HAVE_NATIVE_SOUND. (It's usually found in /usr/demo/SOUND/ on SunOS 4 - and Solaris systems; on Solaris, you may need to install the "SUNWaudmo" - package.) */ +/* Sun SparcStations, SGI machines, and HP9000s700s have built-in + support for playing sound files. (On Suns, the sound support is + usually found in /usr/demo/SOUND - you may need to install the + "SUNWaudmo" package.) */ #undef HAVE_NATIVE_SOUND +/* Native sound may be provided via soundcard.h, in various directories */ +#undef SOUNDCARD_H_PATH -/* If you wish to compile with support for the Network Audio System - system define HAVE_NAS_SOUND. - NAS_NO_ERROR_JUMP means that the NAS libraries don't inlcude some +/* Compile in support for NAS (Network Audio System)? + NAS_NO_ERROR_JUMP means that the NAS libraries don't include some error handling changes. */ #undef HAVE_NAS_SOUND #undef NAS_NO_ERROR_JUMP -/* Compile in support for SunPro usage-tracking code. */ +/* Compile in support for SunPro usage-tracking code? */ #undef USAGE_TRACKING -/* Define TOOLTALK if your site supports the ToolTalk library. */ +/* Compile in support for Tooltalk? */ #undef TOOLTALK +/* tt_c.h might be in "Tt" or "desktop" subdirectories */ +#undef TT_C_H_PATH +/* Toolkits used by lwlib for various widgets... */ #undef LWLIB_USES_MOTIF #undef LWLIB_USES_ATHENA #undef LWLIB_MENUBARS_LUCID @@ -576,7 +538,7 @@ uses, mbstowcs() and wcstombs(), are unusable when programs are statically linked (as XEmacs must be) because the static version of libc.a contains the *dynamic* versions of these functions. These - functions don't seem to be called when XEmacs is running, so it's + functions don't seem to be called when XEmacs is running, so it's enough to define stubs for them. This appears to be fixed in SunOS 4.1.2. @@ -706,11 +668,23 @@ #endif /* movemail options */ -/* define to POP3 for mail access */ +/* Should movemail use POP3 for mail access? */ #undef MAIL_USE_POP -/* define to use kerberos for POP authentication */ +/* Should movemail use kerberos for POP authentication? */ #undef KERBEROS -/* define to use hesiod for getting POP server host */ +/* Should movemail use hesiod for getting POP server host? */ #undef HESIOD +/* Determine type of mail locking. */ +/* Play preprocessor games so that configure options override s&m files */ +#undef REAL_MAIL_USE_LOCKF +#undef REAL_MAIL_USE_FLOCK +#undef MAIL_USE_LOCKF +#undef MAIL_USE_FLOCK +#ifdef REAL_MAIL_USE_FLOCK +#define MAIL_USE_FLOCK +#endif +#ifdef REAL_MAIL_USE_LOCKF +#define MAIL_USE_LOCKF +#endif #endif /* _CONFIG_H_ */
--- a/src/console-tty.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/console-tty.h Mon Aug 13 09:36:16 2007 +0200 @@ -58,6 +58,9 @@ int height; int width; + /* The count of frame number. */ + int frame_count; + /* flags indicating presence, absence or value of various features */ struct {
--- a/src/database.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/database.c Mon Aug 13 09:36:16 2007 +0200 @@ -21,36 +21,52 @@ /* Synched up with: Not in FSF. */ /* Written by Bill Perry */ +/* Hacked on by Martin Buchholz */ #include <config.h> #include "lisp.h" #include <errno.h> -#ifdef HAVE_DATABASE -#include <database.h> /* Our include file */ +#ifndef HAVE_DATABASE +#error database.c being compiled, but HAVE_DATABASE not defined! +#endif /* HAVE_DATABASE */ + +#include <database.h> /* Our include file */ + #ifdef HAVE_BERKELEY_DB -#include <db.h> /* Berkeley db access */ -#endif -#ifdef HAVE_DBM -#include <ndbm.h> -#endif - -Lisp_Object Qdatabasep; -#ifdef HAVE_DBM -Lisp_Object Qdbm; -#endif -#ifdef HAVE_BERKELEY_DB +/* Work around Berkeley DB's use of int types which are defined + slightly differently in the not quite yet standard <inttypes.h>. + See db.h for details of why we're resorting to this... */ +#ifdef HAVE_INTTYPES_H +#define __BIT_TYPES_DEFINED__ +#include <inttypes.h> +typedef uint8_t u_int8_t; +typedef uint16_t u_int16_t; +typedef uint32_t u_int32_t; +#ifdef WE_DONT_NEED_QUADS +typedef uint64_t u_int64_t; +#endif /* WE_DONT_NEED_QUADS */ +#endif /* HAVE_INTTYPES_H */ +#include DB_H_PATH /* Berkeley db's header file */ Lisp_Object Qberkeley_db; Lisp_Object Qhash; Lisp_Object Qbtree; Lisp_Object Qrecno; -#endif +#endif /* HAVE_BERKELEY_DB */ + +#ifdef HAVE_DBM +#include <ndbm.h> +Lisp_Object Qdbm; +#endif /* HAVE_DBM */ + +Lisp_Object Qdatabasep; typedef enum { DB_DBM, DB_BERKELEY, DB_UNKNOWN } XEMACS_DB_TYPE; struct database_struct; +typedef struct database_struct database_struct; -typedef struct _DB_FUNCS +typedef struct { CONST char * (*get_subtype) (struct database_struct *); CONST char * (*get_type) (struct database_struct *); @@ -74,6 +90,9 @@ int dberrno; void *db_handle; DB_FUNCS *funcs; +#ifdef MULE + Lisp_Object coding_system; +#endif }; #define XDATABASE(x) XRECORD (x, database, struct database_struct) @@ -102,6 +121,9 @@ dbase->mode = 0; dbase->dberrno = 0; dbase->type = DB_UNKNOWN; +#ifdef MULE + dbase->coding_system = Fget_coding_system (Qbinary); +#endif return (dbase); } @@ -322,8 +344,7 @@ static Lisp_Object dbm_lasterr (struct database_struct *dbp) { - char *temp = strerror (dbp->dberrno); - return (make_string ((unsigned char *) temp, strlen (temp))); + return Fstrerror (make_int (dbp->dberrno)); } static void @@ -405,8 +426,7 @@ static Lisp_Object berkdb_lasterr (struct database_struct *dbp) { - char *temp = strerror (dbp->dberrno); - return (make_string ((unsigned char *) temp, strlen (temp))); + return Fstrerror (make_int (dbp->dberrno)); } static Lisp_Object @@ -519,10 +539,7 @@ struct database_struct *db; if (NILP (obj)) - { - char *temp = strerror (errno); - return (make_string ((unsigned char *) temp, strlen (temp))); - } + return Fstrerror (make_int (errno)); CHECK_DATABASE (obj); db = XDATABASE (obj); @@ -741,4 +758,3 @@ Fprovide (Qberkeley_db); #endif } -#endif /* HAVE_DATABASE */
--- a/src/device-tty.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/device-tty.c Mon Aug 13 09:36:16 2007 +0200 @@ -146,7 +146,9 @@ continue; get_tty_device_size (d, &width, &height); - if (width > 0 && height > 0) + if (width > 0 && height > 0 + && (CONSOLE_TTY_DATA (con)->width != width + || CONSOLE_TTY_DATA (con)->height != height)) { CONSOLE_TTY_DATA (con)->width = width; CONSOLE_TTY_DATA (con)->height = height;
--- a/src/device-x.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/device-x.c Mon Aug 13 09:36:16 2007 +0200 @@ -163,14 +163,13 @@ static void Xatoms_of_device_x (struct device *d) { - Display *display = DEVICE_X_DISPLAY (d); -#define ATOM(x) XInternAtom (display, (x), False) + Display *D = DEVICE_X_DISPLAY (d); - DEVICE_XATOM_WM_PROTOCOLS (d) = ATOM ("WM_PROTOCOLS"); - DEVICE_XATOM_WM_DELETE_WINDOW (d) = ATOM ("WM_DELETE_WINDOW"); - DEVICE_XATOM_WM_SAVE_YOURSELF (d) = ATOM ("WM_SAVE_YOURSELF"); - DEVICE_XATOM_WM_TAKE_FOCUS (d) = ATOM ("WM_TAKE_FOCUS"); - DEVICE_XATOM_WM_STATE (d) = ATOM ("WM_STATE"); + DEVICE_XATOM_WM_PROTOCOLS (d) = XInternAtom (D, "WM_PROTOCOLS", False); + DEVICE_XATOM_WM_DELETE_WINDOW(d) = XInternAtom (D, "WM_DELETE_WINDOW",False); + DEVICE_XATOM_WM_SAVE_YOURSELF(d) = XInternAtom (D, "WM_SAVE_YOURSELF",False); + DEVICE_XATOM_WM_TAKE_FOCUS (d) = XInternAtom (D, "WM_TAKE_FOCUS", False); + DEVICE_XATOM_WM_STATE (d) = XInternAtom (D, "WM_STATE", False); } static void @@ -281,7 +280,7 @@ if (!access (path, R_OK)) XrmCombineFileDatabase (path, &db, False); } -#endif +#endif /* MULE */ if (NILP (DEVICE_NAME (d))) DEVICE_NAME (d) = display;
--- a/src/editfns.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/editfns.c Mon Aug 13 09:36:16 2007 +0200 @@ -202,11 +202,9 @@ p = XSTRING (str); if (string_length (p) != 0) - { - return (make_char (string_char (p, 0))); - } + return make_char (string_char (p, 0)); else /* #### Gag me! */ - return (Qzero); + return Qzero; } @@ -226,8 +224,7 @@ */ (buffer)) { - struct buffer *b = decode_buffer (buffer, 1); - return (make_int (BUF_PT (b))); + return make_int (BUF_PT (decode_buffer (buffer, 1))); } DEFUN ("point-marker", Fpoint_marker, 0, 2, 0, /* @@ -294,7 +291,7 @@ Bufpos n = get_buffer_pos_char (b, position, GB_COERCE_RANGE); BUF_SET_PT (b, n); atomic_extent_goto_char_p = 1; - return (make_int (n)); + return make_int (n); } static Lisp_Object @@ -310,9 +307,9 @@ m = Fmarker_position (b->mark); if (NILP (m)) error ("There is no region now"); if (!!(BUF_PT (b) < XINT (m)) == !!beginningp) - return (make_int (BUF_PT (b))); + return make_int (BUF_PT (b)); else - return (m); + return m; } DEFUN ("region-beginning", Fregion_beginning, 0, 1, 0, /* @@ -330,7 +327,7 @@ */ (buffer)) { - return (region_limit (0, decode_buffer (buffer, 1))); + return region_limit (0, decode_buffer (buffer, 1)); } /* Whether to use lispm-style active-regions */ @@ -532,8 +529,7 @@ */ (buffer)) { - struct buffer *b = decode_buffer (buffer, 1); - return (make_int (BUF_ZV (b))); + return make_int (BUF_ZV (decode_buffer (buffer,1))); } DEFUN ("point-max-marker", Fpoint_max_marker, 0, 1, 0, /* @@ -701,12 +697,12 @@ user_name = (char *) getenv ("USER"); #endif /* WINDOWSNT */ if (user_name) - return (build_string (user_name)); + return build_string (user_name); else pw = (struct passwd *) getpwuid (geteuid ()); } /* #### - I believe this should return nil instead of "unknown" when pw==0 */ - return (pw ? build_string (pw->pw_name) : Qnil); + return pw ? build_string (pw->pw_name) : Qnil; } DEFUN ("user-real-login-name", Fuser_real_login_name, 0, 0, 0, /* @@ -1052,7 +1048,7 @@ Out-of-range values for SEC, MINUTE, HOUR, DAY, or MONTH are allowed; for example, a DAY of 0 means the day preceding the given month. Year numbers less than 100 are treated just like other year numbers. -If you want them to stand for years in this century, you must do that yourself +If you want them to stand for years in this century, you must do that yourself. */ (int nargs, Lisp_Object *args)) { @@ -1060,19 +1056,13 @@ struct tm tm; Lisp_Object zone = (nargs > 6) ? args[nargs - 1] : Qnil; - CHECK_INT (args[0]); /* second */ - CHECK_INT (args[1]); /* minute */ - CHECK_INT (args[2]); /* hour */ - CHECK_INT (args[3]); /* day */ - CHECK_INT (args[4]); /* month */ - CHECK_INT (args[5]); /* year */ + CHECK_INT (*args); tm.tm_sec = XINT (*args++); /* second */ + CHECK_INT (*args); tm.tm_min = XINT (*args++); /* minute */ + CHECK_INT (*args); tm.tm_hour = XINT (*args++); /* hour */ + CHECK_INT (*args); tm.tm_mday = XINT (*args++); /* day */ + CHECK_INT (*args); tm.tm_mon = XINT (*args++) - 1; /* month */ + CHECK_INT (*args); tm.tm_year = XINT (*args++) - 1900;/* year */ - tm.tm_sec = XINT (args[0]); - tm.tm_min = XINT (args[1]); - tm.tm_hour = XINT (args[2]); - tm.tm_mday = XINT (args[3]); - tm.tm_mon = XINT (args[4]) - 1; - tm.tm_year = XINT (args[5]) - 1900; tm.tm_isdst = -1; if (CONSP (zone))
--- a/src/emacs.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/emacs.c Mon Aug 13 09:36:16 2007 +0200 @@ -52,7 +52,7 @@ #endif #ifdef TOOLTALK -#include <tt_c.h> +#include TT_C_H_PATH #endif #ifdef VMS
--- a/src/emacsfns.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/emacsfns.h Mon Aug 13 09:36:16 2007 +0200 @@ -605,6 +605,7 @@ Lisp_Object class, Error_behavior errb); Lisp_Object Fprogn (Lisp_Object args); +Lisp_Object Fstrerror (Lisp_Object errnum); Lisp_Object Fcommandp (Lisp_Object obj); Lisp_Object Feval (Lisp_Object form); Lisp_Object Fapply (int nargs, Lisp_Object *args);
--- a/src/eval.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/eval.c Mon Aug 13 09:36:16 2007 +0200 @@ -2485,6 +2485,18 @@ } +DEFUN ("strerror", Fstrerror, 1, 1, 0, /* +Return the error string associated with integer ERRNUM. +This function is an interface to strerror(3). +The returned string may or may not be translated. +*/ + (errnum)) +{ + CHECK_INT (errnum); + return build_ext_string (strerror (XINT (errnum)), FORMAT_NATIVE); +} + + /**********************************************************************/ /* User commands */ /**********************************************************************/ @@ -2521,17 +2533,10 @@ /* Emacs primitives are interactive if their DEFUN specifies an interactive spec. */ if (SUBRP (fun)) - { - if (XSUBR (fun)->prompt) - return Qt; - else - return Qnil; - } - - else if (COMPILED_FUNCTIONP (fun)) - { - return (((XCOMPILED_FUNCTION (fun)->flags.interactivep) ? Qt : Qnil)); - } + return XSUBR (fun)->prompt ? Qt : Qnil; + + if (COMPILED_FUNCTIONP (fun)) + return XCOMPILED_FUNCTION (fun)->flags.interactivep ? Qt : Qnil; /* Strings and vectors are keyboard macros. */ if (VECTORP (fun) || STRINGP (fun)) @@ -5134,6 +5139,7 @@ DEFSUBR (Fcall_with_condition_handler); DEFSUBR (Fsignal); DEFSUBR (Finteractive_p); + DEFSUBR (Fstrerror); DEFSUBR (Fcommandp); DEFSUBR (Fcommand_execute); DEFSUBR (Fautoload);
--- a/src/event-Xt.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/event-Xt.c Mon Aug 13 09:36:16 2007 +0200 @@ -2159,16 +2159,16 @@ Bool *critical = (Bool *) data; Lisp_Object keysym; - if (critical) *critical = False; - if (event->type != KeyPress) return 0; - if (! x_any_window_to_frame (d, event->xany.window)) return 0; - if (event->xkey.state - & (xd->MetaMask | xd->HyperMask | xd->SuperMask | xd->AltMask)) + if (critical) + *critical = False; + if ((event->type != KeyPress) || + (! x_any_window_to_frame (d, event->xany.window)) || + (event->xkey.state + & (xd->MetaMask | xd->HyperMask | xd->SuperMask | xd->AltMask))) return 0; /* This duplicates some code that exists elsewhere, but it's relatively - fast and doesn't cons. - */ + fast and doesn't cons. */ keysym = x_to_emacs_keysym (&event->xkey, 1); if (NILP (keysym)) return 0; if (CHAR_OR_CHAR_INTP (keysym)) @@ -2331,7 +2331,7 @@ #endif /* This function used to simply check whether there were any X - events (or is user_p was 1, it iterated over all the pending + events (or if user_p was 1, it iterated over all the pending X events using XCheckIfEvent(), looking for keystrokes and button events). That worked in the old cheesoid event loop, which didn't go through XtAppDispatchEvent(), but it doesn't
--- a/src/events.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/events.c Mon Aug 13 09:36:16 2007 +0200 @@ -63,7 +63,7 @@ Lisp_Object Qmouse_event_p; Lisp_Object Qprocess_event_p; -Lisp_Object Qkey_press, Qbutton_press, Qbutton_release, Qmisc_user; +Lisp_Object Qkey_press, Qbutton_press, Qbutton_release, Qmisc_user, Qempty; Lisp_Object Qascii_character; /* #### Ad-hoc hack. Should be part of define_lrecord_implementation */ @@ -185,25 +185,18 @@ break; } case process_event: - { write_c_string ("#<process-event ", printcharfun); print_internal (XEVENT (obj)->event.process.process, printcharfun, 1); break; - } case timeout_event: - { write_c_string ("#<timeout-event ", printcharfun); print_internal (XEVENT (obj)->event.timeout.object, printcharfun, 1); break; - } case empty_event: - { write_c_string ("#<empty-event", printcharfun); break; - } case misc_user_event: case eval_event: - { write_c_string ("#<", printcharfun); if (XEVENT (obj)->event_type == misc_user_event) write_c_string ("misc-user", printcharfun); @@ -215,18 +208,13 @@ print_internal (XEVENT (obj)->event.eval.object, printcharfun, 1); write_c_string (")", printcharfun); break; - } case dead_event: - { write_c_string ("#<DEALLOCATED-EVENT", printcharfun); break; - } default: - { write_c_string ("#<UNKNOWN-EVENT-TYPE", printcharfun); break; } - } write_c_string (">", printcharfun); } @@ -242,53 +230,39 @@ switch (e1->event_type) { case process_event: - return (EQ (e1->event.process.process, - e2->event.process.process)); + return EQ (e1->event.process.process, e2->event.process.process); case timeout_event: - if (NILP (Fequal (e1->event.timeout.function, - e2->event.timeout.function))) - return 0; - if (NILP (Fequal (e1->event.timeout.object, - e2->event.timeout.object))) - return 0; - return 1; + return (!NILP (Fequal (e1->event.timeout.function, + e2->event.timeout.function)) && + !NILP (Fequal (e1->event.timeout.object, + e2->event.timeout.object))); case key_press_event: - return ((EQ (e1->event.key.keysym, - e2->event.key.keysym) - && (e1->event.key.modifiers - == e2->event.key.modifiers))); + return (EQ (e1->event.key.keysym, e2->event.key.keysym) && + (e1->event.key.modifiers == e2->event.key.modifiers)); case button_press_event: case button_release_event: - return (((e1->event.button.button - == e2->event.button.button) - && (e1->event.button.modifiers - == e2->event.button.modifiers))); + return (e1->event.button.button == e2->event.button.button && + e1->event.button.modifiers == e2->event.button.modifiers); case pointer_motion_event: - return ((e1->event.motion.x == e2->event.motion.x - && e1->event.motion.y == e2->event.motion.y)); + return (e1->event.motion.x == e2->event.motion.x && + e1->event.motion.y == e2->event.motion.y); case misc_user_event: case eval_event: - if (NILP (Fequal (e1->event.eval.function, - e2->event.eval.function))) - return 0; - if (NILP (Fequal (e1->event.eval.object, - e2->event.eval.object))) - return 0; - return 1; + return (!NILP (Fequal (e1->event.eval.function, + e2->event.eval.function)) && + !NILP (Fequal (e1->event.eval.object, + e2->event.eval.object))); case magic_eval_event: - if (e1->event.magic_eval.internal_function != - e2->event.magic_eval.internal_function) - return 0; - if (NILP (Fequal (e1->event.magic_eval.object, - e2->event.magic_eval.object))) - return 0; - return 1; + return (e1->event.magic_eval.internal_function == + e2->event.magic_eval.internal_function && + !NILP (Fequal (e1->event.magic_eval.object, + e2->event.magic_eval.object))); case magic_event: { @@ -299,12 +273,16 @@ #ifdef HAVE_X_WINDOWS /* XEvent is actually a union which means that we can't just use == */ if (CONSOLE_X_P (XCONSOLE (console))) - return (!memcmp ((XEvent *) &e1->event.magic.underlying_x_event, + return !memcmp ((XEvent *) &e1->event.magic.underlying_x_event, (XEvent *) &e2->event.magic.underlying_x_event, - sizeof (e1->event.magic.underlying_x_event))); + sizeof (e1->event.magic.underlying_x_event)); #endif +#ifdef HAVE_TTY + if (CONSOLE_TTY_P (XCONSOLE (console))) return (e1->event.magic.underlying_tty_event == e2->event.magic.underlying_tty_event); +#endif + return 1; } case empty_event: /* Empty and deallocated events are equal. */ @@ -960,7 +938,7 @@ case eval_event: strcpy (buf, "eval"); return; case process_event: strcpy (buf, "process");return; case timeout_event: strcpy (buf, "timeout");return; - case empty_event: strcpy (buf, "EMPTY-EVENT"); return; + case empty_event: strcpy (buf, "empty"); return; case dead_event: strcpy (buf, "DEAD-EVENT"); return; default: abort (); @@ -1023,7 +1001,7 @@ */ (object)) { - return ((EVENTP (object)) ? Qt : Qnil); + return EVENTP (object) ? Qt : Qnil; } DEFUN ("event-live-p", Fevent_live_p, 1, 1, 0, /* @@ -1031,18 +1009,17 @@ */ (object)) { - return ((EVENTP (object) && XEVENT (object)->event_type != dead_event) - ? Qt : Qnil); + return EVENTP (object) && XEVENT (object)->event_type != dead_event ? + Qt : Qnil; } #if 0 /* debugging functions */ -xxDEFUN ("event-next", Fevent_next, Sevent_next, 1, 1, 0 /* +xxDEFUN ("event-next", Fevent_next, 1, 1, 0, /* Return the event object's `next' event, or nil if it has none. The `next-event' field is changed by calling `set-next-event'. -*/ ) - (event) - Lisp_Object event; +*/ + (event)) { struct Lisp_Event *e; CHECK_LIVE_EVENT (event); @@ -1050,12 +1027,11 @@ return XEVENT_NEXT (event); } -xxDEFUN ("set-event-next", Fset_event_next, Sset_event_next, 2, 2, 0 /* +xxDEFUN ("set-event-next", Fset_event_next, 2, 2, 0, /* Set the `next event' of EVENT to NEXT-EVENT. NEXT-EVENT must be an event object or nil. -*/ ) - (event, next_event) - Lisp_Object event, next_event; +*/ + (event, next_event)) { Lisp_Object ev; @@ -1078,7 +1054,7 @@ next_event)); } XSET_EVENT_NEXT (event, next_event); - return (next_event); + return next_event; } #endif /* 0 */ @@ -1105,30 +1081,14 @@ CHECK_LIVE_EVENT (event); switch (XEVENT (event)->event_type) { - case key_press_event: - return Qkey_press; - - case button_press_event: - return Qbutton_press; - - case button_release_event: - return Qbutton_release; - - case misc_user_event: - return Qmisc_user; - - case pointer_motion_event: - return Qmotion; - - case process_event: - return Qprocess; - - case timeout_event: - return Qtimeout; - - case eval_event: - return Qeval; - + case key_press_event: return Qkey_press; + case button_press_event: return Qbutton_press; + case button_release_event: return Qbutton_release; + case misc_user_event: return Qmisc_user; + case pointer_motion_event: return Qmotion; + case process_event: return Qprocess; + case timeout_event: return Qtimeout; + case eval_event: return Qeval; case magic_event: case magic_eval_event: return Qmagic; @@ -1143,7 +1103,7 @@ } DEFUN ("event-timestamp", Fevent_timestamp, 1, 1, 0, /* -Return the timestamp of the given event object. +Return the timestamp of the event object EVENT. */ (event)) { @@ -1168,17 +1128,17 @@ } DEFUN ("event-key", Fevent_key, 1, 1, 0, /* -Return the Keysym of the given key-press event. -This will be the ASCII code of a printing character, or a symbol. +Return the Keysym of the key-press event EVENT. +This will be a character if the event is associated with one, else a symbol. */ (event)) { CHECK_EVENT_TYPE (event, key_press_event, Qkey_press_event_p); - return (XEVENT (event)->event.key.keysym); + return XEVENT (event)->event.key.keysym; } DEFUN ("event-button", Fevent_button, 1, 1, 0, /* -Return the button-number of the given mouse-button-press event. +Return the button-number of the given button-press or button-release event. */ (event)) { @@ -1274,10 +1234,10 @@ } DEFUN ("event-window-x-pixel", Fevent_window_x_pixel, 1, 1, 0, /* -Return the X position in pixels of the given mouse event. +Return the X position in pixels of mouse event EVENT. The value returned is relative to the window the event occurred in. -This will signal an error if the event is not a mouse-motion, button-press, -or button-release event. See also `event-x-pixel'. +This will signal an error if the event is not a mouse event. +See also `mouse-event-p' and `event-x-pixel'. */ (event)) { @@ -1292,10 +1252,10 @@ } DEFUN ("event-window-y-pixel", Fevent_window_y_pixel, 1, 1, 0, /* -Return the Y position in pixels of the given mouse event. +Return the Y position in pixels of mouse event EVENT. The value returned is relative to the window the event occurred in. -This will signal an error if the event is not a mouse-motion, button-press, -or button-release event. See also `event-y-pixel'. +This will signal an error if the event is not a mouse event. +See also `mouse-event-p' and `event-y-pixel'. */ (event)) { @@ -1310,10 +1270,10 @@ } DEFUN ("event-x-pixel", Fevent_x_pixel, 1, 1, 0, /* -Return the X position in pixels of the given mouse event. +Return the X position in pixels of mouse event EVENT. The value returned is relative to the frame the event occurred in. -This will signal an error if the event is not a mouse-motion, button-press, -or button-release event. See also `event-window-x-pixel'. +This will signal an error if the event is not a mouse event. +See also `mouse-event-p' and `event-window-x-pixel'. */ (event)) { @@ -1328,10 +1288,10 @@ } DEFUN ("event-y-pixel", Fevent_y_pixel, 1, 1, 0, /* -Return the Y position in pixels of the given mouse event. +Return the Y position in pixels of mouse event EVENT. The value returned is relative to the frame the event occurred in. -This will signal an error if the event is not a mouse-motion, button-press, -or button-release event. See also `event-window-y-pixel'. +This will signal an error if the event is not a mouse event. +See also `mouse-event-p' `event-window-y-pixel'. */ (event)) { @@ -1454,56 +1414,44 @@ } DEFUN ("event-over-text-area-p", Fevent_over_text_area_p, 1, 1, 0, /* -Return whether the given mouse event occurred over the text area of a window. +Return t if the mouse event EVENT occurred over the text area of a window. The modeline is not considered to be part of the text area. */ (event)) { int result = event_pixel_translation (event, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - if (result == OVER_TEXT || result == OVER_NOTHING) - return Qt; - else - return Qnil; + return result == OVER_TEXT || result == OVER_NOTHING ? Qt : Qnil; } DEFUN ("event-over-modeline-p", Fevent_over_modeline_p, 1, 1, 0, /* -Return whether the given mouse event occurred over the modeline of a window. +Return t if the mouse event EVENT occurred over the modeline of a window. */ (event)) { int result = event_pixel_translation (event, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - if (result == OVER_MODELINE) - return Qt; - else - return Qnil; + return result == OVER_MODELINE ? Qt : Qnil; } DEFUN ("event-over-border-p", Fevent_over_border_p, 1, 1, 0, /* -Return whether the given mouse event occurred over an internal border. +Return t if the mouse event EVENT occurred over an internal border. */ (event)) { int result = event_pixel_translation (event, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - if (result == OVER_BORDER) - return Qt; - else - return Qnil; + return result == OVER_BORDER ? Qt : Qnil; } DEFUN ("event-over-toolbar-p", Fevent_over_toolbar_p, 1, 1, 0, /* -Return whether the given mouse event occurred over a toolbar. +Return t if the mouse event EVENT occurred over a toolbar. */ (event)) { int result = event_pixel_translation (event, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); - if (result == OVER_TOOLBAR) - return Qt; - else - return Qnil; + return result == OVER_TOOLBAR ? Qt : Qnil; } struct console * @@ -1519,7 +1467,7 @@ } DEFUN ("event-channel", Fevent_channel, 1, 1, 0, /* -Return the channel that the given event occurred on. +Return the channel that the event EVENT occurred on. This will be a frame, device, console, or nil for some types of events (e.g. eval events). */ @@ -1530,14 +1478,13 @@ } DEFUN ("event-window", Fevent_window, 1, 1, 0, /* -Return the window of the given mouse event. +Return the window over which mouse event EVENT occurred. This may be nil if the event occurred in the border or over a toolbar. -The modeline is considered to be in the window it represents. +The modeline is considered to be within the window it describes. */ (event)) { struct window *w; - Lisp_Object window; event_pixel_translation (event, 0, 0, 0, 0, &w, 0, 0, 0, 0, 0); @@ -1545,15 +1492,17 @@ return Qnil; else { + Lisp_Object window; + XSETWINDOW (window, w); return window; } } DEFUN ("event-point", Fevent_point, 1, 1, 0, /* -Return the character position of the given mouse event. +Return the character position of the mouse event EVENT. If the event did not occur over a window, or did not occur over text, -then this returns nil. Otherwise, it returns an index into the buffer +then this returns nil. Otherwise, it returns a position in the buffer visible in the event's window. */ (event)) @@ -1563,16 +1512,11 @@ event_pixel_translation (event, 0, 0, 0, 0, &w, &bufp, 0, 0, 0, 0); - if (!w) - return Qnil; - else if (!bufp) - return Qnil; - else - return make_int (bufp); + return w && bufp ? make_int (bufp) : Qnil; } DEFUN ("event-closest-point", Fevent_closest_point, 1, 1, 0, /* -Return the character position of the given mouse event. +Return the character position closest to the mouse event EVENT. If the event did not occur over a window or over text, return the closest point to the location of the event. If the Y pixel position overlaps a window and the X pixel position is to the left of that @@ -1580,8 +1524,8 @@ Y position. If the Y pixel position overlaps a window and the X pixel position is to the right of that window, the closest point is the end of the line containing the Y position. If the Y pixel position is -above a window, return 0. If it is below a window, return the value -of (window-end). +above a window, return 0. If it is below the last character in a window, +return the value of (window-end). */ (event)) { @@ -1589,14 +1533,11 @@ event_pixel_translation (event, 0, 0, 0, 0, 0, 0, &bufp, 0, 0, 0); - if (!bufp) - return Qnil; - else - return make_int (bufp); + return bufp ? make_int (bufp) : Qnil; } DEFUN ("event-x", Fevent_x, 1, 1, 0, /* -Return the X position of the given mouse event in characters. +Return the X position of the mouse event EVENT in characters. This is relative to the window the event occurred over. */ (event)) @@ -1609,7 +1550,7 @@ } DEFUN ("event-y", Fevent_y, 1, 1, 0, /* -Return the Y position of the given mouse event in characters. +Return the Y position of the mouse event EVENT in characters. This is relative to the window the event occurred over. */ (event)) @@ -1636,14 +1577,11 @@ event_pixel_translation (event, 0, 0, 0, 0, 0, 0, 0, &mbufp, 0, 0); - if (mbufp < 0) - return Qnil; - else - return make_int (mbufp); + return mbufp < 0 ? Qnil : make_int (mbufp); } DEFUN ("event-glyph", Fevent_glyph, 1, 1, 0, /* -Return the glyph that the given mouse event occurred over, or nil. +Return the glyph that the mouse event EVENT occurred over, or nil. */ (event)) { @@ -1652,16 +1590,11 @@ event_pixel_translation (event, 0, 0, 0, 0, &w, 0, 0, 0, &glyph, 0); - if (!w) - return Qnil; - else if (GLYPHP (glyph)) - return glyph; - else - return Qnil; + return w && GLYPHP (glyph) ? glyph : Qnil; } DEFUN ("event-glyph-extent", Fevent_glyph_extent, 1, 1, 0, /* -Return the extent of the glyph that the given mouse event occurred over. +Return the extent of the glyph that the mouse event EVENT occurred over. If the event did not occur over a glyph, nil is returned. */ (event)) @@ -1671,12 +1604,7 @@ event_pixel_translation (event, 0, 0, 0, 0, &w, 0, 0, 0, 0, &extent); - if (!w) - return Qnil; - else if (EXTENTP (extent)) - return extent; - else - return Qnil; + return w && EXTENTP (extent) ? extent : Qnil; } DEFUN ("event-glyph-x-pixel", Fevent_glyph_x_pixel, 1, 1, 0, /* @@ -1692,10 +1620,7 @@ event_pixel_translation (event, 0, 0, &obj_x, 0, &w, 0, 0, 0, 0, &extent); - if (w && EXTENTP (extent)) - return make_int (obj_x); - else - return Qnil; + return w && EXTENTP (extent) ? make_int (obj_x) : Qnil; } DEFUN ("event-glyph-y-pixel", Fevent_glyph_y_pixel, 1, 1, 0, /* @@ -1711,34 +1636,24 @@ event_pixel_translation (event, 0, 0, 0, &obj_y, &w, 0, 0, 0, 0, &extent); - if (w && EXTENTP (extent)) - return make_int (obj_y); - else - return Qnil; + return w && EXTENTP (extent) ? make_int (obj_y) : Qnil; } DEFUN ("event-toolbar-button", Fevent_toolbar_button, 1, 1, 0, /* -Return the toolbar button that the given mouse event occurred over. -If the event did not occur over a toolbar, nil is returned. +Return the toolbar button that the mouse event EVENT occurred over. +If the event did not occur over a toolbar button, nil is returned. */ (event)) { #ifdef HAVE_TOOLBARS Lisp_Object button; - int result; - result = event_pixel_translation (event, 0, 0, 0, 0, 0, 0, 0, 0, &button, 0); + int result = event_pixel_translation (event, 0, 0, 0, 0, 0, 0, 0, 0, &button, 0); - if (result == OVER_TOOLBAR) - { - if (TOOLBAR_BUTTONP (button)) - return button; - else + return result == OVER_TOOLBAR && TOOLBAR_BUTTONP (button) ? button : Qnil; +#else return Qnil; - } - else #endif - return Qnil; } DEFUN ("event-process", Fevent_process, 1, 1, 0, /* @@ -1747,7 +1662,7 @@ (event)) { CHECK_EVENT_TYPE (event, process_event, Qprocess_event_p); - return (XEVENT (event)->event.process.process); + return XEVENT (event)->event.process.process; } DEFUN ("event-function", Fevent_function, 1, 1, 0, /* @@ -1846,7 +1761,10 @@ case magic_eval_event: case magic_event: + break; + case empty_event: + RETURN_UNGCPRO (Qnil); break; default: @@ -1918,6 +1836,7 @@ defsymbol (&Qbutton_press, "button-press"); defsymbol (&Qbutton_release, "button-release"); defsymbol (&Qmisc_user, "misc-user"); + defsymbol (&Qempty, "empty"); defsymbol (&Qascii_character, "ascii-character"); }
--- a/src/fileio.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/fileio.c Mon Aug 13 09:36:16 2007 +0200 @@ -122,7 +122,7 @@ /* mrb: #### Needs to be fixed at a lower level; errstring needs to be MULEized. The following at least prevents a crash... */ - Lisp_Object errstring = build_ext_string (strerror (errno), FORMAT_BINARY); + Lisp_Object errstring = build_ext_string (strerror (errno), FORMAT_NATIVE); /* System error messages are capitalized. Downcase the initial unless it is followed by a slash. */
--- a/src/fns.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/fns.c Mon Aug 13 09:36:16 2007 +0200 @@ -63,7 +63,7 @@ static Lisp_Object mark_bit_vector (Lisp_Object obj, void (*markobj) (Lisp_Object)) { - return (Qnil); + return Qnil; } static void @@ -172,19 +172,15 @@ length_with_bytecode_hack (Lisp_Object seq) { if (!COMPILED_FUNCTIONP (seq)) - return (XINT (Flength (seq))); + return XINT (Flength (seq)); else { struct Lisp_Compiled_Function *b = XCOMPILED_FUNCTION (seq); - int intp = b->flags.interactivep; - int domainp = b->flags.domainp; - if (intp) - return (COMPILED_INTERACTIVE + 1); - else if (domainp) - return (COMPILED_DOMAIN + 1); - else - return (COMPILED_DOC_STRING + 1); + return (b->flags.interactivep ? COMPILED_INTERACTIVE : + b->flags.domainp ? COMPILED_DOMAIN : + COMPILED_DOC_STRING) + + 1; } } @@ -210,11 +206,11 @@ retry: if (STRINGP (obj)) - return (make_int (string_char_length (XSTRING (obj)))); + return make_int (string_char_length (XSTRING (obj))); else if (VECTORP (obj)) - return (make_int (vector_length (XVECTOR (obj)))); + return make_int (vector_length (XVECTOR (obj))); else if (BIT_VECTORP (obj)) - return (make_int (bit_vector_length (XBIT_VECTOR (obj)))); + return make_int (bit_vector_length (XBIT_VECTOR (obj))); else if (CONSP (obj)) { for (i = 0, tail = obj; !NILP (tail); i++) @@ -1198,7 +1194,7 @@ { int speccount = specpdl_depth (); specbind (Qinhibit_quit, Qt); - return (unbind_to (speccount, Fassoc (key, list))); + return unbind_to (speccount, Fassoc (key, list)); } DEFUN ("assq", Fassq, 2, 2, 0, /* @@ -1571,7 +1567,7 @@ { int speccount = specpdl_depth (); specbind (Qinhibit_quit, Qt); - return (unbind_to (speccount, Fremassoc (key, list))); + return unbind_to (speccount, Fremassoc (key, list)); } DEFUN ("remassq", Fremassq, 2, 2, 0, /* @@ -2885,14 +2881,14 @@ do_cdr: QUIT; if (EQ_WITH_EBOLA_NOTICE (o1, o2)) - return (1); + return 1; /* Note that (equal 20 20.0) should be nil */ else if (XTYPE (o1) != XTYPE (o2)) - return (0); + return 0; else if (CONSP (o1)) { if (!internal_equal (Fcar (o1), Fcar (o2), depth + 1)) - return (0); + return 0; o1 = Fcdr (o1); o2 = Fcdr (o2); goto do_cdr; @@ -2904,26 +2900,26 @@ int indecks; int len = vector_length (XVECTOR (o1)); if (len != vector_length (XVECTOR (o2))) - return (0); + return 0; for (indecks = 0; indecks < len; indecks++) { Lisp_Object v1, v2; v1 = vector_data (XVECTOR (o1)) [indecks]; v2 = vector_data (XVECTOR (o2)) [indecks]; if (!internal_equal (v1, v2, depth + 1)) - return (0); + return 0; } - return (1); + return 1; } #endif /* !LRECORD_VECTOR */ else if (STRINGP (o1)) { Bytecount len = XSTRING_LENGTH (o1); if (len != XSTRING_LENGTH (o2)) - return (0); + return 0; if (memcmp (XSTRING_DATA (o1), XSTRING_DATA (o2), len)) - return (0); - return (1); + return 0; + return 1; } else if (LRECORDP (o1)) { @@ -2931,15 +2927,15 @@ *imp1 = XRECORD_LHEADER (o1)->implementation, *imp2 = XRECORD_LHEADER (o2)->implementation; if (imp1 != imp2) - return (0); + return 0; else if (imp1->equal == 0) /* EQ-ness of the objects was noticed above */ - return (0); + return 0; else - return ((imp1->equal) (o1, o2, depth)); + return (imp1->equal) (o1, o2, depth); } - return (0); + return 0; } /* Note that we may be calling sub-objects that will use @@ -2955,14 +2951,14 @@ do_cdr: QUIT; if (HACKEQ_UNSAFE (o1, o2)) - return (1); + return 1; /* Note that (equal 20 20.0) should be nil */ else if (XTYPE (o1) != XTYPE (o2)) - return (0); + return 0; else if (CONSP (o1)) { if (!internal_old_equal (Fcar (o1), Fcar (o2), depth + 1)) - return (0); + return 0; o1 = Fcdr (o1); o2 = Fcdr (o2); goto do_cdr; @@ -2974,26 +2970,26 @@ int indecks; int len = vector_length (XVECTOR (o1)); if (len != vector_length (XVECTOR (o2))) - return (0); + return 0; for (indecks = 0; indecks < len; indecks++) { Lisp_Object v1, v2; v1 = vector_data (XVECTOR (o1)) [indecks]; v2 = vector_data (XVECTOR (o2)) [indecks]; if (!internal_old_equal (v1, v2, depth + 1)) - return (0); + return 0; } - return (1); + return 1; } #endif /* !LRECORD_VECTOR */ else if (STRINGP (o1)) { Bytecount len = XSTRING_LENGTH (o1); if (len != XSTRING_LENGTH (o2)) - return (0); + return 0; if (memcmp (XSTRING_DATA (o1), XSTRING_DATA (o2), len)) - return (0); - return (1); + return 0; + return 1; } else if (LRECORDP (o1)) { @@ -3001,15 +2997,15 @@ *imp1 = XRECORD_LHEADER (o1)->implementation, *imp2 = XRECORD_LHEADER (o2)->implementation; if (imp1 != imp2) - return (0); + return 0; else if (imp1->equal == 0) /* EQ-ness of the objects was noticed above */ - return (0); + return 0; else return ((imp1->equal) (o1, o2, depth)); } - return (0); + return 0; } DEFUN ("equal", Fequal, 2, 2, 0, /* @@ -3021,7 +3017,7 @@ */ (o1, o2)) { - return ((internal_equal (o1, o2, 0)) ? Qt : Qnil); + return internal_equal (o1, o2, 0) ? Qt : Qnil; } DEFUN ("old-equal", Fold_equal, 2, 2, 0, /* @@ -3035,7 +3031,7 @@ */ (o1, o2)) { - return (internal_old_equal (o1, o2, 0) ? Qt : Qnil); + return internal_old_equal (o1, o2, 0) ? Qt : Qnil; } @@ -3368,7 +3364,7 @@ tem = Fmemq (feature, Vfeatures); LOADHIST_ATTACH (Fcons (Qrequire, feature)); if (!NILP (tem)) - return (feature); + return feature; else { int speccount = specpdl_depth (); @@ -3387,7 +3383,7 @@ /* Once loading finishes, don't undo it. */ Vautoload_queue = Qt; - return (unbind_to (speccount, feature)); + return unbind_to (speccount, feature); } }
--- a/src/frame-tty.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/frame-tty.c Mon Aug 13 09:36:16 2007 +0200 @@ -1,6 +1,7 @@ /* TTY frame functions. - Copyright (C) 1995 Free Software Foundation, Inc. + Copyright (C) 1995 Free Software Foundation, Inc. Copyright (C) 1995, 1996 Ben Wing. + Copyright (C) 1997 Free Software Foundation, Inc. This file is part of XEmacs. @@ -21,11 +22,8 @@ /* Synched up with: Not in FSF. */ -/* Written by Ben Wing. */ - -/* #### This file is just a stub. It should be possible to have more - than one frame on a tty, with only one frame being "active" (displayed) - at a time. */ +/* Written by Ben Wing. + Multi-frame support added by Hrvoje Niksic. */ #include <config.h> #include "lisp.h" @@ -33,25 +31,47 @@ #include "console-tty.h" #include "frame.h" + +/* Default properties to use when creating frames. */ Lisp_Object Vdefault_tty_frame_plist; +/* The count of frame number. */ +static int tty_frame_count; + +static void tty_make_frame_visible (struct frame *); +static void tty_make_frame_invisible (struct frame *); + + static void tty_init_frame_1 (struct frame *f, Lisp_Object props) { struct device *d = XDEVICE (FRAME_DEVICE (f)); struct console *c = XCONSOLE (DEVICE_CONSOLE (d)); - if (!NILP (DEVICE_FRAME_LIST (d))) - error ("Only one frame allowed on TTY devices"); - f->name = build_string ("emacs"); + ++CONSOLE_TTY_DATA (c)->frame_count; + f->order_count = CONSOLE_TTY_DATA (c)->frame_count; f->height = CONSOLE_TTY_DATA (c)->height; f->width = CONSOLE_TTY_DATA (c)->width; - f->visible = 1; #ifdef HAVE_SCROLLBARS f->scrollbar_on_left = 1; f->scrollbar_on_top = 0; #endif +} + +static void +tty_init_frame_3 (struct frame *f) +{ + struct device *d = XDEVICE (FRAME_DEVICE (f)); + Lisp_Object tail = DEVICE_FRAME_LIST (d); + + while (CONSP (tail)) + { + tty_make_frame_invisible (decode_frame (XCAR (tail))); + tail = XCDR (tail); + } + select_frame_2 (make_frame (f)); SET_FRAME_CLEAR (f); + tty_make_frame_visible (f); } static void @@ -59,7 +79,7 @@ int first_on_console) { if (first_on_console) - call1 (Qinit_post_tty_win, FRAME_CONSOLE (f)); + call1 (Qinit_post_tty_win, FRAME_CONSOLE (f)); } /* Change from withdrawn state to mapped state. */ @@ -71,20 +91,72 @@ SET_FRAME_CLEAR(f); f->visible = 1; } - } /* Change from mapped state to withdrawn state. */ static void tty_make_frame_invisible (struct frame *f) { - f->visible = 0; + f->visible = 0; } static int tty_frame_visible_p (struct frame *f) { - return FRAME_VISIBLE_P(f); + return FRAME_VISIBLE_P (f); +} + +/* Raise the frame. This means that it becomes visible, and all the + others become invisible. */ +static void +tty_raise_frame (struct frame *f) +{ + struct device *d = XDEVICE (FRAME_DEVICE (f)); + Lisp_Object frame_list = DEVICE_FRAME_LIST (d); + Lisp_Object tail = frame_list; + + while (CONSP (tail)) + { + if (decode_frame (XCAR (tail)) != f) + tty_make_frame_invisible (XFRAME (XCAR (tail))); + tail = XCDR (tail); + } + select_frame_2 (make_frame (f)); + tty_make_frame_visible (f); +} + +/* Lower the frame. This means that it becomes invisible, while the + one after it in the frame list becomes visible. */ +static void +tty_lower_frame (struct frame *f) +{ + struct device *d = XDEVICE (FRAME_DEVICE (f)); + Lisp_Object frame_list = DEVICE_FRAME_LIST (d); + Lisp_Object tail; + Lisp_Object new; + + if (!FRAME_VISIBLE_P (f)) + return; + + tail = frame_list; + while (CONSP (tail)) + { + if (decode_frame (XCAR (tail)) == f) + break; + tail = XCDR (tail); + } + if (!CONSP (tail)) + { + error ("Cannot find frame to lower"); + } + + tty_make_frame_invisible (f); + if (CONSP (XCDR (tail))) + new = XCAR (XCDR (tail)); + else + new = XCAR (frame_list); + tty_make_frame_visible (XFRAME (new)); + select_frame_2 (new); } @@ -96,10 +168,13 @@ console_type_create_frame_tty (void) { CONSOLE_HAS_METHOD (tty, init_frame_1); + CONSOLE_HAS_METHOD (tty, init_frame_3); CONSOLE_HAS_METHOD (tty, after_init_frame); CONSOLE_HAS_METHOD (tty, make_frame_visible); CONSOLE_HAS_METHOD (tty, make_frame_invisible); CONSOLE_HAS_METHOD (tty, frame_visible_p); + CONSOLE_HAS_METHOD (tty, raise_frame); + CONSOLE_HAS_METHOD (tty, lower_frame); } void
--- a/src/frame.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/frame.c Mon Aug 13 09:36:16 2007 +0200 @@ -639,8 +639,27 @@ select_frame_1 (Lisp_Object frame) { struct frame *f = XFRAME (frame); + + /* If on a TTY, selecting a frame must raise it. */ +#ifdef HAVE_TTY + if (FRAME_TTY_P (f)) + FRAMEMETH(f, raise_frame, (f)); /* tty_raise_frame will call + select_frame_2, so we can skip + it. */ + else + select_frame_2 (frame); +#else + select_frame_2 (frame); +#endif +} + +/* Called from tty_raise_frame. */ +void +select_frame_2 (Lisp_Object frame) +{ + struct frame *f = XFRAME (frame); Lisp_Object old_selected_frame = Fselected_frame (Qnil); - + if (EQ (frame, old_selected_frame)) return; @@ -711,7 +730,7 @@ #if 0 /* FSFmacs */ -xxDEFUN ("handle-switch-frame", Fhandle_switch_frame, Shandle_switch_frame, 1, 2, "e" /* +xxDEFUN ("handle-switch-frame", Fhandle_switch_frame, 1, 2, "e", /* Handle a switch-frame event EVENT. Switch-frame events are usually bound to this function. A switch-frame event tells Emacs that the window manager has requested @@ -720,8 +739,8 @@ If EVENT is frame object, handle it as if it were a switch-frame event to that frame. -*/ ) - (Lisp_Object frame, Lisp_Object no_enter) +*/ + (frame, no_enter)) { /* Preserve prefix arg that the command loop just cleared. */ XCONSOLE (Vselected_console)->prefix_arg = Vcurrent_prefix_arg; @@ -732,11 +751,11 @@ } /* A load of garbage. */ -xxDEFUN ("ignore-event", Fignore_event, Signore_event, 0, 0, "" /* +xxDEFUN ("ignore-event", Fignore_event, 0, 0, "", /* Do nothing, but preserve any prefix argument already specified. This is a suitable binding for iconify-frame and make-frame-visible. -*/ ) - () +*/ + ()) { struct console *c = XCONSOLE (Vselected_console); @@ -744,7 +763,7 @@ return Qnil; } -#endif +#endif /* 0 */ DEFUN ("selected-frame", Fselected_frame, 0, 1, 0, /* Return the frame that is now selected on device DEVICE. @@ -966,6 +985,7 @@ { int passed = 0; int started_over = 0; + Lisp_Object tmp_frametype; /* If this frame is dead, it won't be in frame_list, and we'll loop forever. Forestall that. */ @@ -1013,7 +1033,18 @@ if (EQ (f, frame)) return f; - if (frame_matches_frametype (f, frametype)) + tmp_frametype = frametype; + if (FRAME_TTY_P (XFRAME (f))) + { + /* Only one TTY frame is visible at a time, but + next-frame and similar should still find + them. */ + if (EQ (frametype, Qvisible) + || EQ (frametype, Qvisible_nomini) + || EQ (frametype, Qvisible_iconic_nomini)) + tmp_frametype = Qnil; + } + if (frame_matches_frametype (f, tmp_frametype)) return f; } @@ -1043,6 +1074,7 @@ { Lisp_Object devcons, concons; Lisp_Object prev; + Lisp_Object tmp_frametype; /* If this frame is dead, it won't be in frame_list, and we'll loop forever. Forestall that. */ @@ -1067,7 +1099,17 @@ /* Decide whether this frame is eligible to be returned, according to frametype. */ - if (frame_matches_frametype (f, frametype)) + tmp_frametype = frametype; + if (FRAME_TTY_P (XFRAME (f))) + { + /* Only one TTY frame is visible at a time, but + next-frame and similar should still find them. */ + if (EQ (frametype, Qvisible) + || EQ (frametype, Qvisible_nomini) + || EQ (frametype, Qvisible_iconic_nomini)) + tmp_frametype = Qnil; + } + if (frame_matches_frametype (f, tmp_frametype)) prev = f; } @@ -2594,6 +2636,15 @@ abort (); XSETFRAME (frame, f); + + /* + * If the frame has been initialized and the new height and width + * are the same as the current height and width, then just return. + */ + if (f->init_finished && + newheight == FRAME_HEIGHT (f) && newwidth == FRAME_WIDTH (f)) + return; + default_face_height_and_width (frame, &font_height, &font_width); /* This size-change overrides any pending one for this frame. */ @@ -2942,7 +2993,7 @@ staticpro (&Vframe_being_created); #ifdef HAVE_CDE - Vfeatures = Fcons (intern ("cde"), Vfeatures); + Fprovide (intern ("cde")); #endif #if 0 /* FSFmacs stupidity */
--- a/src/frame.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/frame.h Mon Aug 13 09:36:16 2007 +0200 @@ -59,6 +59,11 @@ int pixheight; int pixwidth; +#ifdef HAVE_TTY + /* The count of frame number. This applies to TTY frames only. */ + int order_count; +#endif + /* Width of the internal border. This is a line of background color just inside the window's border. It is normally only non-zero on X frames, but we put it here to avoid introducing window system @@ -540,6 +545,7 @@ void unhold_one_frame_size_changes (struct frame *f); void unhold_frame_size_changes (void); void select_frame_1 (Lisp_Object frame); +void select_frame_2 (Lisp_Object frame); struct frame *selected_frame (void); struct frame *device_selected_frame (struct device *d); struct frame *decode_frame (Lisp_Object frame);
--- a/src/glyphs-x.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/glyphs-x.c Mon Aug 13 09:36:16 2007 +0200 @@ -208,7 +208,6 @@ case IMAGE_POINTER: if (IMAGE_INSTANCE_X_NPIXELS (p1) != IMAGE_INSTANCE_X_NPIXELS (p2)) return 0; - break; #if HAVE_SUBWINDOWS case IMAGE_SUBWINDOW: /* #### implement me */ @@ -233,8 +232,8 @@ #if HAVE_SUBWINDOWS case IMAGE_SUBWINDOW: /* #### implement me */ + return 0; #endif - return 0; default: return 0; }
--- a/src/indent.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/indent.c Mon Aug 13 09:36:16 2007 +0200 @@ -439,13 +439,13 @@ last_known_column_point = BUF_PT (buf); last_known_column_modified = BUF_MODIFF (buf); - return (make_int (col)); + return make_int (col); } #if 0 /* #### OK boys, this function needs to be present, I think. It was there before the 19.12 redisplay rewrite. */ -xxDEFUN ("compute-motion", Fcompute_motion, Scompute_motion, 7, 7, 0 /* +xxDEFUN ("compute-motion", Fcompute_motion, 7, 7, 0, /* "Scan through the current buffer, calculating screen position. Scan the current buffer forward from offset FROM, assuming it is at position FROMPOS--a cons of the form (HPOS . VPOS)-- @@ -484,10 +484,8 @@ and the window's upper-left coordinates as FROMPOS. Pass the buffer's (point-max) as TO, to limit the scan to the end of the visible section of the buffer, and pass LINE and COL as TOPOS. -*/ ) - (from, frompos, to, topos, width, offsets, window) - Lisp_Object from, frompos, to, topos; - Lisp_Object width, offsets, window; +*/ + (from, frompos, to, topos, width, offsets, window)) { Lisp_Object bufpos, hpos, vpos, prevhpos, contin; struct position *pos; @@ -525,12 +523,8 @@ XSETINT (vpos, pos->vpos); XSETINT (prevhpos, pos->prevhpos); - return list5 (bufpos, - hpos, - vpos, - prevhpos, + return list5 (bufpos, hpos, vpos, prevhpos, pos->contin ? Qt : Qnil); - } #endif /* 0 */
--- a/src/inline.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/inline.c Mon Aug 13 09:36:16 2007 +0200 @@ -73,6 +73,6 @@ #endif #ifdef TOOLTALK -#include <tt_c.h> +#include TT_C_H_PATH #include "tooltalk.h" #endif
--- a/src/input-method-motif.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/input-method-motif.c Mon Aug 13 09:36:16 2007 +0200 @@ -146,7 +146,7 @@ fontlistEntry = XmFontListEntryCreate(XmFONTLIST_DEFAULT_TAG, XmFONT_IS_FONTSET, - xim_resources.fontset); + (XtPointer) xim_resources.fontset); fontlist = XmFontListAppendEntry (NULL, fontlistEntry); XmImRegister (w, 0); XmImVaSetValues (w,
--- a/src/insdel.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/insdel.c Mon Aug 13 09:36:16 2007 +0200 @@ -1139,15 +1139,15 @@ GB_ALLOW_PAST_ACCESSIBLE - The allowable range for the position is the entire buffer - (BEG and Z), rather than the accessible portion. For strings, - this flag has no effect. + Allow positions to range over the entire buffer (BUF_BEG to BUF_Z), + rather than just the accessible portion (BUF_BEGV to BUF_ZV). + For strings, this flag has no effect. GB_COERCE_RANGE - If the position is outside the allowable range, return - the lower or upper bound of the range, whichever is closer - to the specified position. + If the position is outside the allowable range, return the lower + or upper bound of the range, whichever is closer to the specified + position. GB_NO_ERROR_IF_BAD @@ -1198,10 +1198,8 @@ CHECK_INT_COERCE_MARKER (pos); ind = XINT (pos); - min_allowed = (flags & GB_ALLOW_PAST_ACCESSIBLE) ? - BUF_BEG (b) : BUF_BEGV (b); - max_allowed = (flags & GB_ALLOW_PAST_ACCESSIBLE) ? - BUF_Z (b) : BUF_ZV (b); + min_allowed = flags & GB_ALLOW_PAST_ACCESSIBLE ? BUF_BEG (b) : BUF_BEGV (b); + max_allowed = flags & GB_ALLOW_PAST_ACCESSIBLE ? BUF_Z (b) : BUF_ZV (b); if (ind < min_allowed || ind > max_allowed) {
--- a/src/linuxplay.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/linuxplay.c Mon Aug 13 09:36:16 2007 +0200 @@ -61,13 +61,7 @@ #include <errno.h> #include <fcntl.h> -#ifdef __FreeBSD__ -# include <machine/soundcard.h> -#elif defined(__bsdi__) -# include <sys/soundcard.h> -#else -# include <linux/soundcard.h> -#endif +#include SOUNDCARD_H_PATH /* Path computed by configure */ #include <stdio.h> #include <stdlib.h> #include <string.h>
--- a/src/lisp.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/lisp.h Mon Aug 13 09:36:16 2007 +0200 @@ -256,10 +256,8 @@ #ifdef QUANTIFY #include "quantify.h" -#define QUANTIFY_START_RECORDING \ - do { quantify_start_recording_data (); } while (0) -#define QUANTIFY_STOP_RECORDING \ - do { quantify_stop_recording_data (); } while (0) +#define QUANTIFY_START_RECORDING quantify_start_recording_data () +#define QUANTIFY_STOP_RECORDING quantify_stop_recording_data () #else /* !QUANTIFY */ #define QUANTIFY_START_RECORDING #define QUANTIFY_STOP_RECORDING @@ -547,6 +545,8 @@ FORMAT_CTEXT }; +#define FORMAT_NATIVE FORMAT_FILENAME + enum run_hooks_condition { RUN_HOOKS_TO_COMPLETION,
--- a/src/lread.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/lread.c Mon Aug 13 09:36:16 2007 +0200 @@ -1402,20 +1402,19 @@ } #if 0 -xxDEFUN ("eval-current-buffer", Feval_current_buffer, Seval_current_buffer, 0, 1, "" /* +xxDEFUN ("eval-current-buffer", Feval_current_buffer, 0, 1, "", /* Execute the current buffer as Lisp code. Programs can pass argument PRINTFLAG which controls printing of output: nil means discard it; anything else is stream for print. If there is no error, point does not move. If there is an error, point remains at the end of the last character read from the buffer. -*/ ) - (printflag) - Lisp_Object printflag; +*/ + (printflag)) { code omitted; } -#endif +#endif /* 0 */ DEFUN ("eval-region", Feval_region, 2, 3, "r", /* Execute the region as Lisp code.
--- a/src/m/intel386.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/m/intel386.h Mon Aug 13 09:36:16 2007 +0200 @@ -93,27 +93,6 @@ /* This is totally uncalibrated. */ #define LOAD_AVE_CVT(x) ((int) (((double) (x)) * 100.0 / FSCALE)) -/* J.W.Hawtin@lut.ac.uk say Solaris 2.4 as well as Solaris 2.1 on X86 - requires -lkvm as well */ -#define LIBS_MACHINE -lkvm - -#ifndef SOLARIS2_4 -/* J.W.hawtin@lut.ac.uk says Solaris 2.1 on the X86 has FSCALE defined in a - system header. */ - -#else /* SOLARIS2_4 */ -#ifndef __GNUC__ -#if 0 /* wisner@gryphon.com says this screws up cpp */ -#define C_SWITCH_MACHINE -Xa -#endif -#ifndef NOT_C_CODE -#ifdef HAVE_ALLOCA_H -#include <alloca.h> -#endif /* HAVE_ALLOCA_H */ -#endif /* not NOT_C_CODE */ -#endif /* not __GNUC__ */ -#endif /* SOLARIS2_4 */ - /* configure thinks solaris X86 has gethostname, but it does not work, so undefine it. */ #undef HAVE_GETHOSTNAME
--- a/src/m/powerpc.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/m/powerpc.h Mon Aug 13 09:36:16 2007 +0200 @@ -54,24 +54,3 @@ /* Convert that into an integer that is 100 for a load average of 1.0 */ #define LOAD_AVE_CVT(x) (int) (((double) (x)) * 100.0 / FSCALE) - -/* Define C_ALLOCA if this machine does not support a true alloca - and the one written in C should be used instead. - Define HAVE_ALLOCA to say that the system provides a properly - working alloca function and it should be used. - Define neither one if an assembler-language alloca - in the file alloca.s should be used. */ - -#define HAVE_ALLOCA -#ifndef NOT_C_CODE -#if __GNUC__ < 2 /* Modern versions of GCC handle alloca directly. */ -#include <alloca.h> -#endif -#endif - -/* Solaris defines alloca to __builtin_alloca & does not provide a prototype */ -#ifdef __SUNPRO_C -# ifndef NOT_C_CODE -# include <alloca.h> -# endif -#endif
--- a/src/m/sparc.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/m/sparc.h Mon Aug 13 09:36:16 2007 +0200 @@ -66,28 +66,6 @@ #define LOAD_AVE_CVT(x) (int) (((double) (x)) * 100.0 / FSCALE) -/* Define C_ALLOCA if this machine does not support a true alloca - and the one written in C should be used instead. - Define HAVE_ALLOCA to say that the system provides a properly - working alloca function and it should be used. - Define neither one if an assembler-language alloca - in the file alloca.s should be used. */ - -#define HAVE_ALLOCA -#ifndef NOT_C_CODE -#if __GNUC__ < 2 /* Modern versions of GCC handle alloca directly. */ -#include <alloca.h> -#endif -#endif - -/* Solaris defines alloca to __builtin_alloca & does not provide a prototype */ -#ifdef __SUNPRO_C -# ifndef NOT_C_CODE -# include <alloca.h> - void *__builtin_alloca (unsigned int); -# endif -#endif - /* Must use the system's termcap, if we use any termcap. It does special things. */
--- a/src/m/sun386.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/m/sun386.h Mon Aug 13 09:36:16 2007 +0200 @@ -88,9 +88,3 @@ #undef RUN_TIME_REMAP #undef UNEXEC #define UNEXEC unexec.o - -#ifdef USG -/* USG detects Solaris. j.w.hawtin@lut.ac.uk says Solaris 2.1 - on the 386 needs this. */ -#define LIBS_MACHINE -lkvm -#endif
--- a/src/minibuf.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/minibuf.c Mon Aug 13 09:36:16 2007 +0200 @@ -130,6 +130,7 @@ Vminibuf_preprompt = LISP_GETTEXT (preprompt); } + return Qnil; } DEFUN ("read-minibuffer-internal", Fread_minibuffer_internal, 1, 1, 0, /* @@ -622,18 +623,19 @@ implement some braindamage in FSF which we aren't including. --cet */ #if 0 -xxDEFUN ("minibuffer-prompt", Fminibuffer_prompt, Sminibuffer_prompt, 0, 0, 0, - "Return the prompt string of the currently-active minibuffer.\n" -"If no minibuffer is active, return nil.") - () +xxDEFUN ("minibuffer-prompt", Fminibuffer_prompt, 0, 0, 0, /* +Return the prompt string of the currently-active minibuffer. +If no minibuffer is active, return nil. +*/ + ()) { return (Fcopy_sequence (Vminibuf_prompt)); } -xxDEFUN ("minibuffer-prompt-width", Fminibuffer_prompt_width, - Sminibuffer_prompt_width, 0, 0, 0, - "Return the display width of the minibuffer prompt.") - () +xxDEFUN ("minibuffer-prompt-width", Fminibuffer_prompt_width, 0, 0, 0, /* +Return the display width of the minibuffer prompt. +*/ + ()) { return (make_int (minibuf_prompt_width)); }
--- a/src/mule-ccl.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/mule-ccl.c Mon Aug 13 09:36:16 2007 +0200 @@ -587,8 +587,6 @@ #else /* not emacs */ #ifdef standalone -#include <alloca.h> - #define INBUF_SIZE 1024 #define MAX_CCL_CODE_SIZE 4096
--- a/src/mule.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/mule.c Mon Aug 13 09:36:16 2007 +0200 @@ -113,15 +113,12 @@ re_short_flag = 0; #endif /* MULE_REGEXP */ - Vfeatures = Fcons (intern ("mule"), Vfeatures); + Fprovide (intern ("mule")); #ifdef HAVE_EGG - Vfeatures = Fcons (intern ("egg"), Vfeatures); + Fprovide (intern ("egg")); #endif #ifdef HAVE_WNN - Vfeatures = Fcons (intern ("wnn"), Vfeatures); -#endif -#ifdef HAVE_SJ3 - Vfeatures = Fcons (intern "sj3"), Vfeatures); + Fprovide (intern ("wnn")); #endif }
--- a/src/objects-x.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/objects-x.c Mon Aug 13 09:36:16 2007 +0200 @@ -911,20 +911,20 @@ void Xatoms_of_objects_x (struct device *d) { -#define ATOM(x) XInternAtom (DEVICE_X_DISPLAY (d), (x), False) -#define ATOMIZE(x) DEVICE_XATOM_##x (d) = ATOM(#x) - ATOMIZE (FOUNDRY); - ATOMIZE (FAMILY_NAME); - ATOMIZE (WEIGHT_NAME); - ATOMIZE (SLANT); - ATOMIZE (SETWIDTH_NAME); - ATOMIZE (ADD_STYLE_NAME); - ATOMIZE (PIXEL_SIZE); - ATOMIZE (POINT_SIZE); - ATOMIZE (RESOLUTION_X); - ATOMIZE (RESOLUTION_Y); - ATOMIZE (SPACING); - ATOMIZE (AVERAGE_WIDTH); - ATOMIZE (CHARSET_REGISTRY); - ATOMIZE (CHARSET_ENCODING); + Display *D = DEVICE_X_DISPLAY (d); + + DEVICE_XATOM_FOUNDRY (d) = XInternAtom (D, "FOUNDRY", False); + DEVICE_XATOM_FAMILY_NAME (d) = XInternAtom (D, "FAMILY_NAME", False); + DEVICE_XATOM_WEIGHT_NAME (d) = XInternAtom (D, "WEIGHT_NAME", False); + DEVICE_XATOM_SLANT (d) = XInternAtom (D, "SLANT", False); + DEVICE_XATOM_SETWIDTH_NAME (d) = XInternAtom (D, "SETWIDTH_NAME", False); + DEVICE_XATOM_ADD_STYLE_NAME (d) = XInternAtom (D, "ADD_STYLE_NAME", False); + DEVICE_XATOM_PIXEL_SIZE (d) = XInternAtom (D, "PIXEL_SIZE", False); + DEVICE_XATOM_POINT_SIZE (d) = XInternAtom (D, "POINT_SIZE", False); + DEVICE_XATOM_RESOLUTION_X (d) = XInternAtom (D, "RESOLUTION_X", False); + DEVICE_XATOM_RESOLUTION_Y (d) = XInternAtom (D, "RESOLUTION_Y", False); + DEVICE_XATOM_SPACING (d) = XInternAtom (D, "SPACING", False); + DEVICE_XATOM_AVERAGE_WIDTH (d) = XInternAtom (D, "AVERAGE_WIDTH", False); + DEVICE_XATOM_CHARSET_REGISTRY(d) = XInternAtom (D, "CHARSET_REGISTRY",False); + DEVICE_XATOM_CHARSET_ENCODING(d) = XInternAtom (D, "CHARSET_ENCODING",False); }
--- a/src/print.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/print.c Mon Aug 13 09:36:16 2007 +0200 @@ -42,6 +42,8 @@ #endif /* not standalone */ +static void print_error_message (Lisp_Object data, Lisp_Object stream); + Lisp_Object Vstandard_output, Qstandard_output; /* The subroutine object for external-debugging-output is kept here @@ -601,7 +603,7 @@ Lisp_Object original, printcharfun, value; struct gcpro gcpro1; - print_error_message (obj, Vprin1_to_string_buffer, NULL); + print_error_message (obj, Vprin1_to_string_buffer); set_buffer_internal (XBUFFER (Vprin1_to_string_buffer)); value = Fbuffer_substring (Fpoint_min(Fcurrent_buffer()), @@ -619,8 +621,7 @@ /* Print an error message for the error DATA onto Lisp output stream STREAM (suitable for the print functions). */ -print_error_message (data, stream) - Lisp_Object data, stream; +static void print_error_message (Lisp_Object data, Lisp_Object stream) { Lisp_Object errname, errmsg, file_error, tail; struct gcpro gcpro1;
--- a/src/process.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/process.c Mon Aug 13 09:36:16 2007 +0200 @@ -3298,15 +3298,14 @@ proc_buffered_char[i] = -1; } } + #if 0 -xxDEFUN ("process-connection", Fprocess_connection, Sprocess_connection, - 0, 1, 0 /* +xxDEFUN ("process-connection", Fprocess_connection, 0, 1, 0, /* Return the connection type of `PROCESS'. This can be nil (pipe), t or pty (pty) or stream (socket connection). -*/ ) - (process) - Lisp_Object process; +*/ + (process)) { return XPROCESS (process)->type; }
--- a/src/profile.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/profile.c Mon Aug 13 09:36:16 2007 +0200 @@ -67,7 +67,7 @@ the table while another routine is operating on it. We also set inside_profiling in case the timeout between signal calls is short enough to catch us while we're already in there. */ -volatile static int inside_profiling; +static volatile int inside_profiling; static SIGTYPE sigprof_handler (int signo)
--- a/src/redisplay.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/redisplay.c Mon Aug 13 09:36:16 2007 +0200 @@ -61,6 +61,10 @@ #include "mule-coding.h" #endif +#ifdef HAVE_TTY +#include "console-tty.h" +#endif + /* Note: We have to be careful throughout this code to properly handle and differentiate between Bufbytes and Emchars. @@ -5767,6 +5771,20 @@ obj = b->mode_name; break; + /* print hyphen and frame number, if != 1 */ + case 'N': +#ifdef HAVE_TTY + { + struct frame *f = XFRAME (w->frame); + if (FRAME_TTY_P (f) && f->order_count > 1) + { + str = alloca (10); + sprintf (str, "-%d", f->order_count); + } + } +#endif + break; + /* print Narrow if appropriate */ case 'n': if (BUF_BEGV (b) > BUF_BEG (b)
--- a/src/s/bsd386.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/bsd386.h Mon Aug 13 09:36:16 2007 +0200 @@ -18,7 +18,7 @@ #define LIBS_DEBUG #define LIB_X11_LIB -L/usr/X11/lib -lX11 -#define LIBS_SYSTEM -lutil -lkvm -lcompat +#define LIBS_SYSTEM -lutil -lcompat #define HAVE_GETLOADAVG
--- a/src/s/decosf3-1.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/decosf3-1.h Mon Aug 13 09:36:16 2007 +0200 @@ -2,13 +2,6 @@ #include "decosf1-3.h" -/* XEmacs change from Carl D. Roth <roth@cse.ucsc.edu> - -/* we have a working alloca */ -# ifndef NOT_C_CODE -# include <alloca.h> -# endif - /* It seems that read() and write() are affected, but not open() and close() */
--- a/src/s/freebsd.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/freebsd.h Mon Aug 13 09:36:16 2007 +0200 @@ -87,7 +87,11 @@ #if __FreeBSD__ == 1 #define BSD 199103 #elif __FreeBSD__ == 2 -#define BSD 199306 +#if __FreeBSD_version < 199701 +# define BSD 199306 +#else +# define BSD 199506 +#endif #elif __FreeBSD__ == 3 #define BSD 199506 #endif
--- a/src/s/hpux10.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/hpux10.h Mon Aug 13 09:36:16 2007 +0200 @@ -14,10 +14,6 @@ #undef HAVE_RANDOM #define HPUX10 #define FORCE_ALLOCA_H -/* XEmacs addition */ -#ifndef OBJECTS_SYSTEM -#define OBJECTS_SYSTEM strcat.o -#endif /* AlainF 20-Jul-1996 -- fixes for 10.10, untested for 10.0x */ /* Fix kernel file name for 10.10 */ #undef KERNEL_FILE
--- a/src/s/hpux9.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/hpux9.h Mon Aug 13 09:36:16 2007 +0200 @@ -75,8 +75,3 @@ /* XEmacs: apparently rint() is totally broken in HPUX 9. */ #undef HAVE_RINT - -/* XEmacs addition */ -#ifndef OBJECTS_SYSTEM -#define OBJECTS_SYSTEM strcat.o -#endif
--- a/src/s/irix4-0.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/irix4-0.h Mon Aug 13 09:36:16 2007 +0200 @@ -5,11 +5,6 @@ #define USG5_3 #define IRIX4 -#define HAVE_ALLOCA -#ifndef NOT_C_CODE -#include <alloca.h> -#endif - #undef NEED_SIOCTL /* Make process_send_signal work by "typing" a signal character on the pty. */
--- a/src/s/irix5-0.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/irix5-0.h Mon Aug 13 09:36:16 2007 +0200 @@ -25,17 +25,6 @@ /* Make process_send_signal work by "typing" a signal character on the pty. */ #define SIGNALS_VIA_CHARACTERS -/* Define HAVE_ALLOCA to say that the system provides a properly - working alloca function and it should be used. */ -#define HAVE_ALLOCA -#undef C_ALLOCA - -#ifndef NOT_C_CODE -#ifndef __GNUC__ -#include <alloca.h> -#endif -#endif - /* SGI has all the fancy wait stuff, but we can't include sys/wait.h because it defines BIG_ENDIAN and LITTLE_ENDIAN (ugh!.) Instead we'll just define WNOHANG right here.
--- a/src/s/sol2-4.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/sol2-4.h Mon Aug 13 09:36:16 2007 +0200 @@ -17,6 +17,10 @@ #endif /* 0 */ #undef LD_SWITCH_SYSTEM +#undef C_SWITCH_SYSTEM + +#if 0 /* mrb */ +#undef LD_SWITCH_SYSTEM #ifndef __GNUC__ #define LD_SWITCH_SYSTEM -L /usr/ccs/lib LD_SWITCH_X_SITE_AUX -R /usr/openwin/lib -L /usr/openwin/lib -R /usr/dt/lib -L /usr/dt/lib #else /* GCC */ @@ -30,6 +34,7 @@ /* Gregory Neil Shapiro <gshapiro@hhmi.org> reports the Motif header files are in this directory on Solaris 2.4. */ #define C_SWITCH_X_SYSTEM -I/usr/dt/include +#endif /* XEmacs addition: Raymond Toy says XEmacs completely misses SIGCHLD when compiled with GCC 2.7.0 (but not, apparently, with SunPro C?),
--- a/src/s/sol2-static.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/sol2-static.h Mon Aug 13 09:36:16 2007 +0200 @@ -34,7 +34,7 @@ #undef LIBS_SYSTEM #ifdef NOT_C_CODE # undef LIBS_SYSTEM -# define LIBS_SYSTEM -lsocket -lnsl -lintl -lkvm -lelf -lgen +# define LIBS_SYSTEM -lsocket -lnsl -lintl -lelf -lgen #else -# define LIBS_SYSTEM -lsocket -lnsl -lkvm -lelf -lgen +# define LIBS_SYSTEM -lsocket -lnsl -lelf -lgen #endif
--- a/src/s/sol2.h Mon Aug 13 09:35:15 2007 +0200 +++ b/src/s/sol2.h Mon Aug 13 09:36:16 2007 +0200 @@ -18,25 +18,6 @@ #define POSIX -/* FSF uses LD_SWITCH_X_SITE_AUX in the following definitions to deal with - the -R flags. While the intention is good, it doesn't seem to work that - well -- Solaris is just too damn screwy. So we go ahead and let - configure have special checks for Solaris. */ - -/* Here is how to find X Windows. The -R option says where - to find X windows at run time. */ -#define LD_SWITCH_SYSTEM_RPATH -R/usr/dt/lib:/opt/SUNWdt/lib:/usr/openwin/lib -#ifdef __GNUC__ -#define LD_SWITCH_SYSTEM -Xlinker LD_SWITCH_SYSTEM_RPATH -#else -#define LD_SWITCH_SYSTEM LD_SWITCH_SYSTEM_RPATH -#endif - -/* XEmacs change -- Sun CC needs this to default to ANSI */ -#ifdef __SUNPRO_C -#define C_SWITCH_SYSTEM -Xa -#endif /* __SUNPRO_C */ - #ifndef NOT_C_CODE /* The standard Solaris library nsl has this function in it which is supposed to only be in the BSD compat stuff. Yuck. Of course, @@ -69,7 +50,7 @@ */ #undef LIBS_SYSTEM -#define LIBS_SYSTEM -lsocket -lnsl -lkvm -lelf -lgen -ldl +#define LIBS_SYSTEM -lsocket -lnsl -lelf -lgen -ldl /* XEmacs change -- Mark Borges says this is needed. */ #define LIBS_TERMCAP -ltermlib @@ -79,10 +60,9 @@ */ #if defined (NOT_C_CODE) && defined (ENERGIZE) -# define LIB_INTL -L/usr/openwin/lib -lintl -lw # define LIBS_DEBUG # undef LIBS_SYSTEM -# define LIBS_SYSTEM -lsocket -lnsl -lintl -lelf -lkvm -lgen -ldl +# define LIBS_SYSTEM -lsocket -lnsl -lelf -lgen -ldl # define START_FILES # define LD_CMD $(CC)
--- a/src/terminfo.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/terminfo.c Mon Aug 13 09:36:16 2007 +0200 @@ -48,12 +48,7 @@ format is different too. */ -#ifdef HAVE_NCURSES_CURSES_H -#include <ncurses/curses.h> -#else -#include <curses.h> -#endif -#if !(defined (__GNUC__) && defined (SOLARIS2)) +#include CURSES_H_PATH /* Sun, in their infinite lameness, supplies (possibly) broken headers even under Solaris. GCC feels it necessary to correct things by supplying its own headers. Unfortunately, if you build GCC under @@ -63,11 +58,8 @@ is equally lame in that it supplies "fixed" headers for curses.h but not term.h.) However, it seems to work to just not include term.h under Solaris, so we try that. KLUDGE! */ -#ifdef HAVE_NCURSES_TERM_H -#include <ncurses/term.h> -#else -#include <term.h> -#endif +#if !(defined (__GNUC__) && defined (SOLARIS2)) +#include TERM_H_PATH #endif extern void *xmalloc (int size);
--- a/src/tooltalk.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/tooltalk.c Mon Aug 13 09:36:16 2007 +0200 @@ -28,7 +28,7 @@ #include "lisp.h" #include <X11/Xlib.h> -#include <tt_c.h> +#include TT_C_H_PATH #include "buffer.h" #include "elhash.h"
--- a/src/unexelf.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/unexelf.c Mon Aug 13 09:36:16 2007 +0200 @@ -732,6 +732,7 @@ /* Now copy over what we have in the memory now. */ memcpy (NEW_SECTION_H (nn).sh_offset + new_base, (caddr_t) OLD_SECTION_H (n).sh_addr, + /* #### mrb: should be old_bss_size instead? */ new_data2_size); nn++; }
--- a/src/window.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/window.c Mon Aug 13 09:36:16 2007 +0200 @@ -791,19 +791,12 @@ window_needs_vertical_divider (struct window *w) { #ifdef HAVE_SCROLLBARS - struct frame *f = XFRAME (w->frame); - - if (!window_scrollbar_width (w)) - { - if (f->scrollbar_on_left) - return (!window_is_leftmost (w)); - else - return (!window_is_rightmost (w)); - } - else - return 0; + return (!window_scrollbar_width (w) && + ((XFRAME (w->frame)->scrollbar_on_left) ? + !window_is_leftmost (w) : + !window_is_rightmost (w))); #else - return (!window_is_leftmost (w)); + return !window_is_leftmost (w); #endif /* HAVE_SCROLLBARS */ } @@ -1397,7 +1390,8 @@ #if 0 /* bogus RMS crock */ -xxDEFUN ("window-redisplay-end-trigger", Fwindow_redisplay_end_trigger, 0, 1, 0 /* +xxDEFUN ("window-redisplay-end-trigger", + Fwindow_redisplay_end_trigger, 0, 1, 0, /* Return WINDOW's redisplay end trigger value. See `set-window-redisplay-end-trigger' for more information. */ @@ -1406,7 +1400,8 @@ return decode_window (window)->redisplay_end_trigger; } -xxDEFUN ("set-window-redisplay-end-trigger", Fset_window_redisplay_end_trigger, 2, 2, 0 /* +xxDEFUN ("set-window-redisplay-end-trigger", + Fset_window_redisplay_end_trigger, 2, 2, 0, /* Set WINDOW's redisplay end trigger value to VALUE. VALUE should be a buffer position (typically a marker) or nil. If it is a buffer position, then if redisplay in WINDOW reaches a position @@ -1430,10 +1425,9 @@ { struct window *w = decode_window (window); struct frame *f = XFRAME (w->frame); - int left, top; - - left = w->pixel_left - FRAME_LEFT_BORDER_END (f); - top = w->pixel_top - FRAME_TOP_BORDER_END (f); + + int left = w->pixel_left - FRAME_LEFT_BORDER_END (f); + int top = w->pixel_top - FRAME_TOP_BORDER_END (f); return list4 (make_int (left), make_int (top), @@ -1566,10 +1560,7 @@ { register struct window *w = decode_window (window); - if (NILP (arg)) - w->dedicated = Qnil; - else - w->dedicated = Qt; + w->dedicated = NILP (arg) ? Qnil : Qt; return w->dedicated; } @@ -2726,9 +2717,7 @@ */ (window)) { - struct window *w = decode_window (window); - - return (make_int (window_left_margin_width (w))); + return make_int (window_left_margin_width (decode_window (window))); } DEFUN ("window-right-margin-pixel-width", @@ -2738,9 +2727,7 @@ */ (window)) { - struct window *w = decode_window (window); - - return (make_int (window_right_margin_width (w))); + return make_int (window_right_margin_width (decode_window (window))); } DEFUN ("delete-other-windows", Fdelete_other_windows, 0, 1, "", /* @@ -3046,7 +3033,7 @@ but to fix set-window-configuration. */ #if 0 else if (EQ (tem, buffer)) - return (Qnil); + return Qnil; #endif else if (! EQ (tem, Qt)) /* w->buffer is t when the window is first being set up. */ @@ -3414,17 +3401,15 @@ */ (n, side, window)) { - struct window *w = decode_window (window); CHECK_INT (n); - change_window_height (w, -XINT (n), !NILP (side)); + change_window_height (decode_window (window), -XINT (n), !NILP (side)); return Qnil; } static int window_pixel_height (Lisp_Object window) { - struct window *w = XWINDOW (window); - return WINDOW_HEIGHT (w); + return WINDOW_HEIGHT (XWINDOW (window)); } static int @@ -3547,7 +3532,7 @@ scrolling on clipped lines just know off the clipped line and return .*/ if (scroll_on_clipped_lines && dl->clip) - return (num_lines - 1); + return num_lines - 1; ypos1 = dl->ypos + dl->descent - dl->clip; } } @@ -3573,8 +3558,7 @@ static int window_pixel_width (Lisp_Object window) { - struct window *w = XWINDOW (window); - return WINDOW_WIDTH (w); + return WINDOW_WIDTH (XWINDOW (window)); } static int @@ -4134,8 +4118,7 @@ else arg = Fprefix_numeric_value (arg); - return - Fset_window_hscroll (window, make_int (w->hscroll + XINT (arg))); + return Fset_window_hscroll (window, make_int (w->hscroll + XINT (arg))); } DEFUN ("scroll-right", Fscroll_right, 0, 1, "_P", /* @@ -4152,8 +4135,7 @@ else arg = Fprefix_numeric_value (arg); - return - Fset_window_hscroll (window, make_int (w->hscroll - XINT (arg))); + return Fset_window_hscroll (window, make_int (w->hscroll - XINT (arg))); } DEFUN ("recenter", Frecenter, 0, 2, "_P", /* @@ -4272,7 +4254,7 @@ retval = line_at_center (w, CMOTION_DISP, start, BUF_PT (b)); } - return (make_int (retval)); + return make_int (retval); } else { @@ -4411,7 +4393,7 @@ compute_scrollbar_instance_usage (d, mir->scrollbar_horizontal_instance, ovstats); } -#endif +#endif /* HAVE_SCROLLBARS */ stats->other_redisplay += compute_display_line_dynarr_usage (mir->current_display_lines, ovstats); stats->other_redisplay += @@ -4581,7 +4563,7 @@ ((markobj) (s->mark)); ((markobj) (s->dedicated)); } - return (Qnil); + return Qnil; } static int @@ -4617,38 +4599,22 @@ static int saved_window_equal (struct saved_window *win1, struct saved_window *win2) { - if (!EQ (win1->window, win2->window)) - return 0; - else if (!EQ (win1->buffer, win2->buffer)) - return 0; - else if (NILP (Fequal (win1->start, win2->start))) - return 0; - else if (NILP (Fequal (win1->pointm, win2->pointm))) - return 0; - else if (NILP (Fequal (win1->sb_point, win2->sb_point))) - return 0; - else if (NILP (Fequal (win1->mark, win2->mark))) - return 0; - else if (win1->pixel_left != win2->pixel_left) - return 0; - else if (win1->pixel_top != win2->pixel_top) - return 0; - else if (win1->pixel_width != win2->pixel_width) - return 0; - else if (win1->pixel_height != win2->pixel_height) - return 0; - else if (win1->hscroll != win2->hscroll) - return 0; - else if (win1->parent_index != win2->parent_index) - return 0; - else if (win1->prev_index != win2->prev_index) - return 0; - else if (!EQ (win1->dedicated, win2->dedicated)) - return 0; - else if (win1->start_at_line_beg != win2->start_at_line_beg) - return 0; - - return 1; + return + EQ (win1->window, win2->window) && + EQ (win1->buffer, win2->buffer) && + !NILP (Fequal (win1->start, win2->start)) && + !NILP (Fequal (win1->pointm, win2->pointm)) && + !NILP (Fequal (win1->sb_point, win2->sb_point)) && + !NILP (Fequal (win1->mark, win2->mark)) && + win1->pixel_left == win2->pixel_left && + win1->pixel_top == win2->pixel_top && + win1->pixel_width == win2->pixel_width && + win1->pixel_height == win2->pixel_height && + win1->hscroll == win2->hscroll && + win1->parent_index == win2->parent_index && + win1->prev_index == win2->prev_index && + EQ (win1->dedicated, win2->dedicated) && + win1->start_at_line_beg == win2->start_at_line_beg; } /* Returns a boolean indicating whether the two given configurations @@ -4666,24 +4632,17 @@ fig1 = XWINDOW_CONFIGURATION (conf1); fig2 = XWINDOW_CONFIGURATION (conf2); - if (fig1->saved_windows_count != fig2->saved_windows_count) - return 0; - else if (!EQ (fig1->current_window, fig2->current_window)) - return 0; - else if (!EQ (fig1->current_buffer, fig2->current_buffer)) - return 0; - else if (!EQ (fig1->root_window, fig2->root_window)) + if (!((fig1->saved_windows_count == fig2->saved_windows_count) && + EQ (fig1->current_window, fig2->current_window) && + EQ (fig1->current_buffer, fig2->current_buffer) && + EQ (fig1->root_window, fig2->root_window) && + EQ (fig1->minibuf_scroll_window, fig2->minibuf_scroll_window) && +#ifdef ENERGIZE + EQ (fig1->p_sheet_buffer, fig2->p_sheet_buffer) && +#endif + fig1->frame_width == fig2->frame_width && + fig1->frame_height == fig2->frame_height)) return 0; - else if (!EQ (fig1->minibuf_scroll_window, fig2->minibuf_scroll_window)) - return 0; - else if (fig1->frame_width != fig2->frame_width) - return 0; - else if (fig1->frame_height != fig2->frame_height) - return 0; -#ifdef ENERGIZE - else if (!EQ (fig1->p_sheet_buffer, fig2->p_sheet_buffer)) - return 0; -#endif for (i = 0; i < fig1->saved_windows_count; i++) { @@ -4700,7 +4659,7 @@ */ (obj)) { - return (WINDOW_CONFIGURATIONP (obj) ? Qt : Qnil); + return WINDOW_CONFIGURATIONP (obj) ? Qt : Qnil; } /* @@ -5127,7 +5086,7 @@ UNGCPRO; - return (Qnil); + return Qnil; } /* Mark all subwindows of a window as deleted. The argument @@ -5167,10 +5126,8 @@ for (j = 0; j < lim; j++) { if (EQ (SAVED_WINDOW_N (config, j)->window, window)) - { - return (j); + return j; } - } abort (); return 0; /* suppress compiler warning */ } @@ -5302,7 +5259,7 @@ } #endif save_window_save (FRAME_ROOT_WINDOW (f), config, 0); - return (result); + return result; } Lisp_Object
--- a/src/xselect.c Mon Aug 13 09:35:15 2007 +0200 +++ b/src/xselect.c Mon Aug 13 09:36:16 2007 +0200 @@ -2218,19 +2218,18 @@ void Xatoms_of_xselect (struct device *d) { -#define ATOM(x) XInternAtom (DEVICE_X_DISPLAY (d), (x), False) -#define ATOMIZE(x) DEVICE_XATOM_##x (d) = ATOM(#x) + Display *D = DEVICE_X_DISPLAY (d); /* Non-predefined atoms that we might end up using a lot */ - ATOMIZE (CLIPBOARD); - ATOMIZE (TIMESTAMP); - ATOMIZE (TEXT); - ATOMIZE (DELETE); - ATOMIZE (MULTIPLE); - ATOMIZE (INCR); - ATOMIZE (TARGETS); - ATOMIZE (NULL); - ATOMIZE (ATOM_PAIR); - ATOMIZE (COMPOUND_TEXT); - DEVICE_XATOM_EMACS_TMP (d) = ATOM ("_EMACS_TMP_"); + DEVICE_XATOM_CLIPBOARD (d) = XInternAtom (D, "CLIPBOARD", False); + DEVICE_XATOM_TIMESTAMP (d) = XInternAtom (D, "TIMESTAMP", False); + DEVICE_XATOM_TEXT (d) = XInternAtom (D, "TEXT", False); + DEVICE_XATOM_DELETE (d) = XInternAtom (D, "DELETE", False); + DEVICE_XATOM_MULTIPLE (d) = XInternAtom (D, "MULTIPLE", False); + DEVICE_XATOM_INCR (d) = XInternAtom (D, "INCR", False); + DEVICE_XATOM_TARGETS (d) = XInternAtom (D, "TARGETS", False); + DEVICE_XATOM_NULL (d) = XInternAtom (D, "NULL", False); + DEVICE_XATOM_ATOM_PAIR (d) = XInternAtom (D, "ATOM_PAIR", False); + DEVICE_XATOM_COMPOUND_TEXT (d) = XInternAtom (D, "COMPOUND_TEXT", False); + DEVICE_XATOM_EMACS_TMP (d) = XInternAtom (D, "_EMACS_TMP_", False); }