From 976b002b16336930724ae22476014583ad022e7d Mon Sep 17 00:00:00 2001 From: tomo Date: Mon, 17 May 1999 09:44:10 +0000 Subject: [PATCH] XEmacs 21.2.14. --- CHANGES-beta | 3 + ChangeLog | 54 + Makefile.in.in | 8 +- aclocal.m4 | 6 +- configure | 1984 ++++++++++++++---------------- configure.in | 81 +- configure.usage | 5 - etc/HELLO | 26 +- etc/NEWS | 167 ++- etc/package-index.LATEST.pgp | 304 ++--- etc/xemacs.1 | 26 + lib-src/ChangeLog | 40 + lib-src/Makefile.in.in | 13 +- lib-src/fakemail.c | 4 + lib-src/gnuclient.c | 6 + lib-src/make-docfile.c | 4 +- lib-src/movemail.c | 1 - lib-src/profile.c | 19 + lib-src/sorted-doc.c | 5 +- lib-src/yow.c | 1 + lisp/ChangeLog | 204 +++ lisp/about.el | 16 +- lisp/auto-autoloads.el | 10 +- lisp/bytecomp.el | 7 +- lisp/check-features.el | 8 +- lisp/cl-extra.el | 5 +- lisp/code-files.el | 2 +- lisp/custom-load.el | 1 + lisp/device.el | 23 + lisp/dumped-lisp.el | 7 +- lisp/faces.el | 2 +- lisp/files.el | 2 +- lisp/format.el | 29 +- lisp/ldap.el | 39 +- lisp/lib-complete.el | 7 +- lisp/loadup.el | 26 +- lisp/make-docfile.el | 4 +- lisp/msw-select.el | 4 +- lisp/mule/cyrillic.el | 105 +- lisp/mule/ethiopic.el | 81 ++ lisp/mule/european.el | 37 +- lisp/mule/mule-charset.el | 18 +- lisp/mule/mule-misc.el | 15 +- lisp/mule/thai-xtis.el | 300 +++++ lisp/mule/vietnamese.el | 279 +++++ lisp/packages.el | 14 +- lisp/simple.el | 2 +- lisp/sound.el | 4 +- lisp/startup.el | 4 +- lisp/subr.el | 23 +- lisp/view-less.el | 1 + lisp/wid-edit.el | 42 +- lisp/x-faces.el | 44 +- lisp/x-font-menu.el | 102 +- lwlib/ChangeLog | 4 + lwlib/xlwmenu.c | 9 +- man/ChangeLog | 36 + man/cl.texi | 5 + man/custom.texi | 8 + man/external-widget.texi | 8 + man/internals/internals.texi | 4 + man/lispref/eval.texi | 2 +- man/lispref/ldap.texi | 11 +- man/lispref/lispref.texi | 5 + man/lispref/mule.texi | 337 ++++- man/new-users-guide/new-users-guide.texi | 5 + man/term.texi | 9 +- man/termcap.texi | 4 + man/widget.texi | 7 + man/xemacs-faq.texi | 11 +- man/xemacs/xemacs.texi | 5 + nt/ChangeLog | 33 + nt/xemacs.mak | 238 ++-- src/ChangeLog | 466 ++++++- src/Makefile.in.in | 42 +- src/alloc.c | 1295 ++----------------- src/buffer.c | 6 +- src/callproc.c | 9 +- src/chartab.c | 8 +- src/config.h.in | 16 +- src/console-msw.h | 2 +- src/console.c | 6 +- src/data.c | 53 +- src/database.c | 2 +- src/depend | 10 +- src/device-msw.c | 5 +- src/device.c | 2 +- src/dired-msw.c | 14 +- src/dired.c | 199 +-- src/eldap.c | 37 +- src/eldap.h | 3 +- src/elhash.c | 4 +- src/emacs.c | 23 +- src/emodules.c | 9 +- src/event-stream.c | 2 +- src/events.c | 4 +- src/extents.c | 12 +- src/faces.c | 4 +- src/file-coding.c | 50 +- src/floatfns.c | 14 +- src/fns.c | 103 +- src/frame-msw.c | 7 +- src/frame.c | 2 +- src/getloadavg.c | 7 +- src/glyphs-msw.c | 4 +- src/glyphs-x.c | 4 +- src/glyphs.c | 4 +- src/gui-x.c | 2 +- src/keymap.c | 4 +- src/lisp-disunion.h | 93 +- src/lisp-union.h | 44 +- src/lisp.h | 209 +--- src/lread.c | 589 +++++---- src/lrecord.h | 135 +- src/lstream.c | 2 +- src/m/intel386.h | 7 - src/make-src-depend | 2 +- src/mem-limits.h | 7 +- src/menubar-x.c | 4 +- src/mule-charset.c | 365 +++--- src/mule-charset.h | 11 +- src/nt.c | 124 +- src/nt.h | 3 + src/ntheap.c | 16 +- src/ntheap.h | 8 +- src/ntplay.c | 2 +- src/ntproc.c | 229 +++- src/objects-msw.c | 49 +- src/objects.c | 28 +- src/opaque.c | 4 +- src/print.c | 69 +- src/process-nt.c | 14 +- src/process.c | 7 +- src/rangetab.c | 4 +- src/realpath.c | 2 +- src/redisplay.c | 7 +- src/sheap.c | 4 +- src/specifier.c | 2 +- src/src-headers | 2 +- src/symbols.c | 125 +- src/symeval.h | 7 +- src/symsinit.h | 1 + src/syntax.c | 4 +- src/sysdep.c | 69 +- src/sysdir.h | 2 +- src/systime.h | 2 +- src/systty.h | 2 + src/toolbar-msw.c | 5 +- src/toolbar.c | 2 +- src/tooltalk.c | 4 +- src/unexcw.c | 2 +- src/unexnt.c | 63 - src/window.c | 149 ++- tests/ChangeLog | 27 + tests/automated/byte-compiler-tests.el | 2 +- tests/automated/database-tests.el | 4 +- tests/automated/hash-table-tests.el | 20 +- tests/automated/lisp-tests.el | 56 +- tests/automated/md5-tests.el | 2 +- tests/automated/test-harness.el | 32 +- version.sh | 6 +- 161 files changed, 5477 insertions(+), 4550 deletions(-) create mode 100644 lisp/mule/ethiopic.el create mode 100644 lisp/mule/thai-xtis.el create mode 100644 lisp/mule/vietnamese.el diff --git a/CHANGES-beta b/CHANGES-beta index 6924d6b..48c24ee 100644 --- a/CHANGES-beta +++ b/CHANGES-beta @@ -1,4 +1,7 @@ -*- indented-text -*- +to 21.2.14 "" +-- mingw32 port from Andy Piper + to 21.2.13 "Demeter" -- Build fixes from Martin Buchholz -- experimental splash screen rewrite from Didier Verna diff --git a/ChangeLog b/ChangeLog index 7057cf3..bb8025d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,57 @@ +1999-05-14 XEmacs Build Bot + + * XEmacs 21.2.14 is released + +1999-05-11 SL Baur + + * version.sh (infodock_build_version): Synch InfoDock version. + +1999-05-06 Hrvoje Niksic + + * aclocal.m4 (ld_dynamic_link_flags): Change -Bexport to -Bdynamic + for Solaris. + +1999-05-03 Hrvoje Niksic + + * configure.in (xemacs_betaname): Don't generate Installation.el. + + * Makefile.in.in (top_distclean): Don't remove Installation.el. + +1999-04-29 Andy Piper + + * configure.in: add mingw32 as a target platform. add nt process + support options. + +1999-03-30 MORIOKA Tomohiko + + * etc/HELLO (Amharic): New language. + (Slovak): Likewise. + (Thai): Likewise (by Virach Sornlertlamvanich). + (Greek): Fixed (by Yannis Haralambous). + +1998-09-04 MORIOKA Tomohiko + + * configure.in: Delete mule-coding.o. + +1999-04-22 Gunnar Evermann + + * lwlib/xlwmenu.c (string_width_u): Initialise chars before + calling XmStringGetLtoR + (string_draw_u): ditto and check return value of XmStringGetLtoR() + +1999-04-05 Olivier Galibert + + * Makefile.in.in (GENERATED_HEADERS): Don't generate + puresize-adjust.h anymore + + * configure.usage: Remove everything gung-ho or purespace related + + * configure.in: Ditto + +1999-04-17 Hrvoje Niksic + + * configure.in: Check for getloadavg(). + 1999-03-12 XEmacs Build Bot * XEmacs 21.2.13 is released diff --git a/Makefile.in.in b/Makefile.in.in index 92f8f30..69496da 100644 --- a/Makefile.in.in +++ b/Makefile.in.in @@ -228,7 +228,7 @@ INSTALL_ARCH_DEP_SUBDIR = @INSTALL_ARCH_DEP_SUBDIR@ ## instead, we have written out explicit code in the `install' targets. COPYDIR = ${srcdir}/etc ${srcdir}/lisp COPYDESTS = ${etcdir} ${lispdir} -GENERATED_HEADERS = src/paths.h src/Emacs.ad.h src/puresize-adjust.h src/config.h lwlib/config.h src/sheap-adjust.h +GENERATED_HEADERS = src/paths.h src/Emacs.ad.h src/config.h lwlib/config.h src/sheap-adjust.h GENERATED_LISP = lisp/finder-inf.el all: ${PROGNAME} all-elc info @@ -309,12 +309,6 @@ src/Emacs.ad.h: ${srcdir}/etc/Emacs.ad /bin/sh ${srcdir}/lib-src/ad2c ${srcdir}/etc/Emacs.ad ) > \ src/Emacs.ad.h -src/puresize-adjust.h: ${srcdir}/src/puresize.h - @echo "Resetting \`src/puresize-adjust.h'."; \ - (echo "/* Do not edit this file!" ; \ - echo " Automatically generated by XEmacs */" ; \ - echo "#define PURESIZE_ADJUSTMENT 0") > $@ - src/sheap-adjust.h: @echo "Resetting \`src/sheap-adjust.h'."; \ (echo "/* Do not edit this file!" ; \ diff --git a/aclocal.m4 b/aclocal.m4 index 1348285..ff5c7ae 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -568,7 +568,11 @@ if test -z "$ld_dynamic_link_flags"; then ld_dynamic_link_flags= ;; - sco3.2v5* | unixware* | sysv5* | sysv4* | solaris2* | solaris7*) + solaris2* | solaris7*) + ld_dynamic_link_flags="${wl}-Bdynamic" + ;; + + sco3.2v5* | unixware* | sysv5* | sysv4*) ld_dynamic_link_flags="${wl}-Bexport" ;; diff --git a/configure b/configure index 8092ac2..8e677b0 100755 --- a/configure +++ b/configure @@ -2,7 +2,7 @@ #### Configuration script for XEmacs. Largely divergent from FSF. #### Guess values for system-dependent variables and create Makefiles. -#### Generated automatically using autoconf version 2.13 +#### 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. @@ -199,8 +199,6 @@ ac_compile='${CC-cc} -c $CFLAGS '"$xe_cppflags"' conftest.$ac_ext 1>&5' ac_link='${CC-cc} -o conftest $CFLAGS '"$xe_cppflags $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' cross_compiling=no -ac_exeext= -ac_objext=o 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 @@ -245,7 +243,6 @@ with_menubars='' with_scrollbars='' with_dialogs='' with_file_coding='' -puresize='' cpp='' cppflags='' libs='' ldflags='' dynamic='' with_x11='' @@ -356,9 +353,6 @@ while test $# != 0; do use_union_type | \ debug | \ use_assertions | \ - gung_ho | \ - use_minimal_tagbits | \ - use_indexed_lrecord_implementation | \ memory_usage_stats | \ with_clash_detection | \ with_shlib | \ @@ -380,7 +374,6 @@ echo " Use \`$progname --help' to show usage.") >&2 && exit 1 ;; cppflags | \ libs | \ ldflags | \ - puresize | \ cache_file | \ native_sound_lib| \ site_lisp | \ @@ -714,19 +707,6 @@ if test "$with_purify" = "yes" -o "$with_quantify" = "yes"; then test "$with_system_malloc" = "default" && with_system_malloc=yes fi -if test -n "$gung_ho"; then - test -z "$use_minimal_tagbits" && use_minimal_tagbits="$gung_ho" - test -z "$use_indexed_lrecord_implementation" && \ - use_indexed_lrecord_implementation="$gung_ho" -fi -if test "$use_minimal_tagbits" = "no"; then - test "$with_dlmalloc" = "yes" && \ - (echo "$progname: Usage error:" -echo " " "--with-dlmalloc requires --use-minimal-tagbits" -echo " Use \`$progname --help' to show usage.") >&2 && exit 1 - with_dlmalloc=no -fi - if test "$with_cde $with_tooltalk" = "yes no"; then @@ -783,7 +763,7 @@ echo " Use \`$progname --help' to show usage.") >&2 && exit 1 fi echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6 -echo "configure:787: checking whether ln -s works" >&5 +echo "configure:767: checking whether ln -s works" >&5 rm -f conftestdata if ln -s X conftestdata 2>/dev/null @@ -1008,7 +988,7 @@ EOF echo $ac_n "checking "host system type"""... $ac_c" 1>&6 -echo "configure:1012: checking "host system type"" >&5 +echo "configure:992: checking "host system type"" >&5 internal_configuration=`echo $configuration | sed 's/-\(workshop\)//'` canonical=`${CONFIG_SHELL-/bin/sh} $srcdir/config.sub "$internal_configuration"` configuration=`echo "$configuration" | sed 's/^\([^-][^-]*-[^-][^-]*-[^-][^-]*\)-.*$/\1/'` @@ -1394,7 +1374,9 @@ EOF *-386bsd* ) opsys=386bsd ;; *-freebsd* ) opsys=freebsd ;; *-nextstep* ) opsys=nextstep ;; - *-pc-cygwin32 ) opsys=cygwin32 ;; + *-pc-cygwin* ) opsys=cygwin32 ;; + *-pc-mingw* ) opsys=mingw32 ; + test -z "$with_tty" && with_tty="no";; esac ;; @@ -1498,14 +1480,13 @@ xe_save_CFLAGS="$CFLAGS" # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1502: checking for $ac_word" >&5 +echo "configure:1484: 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=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do + 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" @@ -1525,15 +1506,14 @@ 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:1529: checking for $ac_word" >&5 +echo "configure:1510: 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="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ac_prog_rejected=no - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do + 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 @@ -1567,42 +1547,11 @@ else echo "$ac_t""no" 1>&6 fi - if test -z "$CC"; then - case "`uname -s`" in - *win32* | *WIN32*) - # Extract the first word of "cl", so it can be a program name with args. -set dummy cl; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1577: 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=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_prog_CC="cl" - 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 - ;; - esac - 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:1606: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:1555: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' @@ -1613,14 +1562,12 @@ ac_compile='${CC-cc} -c $CFLAGS '"$xe_cppflags"' conftest.$ac_ext 1>&5' ac_link='${CC-cc} -o conftest $CFLAGS '"$xe_cppflags $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' cross_compiling=no -cat > conftest.$ac_ext << EOF - -#line 1619 "configure" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1571: \"$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 @@ -1634,33 +1581,25 @@ else ac_cv_prog_cc_works=no fi rm -fr conftest* -ac_ext=c -xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' -xe_ldflags='$LDFLAGS $ld_switch_site $ld_switch_machine $ld_switch_system $ld_switch_x_site $ld_switch_run' -xe_libs='$ld_call_shared $xe_check_libs $X_EXTRA_LIBS $libs_x $X_PRE_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 $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' -cross_compiling=no 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:1652: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:1591: 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:1657: checking whether we are using GNU C" >&5 +echo "configure:1596: checking whether we are using GNU C" >&5 cat > conftest.c <&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1603: \"$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 @@ -1670,15 +1609,11 @@ echo "$ac_t""$ac_cv_prog_gcc" 1>&6 if test $ac_cv_prog_gcc = yes; then GCC=yes -else - GCC= -fi - -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:1682: checking whether ${CC-cc} accepts -g" >&5 + 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:1617: checking whether ${CC-cc} accepts -g" >&5 echo 'void f(){}' > conftest.c if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then @@ -1690,20 +1625,16 @@ 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 - if test "$GCC" = yes; then + 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="-g" - fi -else - if test "$GCC" = yes; then CFLAGS="-O2" - else - CFLAGS= fi +else + GCC= + test "${CFLAGS+set}" = set || CFLAGS="-g" fi if test "$with_gcc" = "no" -a "$GCC" = "yes"; then @@ -1711,14 +1642,13 @@ if test "$with_gcc" = "no" -a "$GCC" = "yes"; then # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1715: checking for $ac_word" >&5 +echo "configure:1646: 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=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do + 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" @@ -1738,15 +1668,14 @@ 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:1742: checking for $ac_word" >&5 +echo "configure:1672: 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="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ac_prog_rejected=no - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do + 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 @@ -1780,42 +1709,11 @@ else echo "$ac_t""no" 1>&6 fi - if test -z "$CC"; then - case "`uname -s`" in - *win32* | *WIN32*) - # Extract the first word of "cl", so it can be a program name with args. -set dummy cl; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1790: 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=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_prog_CC="cl" - 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 - ;; - esac - 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:1819: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:1717: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' @@ -1826,14 +1724,12 @@ ac_compile='${CC-cc} -c $CFLAGS '"$xe_cppflags"' conftest.$ac_ext 1>&5' ac_link='${CC-cc} -o conftest $CFLAGS '"$xe_cppflags $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' cross_compiling=no -cat > conftest.$ac_ext << EOF - -#line 1832 "configure" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1733: \"$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 @@ -1847,33 +1743,25 @@ else ac_cv_prog_cc_works=no fi rm -fr conftest* -ac_ext=c -xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' -xe_ldflags='$LDFLAGS $ld_switch_site $ld_switch_machine $ld_switch_system $ld_switch_x_site $ld_switch_run' -xe_libs='$ld_call_shared $xe_check_libs $X_EXTRA_LIBS $libs_x $X_PRE_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 $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' -cross_compiling=no 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:1865: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:1753: 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:1870: checking whether we are using GNU C" >&5 +echo "configure:1758: checking whether we are using GNU C" >&5 cat > conftest.c <&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1765: \"$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 @@ -1883,15 +1771,11 @@ echo "$ac_t""$ac_cv_prog_gcc" 1>&6 if test $ac_cv_prog_gcc = yes; then GCC=yes -else - GCC= -fi - -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:1895: checking whether ${CC-cc} accepts -g" >&5 + 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:1779: checking whether ${CC-cc} accepts -g" >&5 echo 'void f(){}' > conftest.c if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then @@ -1903,20 +1787,16 @@ 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 - if test "$GCC" = yes; then + 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="-g" - fi -else - if test "$GCC" = yes; then CFLAGS="-O2" - else - CFLAGS= fi +else + GCC= + test "${CFLAGS+set}" = set || CFLAGS="-g" fi elif test "$with_gcc" = "yes" -a "$GCC" != "yes" ; then @@ -1924,14 +1804,13 @@ elif test "$with_gcc" = "yes" -a "$GCC" != "yes" ; then # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1928: checking for $ac_word" >&5 +echo "configure:1808: 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=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do + 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" @@ -1951,15 +1830,14 @@ 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:1955: checking for $ac_word" >&5 +echo "configure:1834: 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="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ac_prog_rejected=no - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do + 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 @@ -1993,42 +1871,11 @@ else echo "$ac_t""no" 1>&6 fi - if test -z "$CC"; then - case "`uname -s`" in - *win32* | *WIN32*) - # Extract the first word of "cl", so it can be a program name with args. -set dummy cl; ac_word=$2 -echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2003: 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=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$ac_word; then - ac_cv_prog_CC="cl" - 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 - ;; - esac - 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:2032: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 +echo "configure:1879: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 ac_ext=c xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' @@ -2039,14 +1886,12 @@ ac_compile='${CC-cc} -c $CFLAGS '"$xe_cppflags"' conftest.$ac_ext 1>&5' ac_link='${CC-cc} -o conftest $CFLAGS '"$xe_cppflags $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' cross_compiling=no -cat > conftest.$ac_ext << EOF - -#line 2045 "configure" +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1895: \"$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 @@ -2060,33 +1905,25 @@ else ac_cv_prog_cc_works=no fi rm -fr conftest* -ac_ext=c -xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS' -xe_ldflags='$LDFLAGS $ld_switch_site $ld_switch_machine $ld_switch_system $ld_switch_x_site $ld_switch_run' -xe_libs='$ld_call_shared $xe_check_libs $X_EXTRA_LIBS $libs_x $X_PRE_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 $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' -cross_compiling=no 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:2078: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 +echo "configure:1915: 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:2083: checking whether we are using GNU C" >&5 +echo "configure:1920: checking whether we are using GNU C" >&5 cat > conftest.c <&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then +if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1927: \"$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 @@ -2096,15 +1933,11 @@ echo "$ac_t""$ac_cv_prog_gcc" 1>&6 if test $ac_cv_prog_gcc = yes; then GCC=yes -else - GCC= -fi - -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:2108: checking whether ${CC-cc} accepts -g" >&5 + 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:1941: checking whether ${CC-cc} accepts -g" >&5 echo 'void f(){}' > conftest.c if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then @@ -2116,20 +1949,16 @@ 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 - if test "$GCC" = yes; then + 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="-g" - fi -else - if test "$GCC" = yes; then CFLAGS="-O2" - else - CFLAGS= fi +else + GCC= + test "${CFLAGS+set}" = set || CFLAGS="-g" fi fi @@ -2141,7 +1970,7 @@ test -n "$CPP" -a -d "$CPP" && CPP= test -n "$NON_GNU_CPP" -a "$GCC" != "yes" -a -z "$CPP" && CPP="$NON_GNU_CPP" echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:2145: checking how to run the C preprocessor" >&5 +echo "configure:1974: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -2154,14 +1983,14 @@ if test -z "$CPP"; then # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2164: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:1993: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then : else @@ -2171,31 +2000,14 @@ else rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext < -Syntax Error -EOF -ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2181: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` -if test -z "$ac_err"; then - : -else - echo "$ac_err" >&5 - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - CPP="${CC-cc} -nologo -E" - cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2198: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:2010: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then : else @@ -2208,8 +2020,6 @@ fi rm -f conftest* fi rm -f conftest* -fi -rm -f conftest* ac_cv_prog_CPP="$CPP" CPP="$ac_cv_prog_CPP" else @@ -2219,9 +2029,9 @@ echo "$ac_t""$CPP" 1>&6 echo $ac_n "checking for AIX""... $ac_c" 1>&6 -echo "configure:2223: checking for AIX" >&5 +echo "configure:2033: checking for AIX" >&5 cat > conftest.$ac_ext <&6 -echo "configure:2252: checking for GNU libc" >&5 +echo "configure:2062: checking for GNU libc" >&5 cat > conftest.$ac_ext < int main() { @@ -2262,7 +2072,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:2266: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2076: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* have_glibc=yes else @@ -2284,7 +2094,7 @@ EOF cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:2110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then : else @@ -2469,6 +2279,12 @@ configure___ mail_use_lockf=yes configure___ mail_use_lockf=no #endif +#ifdef HAVE_WIN32_PROCESSES +configure___ win32_processes=yes +#else +configure___ win32_processes=no +#endif + EOF CPP=`eval "echo $CPP $CPPFLAGS"` @@ -2487,7 +2303,7 @@ test "$__DECC" = "yes" && c_switch_site="$c_switch_site -std" && if test "$extr if test "$cflags_specified" = "no"; then if test "$GCC" = "yes"; then CFLAGS="-g -O3 -Wall -Wno-switch" - elif test "$__SUNPRO_C" = "yes"; then + elif test "$__SUNPRO_C" = "yes"; then case "$opsys" in sol2 ) CFLAGS="-v -xO4" ;; sunos4* ) CFLAGS="-xO2";; @@ -2564,7 +2380,7 @@ test -n "$unexec" && extra_objs="$extra_objs $unexec" && if test "$ext fi echo $ac_n "checking for dynodump""... $ac_c" 1>&6 -echo "configure:2568: checking for dynodump" >&5 +echo "configure:2384: checking for dynodump" >&5 if test "$unexec" != "unexsol2.o"; then echo "$ac_t""no" 1>&6 else @@ -2602,12 +2418,12 @@ if test "$unexec" = "unexaix.o"; then done echo $ac_n "checking for terminateAndUnload in -lC""... $ac_c" 1>&6 -echo "configure:2606: checking for terminateAndUnload in -lC" >&5 +echo "configure:2422: checking for terminateAndUnload in -lC" >&5 ac_lib_var=`echo C'_'terminateAndUnload | sed 'y%./+-%__p_%'` xe_check_libs=" -lC " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2438: \"$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 @@ -2722,7 +2538,7 @@ fi if test "$add_runtime_path" = "yes"; then echo $ac_n "checking "for runtime libraries flag"""... $ac_c" 1>&6 -echo "configure:2726: checking "for runtime libraries flag"" >&5 +echo "configure:2542: checking "for runtime libraries flag"" >&5 case "$opsys" in sol2 ) dash_r="-R" ;; decosf* | linux* | irix*) dash_r="-rpath " ;; @@ -2744,14 +2560,14 @@ if test "$GCC" = "yes"; then done fi cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2571: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* dash_r="$try_dash_r" else @@ -2853,10 +2669,10 @@ else fi after_morecore_hook_exists=yes echo $ac_n "checking for malloc_get_state""... $ac_c" 1>&6 -echo "configure:2857: checking for malloc_get_state" >&5 +echo "configure:2673: checking for malloc_get_state" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_malloc_get_state=yes" else @@ -2899,10 +2715,10 @@ doug_lea_malloc=no fi echo $ac_n "checking for malloc_set_state""... $ac_c" 1>&6 -echo "configure:2903: checking for malloc_set_state" >&5 +echo "configure:2719: checking for malloc_set_state" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2745: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_malloc_set_state=yes" else @@ -2945,16 +2761,16 @@ doug_lea_malloc=no fi echo $ac_n "checking whether __after_morecore_hook exists""... $ac_c" 1>&6 -echo "configure:2949: checking whether __after_morecore_hook exists" >&5 +echo "configure:2765: checking whether __after_morecore_hook exists" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* echo "$ac_t""yes" 1>&6 else @@ -3013,14 +2829,13 @@ 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:3017: checking for $ac_word" >&5 +echo "configure:2833: 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=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do + 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_RANLIB="ranlib" @@ -3063,28 +2878,26 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # 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:3072: checking for a BSD compatible install" >&5 +echo "configure:2886: checking for a BSD compatible install" >&5 if test -z "$INSTALL"; then - IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" + IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:" for ac_dir in $PATH; do # 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. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall 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 # AIX install. It has an incompatible calling convention. + # OSF/1 installbsd also uses dspmsg, but is usable. : else ac_cv_path_install="$ac_dir/$ac_prog -c" @@ -3113,8 +2926,6 @@ echo "$ac_t""$INSTALL" 1>&6 # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' - test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' for ac_prog in 'bison -y' byacc @@ -3122,14 +2933,13 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:3126: checking for $ac_word" >&5 +echo "configure:2937: 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=":" - ac_dummy="$PATH" - for ac_dir in $ac_dummy; do + 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_YACC="$ac_prog" @@ -3154,16 +2964,16 @@ for ac_hdr in mach/mach.h sys/stropts.h sys/timeb.h sys/time.h unistd.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3158: checking for $ac_hdr" >&5 +echo "configure:2968: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3166: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:2976: \"$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" @@ -3195,16 +3005,16 @@ for ac_hdr in utime.h locale.h libgen.h fcntl.h ulimit.h cygwin/version.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3199: checking for $ac_hdr" >&5 +echo "configure:3009: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3207: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:3017: \"$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" @@ -3236,16 +3046,16 @@ for ac_hdr in kstat.h sys/pstat.h inttypes.h sys/un.h a.out.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:3240: checking for $ac_hdr" >&5 +echo "configure:3050: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3248: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:3058: \"$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" @@ -3274,10 +3084,10 @@ fi done echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 -echo "configure:3278: checking for sys/wait.h that is POSIX.1 compatible" >&5 +echo "configure:3088: checking for sys/wait.h that is POSIX.1 compatible" >&5 cat > conftest.$ac_ext < #include @@ -3293,7 +3103,7 @@ wait (&s); s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; ; return 0; } EOF -if { (eval echo configure:3297: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3107: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_sys_wait_h=yes else @@ -3317,10 +3127,10 @@ EOF fi echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 -echo "configure:3321: checking for ANSI C header files" >&5 +echo "configure:3131: checking for ANSI C header files" >&5 cat > conftest.$ac_ext < #include @@ -3328,8 +3138,8 @@ cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3332: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:3142: \"$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 @@ -3345,7 +3155,7 @@ rm -f conftest* if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat > conftest.$ac_ext < EOF @@ -3363,7 +3173,7 @@ fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat > conftest.$ac_ext < EOF @@ -3381,7 +3191,7 @@ fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. cat > conftest.$ac_ext < #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') @@ -3392,7 +3202,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); exit (0); } EOF -if { (eval echo configure:3396: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:3206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then : else @@ -3418,10 +3228,10 @@ EOF fi echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 -echo "configure:3422: checking whether time.h and sys/time.h may both be included" >&5 +echo "configure:3232: checking whether time.h and sys/time.h may both be included" >&5 cat > conftest.$ac_ext < #include @@ -3430,7 +3240,7 @@ int main() { struct tm *tp; ; return 0; } EOF -if { (eval echo configure:3434: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3244: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_time=yes else @@ -3454,10 +3264,10 @@ EOF fi echo $ac_n "checking for sys_siglist declaration in signal.h or unistd.h""... $ac_c" 1>&6 -echo "configure:3458: checking for sys_siglist declaration in signal.h or unistd.h" >&5 +echo "configure:3268: checking for sys_siglist declaration in signal.h or unistd.h" >&5 cat > conftest.$ac_ext < #include @@ -3469,7 +3279,7 @@ int main() { char *msg = *(sys_siglist + 1); ; return 0; } EOF -if { (eval echo configure:3473: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3283: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_decl_sys_siglist=yes else @@ -3494,9 +3304,9 @@ fi echo $ac_n "checking for struct utimbuf""... $ac_c" 1>&6 -echo "configure:3498: checking for struct utimbuf" >&5 +echo "configure:3308: checking for struct utimbuf" >&5 cat > conftest.$ac_ext < @@ -3515,7 +3325,7 @@ int main() { static struct utimbuf x; x.actime = x.modtime; ; return 0; } EOF -if { (eval echo configure:3519: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3329: \"$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 @@ -3535,10 +3345,10 @@ fi rm -f conftest* echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 -echo "configure:3539: checking return type of signal handlers" >&5 +echo "configure:3349: checking return type of signal handlers" >&5 cat > conftest.$ac_ext < #include @@ -3555,7 +3365,7 @@ int main() { int i; ; return 0; } EOF -if { (eval echo configure:3559: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3369: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_type_signal=void else @@ -3577,10 +3387,10 @@ EOF echo $ac_n "checking for size_t""... $ac_c" 1>&6 -echo "configure:3581: checking for size_t" >&5 +echo "configure:3391: checking for size_t" >&5 cat > conftest.$ac_ext < #if STDC_HEADERS @@ -3589,7 +3399,7 @@ cat > conftest.$ac_ext <&5 | - egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then + egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then rm -rf conftest* ac_cv_type_size_t=yes else @@ -3611,10 +3421,10 @@ EOF fi echo $ac_n "checking for pid_t""... $ac_c" 1>&6 -echo "configure:3615: checking for pid_t" >&5 +echo "configure:3425: checking for pid_t" >&5 cat > conftest.$ac_ext < #if STDC_HEADERS @@ -3623,7 +3433,7 @@ cat > conftest.$ac_ext <&5 | - egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then + egrep "pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then rm -rf conftest* ac_cv_type_pid_t=yes else @@ -3645,10 +3455,10 @@ EOF fi echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 -echo "configure:3649: checking for uid_t in sys/types.h" >&5 +echo "configure:3459: checking for uid_t in sys/types.h" >&5 cat > conftest.$ac_ext < EOF @@ -3684,10 +3494,10 @@ EOF fi echo $ac_n "checking for mode_t""... $ac_c" 1>&6 -echo "configure:3688: checking for mode_t" >&5 +echo "configure:3498: checking for mode_t" >&5 cat > conftest.$ac_ext < #if STDC_HEADERS @@ -3696,7 +3506,7 @@ cat > conftest.$ac_ext <&5 | - egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then + egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then rm -rf conftest* ac_cv_type_mode_t=yes else @@ -3718,10 +3528,10 @@ EOF fi echo $ac_n "checking for off_t""... $ac_c" 1>&6 -echo "configure:3722: checking for off_t" >&5 +echo "configure:3532: checking for off_t" >&5 cat > conftest.$ac_ext < #if STDC_HEADERS @@ -3730,7 +3540,7 @@ cat > conftest.$ac_ext <&5 | - egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then + egrep "off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then rm -rf conftest* ac_cv_type_off_t=yes else @@ -3753,9 +3563,9 @@ fi echo $ac_n "checking for struct timeval""... $ac_c" 1>&6 -echo "configure:3757: checking for struct timeval" >&5 +echo "configure:3567: checking for struct timeval" >&5 cat > conftest.$ac_ext < @@ -3771,7 +3581,7 @@ int main() { static struct timeval x; x.tv_sec = x.tv_usec; ; return 0; } EOF -if { (eval echo configure:3775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3585: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 HAVE_TIMEVAL=yes @@ -3793,10 +3603,10 @@ fi rm -f conftest* echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 -echo "configure:3797: checking whether struct tm is in sys/time.h or time.h" >&5 +echo "configure:3607: checking whether struct tm is in sys/time.h or time.h" >&5 cat > conftest.$ac_ext < #include @@ -3804,7 +3614,7 @@ int main() { struct tm *tp; tp->tm_sec; ; return 0; } EOF -if { (eval echo configure:3808: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3618: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm=time.h else @@ -3828,10 +3638,10 @@ EOF fi echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 -echo "configure:3832: checking for tm_zone in struct tm" >&5 +echo "configure:3642: checking for tm_zone in struct tm" >&5 cat > conftest.$ac_ext < #include <$ac_cv_struct_tm> @@ -3839,7 +3649,7 @@ int main() { struct tm tm; tm.tm_zone; ; return 0; } EOF -if { (eval echo configure:3843: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3653: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_struct_tm_zone=yes else @@ -3862,10 +3672,10 @@ EOF else echo $ac_n "checking for tzname""... $ac_c" 1>&6 -echo "configure:3866: checking for tzname" >&5 +echo "configure:3676: checking for tzname" >&5 cat > conftest.$ac_ext < #ifndef tzname /* For SGI. */ @@ -3875,7 +3685,7 @@ int main() { atoi(*tzname); ; return 0; } EOF -if { (eval echo configure:3879: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* ac_cv_var_tzname=yes else @@ -3901,10 +3711,10 @@ fi echo $ac_n "checking for working const""... $ac_c" 1>&6 -echo "configure:3905: checking for working const" >&5 +echo "configure:3715: checking for working const" >&5 cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3767: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_const=yes else @@ -3978,7 +3788,7 @@ fi echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 -echo "configure:3982: checking whether ${MAKE-make} sets \${MAKE}" >&5 +echo "configure:3792: checking whether ${MAKE-make} sets \${MAKE}" >&5 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` cat > conftestmake <<\EOF @@ -4003,12 +3813,12 @@ fi echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 -echo "configure:4007: checking whether byte ordering is bigendian" >&5 +echo "configure:3817: checking whether byte ordering is bigendian" >&5 ac_cv_c_bigendian=unknown # See if sys/param.h defines the BYTE_ORDER macro. cat > conftest.$ac_ext < #include @@ -4019,11 +3829,11 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:4023: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3833: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* # It does; now see whether it defined to BIG_ENDIAN or not. cat > conftest.$ac_ext < #include @@ -4034,7 +3844,7 @@ int main() { #endif ; return 0; } EOF -if { (eval echo configure:4038: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:3848: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_bigendian=yes else @@ -4051,7 +3861,7 @@ fi rm -f conftest* if test $ac_cv_c_bigendian = unknown; then cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:3878: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_c_bigendian=no else @@ -4091,10 +3901,10 @@ fi echo $ac_n "checking size of short""... $ac_c" 1>&6 -echo "configure:4095: checking size of short" >&5 +echo "configure:3905: checking size of short" >&5 cat > conftest.$ac_ext < main() @@ -4105,7 +3915,7 @@ main() exit(0); } EOF -if { (eval echo configure:4109: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:3919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_short=`cat conftestval` else @@ -4133,10 +3943,10 @@ if test "$ac_cv_sizeof_short" = 0; then exit 1 fi echo $ac_n "checking size of int""... $ac_c" 1>&6 -echo "configure:4137: checking size of int" >&5 +echo "configure:3947: checking size of int" >&5 cat > conftest.$ac_ext < main() @@ -4147,7 +3957,7 @@ main() exit(0); } EOF -if { (eval echo configure:4151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:3961: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_int=`cat conftestval` else @@ -4169,10 +3979,10 @@ EOF echo $ac_n "checking size of long""... $ac_c" 1>&6 -echo "configure:4173: checking size of long" >&5 +echo "configure:3983: checking size of long" >&5 cat > conftest.$ac_ext < main() @@ -4183,7 +3993,7 @@ main() exit(0); } EOF -if { (eval echo configure:4187: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:3997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_long=`cat conftestval` else @@ -4205,10 +4015,10 @@ EOF echo $ac_n "checking size of long long""... $ac_c" 1>&6 -echo "configure:4209: checking size of long long" >&5 +echo "configure:4019: checking size of long long" >&5 cat > conftest.$ac_ext < main() @@ -4219,7 +4029,7 @@ main() exit(0); } EOF -if { (eval echo configure:4223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:4033: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_long_long=`cat conftestval` else @@ -4241,10 +4051,10 @@ EOF echo $ac_n "checking size of void *""... $ac_c" 1>&6 -echo "configure:4245: checking size of void *" >&5 +echo "configure:4055: checking size of void *" >&5 cat > conftest.$ac_ext < main() @@ -4255,7 +4065,7 @@ main() exit(0); } EOF -if { (eval echo configure:4259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:4069: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_sizeof_void_p=`cat conftestval` else @@ -4278,7 +4088,7 @@ EOF echo $ac_n "checking for long file names""... $ac_c" 1>&6 -echo "configure:4282: checking for long file names" >&5 +echo "configure:4092: 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: @@ -4323,14 +4133,57 @@ EOF fi +echo $ac_n "checking for sin""... $ac_c" 1>&6 +echo "configure:4138: checking for sin" >&5 + +cat > conftest.$ac_ext < +/* 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 sin(); + +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_sin) || defined (__stub___sin) +choke me +#else +sin(); +#endif + +; return 0; } +EOF +if { (eval echo configure:4164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + eval "ac_cv_func_sin=yes" +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + eval "ac_cv_func_sin=no" +fi +rm -f conftest* + +if eval "test \"`echo '$ac_cv_func_'sin`\" = yes"; then + echo "$ac_t""yes" 1>&6 + : +else + echo "$ac_t""no" 1>&6 echo $ac_n "checking for sin in -lm""... $ac_c" 1>&6 -echo "configure:4329: checking for sin in -lm" >&5 +echo "configure:4182: checking for sin in -lm" >&5 ac_lib_var=`echo m'_'sin | sed 'y%./+-%__p_%'` xe_check_libs=" -lm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4198: \"$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 @@ -4355,7 +4208,7 @@ 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' \ + 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 @@ -4372,6 +4225,8 @@ else fi +fi + { test "$extra_verbose" = "yes" && cat << \EOF Defining LISP_FLOAT_TYPE @@ -4383,14 +4238,14 @@ EOF cat > conftest.$ac_ext < int main() { return atanh(1.0) + asinh(1.0) + acosh(1.0); ; return 0; } EOF -if { (eval echo configure:4394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_INVERSE_HYPERBOLIC @@ -4407,7 +4262,7 @@ fi rm -f conftest* echo "checking type of mail spool file locking" 1>&6 -echo "configure:4411: checking type of mail spool file locking" >&5 +echo "configure:4266: 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 @@ -4429,115 +4284,15 @@ EOF else mail_locking="dot-locking" fi - -echo $ac_n "checking for kstat_open in -lkstat""... $ac_c" 1>&6 -echo "configure:4435: checking for kstat_open in -lkstat" >&5 -ac_lib_var=`echo kstat'_'kstat_open | sed 'y%./+-%__p_%'` - -xe_check_libs=" -lkstat " -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - 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 <&6 -fi - - - - -echo $ac_n "checking for kvm_read in -lkvm""... $ac_c" 1>&6 -echo "configure:4485: checking for kvm_read in -lkvm" >&5 -ac_lib_var=`echo kvm'_'kvm_read | sed 'y%./+-%__p_%'` - -xe_check_libs=" -lkvm " -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - 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 <&6 -fi - - - case "$opsys" in decosf*) echo $ac_n "checking for cma_open in -lpthreads""... $ac_c" 1>&6 -echo "configure:4536: checking for cma_open in -lpthreads" >&5 +echo "configure:4291: checking for cma_open in -lpthreads" >&5 ac_lib_var=`echo pthreads'_'cma_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lpthreads " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4307: \"$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 @@ -4584,7 +4339,7 @@ fi esac echo $ac_n "checking whether the -xildoff compiler flag is required""... $ac_c" 1>&6 -echo "configure:4588: checking whether the -xildoff compiler flag is required" >&5 +echo "configure:4343: 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; @@ -4595,7 +4350,7 @@ fi if test "$opsys" = "sol2" && test "$OS_RELEASE" -ge 56; then echo $ac_n "checking for \"-z ignore\" linker flag""... $ac_c" 1>&6 -echo "configure:4599: checking for \"-z ignore\" linker flag" >&5 +echo "configure:4354: checking for \"-z ignore\" linker flag" >&5 case "`ld -h 2>&1`" in *-z\ ignore\|record* ) echo "$ac_t""yes" 1>&6 ld_switch_site="-z ignore $ld_switch_site" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-z ignore\" to \$ld_switch_site"; fi ;; @@ -4605,7 +4360,7 @@ fi echo "checking "for specified window system"" 1>&6 -echo "configure:4609: checking "for specified window system"" >&5 +echo "configure:4364: checking "for specified window system"" >&5 if test "$with_x11" != "no"; then test "$x_includes $x_libraries" != "NONE NONE" && \ @@ -4638,7 +4393,7 @@ if test "$with_x11" != "no"; then # Uses ac_ vars as temps to allow command line to override cache and checks. # --without-x overrides everything else, but does not touch the cache. echo $ac_n "checking for X""... $ac_c" 1>&6 -echo "configure:4642: checking for X" >&5 +echo "configure:4397: checking for X" >&5 # Check whether --with-x or --without-x was given. if test "${with_x+set}" = set; then @@ -4698,13 +4453,13 @@ if test "$ac_x_includes" = NO; then # First, try using that file with no special directory specified. cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4707: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:4462: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +ac_err=`grep -v '^ *+' conftest.out` if test -z "$ac_err"; then rm -rf conftest* # We can compile using X headers with no special include directory. @@ -4772,14 +4527,14 @@ if test "$ac_x_libraries" = NO; then ac_save_LIBS="$LIBS" LIBS="-l$x_direct_test_library $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4538: \"$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. @@ -4888,17 +4643,17 @@ else case "`(uname -sr) 2>/dev/null`" in "SunOS 5"*) echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6 -echo "configure:4892: checking whether -R must be followed by a space" >&5 +echo "configure:4647: checking whether -R must be followed by a space" >&5 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* ac_R_nospace=yes else @@ -4914,14 +4669,14 @@ rm -f conftest* else LIBS="$ac_xsave_LIBS -R $x_libraries" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* ac_R_space=yes else @@ -4957,12 +4712,12 @@ ac_cv_lib_dnet_dnet_ntoa=no else echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6 -echo "configure:4961: checking for dnet_ntoa in -ldnet" >&5 +echo "configure:4716: checking for dnet_ntoa in -ldnet" >&5 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'` xe_check_libs=" -ldnet " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4732: \"$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 @@ -4997,12 +4752,12 @@ fi if test $ac_cv_lib_dnet_dnet_ntoa = no; then echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6 -echo "configure:5001: checking for dnet_ntoa in -ldnet_stub" >&5 +echo "configure:4756: checking for dnet_ntoa in -ldnet_stub" >&5 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'` xe_check_libs=" -ldnet_stub " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4772: \"$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 @@ -5042,10 +4797,10 @@ fi # The nsl library prevents programs from opening the X display # on Irix 5.2, according to dickey@clark.net. echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 -echo "configure:5046: checking for gethostbyname" >&5 +echo "configure:4801: checking for gethostbyname" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_gethostbyname=yes" else @@ -5089,12 +4844,12 @@ fi if test $ac_cv_func_gethostbyname = no; then echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 -echo "configure:5093: checking for gethostbyname in -lnsl" >&5 +echo "configure:4848: checking for gethostbyname in -lnsl" >&5 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` xe_check_libs=" -lnsl " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4864: \"$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 @@ -5135,10 +4890,10 @@ fi # -lsocket must be given before -lnsl if both are needed. # We assume that if connect needs -lnsl, so does gethostbyname. echo $ac_n "checking for connect""... $ac_c" 1>&6 -echo "configure:5139: checking for connect" >&5 +echo "configure:4894: checking for connect" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4920: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_connect=yes" else @@ -5184,12 +4939,12 @@ fi xe_msg_checking="for connect in -lsocket" test -n "$X_EXTRA_LIBS" && xe_msg_checking="$xe_msg_checking using extra libs $X_EXTRA_LIBS" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:5188: checking "$xe_msg_checking"" >&5 +echo "configure:4943: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'` xe_check_libs=" -lsocket $X_EXTRA_LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4959: \"$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 @@ -5224,10 +4979,10 @@ fi # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX. echo $ac_n "checking for remove""... $ac_c" 1>&6 -echo "configure:5228: checking for remove" >&5 +echo "configure:4983: checking for remove" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5009: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_remove=yes" else @@ -5271,12 +5026,12 @@ fi if test $ac_cv_func_remove = no; then echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6 -echo "configure:5275: checking for remove in -lposix" >&5 +echo "configure:5030: checking for remove in -lposix" >&5 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'` xe_check_libs=" -lposix " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5046: \"$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 @@ -5311,10 +5066,10 @@ fi # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. echo $ac_n "checking for shmat""... $ac_c" 1>&6 -echo "configure:5315: checking for shmat" >&5 +echo "configure:5070: checking for shmat" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_shmat=yes" else @@ -5358,12 +5113,12 @@ fi if test $ac_cv_func_shmat = no; then echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6 -echo "configure:5362: checking for shmat in -lipc" >&5 +echo "configure:5117: checking for shmat in -lipc" >&5 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'` xe_check_libs=" -lipc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5133: \"$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 @@ -5407,15 +5162,13 @@ fi # libraries we check for below, so use a different variable. # --interran@uluru.Stanford.EDU, kb@cs.umb.edu. -xe_msg_checking="for IceConnectionNumber in -lICE" -test -n "$X_EXTRA_LIBS" && xe_msg_checking="$xe_msg_checking using extra libs $X_EXTRA_LIBS" -echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:5414: checking "$xe_msg_checking"" >&5 +echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6 +echo "configure:5167: checking for IceConnectionNumber in -lICE" >&5 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'` -xe_check_libs=" -lICE $X_EXTRA_LIBS" +xe_check_libs=" -lICE " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5183: \"$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 @@ -5595,7 +5348,7 @@ EOF echo "checking for X defines extracted by xmkmf" 1>&6 -echo "configure:5599: checking for X defines extracted by xmkmf" >&5 +echo "configure:5352: checking for X defines extracted by xmkmf" >&5 rm -fr conftestdir if mkdir conftestdir; then cd conftestdir @@ -5627,16 +5380,16 @@ EOF ac_safe=`echo "X11/Intrinsic.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for X11/Intrinsic.h""... $ac_c" 1>&6 -echo "configure:5631: checking for X11/Intrinsic.h" >&5 +echo "configure:5384: checking for X11/Intrinsic.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5639: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:5392: \"$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" @@ -5659,12 +5412,12 @@ fi echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6 -echo "configure:5663: checking for XOpenDisplay in -lX11" >&5 +echo "configure:5416: checking for XOpenDisplay in -lX11" >&5 ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'` xe_check_libs=" -lX11 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5432: \"$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 @@ -5700,12 +5453,12 @@ fi xe_msg_checking="for XGetFontProperty in -lX11" test -n "-b i486-linuxaout" && xe_msg_checking="$xe_msg_checking using extra libs -b i486-linuxaout" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:5704: checking "$xe_msg_checking"" >&5 +echo "configure:5457: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo X11'_'XGetFontProperty | sed 'y%./+-%__p_%'` xe_check_libs=" -lX11 -b i486-linuxaout" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5473: \"$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 @@ -5743,12 +5496,12 @@ fi echo $ac_n "checking for XShapeSelectInput in -lXext""... $ac_c" 1>&6 -echo "configure:5747: checking for XShapeSelectInput in -lXext" >&5 +echo "configure:5500: checking for XShapeSelectInput in -lXext" >&5 ac_lib_var=`echo Xext'_'XShapeSelectInput | sed 'y%./+-%__p_%'` xe_check_libs=" -lXext " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5516: \"$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 @@ -5782,12 +5535,12 @@ fi echo $ac_n "checking for XtOpenDisplay in -lXt""... $ac_c" 1>&6 -echo "configure:5786: checking for XtOpenDisplay in -lXt" >&5 +echo "configure:5539: checking for XtOpenDisplay in -lXt" >&5 ac_lib_var=`echo Xt'_'XtOpenDisplay | sed 'y%./+-%__p_%'` xe_check_libs=" -lXt " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5555: \"$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 @@ -5821,14 +5574,14 @@ fi echo $ac_n "checking the version of X11 being used""... $ac_c" 1>&6 -echo "configure:5825: checking the version of X11 being used" >&5 +echo "configure:5578: checking the version of X11 being used" >&5 cat > conftest.$ac_ext < int main(int c, char *v[]) { return c>1 ? XlibSpecificationRelease : 0; } EOF -if { (eval echo configure:5832: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:5585: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ./conftest foobar; x11_release=$? else @@ -5853,16 +5606,16 @@ EOF do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:5857: checking for $ac_hdr" >&5 +echo "configure:5610: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5865: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:5618: \"$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" @@ -5892,7 +5645,7 @@ done echo $ac_n "checking for XFree86""... $ac_c" 1>&6 -echo "configure:5896: checking for XFree86" >&5 +echo "configure:5649: checking for XFree86" >&5 if test -d "/usr/X386/include" -o \ -f "/etc/XF86Config" -o \ -f "/etc/X11/XF86Config" -o \ @@ -5912,12 +5665,12 @@ EOF test -z "$with_xmu" && { echo $ac_n "checking for XmuReadBitmapDataFromFile in -lXmu""... $ac_c" 1>&6 -echo "configure:5916: checking for XmuReadBitmapDataFromFile in -lXmu" >&5 +echo "configure:5669: checking for XmuReadBitmapDataFromFile in -lXmu" >&5 ac_lib_var=`echo Xmu'_'XmuReadBitmapDataFromFile | sed 'y%./+-%__p_%'` xe_check_libs=" -lXmu " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5685: \"$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 @@ -5967,19 +5720,19 @@ EOF echo $ac_n "checking for main in -lXbsd""... $ac_c" 1>&6 -echo "configure:5971: checking for main in -lXbsd" >&5 +echo "configure:5724: checking for main in -lXbsd" >&5 ac_lib_var=`echo Xbsd'_'main | sed 'y%./+-%__p_%'` xe_check_libs=" -lXbsd " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5736: \"$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 @@ -6016,22 +5769,22 @@ fi fi if test "$with_msw" != "no"; then echo "checking for MS-Windows" 1>&6 -echo "configure:6020: checking for MS-Windows" >&5 +echo "configure:5773: checking for MS-Windows" >&5 echo $ac_n "checking for main in -lgdi32""... $ac_c" 1>&6 -echo "configure:6023: checking for main in -lgdi32" >&5 +echo "configure:5776: checking for main in -lgdi32" >&5 ac_lib_var=`echo gdi32'_'main | sed 'y%./+-%__p_%'` xe_check_libs=" -lgdi32 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5788: \"$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 @@ -6096,12 +5849,12 @@ EOF fi fi cat > conftest.$ac_ext < int main() { return (open("/dev/windows", O_RDONLY, 0) > 0)? 0 : 1; } EOF -if { (eval echo configure:6105: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:5858: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_MSG_SELECT @@ -6119,8 +5872,6 @@ fi rm -fr conftest* const_is_losing=no with_file_coding=yes - use_minimal_tagbits=yes - use_indexed_lrecord_implementation=yes extra_objs="$extra_objs console-msw.o device-msw.o event-msw.o frame-msw.o objects-msw.o select-msw.o redisplay-msw.o glyphs-msw.o gui-msw.o" && if test "$extra_verbose" = "yes"; then echo " xemacs will be linked with \"console-msw.o device-msw.o event-msw.o frame-msw.o objects-msw.o select-msw.o redisplay-msw.o glyphs-msw.o gui-msw.o\"" fi @@ -6179,7 +5930,7 @@ case "$x_libraries" in *X11R4* ) esac echo "checking for session-management option" 1>&6 -echo "configure:6183: checking for session-management option" >&5; +echo "configure:5934: checking for session-management option" >&5; if test "$with_session" != "no"; then { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_SESSION @@ -6194,16 +5945,16 @@ 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:6198: checking for X11/Xauth.h" >&5 +echo "configure:5949: checking for X11/Xauth.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6206: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:5957: \"$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" @@ -6225,12 +5976,12 @@ fi } test -z "$with_xauth" && { echo $ac_n "checking for XauGetAuthByAddr in -lXau""... $ac_c" 1>&6 -echo "configure:6229: checking for XauGetAuthByAddr in -lXau" >&5 +echo "configure:5980: checking for XauGetAuthByAddr in -lXau" >&5 ac_lib_var=`echo Xau'_'XauGetAuthByAddr | sed 'y%./+-%__p_%'` xe_check_libs=" -lXau " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:5996: \"$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 @@ -6286,16 +6037,16 @@ 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:6290: checking for ${dir}tt_c.h" >&5 +echo "configure:6041: checking for ${dir}tt_c.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6298: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:6049: \"$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" @@ -6330,12 +6081,12 @@ if test "$with_tooltalk" != "no" ; then xe_msg_checking="for tt_message_create in -ltt" test -n "$extra_libs" && xe_msg_checking="$xe_msg_checking using extra libs $extra_libs" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:6334: checking "$xe_msg_checking"" >&5 +echo "configure:6085: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo tt'_'tt_message_create | sed 'y%./+-%__p_%'` xe_check_libs=" -ltt $extra_libs" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6101: \"$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 @@ -6403,16 +6154,16 @@ 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:6407: checking for Dt/Dt.h" >&5 +echo "configure:6158: checking for Dt/Dt.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6415: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:6166: \"$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" @@ -6434,12 +6185,12 @@ fi } test -z "$with_cde" && { echo $ac_n "checking for DtDndDragStart in -lDtSvc""... $ac_c" 1>&6 -echo "configure:6438: checking for DtDndDragStart in -lDtSvc" >&5 +echo "configure:6189: checking for DtDndDragStart in -lDtSvc" >&5 ac_lib_var=`echo DtSvc'_'DtDndDragStart | sed 'y%./+-%__p_%'` xe_check_libs=" -lDtSvc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6205: \"$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 @@ -6519,7 +6270,7 @@ EOF fi echo $ac_n "checking if drag and drop API is needed""... $ac_c" 1>&6 -echo "configure:6523: checking if drag and drop API is needed" >&5 +echo "configure:6274: checking if drag and drop API is needed" >&5 if test "$with_dragndrop" != "no" ; then if test -n "$dragndrop_proto" ; then with_dragndrop=yes @@ -6540,19 +6291,19 @@ EOF fi echo "checking for LDAP" 1>&6 -echo "configure:6544: checking for LDAP" >&5 +echo "configure:6295: checking for LDAP" >&5 test -z "$with_ldap" && { ac_safe=`echo "ldap.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ldap.h""... $ac_c" 1>&6 -echo "configure:6547: checking for ldap.h" >&5 +echo "configure:6298: checking for ldap.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6555: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:6306: \"$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" @@ -6574,16 +6325,16 @@ fi } test -z "$with_ldap" && { ac_safe=`echo "lber.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for lber.h""... $ac_c" 1>&6 -echo "configure:6578: checking for lber.h" >&5 +echo "configure:6329: checking for lber.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6586: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:6337: \"$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" @@ -6608,12 +6359,12 @@ if test "$with_ldap" != "no"; then xe_msg_checking="for ldap_open in -lldap" test -n "-llber" && xe_msg_checking="$xe_msg_checking using extra libs -llber" echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6 -echo "configure:6612: checking "$xe_msg_checking"" >&5 +echo "configure:6363: checking "$xe_msg_checking"" >&5 ac_lib_var=`echo ldap'_'ldap_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lldap -llber" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6379: \"$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 @@ -6647,12 +6398,12 @@ fi } test "$with_umich_ldap" = "no" && { echo $ac_n "checking for ldap_set_option in -lldap10""... $ac_c" 1>&6 -echo "configure:6651: checking for ldap_set_option in -lldap10" >&5 +echo "configure:6402: checking for ldap_set_option in -lldap10" >&5 ac_lib_var=`echo ldap10'_'ldap_set_option | sed 'y%./+-%__p_%'` xe_check_libs=" -lldap10 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6418: \"$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 @@ -6727,15 +6478,15 @@ fi if test "$window_system" != "none"; then echo "checking for graphics libraries" 1>&6 -echo "configure:6731: checking for graphics libraries" >&5 +echo "configure:6482: checking for graphics libraries" >&5 xpm_problem="" if test -z "$with_xpm"; then echo $ac_n "checking for Xpm - no older than 3.4f""... $ac_c" 1>&6 -echo "configure:6736: checking for Xpm - no older than 3.4f" >&5 +echo "configure:6487: checking for Xpm - no older than 3.4f" >&5 xe_check_libs=-lXpm cat > conftest.$ac_ext < int main(int c, char **v) { @@ -6743,7 +6494,7 @@ echo "configure:6736: checking for Xpm - no older than 3.4f" >&5 XpmIncludeVersion != XpmLibraryVersion() ? 1 : XpmIncludeVersion < 30406 ? 2 : 0 ;} EOF -if { (eval echo configure:6747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:6498: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ./conftest dummy_arg; xpm_status=$?; if test "$xpm_status" = "0"; then @@ -6785,17 +6536,17 @@ EOF libs_x="-lXpm $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXpm\" to \$libs_x"; fi echo $ac_n "checking for \"FOR_MSW\" xpm""... $ac_c" 1>&6 -echo "configure:6789: checking for \"FOR_MSW\" xpm" >&5 +echo "configure:6540: checking for \"FOR_MSW\" xpm" >&5 xe_check_libs=-lXpm cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* xpm_for_msw=no else @@ -6821,16 +6572,16 @@ EOF test -z "$with_xface" && { ac_safe=`echo "compface.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for compface.h""... $ac_c" 1>&6 -echo "configure:6825: checking for compface.h" >&5 +echo "configure:6576: checking for compface.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:6833: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:6584: \"$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" @@ -6852,12 +6603,12 @@ fi } test -z "$with_xface" && { echo $ac_n "checking for UnGenFace in -lcompface""... $ac_c" 1>&6 -echo "configure:6856: checking for UnGenFace in -lcompface" >&5 +echo "configure:6607: checking for UnGenFace in -lcompface" >&5 ac_lib_var=`echo compface'_'UnGenFace | sed 'y%./+-%__p_%'` xe_check_libs=" -lcompface " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6623: \"$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 @@ -6920,12 +6671,12 @@ EOF if test "$with_png $with_tiff" != "no no"; then echo $ac_n "checking for inflate in -lc""... $ac_c" 1>&6 -echo "configure:6924: checking for inflate in -lc" >&5 +echo "configure:6675: checking for inflate in -lc" >&5 ac_lib_var=`echo c'_'inflate | sed 'y%./+-%__p_%'` xe_check_libs=" -lc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6691: \"$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 @@ -6955,12 +6706,12 @@ else echo "$ac_t""no" 1>&6 echo $ac_n "checking for inflate in -lz""... $ac_c" 1>&6 -echo "configure:6959: checking for inflate in -lz" >&5 +echo "configure:6710: checking for inflate in -lz" >&5 ac_lib_var=`echo z'_'inflate | sed 'y%./+-%__p_%'` xe_check_libs=" -lz " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6726: \"$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 @@ -6990,12 +6741,12 @@ else echo "$ac_t""no" 1>&6 echo $ac_n "checking for inflate in -lgz""... $ac_c" 1>&6 -echo "configure:6994: checking for inflate in -lgz" >&5 +echo "configure:6745: checking for inflate in -lgz" >&5 ac_lib_var=`echo gz'_'inflate | sed 'y%./+-%__p_%'` xe_check_libs=" -lgz " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6761: \"$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 @@ -7036,16 +6787,16 @@ 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:7040: checking for jpeglib.h" >&5 +echo "configure:6791: checking for jpeglib.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7048: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:6799: \"$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" @@ -7067,12 +6818,12 @@ fi } test -z "$with_jpeg" && { echo $ac_n "checking for jpeg_destroy_decompress in -ljpeg""... $ac_c" 1>&6 -echo "configure:7071: checking for jpeg_destroy_decompress in -ljpeg" >&5 +echo "configure:6822: checking for jpeg_destroy_decompress in -ljpeg" >&5 ac_lib_var=`echo jpeg'_'jpeg_destroy_decompress | sed 'y%./+-%__p_%'` xe_check_libs=" -ljpeg " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6838: \"$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 @@ -7119,10 +6870,10 @@ EOF png_problem="" test -z "$with_png" && { echo $ac_n "checking for pow""... $ac_c" 1>&6 -echo "configure:7123: checking for pow" >&5 +echo "configure:6874: checking for pow" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_pow=yes" else @@ -7166,16 +6917,16 @@ 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:7170: checking for png.h" >&5 +echo "configure:6921: checking for png.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7178: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:6929: \"$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" @@ -7197,12 +6948,12 @@ fi } test -z "$with_png" && { echo $ac_n "checking for png_read_image in -lpng""... $ac_c" 1>&6 -echo "configure:7201: checking for png_read_image in -lpng" >&5 +echo "configure:6952: checking for png_read_image in -lpng" >&5 ac_lib_var=`echo png'_'png_read_image | sed 'y%./+-%__p_%'` xe_check_libs=" -lpng " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:6968: \"$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 @@ -7236,10 +6987,10 @@ fi } if test -z "$with_png"; then echo $ac_n "checking for workable png version information""... $ac_c" 1>&6 -echo "configure:7240: checking for workable png version information" >&5 +echo "configure:6991: checking for workable png version information" >&5 xe_check_libs="-lpng -lz" cat > conftest.$ac_ext < int main(int c, char **v) { @@ -7247,7 +6998,7 @@ echo "configure:7240: checking for workable png version information" >&5 if (strcmp(png_libpng_ver, PNG_LIBPNG_VER_STRING) != 0) return 1; return (PNG_LIBPNG_VER < 10002) ? 2 : 0 ;} EOF -if { (eval echo configure:7251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:7002: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ./conftest dummy_arg; png_status=$?; if test "$png_status" = "0"; then @@ -7290,16 +7041,16 @@ EOF test -z "$with_tiff" && { ac_safe=`echo "tiffio.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for tiffio.h""... $ac_c" 1>&6 -echo "configure:7294: checking for tiffio.h" >&5 +echo "configure:7045: checking for tiffio.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7302: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:7053: \"$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" @@ -7321,12 +7072,12 @@ fi } test -z "$with_tiff" && { echo $ac_n "checking for TIFFClientOpen in -ltiff""... $ac_c" 1>&6 -echo "configure:7325: checking for TIFFClientOpen in -ltiff" >&5 +echo "configure:7076: checking for TIFFClientOpen in -ltiff" >&5 ac_lib_var=`echo tiff'_'TIFFClientOpen | sed 'y%./+-%__p_%'` xe_check_libs=" -ltiff " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7092: \"$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 @@ -7376,16 +7127,16 @@ fi if test "$with_x11" = "yes"; then echo "checking for X11 graphics libraries" 1>&6 -echo "configure:7380: checking for X11 graphics libraries" >&5 +echo "configure:7131: checking for X11 graphics libraries" >&5 echo $ac_n "checking for XawScrollbarSetThumb in -lXaw""... $ac_c" 1>&6 -echo "configure:7384: checking for XawScrollbarSetThumb in -lXaw" >&5 +echo "configure:7135: checking for XawScrollbarSetThumb in -lXaw" >&5 ac_lib_var=`echo Xaw'_'XawScrollbarSetThumb | sed 'y%./+-%__p_%'` xe_check_libs=" -lXaw " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7151: \"$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 @@ -7420,16 +7171,16 @@ fi ac_safe=`echo "Xm/Xm.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for Xm/Xm.h""... $ac_c" 1>&6 -echo "configure:7424: checking for Xm/Xm.h" >&5 +echo "configure:7175: checking for Xm/Xm.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7432: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:7183: \"$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" @@ -7445,12 +7196,12 @@ if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then echo "$ac_t""yes" 1>&6 echo $ac_n "checking for XmStringFree in -lXm""... $ac_c" 1>&6 -echo "configure:7449: checking for XmStringFree in -lXm" >&5 +echo "configure:7200: checking for XmStringFree in -lXm" >&5 ac_lib_var=`echo Xm'_'XmStringFree | sed 'y%./+-%__p_%'` xe_check_libs=" -lXm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7216: \"$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 @@ -7490,9 +7241,9 @@ fi if test "$have_motif" = "yes"; then echo $ac_n "checking for Lesstif""... $ac_c" 1>&6 -echo "configure:7494: checking for Lesstif" >&5 +echo "configure:7245: checking for Lesstif" >&5 cat > conftest.$ac_ext < #ifdef LESSTIF_VERSION @@ -7734,24 +7485,6 @@ else fi fi -test "$use_minimal_tagbits" = "yes" && { test "$extra_verbose" = "yes" && cat << \EOF - Defining USE_MINIMAL_TAGBITS -EOF -cat >> confdefs.h <<\EOF -#define USE_MINIMAL_TAGBITS 1 -EOF -} - -test "$use_indexed_lrecord_implementation" = "yes" && \ - { test "$extra_verbose" = "yes" && cat << \EOF - Defining USE_INDEXED_LRECORD_IMPLEMENTATION -EOF -cat >> confdefs.h <<\EOF -#define USE_INDEXED_LRECORD_IMPLEMENTATION 1 -EOF -} - - test -z "$with_mule" && with_mule=no test -z "$with_file_coding" && with_file_coding=no @@ -7773,7 +7506,7 @@ fi if test "$with_mule" = "yes" ; then echo "checking for Mule-related features" 1>&6 -echo "configure:7777: checking for Mule-related features" >&5 +echo "configure:7510: checking for Mule-related features" >&5 { test "$extra_verbose" = "yes" && cat << \EOF Defining MULE EOF @@ -7790,24 +7523,24 @@ cat >> confdefs.h <<\EOF EOF } - extra_objs="$extra_objs mule.o mule-ccl.o mule-charset.o mule-coding.o file-coding.o" && if test "$extra_verbose" = "yes"; then - echo " xemacs will be linked with \"mule.o mule-ccl.o mule-charset.o mule-coding.o file-coding.o\"" + extra_objs="$extra_objs mule.o mule-ccl.o mule-charset.o file-coding.o" && if test "$extra_verbose" = "yes"; then + echo " xemacs will be linked with \"mule.o mule-ccl.o mule-charset.o file-coding.o\"" fi for ac_hdr in libintl.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:7802: checking for $ac_hdr" >&5 +echo "configure:7535: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7810: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:7543: \"$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" @@ -7837,12 +7570,12 @@ done echo $ac_n "checking for strerror in -lintl""... $ac_c" 1>&6 -echo "configure:7841: checking for strerror in -lintl" >&5 +echo "configure:7574: checking for strerror in -lintl" >&5 ac_lib_var=`echo intl'_'strerror | sed 'y%./+-%__p_%'` xe_check_libs=" -lintl " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7590: \"$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 @@ -7886,18 +7619,18 @@ fi echo "checking for Mule input methods" 1>&6 -echo "configure:7890: checking for Mule input methods" >&5 +echo "configure:7623: checking for Mule input methods" >&5 case "$with_xim" in "" | "yes" ) echo "checking for XIM" 1>&6 -echo "configure:7893: checking for XIM" >&5 +echo "configure:7626: checking for XIM" >&5 echo $ac_n "checking for XOpenIM in -lX11""... $ac_c" 1>&6 -echo "configure:7896: checking for XOpenIM in -lX11" >&5 +echo "configure:7629: checking for XOpenIM in -lX11" >&5 ac_lib_var=`echo X11'_'XOpenIM | sed 'y%./+-%__p_%'` xe_check_libs=" -lX11 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7645: \"$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 @@ -7932,12 +7665,12 @@ fi if test "$have_motif $have_lesstif" = "yes no"; then echo $ac_n "checking for XmImMbLookupString in -lXm""... $ac_c" 1>&6 -echo "configure:7936: checking for XmImMbLookupString in -lXm" >&5 +echo "configure:7669: checking for XmImMbLookupString in -lXm" >&5 ac_lib_var=`echo Xm'_'XmImMbLookupString | sed 'y%./+-%__p_%'` xe_check_libs=" -lXm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7685: \"$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 @@ -8013,15 +7746,15 @@ EOF if test "$with_xfs" = "yes" ; then echo "checking for XFontSet" 1>&6 -echo "configure:8017: checking for XFontSet" >&5 +echo "configure:7750: checking for XFontSet" >&5 echo $ac_n "checking for XmbDrawString in -lX11""... $ac_c" 1>&6 -echo "configure:8020: checking for XmbDrawString in -lX11" >&5 +echo "configure:7753: checking for XmbDrawString in -lX11" >&5 ac_lib_var=`echo X11'_'XmbDrawString | sed 'y%./+-%__p_%'` xe_check_libs=" -lX11 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7769: \"$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 @@ -8072,16 +7805,16 @@ EOF test "$with_wnn6" = "yes" && with_wnn=yes # wnn6 implies wnn support test -z "$with_wnn" && { ac_safe=`echo "wnn/jllib.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for wnn/jllib.h""... $ac_c" 1>&6 -echo "configure:8076: checking for wnn/jllib.h" >&5 +echo "configure:7809: checking for wnn/jllib.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8084: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:7817: \"$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" @@ -8105,10 +7838,10 @@ fi for ac_func in crypt do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:8109: checking for $ac_func" >&5 +echo "configure:7842: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7868: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -8160,12 +7893,12 @@ done test "$ac_cv_func_crypt" != "yes" && { echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6 -echo "configure:8164: checking for crypt in -lcrypt" >&5 +echo "configure:7897: checking for crypt in -lcrypt" >&5 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'` xe_check_libs=" -lcrypt " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7913: \"$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 @@ -8211,12 +7944,12 @@ fi if test -z "$with_wnn" -o "$with_wnn" = "yes"; then echo $ac_n "checking for jl_dic_list_e in -lwnn""... $ac_c" 1>&6 -echo "configure:8215: checking for jl_dic_list_e in -lwnn" >&5 +echo "configure:7948: checking for jl_dic_list_e in -lwnn" >&5 ac_lib_var=`echo wnn'_'jl_dic_list_e | sed 'y%./+-%__p_%'` xe_check_libs=" -lwnn " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7964: \"$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 @@ -8245,12 +7978,12 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for jl_dic_list_e in -lwnn4""... $ac_c" 1>&6 -echo "configure:8249: checking for jl_dic_list_e in -lwnn4" >&5 +echo "configure:7982: checking for jl_dic_list_e in -lwnn4" >&5 ac_lib_var=`echo wnn4'_'jl_dic_list_e | sed 'y%./+-%__p_%'` xe_check_libs=" -lwnn4 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7998: \"$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 @@ -8279,12 +8012,12 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for jl_dic_list_e in -lwnn6""... $ac_c" 1>&6 -echo "configure:8283: checking for jl_dic_list_e in -lwnn6" >&5 +echo "configure:8016: checking for jl_dic_list_e in -lwnn6" >&5 ac_lib_var=`echo wnn6'_'jl_dic_list_e | sed 'y%./+-%__p_%'` xe_check_libs=" -lwnn6 " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8032: \"$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 @@ -8313,12 +8046,12 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for dic_list_e in -lwnn6_fromsrc""... $ac_c" 1>&6 -echo "configure:8317: checking for dic_list_e in -lwnn6_fromsrc" >&5 +echo "configure:8050: checking for dic_list_e in -lwnn6_fromsrc" >&5 ac_lib_var=`echo wnn6_fromsrc'_'dic_list_e | sed 'y%./+-%__p_%'` xe_check_libs=" -lwnn6_fromsrc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8066: \"$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 @@ -8377,12 +8110,12 @@ EOF if test "$with_wnn6" != "no"; then echo $ac_n "checking for jl_fi_dic_list in -l$libwnn""... $ac_c" 1>&6 -echo "configure:8381: checking for jl_fi_dic_list in -l$libwnn" >&5 +echo "configure:8114: checking for jl_fi_dic_list in -l$libwnn" >&5 ac_lib_var=`echo $libwnn'_'jl_fi_dic_list | sed 'y%./+-%__p_%'` xe_check_libs=" -l$libwnn " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8130: \"$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 @@ -8428,16 +8161,16 @@ EOF if test "$with_canna" != "no"; then ac_safe=`echo "canna/jrkanji.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for canna/jrkanji.h""... $ac_c" 1>&6 -echo "configure:8432: checking for canna/jrkanji.h" >&5 +echo "configure:8165: checking for canna/jrkanji.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8440: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:8173: \"$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" @@ -8463,16 +8196,16 @@ fi c_switch_site="$c_switch_site -I/usr/local/canna/include" ac_safe=`echo "canna/jrkanji.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for canna/jrkanji.h""... $ac_c" 1>&6 -echo "configure:8467: checking for canna/jrkanji.h" >&5 +echo "configure:8200: checking for canna/jrkanji.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8475: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:8208: \"$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" @@ -8499,16 +8232,16 @@ 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:8503: checking for canna/RK.h" >&5 +echo "configure:8236: checking for canna/RK.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:8511: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:8244: \"$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" @@ -8530,12 +8263,12 @@ fi } test -z "$with_canna" && { echo $ac_n "checking for RkBgnBun in -lRKC""... $ac_c" 1>&6 -echo "configure:8534: checking for RkBgnBun in -lRKC" >&5 +echo "configure:8267: checking for RkBgnBun in -lRKC" >&5 ac_lib_var=`echo RKC'_'RkBgnBun | sed 'y%./+-%__p_%'` xe_check_libs=" -lRKC " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8283: \"$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 @@ -8569,12 +8302,12 @@ fi } test -z "$with_canna" && { echo $ac_n "checking for jrKanjiControl in -lcanna""... $ac_c" 1>&6 -echo "configure:8573: checking for jrKanjiControl in -lcanna" >&5 +echo "configure:8306: checking for jrKanjiControl in -lcanna" >&5 ac_lib_var=`echo canna'_'jrKanjiControl | sed 'y%./+-%__p_%'` xe_check_libs=" -lcanna " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8322: \"$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 @@ -8634,12 +8367,12 @@ if test "$need_motif" = "yes" ; then libs_x="-lXm $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-lXm\" to \$libs_x"; fi echo $ac_n "checking for layout_object_getvalue in -li18n""... $ac_c" 1>&6 -echo "configure:8638: checking for layout_object_getvalue in -li18n" >&5 +echo "configure:8371: checking for layout_object_getvalue in -li18n" >&5 ac_lib_var=`echo i18n'_'layout_object_getvalue | sed 'y%./+-%__p_%'` xe_check_libs=" -li18n " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8387: \"$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 @@ -8736,10 +8469,10 @@ fi for ac_func in cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask snprintf strcasecmp strerror tzset ulimit usleep utimes waitpid vsnprintf do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:8740: checking for $ac_func" >&5 +echo "configure:8473: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8499: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -8803,10 +8536,10 @@ case "$opsys" in * ) for ac_func in realpath do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:8807: checking for $ac_func" >&5 +echo "configure:8540: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -8862,17 +8595,181 @@ done esac ;; esac +for ac_func in getloadavg +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:8602: checking for $ac_func" >&5 + +cat > conftest.$ac_ext < +/* 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:8628: \"$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 <&6 +fi +done + + +if test "$ac_cv_func_getloadavg" != "yes" +then + extra_objs="$extra_objs getloadavg.o" && if test "$extra_verbose" = "yes"; then + echo " xemacs will be linked with \"getloadavg.o\"" + fi + + +echo $ac_n "checking for kstat_open in -lkstat""... $ac_c" 1>&6 +echo "configure:8664: checking for kstat_open in -lkstat" >&5 +ac_lib_var=`echo kstat'_'kstat_open | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lkstat " +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 <&6 +fi + + + + +echo $ac_n "checking for kvm_read in -lkvm""... $ac_c" 1>&6 +echo "configure:8714: checking for kvm_read in -lkvm" >&5 +ac_lib_var=`echo kvm'_'kvm_read | sed 'y%./+-%__p_%'` + +xe_check_libs=" -lkvm " +cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest; 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 <&6 +fi + + +fi + echo $ac_n "checking whether netdb declares h_errno""... $ac_c" 1>&6 -echo "configure:8867: checking whether netdb declares h_errno" >&5 +echo "configure:8764: checking whether netdb declares h_errno" >&5 cat > conftest.$ac_ext < int main() { return h_errno; ; return 0; } EOF -if { (eval echo configure:8876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8773: \"$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 @@ -8892,16 +8789,16 @@ fi rm -f conftest* echo $ac_n "checking for sigsetjmp""... $ac_c" 1>&6 -echo "configure:8896: checking for sigsetjmp" >&5 +echo "configure:8793: checking for sigsetjmp" >&5 cat > conftest.$ac_ext < int main() { sigjmp_buf bar; sigsetjmp (bar, 0); ; return 0; } EOF -if { (eval echo configure:8905: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:8802: \"$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 @@ -8921,11 +8818,11 @@ fi rm -f conftest* echo $ac_n "checking whether localtime caches TZ""... $ac_c" 1>&6 -echo "configure:8925: checking whether localtime caches TZ" >&5 +echo "configure:8822: checking whether localtime caches TZ" >&5 if test "$ac_cv_func_tzset" = "yes"; then cat > conftest.$ac_ext < #if STDC_HEADERS @@ -8960,7 +8857,7 @@ main() exit (0); } EOF -if { (eval echo configure:8964: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:8861: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then emacs_cv_localtime_cache=no else @@ -8990,9 +8887,9 @@ fi if test "$HAVE_TIMEVAL" = "yes"; then echo $ac_n "checking whether gettimeofday accepts one or two arguments""... $ac_c" 1>&6 -echo "configure:8994: checking whether gettimeofday accepts one or two arguments" >&5 +echo "configure:8891: checking whether gettimeofday accepts one or two arguments" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:8915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* echo "$ac_t""two" 1>&6 else @@ -9036,19 +8933,19 @@ fi echo $ac_n "checking for inline""... $ac_c" 1>&6 -echo "configure:9040: checking for inline" >&5 +echo "configure:8937: checking for inline" >&5 ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:8949: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_inline=$ac_kw; break else @@ -9098,17 +8995,17 @@ fi # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 -echo "configure:9102: checking for working alloca.h" >&5 +echo "configure:8999: checking for working alloca.h" >&5 cat > conftest.$ac_ext < int main() { char *p = alloca(2 * sizeof(int)); ; return 0; } EOF -if { (eval echo configure:9112: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9009: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* ac_cv_header_alloca_h=yes else @@ -9132,28 +9029,23 @@ EOF fi echo $ac_n "checking for alloca""... $ac_c" 1>&6 -echo "configure:9136: checking for alloca" >&5 +echo "configure:9033: checking for alloca" >&5 cat > conftest.$ac_ext < -# define alloca _alloca +# if HAVE_ALLOCA_H +# include # else -# if HAVE_ALLOCA_H -# include -# else -# ifdef _AIX +# ifdef _AIX #pragma alloca -# else -# ifndef alloca /* predefined by HP cc +Olibcalls */ +# else +# ifndef alloca /* predefined by HP cc +Olibcalls */ char *alloca (); -# endif # endif # endif # endif @@ -9163,7 +9055,7 @@ int main() { char *p = (char *) alloca(1); ; return 0; } EOF -if { (eval echo configure:9167: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9059: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* ac_cv_func_alloca_works=yes else @@ -9191,7 +9083,7 @@ if test $ac_cv_func_alloca_works = no; then # 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.${ac_objext} + ALLOCA=alloca.o { test "$extra_verbose" = "yes" && cat << \EOF Defining C_ALLOCA EOF @@ -9202,10 +9094,10 @@ EOF echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 -echo "configure:9206: checking whether alloca needs Cray hooks" >&5 +echo "configure:9098: checking whether alloca needs Cray hooks" >&5 cat > conftest.$ac_ext <&6 if test $ac_cv_os_cray = yes; then for ac_func in _getb67 GETB67 getb67; do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:9233: checking for $ac_func" >&5 +echo "configure:9125: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -9285,10 +9177,10 @@ done fi echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 -echo "configure:9289: checking stack direction for C alloca" >&5 +echo "configure:9181: checking stack direction for C alloca" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_c_stack_direction=1 else @@ -9336,16 +9228,16 @@ test -n "$ALLOCA" && extra_objs="$extra_objs $ALLOCA" && if test "$extra_verbos ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for vfork.h""... $ac_c" 1>&6 -echo "configure:9340: checking for vfork.h" >&5 +echo "configure:9232: checking for vfork.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:9348: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:9240: \"$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" @@ -9372,10 +9264,10 @@ else fi echo $ac_n "checking for working vfork""... $ac_c" 1>&6 -echo "configure:9376: checking for working vfork" >&5 +echo "configure:9268: checking for working vfork" >&5 cat > conftest.$ac_ext < @@ -9470,7 +9362,7 @@ main() { } } EOF -if { (eval echo configure:9474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_func_vfork_works=yes else @@ -9496,10 +9388,10 @@ fi echo $ac_n "checking for working strcoll""... $ac_c" 1>&6 -echo "configure:9500: checking for working strcoll" >&5 +echo "configure:9392: checking for working strcoll" >&5 cat > conftest.$ac_ext < main () @@ -9509,7 +9401,7 @@ main () strcoll ("123", "456") >= 0); } EOF -if { (eval echo configure:9513: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9405: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_func_strcoll_works=yes else @@ -9537,10 +9429,10 @@ fi for ac_func in getpgrp do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:9541: checking for $ac_func" >&5 +echo "configure:9433: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9459: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -9591,10 +9483,10 @@ fi done echo $ac_n "checking whether getpgrp takes no argument""... $ac_c" 1>&6 -echo "configure:9595: checking whether getpgrp takes no argument" >&5 +echo "configure:9487: checking whether getpgrp takes no argument" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9545: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_func_getpgrp_void=yes else @@ -9676,10 +9568,10 @@ fi echo $ac_n "checking for working mmap""... $ac_c" 1>&6 -echo "configure:9680: checking for working mmap" >&5 +echo "configure:9572: checking for working mmap" >&5 case "$opsys" in ultrix* ) have_mmap=no ;; *) cat > conftest.$ac_ext < #include @@ -9712,7 +9604,7 @@ int main (int argc, char *argv[]) return 1; } EOF -if { (eval echo configure:9716: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9608: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then have_mmap=yes else @@ -9737,16 +9629,16 @@ for ac_hdr in unistd.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:9741: checking for $ac_hdr" >&5 +echo "configure:9633: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:9749: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:9641: \"$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" @@ -9777,10 +9669,10 @@ done for ac_func in getpagesize do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:9781: checking for $ac_func" >&5 +echo "configure:9673: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:9699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -9831,10 +9723,10 @@ fi done echo $ac_n "checking for working mmap""... $ac_c" 1>&6 -echo "configure:9835: checking for working mmap" >&5 +echo "configure:9727: checking for working mmap" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:9870: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then ac_cv_func_mmap_fixed_mapped=yes else @@ -10012,16 +9904,16 @@ EOF ac_safe=`echo "termios.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for termios.h""... $ac_c" 1>&6 -echo "configure:10016: checking for termios.h" >&5 +echo "configure:9908: checking for termios.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10024: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:9916: \"$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" @@ -10063,16 +9955,16 @@ 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:10067: checking for termio.h" >&5 +echo "configure:9959: checking for termio.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10075: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:9967: \"$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" @@ -10103,10 +9995,10 @@ fi echo $ac_n "checking for socket""... $ac_c" 1>&6 -echo "configure:10107: checking for socket" >&5 +echo "configure:9999: checking for socket" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_socket=yes" else @@ -10144,16 +10036,16 @@ 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:10148: checking for netinet/in.h" >&5 +echo "configure:10040: checking for netinet/in.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10156: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10048: \"$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" @@ -10169,16 +10061,16 @@ 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:10173: checking for arpa/inet.h" >&5 +echo "configure:10065: checking for arpa/inet.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10181: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10073: \"$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" @@ -10202,9 +10094,9 @@ EOF } echo $ac_n "checking "for sun_len member in struct sockaddr_un"""... $ac_c" 1>&6 -echo "configure:10206: checking "for sun_len member in struct sockaddr_un"" >&5 +echo "configure:10098: checking "for sun_len member in struct sockaddr_un"" >&5 cat > conftest.$ac_ext < @@ -10215,7 +10107,7 @@ int main() { static struct sockaddr_un x; x.sun_len = 1; ; return 0; } EOF -if { (eval echo configure:10219: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10111: \"$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 @@ -10233,9 +10125,9 @@ else fi rm -f conftest* echo $ac_n "checking "for ip_mreq struct in netinet/in.h"""... $ac_c" 1>&6 -echo "configure:10237: checking "for ip_mreq struct in netinet/in.h"" >&5 +echo "configure:10129: checking "for ip_mreq struct in netinet/in.h"" >&5 cat > conftest.$ac_ext < @@ -10245,7 +10137,7 @@ int main() { static struct ip_mreq x; ; return 0; } EOF -if { (eval echo configure:10249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10141: \"$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_MULTICAST @@ -10276,10 +10168,10 @@ fi echo $ac_n "checking for msgget""... $ac_c" 1>&6 -echo "configure:10280: checking for msgget" >&5 +echo "configure:10172: checking for msgget" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_msgget=yes" else @@ -10317,16 +10209,16 @@ 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:10321: checking for sys/ipc.h" >&5 +echo "configure:10213: checking for sys/ipc.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10329: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10221: \"$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" @@ -10342,16 +10234,16 @@ 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:10346: checking for sys/msg.h" >&5 +echo "configure:10238: checking for sys/msg.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10354: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10246: \"$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" @@ -10388,16 +10280,16 @@ fi ac_safe=`echo "dirent.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for dirent.h""... $ac_c" 1>&6 -echo "configure:10392: checking for dirent.h" >&5 +echo "configure:10284: checking for dirent.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10400: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10292: \"$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" @@ -10423,16 +10315,16 @@ 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:10427: checking for sys/dir.h" >&5 +echo "configure:10319: checking for sys/dir.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10435: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10327: \"$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" @@ -10464,16 +10356,16 @@ fi ac_safe=`echo "nlist.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for nlist.h""... $ac_c" 1>&6 -echo "configure:10468: checking for nlist.h" >&5 +echo "configure:10360: checking for nlist.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10476: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10368: \"$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" @@ -10502,7 +10394,7 @@ fi echo "checking "for sound support"" 1>&6 -echo "configure:10506: checking "for sound support"" >&5 +echo "configure:10398: checking "for sound support"" >&5 case "$with_sound" in native | both ) with_native_sound=yes;; nas | no ) with_native_sound=no;; @@ -10513,16 +10405,16 @@ if test "$with_native_sound" != "no"; then if test -n "$native_sound_lib"; then ac_safe=`echo "multimedia/audio_device.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for multimedia/audio_device.h""... $ac_c" 1>&6 -echo "configure:10517: checking for multimedia/audio_device.h" >&5 +echo "configure:10409: checking for multimedia/audio_device.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10525: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10417: \"$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" @@ -10569,12 +10461,12 @@ fi if test -z "$native_sound_lib"; then echo $ac_n "checking for ALopenport in -laudio""... $ac_c" 1>&6 -echo "configure:10573: checking for ALopenport in -laudio" >&5 +echo "configure:10465: checking for ALopenport in -laudio" >&5 ac_lib_var=`echo audio'_'ALopenport | sed 'y%./+-%__p_%'` xe_check_libs=" -laudio " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10481: \"$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 @@ -10616,12 +10508,12 @@ fi if test -z "$native_sound_lib"; then echo $ac_n "checking for AOpenAudio in -lAlib""... $ac_c" 1>&6 -echo "configure:10620: checking for AOpenAudio in -lAlib" >&5 +echo "configure:10512: checking for AOpenAudio in -lAlib" >&5 ac_lib_var=`echo Alib'_'AOpenAudio | sed 'y%./+-%__p_%'` xe_check_libs=" -lAlib " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10528: \"$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 @@ -10670,16 +10562,16 @@ fi for dir in "machine" "sys" "linux"; do ac_safe=`echo "${dir}/soundcard.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ${dir}/soundcard.h""... $ac_c" 1>&6 -echo "configure:10674: checking for ${dir}/soundcard.h" >&5 +echo "configure:10566: checking for ${dir}/soundcard.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10682: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10574: \"$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" @@ -10748,7 +10640,7 @@ EOF fi libs_x="-laudio $libs_x" && if test "$extra_verbose" = "yes"; then echo " Prepending \"-laudio\" to \$libs_x"; fi cat > conftest.$ac_ext < EOF @@ -10775,7 +10667,7 @@ test -z "$with_tty" && with_tty=yes if test "$with_tty" = "yes" ; then echo "checking for TTY-related features" 1>&6 -echo "configure:10779: checking for TTY-related features" >&5 +echo "configure:10671: checking for TTY-related features" >&5 { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_TTY EOF @@ -10791,12 +10683,12 @@ EOF if test -z "$with_ncurses"; then echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6 -echo "configure:10795: checking for tgetent in -lncurses" >&5 +echo "configure:10687: checking for tgetent in -lncurses" >&5 ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'` xe_check_libs=" -lncurses " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10703: \"$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 @@ -10840,16 +10732,16 @@ EOF ac_safe=`echo "ncurses/curses.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ncurses/curses.h""... $ac_c" 1>&6 -echo "configure:10844: checking for ncurses/curses.h" >&5 +echo "configure:10736: checking for ncurses/curses.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10852: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10744: \"$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" @@ -10870,16 +10762,16 @@ fi ac_safe=`echo "ncurses/term.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ncurses/term.h""... $ac_c" 1>&6 -echo "configure:10874: checking for ncurses/term.h" >&5 +echo "configure:10766: checking for ncurses/term.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10882: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10774: \"$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" @@ -10908,16 +10800,16 @@ fi c_switch_site="$c_switch_site -I/usr/include/ncurses" ac_safe=`echo "ncurses/curses.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ncurses/curses.h""... $ac_c" 1>&6 -echo "configure:10912: checking for ncurses/curses.h" >&5 +echo "configure:10804: checking for ncurses/curses.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:10920: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:10812: \"$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" @@ -10951,12 +10843,12 @@ fi for lib in curses termlib termcap; do echo $ac_n "checking for tgetent in -l$lib""... $ac_c" 1>&6 -echo "configure:10955: checking for tgetent in -l$lib" >&5 +echo "configure:10847: checking for tgetent in -l$lib" >&5 ac_lib_var=`echo $lib'_'tgetent | sed 'y%./+-%__p_%'` xe_check_libs=" -l$lib " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10863: \"$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 @@ -10998,12 +10890,12 @@ fi else echo $ac_n "checking for tgetent in -lcurses""... $ac_c" 1>&6 -echo "configure:11002: checking for tgetent in -lcurses" >&5 +echo "configure:10894: checking for tgetent in -lcurses" >&5 ac_lib_var=`echo curses'_'tgetent | sed 'y%./+-%__p_%'` xe_check_libs=" -lcurses " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10910: \"$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 @@ -11032,12 +10924,12 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6 -echo "configure:11036: checking for tgetent in -ltermcap" >&5 +echo "configure:10928: checking for tgetent in -ltermcap" >&5 ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'` xe_check_libs=" -ltermcap " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:10944: \"$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 @@ -11096,16 +10988,16 @@ EOF test -z "$with_gpm" && { ac_safe=`echo "gpm.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for gpm.h""... $ac_c" 1>&6 -echo "configure:11100: checking for gpm.h" >&5 +echo "configure:10992: checking for gpm.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:11108: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:11000: \"$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" @@ -11127,12 +11019,12 @@ fi } test -z "$with_gpm" && { echo $ac_n "checking for Gpm_Open in -lgpm""... $ac_c" 1>&6 -echo "configure:11131: checking for Gpm_Open in -lgpm" >&5 +echo "configure:11023: checking for Gpm_Open in -lgpm" >&5 ac_lib_var=`echo gpm'_'Gpm_Open | sed 'y%./+-%__p_%'` xe_check_libs=" -lgpm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11039: \"$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 @@ -11193,21 +11085,21 @@ test "$with_x11" = "yes" -o "$with_tty" = "yes" && extra_objs="$extra_objs event test "$with_database_gnudbm $with_database_dbm $with_database_berkdb" \ != "no no no" && echo "checking for database support" 1>&6 -echo "configure:11197: checking for database support" >&5 +echo "configure:11089: checking for database support" >&5 if test "$with_database_gnudbm $with_database_dbm" != "no no"; then ac_safe=`echo "ndbm.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for ndbm.h""... $ac_c" 1>&6 -echo "configure:11202: checking for ndbm.h" >&5 +echo "configure:11094: checking for ndbm.h" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:11210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:11102: \"$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" @@ -11236,12 +11128,12 @@ fi if test "$with_database_gnudbm" != "no"; then echo $ac_n "checking for dbm_open in -lgdbm""... $ac_c" 1>&6 -echo "configure:11240: checking for dbm_open in -lgdbm" >&5 +echo "configure:11132: checking for dbm_open in -lgdbm" >&5 ac_lib_var=`echo gdbm'_'dbm_open | sed 'y%./+-%__p_%'` xe_check_libs=" -lgdbm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11148: \"$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 @@ -11280,10 +11172,10 @@ fi if test "$with_database_dbm" != "no"; then echo $ac_n "checking for dbm_open""... $ac_c" 1>&6 -echo "configure:11284: checking for dbm_open" >&5 +echo "configure:11176: checking for dbm_open" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_dbm_open=yes" else @@ -11325,12 +11217,12 @@ else echo $ac_n "checking for dbm_open in -ldbm""... $ac_c" 1>&6 -echo "configure:11329: checking for dbm_open in -ldbm" >&5 +echo "configure:11221: checking for dbm_open in -ldbm" >&5 ac_lib_var=`echo dbm'_'dbm_open | sed 'y%./+-%__p_%'` xe_check_libs=" -ldbm " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11237: \"$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 @@ -11382,10 +11274,10 @@ EOF if test "$with_database_berkdb" != "no"; then echo $ac_n "checking for Berkeley db.h""... $ac_c" 1>&6 -echo "configure:11386: checking for Berkeley db.h" >&5 +echo "configure:11278: checking for Berkeley db.h" >&5 for path in "db/db.h" "db.h"; do cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:11299: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* db_h_path="$path"; break else @@ -11419,9 +11311,9 @@ rm -f conftest* if test "$with_database_berkdb" != "no"; then echo $ac_n "checking for Berkeley DB version""... $ac_c" 1>&6 -echo "configure:11423: checking for Berkeley DB version" >&5 +echo "configure:11315: checking for Berkeley DB version" >&5 cat > conftest.$ac_ext < #if DB_VERSION_MAJOR > 1 @@ -11440,10 +11332,10 @@ fi rm -f conftest* echo $ac_n "checking for $dbfunc""... $ac_c" 1>&6 -echo "configure:11444: checking for $dbfunc" >&5 +echo "configure:11336: checking for $dbfunc" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$dbfunc=yes" else @@ -11485,12 +11377,12 @@ else echo $ac_n "checking for $dbfunc in -ldb""... $ac_c" 1>&6 -echo "configure:11489: checking for $dbfunc in -ldb" >&5 +echo "configure:11381: checking for $dbfunc in -ldb" >&5 ac_lib_var=`echo db'_'$dbfunc | sed 'y%./+-%__p_%'` xe_check_libs=" -ldb " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11397: \"$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 @@ -11565,12 +11457,12 @@ fi if test "$with_socks" = "yes"; then echo $ac_n "checking for SOCKSinit in -lsocks""... $ac_c" 1>&6 -echo "configure:11569: checking for SOCKSinit in -lsocks" >&5 +echo "configure:11461: checking for SOCKSinit in -lsocks" >&5 ac_lib_var=`echo socks'_'SOCKSinit | sed 'y%./+-%__p_%'` xe_check_libs=" -lsocks " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11477: \"$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 @@ -11638,16 +11530,16 @@ for ac_hdr in dlfcn.h do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:11642: checking for $ac_hdr" >&5 +echo "configure:11534: checking for $ac_hdr" >&5 cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:11650: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } -ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` +{ (eval echo configure:11542: \"$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" @@ -11685,12 +11577,12 @@ done test -z "$with_shlib" && test ! -z "$have_dlfcn" && { echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 -echo "configure:11689: checking for dlopen in -ldl" >&5 +echo "configure:11581: checking for dlopen in -ldl" >&5 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` xe_check_libs=" -ldl " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11597: \"$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 @@ -11730,12 +11622,12 @@ fi } test -z "$with_shlib" && test ! -z "$have_dlfcn" && { echo $ac_n "checking for _dlopen in -lc""... $ac_c" 1>&6 -echo "configure:11734: checking for _dlopen in -lc" >&5 +echo "configure:11626: checking for _dlopen in -lc" >&5 ac_lib_var=`echo c'_'_dlopen | sed 'y%./+-%__p_%'` xe_check_libs=" -lc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11642: \"$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 @@ -11775,12 +11667,12 @@ fi } test -z "$with_shlib" && test ! -z "$have_dlfcn" && { echo $ac_n "checking for dlopen in -lc""... $ac_c" 1>&6 -echo "configure:11779: checking for dlopen in -lc" >&5 +echo "configure:11671: checking for dlopen in -lc" >&5 ac_lib_var=`echo c'_'dlopen | sed 'y%./+-%__p_%'` xe_check_libs=" -lc " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11687: \"$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 @@ -11820,12 +11712,12 @@ fi } test -z "$with_shlib" && { echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 -echo "configure:11824: checking for shl_load in -ldld" >&5 +echo "configure:11716: checking for shl_load in -ldld" >&5 ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` xe_check_libs=" -ldld " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11732: \"$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 @@ -11865,12 +11757,12 @@ fi } test -z "$with_shlib" && { echo $ac_n "checking for dld_init in -ldld""... $ac_c" 1>&6 -echo "configure:11869: checking for dld_init in -ldld" >&5 +echo "configure:11761: checking for dld_init in -ldld" >&5 ac_lib_var=`echo dld'_'dld_init | sed 'y%./+-%__p_%'` xe_check_libs=" -ldld " cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:11777: \"$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 @@ -11920,7 +11812,7 @@ xehost=$canonical xealias=$internal_configuration echo "checking how to build dynamic libraries for ${xehost}" 1>&6 -echo "configure:11924: checking how to build dynamic libraries for ${xehost}" >&5 +echo "configure:11816: checking how to build dynamic libraries for ${xehost}" >&5 # Transform *-*-linux* to *-*-linux-gnu*, to support old configure scripts. case "$xehost" in *-*-linux-gnu*) ;; @@ -11948,9 +11840,9 @@ if test "$GCC" = "yes"; then XEGCC=yes else echo $ac_n "checking checking whether we are using GNU C""... $ac_c" 1>&6 -echo "configure:11952: checking checking whether we are using GNU C" >&5 +echo "configure:11844: checking checking whether we are using GNU C" >&5 cat > conftest.$ac_ext <&6 -echo "configure:11976: checking how to produce PIC code" >&5 +echo "configure:11868: checking how to produce PIC code" >&5 wl= can_build_shared=yes @@ -12065,18 +11957,18 @@ if test -n "$dll_cflags"; then # Check to make sure the dll_cflags actually works. echo $ac_n "checking if PIC flag ${dll_cflags} really works""... $ac_c" 1>&6 -echo "configure:12069: checking if PIC flag ${dll_cflags} really works" >&5 +echo "configure:11961: checking if PIC flag ${dll_cflags} really works" >&5 save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS $dll_cflags -DPIC" cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:11972: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* # On HP-UX, the stripped-down bundled CC doesn't accept +Z, but also @@ -12107,7 +11999,7 @@ cc_produces_so=no xldf= xcldf= echo $ac_n "checking if C compiler can produce shared libraries""... $ac_c" 1>&6 -echo "configure:12111: checking if C compiler can produce shared libraries" >&5 +echo "configure:12003: checking if C compiler can produce shared libraries" >&5 if test "$XEGCC" = yes; then xcldf="-shared" xldf="-shared" @@ -12158,14 +12050,14 @@ if test -n "$xcldf"; then xe_libs= ac_link='${CC-cc} -o conftest $CFLAGS '"$xe_cppflags $xe_ldflags"' conftest.$ac_ext '"$xe_libs"' 1>&5' cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:12061: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* cc_produces_so=yes else @@ -12190,7 +12082,7 @@ if test -z "$LTLD"; then if test "$XEGCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6 -echo "configure:12194: checking for ld used by GCC" >&5 +echo "configure:12086: checking for ld used by GCC" >&5 ac_prog=`($CC -print-prog-name=ld) 2>&5` case "$ac_prog" in # Accept absolute paths. @@ -12215,7 +12107,7 @@ echo "configure:12194: checking for ld used by GCC" >&5 esac else echo $ac_n "checking for GNU ld""... $ac_c" 1>&6 -echo "configure:12219: checking for GNU ld" >&5 +echo "configure:12111: checking for GNU ld" >&5 fi if test -z "$LTLD"; then @@ -12253,7 +12145,7 @@ ld_dynamic_link_flags= # Check to see if it really is or isn't GNU ld. echo $ac_n "checking if the linker is GNU ld""... $ac_c" 1>&6 -echo "configure:12257: checking if the linker is GNU ld" >&5 +echo "configure:12149: checking if the linker is GNU ld" >&5 # I'd rather use --version here, but apparently some GNU ld's only accept -v. if $LTLD -v 2>&1 &5; then xe_gnu_ld=yes @@ -12280,7 +12172,7 @@ else # OK - only NOW do we futz about with ld. # See if the linker supports building shared libraries. echo $ac_n "checking whether the linker supports shared libraries""... $ac_c" 1>&6 -echo "configure:12284: checking whether the linker supports shared libraries" >&5 +echo "configure:12176: checking whether the linker supports shared libraries" >&5 dll_ld=$CC dll_ldflags=$LDFLAGS ld_shlibs=yes @@ -12445,7 +12337,11 @@ if test -z "$ld_dynamic_link_flags"; then ld_dynamic_link_flags= ;; - sco3.2v5* | unixware* | sysv5* | sysv4* | solaris2* | solaris7*) + solaris2* | solaris7*) + ld_dynamic_link_flags="${wl}-Bdynamic" + ;; + + sco3.2v5* | unixware* | sysv5* | sysv4*) ld_dynamic_link_flags="${wl}-Bexport" ;; @@ -12492,10 +12388,10 @@ EOF for ac_func in dlerror _dlerror do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:12496: checking for $ac_func" >&5 +echo "configure:12392: checking for $ac_func" >&5 cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:12418: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -12552,11 +12448,11 @@ done fi cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 +if { (eval echo configure:12456: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5 then : else @@ -12583,8 +12479,12 @@ else fi rm -fr conftest* - -{ test "$extra_verbose" = "yes" && cat << \EOF +if test "$win32_processes" = "yes"; then + extra_objs="$extra_objs process-nt.o" && if test "$extra_verbose" = "yes"; then + echo " xemacs will be linked with \"process-nt.o\"" + fi +else + { test "$extra_verbose" = "yes" && cat << \EOF Defining HAVE_UNIX_PROCESSES EOF cat >> confdefs.h <<\EOF @@ -12592,9 +12492,10 @@ cat >> confdefs.h <<\EOF EOF } -extra_objs="$extra_objs process-unix.o" && if test "$extra_verbose" = "yes"; then + extra_objs="$extra_objs process-unix.o" && if test "$extra_verbose" = "yes"; then echo " xemacs will be linked with \"process-unix.o\"" fi +fi @@ -12984,15 +12885,6 @@ EOF -test -n "$puresize" && { test "$extra_verbose" = "yes" && cat << EOF - Defining RAW_PURESIZE = $puresize -EOF -cat >> confdefs.h < Installation.el -sed 's/"/\\"/g' Installation >> Installation.el -echo '")' >> Installation.el - # Remove any trailing slashes in these variables. test -n "$prefix" && @@ -13340,7 +13225,7 @@ do 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 2.13" + echo "$CONFIG_STATUS generated by autoconf version 2.12" exit 0 ;; -help | --help | --hel | --he | --h) echo "\$ac_cs_usage"; exit 0 ;; @@ -13360,11 +13245,9 @@ sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF $ac_vpsub $extrasub -s%@SHELL@%$SHELL%g s%@CFLAGS@%$CFLAGS%g s%@CPPFLAGS@%$CPPFLAGS%g s%@CXXFLAGS@%$CXXFLAGS%g -s%@FFLAGS@%$FFLAGS%g s%@DEFS@%$DEFS%g s%@LDFLAGS@%$LDFLAGS%g s%@LIBS@%$LIBS%g @@ -13394,7 +13277,6 @@ s%@ld@%$ld%g s%@lib_gcc@%$lib_gcc%g s%@RANLIB@%$RANLIB%g s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g -s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g s%@INSTALL_DATA@%$INSTALL_DATA%g s%@YACC@%$YACC%g s%@SET_MAKE@%$SET_MAKE%g diff --git a/configure.in b/configure.in index e7c7eb4..e77bf16 100644 --- a/configure.in +++ b/configure.in @@ -366,7 +366,6 @@ with_file_coding='' dnl const_is_losing is removed - we rely on AC_C_CONST instead. dnl We accept (and ignore) the --const-is-losing option for compatibility. dnl const_is_losing='yes' -puresize='' cpp='' cppflags='' libs='' ldflags='' dynamic='' with_x11='' @@ -513,9 +512,6 @@ while test $# != 0; do use_union_type | \ debug | \ use_assertions | \ - gung_ho | \ - use_minimal_tagbits | \ - use_indexed_lrecord_implementation | \ memory_usage_stats | \ with_clash_detection | \ with_shlib | \ @@ -529,7 +525,7 @@ while test $# != 0; do eval "$opt=\"$val\"" ;; - dnl Options that take a user-supplied value, as in --puresize=8000000 + dnl Options that take a user-supplied value, as in --x-includes=/usr/X11R6/include dnl The cache-file option is ignored (for compatibility with other configures) srcdir | \ compiler | \ @@ -538,7 +534,6 @@ while test $# != 0; do cppflags | \ libs | \ ldflags | \ - puresize | \ cache_file | \ native_sound_lib| \ site_lisp | \ @@ -794,19 +789,6 @@ if test "$with_purify" = "yes" -o "$with_quantify" = "yes"; then test "$with_system_malloc" = "default" && with_system_malloc=yes fi -dnl --gung-ho=val is a synonym for -dnl --use-minimal-tagbits=val --use-indexed-lrecord-implementation=val -if test -n "$gung_ho"; then - test -z "$use_minimal_tagbits" && use_minimal_tagbits="$gung_ho" - test -z "$use_indexed_lrecord_implementation" && \ - use_indexed_lrecord_implementation="$gung_ho" -fi -if test "$use_minimal_tagbits" = "no"; then - test "$with_dlmalloc" = "yes" && \ - USAGE_ERROR("--with-dlmalloc requires --use-minimal-tagbits") - with_dlmalloc=no -fi - dnl XE_CHECK_FEATURE_DEPENDENCY(feature1, feature2) define([XE_CHECK_FEATURE_DEPENDENCY], [if test "$with_$1 $with_$2" = "yes no"; then @@ -1484,7 +1466,9 @@ case "$canonical" in *-386bsd* ) opsys=386bsd ;; *-freebsd* ) opsys=freebsd ;; *-nextstep* ) opsys=nextstep ;; - *-pc-cygwin32 ) opsys=cygwin32 ;; + *-pc-cygwin* ) opsys=cygwin32 ;; + *-pc-mingw* ) opsys=mingw32 ; + test -z "$with_tty" && with_tty="no";; dnl Otherwise, we fall through to the generic opsys code at the bottom. esac ;; @@ -1724,6 +1708,7 @@ 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(HAVE_WIN32_PROCESSES, win32_processes) EOF dnl The value of CPP is a quoted variable reference, so we need to do this @@ -1762,9 +1747,6 @@ if test "$cflags_specified" = "no"; then dnl I'm not convinced this is a good idea any more. -sb dnl test "$opsys $machine" = "linux intel386" && \ dnl CFLAGS="$CFLAGS -fno-strength-reduce -malign-loops=2 -malign-jumps=2 -malign-functions=2" - dnl cygwin b19 can't cope with -O3, but most people use 20.1 or egcs now. - dnl test "$opsys $machine" = "cygwin32 intel386" && \ - dnl CFLAGS="-g -O2 -Wall -Wno-switch" elif test "$__SUNPRO_C" = "yes"; then case "$opsys" in sol2 ) CFLAGS="-v -xO4" ;; @@ -2198,7 +2180,7 @@ dnl check for long file names AC_SYS_LONG_FILE_NAMES dnl -lm is required by LISP_FLOAT_TYPE, among other things -AC_CHECK_LIB(m, sin) +AC_CHECK_FUNC(sin, ,AC_CHECK_LIB(m, sin)) dnl Floating operation support is now unconditional AC_DEFINE(LISP_FLOAT_TYPE) @@ -2216,12 +2198,6 @@ elif test "$mail_locking" = "flock"; then AC_DEFINE(REAL_MAIL_USE_FLOCK) else mail_locking="dot-locking" fi -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) - case "$opsys" in decosf*) AC_CHECK_LIB(pthreads, cma_open) test "$ac_cv_lib_pthreads_cma_open" = "yes" && \ @@ -2501,8 +2477,6 @@ if test "$with_msw" != "no"; then [AC_DEFINE(HAVE_MSG_SELECT)]) const_is_losing=no with_file_coding=yes - use_minimal_tagbits=yes - use_indexed_lrecord_implementation=yes XE_ADD_OBJS(console-msw.o device-msw.o event-msw.o frame-msw.o objects-msw.o select-msw.o redisplay-msw.o glyphs-msw.o gui-msw.o) fi fi @@ -2956,10 +2930,6 @@ else fi fi -test "$use_minimal_tagbits" = "yes" && AC_DEFINE(USE_MINIMAL_TAGBITS) -test "$use_indexed_lrecord_implementation" = "yes" && \ - AC_DEFINE(USE_INDEXED_LRECORD_IMPLEMENTATION) - dnl ---------------------- dnl Mule-dependent options dnl ---------------------- @@ -2983,7 +2953,7 @@ if test "$with_mule" = "yes" ; then AC_CHECKING(for Mule-related features) AC_DEFINE(MULE) AC_DEFINE(FILE_CODING) - XE_ADD_OBJS(mule.o mule-ccl.o mule-charset.o mule-coding.o file-coding.o) + XE_ADD_OBJS(mule.o mule-ccl.o mule-charset.o file-coding.o) dnl Use -lintl to get internationalized strerror for Mule AC_CHECK_HEADERS(libintl.h) @@ -3119,6 +3089,20 @@ case "$opsys" in esac ;; esac +dnl Check whether the system provides getloadavg (Solaris 7 has it) +AC_CHECK_FUNCS(getloadavg) + +if test "$ac_cv_func_getloadavg" != "yes" +then + XE_ADD_OBJS(getloadavg.o) + + 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) +fi + 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 ], @@ -3649,12 +3633,13 @@ AC_TRY_RUN([int main(int c,char *v[]){return 0;}],[:],[ echo "*** PANIC *** on your system. Don't do that." exit 1]) -dnl Process support (hardcoded) -dnl every system that supports this runs configure, the others don't - -dnl We're not ready for this yet. -AC_DEFINE(HAVE_UNIX_PROCESSES) -XE_ADD_OBJS(process-unix.o) +dnl Process support +if test "$win32_processes" = "yes"; then + XE_ADD_OBJS(process-nt.o) +else + AC_DEFINE(HAVE_UNIX_PROCESSES) + XE_ADD_OBJS(process-unix.o) +fi dnl -------------------------------- dnl Compute SUBST-itutable variables @@ -3946,8 +3931,6 @@ dnl at the point where the autodetection occurs or would occur, 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 test "$GNU_MALLOC" = "yes"; then AC_DEFINE(GNU_MALLOC) elif test "$with_system_malloc" = "yes"; then AC_DEFINE(USE_SYSTEM_MALLOC) elif test "$with_debug_malloc" = "yes"; then AC_DEFINE(USE_DEBUG_MALLOC) @@ -4121,10 +4104,7 @@ 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 "$use_minimal_tagbits" = yes && echo " Using Lisp_Objects with minimal tagbits." -test "$use_indexed_lrecord_implementation" = yes && echo " Using indexed lrecord implementation." 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)." if test "$error_check_extents $error_check_typecheck $error_check_bufpos $error_check_gc $error_check_malloc" \ != "no no no no no"; then @@ -4139,11 +4119,6 @@ echo "" dnl echo "The above configure report is appended to \"Installation\" file." echo "" -dnl Generate Installation.el -echo '(setq Installation-string "' > Installation.el -sed 's/"/\\"/g' Installation >> Installation.el -echo '")' >> Installation.el - dnl ----------------------------------- dnl Now generate config.h and Makefiles dnl ----------------------------------- diff --git a/configure.usage b/configure.usage index d612b90..69088f9 100644 --- a/configure.usage +++ b/configure.usage @@ -42,10 +42,6 @@ Compilation options: linking is the default. --srcdir=DIR Look for the XEmacs source files in DIR. Works best when using GNU Make. ---use-indexed-lrecord-implementation ---use-minimal-tagbits ---gung-ho Build with new-style Lisp_Objects. - Equivalent to both of the 2 previous options combined. Installation options: @@ -210,7 +206,6 @@ Debugging options: Other options: ---puresize=VALUE Override default amount of space for pure Lisp code. --rel-alloc Use the relocating allocator (default for this option is system-dependent). --with-dlmalloc Control usage of Doug Lea malloc on systems that have diff --git a/etc/HELLO b/etc/HELLO index ea86d00..7938aa5 100644 --- a/etc/HELLO +++ b/etc/HELLO @@ -2,31 +2,37 @@ You need many fonts to read all. Please correct this incomplete list and add more! --------------------------------------------------------- +Amharic ($(3"c!(B Arabic [2](38R(47d(3T!JSa(4W(3W[0](B Croatian (Hrvatski) Bog (Bok), Dobar dan -Czech (,Bh(Besky) Dobr,B}(B den +Czech (.BNhesky) DobrN} den Danish (Dansk) Hej, Goddag English Hello Esperanto Saluton Estonian Tere, Tervist FORTRAN PROGRAM Finnish (Suomi) Hei -French (Fran,Ag(Bais) Bonjour, Salut +French (Fran.ANgais) Bonjour, Salut German (Deutsch Nord) Guten Tag -German (Deutsch S,A|(Bd) Gr,A|_(B Gott -Greek (,FGkk]mija(B) ,FCei\(B ,Fsar(B -Hebrew [2],Hylem[0](B +German (Deutsch S.AN|d) GrN|N_ Gott +Greek (.FNENkNkNgNmNiNjN\) NCNeNiN\ NsNaNr +Hebrew [2].HNyNlNeNm[0] Italiano Ciao, Buon giorno Maltese Ciao Nederlands, Vlaams Hallo, Hoi, Goedendag Norwegian (Norsk) Hei, God dag -Polish Cze,B6f(B! -Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B! -Spanish (Espa,Aq(Bol) ,A!(BHola! +Polish Cze.BN6Nf! +Russian (.LN@NcNaNaNZNXNY) N7NTN`NPNRNaNbNRNcNYNbNU! +Slovak Dobr.BN} deNr +Spanish (Espa.ANqol) N!Hola! Swedish (Svenska) Hej, Goddag -Vietnamese (Ti,1*(Bng Vi,1.(Bt) Ch,1`(Bo b,1U(Bn +Thai ($(?@0R0I0R0d070B0(B) $(?J0G8J04H$0C8:0(B, $(?J0G8J04H$2P0(B -Japanese ($BF|K\8l(B) $B$3$s$K$A$O(B, (I:]FAJ(B, $BqV$(DiQ(B +Tigrigna ($(3"8#r!N"^(B) $(3!Q!,!<"8(B +Turkish (T.AN|rkNge) Merhaba +Vietnamese (Ti.1N*ng ViN.t) ChN`o bNUn + +Japanese ($BF|K\8l(B) $B$3$s$K$A$O(B, *IN:N]NFNANJ, $BqV$(DiQ(B Chinese ($AVPND(B,$AFUM(;0(B,$A::So(B) $ADc:C(B Cantonese ($(0GnM$(B,$(0N]0*Hd(B) $(0*/=((B, $(0+$)p(B Hangul ($(CGQ1[(B) $(C>H3gGO<H3gGO=J4O1n(B diff --git a/etc/NEWS b/etc/NEWS index 80f0f64..a7cbbe0 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -33,15 +33,31 @@ file. * Changes in XEmacs 21.2 ======================== -** Interactive searching and matching case improvements: -Case sensitiveness in searching operations is controled by the variable -`case-fold-search' (if non-nil, case is ignored while searching). This -mechanism has now been slightly improved in the case of an interactive -search: if the search string (or regexp) happens to contain uppercase -characters, the searching is forced to be case-sensitive, regardless of -the value of `case-fold-search'. This behavior affects all functions -performing interactive searches, like `zap-to-char', `tags-search', -`occur' etc. +** `delete-key-deletes-forward' now defaults to t. + +`delete-key-deletes-forward' is the variable that regulates the +behaviour of the delete key on the systems that offer both a backspace +and a delete key. If set to nil, the key labeled "Delete" will delete +backward. If set to non-nil, the "Delete" key will delete forward, +except on keyboards where a "Backspace" key is not provided. + +Unless our implementation has bugs, the only reason why you would want +to set `delete-key-deletes-forward' to nil is if you want to use the +Delete key to delete backwards, despite the presence (according to +Xlib) of a BackSpace key on the keyboard. + +** Interactive searching and matching case improvements. + +Case sensitiveness in searching operations is normally controlled by +the variable `case-fold-search' (if non-nil, case is ignored while +searching). This mechanism has now been slightly improved for +interactive searches: if the search string (or regexp) contains +uppercase characters, the searching is forced to be case-sensitive, +`case-fold-search'. + +The new behavior affects all functions performing interactive +searches, like `zap-to-char', `list-matching-lines', `tags-search' +etc. The incremental search facility has always behaved that way. ** You can now create "indirect buffers", like in GNU Emacs. An indirect buffer shares its text with another buffer ("base buffer"), @@ -52,54 +68,60 @@ be visiting a file (though its base buffer can be). The base buffer cannot itself be indirect. Use (make-indirect-buffer BASE-BUFFER NAME) to make an indirect buffer -named NAME whose base is BASE-BUFFER. If BASE-BUFFER is an indirect -buffer, its base buffer is used as the base for the new buffer. +named NAME whose base is BASE-BUFFER. If BASE-BUFFER is itself an +indirect buffer, its base buffer is used as the base for the new +buffer. You can make an indirect buffer current, or switch to it in a window, just as you would a non-indirect buffer. -The function `buffer-base-buffer', given an indirect buffer, returns -its base buffer. It returns nil when given an ordinary buffer (not -indirect). `buffer-indirect-children' returns a list of the indirect -children of a base buffer. +The function `buffer-base-buffer' returns a buffer's base buffer or +nil, if given an ordinary (non-indirect) buffer. The function +`buffer-indirect-children' returns a list of the indirect children of +a base buffer. + +** User names following the tilde character can now be completed at +file name prompts; e.g. `C-x C-f ~hni' will complete to +`~hniksic/'. To make this operation faster, a cache of user names is +maintained internally. * Lisp and internal changes in XEmacs 21.2 ========================================== -** Functions for decoding base64 encoding are now available; see -`base64-encode-region', `base64-encode-string', `base64-decode-region' -and `base64-decode-string'. +** Much effort has been invested to make XEmacs Lisp faster: -** Many basic lisp operations are now faster. +*** Many basic lisp operations are now faster. This is especially the case when running a Mule-enabled XEmacs. A general overhaul of the lisp engine should produce a speedup of 1.4 in a Latin-1 XEmacs, and 2.1 in a Mule XEmacs. These numbers were -obtained running (byte-compile "simple.el"), which should be a pretty -typical test of `pure' lisp. +obtained running `(byte-compile "simple.el")', which should be a +pretty typical test of "pure" Lisp. -Lisp hash tables have been re-implemented. The Common Lisp style hash -table interface has been made standard, and moved from cl.el into fast -C code (See the section on hash tables in the XEmacs Lisp Reference). -A speedup factor of 3 can be expected with code that makes intensive -use of hash tables. +*** Lisp hash tables have been re-implemented. The Common Lisp style +hash table interface has been made standard, and moved from cl.el into +fast C code (See the section on hash tables in the XEmacs Lisp +Reference). A speedup factor of 3 can be expected with code that +makes intensive use of hash tables. -The garbage collector has been tuned, leading to a speedup of 1.16. +*** The garbage collector has been tuned, leading to a speedup of +1.16. -The family of functions that iterate over lists, like `memq', and +*** The family of functions that iterate over lists, like `memq', and `rassq', have been made a little faster (typically 1.3). -Lisp function calls are faster, by approximately a factor of two. -However, defining inline functions (via defsubst) still make sense. +*** Lisp function calls are faster, by approximately a factor of two. +However, defining inline functions (via defsubst) still makes sense +for tight loops. -And finally, a few functions have had dramatic performance -improvements. For example, (last long-list) is now 30 times faster. +*** Finally, a few functions have had dramatic performance +improvements. For example, `(last long-list)' is now 30 times faster. Of course, your mileage will vary. Many operations do not see any improvement. Surprisingly, running -(font-lock-refontify-buffer) does not use the Lisp engine much at all. +(font-lock-fontify-buffer) does not use the Lisp engine much at all. Speeding up your favorite slow operation is an excellent project to improve XEmacs. Don't forget to profile! @@ -108,7 +130,7 @@ Although this is not yet very sophisticated, it is already responsible for several important bug fixes in XEmacs. To try it out, simply use the makefile target `make check' after building XEmacs. -** New hash table implementation +** Hash tables have been reimplemented. As was pointed out above, the standard interface to hash tables is now the Common Lisp interface, as described in Common Lisp, the Language (CLtL2, by Steele). The older interface (functions with names @@ -122,14 +144,64 @@ Lisp Reference Manual for details. ** Lisp code handles circular lists much more robustly. Many basic lisp functions used to loop forever when given a circular -list. Now this is more likely to trigger a `circular-list' error. -Printing a circular list now results in something like this: +list, expecting you to C-g (quit) out of the loop. Now this is more +likely to trigger a `circular-list' error. Printing a circular list +now results in something like this: - (progn (setq x (cons 'foo 'foo)) (setcdr x x) x) -==> (foo ... ) + (let ((x (cons 'foo 'foo))) + (setcdr x x) + x) + => (foo ... ) An extra bonus is that checking for circularities is not just -friendlier, but actually faster than checking for quit. +friendlier, but actually faster than checking for C-g. + +** The new form `ignore-file-errors', similar to `ignore-errors' may +be used as a short-hand for condition-case when you wish to ignore +file-related error. For example: + + (ignore-file-errors (delete-file "foo")) + +** The arguments to `locate-file' are now much more "lispy". As +before, the usage is: + + (locate-file FILENAME PATH-LIST &optional SUFFIXES MODE) + +Except that SUFFIXES are now a list of strings instead of a single, +colon-separated string. MODE is now a symbol or a list of symbols +(symbols `exists', `executable', `writable', and `readable' are +supported) instead of an integer code. See the documentation for +details. + +Of course, the old form is still accepted for backward compatibility. + +** The `keywordp' function now returns non-nil only on symbols +interned in the global obarray. For example: + + (keywordp (intern ":foo" [0])) + => nil + (keywordp (intern ":foo")) ; The same as (keywordp :foo) + => t + +This behaviour is compatible with other code which treats symbols +beginning with colon as keywords only if they are interned in the +global obarray. `keyword' used to wrongly return t in both cases +above. + +** The first argument to `intern-soft' may now also be a symbol, like +with `unintern'. If given a symbol, `intern-soft' will look for that +exact symbol rather than for any string. This is useful when you want +to check whether a specific symbol is interned in an obarray, e.g.: + + (intern "foo") + (intern-soft "foo") + => foo + (intern-soft (make-symbol "foo")) + => nil + +** Functions for decoding base64 encoding are now available; see +`base64-encode-region', `base64-encode-string', `base64-decode-region' +and `base64-decode-string'. * Changes in XEmacs 21.0 @@ -161,8 +233,18 @@ will have to set them all again through the menu, and remove the code loading ** When the Zmacs region is active, `M-x query-replace' and the other replace commands now operate on the region contents only. -** Using the new `-private' option, you can make XEmacs use a private -colormap. +** XEmacs now is able to choose X visuals and use private colormaps. +The '-visual ' command line option or the '.EmacsVisual' +Xresource controls which visual XEmacs will use, and +'-privateColormap' or '.privateColormap' will force XEmacs to create a +private colormap for use. The syntax for the visual string is +"" where is one of 'StaticColor', +'TrueColor', 'GrayScale', 'PseudoColor' or 'DirectColor' and + is the appropriate number of bits per pixel. If an invalid +or non-supported combination is entered, XEmacs attempts to find a happy +medium. The X creation mechanism will then determine if it needs to +create a colormap for use, or the presence of the private flags will +force it to create it. ** The `imenu' package has been ported to XEmacs and is available as a package. @@ -259,8 +341,7 @@ with the ilisp package and should work well under XEmacs 21.0. *** Like the old 'gnudoit' program. Gnuclient -batch now can read from stdin. -*** Again like the old 'gnudoit' program, gnuclient now can return multiple -lines. +*** Gnuclient -batch no longer breaks off the output at the first LF. ** C mode changes diff --git a/etc/package-index.LATEST.pgp b/etc/package-index.LATEST.pgp index a9ea8e9..a980601 100644 --- a/etc/package-index.LATEST.pgp +++ b/etc/package-index.LATEST.pgp @@ -3,19 +3,19 @@ (package-get-update-base-entry (quote (ediff (standards-version 1.0 - version "1.18" + version "1.19" author-version "2.72" - date "1999-03-03" - build-date "1999-03-05" + date "1999-04-06" + build-date "1999-05-13" maintainer "Michael Kifer " distribution stable priority medium category "prog" dump nil description "Interface over GNU patch." - filename "ediff-1.18-pkg.tar.gz" - md5sum "ece3aca382d80a7c03d71766987b9f2f" - size 281635 + filename "ediff-1.19-pkg.tar.gz" + md5sum "d6e0edc88c5d09279df71ce9aff41b25" + size 281804 provides (ediff) requires (pcl-cvs elib dired xemacs-base) type regular @@ -91,19 +91,19 @@ (package-get-update-base-entry (quote (egg-its (standards-version 1.0 - version "1.15" - author-version "21.0b62" - date "1999-01-04" - build-date "1999-02-02" + version "1.16" + author-version "21.0b65" + date "1999-03-05" + build-date "1999-03-11" maintainer "XEmacs Development Team " distribution mule priority high category "mule" dump t description "Wnn (4.2 and 6) support. SJ3 support." - filename "egg-its-1.15-pkg.tar.gz" - md5sum "9c3f18c0c7eb0e77bc23af5aed0e3bcd" - size 257327 + filename "egg-its-1.16-pkg.tar.gz" + md5sum "5a3b23dbe609feeabfc108ae142715c3" + size 257562 provides (egg-cnpinyin egg-cnzhuyin egg-cwnn-leim egg-jisx0201 egg-jsymbol egg-kwnn-leim egg-leim egg-sj3-client egg-sj3-leim egg-sj3 egg-wnn egg) requires (leim mule-base fsf-compat xemacs-base) type regular @@ -157,19 +157,19 @@ (package-get-update-base-entry (quote (locale (standards-version 1.0 - version "1.12" - author-version "21.0b64" - date "1999-02-02" - build-date "1999-03-05" + version "1.13" + author-version "21.0" + date "1999-05-11" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution mule priority high category "mule" dump nil description "Localized menubars and localized splash screens." - filename "locale-1.12-pkg.tar.gz" - md5sum "fbdb329b8e57e5eaf8c8fb9488357312" - size 33900 + filename "locale-1.13-pkg.tar.gz" + md5sum "4735b4005dfce55cf3581885add18836" + size 33964 provides () requires (mule-base) type regular @@ -179,19 +179,19 @@ (package-get-update-base-entry (quote (mule-base (standards-version 1.0 - version "1.28" - author-version "21.0b63" - date "1999-02-17" - build-date "1999-03-01" + version "1.29" + author-version "21.0" + date "1999-05-13" + build-date "1999-05-13" maintainer "SL Baur " distribution mule priority high category "mule" dump t description "Basic Mule support, required for building with Mule." - filename "mule-base-1.28-pkg.tar.gz" - md5sum "498d725e923476af3df12b83fef6277d" - size 441953 + filename "mule-base-1.29-pkg.tar.gz" + md5sum "9b713b6f95c4016dc29d7b584c78f7d1" + size 420205 provides (canna-leim canna char-table china-util cyril-util isearch-ext japan-util ccl can-n-egg mule-help) requires (fsf-compat xemacs-base) type regular @@ -245,19 +245,19 @@ (package-get-update-base-entry (quote (text-modes (standards-version 1.0 - version "1.18" - author-version "21.0b63" - date "1999-02-15" - build-date "1999-03-01" + version "1.19" + author-version "21.0" + date "1999-04-22" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority high category "oa" dump nil description "Miscellaneous support for editing text files." - filename "text-modes-1.18-pkg.tar.gz" - md5sum "f9d30bd220d0806179397194603b0b0f" - size 207596 + filename "text-modes-1.19-pkg.tar.gz" + md5sum "9031e37912506b87a9a4fc4aa8107c13" + size 207865 provides (autoinsert crontab-edit filladapt fold-isearch folding image-mode iso-acc iso-ascii iso-cvt iso-insert iso-swed swedish tabify whitespace-mode winmgr-mode xpm-mode xrdb-mode) requires (ispell fsf-compat xemacs-base) type regular @@ -333,19 +333,19 @@ (package-get-update-base-entry (quote (pc (standards-version 1.0 - version "1.14" - author-version "21.0b62" - date "1998-07-25" - build-date "1999-02-02" + version "1.15" + author-version "21.0" + date "1999-04-13" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority low category "oa" dump nil description "PC style interface emulation." - filename "pc-1.14-pkg.tar.gz" - md5sum "e300f9e0ee56640e110bee972fca8333" - size 16243 + filename "pc-1.15-pkg.tar.gz" + md5sum "99ad6b816d02360a4a9ccb5425974818" + size 16315 provides (delbs fusion pc-select pending-del s-region) requires (xemacs-base) type regular @@ -355,19 +355,19 @@ (package-get-update-base-entry (quote (ispell (standards-version 1.0 - version "1.14" - author-version "3.1" - date "1998-12-09" - build-date "1999-02-02" + version "1.15" + author-version "3.2" + date "1999-05-13" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority low category "oa" dump nil description "Spell-checking with GNU ispell." - filename "ispell-1.14-pkg.tar.gz" - md5sum "2b382122698c2c46aeaa4847e7ab3825" - size 67525 + filename "ispell-1.15-pkg.tar.gz" + md5sum "23632bd9fc2f7e4c0303865c35c5f4a5" + size 68118 provides (ispell) requires () type regular @@ -399,19 +399,19 @@ (package-get-update-base-entry (quote (forms (standards-version 1.0 - version "1.09" - author-version "2.10" - date "1998-01-25" - build-date "1999-02-02" + version "1.10" + author-version "2.37" + date "1999-05-11" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution contrib priority low category "oa" dump nil description "Forms editing support (obsolete, use Widget instead)." - filename "forms-1.09-pkg.tar.gz" - md5sum "7023bf24836c00572fc3b014d9c9b3c9" - size 47673 + filename "forms-1.10-pkg.tar.gz" + md5sum "a8ad3a114859c0981a1f884072bf4b1b" + size 48264 provides (forms forms-mode) requires () type regular @@ -465,19 +465,19 @@ (package-get-update-base-entry (quote (speedbar (standards-version 1.0 - version "1.11" + version "1.12" author-version "0.6.2x" - date "1998-10-02" - build-date "1999-02-02" + date "1999-03-05" + build-date "1999-03-12" maintainer "XEmacs Development Team " distribution stable priority low category "oa" dump nil description "Provides a seperate frame with convenient references." - filename "speedbar-1.11-pkg.tar.gz" - md5sum "896acffc88848f175ada5ae637b67738" - size 64858 + filename "speedbar-1.12-pkg.tar.gz" + md5sum "3b578d06426921193ac2b8337a669bfa" + size 64892 provides (speedbar) requires (xemacs-base) type regular @@ -487,19 +487,19 @@ (package-get-update-base-entry (quote (edit-utils (standards-version 1.0 - version "1.37" - author-version "21.0b63" - date "1999-02-18" - build-date "1999-03-01" + version "1.39" + author-version "21.0" + date "1999-05-11" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority high category "oa" dump nil description "Miscellaneous editor extensions, you probably need this." - filename "edit-utils-1.37-pkg.tar.gz" - md5sum "fb7f38fd037c0fa045a199796c69e6d7" - size 577293 + filename "edit-utils-1.39-pkg.tar.gz" + md5sum "f129277008f56e86ec8630a299df7408" + size 577970 provides (abbrevlist atomic-extents avoid backup-dir balloon-help big-menubar blink-cursor blink-paren bookmark compare-w completion dabbrev desktop detached-minibuf edit-toolbar fast-lock file-part floating-toolbar flow-ctrl foldout func-menu hippie-exp icomplete id-select info-look iswitchb lazy-lock lazy-shot live-icon man mic-paren paren popper mode-motion+ outl-mouse page-ext blink-paren paren permanent-buffers recent-files redo reportmail rsz-minibuf saveconfsavehist saveplace scroll-in-place tempo toolbar-utils tree-menu uniquify where-was-i-db) requires (xemacs-base) type single @@ -531,19 +531,19 @@ (package-get-update-base-entry (quote (os-utils (standards-version 1.0 - version "1.14" - author-version "21.0b62" - date "1998-12-30" - build-date "1999-02-02" + version "1.15" + author-version "21.0" + date "1999-03-19" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority medium category "os" dump nil description "Miscellaneous O/S utilities." - filename "os-utils-1.14-pkg.tar.gz" - md5sum "2ff61cea716a53af1846d1699b5194a7" - size 227298 + filename "os-utils-1.15-pkg.tar.gz" + md5sum "92a3d72b0df1fb79fef2aee88a4d4f50" + size 228261 provides (archive-mode background crypt crypt++ inf-lisp jka-compr lpr mchat ps-print tar-mode telnet terminal uncompress) requires (xemacs-base) type single @@ -707,19 +707,19 @@ (package-get-update-base-entry (quote (reftex (standards-version 1.0 - version "1.12" + version "1.13" author-version "3.43" - date "1999-03-01" - build-date "1999-03-02" + date "1999-04-06" + build-date "1999-05-13" maintainer "Carsten Dominik " distribution stable priority medium category "wp" dump nil description "Emacs support for LaTeX cross-references, citations.." - filename "reftex-1.12-pkg.tar.gz" - md5sum "73efb58d055143d9322024d97fcca479" - size 215874 + filename "reftex-1.13-pkg.tar.gz" + md5sum "5e9196a6fdda2587bec1aff19d6322ec" + size 216008 provides (reftex) requires (fsf-compat xemacs-base) type regular @@ -905,19 +905,19 @@ (package-get-update-base-entry (quote (prog-modes (standards-version 1.0 - version "1.18" - author-version "21.0b63" - date "1999-02-05" - build-date "1999-03-01" + version "1.19" + author-version "21.0" + date "1999-05-12" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority medium category "prog" dump nil description "Support for various programming languages." - filename "prog-modes-1.18-pkg.tar.gz" - md5sum "b6b86a7a88544c54e5231e11e0a9af79" - size 595658 + filename "prog-modes-1.19-pkg.tar.gz" + md5sum "11da842b17ee65837bc56c13d76f49af" + size 596965 provides (autoconf-mode cperl-mode eiffel3 f90 fortran ksh-mode m4-mode makefile perl-mode postscript python-mode rexx-mode simula-mode tcl teco verilog-mod) requires (mail-lib xemacs-devel xemacs-base) type regular @@ -949,19 +949,19 @@ (package-get-update-base-entry (quote (debug (standards-version 1.0 - version "1.08" - author-version "21.0b62" - date "1998-11-18" - build-date "1999-02-02" + version "1.09" + author-version "21.0" + date "1999-05-12" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution contrib priority low category "prog" dump nil description "GUD, gdb, dbx debugging support." - filename "debug-1.08-pkg.tar.gz" - md5sum "e2c9ff97146272670632311a9267765a" - size 89552 + filename "debug-1.09-pkg.tar.gz" + md5sum "24442a34f07cdd97ed52aa2c88c3de0b" + size 103161 provides (dbx gdb-highlight gdb gdbsrc gud history) requires (xemacs-base) type regular @@ -1059,19 +1059,19 @@ (package-get-update-base-entry (quote (misc-games (standards-version 1.0 - version "1.10" - author-version "21.0b64" - date "1999-03-04" - build-date "1999-03-05" + version "1.11" + author-version "21.0b65" + date "1999-03-05" + build-date "1999-03-11" maintainer "XEmacs Development Team " distribution stable priority low category "games" dump nil description "Other amusements and diversions." - filename "misc-games-1.10-pkg.tar.gz" - md5sum "d5d5c6c074fab908ba48a8a6ccdc4273" - size 165902 + filename "misc-games-1.11-pkg.tar.gz" + md5sum "80149e00e5698d0a48945c918bd2d0ba" + size 166197 provides (decipher gomoku hanoi life morse rot13) requires (xemacs-base) type single @@ -1213,19 +1213,19 @@ (package-get-update-base-entry (quote (tm (standards-version 1.0 - version "1.17" - author-version "21.0b63" + version "1.18" + author-version "21.0" date "1999-02-06" - build-date "1999-02-06" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority low category "comm" dump nil description "Emacs MIME support." - filename "tm-1.17-pkg.tar.gz" - md5sum "ee33e9f5fb4cd461e19e5ff23b4a3ea2" - size 329581 + filename "tm-1.18-pkg.tar.gz" + md5sum "3d7641bd11adb085686384ffee80bf04" + size 330163 provides (tm tm-edit tm-view mime-setup) requires (gnus mh-e rmail vm mailcrypt mail-lib apel xemacs-base) type regular @@ -1235,19 +1235,19 @@ (package-get-update-base-entry (quote (gnus (standards-version 1.0 - version "1.39" + version "1.40" author-version "5.6.45x1" - date "1999-02-17" - build-date "1999-03-05" + date "1999-03-12" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority medium category "comm" dump nil description "The Gnus Newsreader and Mailreader." - filename "gnus-1.39-pkg.tar.gz" - md5sum "5413e7508693bfcb16c5a4a0e0bce7c7" - size 1869261 + filename "gnus-1.40-pkg.tar.gz" + md5sum "df916949c14fc6a1dcd5b3f3158a5497" + size 1873480 provides (gnus message) requires (gnus tm apel w3 mh-e mailcrypt rmail mail-lib xemacs-base) type regular @@ -1301,19 +1301,19 @@ (package-get-update-base-entry (quote (supercite (standards-version 1.0 - version "1.11" - author-version "3.55x2" - date "1998-08-9" - build-date "1999-02-02" + version "1.12" + author-version "3.55x3" + date "1999-04-06" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority low category "comm" dump nil description "An Emacs citation tool for News & Mail messages." - filename "supercite-1.11-pkg.tar.gz" - md5sum "816ba6aa0d984b06a0d8749fd85c4434" - size 99417 + filename "supercite-1.12-pkg.tar.gz" + md5sum "7188738f17ec05c1561fe054fdf120dd" + size 99564 provides (supercite) requires (mail-lib xemacs-base) type regular @@ -1367,19 +1367,19 @@ (package-get-update-base-entry (quote (footnote (standards-version 1.0 - version "1.08" + version "1.10" author-version "0.18x" - date "1998-08-27" - build-date "1999-02-02" + date "1999-03-11" + build-date "1999-05-13" maintainer "SL Baur " distribution stable priority low category "comm" dump nil description "Footnoting in mail message editing modes." - filename "footnote-1.08-pkg.tar.gz" - md5sum "2c2377f0e702b8ba437cc8e245c08cfd" - size 13352 + filename "footnote-1.10-pkg.tar.gz" + md5sum "124d7e58ba9905db7488ee142470249f" + size 18356 provides (footnote) requires (mail-lib xemacs-base) type regular @@ -1455,19 +1455,19 @@ (package-get-update-base-entry (quote (vm (standards-version 1.0 - version "1.17" - author-version "6.67" - date "1998-09-22" - build-date "1999-03-05" + version "1.20" + author-version "6.71" + date "1999-05-13" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority medium category "comm" dump nil description "An Emacs mailer." - filename "vm-1.17-pkg.tar.gz" - md5sum "9a95c6264135124db979bce745bf0e07" - size 609688 + filename "vm-1.20-pkg.tar.gz" + md5sum "120d25d3541fc7ef4bb34659a4aba89c" + size 614987 provides (vm) requires (mail-lib xemacs-base) type regular @@ -1631,19 +1631,19 @@ (package-get-update-base-entry (quote (apel (standards-version 1.0 - version "1.09" - author-version "3.3" - date "1998-07-23" - build-date "1999-03-01" + version "1.11" + author-version "9.18" + date "1999-05-08" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution mule priority high category "libs" dump nil description "A Portable Emacs Library. Used by XEmacs MIME support." - filename "apel-1.09-pkg.tar.gz" - md5sum "2030f4f38ef76da3104f77f36b797916" - size 35302 + filename "apel-1.11-pkg.tar.gz" + md5sum "4c53047e1f0964b24626c29ee40a04c5" + size 73997 provides (atype emu-20 emu-e19 emu-x20 emu-xemacs emu file-detect filename install mule-caesar path-util richtext std11-parse std11 tinyrich) requires (fsf-compat xemacs-base) type regular @@ -1697,19 +1697,19 @@ (package-get-update-base-entry (quote (mail-lib (standards-version 1.0 - version "1.22" - author-version "21.0b64" - date "1999-03-05" - build-date "1999-03-05" + version "1.23" + author-version "21.0" + date "1999-04-13" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution stable priority medium category "libs" dump nil description "Fundamental lisp files for providing email support." - filename "mail-lib-1.22-pkg.tar.gz" - md5sum "70a947a1980887430c53032e3dfcbe4f" - size 131476 + filename "mail-lib-1.23-pkg.tar.gz" + md5sum "4293acbed286a63581f55b7a16e4a489" + size 131968 provides (browse-url highlight-headers mail-abbrevs mail-extr mail-utils reporter rfc822 rmail-mini rmailout sendmail smtpmail) requires (xemacs-base) type regular @@ -1742,9 +1742,9 @@ (xemacs-base (standards-version 1.0 version "1.30" - author-version "21.0b63" + author-version "21.0" date "1998-11-30" - build-date "1999-03-01" + build-date "1999-05-13" maintainer "XEmacs Development Team " distribution mule priority high @@ -1752,8 +1752,8 @@ dump nil description "Fundamental XEmacs support, you almost certainly need this." filename "xemacs-base-1.30-pkg.tar.gz" - md5sum "e0c4ffb2561c10755c8132b2b88e11b2" - size 430503 + md5sum "d9e95850fe8e13a04166d59d62fb38ab" + size 430640 provides (add-log advice annotations assoc case-table chistory comint-xemacs comint compile debug ebuff-menu echistory edmacro ehelp electric enriched env facemenu ffap helper imenu iso-syntax macros novice outline overlay passwd pp regi ring shell skeleton sort thing time-stamp timezone xbm-button xpm-button) requires () type regular diff --git a/etc/xemacs.1 b/etc/xemacs.1 index d812351..e86dce2 100644 --- a/etc/xemacs.1 +++ b/etc/xemacs.1 @@ -211,6 +211,22 @@ so that you can continue using your original window. .I XEmacs can be started with the following standard X options: .TP +.BI \-visual " " +Select the visual that XEmacs will attempt to use. +.I +should be one of the strings "StaticColor", "TrueColor", "GrayScale", +"PseudoColor" or "DirectColor", and +.I +should be the number of bits per pixel (example, "-visual TrueColor24" +for a 24bit TrueColor visual) See +.IR X (1) +for more information. +.TP +.B -privateColormap +Require XEmacs to create and use a private colormap for display. This will keep +XEmacs from taking colors from the default colormap and keeping them from other +clients. +.TP .BI \-geometry " ##x##+##+##" Specify the geometry of the initial window. The ##'s represent a number; the four numbers are width (characters), height (characters), X offset @@ -440,6 +456,16 @@ Sets the color of the window's text cursor. .B pointerColor (\fPclass\fB Foreground) Sets the color of the window's mouse cursor. .TP +.B emacsVisual (\fPclass\fB EmacsVisual) +Sets the default visual +.I XEmacs +will try to use (as described above). +.TP +.B privateColormap (\fPclass\fB PrivateColormap) +If set, +.I XEmacs +will default to using a private colormap. +.TP .B geometry (\fPclass\fB Geometry) Sets the geometry of the .I XEmacs diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index d14d7b0..d90785d 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,43 @@ +1999-05-14 XEmacs Build Bot + + * XEmacs 21.2.14 is released + +1999-05-14 SL Baur + + * update-elc.sh (ignore_pattern): Correct ignore_dirs/ignore=dirs + european keyboard fuckage. + +1999-05-03 Hrvoje Niksic + + * update-elc.sh (ignore_pattern): Installation.el is dead. + +1999-05-03 Hrvoje Niksic + + * gnuclient.c: Include instead of <../src/sysfile.h>. + + * Makefile.in.in (cppflags): Add -I$(top_srcdir)/src. + +1999-04-29 Andy Piper + + * make-docfile.c: build fixes for mingw32. + * movemail.c: ditto. + * run.c: ditto. + * yow.c: ditto. + * profile.c: ditto. + (gettimeofday): new function copied from nt.c. + + * fakemail.c (make_file_preface): make buildable under windows. + + * Makefile.in.in: fix some build targets for when we are building + on a windows platform. + +1999-03-12 giacomo boffi + + * sorted-doc.c: corrected the outdated or plainly wrong + texinfo headers. Broken up the mega-@table that crashes (at + least RedHat's) TeX with: + "! TeX capacity exceeded, sorry [save size=4000]." + 1999-03-12 XEmacs Build Bot * XEmacs 21.2.13 is released diff --git a/lib-src/Makefile.in.in b/lib-src/Makefile.in.in index 1e62172..9a4552f 100644 --- a/lib-src/Makefile.in.in +++ b/lib-src/Makefile.in.in @@ -53,6 +53,7 @@ exec_prefix=@exec_prefix@ bindir=@bindir@ libdir=@libdir@ srcdir=@srcdir@ +top_srcdir=@top_srcdir@ archlibdir=@archlibdir@ configuration=@configuration@ moduledir=@moduledir@ @@ -72,7 +73,11 @@ INSTALL_DATA = @INSTALL_DATA@ ## Things that a user might actually run, ## which should be installed in bindir. +#ifdef WINDOWSNT +INSTALLABLES_BASE = etags ctags b2m ootags +#else INSTALLABLES_BASE = etags ctags b2m gnuclient ootags +#endif INSTALLABLE_SCRIPTS = rcs-checkin pstogif gnudoit gnuattach #ifdef HAVE_SHLIB #ifdef HAVE_MS_WINDOWS @@ -91,9 +96,15 @@ INSTALLABLES = $(INSTALLABLES_BASE) ## Things that Emacs runs internally, or during the build process, ## which should not be installed in bindir. +#ifdef WINDOWSNT +UTILITIES= make-path wakeup profile make-docfile digest-doc \ + sorted-doc movemail cvtmail yow hexl \ + mmencode +#else UTILITIES= make-path wakeup profile make-docfile digest-doc \ sorted-doc movemail cvtmail fakemail yow hexl \ gnuserv mmencode +#endif ## These need to be conditional on I18N3 make-msgfile make-po ## Like UTILITIES, but they are not system-dependent, and should not be @@ -149,7 +160,7 @@ ld_libs_general=@ld_libs_general@ ## We need to #define emacs to get the right versions of some files. -cppflags = -Demacs -I../src $(CPPFLAGS) +cppflags = -Demacs -I$(top_srcdir)/src -I../src $(CPPFLAGS) cflags = $(CFLAGS) $(cppflags) $(c_switch_general) ldflags = $(LDFLAGS) $(ld_switch_general) $(ld_libs_general) diff --git a/lib-src/fakemail.c b/lib-src/fakemail.c index 1241fef..5397d7c 100644 --- a/lib-src/fakemail.c +++ b/lib-src/fakemail.c @@ -323,7 +323,11 @@ make_file_preface (void) /* the_date has an unwanted newline at the end */ date_length = strlen (the_date) - 1; the_date[date_length] = '\0'; +#ifdef WINDOWSNT + temp = "(null)"; +#else temp = cuserid ((char *) NULL); +#endif user_length = strlen (temp); the_user = alloc_string ((size_t) (user_length + 1)); strcpy (the_user, temp); diff --git a/lib-src/gnuclient.c b/lib-src/gnuclient.c index 4fd2771..1902691 100644 --- a/lib-src/gnuclient.c +++ b/lib-src/gnuclient.c @@ -48,6 +48,8 @@ static char rcsid [] = "!Header: gnuclient.c,v 2.2 95/12/12 01:39:21 wing nene ! #include #include #include +#define DONT_ENCAPSULATE +#include #ifdef HAVE_STRING_H #include @@ -89,7 +91,9 @@ tell_emacs_to_resume (int sig) /* Why is SYSV so retarded? */ /* We want emacs to realize that we are resuming */ +#ifdef SIGCONT signal(SIGCONT, tell_emacs_to_resume); +#endif connect_type = make_connection (NULL, (u_short) 0, &s); @@ -129,8 +133,10 @@ initialize_signals () signal (SIGWINCH, pass_signal_to_emacs); #endif +#ifdef SIGCONT /* We want emacs to realize that we are resuming */ signal (SIGCONT, tell_emacs_to_resume); +#endif } diff --git a/lib-src/make-docfile.c b/lib-src/make-docfile.c index 79f79e1..e28e38e 100644 --- a/lib-src/make-docfile.c +++ b/lib-src/make-docfile.c @@ -51,8 +51,6 @@ Boston, MA 02111-1307, USA. */ #include #endif -#include - #if defined(MSDOS) || defined(__CYGWIN32__) #include #endif /* MSDOS */ @@ -63,6 +61,8 @@ Boston, MA 02111-1307, USA. */ #include #endif /* WINDOWSNT */ +#include + #if defined(DOS_NT) || defined(__CYGWIN32__) #define READ_TEXT "rt" #define READ_BINARY "rb" diff --git a/lib-src/movemail.c b/lib-src/movemail.c index 7a91c6e..19793a3 100644 --- a/lib-src/movemail.c +++ b/lib-src/movemail.c @@ -59,7 +59,6 @@ Boston, MA 02111-1307, USA. */ #include <../src/config.h> #include #include -#include #include #include #include "../src/sysfile.h" diff --git a/lib-src/profile.c b/lib-src/profile.c index 5644d21..ec62ebb 100644 --- a/lib-src/profile.c +++ b/lib-src/profile.c @@ -41,6 +41,25 @@ static struct timeval TV1, TV2; static int watch_not_started = 1; /* flag */ static char time_string[30]; +#ifdef WINDOWSNT +#include +/* Emulate gettimeofday (Ulrich Leodolter, 1/11/95). */ +void +gettimeofday (struct timeval *tv, struct timezone *tz) +{ + struct _timeb tb; + _ftime (&tb); + + tv->tv_sec = tb.time; + tv->tv_usec = tb.millitm * 1000L; + if (tz) + { + tz->tz_minuteswest = tb.timezone; /* minutes west of Greenwich */ + tz->tz_dsttime = tb.dstflag; /* type of dst correction */ + } +} +#endif + /* Reset the stopwatch to zero. */ static void diff --git a/lib-src/sorted-doc.c b/lib-src/sorted-doc.c index 89ecafd..b7c3baa 100644 --- a/lib-src/sorted-doc.c +++ b/lib-src/sorted-doc.c @@ -224,7 +224,8 @@ main (int argc, char *argv[]) printf ("@unnumbered Command Summary for GNU Emacs\n"); printf ("@table @asis\n"); printf ("\n"); - printf ("@let@ITEM@item\n"); + printf ("@iftex\n"); + printf ("@global@let@ITEM=@item\n"); printf ("@def@item{@filbreak@vskip5pt@ITEM}\n"); printf ("@font@tensy cmsy10 scaled @magstephalf\n"); printf ("@font@teni cmmi10 scaled @magstephalf\n"); @@ -237,6 +238,7 @@ main (int argc, char *argv[]) printf ("@chardef@@64\n"); printf ("@catcode43=12\n"); printf ("@tableindent-0.2in\n"); + printf ("@end iftex\n"); /* print each function from the array */ @@ -260,6 +262,7 @@ main (int argc, char *argv[]) putchar ('\n'); } printf("@end display\n"); + if ( i%200 == 0 && i != 0 ) printf("@end table\n\n@table @asis\n"); } printf ("@end table\n"); diff --git a/lib-src/yow.c b/lib-src/yow.c index f5b7410..6a76772 100644 --- a/lib-src/yow.c +++ b/lib-src/yow.c @@ -9,6 +9,7 @@ /* Synched up with: FSF 19.28. */ +#define DONT_ENCAPSULATE #include <../src/config.h> #include diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 133d7dc..a8c5f60 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,207 @@ +1999-05-14 XEmacs Build Bot + + * XEmacs 21.2.14 is released + +1999-05-13 SL Baur + + * about.el: update contact info for jason and slb. + +1999-05-13 SL Baur + + * mule/european.el (setup-romanian-environment): Add Romanian + support from Emacs/Mule romanian.el. + +1999-03-17 Jan Vroonhof + + * cus-face.el: Label all custom changes with the 'custom' tag. + + * cus-edit.el: idem ditto. + + * faces.el: Added suport for adding device tags to various functions. + (custom): New device tag. + (face-spec-set): Call reset face with tags argument. No longer do + x-init-global-faces hack. + + * faces.el (frob-face-property): Use an anonymous specifier to map + frob-face-property-1 over. + + * x-font-menu.el (font-menu-set-font): Always specify all + properties to custom. + +1999-05-12 SL Baur + + * mule/european.el (setup-czech-environment): Add czech support. + From David Sauer + +1999-03-15 SL Baur + + * check-features.el: Turn hard errors into warnings. + +1999-03-21 SL Baur + + * simple.el (delete-key-deletes-forward): As per discussion on + xemacs-beta, default to t. + +1999-05-11 Hrvoje Niksic + + * loadup.el: Define Installation-string before loading anything. + +1999-05-06 Gunnar Evermann + + * files.el (auto-mode-alist): fix typo in regex for .bash_* files + From Anders Stenman + +1999-05-03 Hrvoje Niksic + + * wid-edit.el (widget-glyph-find): Ditto. + + * packages.el (locate-library): Ditto. + + * loadup.el (really-early-error-handler): Ditto. + + * lib-complete.el (read-library): Ditto. + + * faces.el (set-face-stipple): Ditto. + + * code-files.el (load): Use new calling style of locate-file. + +1999-05-03 Hrvoje Niksic + + * packages.el (packages-unbytecompiled-lisp): Installation.el is + dead. + +1999-05-03 Hrvoje Niksic + + * dumped-lisp.el (preloaded-file-list): Don't load + Installation.el. + + * loadup.el (Installation-string): Define it here. + +1999-05-03 Hrvoje Niksic + + * dumped-lisp.el (preloaded-file-list): Revert previous change -- + Installation.el needs to be loaded before `dump-paths', otherwise + the dumping process won't find it. + +1999-03-13 Adrian Aichner + + * dumped-lisp.el (preloaded-file-list): Load Installation.el after + subr so that we can use `replace-in-string' in Installation.el to + get rid of C-m chars under the native Windows build. + +1999-04-29 Andy Piper + + * make-docfile.el: canonicalize file and directory names. + + * device.el (call-device-method): new function for calling device + specific methods. + (define-device-method): new function for defining device methods. + (define-device-method*): ditto. + +1999-04-27 Hrvoje Niksic + + * subr.el (buffer-string): Support new FSFmacs 20.4 stuff. + +1999-04-08 MORIOKA Tomohiko + + * mule/cyrillic.el (cyrillic-koi8-r-decode-table): New variable. + (cyrillic-koi8-r-encode-table): Likewise. + (ccl-decode-koi8): Use `cyrillic-koi8-r-decode-table'. + (ccl-encode-koi8): Use `cyrillic-koi8-r-encode-table'. + + * mule/mule-misc.el (split-char-or-char-int): New function [moved + from vietnamese.el]. + + * mule/vietnamese.el: Move function `split-char-or-char-int' to + mule/mule-misc.el. + +1999-04-08 MORIOKA Tomohiko + + * mule/thai-xtis.el: + - Change font registry name from "Thai94x94-0" to "xtis-0". + - Change mnemonic of coding-system `tis-620' to "TIS620". + +1999-04-06 MORIOKA Tomohiko + + * mule/ethiopic.el: fixed. + +1999-03-30 MORIOKA Tomohiko + + * dumped-lisp.el: Add ethiopic, thai-xtis and vietnamese. + + * mule/thai-xtis.el: New file. + + * mule/vietnamese.el: New file. + + * mule/ethiopic.el: New file. + +1999-04-22 Hrvoje Niksic + + * bytecomp.el (byte-compile-close-variables): Leave + debug-issue-ebola-notices alone. + +1999-04-11 Oscar Figueiredo + + * ldap.el (ldap-host-parameters-alist): Make `Search Base' appear + at the top of the buffer since it is the most important thing to + customize + (ldap-get-host-parameter): New defun + (ldap-search): Add a new parameter `withdn' to retrieve the + distinguished names of entries + +1999-04-22 Kai Haberzettl + + * startup.el (splash-frame-body): Date and spelling fixes. + +1999-03-16 Colin Rafferty + + * view-less.el (toggle-truncate-lines): add autoload tag + +1999-04-19 Hrvoje Niksic + + * format.el (format-alist): Disable image stuff. + +1999-04-17 Hrvoje Niksic + + * wid-edit.el (widget-glyph-find): Search by directories, then by + suffixes rather than the other way around. + (widget-image-conversion): Renamed to + `widget-image-file-name-suffixes'. + +1999-04-16 Olivier Galibert + + * mule/mule-charset.el: Made old functions obsolete, remove the + unspeakably evil (and inexistant in fsf's) charset-leading-byte. + (charset-iso-graphic-plane): Rename from charset-graphic. + (charset-iso-final-char): Rename from charset-final. + (charset-width): Rename from charset-columns. + (charset-bytes): Added from fsf compatibility, returns always 1. + + * mule/mule-misc.el: Move charset-doc-string alias to + mule-charset.el + +1999-04-14 Colin Rafferty + + * x-faces.el (x-make-font-bold-italic): honor + *try-oblique-before-italic-fonts* + +1999-04-14 Hrvoje Niksic + + * cl-extra.el (coerce): Coerce numbers to characters correctly. + +1998-12-02 Hrvoje Niksic + + * x-faces.el (try-oblique-before-italic-fonts): Use the right + name. + +1999-04-14 Dave Gillesipe + + * cl-extra.el (equalp): Would bug out for lists. + +1999-03-12 Charles G Waldman + + * about.el (about-hackers): Change cgw's email address + 1999-03-12 XEmacs Build Bot * XEmacs 21.2.13 is released diff --git a/lisp/about.el b/lisp/about.el index 959887e..9fcddb2 100644 --- a/lisp/about.el +++ b/lisp/about.el @@ -564,13 +564,8 @@ contributed to the XEmacs development from late 1994 to early (ecase (car entry) (slb (widget-insert "\ -I took over the maintenance of XEmacs in November of 1996 (it -seemed like a good idea at the time ...). In real life I am a -network administrator and Unix systems programmer for Calag.com, -Inc. a small, but growing ISP in California. - -My main hobby while not maintaining XEmacs or working is ... -you have got to be kidding ...") +Peaches Baur, 1986-1999. +Rest in peace") (widget-insert ".\n")) (martin (widget-insert "\ @@ -962,8 +957,9 @@ My homepage is ") (widget-insert ".\n")) (jason (widget-insert "\ -Beta tester and manager of the various XEmacs mailing lists. -Originator and maintainer of the gnus.org domain. +Beta tester, manager of the various XEmacs mailing lists and +binary kit manager. Also, originator and maintainer of the gnus.org +domain. Jason resides in Albuquerque, New Mexico where he keeps himself busy with studies at the university and consulting work. @@ -1492,7 +1488,7 @@ above. We couldn't have done it without them.\n\n" (print-short "Juan E. Villacis" "jvillaci@cs.indiana.edu") (print-short "Jan Vroonhof" "vroonhof@math.ethz.ch") (print-short "Vladimir Vukicevic" "vladimir@intrepid.com") - (print-short "Charles G. Waldman" "cgw@pgt.com") + (print-short "Charles G. Waldman" "cgw@fnal.gov") (print-short "David Walte" "djw18@cornell.edu") (print-short "Peter Ware" "ware@cis.ohio-state.edu") (print-short "Christoph Wedler" "wedler@fmi.uni-passau.de") diff --git a/lisp/auto-autoloads.el b/lisp/auto-autoloads.el index 3e38aee..b485276 100644 --- a/lisp/auto-autoloads.el +++ b/lisp/auto-autoloads.el @@ -1615,7 +1615,7 @@ The buffer in question is current when this function is called." nil nil) ;;;*** -;;;### (autoloads (auto-view-mode view-major-mode view-mode view-minor-mode view-buffer-other-window view-file-other-window view-buffer view-file) "view-less" "lisp/view-less.el") +;;;### (autoloads (toggle-truncate-lines auto-view-mode view-major-mode view-mode view-minor-mode view-buffer-other-window view-file-other-window view-buffer view-file) "view-less" "lisp/view-less.el") (defvar view-minor-mode-map (let ((map (make-keymap))) (set-keymap-name map 'view-minor-mode-map) (suppress-keymap map) (define-key map "-" 'negative-argument) (define-key map " " 'scroll-up) (define-key map "f" 'scroll-up) (define-key map "b" 'scroll-down) (define-key map 'backspace 'scroll-down) (define-key map 'delete 'scroll-down) (define-key map " " 'view-scroll-lines-up) (define-key map "\n" 'view-scroll-lines-up) (define-key map "e" 'view-scroll-lines-up) (define-key map "j" 'view-scroll-lines-up) (define-key map "y" 'view-scroll-lines-down) (define-key map "k" 'view-scroll-lines-down) (define-key map "d" 'view-scroll-some-lines-up) (define-key map "u" 'view-scroll-some-lines-down) (define-key map "r" 'recenter) (define-key map "t" 'toggle-truncate-lines) (define-key map "N" 'view-buffer) (define-key map "E" 'view-file) (define-key map "P" 'view-buffer) (define-key map "!" 'shell-command) (define-key map "|" 'shell-command-on-region) (define-key map "=" 'what-line) (define-key map "?" 'view-search-backward) (define-key map "h" 'view-mode-describe) (define-key map "s" 'view-repeat-search) (define-key map "n" 'view-repeat-search) (define-key map "/" 'view-search-forward) (define-key map "\\" 'view-search-backward) (define-key map "g" 'view-goto-line) (define-key map "G" 'view-last-windowful) (define-key map "%" 'view-goto-percent) (define-key map "p" 'view-goto-percent) (define-key map "m" 'point-to-register) (define-key map "'" 'register-to-point) (define-key map "C" 'view-cleanup-backspaces) (define-key map "" 'view-quit) (define-key map "" 'view-quit-toggle-ro) (define-key map "q" 'view-quit) map)) @@ -1681,6 +1681,10 @@ named but is like this for compatibility reasons." t nil) If the file of the current buffer is not writable, call view-mode. This is meant to be added to `find-file-hooks'." nil nil) +(autoload 'toggle-truncate-lines "view-less" "\ +Toggles the values of truncate-lines. +Positive prefix arg sets, negative disables." t nil) + ;;;*** ;;;### (autoloads (widget-minor-mode widget-browse-other-window widget-browse widget-browse-at) "wid-browse" "lisp/wid-browse.el") @@ -1717,9 +1721,9 @@ Delete WIDGET." nil nil) ;;;### (autoloads (font-menu-weight-constructor font-menu-size-constructor font-menu-family-constructor reset-device-font-menus) "x-font-menu" "lisp/x-font-menu.el") -(defcustom font-menu-ignore-scaled-fonts t "*If non-nil, then the font menu will try to show only bitmap fonts." :type 'boolean :group 'x) +(defcustom font-menu-ignore-scaled-fonts t "*If non-nil, then the font menu will try to show only bitmap fonts." :type 'boolean :group 'font-menu) -(defcustom font-menu-this-frame-only-p nil "*If non-nil, then changing the default font from the font menu will only\naffect one frame instead of all frames." :type 'boolean :group 'x) +(defcustom font-menu-this-frame-only-p nil "*If non-nil, then changing the default font from the font menu will only\naffect one frame instead of all frames." :type 'boolean :group 'font-menu) (fset 'install-font-menus 'reset-device-font-menus) diff --git a/lisp/bytecomp.el b/lisp/bytecomp.el index 5340162..d8ab789 100644 --- a/lisp/bytecomp.el +++ b/lisp/bytecomp.el @@ -432,7 +432,6 @@ on the specbind stack. The cdr of each cell is an integer bitmask.") (defvar byte-compile-free-references) (defvar byte-compile-free-assignments) -(defvar debug-issue-ebola-notices) (defvar byte-compiler-error-flag) @@ -1298,11 +1297,7 @@ otherwise pop it") (byte-compile-warnings (if (eq byte-compile-warnings t) byte-compile-default-warnings byte-compile-warnings)) - (byte-compile-file-domain nil) - - ;; We reserve the right to compare ANY objects for equality. - (debug-issue-ebola-notices -42) - ) + (byte-compile-file-domain nil)) (prog1 (progn ,@body) (if (memq 'unused-vars byte-compile-warnings) diff --git a/lisp/check-features.el b/lisp/check-features.el index 3aa0a82..9596ff7 100644 --- a/lisp/check-features.el +++ b/lisp/check-features.el @@ -39,8 +39,8 @@ (condition-case nil (package-require 'tooltalk 1.0) (t (progn - (setq build-error 1) - (message "Error: This XEmacs is built with tooltalk support but") + ;; (setq build-error 1) + (message "Warning: This XEmacs is built with tooltalk support but") (message "does not have a tooltalk package installed. Without the") (message "tooltalk lisp package, Tooltalk support is broken."))))) @@ -48,8 +48,8 @@ (condition-case nil (package-require 'Sun 1.0) (t (progn - (setq build-error 1) - (message "Error: This XEmacs is built with sparcworks support but") + ;; (setq build-error 1) + (message "Warning: This XEmacs is built with sparcworks support but") (message "does not have the Sun package installed. Without the Sun") (message "lisp package, Sparcworks support will be broken."))))) diff --git a/lisp/cl-extra.el b/lisp/cl-extra.el index e419fe3..8c97ea0 100644 --- a/lisp/cl-extra.el +++ b/lisp/cl-extra.el @@ -76,6 +76,8 @@ TYPE is a Common Lisp type specifier." ((eq type 'array) (if (arrayp x) x (vconcat x))) ((and (eq type 'character) (stringp x) (= (length x) 1)) (aref x 0)) ((and (eq type 'character) (symbolp x)) (coerce (symbol-name x) type)) + ((and (eq type 'character) (numberp x) (char-or-char-int-p x) + (int-char x))) ((eq type 'float) (float x)) ((eq type 'bit-vector) (if (bit-vector-p x) x (apply 'bit-vector (append x nil)))) @@ -108,7 +110,8 @@ strings case-insensitively." (and (numberp y) (= x y))) ((consp x) ;; XEmacs change - (while (and (consp x) (consp y) (equalp (cl-pop x) (cl-pop y)))) + (while (and (consp x) (consp y) (equalp (car x) (car y))) + (cl-pop x) (cl-pop y)) (and (not (consp x)) (equalp x y))) ((vectorp x) (and (vectorp y) (= (length x) (length y)) diff --git a/lisp/code-files.el b/lisp/code-files.el index accbc0d..d74a11c 100644 --- a/lisp/code-files.el +++ b/lisp/code-files.el @@ -271,7 +271,7 @@ Return t if file exists." (if (or (<= (length filename) 0) (null (setq path (locate-file filename load-path - (and (not nosuffix) ".elc:.el:"))))) + (and (not nosuffix) '(".elc" ".el" "")))))) (and (null noerror) (signal 'file-error (list "Cannot open load file" filename))) ;; now use the internal load to actually load the file. diff --git a/lisp/custom-load.el b/lisp/custom-load.el index 7f2e6b3..54b38b3 100644 --- a/lisp/custom-load.el +++ b/lisp/custom-load.el @@ -55,6 +55,7 @@ (custom-add-loads 'widget-button '("wid-edit")) (custom-add-loads 'paren-blinking '("simple")) (custom-add-loads 'find-file '("files")) +(custom-add-loads 'font-menu '("x-font-menu")) (custom-add-loads 'files '("files")) (custom-add-loads 'build '("build-report")) (custom-add-loads 'font-lock '("font-lock")) diff --git a/lisp/device.el b/lisp/device.el index 6d40d5f..06bac1c 100644 --- a/lisp/device.el +++ b/lisp/device.el @@ -106,6 +106,29 @@ the toolbar, glyphs, etc." (or device (setq device (selected-device))) (console-on-window-system-p (device-console device))) +(defun call-device-method (name device &rest args) + "Call a DEVICE-specific function with the generic name NAME. +If DEVICE is not provide the selected device is used." + (or device (setq device (selected-device))) + (or (symbolp name) (error "function name must be a symbol")) + (let ((devmeth (intern (concat (symbol-name + (device-type device)) "-" (symbol-name name))))) + (if (functionp devmeth) + (if args + (apply devmeth args) + (funcall devmeth)) + nil))) + +(defmacro define-device-method (name &optional docstring) + "Define NAME to be a device method." + `(defun ,name (&rest arglist) ,docstring + (apply 'call-device-method (quote ,name) nil arglist))) + +(defmacro define-device-method* (name &optional docstring) + "Define NAME to be a device method." + `(defun* ,name (&rest arglist) ,docstring + (apply 'call-device-method (quote ,name) nil arglist))) + (defalias 'valid-device-type-p 'valid-console-type-p) (defalias 'device-type-list 'console-type-list) (defalias 'device-pixel-depth 'device-bitplanes) diff --git a/lisp/dumped-lisp.el b/lisp/dumped-lisp.el index 290991b..07c67ce 100644 --- a/lisp/dumped-lisp.el +++ b/lisp/dumped-lisp.el @@ -2,7 +2,6 @@ (assemble-list "backquote" ; needed for defsubst etc. "bytecomp-runtime" ; define defsubst - "Installation.el" "find-paths" "packages" ; Bootstrap run-time lisp environment "setup-paths" @@ -128,16 +127,16 @@ (when-feature mule "chinese") (when-feature mule "mule/cyrillic") ; overloaded in leim/quail (when-feature mule "english") -;; (when-feature mule "ethiopic") + (when-feature mule "ethiopic") (when-feature mule "european") (when-feature mule "mule/greek") ; overloaded in leim/quail (when-feature mule "hebrew") (when-feature mule "japanese") (when-feature mule "korean") (when-feature mule "misc-lang") -;; (when-feature mule "thai") + (when-feature mule "thai-xtis") (when-feature mule "viet-chars") -;; (when-feature mule "vietnamese") + (when-feature mule "vietnamese") ;; Specialized language support (when-feature (and mule CANNA) "canna-leim") diff --git a/lisp/faces.el b/lisp/faces.el index a0c193e..8231011 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -1575,7 +1575,7 @@ If the optional FRAME argument is provided, change only in that frame; otherwise change each frame." (while (not (find-face face)) (setq face (signal 'wrong-type-argument (list 'facep face)))) - (locate-file pixmap x-bitmap-file-path ".xbm:" 4) + (locate-file pixmap x-bitmap-file-path '(".xbm" "")) (while (cond ((stringp pixmap) (unless (file-readable-p pixmap) (setq pixmap `[xbm :file ,pixmap])) diff --git a/lisp/files.el b/lisp/files.el index 2480c79..186043f 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -1158,7 +1158,7 @@ run `normal-mode' explicitly." ("\\.icn\\'" . icon-mode) ("\\.\\(?:[ckz]?sh\\|shar\\)\\'" . sh-mode) ;; #### Unix-specific! - ("/\\.\\(?:bash_\\|z\\)?\\(profile\\|login\||logout\\)\\'" . sh-mode) + ("/\\.\\(?:bash_\\|z\\)?\\(profile\\|login\\|logout\\)\\'" . sh-mode) ("/\\.\\(?:[ckz]sh\\|bash\\|tcsh\\|es\\|xinit\\|startx\\)rc\\'" . sh-mode) ("/\\.\\(?:[kz]shenv\\|xsession\\)\\'" . sh-mode) ;; The following come after the ChangeLog pattern for the sake of diff --git a/lisp/format.el b/lisp/format.el index 2b4c609..7542247 100644 --- a/lisp/format.el +++ b/lisp/format.el @@ -69,20 +69,21 @@ (put 'buffer-file-format 'permanent-local t) (defvar format-alist - '((image/jpeg "JPEG image" "\377\330\377\340\000\020JFIF" - image-decode-jpeg nil t image-mode) - (image/gif "GIF image" "GIF8[79]" - image-decode-gif nil t image-mode) - (image/png "Portable Network Graphics" "\211PNG" - image-decode-png nil t image-mode) - (image/x-xpm "XPM image" "/\\* XPM \\*/" - image-decode-xpm nil t image-mode) - - ;; TIFF files have lousy magic - (image/tiff "TIFF image" "II\\*\000" - image-decode-tiff nil t image-mode) ;; TIFF 6.0 big-endian - (image/tiff "TIFF image" "MM\000\\*" - image-decode-tiff nil t image-mode) ;; TIFF 6.0 little-endian + '( +; (image/jpeg "JPEG image" "\377\330\377\340\000\020JFIF" +; image-decode-jpeg nil t image-mode) +; (image/gif "GIF image" "GIF8[79]" +; image-decode-gif nil t image-mode) +; (image/png "Portable Network Graphics" "\211PNG" +; image-decode-png nil t image-mode) +; (image/x-xpm "XPM image" "/\\* XPM \\*/" +; image-decode-xpm nil t image-mode) + +; ;; TIFF files have lousy magic +; (image/tiff "TIFF image" "II\\*\000" +; image-decode-tiff nil t image-mode) ;; TIFF 6.0 big-endian +; (image/tiff "TIFF image" "MM\000\\*" +; image-decode-tiff nil t image-mode) ;; TIFF 6.0 little-endian (text/enriched "Extended MIME text/enriched format." "Content-[Tt]ype:[ \t]*text/enriched" diff --git a/lisp/ldap.el b/lisp/ldap.el index 2e01edb..57cfe78 100644 --- a/lisp/ldap.el +++ b/lisp/ldap.el @@ -5,7 +5,7 @@ ;; Author: Oscar Figueiredo ;; Maintainer: Oscar Figueiredo ;; Created: Jan 1998 -;; Version: $Revision: 1.7.2.2 $ +;; Version: $Revision: 1.7.2.3 $ ;; Keywords: help comm ;; This file is part of XEmacs @@ -40,7 +40,9 @@ :group 'comm) (defcustom ldap-default-host nil - "*Default LDAP server." + "*Default LDAP server hostname. +A TCP port number can be appended to that name using a colon as +a separator." :type '(choice (string :tag "Host name") (const :tag "Use library default" nil)) :group 'ldap) @@ -66,8 +68,10 @@ Acme organization in the United States." "*Alist of host-specific options for LDAP transactions. The format of each list element is: \(HOST PROP1 VAL1 PROP2 VAL2 ...) -HOST is the name of an LDAP server. PROPn and VALn are property/value -pairs describing parameters for the server. Valid properties include: +HOST is the hostname of an LDAP server (with an optional TCP port number +appended to it using a colon as a separator). +PROPn and VALn are property/value pairs describing parameters for the server. +Valid properties include: `binddn' is the distinguished name of the user to bind as (in RFC 1779 syntax). `passwd' is the password to use for simple authentication. @@ -87,6 +91,11 @@ pairs describing parameters for the server. Valid properties include: (checklist :inline t :greedy t (list + :tag "Search Base" + :inline t + (const :tag "Search Base" base) + string) + (list :tag "Binding DN" :inline t (const :tag "Binding DN" binddn) @@ -106,11 +115,6 @@ pairs describing parameters for the server. Valid properties include: (const :menu-tag "Kerberos 4.1" :tag "Kerberos 4.1" krbv41) (const :menu-tag "Kerberos 4.2" :tag "Kerberos 4.2" krbv42))) (list - :tag "Search Base" - :inline t - (const :tag "Search Base" base) - string) - (list :tag "Search Scope" :inline t (const :tag "Search Scope" scope) @@ -141,8 +145,12 @@ pairs describing parameters for the server. Valid properties include: (integer :tag "(number of records)"))))) :group 'ldap) - -(defun ldap-search (filter &optional host attributes attrsonly) +(defun ldap-get-host-parameter (host parameter) + "Get the value of PARAMETER for HOST in `ldap-host-parameters-alist'." + (plist-get (cdr (assoc host ldap-host-parameters-alist)) + parameter)) + +(defun ldap-search (filter &optional host attributes attrsonly withdn) "Perform an LDAP search. FILTER is the search filter in RFC1558 syntax, i.e. something that looks like \"(cn=John Smith)\". @@ -150,8 +158,13 @@ HOST is the LDAP host on which to perform the search. ATTRIBUTES is a list of attributes to retrieve; nil means retrieve all. If ATTRSONLY is non nil, the attributes will be retrieved without the associated values. +If WITHDN is non-nil each entry in the result will be prepennded with +its distinguished name DN. Additional search parameters can be specified through -`ldap-host-parameters-alist' which see." +`ldap-host-parameters-alist' which see. +The function returns a list of matching entries. Each entry is itself +an alist of attribute/value pairs optionally preceded by the DN of the +entry according to the value of WITHDN." (interactive "sFilter:") (or host (setq host ldap-default-host)) @@ -165,7 +178,7 @@ Additional search parameters can be specified through (prog1 (ldap-search-internal ldap filter (plist-get host-plist 'base) (plist-get host-plist 'scope) - attributes attrsonly) + attributes attrsonly withdn) (ldap-close ldap)))) (provide 'ldap) diff --git a/lisp/lib-complete.el b/lisp/lib-complete.el index 19e66da..7ae20c3 100644 --- a/lisp/lib-complete.el +++ b/lisp/lib-complete.el @@ -38,7 +38,7 @@ ;; Last Modified By: Heiko M|nkel ;; Additional XEmacs integration By: Chuck Thompson ;; Last Modified On: Thu Jul 1 14:23:00 1994 -;; RCS Info : $Revision: 1.1 $ $Locker: $ +;; RCS Info : $Revision: 1.3.2.1 $ $Locker: $ ;; ======================================================================== ;; NOTE: XEmacs must be redumped if this file is changed. ;; @@ -255,10 +255,7 @@ Optional sixth argument FILTER can be used to provide a function to (cond ((equal library "") DEFAULT) (FULL (locate-file library read-library-internal-search-path - ;; decompression doesn't work with Mule -slb - (if (featurep 'mule) - ".el:.elc" - ".el:.el.gz:.elc"))) + '(".el" ".el.gz" ".elc"))) (t library)))) ;; NOTE: as a special case, read-library may be used to read a filename diff --git a/lisp/loadup.el b/lisp/loadup.el index ee86aa9..4c836bb 100644 --- a/lisp/loadup.el +++ b/lisp/loadup.el @@ -42,18 +42,36 @@ (defvar preloaded-file-list nil "List of files preloaded into the XEmacs binary image.") +(defvar Installation-string nil + "Description of XEmacs installation.") (let ((gc-cons-threshold 30000)) ;; This is awfully damn early to be getting an error, right? (call-with-condition-handler 'really-early-error-handler #'(lambda () - ;; message not defined yet ... + + ;; Initializa Installation-string. We do it before loading + ;; anything so that dumped code can make use of its value. + (setq Installation-string + (save-current-buffer + (set-buffer (get-buffer-create (generate-new-buffer-name + " *temp*"))) + ;; insert-file-contents-internal bogusly calls + ;; format-decode without checking if it's defined. + (fset 'format-decode #'(lambda (f l &optional v) l)) + (insert-file-contents-internal "../Installation") + (fmakunbound 'format-decode) + (prog1 (buffer-substring) + (kill-buffer (current-buffer))))) + (setq load-path (split-path (getenv "EMACSBOOTSTRAPLOADPATH"))) (setq module-load-path (split-path (getenv "EMACSBOOTSTRAPMODULEPATH"))) + ;; message not defined yet ... (external-debugging-output (format "\nUsing load-path %s" load-path)) - (external-debugging-output (format "\nUsing module-load-path %s" module-load-path)) + (external-debugging-output (format "\nUsing module-load-path %s" + module-load-path)) ;; We don't want to have any undo records in the dumped XEmacs. (buffer-disable-undo (get-buffer "*scratch*")) @@ -86,7 +104,8 @@ (defun pureload (file) (let ((full-path (locate-file file load-path - (if load-ignore-elc-files ".el:" ".elc:.el:")))) + (if load-ignore-elc-files + '(".el" "") '(".elc" ".el" ""))))) (if full-path (prog1 (load full-path) @@ -145,7 +164,6 @@ ;;; for the sake of the next call to precompute-menubar-bindings. ;(setq define-key-rebound-commands nil) - ;; Note: all compiled Lisp files loaded above this point ;; must be among the ones parsed by make-docfile ;; to construct DOC. Any that are not processed diff --git a/lisp/make-docfile.el b/lisp/make-docfile.el index c501878..e67fdbf 100644 --- a/lisp/make-docfile.el +++ b/lisp/make-docfile.el @@ -51,9 +51,9 @@ (string-equal arg "-a") ; Append to DOC file (string-equal arg "-d")) ; Set working directory (if (string-equal arg "-o") - (setq docfile (car (cdr command-line-args)))) + (setq docfile (expand-file-name (car (cdr command-line-args))))) (setq options (cons arg options)) - (setq options (cons (car (cdr command-line-args)) options))) + (setq options (cons (expand-file-name (car (cdr command-line-args))) options))) ((string-equal arg "-i") ; Set site files to scan (setq site-file-list (car (cdr command-line-args)))) (t (setq done t))) diff --git a/lisp/msw-select.el b/lisp/msw-select.el index cd99854..34b43b8 100644 --- a/lisp/msw-select.el +++ b/lisp/msw-select.el @@ -86,7 +86,9 @@ Interactively, the text of the region is used as the selection value." valid)) (signal 'error (list "invalid selection" data))) (if data - (setq mswindows-selection-owned-p data) + (progn +; (mswindows-set-clipboard data) + (setq mswindows-selection-owned-p data)) (setq mswindows-selection-owned-p nil)) (setq primary-selection-extent (select-make-extent-for-selection diff --git a/lisp/mule/cyrillic.el b/lisp/mule/cyrillic.el index 24322f8..01eedc5 100644 --- a/lisp/mule/cyrillic.el +++ b/lisp/mule/cyrillic.el @@ -1,6 +1,6 @@ ;;; cyrillic.el --- Support for languages which use Cyrillic characters -;; Copyright (C) 1995 Electrotechnical Laboratory, JAPAN. +;; Copyright (C) 1995,1999 Electrotechnical Laboratory, JAPAN. ;; Licensed to the Free Software Foundation. ;; Copyright (C) 1997 MORIOKA Tomohiko @@ -32,9 +32,9 @@ ;; For syntax of Cyrillic (modify-syntax-entry 'cyrillic-iso8859-5 "w") -(modify-syntax-entry ?,L-(B ".") -(modify-syntax-entry ?,Lp(B ".") -(modify-syntax-entry ?,L}(B ".") +(modify-syntax-entry ?.LN- ".") +(modify-syntax-entry ?.LNp ".") +(modify-syntax-entry ?.LN} ".") ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; CYRILLIC @@ -77,53 +77,68 @@ (charset . (cyrillic-iso8859-5)) (tutorial . "TUTORIAL.ru") (coding-system . (iso-8859-5)) - (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!") + (sample-text . "Russian (.LN@NcNaNaNZNXNY) N7NTN`NPNRNaNbNRNcNYNbNU!") (documentation . ("Support for Cyrillic ISO-8859-5." . describe-cyrillic-environment-map)))) ;; KOI-8 staff +(eval-and-compile + +(defvar cyrillic-koi8-r-decode-table + [ + 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 + 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 + 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 + 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 + 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 + 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 + 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 + 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 + ?$B(!(B ?$B("(B ?$B(#(B ?$B($(B ?$B(&(B ?$B(%(B ?$B('(B ?$B()(B ?$B(((B ?$B(*(B ?$B(+(B 32 ?$(G#'(B ?$(G#+(B ?$(G#/(B 32 + 144 ?$(C"F(B 146 147 ?$B"#(B 149 ?$B"e(B ?$A!V(B ?$A!\(B ?$A!](B ?.AN 32 ?N0 ?N2 ?N7 ?Nw + ?$(G#D(B 32 32 ?.LNq 32 32 32 32 32 32 32 32 32 32 32 ?$(G#E(B + 32 32 ?$(G#G(B ?.LN! 32 32 32 32 32 32 32 32 ?$(G#F(B 32 32 ?.AN) + ?.LNn ?NP ?NQ ?Nf ?NT ?NU ?Nd ?NS ?Ne ?NX ?NY ?NZ ?N[ ?N\ ?N] ?N^ + ?.LN_ ?No ?N` ?Na ?Nb ?Nc ?NV ?NR ?Nl ?Nk ?NW ?Nh ?Nm ?Ni ?Ng ?Nj + ?.LNN ?N0 ?N1 ?NF ?N4 ?N5 ?ND ?N3 ?NE ?N8 ?N9 ?N: ?N; ?N< ?N= ?N> + ?.LN? ?NO ?N@ ?NA ?NB ?NC ?N6 ?N2 ?NL ?NK ?N7 ?NH ?NM ?NI ?NG ?NJ ] + "Cyrillic KOI8-R decoding table.") + +(defvar cyrillic-koi8-r-encode-table + (let ((table (make-vector 256 32)) + (i 0)) + (while (< i 256) + (let* ((ch (aref cyrillic-koi8-r-decode-table i)) + (split (split-char-or-char-int ch))) + (cond ((eq (car split) 'cyrillic-iso8859-5) + (aset table (logior (nth 1 split) 128) i) + ) + ((eq ch 32)) + ((eq (car split) 'ascii) + (aset table ch i) + ))) + (setq i (1+ i))) + table) + "Cyrillic KOI8-R encoding table.") + +) + (define-ccl-program ccl-decode-koi8 - '(3 + `(3 ((read r0) (loop - (write-read-repeat - r0 - [0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 - 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 - 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 - 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 - 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 - 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 - 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 - 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 - 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 - 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 - 32 32 32 ?,Lq(B 32 32 32 32 32 32 32 32 32 32 32 32 - 32 32 32 ?,L!(B 32 32 32 32 32 32 32 32 32 32 32 32 - ?,Ln(B ?,LP(B ?,LQ(B ?,Lf(B ?,LT(B ?,LU(B ?,Ld(B ?,LS(B ?,Le(B ?,LX(B ?,LY(B ?,LZ(B ?,L[(B ?,L\(B ?,L](B ?,L^(B - ?,L_(B ?,Lo(B ?,L`(B ?,La(B ?,Lb(B ?,Lc(B ?,LV(B ?,LR(B ?,Ll(B ?,Lk(B ?,LW(B ?,Lh(B ?,Lm(B ?,Li(B ?,Lg(B ?,Lj(B - ?,LN(B ?,L0(B ?,L1(B ?,LF(B ?,L4(B ?,L5(B ?,LD(B ?,L3(B ?,LE(B ?,L8(B ?,L9(B ?,L:(B ?,L;(B ?,L<(B ?,L=(B ?,L>(B - ?,L?(B ?,LO(B ?,L@(B ?,LA(B ?,LB(B ?,LC(B ?,L6(B ?,L2(B ?,LL(B ?,LK(B ?,L7(B ?,LH(B ?,LM(B ?,LI(B ?,LG(B ?,LJ(B ])))) + (write-read-repeat r0 ,cyrillic-koi8-r-decode-table)))) "CCL program to decode KOI8.") (define-ccl-program ccl-encode-koi8 `(1 ((read r0) (loop - (if (r0 != ,(charset-id 'cyrillic-iso8859-5)) - (write-read-repeat r0) - ((read r0) - (r0 -= 160) - (write-read-repeat - r0 - [ 32 179 32 32 32 32 32 32 32 32 32 32 32 32 32 32 - 225 226 247 231 228 229 246 250 233 234 235 236 237 238 239 240 - 242 243 244 245 230 232 227 254 251 253 255 249 248 252 224 241 - 193 194 215 199 196 197 214 218 201 202 203 204 205 206 207 208 - 210 211 212 213 198 200 195 222 219 221 223 217 216 220 192 209 - 32 163 32 32 32 32 32 32 32 32 32 32 32 32 32 32]) - ))))) + (if (r0 != ,(charset-id 'cyrillic-iso8859-5)) + (write-read-repeat r0) + ((read r0) + (write-read-repeat r0 , cyrillic-koi8-r-encode-table)))))) "CCL program to encode KOI8.") ;(make-coding-system @@ -169,7 +184,7 @@ (charset . (cyrillic-iso8859-5)) (coding-system . (koi8-r)) (tutorial . "TUTORIAL.ru") - (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!") + (sample-text . "Russian (.LN@NcNaNaNZNXNY) N7NTN`NPNRNaNbNRNcNYNbNU!") (documentation . ("Support for Cyrillic KOI-8." . describe-cyrillic-environment-map)))) @@ -189,14 +204,14 @@ 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 - ?,L0(B ?,L1(B ?,L2(B ?,L3(B ?,L4(B ?,L5(B ?,L6(B ?,L7(B ?,L8(B ?,L9(B ?,L:(B ?,L;(B ?,L<(B ?,L=(B ?,L>(B ?,L?(B - ?,L@(B ?,LA(B ?,LB(B ?,LC(B ?,LD(B ?,LE(B ?,LF(B ?,LG(B ?,LH(B ?,LI(B ?,LJ(B ?,LK(B ?,LL(B ?,LM(B ?,LN(B ?,LO(B - ?,LP(B ?,LQ(B ?,LR(B ?,LS(B ?,LT(B ?,LU(B ?,LV(B ?,LW(B ?,LX(B ?,LY(B ?,LZ(B ?,L[(B ?,L\(B ?,L](B ?,L^(B ?,L_(B + ?.LN0 ?N1 ?N2 ?N3 ?N4 ?N5 ?N6 ?N7 ?N8 ?N9 ?N: ?N; ?N< ?N= ?N> ?N? + ?.LN@ ?NA ?NB ?NC ?ND ?NE ?NF ?NG ?NH ?NI ?NJ ?NK ?NL ?NM ?NN ?NO + ?.LNP ?NQ ?NR ?NS ?NT ?NU ?NV ?NW ?NX ?NY ?NZ ?N[ ?N\ ?N] ?N^ ?N_ 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 - ?,L`(B ?,La(B ?,Lb(B ?,Lc(B ?,Ld(B ?,Le(B ?,Lf(B ?,Lg(B ?,Lh(B ?,Li(B ?,Lj(B ?,Lk(B ?,Ll(B ?,Lm(B ?,Ln(B ?,Lo(B - ?,L!(B ?,Lq(B 32 32 32 32 32 32 32 32 32 32 32 32 32 ?,Lp(B])))) + ?.LN` ?Na ?Nb ?Nc ?Nd ?Ne ?Nf ?Ng ?Nh ?Ni ?Nj ?Nk ?Nl ?Nm ?Nn ?No + ?.LN! ?Nq 32 32 32 32 32 32 32 32 32 32 32 32 32 ?Np])))) "CCL program to decode Alternativnyj.") (define-ccl-program ccl-encode-alternativnyj @@ -253,7 +268,7 @@ (charset . (cyrillic-iso8859-5)) (coding-system . (alternativnyj)) (tutorial . "TUTORIAL.ru") - (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!") + (sample-text . "Russian (.LN@NcNaNaNZNXNY) N7NTN`NPNRNaNbNRNcNYNbNU!") (documentation . ("Support for Cyrillic ALTERNATIVNYJ." . describe-cyrillic-environment-map)))) @@ -288,7 +303,7 @@ (charset . (cyrillic-iso8859-5)) (tutorial . "TUTORIAL.ru") (coding-system . (iso-8859-5 koi8-r alternativnyj)) - (sample-text . "Russian (,L@caaZXY(B) ,L7T`PRabRcYbU(B!") + (sample-text . "Russian (.LN@NcNaNaNZNXNY) N7NTN`NPNRNaNbNRNcNYNbNU!") (documentation . nil))) ;;; cyrillic.el ends here diff --git a/lisp/mule/ethiopic.el b/lisp/mule/ethiopic.el new file mode 100644 index 0000000..f7ddcaa --- /dev/null +++ b/lisp/mule/ethiopic.el @@ -0,0 +1,81 @@ +;;; ethiopic.el --- Support for Ethiopic + +;; Copyright (C) 1995 Electrotechnical Laboratory, JAPAN. +;; Licensed to the Free Software Foundation. +;; Copyright (C) 1997 MORIOKA Tomohiko + +;; Keywords: multilingual, Ethiopic + +;; 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. + +;; Author: TAKAHASHI Naoto +;; modified by MORIOKA Tomohiko for XEmacs. + +;;; Code: + +;; Ethiopic +(make-charset 'ethiopic "Ethiopic" + '(registry "Ethio" + dimension 2 + chars 94 + final ?3 + graphic 0 + )) + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;; ETHIOPIC +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + +(define-category ?E "Ethiopic (Ge'ez) character.") +(modify-category-entry 'ethiopic ?E) + +(define-ccl-program ccl-encode-ethio-font + '(0 + ;; In: R0:ethiopic (not checked) + ;; R1:position code 1 + ;; R2:position code 2 + ;; Out: R1:font code point 1 + ;; R2:font code point 2 + ((r1 -= 33) + (r2 -= 33) + (r1 *= 94) + (r2 += r1) + (if (r2 < 256) + (r1 = ?\x12) + (if (r2 < 448) + ((r1 = ?\x13) (r2 -= 256)) + ((r1 = ?\xfd) (r2 -= 208)) + )))) + "CCL program to encode an Ethiopic code to code point of Ethiopic font.") + +;; (setq font-ccl-encoder-alist +;; (cons (cons "ethiopic" ccl-encode-ethio-font) font-ccl-encoder-alist)) +(set-charset-ccl-program 'ethiopic ccl-encode-ethio-font) + +(set-language-info-alist + "Ethiopic" '((setup-function . setup-ethiopic-environment-internal) + (exit-function . exit-ethiopic-environment) + (charset ethiopic) + (coding-system iso-2022-7bit) + (coding-priority iso-2022-7bit) + (input-method . "ethiopic") + (features ethio-util) + (sample-text . "$(3$Q#U!.(B") + (documentation . t))) + +;;; ethiopic.el ends here diff --git a/lisp/mule/european.el b/lisp/mule/european.el index 7feb4e4..420ca2c 100644 --- a/lisp/mule/european.el +++ b/lisp/mule/european.el @@ -229,8 +229,16 @@ These languages are supported with the Latin-2 (ISO-8859-2) character set: " . describe-european-environment-map)) )) +;; Romanian support originally from romanian.el + +(defun setup-romanian-environment () + "Setup multilingual environment (MULE) for Romanian." + (interactive) + (setup-8-bit-environment "Romanian" 'latin-iso8859-2 'iso-8859-2 + "romanian")) + (set-language-info-alist - "Romanian" '((setup-function . (setup-latin2-environment + "Romanian" '((setup-function . (setup-romanian-environment . setup-european-environment-map)) (charset . (ascii latin-iso8859-2)) (tutorial . "TUTORIAL.ro") @@ -241,6 +249,33 @@ These languages are supported with the Latin-2 (ISO-8859-2) character set: Serbian, Croatian, Slovak, Slovene, and Swedish. " . describe-european-environment-map)) )) + +;; Czech support originally from czech.el +;; Author: Milan Zamazal +;; Maintainer(for XEmacs): David Sauer + +(defun setup-czech-environment () + "Set up multilingual environment (MULE) for czech users." + (interactive) + (setup-8-bit-environment "Czech" 'latin-iso8859-2 'iso-8859-2 + "czech")) + + +(set-language-info-alist + "Czech" + '((setup-function . (setup-czech-environment + . setup-european-environment-map)) + (charset . (ascii latin-iso8859-2)) + (coding-system . (iso-8859-2)) + (tutorial . "TUTORIAL.cs") + (documentation . ("\ +These languages are supported with the Latin-2 (ISO-8859-2) character set: +Albanian, Czech, English, German, Hungarian, Polish, Romanian, +Serbian, Croatian, Slovak, Slovene, and Swedish. +" . describe-european-environment-map)) +)) + + ;; Latin-3 (ISO-8859-3) diff --git a/lisp/mule/mule-charset.el b/lisp/mule/mule-charset.el index 6e3c366..c31abc8 100644 --- a/lisp/mule/mule-charset.el +++ b/lisp/mule/mule-charset.el @@ -97,12 +97,12 @@ BUFFER defaults to the current buffer if omitted." ;;;; Charset accessors -(defun charset-graphic (charset) +(defun charset-iso-graphic-plane (charset) "Return the `graphic' property of CHARSET. See `make-charset'." (charset-property charset 'graphic)) -(defun charset-final (charset) +(defun charset-iso-final-char (charset) "Return the final byte of the ISO 2022 escape sequence designating CHARSET." (charset-property charset 'final)) @@ -110,7 +110,7 @@ See `make-charset'." "Return the number of characters per dimension of CHARSET." (charset-property charset 'chars)) -(defun charset-columns (charset) +(defun charset-width (charset) "Return the number of display columns per character of CHARSET. This only applies to TTY mode (under X, the actual display width can be automatically determined)." @@ -131,10 +131,14 @@ that can display the characters in CHARSET." See `make-charset'." (charset-property charset 'ccl-program)) -(defun charset-leading-byte (charset) - "Return the leading byte of CHARSET. -See `make-charset'." - (charset-property charset 'leading-byte)) +(defun charset-bytes (charset) + "Useless in XEmacs, returns 1." + 1) + +(define-obsolete-function-alias 'charset-columns 'charset-width) ;; 19990409 +(define-obsolete-function-alias 'charset-final 'charset-iso-final-char) ;; 19990409 +(define-obsolete-function-alias 'charset-graphic 'charset-iso-graphic-plane) ;; 19990409 +(define-obsolete-function-alias 'charset-doc-string 'charset-description) ;; 19990409 ;;;; Define setf methods for all settable Charset properties diff --git a/lisp/mule/mule-misc.el b/lisp/mule/mule-misc.el index 3488781..fe9948f 100644 --- a/lisp/mule/mule-misc.el +++ b/lisp/mule/mule-misc.el @@ -1,6 +1,6 @@ ;; mule-misc.el --- Miscellaneous Mule functions. -;; Copyright (C) 1995 Electrotechnical Laboratory, JAPAN. +;; Copyright (C) 1995,1999 Electrotechnical Laboratory, JAPAN. ;; Licensed to the Free Software Foundation. ;; Copyright (C) 1992,93,94,95 Free Software Foundation, Inc. ;; Copyright (C) 1995 Amdahl Corporation. @@ -175,8 +175,6 @@ It returns only 1 in XEmacs. It is for compatibility with MULE 2.3." (defalias 'char-columns 'char-width) (make-obsolete 'char-columns 'char-width) -(defalias 'charset-description 'charset-doc-string) - (defalias 'find-charset-string 'charsets-in-string) (defalias 'find-charset-region 'charsets-in-region) @@ -210,6 +208,17 @@ because its `find-charset-string' ignores ASCII charset." (cons charset dest) )))) +(defun split-char-or-char-int (char) + "Return list of charset and one or two position-codes of CHAR. +CHAR must be character or integer." + (if (characterp char) + (split-char char) + (let ((c (int-char char))) + (if c + (split-char c) + (list 'ascii c) + )))) + ;;; Commands diff --git a/lisp/mule/thai-xtis.el b/lisp/mule/thai-xtis.el new file mode 100644 index 0000000..1fe6b88 --- /dev/null +++ b/lisp/mule/thai-xtis.el @@ -0,0 +1,300 @@ +;;; thai-xtis.el --- Thai support for pre-composed font (for XTIS). + +;; Copyright (C) 1999 Electrotechnical Laboratory, JAPAN. +;; Licensed to the Free Software Foundation. + +;; Author: TAKAHASHI Naoto +;; MORIOKA Tomohiko +;; Created: 1998-03-27 for Emacs-20.3 by TAKAHASHI Naoto +;; 1999-03-29 imported and modified for XEmacs by MORIOKA Tomohiko + +;; Keywords: mule, multilingual, Thai, XTIS + +;; 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: + +;; For Thai, the pre-composed character set proposed by +;; Virach Sornlertlamvanich is supported. + +;;; Code: + +(when (featurep 'xemacs) + (make-charset 'thai-xtis "Precomposed Thai (XTIS by Virach)." + '(registry "xtis-0$" + dimension 2 + chars 94 + final ?? + graphic 0)) + + (modify-syntax-entry 'thai-xtis "w") + + (define-category ?T "Precomposed Thai character.") + (modify-category-entry 'thai-xtis ?T) + ) + + +(defvar leading-code-private-21 #x9F) + +(defconst thai-xtis-leading-code + (concat (char-to-string leading-code-private-21) + (char-to-string (charset-id 'thai-xtis)))) + +(define-ccl-program ccl-thai-xtis-consonant + `(0 + (if (r1 == 0) + ((write ,thai-xtis-leading-code) + (write r0) + (r1 = r2)) + (if (r1 == r2) + ((write r1) + (write ,thai-xtis-leading-code) + (write r0)) + ((write r1) + (write ,thai-xtis-leading-code) + (write r0) + (r1 = r2)))))) + +(define-ccl-program ccl-thai-xtis-vowel-d1 + `(0 + (if (r1 == 0) + ((write ,thai-xtis-leading-code) + (write r0 r2)) + (if (r1 == r2) + (r1 = ?\xb8) + ((write r1) + (write ,thai-xtis-leading-code) + (write r0 r2) + (r1 = 0)))))) + +(define-ccl-program ccl-thai-xtis-vowel + `(0 + (if (r1 == 0) + ((write ,thai-xtis-leading-code) + (write r0 r2)) + (if (r1 == r2) + (r1 = ((r0 - 188) << 3)) + ((write r1) + (write ,thai-xtis-leading-code) + (write r0 r2) + (r1 = 0)))))) + +(define-ccl-program ccl-thai-xtis-vowel-ee + `(0 + (if (r1 == 0) + ((write ,thai-xtis-leading-code) + (write r0 r2)) + (if (r1 == r2) + (r1 = ?\xf8) + ((write r1) + (write ,thai-xtis-leading-code) + (write r0 r2) + (r1 = 0)))))) + +(define-ccl-program ccl-thai-xtis-tone + `(0 + (if (r1 == 0) + ((write ,thai-xtis-leading-code) + (write r0 r2)) + (if (r1 == r2) + ((r0 -= 54) + (write r0) + (r1 = 0)) + ((r1 += (r0 - ?\xe6)) + (write r1) + (r1 = 0)))))) + +(define-ccl-program ccl-thai-xtis-symbol + `(0 + (if (r1 == 0) + ((write ,thai-xtis-leading-code) + (write r0 r2)) + (if (r1 == r2) + ((write r2) + (write ,thai-xtis-leading-code) + (write r0 r2) + (r1 = 0)) + ((write r1) + (write ,thai-xtis-leading-code) + (write r0 r2) + (r1 = 0)))))) + +(define-ccl-program ccl-decode-thai-xtis + `(4 + ((read r0) + (r1 = 0) + (r2 = ?\xb0) + (loop + (if (r0 < 161) + (if (r1 == 0) + (write r0) + (if (r1 == r2) + ((write r2 r0) + (r1 = 0)) + ((write r1 r0) + (r1 = 0)))) + (branch (r0 - 161) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-consonant) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-vowel-d1) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-vowel) + (call ccl-thai-xtis-vowel) + (call ccl-thai-xtis-vowel) + (call ccl-thai-xtis-vowel) + (call ccl-thai-xtis-vowel) + (call ccl-thai-xtis-vowel) + (call ccl-thai-xtis-vowel) + nil + nil + nil + nil + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-tone) + (call ccl-thai-xtis-tone) + (call ccl-thai-xtis-tone) + (call ccl-thai-xtis-tone) + (call ccl-thai-xtis-tone) + (call ccl-thai-xtis-tone) + (call ccl-thai-xtis-tone) + (call ccl-thai-xtis-vowel-ee) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + (call ccl-thai-xtis-symbol) + nil + nil + nil)) + (read r0) + (repeat))) + + (if (r1 != 0) + (write r1) + nil))) + +(define-ccl-program ccl-encode-thai-xtis + `(1 + ((read r0) + (loop + (if (r0 == ,leading-code-private-21) + ((read r1) + (if (r1 == ,(charset-id 'thai-xtis)) + ((read r0) + (write r0) + (read r0) + (r1 = (r0 & 7)) + (r0 = ((r0 - ?\xb0) >> 3)) + (if (r0 != 0) + (write r0 [0 209 212 213 214 215 216 217 218 238])) + (if (r1 != 0) + (write r1 [0 231 232 233 234 235 236 237])) + (read r0) + (repeat)) + ((write r0 r1) + (read r0) + (repeat)))) + (write-read-repeat r0)))))) + +(if (featurep 'xemacs) + (make-coding-system + 'tis-620 'ccl + "external=tis620, internal=thai-xtis" + `(mnemonic "TIS620" + decode ,ccl-decode-thai-xtis + encode ,ccl-encode-thai-xtis)) + (make-coding-system + 'tis-620 4 ?T "external=tis620, internal=thai-xtis" + '(ccl-decode-thai-xtis . ccl-encode-thai-xtis) + '((safe-charsets . t))) + ) + + +(set-language-info-alist + "Thai-XTIS" + '((setup-function . setup-thai-xtis-environment) + (exit-function . exit-thai-xtis-environment) + (charset thai-xtis) + (coding-system tis-620 iso-2022-7bit) + (coding-priority tis-620 iso-2022-7bit) + (sample-text . "$(?!:(B") + (documentation . t))) + +;; thai-xtis.el ends here. diff --git a/lisp/mule/vietnamese.el b/lisp/mule/vietnamese.el new file mode 100644 index 0000000..d71dbcf --- /dev/null +++ b/lisp/mule/vietnamese.el @@ -0,0 +1,279 @@ +;;; vietnamese.el --- Support for Vietnamese + +;; Copyright (C) 1995 Electrotechnical Laboratory, JAPAN. +;; Licensed to the Free Software Foundation. +;; Copyright (C) 1997 MORIOKA Tomohiko + +;; Keywords: multilingual, Vietnamese + +;; 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: + +;; For Vietnames, the character sets VISCII and VSCII are supported. + +;;; Code: + +(eval-and-compile + +(defvar viet-viscii-decode-table + [;; VISCII is a full 8-bit code. + 0 1 ?.2NF 3 4 ?NG ?Ng 7 8 9 10 11 12 13 14 15 + 16 17 18 19 ?.2NV 21 22 23 24 ?N[ 26 27 28 29 ?N\ 31 + 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 + 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 + 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 + 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 + 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 + 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 + ?.2NU ?N! ?N" ?N# ?N$ ?N% ?N& ?N' ?N( ?N) ?N* ?N+ ?N, ?N- ?N. ?N/ + ?.2N0 ?N1 ?N2 ?N5 ?N~ ?N> ?N6 ?N7 ?N8 ?Nv ?Nw ?No ?N| ?N{ ?Nx ?NO + ?.2Nu ?.1N! ?N" ?N# ?N$ ?N% ?N& ?N' ?N( ?N) ?N* ?N+ ?N, ?N- ?N. ?N/ + ?.1N0 ?N1 ?N2 ?.2N^ ?N= ?.1N5 ?N6 ?N7 ?N8 ?.2Nq ?NQ ?NW ?NX ?.1N= ?N> ?.2N_ + ?.2N` ?Na ?Nb ?Nc ?Nd ?Ne ?.1NF ?NG ?.2Nh ?Ni ?Nj ?Nk ?Nl ?Nm ?Nn ?.1NO + ?.2Np ?.1NQ ?.2Nr ?Ns ?Nt ?.1NU ?NV ?NW ?NX ?.2Ny ?Nz ?.1N[ ?N\ ?.2N} ?.1N^ ?N_ + ?.1N` ?Na ?Nb ?Nc ?Nd ?Ne ?Nf ?Ng ?Nh ?Ni ?Nj ?Nk ?Nl ?Nm ?Nn ?No + ?.1Np ?Nq ?Nr ?Ns ?Nt ?Nu ?Nv ?Nw ?Nx ?Ny ?Nz ?N{ ?N| ?N} ?N~ ?.2Nf ] + "Vietnamese VISCII decoding table.") + +(defvar viet-viscii-encode-table + (let ((table-lower (make-vector 128 0)) + (table-upper (make-vector 128 0)) + (i 0) + char-component) + (while (< i 256) + (setq char-component + (split-char-or-char-int (aref viet-viscii-decode-table i))) + (cond ((eq (car char-component) 'vietnamese-viscii-lower) + (aset table-lower (nth 1 char-component) i)) + ((eq (car char-component) 'vietnamese-viscii-upper) + (aset table-upper (nth 1 char-component) i))) + (setq i (1+ i))) + (cons table-lower table-upper)) + "Vietnamese VISCII encoding table. +Cons of tables for encoding lower-case chars and upper-case characters. +Both tables are indexed by the position code of Vietnamese characters.") + +(defvar viet-vscii-decode-table + [;; VSCII is a full 8-bit code. + 0 ?.2Nz ?Nx 3 ?NW ?NX ?Nf 7 8 9 10 11 12 13 14 15 + 16 ?.2NQ ?N_ ?NO ?NV ?N[ ?N} ?N\ 24 25 26 27 28 29 30 31 + 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 + 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 + 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 + 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 + 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 + 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 + ?.2N` ?Nd ?Nc ?Na ?NU ?N# ?N' ?Nh ?Nk ?N( ?Ni ?N) ?N. ?Nl ?No ?Nn + ?.2Nm ?N8 ?Nr ?Nv ?Nu ?Ns ?Nw ?N5 ?N6 ?N7 ?N^ ?N> ?N~ ?Ny ?N| ?N{ + 160 ?.2Ne ?Nb ?Nj ?Nt ?N= ?N_ ?Np ?.1Ne ?Nb ?Nj ?Nt ?N> ?Ny ?Np ?.2N" + 192 193 194 195 196 ?.1N` ?Nd ?Nc ?Na ?NU ?.2NF ?.1N" ?NF ?NG ?N! ?.2NG + ?.2N! ?N% ?N& ?Ng ?N% ?N+ ?.1N# ?N% ?N& ?Ng ?N$ ?N' ?Nh ?.2N, ?.1Nk ?N( + ?.1Ni ?N) ?N+ ?N, ?N- ?N* ?N. ?Nl ?No ?.2N- ?N* ?N0 ?.1Nn ?Nm ?N8 ?Nr + ?.2N1 ?.1Nv ?Nu ?Ns ?Nw ?N0 ?N1 ?N2 ?N/ ?N5 ?N6 ?N7 ?N^ ?N> ?N~ ?Ny + ?.2N2 ?.1N| ?N{ ?Nz ?Nx ?NW ?NX ?Nf ?NQ ?Nq ?NO ?NV ?N[ ?N} ?N\ ?.2N/] + "Vietnamese VSCII decoding table.") + +(defvar viet-vscii-encode-table + (let ((table-lower (make-vector 128 0)) + (table-upper (make-vector 128 0)) + (i 0) + char-component) + (while (< i 256) + (setq char-component + (split-char-or-char-int (aref viet-vscii-decode-table i))) + (cond ((eq (car char-component) 'vietnamese-viscii-lower) + (aset table-lower (nth 1 char-component) i)) + ((eq (car char-component) 'vietnamese-viscii-upper) + (aset table-upper (nth 1 char-component) i))) + (setq i (1+ i))) + (cons table-lower table-upper)) + "Vietnamese VSCII encoding table. +Cons of tables for encoding lower-case chars and upper-case characters. +Both tables are indexed by the position code of Vietnamese characters.") + +) + +(define-ccl-program ccl-decode-viscii + `(3 + ((read r0) + (loop + (write-read-repeat r0 ,viet-viscii-decode-table)) + )) + "CCL program to decode VISCII 1.1") + +;; Multibyte form of a Vietnamese character is as follows (3-byte): +;; LEADING-CODE-PRIVATE-11 LEADING-CODE-EXTENDED-11 POSITION-CODE +;; where LEADING-CODE-EXTENDED-11 for Vietnamese is +;; `vietnamese-viscii-lower' or `vietnamese-viscii-upper'. + +(defvar leading-code-private-11 #x9E) + +(define-ccl-program ccl-encode-viscii + `(1 + ((read r0) + (loop + (if (r0 < 128) + ;; ASCII + (write-read-repeat r0) + ;; not ASCII + (if (r0 != ,leading-code-private-11) + ;; not Vietnamese + (write-read-repeat r0) + ((read-if (r0 == ,(charset-id 'vietnamese-viscii-lower)) + (;; Vietnamese lower + (read r0) + (r0 -= 128) + (write-read-repeat r0 ,(car viet-viscii-encode-table))) + (if (r0 == ,(charset-id 'vietnamese-viscii-upper)) + (;; Vietnamese upper + (read r0) + (r0 -= 128) + (write-read-repeat r0 ,(cdr viet-viscii-encode-table))) + ;; not Vietnamese + (write-read-repeat r0))))))))) + "CCL program to encode VISCII 1.1") + +(define-ccl-program ccl-encode-viscii-font + `(0 + ;; In: R0:vietnamese-viscii-lower/vietnamese-viscii-upper + ;; R1:position code + ;; Out: R1:font code point + (if (r0 == ,(charset-id 'vietnamese-viscii-lower)) + (r1 = r1 ,(car viet-viscii-encode-table)) + (r1 = r1 ,(cdr viet-viscii-encode-table))) + ) + "CCL program to encode Vietnamese chars to VISCII 1.1 font") + +(define-ccl-program ccl-decode-vscii + `(3 + ((read r0) + (loop + (write-read-repeat r0 ,viet-vscii-decode-table)) + )) + "CCL program to decode VSCII-1.") + +(define-ccl-program ccl-encode-vscii + `(1 + ((read r0) + (loop + (if (r0 < 128) + ;; ASCII + (write-read-repeat r0) + ;; not ASCII + (if (r0 != ,leading-code-private-11) + ;; not Vietnamese + (write-read-repeat r0) + (read-if (r0 == ,(charset-id 'vietnamese-viscii-lower)) + (;; Vietnamese lower + (read r0) + (r0 -= 128) + (write-read-repeat r0 ,(car viet-vscii-encode-table))) + (if (r0 == ,(charset-id 'vietnamese-viscii-upper)) + (;; Vietnamese upper + (read r0) + (r0 -= 128) + (write-read-repeat r0 ,(cdr viet-viscii-encode-table))) + ;; not Vietnamese + (write-read-repeat r0)))))))) + "CCL program to encode VSCII-1.") + +(define-ccl-program ccl-encode-vscii-font + `(0 + ;; In: R0:vietnamese-viscii-lower/vietnamese-viscii-upper + ;; R1:position code + ;; Out: R1:font code point + (if (r0 == ,(charset-id 'vietnamese-viscii-lower)) + (r1 = r1 ,(car viet-vscii-encode-table)) + (r1 = r1 ,(cdr viet-vscii-encode-table))) + ) + "CCL program to encode Vietnamese chars to VSCII-1 font.") + + +(make-coding-system + 'viscii 'ccl + "Coding-system used for VISCII 1.1." + `(mnemonic "VISCII" + decode ,ccl-decode-viscii + encode ,ccl-encode-viscii)) + +;; (make-coding-system +;; 'vietnamese-viscii 4 ?V +;; "8-bit encoding for Vietnamese VISCII 1.1 (MIME:VISCII)" +;; (cons ccl-decode-viscii ccl-encode-viscii)) + +;; (define-coding-system-alias 'viscii 'vietnamese-viscii) + +(make-coding-system + 'vscii 'ccl + "Coding-system used for VSCII 1.1." + `(mnemonic "VSCII" + decode ,ccl-decode-vscii + encode ,ccl-encode-vscii)) + +;; (make-coding-system +;; 'vietnamese-vscii 4 ?v +;; "8-bit encoding for Vietnamese VSCII-1" +;; (cons ccl-decode-vscii ccl-encode-vscii)) + +;; (define-coding-system-alias 'vscii 'vietnamese-vscii) + +(make-coding-system + 'viqr 'no-conversion + "Coding-system used for VIQR." + '(mnemonic "VIQR" + eol-type lf + post-read-conversion viqr-post-read-conversion + pre-write-conversion viqr-pre-write-conversion)) + +;; (make-coding-system +;; 'vietnamese-viqr 0 ?q +;; "Vietnamese latin transcription (VIQR)" +;; nil) +;; (put 'vietnamese-viqr 'post-read-conversion 'viqr-post-read-conversion) +;; (put 'vietnamese-viqr 'pre-write-conversion 'viqr-pre-write-conversion) + +;; (define-coding-system-alias 'viqr 'vietnamese-viqr) + +;; For VISCII users +(set-charset-ccl-program 'vietnamese-viscii-lower + ccl-encode-viscii-font) +(set-charset-ccl-program 'vietnamese-viscii-upper + ccl-encode-viscii-font) +;; For VSCII users +(set-charset-ccl-program 'vietnamese-viscii-lower ccl-encode-vscii-font) +(set-charset-ccl-program 'vietnamese-viscii-upper ccl-encode-vscii-font) + +;; (setq font-ccl-encoder-alist +;; (cons (cons "viscii" ccl-encode-viscii-font) font-ccl-encoder-alist)) + +;; (setq font-ccl-encoder-alist +;; (cons (cons "vscii" ccl-encode-vscii-font) font-ccl-encoder-alist)) + +(set-language-info-alist + "Vietnamese" '((setup-function . setup-vietnamese-environment) + (charset . (vietnamese-viscii-lower + vietnamese-viscii-upper)) + (coding-system . (viscii vscii viqr)) + (sample-text . "Vietnamese (Ti.1N*ng ViN.t) ChN`o bNUn") + (documentation . "\ +For Vietnamese, Emacs uses special charasets internally. +They can be decoded from and encoded to VISCC, VSCII, and VIQR.") + )) + +;;; vietnamese.el ends here diff --git a/lisp/packages.el b/lisp/packages.el index 49f4fd4..eb3b4a7 100644 --- a/lisp/packages.el +++ b/lisp/packages.el @@ -173,8 +173,7 @@ in dumped-lisp.el and is not itself listed.") "dumped-lisp.el" "dumped-pkg-lisp.el" "version.el" - "very-early-lisp.el" - "Installation.el") + "very-early-lisp.el") "Lisp packages that should not be byte compiled.") @@ -203,14 +202,13 @@ is used instead of `load-path'." (member 'crypt-find-file-hook find-file-hooks))) ;; Compression involved. (if nosuffix - ":.gz:.Z" - ".elc:.elc.gz:elc.Z:.el:.el.gz:.el.Z::.gz:.Z")) + '("" ".gz" ".Z") + '(".elc" ".elc.gz" "elc.Z" ".el" ".el.gz" ".el.Z" "" ".gz" ".Z"))) (t ;; No compression. (if nosuffix "" - ".elc:.el:"))) - 4))) + '(".elc" ".el" ""))))))) (and interactive-call (if result (message "Library is file %s" result) @@ -343,9 +341,7 @@ If no DIR-LIST is supplied, it defaults to `data-directory-list'." "Locate a file in a search path DIR-LIST (a list of directories). If no DIR-LIST is supplied, it defaults to `data-directory-list'. This function is basically a wrapper over `locate-file'." - (unless dir-list - (setq dir-list data-directory-list)) - (locate-file name dir-list)) + (locate-file name (or dir-list data-directory-list))) ;; Path setup diff --git a/lisp/simple.el b/lisp/simple.el index 8a78f9d..74daf55 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -433,7 +433,7 @@ and KILLP is t if a prefix arg was specified." (and overwrite-mode (not (eolp)) (save-excursion (insert-char ?\ arg)))) -(defcustom delete-key-deletes-forward nil +(defcustom delete-key-deletes-forward t "*If non-nil, the DEL key will erase one character forwards. If nil, the DEL key will erase one character backwards." :type 'boolean diff --git a/lisp/sound.el b/lisp/sound.el index af52042..e63c0e9 100644 --- a/lisp/sound.el +++ b/lisp/sound.el @@ -105,6 +105,7 @@ :type 'directory ) +;; #### This should really be a list. --hniksic (defcustom sound-extension-list (if (or (eq system-type 'cygwin32) (eq system-type 'windows-nt)) ".wav:" ".au:") @@ -144,7 +145,8 @@ nVolume (0 for default): ") (error "volume not an integer or nil")) (let (buf data - (file (locate-file filename default-sound-directory-list sound-extension-list))) + (file (locate-file filename default-sound-directory-list + sound-extension-list))) (unless file (error "Couldn't load sound file %s" filename)) (unwind-protect diff --git a/lisp/startup.el b/lisp/startup.el index 01a3d3f..3ac3778 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -961,7 +961,7 @@ XEmacs, by either running the command `xemacs-mule', or by using the X resource ": how to get the latest version\n") "\n--\n" (face italic "\ -Copyright (C) 1985-1998 Free Software Foundation, Inc. +Copyright (C) 1985-1999 Free Software Foundation, Inc. Copyright (C) 1990-1994 Lucid, Inc. Copyright (C) 1993-1997 Sun Microsystems, Inc. All Rights Reserved. Copyright (C) 1994-1996 Board of Trustees, University of Illinois @@ -984,7 +984,7 @@ Copyright (C) 1995-1996 Ben Wing\n")) (face bold "Help") " menu)\n") ((key info) ": read the on-line documentation\n\n") ((key describe-project) ": read about the GNU project\n") - ((key about-xemacs) ": see who's developping XEmacs\n")) + ((key about-xemacs) ": see who's developing XEmacs\n")) ((face (blue bold underline) "\nUseful stuff:\n\n") "Things that you should know rather quickly...\n\n" diff --git a/lisp/subr.el b/lisp/subr.el index e1a2a29..6a49cff 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -614,6 +614,28 @@ If FUNCTION is not interactive, nil will be returned." (t (error "Non-funcallable object: %s" function)))) +;; This function used to be an alias to `buffer-substring', except +;; that FSF Emacs 20.4 added a BUFFER argument in an incompatible way. +;; The new FSF's semantics makes more sense, but we try to support +;; both for backward compatibility. +(defun buffer-string (&optional buffer old-end old-buffer) + "Return the contents of the current buffer as a string. +If narrowing is in effect, this function returns only the visible part +of the buffer. + +If BUFFER is specified, the contents of that buffer are returned. + +The arguments OLD-END and OLD-BUFFER are supported for backward +compatibility with pre-21.2 XEmacsen times when arguments to this +function were (buffer-string &optional START END BUFFER)." + (if (or (null buffer) + (bufferp buffer) + (stringp buffer)) + ;; The new way + (buffer-substring nil nil buffer) + ;; The old way + (buffer-substring buffer old-end old-buffer))) + ;; This was not present before. I think Jamie had some objections ;; to this, so I'm leaving this undefined for now. --ben @@ -667,6 +689,5 @@ FILE should be the name of a library, with no directory name." (define-function 'remove-directory 'delete-directory) (define-function 'set-match-data 'store-match-data) (define-function 'send-string-to-terminal 'external-debugging-output) -(define-function 'buffer-string 'buffer-substring) ;;; subr.el ends here diff --git a/lisp/view-less.el b/lisp/view-less.el index 23296f9..28c14be 100644 --- a/lisp/view-less.el +++ b/lisp/view-less.el @@ -312,6 +312,7 @@ as a modified buffer. This works even if the buffer is read-only." ;; #### - THIS IS PROBABLY A REALLY DANGEROUS THING TO DO IN A MINOR MODE!! (set-buffer-modified-p buf-mod))) +;;;###autoload (defun toggle-truncate-lines (&optional p) "Toggles the values of truncate-lines. Positive prefix arg sets, negative disables." diff --git a/lisp/wid-edit.el b/lisp/wid-edit.el index d0cd014..c01d457 100644 --- a/lisp/wid-edit.el +++ b/lisp/wid-edit.el @@ -674,7 +674,7 @@ automatically." :group 'widgets :type 'boolean) -(defcustom widget-image-conversion +(defcustom widget-image-file-name-suffixes '((xpm ".xpm") (gif ".gif") (png ".png") (jpeg ".jpg" ".jpeg") (xbm ".xbm")) "Conversion alist from image formats to file name suffixes." @@ -723,27 +723,27 @@ It can also be a valid image instantiator, in which case it will be (let* ((dirlist (cons (or widget-glyph-directory (locate-data-directory "custom")) data-directory-list)) - (formats widget-image-conversion) - file) - (while (and formats (not file)) - ;; This dance is necessary, because XEmacs signals an - ;; error when it encounters an unrecognized image - ;; format. - (when (valid-image-instantiator-format-p (caar formats)) - (setq file (locate-file image dirlist - (mapconcat #'identity (cdar formats) - ":")))) - (unless file - (pop formats))) + (all-suffixes + (apply #'append + (mapcar + (lambda (el) + (and (valid-image-instantiator-format-p (car el)) + (cdr el))) + widget-image-file-name-suffixes))) + (file (locate-file image dirlist all-suffixes))) (when file - ;; We create a glyph with the file as the default image - ;; instantiator, and the TAG fallback - (let ((glyph (make-glyph `([,(caar formats) :file ,file] - [string :data ,tag])))) - ;; Cache the glyph - (laxputf widget-glyph-cache image glyph) - ;; ...and return it - glyph))))) + (let* ((extension (concat "." (file-name-extension file))) + (format (car (rassoc* extension + widget-image-file-name-suffixes + :test #'member)))) + ;; We create a glyph with the file as the default image + ;; instantiator, and the TAG fallback + (let ((glyph (make-glyph `([,format :file ,file] + [string :data ,tag])))) + ;; Cache the glyph + (laxputf widget-glyph-cache image glyph) + ;; ...and return it + glyph)))))) ((valid-instantiator-p image 'image) ;; A valid image instantiator (e.g. [gif :file "somefile"] etc.) (make-glyph `(,image [string :data ,tag]))) diff --git a/lisp/x-faces.el b/lisp/x-faces.el index 123fcc0..46677cf 100644 --- a/lisp/x-faces.el +++ b/lisp/x-faces.el @@ -176,18 +176,19 @@ If it fails, it returns nil." If it fails, it returns nil." (try-font-name (x-frob-font-weight font "medium") device)) -(defcustom *try-oblique-before-italic-fonts* nil +(defcustom try-oblique-before-italic-fonts nil "*If nil, italic fonts are searched before oblique fonts. If non-nil, oblique fonts are tried before italic fonts. This is mostly applicable to adobe-courier fonts" :type 'boolean - :tag "Try Oblique Before Italic Fonts" :group 'x) +(define-obsolete-variable-alias '*try-oblique-before-italic-fonts* + 'try-oblique-before-italic-fonts) (defun x-make-font-italic (font &optional device) "Given an X font specification, this attempts to make an `italic' font. If it fails, it returns nil." - (if *try-oblique-before-italic-fonts* + (if try-oblique-before-italic-fonts (or (try-font-name (x-frob-font-slant font "o") device) (try-font-name (x-frob-font-slant font "i") device)) (or (try-font-name (x-frob-font-slant font "i") device) @@ -202,18 +203,31 @@ If it fails, it returns nil." "Given an X font specification, this attempts to make a `bold-italic' font. If it fails, it returns nil." ;; This is haired up to avoid loading the "intermediate" fonts. - (or (try-font-name - (x-frob-font-slant (x-frob-font-weight font "bold") "i") device) - (try-font-name - (x-frob-font-slant (x-frob-font-weight font "bold") "o") device) - (try-font-name - (x-frob-font-slant (x-frob-font-weight font "black") "i") device) - (try-font-name - (x-frob-font-slant (x-frob-font-weight font "black") "o") device) - (try-font-name - (x-frob-font-slant (x-frob-font-weight font "demibold") "i") device) - (try-font-name - (x-frob-font-slant (x-frob-font-weight font "demibold") "o") device))) + (if *try-oblique-before-italic-fonts* + (or (try-font-name + (x-frob-font-slant (x-frob-font-weight font "bold") "o") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "bold") "i") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "black") "o") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "black") "i") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "demibold") "o") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "demibold") "i") device)) + (or (try-font-name + (x-frob-font-slant (x-frob-font-weight font "bold") "i") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "bold") "o") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "black") "i") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "black") "o") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "demibold") "i") device) + (try-font-name + (x-frob-font-slant (x-frob-font-weight font "demibold") "o") device)))) (defun x-font-size (font) "Return the nominal size of the given font. diff --git a/lisp/x-font-menu.el b/lisp/x-font-menu.el index 9a1db5c..d96fe11 100644 --- a/lisp/x-font-menu.el +++ b/lisp/x-font-menu.el @@ -130,18 +130,45 @@ ;;; (defvar font-menu-ignore-proportional-fonts nil ;;; "*If non-nil, then the font menu will only show fixed-width fonts.") +(defgroup font-menu () + "Settings for the font menu" + :group 'x) + ;;;###autoload (defcustom font-menu-ignore-scaled-fonts t "*If non-nil, then the font menu will try to show only bitmap fonts." :type 'boolean - :group 'x) + :group 'font-menu) ;;;###autoload (defcustom font-menu-this-frame-only-p nil "*If non-nil, then changing the default font from the font menu will only affect one frame instead of all frames." :type 'boolean - :group 'x) + :group 'font-menu) + +(defcustom font-menu-max-items 25 + "*Maximum number of items in the font menu +If number of entries in a menu is larger than this value, split menu +into submenus of nearly equal length. If nil, never split menu into +submenus." + :group 'font-menu + :type '(choice (const :tag "no submenus" nil) + (integer))) + +(defcustom font-menu-submenu-name-format "%-12.12s ... %.12s" + "*Format specification of the submenu name. +Used by `font-menu-split-long-menu' if the number of entries in a menu is +larger than `font-menu-menu-max-items'. +This string should contain one %s for the name of the first entry and +one %s for the name of the last entry in the submenu. +If the value is a function, it should return the submenu name. The +function is be called with two arguments, the names of the first and +the last entry in the menu." + :group 'font-menu + :type '(choice (string :tag "Format string") + (function))) + ;; only call XListFonts (and parse) once per device. ;; ( (device . [parsed-list-fonts family-menu size-menu weight-menu]) ...) @@ -358,6 +385,40 @@ or if you change your font path, you can call this to re-initialize the menus." (vector entry family size weight slant))) +(defun font-menu-split-long-menu (menu) + "Split MENU according to `font-menu-max-items'." + (let ((len (length menu))) + (if (or (null font-menu-max-items) + (null (featurep 'lisp-float-type)) + (<= len font-menu-max-items)) + menu + ;; Submenu is max 2 entries longer than menu, never shorter, number of + ;; entries in submenus differ by at most one (with longer submenus first) + (let* ((outer (floor (sqrt len))) + (inner (/ len outer)) + (rest (% len outer)) + (result nil)) + (setq menu (reverse menu)) + (while menu + (let ((in inner) + (sub nil) + (to (car menu))) + (while (> in 0) + (setq in (1- in) + sub (cons (car menu) sub) + menu (cdr menu))) + (setq result + (cons (cons (if (stringp font-menu-submenu-name-format) + (format font-menu-submenu-name-format + (aref (car sub) 0) (aref to 0)) + (funcall font-menu-submenu-name-format + (aref (car sub) 0) (aref to 0))) + sub) + result) + rest (1+ rest)) + (if (= rest outer) (setq inner (1+ inner))))) + result)))) + ;;;###autoload (defun font-menu-family-constructor (ignored) (catch 'menu @@ -376,21 +437,28 @@ or if you change your font path, you can call this to re-initialize the menus." ;; the same size and weight as the current font (scalable fonts ;; exist in every size). Only the current font is marked as ;; selected. - (mapcar - (lambda (item) - (setq f (aref item 0) - entry (vassoc f (aref dcache 0))) - (if (and (member weight (aref entry 1)) - (or (member size (aref entry 2)) - (and (not font-menu-ignore-scaled-fonts) - (member 0 (aref entry 2))))) - (enable-menu-item item) - (disable-menu-item item)) - (if (string-equal family f) - (select-toggle-menu-item item) - (deselect-toggle-menu-item item)) - item) - (aref dcache 1))))) + (font-menu-split-long-menu + (mapcar + (lambda (item) + (setq f (aref item 0) + entry (vassoc f (aref dcache 0))) + ;; The user can no longer easily control the weight using the menu + ;; Note it is silly anyway as it could very well be that the font + ;; has no common size+weight combinations with the default font. +;; (if (and (member weight (aref entry 1)) +;; (or (member size (aref entry 2)) +;; (and (not font-menu-ignore-scaled-fonts) +;; (member 0 (aref entry 2))))) +;; (enable-menu-item item) +;; (disable-menu-item item)) + (if (and font-menu-ignore-scaled-fonts (member 0 (aref entry 2))) + (disable-menu-item item) + (enable-menu-item item)) + (if (string-equal family f) + (select-toggle-menu-item item) + (deselect-toggle-menu-item item)) + item) + (aref dcache 1)))))) ;;;###autoload (defun font-menu-size-constructor (ignored) diff --git a/lwlib/ChangeLog b/lwlib/ChangeLog index 039d6e1..3e8da0b 100644 --- a/lwlib/ChangeLog +++ b/lwlib/ChangeLog @@ -1,3 +1,7 @@ +1999-05-14 XEmacs Build Bot + + * XEmacs 21.2.14 is released + 1999-03-12 XEmacs Build Bot * XEmacs 21.2.13 is released diff --git a/lwlib/xlwmenu.c b/lwlib/xlwmenu.c index 313e46f..94ebf84 100644 --- a/lwlib/xlwmenu.c +++ b/lwlib/xlwmenu.c @@ -423,10 +423,9 @@ string_width_u (XlwMenuWidget mw, int i, j; #ifdef NEED_MOTIF + chars = ""; if (!XmStringGetLtoR (string, XmFONTLIST_DEFAULT_TAG, &chars)) - { - chars = ""; - } + chars = ""; #else chars = string; #endif @@ -872,7 +871,9 @@ string_draw_u (XlwMenuWidget mw, char *chars; #ifdef NEED_MOTIF - XmStringGetLtoR (string, XmFONTLIST_DEFAULT_TAG, &chars); + chars = ""; + if (!XmStringGetLtoR (string, XmFONTLIST_DEFAULT_TAG, &chars)) + chars = ""; #else chars = string; #endif diff --git a/man/ChangeLog b/man/ChangeLog index 638ad5d..ec0ac13 100644 --- a/man/ChangeLog +++ b/man/ChangeLog @@ -1,3 +1,39 @@ +1999-05-14 XEmacs Build Bot + + * XEmacs 21.2.14 is released + +1999-05-11 Albert Chin-A-Young + + * man/internals/internals.texi: + * man/lispref/lispref.texi: + * man/new-users-guide/new-users-guide.texi: + * man/xemacs/xemacs.texi: + * man/cl.texi: + * man/custom.texi: + * man/term.texi: + * man/termcap.texi: + * man/widget.texi: + * man/xemacs-faq.texi: + * man/external-widget.texi: + Added info dir entries so install-info will add them to + the common `dir' file. + +1999-04-28 Stephen J. Turnbull + + * man/lispref/mule.texi: Document CCL + - add sections: syntax, statements, expressions, and examples. + - fix naming and description errors. + - update links in neighboring nodes. + +1999-04-24 Gunnar Evermann + + * lispref/eval.texi (Eval): default for max-lisp-eval-depth is 500. + +1999-04-23 Gunnar Evermann + + * xemacs-faq.texi (Q3.0.7): refer to correct menu (Option->Frame + Appearance) + 1999-03-12 XEmacs Build Bot * XEmacs 21.2.13 is released diff --git a/man/cl.texi b/man/cl.texi index f7607c9..2561564 100644 --- a/man/cl.texi +++ b/man/cl.texi @@ -7,6 +7,11 @@ @end iftex @ifinfo +@dircategory XEmacs Editor +@direntry +* Common Lisp: (cl). GNU Emacs Common Lisp emulation package. +@end direntry + This file documents the GNU Emacs Common Lisp emulation package. Copyright (C) 1993 Free Software Foundation, Inc. diff --git a/man/custom.texi b/man/custom.texi index 909c5a8..7a92b74 100644 --- a/man/custom.texi +++ b/man/custom.texi @@ -9,6 +9,14 @@ @end iftex @c %**end of header +@ifinfo +@dircategory XEmacs Editor +@direntry +* Customizations: (custom). Customization Library. +package. +@end direntry +@end ifinfo + @node Top, Declaring Groups, (dir), (dir) @comment node-name, next, previous, up @top The Customization Library diff --git a/man/external-widget.texi b/man/external-widget.texi index 40ccb5c..9de5af0 100644 --- a/man/external-widget.texi +++ b/man/external-widget.texi @@ -1,6 +1,14 @@ \input texinfo @c -*-texinfo-*- @setfilename ../info/external-widget.info +@ifinfo +@dircategory XEmacs Editor +@direntry +* External Widget: (external-widget) External Client Widget. +package. +@end direntry +@end ifinfo + @node Top, Using an External Client Widget,, (dir) An @dfn{external client widget} is a widget that is part of another program diff --git a/man/internals/internals.texi b/man/internals/internals.texi index f6894c5..c5d8399 100644 --- a/man/internals/internals.texi +++ b/man/internals/internals.texi @@ -5,6 +5,10 @@ @c %**end of header @ifinfo +@dircategory XEmacs Editor +@direntry +* Internals: (internals). XEmacs Internals Manual. +@end direntry Copyright @copyright{} 1992 - 1996 Ben Wing. Copyright @copyright{} 1996, 1997 Sun Microsystems. diff --git a/man/lispref/eval.texi b/man/lispref/eval.texi index 3caa838..4714c04 100644 --- a/man/lispref/eval.texi +++ b/man/lispref/eval.texi @@ -182,7 +182,7 @@ This limit, with the associated error when it is exceeded, is one way that Lisp avoids infinite recursion on an ill-defined function. @cindex Lisp nesting error -The default value of this variable is 200. If you set it to a value +The default value of this variable is 500. If you set it to a value less than 100, Lisp will reset it to 100 if the given value is reached. @code{max-specpdl-size} provides another limit on nesting. diff --git a/man/lispref/ldap.texi b/man/lispref/ldap.texi index a2990f1..a3a3ffd 100644 --- a/man/lispref/ldap.texi +++ b/man/lispref/ldap.texi @@ -21,10 +21,11 @@ to access directory servers using the Lightweight Directory Access Protocol. @section Building XEmacs with LDAP support LDAP support must be added to XEmacs at build time since it requires -linking to an external LDAP client library. As of 21.0, XEmacs has been +linking to an external LDAP client library. As of 21.2, XEmacs has been successfully built and tested with @itemize @bullet +@item OpenLDAP 1.0.3 (@url{http://www.openldap.org/}) @item University of Michigan's LDAP 3.3 (@url{http://www.umich.edu/~dirsvcs/ldap/}) @item LDAP SDK 1.0 from Netscape Corp. (@url{http://developer.netscape.com/}) @end itemize @@ -63,7 +64,9 @@ provided, broader support is planned in future versions. @subsection LDAP Variables @defvar ldap-default-host -The default LDAP server +The default LDAP server hostname. +A TCP port number can be appended to that name using a colon as +a separator. @end defvar @defvar ldap-default-port @@ -81,7 +84,9 @@ Acme organization in the United States. @defvar ldap-host-parameters-alist An alist of per host options for LDAP transactions. The list elements look like @code{(HOST PROP1 VAL1 PROP2 VAL2 ...)} -@var{host} is the name of an LDAP server. @var{propn} and @var{valn} are +@var{host} is the name of an LDAP server. A TCP port number can be +appended to that name using a colon as a separator. +@var{propn} and @var{valn} are property/value pairs describing parameters for the server. Valid properties: @table @code diff --git a/man/lispref/lispref.texi b/man/lispref/lispref.texi index ff9f0d9..a24a43c 100644 --- a/man/lispref/lispref.texi +++ b/man/lispref/lispref.texi @@ -6,6 +6,11 @@ @c %**end of header @ifinfo +@dircategory XEmacs Editor +@direntry +* Lispref: (lispref). XEmacs Lisp Reference Manual. +@end direntry + Edition History: GNU Emacs Lisp Reference Manual Second Edition (v2.01), May 1993 diff --git a/man/lispref/mule.texi b/man/lispref/mule.texi index 4e1a8e7..89242e1 100644 --- a/man/lispref/mule.texi +++ b/man/lispref/mule.texi @@ -1093,49 +1093,356 @@ This function encodes the Big5 character @var{char} to BIG5 coding-system. The corresponding character code in Big5 is returned. @end defun -@node CCL +@node CCL, Category Tables, Coding Systems, MULE @section CCL -@defun execute-ccl-program ccl-program status -This function executes @var{ccl-program} with registers initialized by +CCL (Code Conversion Language) is a simple structured programming +language designed for character coding conversions. A CCL program is +compiled to CCL code (represented by a vector of integers) and executed +by the CCL interpreter embedded in Emacs. The CCL interpreter +implements a virtual machine with 8 registers called @code{r0}, ..., +@code{r7}, a number of control structures, and some I/O operators. Take +care when using registers @code{r0} (used in implicit @dfn{set} +statements) and especially @code{r7} (used internally by several +statements and operations, especially for multiple return values and I/O +operations). + +CCL is used for code conversion during process I/O and file I/O for +non-ISO2022 coding systems. (It is the only way for a user to specify a +code conversion function.) It is also used for calculating the code +point of an X11 font from a character code. However, since CCL is +designed as a powerful programming language, it can be used for more +generic calculation where efficiency is demanded. A combination of +three or more arithmetic operations can be calculated faster by CCL than +by Emacs Lisp. + +@strong{Warning:} The code in @file{src/mule-ccl.c} and +@file{$packages/lisp/mule-base/mule-ccl.el} is the definitive +description of CCL's semantics. The previous version of this section +contained several typos and obsolete names left from earlier versions of +MULE, and many may remain. (I am not an experienced CCL programmer; the +few who know CCL well find writing English painful.) + +A CCL program transforms an input data stream into an output data +stream. The input stream, held in a buffer of constant bytes, is left +unchanged. The buffer may be filled by an external input operation, +taken from an Emacs buffer, or taken from a Lisp string. The output +buffer is a dynamic array of bytes, which can be written by an external +output operation, inserted into an Emacs buffer, or returned as a Lisp +string. + +A CCL program is a (Lisp) list containing two or three members. The +first member is the @dfn{buffer magnification}, which indicates the +required minimum size of the output buffer as a multiple of the input +buffer. It is followed by the @dfn{main block} which executes while +there is input remaining, and an optional @dfn{EOF block} which is +executed when the input is exhausted. Both the main block and the EOF +block are CCL blocks. + +A @dfn{CCL block} is either a CCL statement or list of CCL statements. +A @dfn{CCL statement} is either a @dfn{set statement} (either an integer +or an @dfn{assignment}, which is a list of a register to receive the +assignment, an assignment operator, and an expression) or a @dfn{control +statement} (a list starting with a keyword, whose allowable syntax +depends on the keyword). + +@menu +* CCL Syntax:: CCL program syntax in BNF notation. +* CCL Statements:: Semantics of CCL statements. +* CCL Expressions:: Operators and expressions in CCL. +* Calling CCL:: Running CCL programs. +* CCL Examples:: The encoding functions for Big5 and KOI-8. +@end menu + +@node CCL Syntax, CCL Statements, CCL, CCL +@comment Node, Next, Previous, Up +@subsection CCL Syntax + +The full syntax of a CCL program in BNF notation: + +@format +CCL_PROGRAM := + (BUFFER_MAGNIFICATION + CCL_MAIN_BLOCK + [ CCL_EOF_BLOCK ]) + +BUFFER_MAGNIFICATION := integer +CCL_MAIN_BLOCK := CCL_BLOCK +CCL_EOF_BLOCK := CCL_BLOCK + +CCL_BLOCK := + STATEMENT | (STATEMENT [STATEMENT ...]) +STATEMENT := + SET | IF | BRANCH | LOOP | REPEAT | BREAK | READ | WRITE + | CALL | END + +SET := + (REG = EXPRESSION) + | (REG ASSIGNMENT_OPERATOR EXPRESSION) + | integer + +EXPRESSION := ARG | (EXPRESSION OPERATOR ARG) + +IF := (if EXPRESSION CCL_BLOCK [CCL_BLOCK]) +BRANCH := (branch EXPRESSION CCL_BLOCK [CCL_BLOCK ...]) +LOOP := (loop STATEMENT [STATEMENT ...]) +BREAK := (break) +REPEAT := + (repeat) + | (write-repeat [REG | integer | string]) + | (write-read-repeat REG [integer | ARRAY]) +READ := + (read REG ...) + | (read-if (REG OPERATOR ARG) CCL_BLOCK CCL_BLOCK) + | (read-branch REG CCL_BLOCK [CCL_BLOCK ...]) +WRITE := + (write REG ...) + | (write EXPRESSION) + | (write integer) | (write string) | (write REG ARRAY) + | string +CALL := (call ccl-program-name) +END := (end) + +REG := r0 | r1 | r2 | r3 | r4 | r5 | r6 | r7 +ARG := REG | integer +OPERATOR := + + | - | * | / | % | & | '|' | ^ | << | >> | <8 | >8 | // + | < | > | == | <= | >= | != | de-sjis | en-sjis +ASSIGNMENT_OPERATOR := + += | -= | *= | /= | %= | &= | '|=' | ^= | <<= | >>= +ARRAY := '[' integer ... ']' +@end format + +@node CCL Statements, CCL Expressions, CCL Syntax, CCL +@comment Node, Next, Previous, Up +@subsection CCL Statements + +The Emacs Code Conversion Language provides the following statement +types: @dfn{set}, @dfn{if}, @dfn{branch}, @dfn{loop}, @dfn{repeat}, +@dfn{break}, @dfn{read}, @dfn{write}, @dfn{call}, and @dfn{end}. + +@heading Set statement: + +The @dfn{set} statement has three variants with the syntaxes +@samp{(@var{reg} = @var{expression})}, +@samp{(@var{reg} @var{assignment_operator} @var{expression})}, and +@samp{@var{integer}}. The assignment operator variation of the +@dfn{set} statement works the same way as the corresponding C expression +statement does. The assignment operators are @code{+=}, @code{-=}, +@code{*=}, @code{/=}, @code{%=}, @code{&=}, @code{|=}, @code{^=}, +@code{<<=}, and @code{>>=}, and they have the same meanings as in C. A +"naked integer" @var{integer} is equivalent to a @var{set} statement of +the form @code{(r0 = @var{integer})}. + +@heading I/O statements: + +The @dfn{read} statement takes one or more registers as arguments. It +reads one byte (a C char) from the input into each register in turn. + +The @dfn{write} takes several forms. In the form @samp{(write @var{reg} +...)} it takes one or more registers as arguments and writes each in +turn to the output. The integer in a register (interpreted as an +Emchar) is encoded to multibyte form (ie, Bufbytes) and written to the +current output buffer. If it is less than 256, it is written as is. +The forms @samp{(write @var{expression})} and @samp{(write +@var{integer})} are treated analogously. The form @samp{(write +@var{string})} writes the constant string to the output. A +"naked string" @samp{@var{string}} is equivalent to the statement @samp{(write +@var{string})}. The form @samp{(write @var{reg} @var{array})} writes +the @var{reg}th element of the @var{array} to the output. + +@heading Conditional statements: + +The @dfn{if} statement takes an @var{expression}, a @var{CCL block}, and +an optional @var{second CCL block} as arguments. If the +@var{expression} evaluates to non-zero, the first @var{CCL block} is +executed. Otherwise, if there is a @var{second CCL block}, it is +executed. + +The @dfn{read-if} variant of the @dfn{if} statement takes an +@var{expression}, a @var{CCL block}, and an optional @var{second CCL +block} as arguments. The @var{expression} must have the form +@code{(@var{reg} @var{operator} @var{operand})} (where @var{operand} is +a register or an integer). The @code{read-if} statement first reads +from the input into the first register operand in the @var{expression}, +then conditionally executes a CCL block just as the @code{if} statement +does. + +The @dfn{branch} statement takes an @var{expression} and one or more CCL +blocks as arguments. The CCL blocks are treated as a zero-indexed +array, and the @code{branch} statement uses the @var{expression} as the +index of the CCL block to execute. Null CCL blocks may be used as +no-ops, continuing execution with the statement following the +@code{branch} statement in the containing CCL block. Out-of-range +values for the @var{EXPRESSION} are also treated as no-ops. + +The @dfn{read-branch} variant of the @dfn{branch} statement takes an +@var{register}, a @var{CCL block}, and an optional @var{second CCL +block} as arguments. The @code{read-branch} statement first reads from +the input into the @var{register}, then conditionally executes a CCL +block just as the @code{branch} statement does. + +@heading Loop control statements: + +The @dfn{loop} statement creates a block with an implied jump from the +end of the block back to its head. The loop is exited on a @code{break} +statement, and continued without executing the tail by a @code{repeat} +statement. + +The @dfn{break} statement, written @samp{(break)}, terminates the +current loop and continues with the next statement in the current +block. + +The @dfn{repeat} statement has three variants, @code{repeat}, +@code{write-repeat}, and @code{write-read-repeat}. Each continues the +current loop from its head, possibly after performing I/O. +@code{repeat} takes no arguments and does no I/O before jumping. +@code{write-repeat} takes a single argument (a register, an +integer, or a string), writes it to the output, then jumps. +@code{write-read-repeat} takes one or two arguments. The first must +be a register. The second may be an integer or an array; if absent, it +is implicitly set to the first (register) argument. +@code{write-read-repeat} writes its second argument to the output, then +reads from the input into the register, and finally jumps. See the +@code{write} and @code{read} statements for the semantics of the I/O +operations for each type of argument. + +@heading Other control statements: + +The @dfn{call} statement, written @samp{(call @var{ccl-program-name})}, +executes a CCL program as a subroutine. It does not return a value to +the caller, but can modify the register status. + +The @dfn{end} statement, written @samp{(end)}, terminates the CCL +program successfully, and returns to caller (which may be a CCL +program). It does not alter the status of the registers. + +@node CCL Expressions, Calling CCL, CCL Statements, CCL +@comment Node, Next, Previous, Up +@subsection CCL Expressions + +CCL, unlike Lisp, uses infix expressions. The simplest CCL expressions +consist of a single @var{operand}, either a register (one of @code{r0}, +..., @code{r0}) or an integer. Complex expressions are lists of the +form @code{( @var{expression} @var{operator} @var{operand} )}. Unlike +C, assignments are not expressions. + +In the following table, @var{X} is the target resister for a @dfn{set}. +In subexpressions, this is implicitly @code{r7}. This means that +@code{>8}, @code{//}, @code{de-sjis}, and @code{en-sjis} cannot be used +freely in subexpressions, since they return parts of their values in +@code{r7}. @var{Y} may be an expression, register, or integer, while +@var{Z} must be a register or an integer. + +@multitable @columnfractions .22 .14 .09 .55 +@item Name @tab Operator @tab Code @tab C-like Description +@item CCL_PLUS @tab @code{+} @tab 0x00 @tab X = Y + Z +@item CCL_MINUS @tab @code{-} @tab 0x01 @tab X = Y - Z +@item CCL_MUL @tab @code{*} @tab 0x02 @tab X = Y * Z +@item CCL_DIV @tab @code{/} @tab 0x03 @tab X = Y / Z +@item CCL_MOD @tab @code{%} @tab 0x04 @tab X = Y % Z +@item CCL_AND @tab @code{&} @tab 0x05 @tab X = Y & Z +@item CCL_OR @tab @code{|} @tab 0x06 @tab X = Y | Z +@item CCL_XOR @tab @code{^} @tab 0x07 @tab X = Y ^ Z +@item CCL_LSH @tab @code{<<} @tab 0x08 @tab X = Y << Z +@item CCL_RSH @tab @code{>>} @tab 0x09 @tab X = Y >> Z +@item CCL_LSH8 @tab @code{<8} @tab 0x0A @tab X = (Y << 8) | Z +@item CCL_RSH8 @tab @code{>8} @tab 0x0B @tab X = Y >> 8, r[7] = Y & 0xFF +@item CCL_DIVMOD @tab @code{//} @tab 0x0C @tab X = Y / Z, r[7] = Y % Z +@item CCL_LS @tab @code{<} @tab 0x10 @tab X = (X < Y) +@item CCL_GT @tab @code{>} @tab 0x11 @tab X = (X > Y) +@item CCL_EQ @tab @code{==} @tab 0x12 @tab X = (X == Y) +@item CCL_LE @tab @code{<=} @tab 0x13 @tab X = (X <= Y) +@item CCL_GE @tab @code{>=} @tab 0x14 @tab X = (X >= Y) +@item CCL_NE @tab @code{!=} @tab 0x15 @tab X = (X != Y) +@item CCL_ENCODE_SJIS @tab @code{en-sjis} @tab 0x16 @tab X = HIGHER_BYTE (SJIS (Y, Z)) +@item @tab @tab @tab r[7] = LOWER_BYTE (SJIS (Y, Z) +@item CCL_DECODE_SJIS @tab @code{de-sjis} @tab 0x17 @tab X = HIGHER_BYTE (DE-SJIS (Y, Z)) +@item @tab @tab @tab r[7] = LOWER_BYTE (DE-SJIS (Y, Z)) +@end multitable + +The CCL operators are as in C, with the addition of CCL_LSH8, CCL_RSH8, +CCL_DIVMOD, CCL_ENCODE_SJIS, and CCL_DECODE_SJIS. The CCL_ENCODE_SJIS +and CCL_DECODE_SJIS treat their first and second bytes as the high and +low bytes of a two-byte character code. (SJIS stands for Shift JIS, an +encoding of Japanese characters used by Microsoft. CCL_ENCODE_SJIS is a +complicated transformation of the Japanese standard JIS encoding to +Shift JIS. CCL_DECODE_SJIS is its inverse.) It is somewhat odd to +represent the SJIS operations in infix form. + +@node Calling CCL, CCL Examples, CCL Expressions, CCL +@comment Node, Next, Previous, Up +@subsection Calling CCL + +CCL programs are called automatically during Emacs buffer I/O when the +external representation has a coding system type of @code{shift-jis}, +@code{big5}, or @code{ccl}. The program is specified by the coding +system (@pxref{Coding Systems}). You can also call CCL programs from +other CCL programs, and from Lisp using these functions: + +@defun ccl-execute ccl-program status +Execute @var{ccl-program} with registers initialized by @var{status}. @var{ccl-program} is a vector of compiled CCL code -created by @code{ccl-compile}. @var{status} must be a vector of nine +created by @code{ccl-compile}. It is an error for the program to try to +execute a CCL I/O command. @var{status} must be a vector of nine values, specifying the initial value for the R0, R1 .. R7 registers and for the instruction counter IC. A @code{nil} value for a register initializer causes the register to be set to 0. A @code{nil} value for the IC initializer causes execution to start at the beginning of the program. When the program is done, @var{status} is modified (by side-effect) to contain the ending values for the corresponding -registers and IC. +registers and IC. @end defun -@defun execute-ccl-program-string ccl-program status str -This function executes @var{ccl-program} with initial @var{status} on +@defun ccl-execute-on-string ccl-program status str &optional continue +Execute @var{ccl-program} with initial @var{status} on @var{string}. @var{ccl-program} is a vector of compiled CCL code created by @code{ccl-compile}. @var{status} must be a vector of nine values, specifying the initial value for the R0, R1 .. R7 registers and for the instruction counter IC. A @code{nil} value for a register initializer causes the register to be set to 0. A @code{nil} value for the IC initializer causes execution to start at the beginning of the -program. When the program is done, @var{status} is modified (by +program. An optional fourth argument @var{continue}, if non-nil, causes +the IC to +remain on the unsatisfied read operation if the program terminates due +to exhaustion of the input buffer. Otherwise the IC is set to the end +of the program. When the program is done, @var{status} is modified (by side-effect) to contain the ending values for the corresponding registers and IC. Returns the resulting string. @end defun -@defun ccl-reset-elapsed-time -This function resets the internal value which holds the time elapsed by -CCL interpreter. +To call a CCL program from another CCL program, it must first be +registered: + +@defun register-ccl-program name ccl-program +Register @var{name} for CCL program @var{program} in +@code{ccl-program-table}. @var{program} should be the compiled form of +a CCL program, or nil. Return index number of the registered CCL +program. @end defun +Information about the processor time used by the CCL interpreter can be +obtained using these functions: + @defun ccl-elapsed-time -This function returns the time elapsed by CCL interpreter as cons of -user and system time. This measures processor time, not real time. -Both values are floating point numbers measured in seconds. If only one +Returns the elapsed processor time of the CCL interpreter as cons of +user and system time, as +floating point numbers measured in seconds. If only one overall value can be determined, the return value will be a cons of that value and 0. @end defun -@node Category Tables +@defun ccl-reset-elapsed-time +Resets the CCL interpreter's internal elapsed time registers. +@end defun + +@node CCL Examples, , Calling CCL, CCL +@comment Node, Next, Previous, Up +@subsection CCL Examples + +This section is not yet written. + +@node Category Tables, , CCL, MULE @section Category Tables A category table is a type of char table used for keeping track of diff --git a/man/new-users-guide/new-users-guide.texi b/man/new-users-guide/new-users-guide.texi index 13f88dd..4d984b7 100644 --- a/man/new-users-guide/new-users-guide.texi +++ b/man/new-users-guide/new-users-guide.texi @@ -4,6 +4,11 @@ @ifinfo +@dircategory XEmacs Editor +@direntry +* Intro: (new-users-guide). Introduction to the XEmacs Editor. +@end direntry + This manual serves as an introduction to the XEmacs editor. Copyright (C) 1985, 1986, 1988 Richard M. Stallman. diff --git a/man/term.texi b/man/term.texi index 93a6730..330d1c9 100644 --- a/man/term.texi +++ b/man/term.texi @@ -8,11 +8,10 @@ settitle Notes about emacs Term mode @end titlepage @ifinfo -@c @format -@c START-INFO-DIR-ENTRY -@c * term mode:: Emacs terminal emulator mode. -@c END-INFO-DIR-ENTRY -@c @end format +@dircategory XEmacs Editor +@direntry +* Term mode: (term). Emacs terminal emulator mode. +@end direntry @node Top, , (DIR) @top Terminal emulator mode diff --git a/man/termcap.texi b/man/termcap.texi index ec54d50..b18dd63 100644 --- a/man/termcap.texi +++ b/man/termcap.texi @@ -2,6 +2,10 @@ @setfilename ../info/termcap.info @settitle The Termcap Library @ifinfo +@direntry +* Termcap: (termcap). Termcap library of the GNU system. +@end direntry + This file documents the termcap library of the GNU system. Copyright (C) 1988 Free Software Foundation, Inc. diff --git a/man/widget.texi b/man/widget.texi index 367ebd0..66159e5 100644 --- a/man/widget.texi +++ b/man/widget.texi @@ -9,6 +9,13 @@ @end iftex @c %**end of header +@ifinfo +@dircategory XEmacs Editor +@direntry +* Widgets: (widget). The Emacs Widget Library. +@end direntry +@end ifinfo + @node Top, Introduction, (dir), (dir) @comment node-name, next, previous, up @top The Emacs Widget Library diff --git a/man/xemacs-faq.texi b/man/xemacs-faq.texi index 405dc97..76641d8 100644 --- a/man/xemacs-faq.texi +++ b/man/xemacs-faq.texi @@ -7,7 +7,7 @@ @finalout @titlepage @title XEmacs FAQ -@subtitle Frequently asked questions about XEmacs @* Last Modified: $Date: 1998/05/03 10:22:33 $ +@subtitle Frequently asked questions about XEmacs @* Last Modified: $Date: 1999/03/04 15:48:25 $ @sp 1 @author Tony Rossini @author Ben Wing @@ -18,6 +18,13 @@ @page @end titlepage +@ifinfo +@dircategory XEmacs Editor +@direntry +* FAQ: (xemacs-faq). XEmacs FAQ. +@end direntry +@end ifinfo + @node Top, Introduction, (dir), (dir) @top XEmacs FAQ @unnumbered Introduction @@ -2760,7 +2767,7 @@ For XEmacs 19.14 and previous: @email{mannj@@ll.mit.edu, John Mann} writes: @quotation -You have to go to Options->Menubar Appearance and unselect +You have to go to Options->Frame Appearance and unselect @samp{Frame-Local Font Menu}. If this option is selected, font changes are only applied to the @emph{current} frame and do @emph{not} get saved when you save options. diff --git a/man/xemacs/xemacs.texi b/man/xemacs/xemacs.texi index 82ccfb2..2dbdb54 100644 --- a/man/xemacs/xemacs.texi +++ b/man/xemacs/xemacs.texi @@ -5,6 +5,11 @@ @ifinfo +@dircategory XEmacs Editor +@direntry +* XEmacs: (xemacs). XEmacs Editor. +@end direntry + This file documents the XEmacs editor. Copyright (C) 1985, 1986, 1988 Richard M. Stallman. diff --git a/nt/ChangeLog b/nt/ChangeLog index f8c7e75..6fa286b 100644 --- a/nt/ChangeLog +++ b/nt/ChangeLog @@ -1,3 +1,36 @@ +1999-05-14 XEmacs Build Bot + + * XEmacs 21.2.14 is released + +1999-05-12 SL Baur + + * xemacs.mak: please document me + From Norbert Koch + +1999-05-03 Hrvoje Niksic + + * xemacs.mak ($(LISP)\Installation.el): Don't use + `replace-in-string'. + +1999-03-17 Adrian Aichner + + * xemacs.mak: Remove ESC macro -- no longer needed. + Remove small configuration report. Remove simplified version of + Installation and Installation.el + (Installation.el): Create it depending on "Installation" file. + Replace \r characters by use of `replace-in-string' in lisp-land. + (all): Make it depend on "Installation" file. + (Installation): Create a complete "Installation" file, looking + much like what is generated by "configure" on UNIX systems. + Insert WARNING where appropriate (currently when building without + HAVE_XPM, HAVE_PNG, and HAVE_MSW_C_DIRED). + Type "Installation" to STDOUT much like the "small configuration + report" did. + +1999-04-29 Andy Piper + + * sys/file.h: conditionalise definition of X_OK. + 1999-03-12 XEmacs Build Bot * XEmacs 21.2.13 is released diff --git a/nt/xemacs.mak b/nt/xemacs.mak index c11dc15..438223e 100644 --- a/nt/xemacs.mak +++ b/nt/xemacs.mak @@ -24,9 +24,6 @@ # Synched up with: Not in FSF. # -# Shell escape character. Used for escaping ', ` and " in commands. -ESC=^ - XEMACS=.. LISP=$(XEMACS)\lisp MODULES=$(XEMACS)\modules @@ -138,8 +135,6 @@ USE_INDEXED_LRECORD_IMPLEMENTATION=0 # !if !defined(OS) OS=Windows_95/98 -# command.com doesn't like or need '^' as an escape character -ESC= EMACS_CONFIGURATION=i586-pc-win32 !else if "$(PROCESSOR_ARCHITECTURE)" == "x86" EMACS_CONFIGURATION=i586-pc-win32 @@ -238,79 +233,6 @@ USE_INDEXED_LRECORD_IMPLEMENTATION=$(GUNG_HO) !endif # -# Small configuration report -# -!if !defined(CONF_REPORT_ALREADY_PRINTED) -!if [set CONF_REPORT_ALREADY_PRINTED=1] -!endif -!message ------------------------------------------------ -!message XEmacs $(XEMACS_VERSION_STRING) $(xemacs_codename) configured for "$(EMACS_CONFIGURATION)". -!message -!message Installation directory is "$(INSTALL_DIR)". -!message Package path is "$(PACKAGE_PATH)". -!message -!if $(INFODOCK) -!message Building InfoDock. -!endif -!if $(HAVE_MSW) -!message Compiling in support for native GUI. -!endif -!if $(HAVE_X) -!message Compiling in support for X-Windows. -!endif -!if $(HAVE_MULE) -!message Compiling in MULE. -!endif -!if $(HAVE_XPM) -!message Compiling in support for XPM images. -!endif -!if $(HAVE_GIF) -!message Compiling in support for GIF images. -!endif -!if $(HAVE_PNG) -!message Compiling in support for PNG images. -!endif -!if $(HAVE_TIFF) -!message Compiling in support for TIFF images. -!endif -!if $(HAVE_JPEG) -!message Compiling in support for JPEG images. -!endif -!if $(HAVE_XFACE) -!message Compiling in support for X-Face message headers. -!endif -!if $(HAVE_TOOLBARS) -!message Compiling in support for toolbars. -!endif -!if $(HAVE_DIALOGS) -!message Compiling in support for dialogs. -!endif -!if $(HAVE_NATIVE_SOUND) -!message Compiling in support for native sounds. -!endif -!if $(HAVE_MSW_C_DIRED) -# Define HAVE_MSW_C_DIRED to be non-zero if you want XEmacs to use C -# primitives to significantly speed up dired, at the expense of an -# additional ~4KB of code. -!message Compiling in fast dired implementation. -!endif -!if $(USE_MINIMAL_TAGBITS) -!message Using minimal tagbits. -!endif -!if $(USE_INDEXED_LRECORD_IMPLEMENTATION) -!message Using indexed lrecord implementation. -!endif -!if $(USE_UNION_TYPE) -!message Using union type for Lisp object storage. -!endif -!if $(DEBUG_XEMACS) -!message Compiling in extra debug checks. XEmacs will be slow! -!endif -!message ------------------------------------------------ -!message -!endif # !defined(CONF_REPORT_ALREADY_PRINTED) - -# # Compiler command echo control. Define VERBOSECC=1 to get vebose compilation. # !if !defined(VERBOSECC) @@ -429,43 +351,6 @@ DEFINES=$(X_DEFINES) $(MSW_DEFINES) $(MULE_DEFINES) \ -DWIN32 -D_WIN32 -DWIN32_LEAN_AND_MEAN -DWINDOWSNT -Demacs \ -DHAVE_CONFIG_H $(PROGRAM_DEFINES) $(PATH_DEFINES) -# -# Creating simplified versions of Installation and Installation.el -# -# Some values cannot be written on the same line with -# their key, since they cannot be put inside an echo command. -# Macro substitution (:"=\", :\=\\) can be performed on values in order -# to create a legal string in LISP for Installation.el. -# -!if [echo OS: $(OS)>Installation] ||\ -[echo XEmacs $(XEMACS_VERSION_STRING) $(xemacs_codename:"=\") configured for $(ESC)`$(EMACS_CONFIGURATION)$(ESC)'.>>Installation] ||\ -[echo Where should the build process find the source code?>>Installation] ||\ -[echo $(MAKEDIR:\=\\)>>Installation] -!endif -# Compiler Information -!if defined(CCV) &&\ -[echo What compiler should XEmacs be built with?>>Installation] &&\ -[echo $(CC) $(CFLAGS)>>Installation] -!endif -# Window System Information -!if [echo What window system should XEmacs use?>>Installation] -!endif -!if (defined (HAVE_X) && $(HAVE_X) == 1) -!if [echo X11>>Installation] -!endif -!endif -!if (defined (HAVE_MSW) && $(HAVE_MSW) == 1) -!if [echo MS Windows>>Installation] -!endif -!endif -# Creation of Installation.el -!if [type Installation] ||\ -[echo (setq Installation-string $(ESC)">Installation.el] ||\ -[type Installation >>Installation.el] ||\ -[echo $(ESC)")>>Installation.el] -!endif - - #------------------------------------------------------------------------------ default: $(OUTDIR)\nul all @@ -476,8 +361,7 @@ $(OUTDIR)\nul: XEMACS_INCLUDES=\ $(XEMACS)\src\config.h \ $(XEMACS)\src\Emacs.ad.h \ - $(XEMACS)\src\paths.h \ - $(XEMACS)\src\puresize-adjust.h + $(XEMACS)\src\paths.h $(XEMACS)\src\config.h: config.h copy config.h $(XEMACS)\src @@ -488,9 +372,6 @@ $(XEMACS)\src\Emacs.ad.h: Emacs.ad.h $(XEMACS)\src\paths.h: paths.h copy paths.h $(XEMACS)\src -$(XEMACS)\src\puresize-adjust.h: puresize-adjust.h - copy puresize-adjust.h $(XEMACS)\src - #------------------------------------------------------------------------------ # lib-src programs @@ -505,17 +386,18 @@ CONFIG_VALUES = $(LIB_SRC)\config.values !if [echo Creating $(CONFIG_VALUES) && echo ;;; Do not edit this file!>$(CONFIG_VALUES)] !endif # MAKEDIR has to be made into a string. -!if [echo blddir>>$(CONFIG_VALUES) && echo $(ESC)"$(MAKEDIR:\=\\)\\..$(ESC)">>$(CONFIG_VALUES)] +#!if [echo blddir>>$(CONFIG_VALUES) && echo $(ESC)"$(MAKEDIR:\=\\)\\..$(ESC)">>$(CONFIG_VALUES)] +!if [echo blddir>>$(CONFIG_VALUES) && echo "$(MAKEDIR:\=\\)\\..">>$(CONFIG_VALUES)] !endif -!if [echo CC>>$(CONFIG_VALUES) && echo $(ESC)"$(CC:\=\\)$(ESC)">>$(CONFIG_VALUES)] +!if [echo CC>>$(CONFIG_VALUES) && echo "$(CC:\=\\)">>$(CONFIG_VALUES)] !endif -!if [echo CFLAGS>>$(CONFIG_VALUES) && echo $(ESC)"$(CFLAGS:\=\\)$(ESC)">>$(CONFIG_VALUES)] +!if [echo CFLAGS>>$(CONFIG_VALUES) && echo "$(CFLAGS:\=\\)">>$(CONFIG_VALUES)] !endif -!if [echo CPP>>$(CONFIG_VALUES) && echo $(ESC)"$(CPP:\=\\)$(ESC)">>$(CONFIG_VALUES)] +!if [echo CPP>>$(CONFIG_VALUES) && echo "$(CPP:\=\\)">>$(CONFIG_VALUES)] !endif -!if [echo CPPFLAGS>>$(CONFIG_VALUES) && echo $(ESC)"$(CPPFLAGS:\=\\)$(ESC)">>$(CONFIG_VALUES)] +!if [echo CPPFLAGS>>$(CONFIG_VALUES) && echo "$(CPPFLAGS:\=\\)">>$(CONFIG_VALUES)] !endif -!if [echo LISPDIR>>$(CONFIG_VALUES) && echo $(ESC)"$(MAKEDIR:\=\\)\\$(LISP:\=\\)$(ESC)">>$(CONFIG_VALUES)] +!if [echo LISPDIR>>$(CONFIG_VALUES) && echo "$(MAKEDIR:\=\\)\\$(LISP:\=\\)">>$(CONFIG_VALUES)] !endif # PATH_PACKAGEPATH is already a quoted string. !if [echo PACKAGE_PATH>>$(CONFIG_VALUES) && echo $(PATH_PACKAGEPATH)>>$(CONFIG_VALUES)] @@ -982,7 +864,7 @@ $(OUTDIR)\TopLevelEmacsShell.obj: $(TEMACS_SRC)\EmacsShell-sub.c $(OUTDIR)\TransientEmacsShell.obj: $(TEMACS_SRC)\EmacsShell-sub.c $(CCV) $(TEMACS_CPP_FLAGS) -DDEFINE_TRANSIENT_EMACS_SHELL $** -Fo$@ -$(OUTDIR)\alloc.obj: $(TEMACS_SRC)\alloc.c $(TEMACS_SRC)\puresize-adjust.h +$(OUTDIR)\alloc.obj: $(TEMACS_SRC)\alloc.c #$(TEMACS_SRC)\Emacs.ad.h: $(XEMACS)\etc\Emacs.ad # !"sed -f ad2c.sed < $(XEMACS)\etc\Emacs.ad > $(TEMACS_SRC)\Emacs.ad.h" @@ -1022,10 +904,7 @@ $(DOC): $(LIB_SRC)\make-docfile.exe $(LIB_SRC)\make-docfile.exe -a $(DOC) -d $(TEMACS_SRC) $(DOC_SRC8) $(LIB_SRC)\make-docfile.exe -a $(DOC) -d $(TEMACS_SRC) $(DOC_SRC9) -$(LISP)\Installation.el: Installation.el - copy Installation.el $(LISP) - -update-elc: $(LISP)\Installation.el +update-elc: set EMACSBOOTSTRAPLOADPATH=$(LISP);$(PACKAGE_PATH) set EMACSBOOTSTRAPMODULEPATH=$(MODULES) $(TEMACS) -batch -l $(TEMACS_DIR)\..\lisp\update-elc.el @@ -1043,7 +922,7 @@ dump-xemacs: $(TEMACS) #------------------------------------------------------------------------------ # use this rule to build the complete system -all: $(OUTDIR)\nul $(LASTFILE) $(LWLIB) $(LIB_SRC_TOOLS) $(RUNEMACS) \ +all: Installation $(OUTDIR)\nul $(LASTFILE) $(LWLIB) $(LIB_SRC_TOOLS) $(RUNEMACS) \ $(TEMACS) update-elc $(DOC) dump-xemacs temacs: $(TEMACS) @@ -1078,7 +957,6 @@ distclean: del *.rej del *.tmp del Installation - del Installation.el cd $(OUTDIR) del *.lib del *.obj @@ -1086,7 +964,6 @@ distclean: del *.res del *.sbr cd $(XEMACS)\$(TEMACS_DIR) - del puresize-adjust.h del config.h del paths.h del Emacs.ad.h @@ -1113,5 +990,98 @@ distclean: depend: mkdepend -f xemacs.mak -p$(OUTDIR)\ -o.obj -w9999 -- $(TEMACS_CPP_FLAGS) -- $(DOC_SRC1) $(DOC_SRC2) $(DOC_SRC3) $(DOC_SRC4) $(DOC_SRC5) $(DOC_SRC6) $(DOC_SRC7) $(DOC_SRC8) $(DOC_SRC9) $(LASTFILE_SRC)\lastfile.c $(LIB_SRC)\make-docfile.c $(LIB_SRC)\run.c +Installation: + @type > Installation << +!if defined(OS) +OS: $(OS) +!endif + +XEmacs $(XEMACS_VERSION_STRING) $(xemacs_codename:"=\") configured for `$(EMACS_CONFIGURATION)'. + + Building XEmacs in \"$(MAKEDIR:\=\\)\". +!if defined(CCV) + Using compiler \"$(CC) $(CFLAGS)\". +!endif + Installing XEmacs in \"$(INSTALL_DIR:\=\\)\". + Package path is $(PATH_PACKAGEPATH:"=\"). +!if $(INFODOCK) + Building InfoDock. +!endif +!if $(HAVE_MSW) + Compiling in support for Microsoft Windows native GUI. +!endif +!if $(HAVE_X) + Compiling in support for X-Windows. +!endif +!if $(HAVE_MULE) + Compiling in MULE. +!endif +!if $(HAVE_XPM) + Compiling in support for XPM images. +!else + -------------------------------------------------------------------- + WARNING: Compiling without XPM support. + WARNING: You should strongly consider installing XPM. + WARNING: Otherwise toolbars and other graphics will look suboptimal. + WARNING: (a copy may be found in ftp://ftp.xemacs.org/pub/xemacs/aux) + -------------------------------------------------------------------- +!endif +!if $(HAVE_GIF) + Compiling in support for GIF images. +!endif +!if $(HAVE_PNG) + Compiling in support for PNG images. +!else + -------------------------------------------------------------------- + WARNING: Compiling without PNG image support. + WARNING: You should strongly consider installing the PNG libraries. + WARNING: Otherwise certain images and glyphs may not display. + WARNING: (a copy may be found in ftp://ftp.xemacs.org/pub/xemacs/aux + -------------------------------------------------------------------- +!endif +!if $(HAVE_TIFF) + Compiling in support for TIFF images. +!endif +!if $(HAVE_JPEG) + Compiling in support for JPEG images. +!endif +!if $(HAVE_XFACE) + Compiling in support for X-Face message headers. +!endif +!if $(HAVE_TOOLBARS) + Compiling in support for toolbars. +!endif +!if $(HAVE_DIALOGS) + Compiling in support for dialogs. +!endif +!if $(HAVE_NATIVE_SOUND) + Compiling in support for native sounds. +!endif +!if $(HAVE_MSW_C_DIRED) + Compiling in fast dired implementation. +!else + -------------------------------------------------------------------- + WARNING: Define HAVE_MSW_C_DIRED to be non-zero if you want XEmacs + WARNING: to use C primitives to significantly speed up dired, at the + WARNING: expense of an additional ~4KB of code. + -------------------------------------------------------------------- +!endif +!if $(USE_MINIMAL_TAGBITS) + Using minimal tagbits. +!endif +!if $(USE_INDEXED_LRECORD_IMPLEMENTATION) + Using indexed lrecord implementation. +!endif +!if $(USE_UNION_TYPE) + Using union type for Lisp object storage. +!endif +!if $(DEBUG_XEMACS) + Compiling in extra debug checks. XEmacs will be slow! +!endif +< + + * XEmacs 21.2.14 is released + +1999-05-12 Andy Piper + + * ntproc.c (sys_spawnve): kludge argv[0] in a MS compatible way. + +1999-05-11 Gunnar Evermann + + * emacs.c (Frun_emacs_from_temacs): (re)alloc natgs+2 entries for + run_temacs_argv array -- fixes random memory corruption crash + +1999-05-12 Jan Vroonhof + + * window.c (Fcurrent_window_configuration): + Save minibuffer height; + + * window.c (set_window_configuration): use it. + +1999-05-10 Robert Pluim + + * lisp.h (NNUNGCPRO): fix typo in name of DEBUG_GCPRO version + +1999-04-21 Jan Vroonhof + + * redisplay.c (redisplay_window): Do not put data + in the line start cache if it is not guaranteed to be correct + +1999-04-02 Jan Vroonhof + + * window.c (struct window_config): Removed frame + size members. + (window_config_equal): No longer compare frame sizes. + (Fset_window_configuration): Resize old top window to fit in the + current frame directly, no longer use a fake frame resize. + (Fcurrent_window_configuration): No longer save frame size + +1999-05-11 Andy Piper + + * ntproc.c (sys_spawnve): actually assign argv[0] instead of the + first character. + +1999-05-10 Hrvoje Niksic + + * sysdep.c (init_system_name): If gethostname gives a proper + domain name, don't look further for one. + +1999-05-09 Hrvoje Niksic + + * symbols.c (Fintern): Avoid frequent XSYMBOL (foo). + (Fintern_soft): Accept a symbol argument. + +1999-05-06 Hrvoje Niksic + + * symbols.c (Fintern): ...do it here. + + * lread.c (read_atom): Don't handle keywords here. + +1999-05-06 Hrvoje Niksic + + * symbols.c (reject_constant_symbols): Just use SYMBOL_IS_KEYWORD. + +1999-05-03 Olivier Galibert + + * lisp.h (SYMBOL_IS_KEYWORD): A symbol can be a keyword only if it + is interned in the main obarray. + +1999-04-23 Gunnar Evermann + + * menubar-x.c (pre_activate_callback): set accelerator field in + "No menu" entries to nil. Avoid crash in + command_builder_operate_menu_accelerator + +1999-05-03 Olivier Galibert + + * symeval.h (symbol_value_forward_lheader_initializer): Ditto. + + * lisp.h (DEFUN): Fix lrecord header initialisation. + +1999-05-02 Andy Piper + + * objects-msw.c (mswindows_font_instance_truename): add a ';'. + + * ntproc.c (sys_kill): cast using MS mandated defines. + +1999-04-29 Andy Piper + + * m/intel386.h: remove redundant definitions. + + * s/mingw32.h: new header for mingw32. + + * unexnt.c: (open_input_file): function moved to nt.c. + (close_file_data): ditto. + (rva_to_section): function moved to ntproc. + + * symsinit.h: declare syms_of_ntproc(); + + * objects-msw.c (mswindows_font_instance_truename): new function. + + * ntproc.c: remove many warnings. + (_sys_read_ahead): moved from nt.c and made static. + (rva_to_section): moved from unexnt.c but not defined under + mingw32. + (win32_executable_type): implement what we can for mingw32 + headers. + (sys_spawnve): fix bad MULE/GCPRO bug in filename handling. + + * ntheap.h: remove declarations of functions that are now static. + + * ntheap.c: support static heap. + + * nt.h: conditionalise X_OK definition. + + * nt.c: eliminate many warnings and support mingw32. + (open_input_file): function moved from unexnt.c and made static + (close_file_data): ditto. + (_sys_read_ahead): moved to ntproc.c + + * emacs.c: make sure syms_of_ntptroc gets called under windows. + + * console-msw.h: support mingw32. + * getloadavg.c: ditto. + * ntplay.c: ditto. + * sysdep.c: ditto. + * sysdir.h: ditto. + * systime.h: ditto. + * systty.h: ditto. + + * config.h.in: dont turn on DEBUG_ENCAPSULATION by default because + some systems don't have all of the encapsulated system calls. + + * callproc.c: warning elimination. + * dired-msw.c: ditto. + * process-nt.c: ditto. + * realpath.c: ditto. + + * Makefile.in.in: tweak : and ; for building under mswindows. + +1999-04-26 Michael Harnois + + * eldap.c (allocate_ldap): Adapt to the new semantics of + alloc_lcrecord_type(). + +1999-03-16 MORIOKA Tomohiko + + * file-coding.c (DECODE_HANDLE_END_OF_CONVERSION): fixed. + +1998-09-04 MORIOKA Tomohiko + + * Delete mule-coding.c and mule-coding.h because they are not + used. + +1999-04-22 Gunnar Evermann + + * objects.c (print_font_instance): Check for NILP(f->device), + i.e. Vthe_null_font_instance. + (font_instance_truename_internal): ditto. + (Ffont_instance_properties): ditto. + +1999-04-22 Olivier Galibert + + * lrecord.h (DECLARE_LRECORD): lrecord_implementation isn't an + array anymore. + +1999-04-22 Hrvoje Niksic + + * Makefile.in.in (tests): Don't mention tests explicitly -- makes + it easier to add new ones. + +1999-04-22 Hrvoje Niksic + + * symbols.c (reject_constant_symbols): Ditto. + (init_symbols_once_early): Ditto. + + * print.c (print_symbol): Don't use ->obarray. + + * symbols.c (Funintern): Ditto. + + * alloc.c (Fmake_symbol): Don't set ->obarray. + + * lisp.h (struct Lisp_Symbol): Removed .obarray field. + + * symbols.c (init_symbols_once_early): Removed + Vpure_uninterned_symbol_table. + (Fintern): Don't store to ->obarray field. + +1999-04-22 Hrvoje Niksic + + * data.c (vars_of_data): Default debug_issue_ebola_notices to 0. + (eq_with_ebola_notice): Remove abracadabra support. + +1999-04-11 Oscar Figueiredo + + * eldap.c (Fldap_search_internal): Add a new parameter `withdn' to + retrieve the distinguished names of entries + +1999-03-08 Martin Buchholz + + * lread.c (read_escape): Make hex escapes read only two hex digits. + +1999-04-05 Olivier Galibert + + * Makefile.in.in: Remove puresize-adjust.h and recursive makes. + * make-src-depend: Remove puresize-adjust.h. + * src-headers: Remove puresize-adjust.h. + * config.h.in: Kill everything purespace/gung-ho related. + + * dbxrc: Make gung-ho mandatory. + * gdbinit: Ditto. + + * lrecord.h: Make gung-ho mandatory. Remove pure flag and add + c_readonly and lisp_readonly. Remove implementation arrays. + (C_READONLY_RECORD_HEADER_P): Added. + (LISP_READONLY_RECORD_HEADER_P): Added. + (SET_C_READONLY_RECORD_HEADER): Added. + (SET_LISP_READONLY_RECORD_HEADER): Added. + + * lisp.h: Kill everything purespace/non gung-ho related. + (CHECK_C_WRITEABLE): Added. + (CHECK_LISP_WRITEABLE): Added. + (C_READONLY): Added. + (LISP_READONLY): Added. + + * lisp-union.h: Make gung-ho mandatory. + * lisp-disunion.h: Ditto. + + * alloc.c: Kill everything purespace/non gung-ho related. Fix all + set_lheader_implementation calls. + (c_readonly): Added. + (lisp_readonly): Added. + (make_string_nocopy): Added. + (Fpurecopy): Changed to do nothing. Kept the old documentation + for reference purposes for the next patches. + (sweep_lcrecords_1): Don't free C readonly lcrecords. + (sweep_bit_vectors_1): Don't free C readonly bitvectors. + (SWEEP_FIXED_TYPE_BLOCK): Don't free C readonly lrecords. + + * fns.c: Make gung-ho mandatory. + (Fput): CHECK_IMPURE -> CHECK_LISP_WRITEABLE. + (Fremprop): Ditto. + (Ffillarray): Ditto. + + * data.c: Make gung-ho mandatory. + (pure_write_error): Removed. + (c_write_error): Added. + (lisp_write_error): Added. + (Fsetcar): CHECK_IMPURE -> CHECK_LISP_WRITEABLE. + (Fsetcdr): Ditto. + (Faset): Ditto. + + * symbols.c: Make gung-ho mandatory. make_pure_pname -> + make_string or make_string_nocopy. Fix various + alloc_lcrecord_type. + + * lread.c: Remove everything purespace related. + (Flocate_file_clear_hashing): purified -> c_readonly. + (locate_file): Ditto. + (read_atom): make_pure_pname -> make_string. + + * emacs.c (Frun_emacs_from_temacs): Remove purespace stats + reporting. + (Fdump_emacs): Ditto. + + * print.c (print_internal): Make gung-ho mandatory. + * ntheap.c (sbrk): Ditto. + * mem-limits.h (EXCEEDS_LISP_PTR): Ditto + * symeval.h (symbol_value_forward_lheader_initializer): Ditto. + + * sheap.c (more_static_core): Remove puresize-adjust.h from + message. + + * syntax.c (complex_vars_of_syntax): make_pure_string -> + make_string_nocopy. + * keymap.c (make_keymap): Fix alloc_lcrecord_type. + (vars_of_keymap): make_pure_string -> make_string_nocopy. + * events.c (deinitialize_event): Fix set_lheader_implementation. + (zero_event): Ditto. + * specifier.c (make_specifier_internal): Fix alloc_lcrecord. + * menubar-x.c (set_frame_menubar): Fix alloc_lcrecord_type. + * mule-charset.c (make_charset): Ditto. + * console.c (allocate_console): Ditto. + (complex_vars_of_console): Ditto. + * file-coding.c (allocate_coding_system): Ditto. + * device.c (allocate_device): Ditto + * gui-x.c (gcpro_popup_callbacks): Ditto. + * extents.c (allocate_extent_auxiliary): Ditto. + (allocate_extent_info): Ditto. + (copy_extent): Ditto. + * glyphs.c (allocate_image_instance): Ditto. + (allocate_glyph): Ditto. + * frame.c (allocate_frame_core): Ditto. + * database.c (allocate_database): Ditto. + * tooltalk.c (make_tooltalk_message): Ditto. + (make_tooltalk_pattern): Ditto. + * rangetab.c (Fmake_range_table): Ditto. + (Fcopy_range_table): Ditto. + * process.c (make_process_internal): Ditto. + * chartab.c (Fmake_char_table): Ditto. + (make_char_table_entry): Ditto. + (copy_char_table_entry): Ditto. + (Fcopy_char_table): Ditto. + * elhash.c (make_general_lisp_hash_table): Ditto. + (Fcopy_hash_table): Ditto. + * buffer.c (allocate_buffer): Ditto. + (complex_vars_of_buffer): Ditto. + * event-stream.c (allocate_command_builder): Ditto. + * objects.c (Fmake_color_instance): Ditto. + (Fmake_font_instance): Ditto. + (vars_of_objects): Ditto. + * toolbar.c (update_toolbar_button): Ditto. + * window.c (allocate_window): Ditto. + (make_dummy_parent): Ditto. + (Fcurrent_window_configuration): Fix alloc_lcrecord. + (vars_of_window): Fix make_lcrecord_list. + * faces.c (allocate_face): Fix alloc_lcrecord_type. pure_list -> + Flist. + * lstream.c (Lstream_new): Fix make_lcrecord_list. + * opaque.c (make_opaque): Fix alloc_lrecord. + (make_opaque_list): Fix alloc_lrecord_type. + +1999-04-19 Hrvoje Niksic + + * process.c (Fstart_process_internal): Ditto. + + * ntproc.c (sys_spawnve): Use Vlisp_EXEC_SUFFIXES when calling + locate_file(). + + * glyphs-x.c (x_locate_pixmap_file): Ditto. + + * glyphs-msw.c (mswindows_locate_pixmap_file): Fix call to + locate_file(). + + * emodules.c (vars_of_module): New variable Vmodule_extensions. + (emodules_load): Use it when calling locate_file(). + + * emacs.c (main_1): Use Vlisp_EXEC_SUFFIXES when calling + locate_file(). + + * callproc.c: Vlisp_EXEC_SUFFIXES: New variable. + (vars_of_callproc): Initialize it. + (Fcall_process_internal): Use it when calling locate_file(). + + * alloc.c (disksave_object_finalization): Use + Flocate_file_clear_hashing(). + + * lread.c (Flocate_file_clear_hashing): Clear all hasing when + given `t' as argument. + +1999-04-18 Hrvoje Niksic + + * lread.c (locate_file): Expand `pathel' when appropriate. + (Flocate_file_clear_hashing): Expand path elements. + (Flocate_file_clear_hashing): Use Vlocate_file_hash_table. + + * dired.c (make_directory_hash_table): Create the hash-table only + if the directory open is successful. + + * lread.c (decode_mode_1): New function. + (decode_mode): Ditto. + (Flocate_file): Use them. + (Flocate_file): Expand FILENAME. + (locate_file_map_suffixes): New function. + (locate_file_in_directory_mapper): New function. + (locate_file_in_directory): Use locate_file_in_directory_mapper() + and locate_file_map_suffixes(). + (locate_file_construct_suffixed_files): Use + locate_file_map_suffixes(). + (locate_file_without_hash): Don't GCPRO path. + (Flocate_file_clear_hashing): Use EXTERNAL_LIST_LOOP. + (syms_of_lread): Remove Qlocate_file_hash_table. + (locate_file_find_directory_hash_table): Use + Vlocate_file_hash_table. + (locate_file_refresh_hashing): Ditto. + + * lread.c: Renamed read_objects to Vread_objects. + +1999-04-16 Olivier Galibert + + * mule-charset.c: Generally resync with fsf 20.3 charset + interface. + (make_charset): Add long and short name. Use id instead of + leading byte. + (Fmake_charset): Ditto. + (Fmake_reverse_direction_charset): Ditto. + (Fcharset_property): Ditto. + (Fcharset_short_name): Added. + (Fcharset_long_name): Added. + (Fcharset_description): Renamed from charset-doc-string. + (syms_of_mule_charset): Synced symbols. + (complex_vars_of_mule_charset): Synced charsets. + + * mule-charset.h: Removed leading byte (uses id instead), added + short and long name. + +1999-04-15 Hrvoje Niksic + + * file-coding.c (Fdefine_coding_system_alias): New function. + +1999-04-08 Olivier Galibert + + * mule-charset.c (complex_vars_of_mule_charset): Allow all iso8859 + and -ascii fonts for displaying ascii instead of iso8859-1 only. + +1998-12-14 Hrvoje Niksic + + * extents.c (set_extent_glyph_1): Make sure that the glyph we + attach to the extent is valid. + +1998-12-12 Hrvoje Niksic + + * dired.c (user_name_completion): Mule-ize. + (user_name_completion): Use xmalloc/xrealloc/xfree. + (user_name_completion): Use DO_REALLOC. + (user_name_completion): Cut down the number of static variables; + use a structure. + (user_name_completion): Username completion is always + case-sensitive. + +1998-12-06 Hrvoje Niksic + + * fns.c (base64_decode_1): Remove COUNTER. + (base64_decode_1): Accept CRLF in addition to CR. + (base64_decode_1): Disallow a stray character after final EOF; the + check was probably a remnant of buggy recode code. + +1998-12-05 Hrvoje Niksic + + * fns.c (init_provide_once): Provide `base64'. + +1998-12-04 Hrvoje Niksic + + * fns.c (XMALLOC_UNBIND): Include SPECCOUNT argument, for clarity. + (Fbase64_encode_region): If buffer is read-only, bail out early. + (Fbase64_decode_region): Ditto. + (Fbase64_encode_region): Initialize SPECCOUNT to pacify the + compiler. + (Fbase64_encode_string): Ditto. + (Fbase64_decode_region): Ditto. + (Fbase64_decode_string): Ditto. + +1998-11-25 Hrvoje Niksic + + * dired.c (Fdirectory_files): Remove redundant code. + +1999-03-05 Philip Aston + + * frame-msw.c Make raise-frame restore minimised windows. + +1999-03-05 Philip Aston + + * device-msw.c: Fix DEFVAR format - Death to phantom quote, and + add magic newline. + +1999-03-05 Philip Aston + + * toolbar-msw.c Consider captions when deciding whether to rebuild + toolbar. This fixes the initial toolbar display for those of us + who don't like captions. These patches applied by Andy Piper. + 1999-03-12 XEmacs Build Bot * XEmacs 21.2.13 is released @@ -2316,12 +2776,6 @@ * s/cygwin32.h: more cygwin b20 reorganisation. -1998-10-03 Gunnar Evermann - - * window.c (Fset_window_start): Document me. - (Fset_window_buffer): Document me. - Fixes some sort of repeatable crash. - 1998-10-01 Raymond Toy * nas.c: Added necessary support functions to be able to handle diff --git a/src/Makefile.in.in b/src/Makefile.in.in index 723d739..47d726c 100644 --- a/src/Makefile.in.in +++ b/src/Makefile.in.in @@ -97,7 +97,6 @@ vpath %.h @srcdir@ vpath config.h vpath paths.h vpath Emacs.ad.h -vpath puresize-adjust.h vpath sheap-adjust.h #else VPATH=@srcdir@ @@ -176,7 +175,7 @@ objs=\ eval.o events.o $(extra_objs)\ event-stream.o extents.o faces.o\ fileio.o $(LOCK_OBJ) filemode.o floatfns.o fns.o font-lock.o\ - frame.o general.o getloadavg.o glyphs.o glyphs-eimage.o glyphs-widget.o\ + frame.o general.o glyphs.o glyphs-eimage.o glyphs-widget.o\ gui.o $(gui_objs) hash.o imgproc.o indent.o insdel.o intl.o\ keymap.o $(RTC_patch_objs) line-number.o lread.o lstream.o\ macros.o marker.o md5.o minibuf.o objects.o opaque.o\ @@ -310,8 +309,13 @@ mo_dir = ${etcdir} mo_file = ${mo_dir}emacs.mo #endif +#ifdef WINDOWSNT +LOADPATH = EMACSBOOTSTRAPLOADPATH="${lispdir};${blddir}" +MODULEPATH = EMACSBOOTSTRAPMODULEPATH="${moduledir};${blddir}" +#else LOADPATH = EMACSBOOTSTRAPLOADPATH="${lispdir}:${blddir}" MODULEPATH = EMACSBOOTSTRAPMODULEPATH="${moduledir}:${blddir}" +#endif DUMPENV = $(LOADPATH) $(MODULEPATH) temacs_loadup = $(DUMPENV) ./temacs -batch -l ${srcdir}/../lisp/loadup.el dump_temacs = ${temacs_loadup} dump @@ -325,39 +329,26 @@ release: temacs ${libsrc}DOC $(mo_file) ${other_files} -if [ -w ${srcdir}/../lisp ]; then \ w=`pwd`; cd ${srcdir} && $${w}/temacs -nl -batch -l ${srcdir}/../lisp/inc-vers; \ else true; fi - @touch SATISFIED -$(DUMPENV) ./temacs -nl -batch -l ${srcdir}/../lisp/loadup.el dump - @if test ! -f SATISFIED; then $(RECURSIVE_MAKE) $@; fi - @$(RM) SATISFIED #else /* ! defined (HAVE_SHM) */ -if [ -w ${srcdir}/../lisp ]; then \ w=`pwd`; cd ${srcdir} && $${w}/temacs -batch -l ${srcdir}/../lisp/inc-vers; \ else true; fi - @touch SATISFIED -$(DUMPENV) ./temacs -batch -l ${srcdir}/../lisp/loadup.el dump - @if test ! -f SATISFIED; then $(RECURSIVE_MAKE) $@; fi - @$(RM) SATISFIED #endif /* ! defined (HAVE_SHM) */ touch release #endif /* ! defined (CANNOT_DUMP) */ ${PROGNAME}: temacs ${libsrc}DOC $(mo_file) ${other_files} update-elc.stamp - @$(RM) $@ && touch SATISFIED + @$(RM) $@ -${dump_temacs} - @if test -f $@; then if test -f SATISFIED; then \ - echo "Testing for Lisp shadows ..."; \ - ./${PROGNAME} -batch -vanilla -f list-load-path-shadows; fi; \ - $(RM) SATISFIED; exit 0; fi; \ - if test -f SATISFIED; then $(RM) SATISFIED; exit 1; fi; \ - $(RECURSIVE_MAKE) $@; + @echo "Testing for Lisp shadows ..." + @./${PROGNAME} -batch -vanilla -f list-load-path-shadows fastdump: temacs @$(RM) ${PROGNAME} && touch SATISFIED -${dump_temacs} - @if test -f ${PROGNAME}; then if test -f SATISFIED; then \ - ./${PROGNAME} -batch -vanilla -f list-load-path-shadows; fi; \ - $(RM) SATISFIED; exit 0; fi; \ - if test -f SATISFIED; then $(RM) SATISFIED; exit 1; fi; + @./${PROGNAME} -batch -vanilla -f list-load-path-shadows FRC.update-elc.stamp : @@ -456,13 +447,7 @@ run-temacs: temacs ## We have automated tests!! testdir = ${srcdir}/../tests/automated -tests = \ - ${testdir}/hash-table-tests.el \ - ${testdir}/lisp-tests.el \ - ${testdir}/database-tests.el \ - ${testdir}/byte-compiler-tests.el \ - ${testdir}/md5-tests.el -batch_test_emacs = -batch -l ${testdir}/test-harness.el -f batch-test-emacs ${tests} +batch_test_emacs = -batch -l ${testdir}/test-harness.el -f batch-test-emacs ${testdir} .PHONY: check check-temacs check: @@ -631,10 +616,9 @@ libextcli_Xlib.so.1: ${external_client_xlib_objs_shared} #endif /* EXTERNAL_WIDGET */ config.h: ${srcdir}/config.h.in -puresize-adjust.h: ${srcdir}/puresize.h Emacs.ad.h: ${srcdir}/${etcdir}Emacs.ad -config.h puresize-adjust.h sheap-adjust.h paths.h Emacs.ad.h : +config.h sheap-adjust.h paths.h Emacs.ad.h : @echo "The file $@ needs to be re-generated." @echo "Please run a make in the top level directory." @echo "Consult the file \`INSTALL' for instructions for building XEmacs." @@ -689,7 +673,7 @@ hpplay.o: ${srcdir}/hpplay.c .PHONY: mostlyclean clean distclean realclean versionclean extraclean mostlyclean: $(RM) temacs puremacs quantmacs prefix-args *.o *.i \ - core temacs.exe puresize-adjust.h sheap-adjust.h + core temacs.exe sheap-adjust.h clean: mostlyclean versionclean $(RM) libextcli* update-elc.stamp ## This is used in making a distribution. diff --git a/src/alloc.c b/src/alloc.c index 415eca7..7902603 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -36,6 +36,7 @@ Boston, MA 02111-1307, USA. */ Added lcrecord lists for 19.14. slb: Lots of work on the purification and dump time code. Synched Doug Lea malloc support from Emacs 20.2. + og: Killed the purespace. */ #include @@ -80,12 +81,6 @@ EXFUN (Fgarbage_collect, 0); #endif #endif -/* Define this to see where all that space is going... */ -/* But the length of the printout is obnoxious, so limit it to testers */ -#ifdef MEMORY_USAGE_STATS -#define PURESTAT -#endif - /* Define this to use malloc/free with no freelist for all datatypes, the hope being that some debugging tools may help detect freed memory references */ @@ -94,8 +89,6 @@ EXFUN (Fgarbage_collect, 0); #define ALLOC_NO_POOLS #endif -#include "puresize.h" - #ifdef DEBUG_XEMACS static int debug_allocation; static int debug_allocation_backtrace_length; @@ -180,38 +173,13 @@ extern #endif /* VIRT_ADDR_VARIES */ EMACS_INT malloc_sbrk_unused; -/* Non-zero means defun should do purecopy on the function definition */ +/* Non-zero means we're in the process of doing the dump */ int purify_flag; #ifdef HEAP_IN_DATA extern void sheap_adjust_h(); #endif -/* Force linker to put it into data space! */ -EMACS_INT pure[PURESIZE / sizeof (EMACS_INT)] = { (EMACS_INT) 0}; - -#define PUREBEG ((char *) pure) - -#if 0 /* This is breathing_space in XEmacs */ -/* Points to memory space allocated as "spare", - to be freed if we run out of memory. */ -static char *spare_memory; - -/* Amount of spare memory to keep in reserve. */ -#define SPARE_MEMORY (1 << 14) -#endif - -/* Index in pure at which next pure object will be allocated. */ -static size_t pure_bytes_used; - -#define PURIFIED(ptr) \ -((char *) (ptr) >= PUREBEG && \ - (char *) (ptr) < PUREBEG + get_PURESIZE()) - -/* Non-zero if pure_bytes_used > get_PURESIZE(); - accounts for excess purespace needs. */ -static size_t pure_lossage; - #ifdef ERROR_CHECK_TYPECHECK Error_behavior ERROR_ME, ERROR_ME_NOT, ERROR_ME_WARN; @@ -219,93 +187,16 @@ Error_behavior ERROR_ME, ERROR_ME_NOT, ERROR_ME_WARN; #endif int -purified (Lisp_Object obj) -{ - return POINTER_TYPE_P (XGCTYPE (obj)) && PURIFIED (XPNTR (obj)); -} - -size_t -purespace_usage (void) +c_readonly (Lisp_Object obj) { - return pure_bytes_used; + return POINTER_TYPE_P (XGCTYPE (obj)) && C_READONLY (obj); } -static int -check_purespace (size_t size) -{ - if (pure_lossage) - { - pure_lossage += size; - return 0; - } - else if (pure_bytes_used + size > get_PURESIZE()) - { - /* This can cause recursive bad behavior, we'll yell at the end */ - /* when we're done. */ - /* message ("\nERROR: Pure Lisp storage exhausted!\n"); */ - pure_lossage = size; - return 0; - } - else - return 1; -} - - - -#ifndef PURESTAT - -#define bump_purestat(p,b) DO_NOTHING - -#else /* PURESTAT */ - -static int purecopying_function_constants; - -static size_t pure_sizeof (Lisp_Object); - -/* Keep statistics on how much of what is in purespace */ -static struct purestat -{ - int nobjects; - int nbytes; - CONST char *name; -} - purestat_cons = {0, 0, "cons cells"}, - purestat_float = {0, 0, "float objects"}, - purestat_string_pname = {0, 0, "symbol-name strings"}, - purestat_function = {0, 0, "compiled-function objects"}, - purestat_opaque_instructions = {0, 0, "compiled-function instructions"}, - purestat_vector_constants = {0, 0, "compiled-function constants vectors"}, - purestat_string_interactive = {0, 0, "interactive strings"}, -#ifdef I18N3 - purestat_string_domain = {0, 0, "domain strings"}, -#endif - purestat_string_documentation = {0, 0, "documentation strings"}, - purestat_string_other_function = {0, 0, "other function strings"}, - purestat_vector_other = {0, 0, "other vectors"}, - purestat_string_other = {0, 0, "other strings"}, - purestat_string_all = {0, 0, "all strings"}, - purestat_vector_all = {0, 0, "all vectors"}; - -static void -bump_purestat (struct purestat *purestat, size_t nbytes) -{ - if (pure_lossage) return; - purestat->nobjects += 1; - purestat->nbytes += nbytes; -} - -static void -print_purestat (struct purestat *purestat) +int +lisp_readonly (Lisp_Object obj) { - char buf [100]; - sprintf(buf, "%s:", purestat->name); - message (" %-36s %5d %7d %2d%%", - buf, - purestat->nobjects, - purestat->nbytes, - (int) (purestat->nbytes / (pure_bytes_used / 100.0) + 0.5)); + return POINTER_TYPE_P (XGCTYPE (obj)) && LISP_READONLY (obj); } -#endif /* PURESTAT */ /* Maximum amount of C stack to save when a GC happens. */ @@ -491,17 +382,6 @@ static void * allocate_lisp_storage (size_t size) { void *p = xmalloc (size); -#ifndef USE_MINIMAL_TAGBITS - char *lim = ((char *) p) + size; - Lisp_Object val; - - XSETOBJ (val, Lisp_Type_Record, lim); - if ((char *) XPNTR (val) != lim) - { - xfree (p); - memory_full (); - } -#endif /* ! USE_MINIMAL_TAGBITS */ return p; } @@ -624,11 +504,7 @@ gc_record_type_p (Lisp_Object frob, CONST struct lrecord_implementation *type) return 0; imp = XRECORD_LHEADER_IMPLEMENTATION (frob); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION return imp == type; -#else - return imp == type || imp == type + 1; -#endif } @@ -640,16 +516,8 @@ gc_record_type_p (Lisp_Object frob, CONST struct lrecord_implementation *type) about expressions in src/gdbinit. See src/gdbinit or src/dbxrc to see how this is used. */ -#ifdef USE_MINIMAL_TAGBITS EMACS_UINT dbg_valmask = ((1UL << VALBITS) - 1) << GCBITS; EMACS_UINT dbg_typemask = (1UL << GCTYPEBITS) - 1; -unsigned char dbg_USE_MINIMAL_TAGBITS = 1; -unsigned char Lisp_Type_Int = 100; -#else -EMACS_UINT dbg_valmask = (1UL << VALBITS) - 1; -EMACS_UINT dbg_typemask = ((1UL << GCTYPEBITS) - 1) << (VALBITS + GCMARKBITS); -unsigned char dbg_USE_MINIMAL_TAGBITS = 0; -#endif #ifdef USE_UNION_TYPE unsigned char dbg_USE_UNION_TYPE = 1; @@ -657,35 +525,11 @@ unsigned char dbg_USE_UNION_TYPE = 1; unsigned char dbg_USE_UNION_TYPE = 0; #endif -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION -unsigned char dbg_USE_INDEXED_LRECORD_IMPLEMENTATION = 1; -#else -unsigned char dbg_USE_INDEXED_LRECORD_IMPLEMENTATION = 0; -#endif - -#ifdef LRECORD_CONS +unsigned char Lisp_Type_Int = 100; unsigned char Lisp_Type_Cons = 101; -#else -unsigned char lrecord_cons; -#endif - -#ifdef LRECORD_STRING unsigned char Lisp_Type_String = 102; -#else -unsigned char lrecord_string; -#endif - -#ifdef LRECORD_VECTOR unsigned char Lisp_Type_Vector = 103; -#else -unsigned char lrecord_vector; -#endif - -#ifdef LRECORD_SYMBOL unsigned char Lisp_Type_Symbol = 104; -#else -unsigned char lrecord_symbol; -#endif #ifndef MULE unsigned char lrecord_char_table_entry; @@ -1104,7 +948,6 @@ DECLARE_FIXED_TYPE_ALLOC (cons, struct Lisp_Cons); /* #define MINIMUM_ALLOWED_FIXED_TYPE_CELLS_cons 20000 */ #define MINIMUM_ALLOWED_FIXED_TYPE_CELLS_cons 2000 -#ifdef LRECORD_CONS static Lisp_Object mark_cons (Lisp_Object obj, void (*markobj) (Lisp_Object)) { @@ -1138,7 +981,6 @@ DEFINE_BASIC_LRECORD_IMPLEMENTATION ("cons", cons, */ 0, struct Lisp_Cons); -#endif /* LRECORD_CONS */ DEFUN ("cons", Fcons, 2, 2, 0, /* Create a new cons, give it CAR and CDR as components, and return it. @@ -1150,9 +992,7 @@ Create a new cons, give it CAR and CDR as components, and return it. struct Lisp_Cons *c; ALLOCATE_FIXED_TYPE (cons, struct Lisp_Cons, c); -#ifdef LRECORD_CONS - set_lheader_implementation (&(c->lheader), lrecord_cons); -#endif + set_lheader_implementation (&(c->lheader), &lrecord_cons); XSETCONS (val, c); c->car = car; c->cdr = cdr; @@ -1169,9 +1009,7 @@ noseeum_cons (Lisp_Object car, Lisp_Object cdr) struct Lisp_Cons *c; NOSEEUM_ALLOCATE_FIXED_TYPE (cons, struct Lisp_Cons, c); -#ifdef LRECORD_CONS - set_lheader_implementation (&(c->lheader), lrecord_cons); -#endif + set_lheader_implementation (&(c->lheader), &lrecord_cons); XSETCONS (val, c); XCAR (val) = car; XCDR (val) = cdr; @@ -1283,7 +1121,7 @@ make_float (double float_value) struct Lisp_Float *f; ALLOCATE_FIXED_TYPE (float, struct Lisp_Float, f); - set_lheader_implementation (&(f->lheader), lrecord_float); + set_lheader_implementation (&(f->lheader), &lrecord_float); float_data (f) = float_value; XSETFLOAT (val, f); return val; @@ -1296,7 +1134,6 @@ make_float (double float_value) /* Vector allocation */ /************************************************************************/ -#ifdef LRECORD_VECTOR static Lisp_Object mark_vector (Lisp_Object obj, void (*markobj) (Lisp_Object)) { @@ -1350,34 +1187,12 @@ make_vector_internal (size_t sizei) { /* no vector_next */ size_t sizem = STRETCHY_STRUCT_SIZEOF (Lisp_Vector, contents, sizei); - Lisp_Vector *p = (Lisp_Vector *) alloc_lcrecord (sizem, lrecord_vector); + Lisp_Vector *p = (Lisp_Vector *) alloc_lcrecord (sizem, &lrecord_vector); p->size = sizei; return p; } -#else /* ! LRECORD_VECTOR */ - -static Lisp_Object all_vectors; - -/* #### should allocate `small' vectors from a frob-block */ -static Lisp_Vector * -make_vector_internal (size_t sizei) -{ - /* + 1 to account for vector_next */ - size_t sizem = STRETCHY_STRUCT_SIZEOF (Lisp_Vector, contents, sizei+1); - Lisp_Vector *p = (Lisp_Vector *) allocate_lisp_storage (sizem); - - INCREMENT_CONS_COUNTER (sizem, "vector"); - - p->size = sizei; - vector_next (p) = all_vectors; - XSETVECTOR (all_vectors, p); - return p; -} - -#endif /* ! LRECORD_VECTOR */ - Lisp_Object make_vector (size_t length, Lisp_Object init) { @@ -1536,7 +1351,7 @@ make_bit_vector_internal (size_t sizei) size_t num_longs = BIT_VECTOR_LONG_STORAGE (sizei); size_t sizem = STRETCHY_STRUCT_SIZEOF (Lisp_Bit_Vector, bits, num_longs); Lisp_Bit_Vector *p = (Lisp_Bit_Vector *) allocate_lisp_storage (sizem); - set_lheader_implementation (&(p->lheader), lrecord_bit_vector); + set_lheader_implementation (&(p->lheader), &lrecord_bit_vector); INCREMENT_CONS_COUNTER (sizem, "bit-vector"); @@ -1634,27 +1449,14 @@ DECLARE_FIXED_TYPE_ALLOC (compiled_function, Lisp_Compiled_Function); #define MINIMUM_ALLOWED_FIXED_TYPE_CELLS_compiled_function 1000 static Lisp_Object -make_compiled_function (int make_pure) +make_compiled_function (void) { Lisp_Compiled_Function *f; Lisp_Object fun; - size_t size = sizeof (Lisp_Compiled_Function); - if (make_pure && check_purespace (size)) - { - f = (Lisp_Compiled_Function *) (PUREBEG + pure_bytes_used); - set_lheader_implementation (&(f->lheader), lrecord_compiled_function); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION - f->lheader.pure = 1; -#endif - pure_bytes_used += size; - bump_purestat (&purestat_function, size); - } - else - { - ALLOCATE_FIXED_TYPE (compiled_function, Lisp_Compiled_Function, f); - set_lheader_implementation (&(f->lheader), lrecord_compiled_function); - } + ALLOCATE_FIXED_TYPE (compiled_function, Lisp_Compiled_Function, f); + set_lheader_implementation (&(f->lheader), &lrecord_compiled_function); + f->stack_depth = 0; f->specpdl_depth = 0; f->flags.documentationp = 0; @@ -1688,7 +1490,7 @@ This is terrible behavior which is retained for compatibility with old /* In a non-insane world this function would have this arglist... (arglist instructions constants stack_depth &optional doc_string interactive) */ - Lisp_Object fun = make_compiled_function (purify_flag); + Lisp_Object fun = make_compiled_function (); Lisp_Compiled_Function *f = XCOMPILED_FUNCTION (fun); Lisp_Object arglist = args[0]; @@ -1698,22 +1500,6 @@ This is terrible behavior which is retained for compatibility with old Lisp_Object doc_string = (nargs > 4) ? args[4] : Qnil; Lisp_Object interactive = (nargs > 5) ? args[5] : Qunbound; - /* Don't purecopy the doc references in instructions because it's - wasteful; they will get fixed up later. - - #### If something goes wrong and they don't get fixed up, - we're screwed, because pure stuff isn't marked and thus the - cons references won't be marked and will get reused. - - Note: there will be a window after the byte code is created and - before the doc references are fixed up in which there will be - impure objects inside a pure object, which apparently won't - get marked, leading to trouble. But during that entire window, - the objects are sitting on Vload_force_doc_string_list, which - is staticpro'd, so we're OK. */ - Lisp_Object (*cons) (Lisp_Object, Lisp_Object) - = purify_flag ? pure_cons : Fcons; - if (nargs < 4 || nargs > 6) return Fsignal (Qwrong_number_of_arguments, list2 (intern ("make-byte-code"), make_int (nargs))); @@ -1757,7 +1543,7 @@ This is terrible behavior which is retained for compatibility with old #ifdef COMPILED_FUNCTION_ANNOTATION_HACK if (!NILP (Vcurrent_compiled_function_annotation)) - f->annotated = Fpurecopy (Vcurrent_compiled_function_annotation); + f->annotated = Fcopy (Vcurrent_compiled_function_annotation); else if (!NILP (Vload_file_name_internal_the_purecopy)) f->annotated = Vload_file_name_internal_the_purecopy; else if (!NILP (Vload_file_name_internal)) @@ -1780,61 +1566,19 @@ This is terrible behavior which is retained for compatibility with old #endif if ((f->flags.interactivep = !UNBOUNDP (interactive)) != 0) { - if (purify_flag) - { - interactive = Fpurecopy (interactive); - if (STRINGP (interactive)) - bump_purestat (&purestat_string_interactive, - pure_sizeof (interactive)); - } f->doc_and_interactive = (UNBOUNDP (f->doc_and_interactive) ? interactive : - cons (interactive, f->doc_and_interactive)); + Fcons (interactive, f->doc_and_interactive)); } if ((f->flags.documentationp = !NILP (doc_string)) != 0) { - if (purify_flag) - { - doc_string = Fpurecopy (doc_string); - if (STRINGP (doc_string)) - /* These should have been snagged by make-docfile... */ - bump_purestat (&purestat_string_documentation, - pure_sizeof (doc_string)); - } f->doc_and_interactive = (UNBOUNDP (f->doc_and_interactive) ? doc_string : - cons (doc_string, f->doc_and_interactive)); + Fcons (doc_string, f->doc_and_interactive)); } if (UNBOUNDP (f->doc_and_interactive)) f->doc_and_interactive = Qnil; - if (purify_flag) - { - - if (!purified (f->arglist)) - f->arglist = Fpurecopy (f->arglist); - - /* Statistics are kept differently for the constants */ - if (!purified (f->constants)) - { -#ifdef PURESTAT - int old = purecopying_function_constants; - purecopying_function_constants = 1; - f->constants = Fpurecopy (f->constants); - bump_purestat (&purestat_vector_constants, - pure_sizeof (f->constants)); - purecopying_function_constants = old; -#else - f->constants = Fpurecopy (f->constants); -#endif /* PURESTAT */ - } - - optimize_compiled_function (fun); - - bump_purestat (&purestat_opaque_instructions, - pure_sizeof (f->instructions)); - } - return fun; } @@ -1858,14 +1602,11 @@ Its value and function definition are void, and its property list is nil. CHECK_STRING (name); ALLOCATE_FIXED_TYPE (symbol, struct Lisp_Symbol, p); -#ifdef LRECORD_SYMBOL - set_lheader_implementation (&(p->lheader), lrecord_symbol); -#endif + set_lheader_implementation (&(p->lheader), &lrecord_symbol); p->name = XSTRING (name); p->plist = Qnil; p->value = Qunbound; p->function = Qunbound; - p->obarray = Qnil; symbol_next (p) = 0; XSETSYMBOL (val, p); return val; @@ -1885,7 +1626,7 @@ allocate_extent (void) struct extent *e; ALLOCATE_FIXED_TYPE (extent, struct extent, e); - set_lheader_implementation (&(e->lheader), lrecord_extent); + set_lheader_implementation (&(e->lheader), &lrecord_extent); extent_object (e) = Qnil; set_extent_start (e, -1); set_extent_end (e, -1); @@ -1915,7 +1656,7 @@ allocate_event (void) struct Lisp_Event *e; ALLOCATE_FIXED_TYPE (event, struct Lisp_Event, e); - set_lheader_implementation (&(e->lheader), lrecord_event); + set_lheader_implementation (&(e->lheader), &lrecord_event); XSETEVENT (val, e); return val; @@ -1938,7 +1679,7 @@ Return a new marker which does not point at any place. struct Lisp_Marker *p; ALLOCATE_FIXED_TYPE (marker, struct Lisp_Marker, p); - set_lheader_implementation (&(p->lheader), lrecord_marker); + set_lheader_implementation (&(p->lheader), &lrecord_marker); p->buffer = 0; p->memind = 0; marker_next (p) = 0; @@ -1955,7 +1696,7 @@ noseeum_make_marker (void) struct Lisp_Marker *p; NOSEEUM_ALLOCATE_FIXED_TYPE (marker, struct Lisp_Marker, p); - set_lheader_implementation (&(p->lheader), lrecord_marker); + set_lheader_implementation (&(p->lheader), &lrecord_marker); p->buffer = 0; p->memind = 0; marker_next (p) = 0; @@ -1988,7 +1729,6 @@ DECLARE_FIXED_TYPE_ALLOC (string, struct Lisp_String); /* #define MINIMUM_ALLOWED_FIXED_TYPE_CELLS_string 10000 */ #define MINIMUM_ALLOWED_FIXED_TYPE_CELLS_string 1000 -#ifdef LRECORD_STRING static Lisp_Object mark_string (Lisp_Object obj, void (*markobj) (Lisp_Object)) { @@ -2021,7 +1761,6 @@ DEFINE_BASIC_LRECORD_IMPLEMENTATION ("string", string, */ 0, string_equal, 0, struct Lisp_String); -#endif /* LRECORD_STRING */ /* String blocks contain this many useful bytes. */ #define STRING_CHARS_BLOCK_SIZE \ @@ -2135,9 +1874,7 @@ make_uninit_string (Bytecount length) /* Allocate the string header */ ALLOCATE_FIXED_TYPE (string, struct Lisp_String, s); -#ifdef LRECORD_STRING - set_lheader_implementation (&(s->lheader), lrecord_string); -#endif + set_lheader_implementation (&(s->lheader), &lrecord_string); s_chars = allocate_string_chars_struct (s, fullsize); @@ -2365,6 +2102,7 @@ Concatenate all the argument characters and make the result a string. return make_string (storage, p - storage); } + /* Take some raw memory, which MUST already be in internal format, and package it up into a Lisp string. */ Lisp_Object @@ -2415,6 +2153,29 @@ build_translated_string (CONST char *str) return build_string (GETTEXT (str)); } +Lisp_Object +make_string_nocopy (CONST Bufbyte *contents, Bytecount length) +{ + struct Lisp_String *s; + Lisp_Object val; + + /* Make sure we find out about bad make_string_nocopy's when they happen */ +#if defined (ERROR_CHECK_BUFPOS) && defined (MULE) + bytecount_to_charcount (contents, length); /* Just for the assertions */ +#endif + + /* Allocate the string header */ + ALLOCATE_FIXED_TYPE (string, struct Lisp_String, s); + set_lheader_implementation (&(s->lheader), &lrecord_string); + SET_C_READONLY_RECORD_HEADER (&s->lheader); + s->plist = Qnil; + set_string_data (s, (Bufbyte *)contents); + set_string_length (s, length); + + XSETSTRING (val, s); + return val; +} + /************************************************************************/ /* lcrecord lists */ @@ -2492,7 +2253,7 @@ make_lcrecord_list (size_t size, CONST struct lrecord_implementation *implementation) { struct lcrecord_list *p = alloc_lcrecord_type (struct lcrecord_list, - lrecord_lcrecord_list); + &lrecord_lcrecord_list); Lisp_Object val; p->implementation = implementation; @@ -2572,503 +2333,20 @@ free_managed_lcrecord (Lisp_Object lcrecord_list, Lisp_Object lcrecord) } -/************************************************************************/ -/* Purity of essence, peace on earth */ -/************************************************************************/ - -static int symbols_initialized; - -Lisp_Object -make_pure_string (CONST Bufbyte *data, Bytecount length, - Lisp_Object plist, int no_need_to_copy_data) -{ - Lisp_String *s; - size_t size = sizeof (Lisp_String) + - (no_need_to_copy_data ? 0 : (length + 1)); /* + 1 for terminating 0 */ - size = ALIGN_SIZE (size, ALIGNOF (Lisp_Object)); - - if (symbols_initialized && !pure_lossage) - { - /* Try to share some names. Saves a few kbytes. */ - Lisp_Object tem = oblookup (Vobarray, data, length); - if (SYMBOLP (tem)) - { - s = XSYMBOL (tem)->name; - if (!PURIFIED (s)) abort (); - - { - Lisp_Object string; - XSETSTRING (string, s); - return string; - } - } - } - - if (!check_purespace (size)) - return make_string (data, length); - - s = (Lisp_String *) (PUREBEG + pure_bytes_used); -#ifdef LRECORD_STRING - set_lheader_implementation (&(s->lheader), lrecord_string); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION - s->lheader.pure = 1; -#endif -#endif - set_string_length (s, length); - if (no_need_to_copy_data) - { - set_string_data (s, (Bufbyte *) data); - } - else - { - set_string_data (s, (Bufbyte *) s + sizeof (Lisp_String)); - memcpy (string_data (s), data, length); - set_string_byte (s, length, 0); - } - s->plist = Qnil; - pure_bytes_used += size; - -#ifdef PURESTAT - bump_purestat (&purestat_string_all, size); - if (purecopying_function_constants) - bump_purestat (&purestat_string_other_function, size); -#endif /* PURESTAT */ - - /* Do this after the official "completion" of the purecopying. */ - s->plist = Fpurecopy (plist); - - { - Lisp_Object string; - XSETSTRING (string, s); - return string; - } -} - - -Lisp_Object -make_pure_pname (CONST Bufbyte *data, Bytecount length, - int no_need_to_copy_data) -{ - Lisp_Object name = make_pure_string (data, length, Qnil, - no_need_to_copy_data); - bump_purestat (&purestat_string_pname, pure_sizeof (name)); - - /* We've made (at least) Qnil now, and Vobarray will soon be set up. */ - symbols_initialized = 1; - - return name; -} - - -Lisp_Object -pure_cons (Lisp_Object car, Lisp_Object cdr) -{ - Lisp_Cons *c; - - if (!check_purespace (sizeof (Lisp_Cons))) - return Fcons (Fpurecopy (car), Fpurecopy (cdr)); - - c = (Lisp_Cons *) (PUREBEG + pure_bytes_used); -#ifdef LRECORD_CONS - set_lheader_implementation (&(c->lheader), lrecord_cons); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION - c->lheader.pure = 1; -#endif -#endif - pure_bytes_used += sizeof (Lisp_Cons); - bump_purestat (&purestat_cons, sizeof (Lisp_Cons)); - - c->car = Fpurecopy (car); - c->cdr = Fpurecopy (cdr); - - { - Lisp_Object cons; - XSETCONS (cons, c); - return cons; - } -} - -Lisp_Object -pure_list (int nargs, Lisp_Object *args) -{ - Lisp_Object val = Qnil; - - for (--nargs; nargs >= 0; nargs--) - val = pure_cons (args[nargs], val); - - return val; -} - -#ifdef LISP_FLOAT_TYPE - -static Lisp_Object -make_pure_float (double num) -{ - struct Lisp_Float *f; - Lisp_Object val; - - /* Make sure that PUREBEG + pure_bytes_used is aligned on at least a sizeof - (double) boundary. Some architectures (like the sparc) require - this, and I suspect that floats are rare enough that it's no - tragedy for those that don't. */ - { -#if defined (__GNUC__) && (__GNUC__ >= 2) - /* In gcc, we can directly ask what the alignment constraints of a - structure are, but in general, that's not possible... Arrgh!! - */ - int alignment = __alignof (struct Lisp_Float); -#else /* !GNUC */ - /* Best guess is to make the `double' slot be aligned to the size - of double (which is probably 8 bytes). This assumes that it's - ok to align the beginning of the structure to the same boundary - that the `double' slot in it is supposed to be aligned to; this - should be ok because presumably there is padding in the layout - of the struct to account for this. - */ - int alignment = sizeof (float_data (f)); -#endif /* !GNUC */ - char *p = ((char *) PUREBEG + pure_bytes_used); - - p = (char *) (((EMACS_UINT) p + alignment - 1) & - alignment); - pure_bytes_used = p - (char *) PUREBEG; - } - - if (!check_purespace (sizeof (struct Lisp_Float))) - return make_float (num); - - f = (struct Lisp_Float *) (PUREBEG + pure_bytes_used); - set_lheader_implementation (&(f->lheader), lrecord_float); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION - f->lheader.pure = 1; -#endif - pure_bytes_used += sizeof (struct Lisp_Float); - bump_purestat (&purestat_float, sizeof (struct Lisp_Float)); - - float_data (f) = num; - XSETFLOAT (val, f); - return val; -} - -#endif /* LISP_FLOAT_TYPE */ - -Lisp_Object -make_pure_vector (size_t len, Lisp_Object init) -{ - Lisp_Vector *v; - size_t size = STRETCHY_STRUCT_SIZEOF (Lisp_Vector, contents, len); - - init = Fpurecopy (init); - - if (!check_purespace (size)) - return make_vector (len, init); - - v = (Lisp_Vector *) (PUREBEG + pure_bytes_used); -#ifdef LRECORD_VECTOR - set_lheader_implementation (&(v->header.lheader), lrecord_vector); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION - v->header.lheader.pure = 1; -#endif -#endif - pure_bytes_used += size; - bump_purestat (&purestat_vector_all, size); - - v->size = len; - - for (size = 0; size < len; size++) - v->contents[size] = init; - - { - Lisp_Object vector; - XSETVECTOR (vector, v); - return vector; - } -} - -#if 0 -/* Presently unused */ -void * -alloc_pure_lrecord (int size, struct lrecord_implementation *implementation) -{ - struct lrecord_header *header = (void *) (PUREBEG + pure_bytes_used); - - if (pure_bytes_used + size > get_PURESIZE()) - pure_storage_exhausted (); - - set_lheader_implementation (header, implementation); - header->next = 0; - return header; -} -#endif /* unused */ - DEFUN ("purecopy", Fpurecopy, 1, 1, 0, /* +Kept for compatibility, returns its argument. +Old: Make a copy of OBJECT in pure storage. Recursively copies contents of vectors and cons cells. Does not copy symbols. */ (obj)) { - if (!purify_flag) - { - return obj; - } - else if (!POINTER_TYPE_P (XTYPE (obj)) - || PURIFIED (XPNTR (obj)) - /* happens when bootstrapping Qnil */ - || EQ (obj, Qnull_pointer)) - { - return obj; - } - /* Order of subsequent tests determined via profiling. */ - else if (SYMBOLP (obj)) - { - /* Symbols can't be made pure (and thus read-only), because - assigning to their function, value or plist slots would - produced a SEGV in the dumped XEmacs. So we previously would - just return the symbol unchanged. - - But purified aggregate objects like lists and vectors can - contain uninterned symbols. If there are no other non-pure - references to the symbol, then the symbol is not protected - from garbage collection because the collector does not mark - the contents of purified objects. So to protect the symbols, - an impure reference has to be kept for each uninterned symbol - that is referenced by a pure object. All such symbols are - stored in the hash table pointed to by - Vpure_uninterned_symbol_table, which is itself - staticpro'd. */ - if (NILP (XSYMBOL (obj)->obarray)) - Fputhash (obj, Qnil, Vpure_uninterned_symbol_table); - return obj; - } - else if (CONSP (obj)) - { - return pure_cons (XCAR (obj), XCDR (obj)); - } - else if (STRINGP (obj)) - { - return make_pure_string (XSTRING_DATA (obj), - XSTRING_LENGTH (obj), - XSTRING (obj)->plist, - 0); - } - else if (VECTORP (obj)) - { - int i; - Lisp_Vector *o = XVECTOR (obj); - Lisp_Object pure_obj = make_pure_vector (vector_length (o), Qnil); - for (i = 0; i < vector_length (o); i++) - XVECTOR_DATA (pure_obj)[i] = Fpurecopy (o->contents[i]); - return pure_obj; - } -#ifdef LISP_FLOAT_TYPE - else if (FLOATP (obj)) - { - return make_pure_float (XFLOAT_DATA (obj)); - } -#endif - else if (COMPILED_FUNCTIONP (obj)) - { - Lisp_Object pure_obj = make_compiled_function (1); - Lisp_Compiled_Function *o = XCOMPILED_FUNCTION (obj); - Lisp_Compiled_Function *n = XCOMPILED_FUNCTION (pure_obj); - n->flags = o->flags; - n->instructions = o->instructions; - n->constants = Fpurecopy (o->constants); - n->arglist = Fpurecopy (o->arglist); - n->doc_and_interactive = Fpurecopy (o->doc_and_interactive); - n->stack_depth = o->stack_depth; - optimize_compiled_function (pure_obj); - return pure_obj; - } - else if (OPAQUEP (obj)) - { - Lisp_Object pure_obj; - Lisp_Opaque *old_opaque = XOPAQUE (obj); - Lisp_Opaque *new_opaque = (Lisp_Opaque *) (PUREBEG + pure_bytes_used); - struct lrecord_header *lheader = XRECORD_LHEADER (obj); - CONST struct lrecord_implementation *implementation - = LHEADER_IMPLEMENTATION (lheader); - size_t size = implementation->size_in_bytes_method (lheader); - size_t pure_size = ALIGN_SIZE (size, ALIGNOF (Lisp_Object)); - if (!check_purespace (pure_size)) - return obj; - pure_bytes_used += pure_size; - - memcpy (new_opaque, old_opaque, size); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION - lheader->pure = 1; -#endif - new_opaque->header.next = 0; - - XSETOPAQUE (pure_obj, new_opaque); - return pure_obj; - } - else - { - signal_simple_error ("Can't purecopy %S", obj); - } - return obj; /* Unreached */ -} - - - -static void -puresize_adjust_h (size_t puresize) -{ - FILE *stream = fopen ("puresize-adjust.h", "w"); - - if (stream == NULL) - report_file_error ("Opening puresize adjustment file", - Fcons (build_string ("puresize-adjust.h"), Qnil)); - - fprintf (stream, - "/*\tDo not edit this file!\n" - "\tAutomatically generated by XEmacs */\n" - "# define PURESIZE_ADJUSTMENT (%ld)\n", - (long) (puresize - RAW_PURESIZE)); - fclose (stream); + return obj; } -void -report_pure_usage (int report_impurities, - int die_if_pure_storage_exceeded) -{ - int rc = 0; - - if (pure_lossage) - { - message ("\n****\tPure Lisp storage exhausted!\n" - "\tPurespace usage: %ld of %ld\n" - "****", - (long) get_PURESIZE() + pure_lossage, - (long) get_PURESIZE()); - if (die_if_pure_storage_exceeded) - { - puresize_adjust_h (get_PURESIZE() + pure_lossage); -#ifdef HEAP_IN_DATA - sheap_adjust_h(); -#endif - rc = -1; - } - } - else - { - size_t lost = (get_PURESIZE() - pure_bytes_used) / 1024; - char buf[200]; - /* extern Lisp_Object Vemacs_beta_version; */ - /* This used to be NILP(Vemacs_beta_version) ? 512 : 4; */ -#ifndef PURESIZE_SLOP -#define PURESIZE_SLOP 0 -#endif - size_t slop = PURESIZE_SLOP; - - sprintf (buf, "Purespace usage: %ld of %ld (%d%%", - (long) pure_bytes_used, - (long) get_PURESIZE(), - (int) (pure_bytes_used / (get_PURESIZE() / 100.0) + 0.5)); - if (lost > ((slop ? slop : 1) / 1024)) { - sprintf (buf + strlen (buf), " -- %ldk wasted", (long)lost); - if (die_if_pure_storage_exceeded) { - puresize_adjust_h (pure_bytes_used + slop); -#ifdef HEAP_IN_DATA - sheap_adjust_h(); -#endif - rc = -1; - } - } - - strcat (buf, ")."); - message ("%s", buf); - } - -#ifdef PURESTAT - - purestat_vector_other.nbytes = - purestat_vector_all.nbytes - - purestat_vector_constants.nbytes; - purestat_vector_other.nobjects = - purestat_vector_all.nobjects - - purestat_vector_constants.nobjects; - - purestat_string_other.nbytes = - purestat_string_all.nbytes - - (purestat_string_pname.nbytes + - purestat_string_interactive.nbytes + - purestat_string_documentation.nbytes + -#ifdef I18N3 - purestat_string_domain.nbytes + -#endif - purestat_string_other_function.nbytes); - - purestat_string_other.nobjects = - purestat_string_all.nobjects - - (purestat_string_pname.nobjects + - purestat_string_interactive.nobjects + - purestat_string_documentation.nobjects + -#ifdef I18N3 - purestat_string_domain.nobjects + -#endif - purestat_string_other_function.nobjects); - - message (" %-34s Objects Bytes", ""); - - print_purestat (&purestat_cons); - print_purestat (&purestat_float); - print_purestat (&purestat_string_pname); - print_purestat (&purestat_function); - print_purestat (&purestat_opaque_instructions); - print_purestat (&purestat_vector_constants); - print_purestat (&purestat_string_interactive); -#ifdef I18N3 - print_purestat (&purestat_string_domain); -#endif - print_purestat (&purestat_string_documentation); - print_purestat (&purestat_string_other_function); - print_purestat (&purestat_vector_other); - print_purestat (&purestat_string_other); - print_purestat (&purestat_string_all); - print_purestat (&purestat_vector_all); - -#endif /* PURESTAT */ - - - if (report_impurities) - { - Lisp_Object plist; - struct gcpro gcpro1; - plist = XCAR (XCDR (XCDR (XCDR (XCDR (XCDR (Fgarbage_collect())))))); - GCPRO1 (plist); - message ("\nImpurities:"); - for (; CONSP (plist); plist = XCDR (XCDR (plist))) - { - Lisp_Object symbol = XCAR (plist); - int size = XINT (XCAR (XCDR (plist))); - if (size > 0) - { - char buf [100]; - char *s = buf; - memcpy (buf, - string_data (XSYMBOL (symbol)->name), - string_length (XSYMBOL (symbol)->name) + 1); - while (*s++) if (*s == '-') *s = ' '; - *(s-1) = ':'; *s = 0; - message (" %-34s %6d", buf, size); - } - } - UNGCPRO; - garbage_collect_1 (); /* collect Fgarbage_collect()'s garbage */ - } - clear_message (); - - if (rc < 0) { - unlink("SATISFIED"); - fatal ("Pure size adjusted, Don't Panic! I will restart the `make'"); - } else if (pure_lossage && die_if_pure_storage_exceeded) { - fatal ("Pure storage exhausted"); - } -} /************************************************************************/ @@ -3125,148 +2403,31 @@ mark_object (Lisp_Object obj) /* if (!POINTER_TYPE_P (XGCTYPE (obj))) return; */ /* if (PURIFIED (XPNTR (obj))) return; */ - switch (XGCTYPE (obj)) + if (XGCTYPE (obj) == Lisp_Type_Record) { -#ifndef LRECORD_CONS - case Lisp_Type_Cons: - { - struct Lisp_Cons *ptr = XCONS (obj); - if (PURIFIED (ptr)) - break; - if (CONS_MARKED_P (ptr)) - break; - MARK_CONS (ptr); - /* If the cdr is nil, tail-recurse on the car. */ - if (GC_NILP (ptr->cdr)) - { - obj = ptr->car; - } - else - { - mark_object (ptr->car); - obj = ptr->cdr; - } - goto tail_recurse; - } -#endif - - case Lisp_Type_Record: - { - struct lrecord_header *lheader = XRECORD_LHEADER (obj); -#if defined (ERROR_CHECK_GC) && defined (USE_INDEXED_LRECORD_IMPLEMENTATION) - assert (lheader->type <= last_lrecord_type_index_assigned); + struct lrecord_header *lheader = XRECORD_LHEADER (obj); +#if defined (ERROR_CHECK_GC) + assert (lheader->type <= last_lrecord_type_index_assigned); #endif - if (PURIFIED (lheader)) - return; + if (C_READONLY_RECORD_HEADER_P (lheader)) + return; - if (! MARKED_RECORD_HEADER_P (lheader) && - ! UNMARKABLE_RECORD_HEADER_P (lheader)) - { - CONST struct lrecord_implementation *implementation = - LHEADER_IMPLEMENTATION (lheader); - MARK_RECORD_HEADER (lheader); + if (! MARKED_RECORD_HEADER_P (lheader) && + ! UNMARKABLE_RECORD_HEADER_P (lheader)) + { + CONST struct lrecord_implementation *implementation = + LHEADER_IMPLEMENTATION (lheader); + MARK_RECORD_HEADER (lheader); #ifdef ERROR_CHECK_GC - if (!implementation->basic_p) - assert (! ((struct lcrecord_header *) lheader)->free); + if (!implementation->basic_p) + assert (! ((struct lcrecord_header *) lheader)->free); #endif - if (implementation->marker) - { - obj = implementation->marker (obj, mark_object); - if (!GC_NILP (obj)) goto tail_recurse; - } - } - } - break; - -#ifndef LRECORD_STRING - case Lisp_Type_String: - { - struct Lisp_String *ptr = XSTRING (obj); - if (PURIFIED (ptr)) - return; - - if (!XMARKBIT (ptr->plist)) - { - if (CONSP (ptr->plist) && - EXTENT_INFOP (XCAR (ptr->plist))) - flush_cached_extent_info (XCAR (ptr->plist)); - XMARK (ptr->plist); - obj = ptr->plist; - goto tail_recurse; - } - } - break; -#endif /* ! LRECORD_STRING */ - -#ifndef LRECORD_VECTOR - case Lisp_Type_Vector: - { - struct Lisp_Vector *ptr = XVECTOR (obj); - int len, i; - - if (PURIFIED (ptr)) - return; - - len = vector_length (ptr); - - if (len < 0) - break; /* Already marked */ - ptr->size = -1 - len; /* Else mark it */ - for (i = 0; i < len - 1; i++) /* and then mark its elements */ - mark_object (ptr->contents[i]); - if (len > 0) - { - obj = ptr->contents[len - 1]; - goto tail_recurse; - } - } - break; -#endif /* !LRECORD_VECTOR */ - -#ifndef LRECORD_SYMBOL - case Lisp_Type_Symbol: - { - struct Lisp_Symbol *sym = XSYMBOL (obj); - - if (PURIFIED (sym)) - return; - - while (!XMARKBIT (sym->plist)) - { - XMARK (sym->plist); - mark_object (sym->value); - mark_object (sym->function); + if (implementation->marker) { - /* - * symbol->name is a struct Lisp_String *, not a - * Lisp_Object. Fix it up and pass to mark_object. - */ - Lisp_Object symname; - XSETSTRING (symname, sym->name); - mark_object (symname); + obj = implementation->marker (obj, mark_object); + if (!GC_NILP (obj)) goto tail_recurse; } - if (!symbol_next (sym)) - { - obj = sym->plist; - goto tail_recurse; - } - mark_object (sym->plist); - /* Mark the rest of the symbols in the hash-chain */ - sym = symbol_next (sym); - } - } - break; -#endif /* !LRECORD_SYMBOL */ - - /* Check for invalid Lisp_Object types */ -#if defined (ERROR_CHECK_GC) && ! defined (USE_MINIMAL_TAGBITS) - case Lisp_Type_Int: - case Lisp_Type_Char: - break; - default: - abort(); - break; -#endif /* ERROR_CHECK_GC && ! USE_MINIMAL_TAGBITS */ + } } } @@ -3292,75 +2453,8 @@ mark_conses_in_list (Lisp_Object obj) } -#ifdef PURESTAT -/* Simpler than mark-object, because pure structure can't - have any circularities */ - -static size_t -pure_string_sizeof (Lisp_Object obj) -{ - struct Lisp_String *ptr = XSTRING (obj); - - if (string_data (ptr) != (Bufbyte *) ptr + sizeof (*ptr)) - { - /* string-data not allocated contiguously. - Probably (better be!!) a pointer constant "C" data. */ - return sizeof (*ptr); - } - else - { - size_t size = sizeof (*ptr) + string_length (ptr) + 1; - size = ALIGN_SIZE (size, sizeof (Lisp_Object)); - return size; - } -} - -static size_t -pure_sizeof (Lisp_Object obj) -{ - if (!POINTER_TYPE_P (XTYPE (obj)) - || !PURIFIED (XPNTR (obj))) - return 0; - /* symbol sizes are accounted for separately */ - else if (SYMBOLP (obj)) - return 0; - else if (STRINGP (obj)) - return pure_string_sizeof (obj); - else if (LRECORDP (obj)) - { - struct lrecord_header *lheader = XRECORD_LHEADER (obj); - CONST struct lrecord_implementation *implementation - = LHEADER_IMPLEMENTATION (lheader); - - return implementation->size_in_bytes_method - ? implementation->size_in_bytes_method (lheader) - : implementation->static_size; - } -#ifndef LRECORD_VECTOR - else if (VECTORP (obj)) - return STRETCHY_STRUCT_SIZEOF (Lisp_Vector, contents, XVECTOR_LENGTH (obj)); -#endif /* !LRECORD_VECTOR */ - -#ifndef LRECORD_CONS - else if (CONSP (obj)) - return sizeof (struct Lisp_Cons); -#endif /* !LRECORD_CONS */ - else - /* Others can't be purified */ - abort (); - return 0; /* unreached */ -} -#endif /* PURESTAT */ - - - - /* Find all structures not marked, and free them. */ -#ifndef LRECORD_VECTOR -static int gc_count_num_vector_used, gc_count_vector_total_size; -static int gc_count_vector_storage; -#endif static int gc_count_num_bit_vector_used, gc_count_bit_vector_total_size; static int gc_count_bit_vector_storage; static int gc_count_num_short_string_in_use; @@ -3454,7 +2548,9 @@ sweep_lcrecords_1 (struct lcrecord_header **prev, int *used) for (header = *prev; header; header = header->next) { struct lrecord_header *h = &(header->lheader); - if (!MARKED_RECORD_HEADER_P (h) && ! (header->free)) + if (!C_READONLY_RECORD_HEADER_P(h) + && !MARKED_RECORD_HEADER_P (h) + && ! (header->free)) { if (LHEADER_IMPLEMENTATION (h)->finalizer) LHEADER_IMPLEMENTATION (h)->finalizer (h, 0); @@ -3464,11 +2560,13 @@ sweep_lcrecords_1 (struct lcrecord_header **prev, int *used) for (header = *prev; header; ) { struct lrecord_header *h = &(header->lheader); - if (MARKED_RECORD_HEADER_P (h)) + if (C_READONLY_RECORD_HEADER_P(h) || MARKED_RECORD_HEADER_P (h)) { - UNMARK_RECORD_HEADER (h); + if (MARKED_RECORD_HEADER_P (h)) + UNMARK_RECORD_HEADER (h); num_used++; /* total_size += n->implementation->size_in_bytes (h);*/ + /* ### May modify header->next on a C_READONLY lcrecord */ prev = &(header->next); header = *prev; tick_lcrecord_stats (h, 0); @@ -3487,47 +2585,6 @@ sweep_lcrecords_1 (struct lcrecord_header **prev, int *used) /* *total = total_size; */ } -#ifndef LRECORD_VECTOR - -static void -sweep_vectors_1 (Lisp_Object *prev, - int *used, int *total, int *storage) -{ - Lisp_Object vector; - int num_used = 0; - int total_size = 0; - int total_storage = 0; - - for (vector = *prev; VECTORP (vector); ) - { - Lisp_Vector *v = XVECTOR (vector); - int len = v->size; - if (len < 0) /* marked */ - { - len = - (len + 1); - v->size = len; - total_size += len; - total_storage += - MALLOC_OVERHEAD + - STRETCHY_STRUCT_SIZEOF (Lisp_Vector, contents, len + 1); - num_used++; - prev = &(vector_next (v)); - vector = *prev; - } - else - { - Lisp_Object next = vector_next (v); - *prev = next; - xfree (v); - vector = next; - } - } - *used = num_used; - *total = total_size; - *storage = total_storage; -} - -#endif /* ! LRECORD_VECTOR */ static void sweep_bit_vectors_1 (Lisp_Object *prev, @@ -3544,15 +2601,17 @@ sweep_bit_vectors_1 (Lisp_Object *prev, { Lisp_Bit_Vector *v = XBIT_VECTOR (bit_vector); int len = v->size; - if (MARKED_RECORD_P (bit_vector)) + if (C_READONLY_RECORD_HEADER_P(&(v->lheader)) || MARKED_RECORD_P (bit_vector)) { - UNMARK_RECORD_HEADER (&(v->lheader)); + if (MARKED_RECORD_P (bit_vector)) + UNMARK_RECORD_HEADER (&(v->lheader)); total_size += len; total_storage += MALLOC_OVERHEAD + STRETCHY_STRUCT_SIZEOF (Lisp_Bit_Vector, bits, BIT_VECTOR_LONG_STORAGE (len)); num_used++; + /* ### May modify next on a C_READONLY bitvector */ prev = &(bit_vector_next (v)); bit_vector = *prev; } @@ -3597,7 +2656,11 @@ do { \ { \ num_free++; \ } \ - else if (!MARKED_##typename##_P (SFTB_victim)) \ + else if (C_READONLY_RECORD_HEADER_P (&SFTB_victim->lheader)) \ + { \ + num_used++; \ + } \ + else if (!MARKED_RECORD_HEADER_P (&SFTB_victim->lheader)) \ { \ num_free++; \ FREE_FIXED_TYPE (typename, obj_type, SFTB_victim); \ @@ -3647,7 +2710,12 @@ do { \ num_free++; \ PUT_FIXED_TYPE_ON_FREE_LIST (typename, obj_type, SFTB_victim); \ } \ - else if (!MARKED_##typename##_P (SFTB_victim)) \ + else if (C_READONLY_RECORD_HEADER_P (&SFTB_victim->lheader)) \ + { \ + SFTB_empty = 0; \ + num_used++; \ + } \ + else if (!MARKED_RECORD_HEADER_P (&SFTB_victim->lheader)) \ { \ num_free++; \ FREE_FIXED_TYPE (typename, obj_type, SFTB_victim); \ @@ -3700,13 +2768,7 @@ do { \ static void sweep_conses (void) { -#ifndef LRECORD_CONS -# define MARKED_cons_P(ptr) XMARKBIT ((ptr)->car) -# define UNMARK_cons(ptr) do { XUNMARK ((ptr)->car); } while (0) -#else /* LRECORD_CONS */ -# define MARKED_cons_P(ptr) MARKED_RECORD_HEADER_P (&((ptr)->lheader)) -# define UNMARK_cons(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) -#endif /* LRECORD_CONS */ +#define UNMARK_cons(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) #define ADDITIONAL_FREE_cons(ptr) SWEEP_FIXED_TYPE_BLOCK (cons, struct Lisp_Cons); @@ -3770,8 +2832,6 @@ free_alist (Lisp_Object alist) static void sweep_compiled_functions (void) { -#define MARKED_compiled_function_P(ptr) \ - MARKED_RECORD_HEADER_P (&((ptr)->lheader)) #define UNMARK_compiled_function(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) #define ADDITIONAL_FREE_compiled_function(ptr) @@ -3783,7 +2843,6 @@ sweep_compiled_functions (void) static void sweep_floats (void) { -#define MARKED_float_P(ptr) MARKED_RECORD_HEADER_P (&((ptr)->lheader)) #define UNMARK_float(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) #define ADDITIONAL_FREE_float(ptr) @@ -3794,13 +2853,7 @@ sweep_floats (void) static void sweep_symbols (void) { -#ifndef LRECORD_SYMBOL -# define MARKED_symbol_P(ptr) XMARKBIT ((ptr)->plist) -# define UNMARK_symbol(ptr) do { XUNMARK ((ptr)->plist); } while (0) -#else -# define MARKED_symbol_P(ptr) MARKED_RECORD_HEADER_P (&((ptr)->lheader)) -# define UNMARK_symbol(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) -#endif /* !LRECORD_SYMBOL */ +#define UNMARK_symbol(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) #define ADDITIONAL_FREE_symbol(ptr) SWEEP_FIXED_TYPE_BLOCK (symbol, struct Lisp_Symbol); @@ -3809,7 +2862,6 @@ sweep_symbols (void) static void sweep_extents (void) { -#define MARKED_extent_P(ptr) MARKED_RECORD_HEADER_P (&((ptr)->lheader)) #define UNMARK_extent(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) #define ADDITIONAL_FREE_extent(ptr) @@ -3819,7 +2871,6 @@ sweep_extents (void) static void sweep_events (void) { -#define MARKED_event_P(ptr) MARKED_RECORD_HEADER_P (&((ptr)->lheader)) #define UNMARK_event(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) #define ADDITIONAL_FREE_event(ptr) @@ -3829,7 +2880,6 @@ sweep_events (void) static void sweep_markers (void) { -#define MARKED_marker_P(ptr) MARKED_RECORD_HEADER_P (&((ptr)->lheader)) #define UNMARK_marker(ptr) UNMARK_RECORD_HEADER (&((ptr)->lheader)) #define ADDITIONAL_FREE_marker(ptr) \ do { Lisp_Object tem; \ @@ -3954,11 +3004,7 @@ compact_string_chars (void) abort (); /* Just skip it if it isn't marked. */ -#ifdef LRECORD_STRING if (! MARKED_RECORD_HEADER_P (&(string->lheader))) -#else - if (!XMARKBIT (string->plist)) -#endif { from_pos += fullsize; continue; @@ -4039,10 +3085,7 @@ sweep_strings (void) int num_small_used = 0, num_small_bytes = 0, num_bytes = 0; int debug = debug_string_purity; -#ifdef LRECORD_STRING - -# define MARKED_string_P(ptr) MARKED_RECORD_HEADER_P (&((ptr)->lheader)) -# define UNMARK_string(ptr) \ +#define UNMARK_string(ptr) \ do { struct Lisp_String *p = (ptr); \ int size = string_length (p); \ UNMARK_RECORD_HEADER (&(p->lheader)); \ @@ -4053,34 +3096,12 @@ sweep_strings (void) } \ if (debug) debug_string_purity_print (p); \ } while (0) -# define ADDITIONAL_FREE_string(p) \ +#define ADDITIONAL_FREE_string(p) \ do { int size = string_length (p); \ if (BIG_STRING_SIZE_P (size)) \ xfree_1 (CHARS_TO_STRING_CHAR (string_data (p))); \ } while (0) -#else - -# define MARKED_string_P(ptr) XMARKBIT ((ptr)->plist) -# define UNMARK_string(ptr) \ - do { struct Lisp_String *p = (ptr); \ - int size = string_length (p); \ - XUNMARK (p->plist); \ - num_bytes += size; \ - if (!BIG_STRING_SIZE_P (size)) \ - { num_small_bytes += size; \ - num_small_used++; \ - } \ - if (debug) debug_string_purity_print (p); \ - } while (0) -# define ADDITIONAL_FREE_string(p) \ - do { int size = string_length (p); \ - if (BIG_STRING_SIZE_P (size)) \ - xfree_1 (CHARS_TO_STRING_CHAR (string_data (p))); \ - } while (0) - -#endif /* ! LRECORD_STRING */ - SWEEP_FIXED_TYPE_BLOCK (string, struct Lisp_String); gc_count_num_short_string_in_use = num_small_used; @@ -4101,57 +3122,15 @@ marked_p (Lisp_Object obj) /* if (!POINTER_TYPE_P (XGCTYPE (obj))) return 1; */ /* if (PURIFIED (XPNTR (obj))) return 1; */ - switch (XGCTYPE (obj)) + if (XGCTYPE (obj) == Lisp_Type_Record) { -#ifndef LRECORD_CONS - case Lisp_Type_Cons: - { - struct Lisp_Cons *ptr = XCONS (obj); - return PURIFIED (ptr) || XMARKBIT (ptr->car); - } -#endif - case Lisp_Type_Record: - { - struct lrecord_header *lheader = XRECORD_LHEADER (obj); -#if defined (ERROR_CHECK_GC) && defined (USE_INDEXED_LRECORD_IMPLEMENTATION) - assert (lheader->type <= last_lrecord_type_index_assigned); -#endif - return PURIFIED (lheader) || MARKED_RECORD_HEADER_P (lheader); - } -#ifndef LRECORD_STRING - case Lisp_Type_String: - { - struct Lisp_String *ptr = XSTRING (obj); - return PURIFIED (ptr) || XMARKBIT (ptr->plist); - } -#endif /* ! LRECORD_STRING */ -#ifndef LRECORD_VECTOR - case Lisp_Type_Vector: - { - struct Lisp_Vector *ptr = XVECTOR (obj); - return PURIFIED (ptr) || vector_length (ptr) < 0; - } -#endif /* !LRECORD_VECTOR */ -#ifndef LRECORD_SYMBOL - case Lisp_Type_Symbol: - { - struct Lisp_Symbol *ptr = XSYMBOL (obj); - return PURIFIED (ptr) || XMARKBIT (ptr->plist); - } -#endif - - /* Ints and Chars don't need GC */ -#if defined (USE_MINIMAL_TAGBITS) || ! defined (ERROR_CHECK_GC) - default: - return 1; -#else - default: - abort(); - case Lisp_Type_Int: - case Lisp_Type_Char: - return 1; + struct lrecord_header *lheader = XRECORD_LHEADER (obj); +#if defined (ERROR_CHECK_GC) + assert (lheader->type <= last_lrecord_type_index_assigned); #endif + return C_READONLY_RECORD_HEADER_P (lheader) || MARKED_RECORD_HEADER_P (lheader); } + return 1; } static void @@ -4187,13 +3166,6 @@ gc_sweep (void) /* Put all unmarked conses on free list */ sweep_conses (); -#ifndef LRECORD_VECTOR - /* Free all unmarked vectors */ - sweep_vectors_1 (&all_vectors, - &gc_count_num_vector_used, &gc_count_vector_total_size, - &gc_count_vector_storage); -#endif - /* Free all unmarked bit vectors */ sweep_bit_vectors_1 (&all_bit_vectors, &gc_count_num_bit_vector_used, @@ -4247,9 +3219,7 @@ disksave_object_finalization (void) Vload_path = Qnil; /* Vdump_load_path = Qnil; */ /* Release hash tables for locate_file */ - Fset (intern ("early-package-load-path"), Qnil); - Fset (intern ("late-package-load-path"), Qnil); - Fset (intern ("last-package-load-path"), Qnil); + Flocate_file_clear_hashing (Qt); uncache_home_directory(); #if defined(LOADHIST) && !(defined(LOADHIST_DUMPED) || \ @@ -4263,14 +3233,6 @@ disksave_object_finalization (void) /* Run the disksave finalization methods of all live objects. */ disksave_object_finalization_1 (); -#if 0 /* I don't see any point in this. The purespace starts out all 0's */ - /* Zero out the unused portion of purespace */ - if (!pure_lossage) - memset ( (char *) (PUREBEG + pure_bytes_used), 0, - (((char *) (PUREBEG + get_PURESIZE())) - - ((char *) (PUREBEG + pure_bytes_used)))); -#endif - /* Zero out the uninitialized (really, unused) part of the containers for the live strings. */ { @@ -4586,12 +3548,7 @@ Garbage collection happens automatically if you cons more than { Lisp_Object pl = Qnil; int i; -#ifdef LRECORD_VECTOR int gc_count_vector_total_size = 0; -#endif - - if (purify_flag && pure_lossage) - return Qnil; garbage_collect_1 (); @@ -4604,12 +3561,11 @@ Garbage collection happens automatically if you cons more than char buf [255]; CONST char *name = lrecord_implementations_table[i]->name; int len = strlen (name); -#ifdef LRECORD_VECTOR /* save this for the FSFmacs-compatible part of the summary */ - if (i == *lrecord_vector[0].lrecord_type_index) + if (i == *lrecord_vector.lrecord_type_index) gc_count_vector_total_size = lcrecord_stats[i].bytes_in_use + lcrecord_stats[i].bytes_freed; -#endif + sprintf (buf, "%s-storage", name); pl = gc_plist_hack (buf, lcrecord_stats[i].bytes_in_use, pl); /* Okay, simple pluralization check for `symbol-value-varalias' */ @@ -4668,13 +3624,6 @@ Garbage collection happens automatically if you cons more than pl = gc_plist_hack ("compiled-functions-used", gc_count_num_compiled_function_in_use, pl); -#ifndef LRECORD_VECTOR - pl = gc_plist_hack ("vector-storage", gc_count_vector_storage, pl); - pl = gc_plist_hack ("vectors-total-length", - gc_count_vector_total_size, pl); - pl = gc_plist_hack ("vectors-used", gc_count_num_vector_used, pl); -#endif - pl = gc_plist_hack ("bit-vector-storage", gc_count_bit_vector_storage, pl); pl = gc_plist_hack ("bit-vectors-total-length", gc_count_bit_vector_total_size, pl); @@ -4887,36 +3836,27 @@ init_alloc_once_early (void) lrecord_implementations_table[iii] = 0; } -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION /* - * If USE_INDEXED_LRECORD_IMPLEMENTATION is defined, all the staticly + * All the staticly * defined subr lrecords were initialized with lheader->type == 0. * See subr_lheader_initializer in lisp.h. Force type index 0 to be * assigned to lrecord_subr so that those predefined indexes match * reality. */ - lrecord_type_index (lrecord_subr); - assert (*(lrecord_subr[0].lrecord_type_index) == 0); + lrecord_type_index (&lrecord_subr); + assert (*(lrecord_subr.lrecord_type_index) == 0); /* * The same is true for symbol_value_forward objects, except the * type is 1. */ - lrecord_type_index (lrecord_symbol_value_forward); - assert (*(lrecord_symbol_value_forward[0].lrecord_type_index) == 1); -#endif /* USE_INDEXED_LRECORD_IMPLEMENTATION */ - - symbols_initialized = 0; + lrecord_type_index (&lrecord_symbol_value_forward); + assert (*(lrecord_symbol_value_forward.lrecord_type_index) == 1); gc_generation_number[0] = 0; /* purify_flag 1 is correct even if CANNOT_DUMP. * loadup.el will set to nil at end. */ purify_flag = 1; - pure_bytes_used = 0; - pure_lossage = 0; breathing_space = 0; -#ifndef LRECORD_VECTOR - XSETINT (all_vectors, 0); /* Qzero may not be set yet. */ -#endif XSETINT (all_bit_vectors, 0); /* Qzero may not be set yet. */ XSETINT (Vgc_message, 0); all_lcrecords = 0; @@ -4970,6 +3910,8 @@ init_alloc_once_early (void) #endif /* ERROR_CHECK_TYPECHECK */ } +int pure_bytes_used = 0; + void reinit_alloc (void) { @@ -5049,7 +3991,7 @@ Length (in stack frames) of short backtrace printed out by `debug-allocation'. DEFVAR_BOOL ("purify-flag", &purify_flag /* Non-nil means loading Lisp code in order to dump an executable. -This means that certain objects should be allocated in shared (pure) space. +This means that certain objects should be allocated in readonly space. */ ); DEFVAR_LISP ("pre-gc-hook", &Vpre_gc_hook /* @@ -5075,9 +4017,8 @@ window system and `gc-pointer-glyph' specifies a value (i.e. a pointer image instance) in the domain of the selected frame, the mouse pointer will change instead of this message being printed. */ ); - Vgc_message = make_pure_string ((CONST Bufbyte *) gc_default_message, - countof (gc_default_message) - 1, - Qnil, 1); + Vgc_message = make_string_nocopy ((CONST Bufbyte *) gc_default_message, + countof (gc_default_message) - 1); DEFVAR_LISP ("gc-pointer-glyph", &Vgc_pointer_glyph /* Pointer glyph used to indicate that a garbage collection is in progress. diff --git a/src/buffer.c b/src/buffer.c index d5d69c9..703f0ce 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -541,7 +541,7 @@ get_truename_buffer (REGISTER Lisp_Object filename) static struct buffer * allocate_buffer (void) { - struct buffer *b = alloc_lcrecord_type (struct buffer, lrecord_buffer); + struct buffer *b = alloc_lcrecord_type (struct buffer, &lrecord_buffer); copy_lcrecord (b, XBUFFER (Vbuffer_defaults)); @@ -2073,8 +2073,8 @@ complex_vars_of_buffer (void) { /* Make sure all markable slots in buffer_defaults are initialized reasonably, so mark_buffer won't choke. */ - struct buffer *defs = alloc_lcrecord_type (struct buffer, lrecord_buffer); - struct buffer *syms = alloc_lcrecord_type (struct buffer, lrecord_buffer); + struct buffer *defs = alloc_lcrecord_type (struct buffer, &lrecord_buffer); + struct buffer *syms = alloc_lcrecord_type (struct buffer, &lrecord_buffer); staticpro (&Vbuffer_defaults); staticpro (&Vbuffer_local_symbols); diff --git a/src/callproc.c b/src/callproc.c index 5bdcb78..4b5a5dc 100644 --- a/src/callproc.c +++ b/src/callproc.c @@ -81,6 +81,7 @@ int synch_process_retcode; /* Nonzero if this is termination due to exit. */ static int call_process_exited; +Lisp_Object Vlisp_EXEC_SUFFIXES; static Lisp_Object call_process_kill (Lisp_Object fdpid) @@ -193,7 +194,7 @@ If you quit, the process is killed with SIGINT, or SIGKILL if you /* Do this before building new_argv because GC in Lisp code * called by various filename-hacking routines might relocate strings */ - locate_file (Vexec_path, args[0], EXEC_SUFFIXES, &path, X_OK); + locate_file (Vexec_path, args[0], Vlisp_EXEC_SUFFIXES, &path, X_OK); /* Make sure that the child will be able to chdir to the current buffer's current directory, or its unhandled equivalent. We @@ -722,7 +723,8 @@ child_setup (int in, int out, int err, char **new_argv, #ifdef WINDOWSNT /* Spawn the child. (See ntproc.c:Spawnve). */ - cpid = spawnve (_P_NOWAIT, new_argv[0], new_argv, env); + cpid = spawnve (_P_NOWAIT, new_argv[0], (CONST char* CONST*)new_argv, + (CONST char* CONST*)env); if (cpid == -1) /* An error occurred while trying to spawn the process. */ report_file_error ("Spawning child process", Qnil); @@ -897,4 +899,7 @@ Each element should be a string of the form ENVVARNAME=VALUE. The environment which Emacs inherits is placed in this variable when Emacs starts. */ ); + + Vlisp_EXEC_SUFFIXES = build_string (EXEC_SUFFIXES); + staticpro (&Vlisp_EXEC_SUFFIXES); } diff --git a/src/chartab.c b/src/chartab.c index 996027d..f5eddc9 100644 --- a/src/chartab.c +++ b/src/chartab.c @@ -581,7 +581,7 @@ and 'syntax. See `valid-char-table-type-p'. Lisp_Object obj; enum char_table_type ty = symbol_to_char_table_type (type); - ct = alloc_lcrecord_type (struct Lisp_Char_Table, lrecord_char_table); + ct = alloc_lcrecord_type (struct Lisp_Char_Table, &lrecord_char_table); ct->type = ty; if (ty == CHAR_TABLE_TYPE_SYNTAX) { @@ -611,7 +611,7 @@ make_char_table_entry (Lisp_Object initval) int i; struct Lisp_Char_Table_Entry *cte = alloc_lcrecord_type (struct Lisp_Char_Table_Entry, - lrecord_char_table_entry); + &lrecord_char_table_entry); for (i = 0; i < 96; i++) cte->level2[i] = initval; @@ -628,7 +628,7 @@ copy_char_table_entry (Lisp_Object entry) int i; struct Lisp_Char_Table_Entry *ctenew = alloc_lcrecord_type (struct Lisp_Char_Table_Entry, - lrecord_char_table_entry); + &lrecord_char_table_entry); for (i = 0; i < 96; i++) { @@ -658,7 +658,7 @@ as OLD-TABLE. The values will not themselves be copied. CHECK_CHAR_TABLE (old_table); ct = XCHAR_TABLE (old_table); - ctnew = alloc_lcrecord_type (struct Lisp_Char_Table, lrecord_char_table); + ctnew = alloc_lcrecord_type (struct Lisp_Char_Table, &lrecord_char_table); ctnew->type = ct->type; for (i = 0; i < NUM_ASCII_CHARS; i++) diff --git a/src/config.h.in b/src/config.h.in index 40b56c3..b4145ec 100644 --- a/src/config.h.in +++ b/src/config.h.in @@ -429,11 +429,6 @@ char *alloca(); #undef USE_GCC #undef USE_LCC -/* Allow the user to override the default value of PURESIZE at configure - time. This must come before we include the sys files in order for - it to be able to override any changes in them. */ -#undef RAW_PURESIZE - /* 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 @@ -499,15 +494,6 @@ char *alloca(); definitions isn't right with 64-bit systems. */ #undef USE_UNION_TYPE -/* If defined, use a minimal number of tagbits. This allows usage of more - advanced versions of malloc (like the Doug Lea new GNU malloc) and larger - integers. */ -/* --use-minimal-tagbits */ -#undef USE_MINIMAL_TAGBITS - -/* --use-indexed-lrecord-implementation */ -#undef USE_INDEXED_LRECORD_IMPLEMENTATION - /* The configuration script defines opsysfile to be the name of the s/...h file that describes the system type you are using. The file is chosen based on the configuration name you give. @@ -635,7 +621,7 @@ extern "C" { /* If you turn this flag on, it forces encapsulation in all circumstances; this can be used to make sure things compile OK on various systems. */ -#define DEBUG_ENCAPSULATION +#undef DEBUG_ENCAPSULATION /* basic system calls */ diff --git a/src/console-msw.h b/src/console-msw.h index 25d3293..0bb2fc5 100644 --- a/src/console-msw.h +++ b/src/console-msw.h @@ -38,7 +38,7 @@ Boston, MA 02111-1307, USA. */ #endif #include #include /* DDE management library */ -#ifndef __CYGWIN32__ +#if !defined (__CYGWIN32__) && !defined(__MINGW32__) #include /* FileManager/Explorer drag and drop */ #include #endif diff --git a/src/console.c b/src/console.c index 550e5f8..40c8607 100644 --- a/src/console.c +++ b/src/console.c @@ -144,7 +144,7 @@ static struct console * allocate_console (void) { Lisp_Object console; - struct console *con = alloc_lcrecord_type (struct console, lrecord_console); + struct console *con = alloc_lcrecord_type (struct console, &lrecord_console); struct gcpro gcpro1; copy_lcrecord (con, XCONSOLE (Vconsole_defaults)); @@ -1195,8 +1195,8 @@ complex_vars_of_console (void) /* Make sure all markable slots in console_defaults are initialized reasonably, so mark_console won't choke. */ - struct console *defs = alloc_lcrecord_type (struct console, lrecord_console); - struct console *syms = alloc_lcrecord_type (struct console, lrecord_console); + struct console *defs = alloc_lcrecord_type (struct console, &lrecord_console); + struct console *syms = alloc_lcrecord_type (struct console, &lrecord_console); staticpro (&Vconsole_defaults); staticpro (&Vconsole_local_symbols); diff --git a/src/data.c b/src/data.c index 4e4a274..f3829d0 100644 --- a/src/data.c +++ b/src/data.c @@ -59,9 +59,7 @@ Lisp_Object Qinteger_or_char_p, Qinteger_char_or_marker_p; Lisp_Object Qnumberp, Qnumber_or_marker_p, Qnumber_char_or_marker_p; Lisp_Object Qbit_vectorp, Qbitp, Qcons, Qkeyword, Qcdr, Qignore; -#ifdef LISP_FLOAT_TYPE Lisp_Object Qfloatp; -#endif #ifdef DEBUG_XEMACS @@ -69,19 +67,14 @@ int debug_issue_ebola_notices; int debug_ebola_backtrace_length; -#if 0 -/*#ifndef LRECORD_SYMBOL*/ -#include "backtrace.h" -#endif - int eq_with_ebola_notice (Lisp_Object obj1, Lisp_Object obj2) { - if (debug_issue_ebola_notices != -42 /* abracadabra */ && - (((CHARP (obj1) && INTP (obj2)) || (CHARP (obj2) && INTP (obj1))) - && (debug_issue_ebola_notices >= 2 - || XCHAR_OR_INT (obj1) == XCHAR_OR_INT (obj2)))) + if (debug_issue_ebola_notices + && ((CHARP (obj1) && INTP (obj2)) || (CHARP (obj2) && INTP (obj1)))) { + /* #### It would be really nice if this were a proper warning + instead of brain-dead print ro Qexternal_debugging_output. */ write_c_string ("Comparison between integer and character is constant nil (", Qexternal_debugging_output); Fprinc (obj1, Qexternal_debugging_output); @@ -130,9 +123,15 @@ PREDICATE. At that point, the gotten value is returned. } DOESNT_RETURN -pure_write_error (Lisp_Object obj) +c_write_error (Lisp_Object obj) +{ + signal_simple_error ("Attempt to modify read-only object (c)", obj); +} + +DOESNT_RETURN +lisp_write_error (Lisp_Object obj) { - signal_simple_error ("Attempt to modify read-only object", obj); + signal_simple_error ("Attempt to modify read-only object (lisp)", obj); } DOESNT_RETURN @@ -546,22 +545,6 @@ Return a symbol representing the type of OBJECT. { switch (XTYPE (object)) { -#ifndef LRECORD_CONS - case Lisp_Type_Cons: return Qcons; -#endif - -#ifndef LRECORD_SYMBOL - case Lisp_Type_Symbol: return Qsymbol; -#endif - -#ifndef LRECORD_STRING - case Lisp_Type_String: return Qstring; -#endif - -#ifndef LRECORD_VECTOR - case Lisp_Type_Vector: return Qvector; -#endif - case Lisp_Type_Record: return intern (XRECORD_LHEADER_IMPLEMENTATION (object)->name); @@ -632,7 +615,7 @@ Set the car of CONSCELL to be NEWCAR. Return NEWCAR. if (!CONSP (conscell)) conscell = wrong_type_argument (Qconsp, conscell); - CHECK_IMPURE (conscell); + CHECK_LISP_WRITEABLE (conscell); XCAR (conscell) = newcar; return newcar; } @@ -645,7 +628,7 @@ Set the cdr of CONSCELL to be NEWCDR. Return NEWCDR. if (!CONSP (conscell)) conscell = wrong_type_argument (Qconsp, conscell); - CHECK_IMPURE (conscell); + CHECK_LISP_WRITEABLE (conscell); XCDR (conscell) = newcdr; return newcdr; } @@ -774,7 +757,7 @@ ARRAY may be a vector, bit vector, or string. INDEX starts at 0. if (idx < 0) goto range_error; - CHECK_IMPURE (array); + CHECK_LISP_WRITEABLE (array); if (VECTORP (array)) { @@ -1630,7 +1613,7 @@ make_weak_list (enum weak_list_type type) { Lisp_Object result; struct weak_list *wl = - alloc_lcrecord_type (struct weak_list, lrecord_weak_list); + alloc_lcrecord_type (struct weak_list, &lrecord_weak_list); wl->list = Qnil; wl->type = type; @@ -2219,7 +2202,7 @@ vars_of_data (void) Vall_weak_lists = Qnil; #ifdef DEBUG_XEMACS - DEFVAR_INT ("debug-issue-ebola-notices", &debug_issue_ebola_notices /* + DEFVAR_BOOL ("debug-issue-ebola-notices", &debug_issue_ebola_notices /* If non-zero, note when your code may be suffering from char-int confoundance. That is to say, if XEmacs encounters a usage of `eq', `memq', `equal', etc. where an int and a char with the same value are being compared, @@ -2233,7 +2216,7 @@ have its chars and ints all confounded in the byte code, making it impossible to accurately determine Ebola infection. */ ); - debug_issue_ebola_notices = 2; /* #### temporary hack */ + debug_issue_ebola_notices = 0; DEFVAR_INT ("debug-ebola-backtrace-length", &debug_ebola_backtrace_length /* diff --git a/src/database.c b/src/database.c index 8450333..0493d0e 100644 --- a/src/database.c +++ b/src/database.c @@ -128,7 +128,7 @@ struct Lisp_Database static Lisp_Database * allocate_database (void) { - Lisp_Database *db = alloc_lcrecord_type (Lisp_Database, lrecord_database); + Lisp_Database *db = alloc_lcrecord_type (Lisp_Database, &lrecord_database); db->fname = Qnil; db->live_p = 0; diff --git a/src/depend b/src/depend index a720c62..9831f13 100644 --- a/src/depend +++ b/src/depend @@ -45,7 +45,6 @@ database.o: $(LISP_H) buffer.h bufslots.h database.h lisp-disunion.h lisp-union. mule-canna.o: $(LISP_H) buffer.h bufslots.h file-coding.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h symeval.h symsinit.h mule-ccl.o: $(LISP_H) buffer.h bufslots.h file-coding.h lisp-disunion.h lisp-union.h lrecord.h mule-ccl.h mule-charset.h symeval.h symsinit.h mule-charset.o: $(LISP_H) buffer.h bufslots.h chartab.h conslots.h console.h device.h elhash.h faces.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-charset.h symeval.h symsinit.h -mule-coding.o: $(LISP_H) buffer.h bufslots.h elhash.h insdel.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-ccl.h mule-charset.h mule-coding.h symeval.h symsinit.h mule-mcpath.o: $(LISP_H) buffer.h bufslots.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h symeval.h symsinit.h sysfile.h mule-wnnfns.o: $(LISP_H) buffer.h bufslots.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h redisplay.h scrollbar.h symeval.h symsinit.h sysdep.h window.h winslots.h mule.o: $(LISP_H) lisp-disunion.h lisp-union.h lrecord.h regex.h symeval.h symsinit.h @@ -62,7 +61,7 @@ EmacsManager.o: EmacsManager.h EmacsManagerP.h config.h xintrinsicp.h xmmanagerp EmacsShell-sub.o: EmacsShell.h EmacsShellP.h config.h xintrinsic.h xintrinsicp.h EmacsShell.o: EmacsShell.h ExternalShell.h config.h xintrinsicp.h abbrev.o: $(LISP_H) buffer.h bufslots.h chartab.h commands.h insdel.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h redisplay.h scrollbar.h symeval.h symsinit.h syntax.h window.h winslots.h -alloc.o: $(LISP_H) backtrace.h buffer.h bufslots.h bytecode.h chartab.h conslots.h console.h device.h elhash.h events.h extents.h frame.h frameslots.h glyphs.h gui.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h opaque.h puresize-adjust.h puresize.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysfile.h systime.h toolbar.h window.h winslots.h +alloc.o: $(LISP_H) backtrace.h buffer.h bufslots.h bytecode.h chartab.h conslots.h console.h device.h elhash.h events.h extents.h frame.h frameslots.h glyphs.h gui.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h opaque.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysfile.h systime.h toolbar.h window.h winslots.h alloca.o: config.h balloon_help.o: balloon_help.h config.h xintrinsic.h blocktype.o: $(LISP_H) blocktype.h lisp-disunion.h lisp-union.h lrecord.h symeval.h symsinit.h @@ -79,13 +78,13 @@ cmds.o: $(LISP_H) buffer.h bufslots.h chartab.h commands.h insdel.h lisp-disunio console-stream.o: $(LISP_H) conslots.h console-stream.h console-tty.h console.h device.h events.h frame.h frameslots.h glyphs.h gui.h lisp-disunion.h lisp-union.h lrecord.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysdep.h sysfile.h syssignal.h systime.h systty.h toolbar.h window.h winslots.h console-tty.o: $(LISP_H) buffer.h bufslots.h conslots.h console-stream.h console-tty.h console.h device.h faces.h file-coding.h frame.h frameslots.h glyphs.h gpmevent.h gui.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-charset.h scrollbar.h specifier.h symeval.h symsinit.h sysdep.h sysfile.h syssignal.h systty.h toolbar.h console.o: $(LISP_H) buffer.h bufslots.h conslots.h console-tty.h console.h device.h events.h frame.h frameslots.h glyphs.h gui.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysdep.h syssignal.h systime.h systty.h toolbar.h window.h winslots.h -data.o: $(LISP_H) backtrace.h buffer.h bufslots.h bytecode.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h symeval.h symsinit.h sysfloat.h syssignal.h +data.o: $(LISP_H) buffer.h bufslots.h bytecode.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h symeval.h symsinit.h sysfloat.h syssignal.h debug.o: $(LISP_H) bytecode.h debug.h lisp-disunion.h lisp-union.h lrecord.h symeval.h symsinit.h device-tty.o: $(LISP_H) buffer.h bufslots.h conslots.h console-stream.h console-tty.h console.h device.h events.h faces.h frame.h frameslots.h glyphs.h gui.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-charset.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysdep.h syssignal.h systime.h systty.h toolbar.h device.o: $(LISP_H) buffer.h bufslots.h conslots.h console.h device.h elhash.h events.h faces.h frame.h frameslots.h glyphs.h gui.h keymap.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysdep.h syssignal.h systime.h toolbar.h window.h winslots.h dgif_lib.o: gifrlib.h dialog.o: $(LISP_H) conslots.h console.h device.h frame.h frameslots.h glyphs.h gui.h lisp-disunion.h lisp-union.h lrecord.h scrollbar.h specifier.h symeval.h symsinit.h toolbar.h -dired.o: $(LISP_H) buffer.h bufslots.h commands.h elhash.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h ndir.h opaque.h regex.h symeval.h symsinit.h sysdir.h sysfile.h syspwd.h systime.h +dired.o: $(LISP_H) buffer.h bufslots.h commands.h elhash.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h ndir.h opaque.h regex.h symeval.h symsinit.h sysdep.h sysdir.h sysfile.h syspwd.h systime.h doc.o: $(LISP_H) buffer.h bufslots.h bytecode.h insdel.h keymap.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h symeval.h symsinit.h sysfile.h doprnt.o: $(LISP_H) buffer.h bufslots.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-charset.h symeval.h symsinit.h dragdrop.o: $(LISP_H) dragdrop.h lisp-disunion.h lisp-union.h lrecord.h symeval.h symsinit.h @@ -104,7 +103,7 @@ event-unixoid.o: $(LISP_H) conslots.h console-stream.h console-tty.h console.h d events.o: $(LISP_H) buffer.h bufslots.h conslots.h console-tty.h console-x.h console.h device.h events-mod.h events.h extents.h frame.h frameslots.h glyphs.h gui.h keymap.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h syssignal.h systime.h systty.h toolbar.h window.h winslots.h xintrinsic.h extents.o: $(LISP_H) buffer.h bufslots.h conslots.h console.h debug.h device.h elhash.h extents.h faces.h frame.h frameslots.h glyphs.h gui.h insdel.h keymap.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h opaque.h process.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h toolbar.h faces.o: $(LISP_H) buffer.h bufslots.h conslots.h console.h device.h elhash.h extents.h faces.h frame.h frameslots.h glyphs.h gui.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h objects.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h toolbar.h window.h winslots.h -file-coding.o: $(LISP_H) buffer.h bufslots.h elhash.h file-coding.h insdel.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-ccl.h mule-charset.h symeval.h symsinit.h +file-coding.o: $(LISP_H) buffer.h bufslots.h chartab.h elhash.h file-coding.h insdel.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-ccl.h mule-charset.h symeval.h symsinit.h fileio.o: $(LISP_H) buffer.h bufslots.h conslots.h console.h device.h events.h file-coding.h frame.h frameslots.h glyphs.h gui.h insdel.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-charset.h ndir.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysdep.h sysdir.h sysfile.h sysproc.h syspwd.h systime.h toolbar.h window.h winslots.h filelock.o: $(LISP_H) buffer.h bufslots.h lisp-disunion.h lisp-union.h lrecord.h mule-charset.h ndir.h paths.h symeval.h symsinit.h sysdir.h sysfile.h syspwd.h syssignal.h filemode.o: $(LISP_H) lisp-disunion.h lisp-union.h lrecord.h symeval.h symsinit.h sysfile.h @@ -158,7 +157,6 @@ process-nt.o: $(LISP_H) hash.h lisp-disunion.h lisp-union.h lrecord.h lstream.h process-unix.o: $(LISP_H) buffer.h bufslots.h conslots.h console.h device.h events.h file-coding.h frame.h frameslots.h glyphs.h gui.h hash.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-charset.h opaque.h process.h procimpl.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysdep.h sysfile.h sysproc.h syssignal.h systime.h systty.h syswait.h toolbar.h window.h winslots.h process.o: $(LISP_H) buffer.h bufslots.h commands.h conslots.h console.h device.h events.h file-coding.h frame.h frameslots.h glyphs.h gui.h hash.h insdel.h lisp-disunion.h lisp-union.h lrecord.h lstream.h mule-charset.h opaque.h process.h procimpl.h redisplay.h scrollbar.h specifier.h symeval.h symsinit.h sysfile.h sysproc.h syssignal.h systime.h systty.h syswait.h toolbar.h window.h winslots.h profile.o: $(LISP_H) backtrace.h bytecode.h elhash.h hash.h lisp-disunion.h lisp-union.h lrecord.h symeval.h symsinit.h syssignal.h systime.h -pure.o: $(LISP_H) lisp-disunion.h lisp-union.h lrecord.h puresize-adjust.h puresize.h symeval.h symsinit.h ralloc.o: $(LISP_H) getpagesize.h lisp-disunion.h lisp-union.h lrecord.h symeval.h symsinit.h rangetab.o: $(LISP_H) lisp-disunion.h lisp-union.h lrecord.h rangetab.h symeval.h symsinit.h realpath.o: config.h diff --git a/src/device-msw.c b/src/device-msw.c index 6c81ef8..7aef4e8 100644 --- a/src/device-msw.c +++ b/src/device-msw.c @@ -303,11 +303,12 @@ syms_of_device_mswindows (void) DEFVAR_LISP ("mswindows-downcase-file-names", &Vmswindows_downcase_file_names /* Non-nil means convert all-upper case file names to lower case. -This applies when performing completions and file name expansion.*/ ); +This applies when performing completions and file name expansion. +*/ ); Vmswindows_downcase_file_names = Qnil; DEFVAR_LISP ("mswindows-get-true-file-attributes", &Vmswindows_get_true_file_attributes /* - "Non-nil means determine accurate link count in file-attributes. +Non-nil means determine accurate link count in file-attributes. This option slows down file-attributes noticeably, so is disabled by default. Note that it is only useful for files on NTFS volumes, where hard links are supported. diff --git a/src/device.c b/src/device.c index 4c1feab..a6b751f 100644 --- a/src/device.c +++ b/src/device.c @@ -166,7 +166,7 @@ static struct device * allocate_device (Lisp_Object console) { Lisp_Object device; - struct device *d = alloc_lcrecord_type (struct device, lrecord_device); + struct device *d = alloc_lcrecord_type (struct device, &lrecord_device); struct gcpro gcpro1; zero_lcrecord (d); diff --git a/src/dired-msw.c b/src/dired-msw.c index f717c65..a090f2b 100644 --- a/src/dired-msw.c +++ b/src/dired-msw.c @@ -319,14 +319,14 @@ mswindows_format_file (WIN32_FIND_DATA *file, char *buf, int display_size, cptr[1] = cptr[4] = cptr[7] = 'w'; } if ((file->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) || - len > 4 && - (_stricmp(&file->cFileName[len - 4], ".exe") == 0 - || _stricmp(&file->cFileName[len - 4], ".com") == 0 - || _stricmp(&file->cFileName[len - 4], ".bat") == 0 + (len > 4 && + (_stricmp(&file->cFileName[len - 4], ".exe") == 0 + || _stricmp(&file->cFileName[len - 4], ".com") == 0 + || _stricmp(&file->cFileName[len - 4], ".bat") == 0 #if 0 - || _stricmp(&file->cFileName[len - 4], ".pif") == 0 + || _stricmp(&file->cFileName[len - 4], ".pif") == 0 #endif - )) + ))) { cptr[2] = cptr[5] = cptr[8] = 'x'; } else { @@ -639,7 +639,7 @@ syms_of_dired_mswindows (void) void vars_of_dired_mswindows (void) { - DEFVAR_BOOL ("mswindows-ls-sort-case-insensitive", &mswindows_ls_sort_case_insensitive, /* + DEFVAR_BOOL ("mswindows-ls-sort-case-insensitive", &mswindows_ls_sort_case_insensitive /* *Non-nil means filenames are sorted in a case-insensitive fashion. Nil means filenames are sorted in a case-sensitive fashion, just like Unix. */ ); diff --git a/src/dired.c b/src/dired.c index b2735e3..472133e 100644 --- a/src/dired.c +++ b/src/dired.c @@ -31,6 +31,7 @@ Boston, MA 02111-1307, USA. */ #include "sysfile.h" #include "sysdir.h" #include "systime.h" +#include "sysdep.h" #include "syspwd.h" Lisp_Object Vcompletion_ignored_extensions; @@ -139,38 +140,15 @@ If FILES-ONLY is the symbol t, then only the "files" in the directory { if (!NILP (files_only)) { - int dir_p; struct stat st; - char *cur_statbuf = statbuf; - char *cur_statbuf_tail = statbuf_tail; - - /* #### I don't think the code under `if' is necessary - anymore. The crashes in this function were reported - because MAXNAMLEN was used to remember the *whole* - statbuf, instead of using MAXPATHLEN. This should be - tested after 21.0 is released. */ - - /* We normally use the buffer created by alloca. - However, if the file name we get too big, we'll use a - malloced buffer, and free it. It is undefined how - stat() will react to this, but we avoid a buffer - overrun. */ - if (len > MAXNAMLEN) - { - cur_statbuf = (char *)xmalloc (directorylen + len + 1); - memcpy (cur_statbuf, statbuf, directorylen); - cur_statbuf_tail = cur_statbuf + directorylen; - } - memcpy (cur_statbuf_tail, dp->d_name, len); - cur_statbuf_tail[len] = 0; + int dir_p = 0; - if (stat (cur_statbuf, &st) < 0) - dir_p = 0; - else - dir_p = ((st.st_mode & S_IFMT) == S_IFDIR); + memcpy (statbuf_tail, dp->d_name, len); + statbuf_tail[len] = 0; - if (cur_statbuf != statbuf) - xfree (cur_statbuf); + if (stat (statbuf, &st) == 0 + && (st.st_mode & S_IFMT) == S_IFDIR) + dir_p = 1; if (EQ (files_only, Qt) && dir_p) continue; @@ -579,54 +557,52 @@ These are all user names which begin with USER. return user_name_completion (user, 1, NULL); } +struct user_cache { + char **data; + int length; + int size; + EMACS_TIME last_rebuild_time; +}; +static struct user_cache user_cache; + +static void +free_user_cache (struct user_cache *cache) +{ + int i; + for (i = 0; i < cache->length; i++) + xfree (cache->data[i]); + xfree (cache->data); +} + static Lisp_Object user_name_completion_unwind (Lisp_Object locative) { - Lisp_Object obj1 = XCAR (locative); - Lisp_Object obj2 = XCDR (locative); - char **cache; - int clen, i; - + int interrupted = !NILP (XCAR (locative)); - if (!NILP (obj1) && !NILP (obj2)) + if (interrupted) { - /* clean up if interrupted building cache */ - cache = *(char ***)get_opaque_ptr (obj1); - clen = *(int *)get_opaque_ptr (obj2); - free_opaque_ptr (obj1); - free_opaque_ptr (obj2); - for (i = 0; i < clen; i++) - free (cache[i]); - free (cache); + endpwent (); + speed_up_interrupts (); + free_user_cache (&user_cache); } - free_cons (XCONS (locative)); - endpwent (); return Qnil; } -static char **user_cache; -static int user_cache_len; -static int user_cache_max; -static long user_cache_time; - #define USER_CACHE_REBUILD (24*60*60) /* 1 day, in seconds */ static Lisp_Object user_name_completion (Lisp_Object user, int all_flag, int *uniq) { /* This function can GC */ - struct passwd *pw; int matchcount = 0; Lisp_Object bestmatch = Qnil; Charcount bestmatchsize = 0; int speccount = specpdl_depth (); - int i, cmax, clen; - char **cache; Charcount user_name_length; - Lisp_Object locative; EMACS_TIME t; + int i; struct gcpro gcpro1, gcpro2; GCPRO2 (user, bestmatch); @@ -638,67 +614,48 @@ user_name_completion (Lisp_Object user, int all_flag, int *uniq) /* Cache user name lookups because it tends to be quite slow. * Rebuild the cache occasionally to catch changes */ EMACS_GET_TIME (t); - if (user_cache && - EMACS_SECS (t) - user_cache_time > USER_CACHE_REBUILD) + if (user_cache.data && + (EMACS_SECS (t) - EMACS_SECS (user_cache.last_rebuild_time) + > USER_CACHE_REBUILD)) { - for (i = 0; i < user_cache_len; i++) - free (user_cache[i]); - free (user_cache); - user_cache = NULL; - user_cache_len = 0; - user_cache_max = 0; + free_user_cache (&user_cache); + xzero (user_cache); } - if (user_cache == NULL || user_cache_max <= 0) + if (!user_cache.data) { - cmax = 200; - clen = 0; - cache = (char **) malloc (cmax*sizeof (char *)); - + struct passwd *pwd; + Lisp_Object locative = noseeum_cons (Qt, Qnil); + slow_down_interrupts (); setpwent (); - locative = noseeum_cons (Qnil, Qnil); - XCAR (locative) = make_opaque_ptr ((void *) &cache); - XCDR (locative) = make_opaque_ptr ((void *) &clen); record_unwind_protect (user_name_completion_unwind, locative); - /* #### may need to slow down interrupts around call to getpwent - * below. at least the call to getpwnam in Fuser_full_name - * is documented as needing it on irix. */ - while ((pw = getpwent ())) + while ((pwd = getpwent ())) { - if (clen >= cmax) - { - cmax *= 2; - cache = (char **) realloc (cache, cmax*sizeof (char *)); - } - + Bufbyte *pwuser; QUIT; - - cache[clen++] = strdup (pw->pw_name); + DO_REALLOC (user_cache.data, user_cache.size, + user_cache.length + 1, char *); + GET_C_CHARPTR_INT_DATA_ALLOCA (pwd->pw_name, FORMAT_OS, pwuser); + user_cache.data[user_cache.length++] = xstrdup (pwuser); } - free_opaque_ptr (XCAR (locative)); - free_opaque_ptr (XCDR (locative)); + endpwent (); + speed_up_interrupts (); XCAR (locative) = Qnil; - XCDR (locative) = Qnil; - - unbind_to (speccount, Qnil); /* free locative cons, endpwent() */ - - user_cache_max = cmax; - user_cache_len = clen; - user_cache = cache; - user_cache_time = EMACS_SECS (t); + unbind_to (speccount, Qnil); /* free locative cons */ + EMACS_GET_TIME (user_cache.last_rebuild_time); } - for (i = 0; i < user_cache_len; i++) + for (i = 0; i < user_cache.length; i++) { - Bufbyte *d_name = (Bufbyte *) user_cache[i]; - Bytecount len = strlen ((char *) d_name); + Bufbyte *u_name = user_cache.data[i]; + Bytecount len = strlen ((char *) u_name); /* scmp() works in chars, not bytes, so we have to compute this: */ - Charcount cclen = bytecount_to_charcount (d_name, len); + Charcount cclen = bytecount_to_charcount (u_name, len); QUIT; - if (cclen < user_name_length || - 0 <= scmp (d_name, XSTRING_DATA (user), user_name_length)) + if (cclen < user_name_length + || 0 <= scmp_1 (u_name, XSTRING_DATA (user), user_name_length, 0)) continue; matchcount++; /* count matching completions */ @@ -709,7 +666,7 @@ user_name_completion (Lisp_Object user, int all_flag, int *uniq) struct gcpro ngcpro1; NGCPRO1 (name); /* This is a possible completion */ - name = make_string (d_name, len); + name = make_string (u_name, len); if (all_flag) { bestmatch = Fcons (name, bestmatch); @@ -725,37 +682,11 @@ user_name_completion (Lisp_Object user, int all_flag, int *uniq) { Charcount compare = min (bestmatchsize, cclen); Bufbyte *p1 = XSTRING_DATA (bestmatch); - Bufbyte *p2 = d_name; - Charcount matchsize = scmp (p1, p2, compare); + Bufbyte *p2 = u_name; + Charcount matchsize = scmp_1 (p1, p2, compare, 0); if (matchsize < 0) matchsize = compare; - if (completion_ignore_case) - { - /* If this is an exact match except for case, - use it as the best match rather than one that is not - an exact match. This way, we get the case pattern - of the actual match. */ - if ((matchsize == cclen - && matchsize < XSTRING_CHAR_LENGTH (bestmatch)) - || - /* If there is no exact match ignoring case, - prefer a match that does not change the case - of the input. */ - (((matchsize == cclen) - == - (matchsize == XSTRING_CHAR_LENGTH (bestmatch))) - /* If there is more than one exact match aside from - case, and one of them is exact including case, - prefer that one. */ - && 0 > scmp_1 (p2, XSTRING_DATA (user), - user_name_length, 0) - && 0 <= scmp_1 (p1, XSTRING_DATA (user), - user_name_length, 0))) - { - bestmatch = make_string (d_name, len); - } - } bestmatchsize = matchsize; } @@ -779,11 +710,11 @@ Lisp_Object make_directory_hash_table (CONST char *path) { DIR *d; - Lisp_Object hash = - make_lisp_hash_table (100, HASH_TABLE_NON_WEAK, HASH_TABLE_EQUAL); if ((d = opendir (path))) { DIRENTRY *dp; + Lisp_Object hash = + make_lisp_hash_table (20, HASH_TABLE_NON_WEAK, HASH_TABLE_EQUAL); while ((dp = readdir (d))) { @@ -793,8 +724,10 @@ make_directory_hash_table (CONST char *path) Fputhash (make_string ((Bufbyte *) dp->d_name, len), Qt, hash); } closedir (d); + return hash; } - return hash; + else + return Qnil; } Lisp_Object @@ -955,10 +888,4 @@ It is used by the functions `file-name-completion' and `file-name-all-completions'. */ ); Vcompletion_ignored_extensions = Qnil; - -#ifndef WINDOWSNT - user_cache = NULL; - user_cache_len = 0; - user_cache_max = 0; -#endif } diff --git a/src/eldap.c b/src/eldap.c index 325daa8..caea909 100644 --- a/src/eldap.c +++ b/src/eldap.c @@ -123,7 +123,7 @@ static struct Lisp_LDAP * allocate_ldap (void) { struct Lisp_LDAP *ldap = - alloc_lcrecord_type (struct Lisp_LDAP, lrecord_ldap); + alloc_lcrecord_type (struct Lisp_LDAP, &lrecord_ldap); ldap->ld = NULL; ldap->host = Qnil; @@ -359,7 +359,7 @@ Close an LDAP connection. struct ldap_unwind_struct { LDAPMessage *res; - char **vals; + struct berval **vals; }; @@ -371,11 +371,11 @@ ldap_search_unwind (Lisp_Object unwind_obj) if (unwind->res) ldap_msgfree (unwind->res); if (unwind->vals) - ldap_value_free (unwind->vals); + ldap_value_free_len (unwind->vals); return Qnil; } -DEFUN ("ldap-search-internal", Fldap_search_internal, 2, 6, 0, /* +DEFUN ("ldap-search-internal", Fldap_search_internal, 2, 7, 0, /* Perform a search on an open LDAP connection. LDAP is an LDAP connection object created with `ldap-open'. FILTER is a filter string for the search as described in RFC 1558. @@ -386,10 +386,13 @@ ATTRS is a list of strings indicating which attributes to retrieve for each matching entry. If nil return all available attributes. If ATTRSONLY is non-nil then only the attributes are retrieved, not the associated values. +If WITHDN is non-nil each entry in the result will be prepennded with +its distinguished name DN. The function returns a list of matching entries. Each entry is itself -an alist of attribute/values. +an alist of attribute/value pairs optionally preceded by the DN of the +entry according to the value of WITHDN. */ - (ldap, filter, base, scope, attrs, attrsonly)) + (ldap, filter, base, scope, attrs, attrsonly, withdn)) { /* This function can GC */ @@ -397,7 +400,7 @@ an alist of attribute/values. LDAP *ld; LDAPMessage *e; BerElement *ptr; - char *a; + char *a, *dn; int i, rc; int matches; struct ldap_unwind_struct unwind; @@ -500,23 +503,35 @@ an alist of attribute/values. restore the old echo area contents later. */ message ("Parsing ldap results... %d", matches); entry = Qnil; + /* Get the DN if required */ + if (! NILP (withdn)) + { + dn = ldap_get_dn (ld, e); + if (dn == NULL) + { + signal_ldap_error (ld); + } + entry = Fcons (build_ext_string (dn, FORMAT_OS), Qnil); + } for (a= ldap_first_attribute (ld, e, &ptr); a != NULL; - a= ldap_next_attribute (ld, e, ptr) ) + a = ldap_next_attribute (ld, e, ptr) ) { list = Fcons (build_ext_string (a, FORMAT_OS), Qnil); - unwind.vals = ldap_get_values (ld, e, a); + unwind.vals = ldap_get_values_len (ld, e, a); if (unwind.vals != NULL) { for (i = 0; unwind.vals[i] != NULL; i++) { - list = Fcons (build_ext_string (unwind.vals[i], FORMAT_OS), + list = Fcons (make_ext_string (unwind.vals[i]->bv_val, + unwind.vals[i]->bv_len, + FORMAT_OS), list); } } entry = Fcons (Fnreverse (list), entry); - ldap_value_free (unwind.vals); + ldap_value_free_len (unwind.vals); unwind.vals = NULL; } result = Fcons (Fnreverse (entry), diff --git a/src/eldap.h b/src/eldap.h index fb0abbb..e60c8a8 100644 --- a/src/eldap.h +++ b/src/eldap.h @@ -69,6 +69,7 @@ Lisp_Object Fldap_search_internal (Lisp_Object ldap, Lisp_Object base, Lisp_Object scope, Lisp_Object attrs, - Lisp_Object attrsonly); + Lisp_Object attrsonly, + Lisp_Object withdn); #endif /* _XEMACS_ELDAP_H_ */ diff --git a/src/elhash.c b/src/elhash.c index 686f78f..a802123 100644 --- a/src/elhash.c +++ b/src/elhash.c @@ -411,7 +411,7 @@ make_general_lisp_hash_table (size_t size, double rehash_threshold) { Lisp_Object hash_table; - Lisp_Hash_Table *ht = alloc_lcrecord_type (Lisp_Hash_Table, lrecord_hash_table); + Lisp_Hash_Table *ht = alloc_lcrecord_type (Lisp_Hash_Table, &lrecord_hash_table); ht->type = type; ht->rehash_size = rehash_size; @@ -832,7 +832,7 @@ The keys and values will not themselves be copied. (hash_table)) { CONST Lisp_Hash_Table *ht_old = xhash_table (hash_table); - Lisp_Hash_Table *ht = alloc_lcrecord_type (Lisp_Hash_Table, lrecord_hash_table); + Lisp_Hash_Table *ht = alloc_lcrecord_type (Lisp_Hash_Table, &lrecord_hash_table); copy_lcrecord (ht, ht_old); diff --git a/src/emacs.c b/src/emacs.c index e022334..a41e580 100644 --- a/src/emacs.c +++ b/src/emacs.c @@ -224,6 +224,8 @@ static void sort_args (int argc, char **argv); Lisp_Object Qkill_emacs_hook; Lisp_Object Qsave_buffers_kill_emacs; +extern Lisp_Object Vlisp_EXEC_SUFFIXES; + /* Signal code for the fatal signal that was received */ static int fatal_error_code; @@ -1022,6 +1024,9 @@ main_1 (int argc, char **argv, char **envp, int restart) #ifdef HAVE_MSW_C_DIRED syms_of_dired_mswindows (); #endif +#ifdef WINDOWSNT + syms_of_ntproc (); +#endif #endif /* HAVE_MS_WINDOWS */ #ifdef MULE @@ -1676,7 +1681,8 @@ main_1 (int argc, char **argv, char **envp, int restart) else { Vinvocation_path = decode_env_path ("PATH", NULL); - locate_file (Vinvocation_path, Vinvocation_name, EXEC_SUFFIXES, + locate_file (Vinvocation_path, Vinvocation_name, + Vlisp_EXEC_SUFFIXES, &Vinvocation_directory, X_OK); } @@ -2014,7 +2020,7 @@ Do not call this. It will reinitialize your XEmacs. You'll be sorry. total_len += wampum_all_len[ac]; } DO_REALLOC (run_temacs_args, run_temacs_args_size, total_len, char); - DO_REALLOC (run_temacs_argv, run_temacs_argv_size, nargs+1, char *); + DO_REALLOC (run_temacs_argv, run_temacs_argv_size, nargs+2, char *); memcpy (run_temacs_args, wampum, namesize); run_temacs_argv [0] = run_temacs_args; @@ -2031,13 +2037,6 @@ Do not call this. It will reinitialize your XEmacs. You'll be sorry. unbind_to (0, Qnil); /* this closes loadup.el */ purify_flag = 0; run_temacs_argc = nargs + 1; -#if 0 -#ifdef REPORT_PURE_USAGE - report_pure_usage (1, 0); -#else - report_pure_usage (0, 0); -#endif -#endif /* 0 */ LONGJMP (run_temacs_catch, 1); return Qnil; /* not reached; warning suppression */ } @@ -2446,12 +2445,6 @@ and announce itself normally when it is run. opurify = purify_flag; purify_flag = 0; -#ifdef DEBUG_XEMACS - report_pure_usage (1, 1); -#else - report_pure_usage (0, 1); -#endif - fflush (stderr); fflush (stdout); diff --git a/src/emodules.c b/src/emodules.c index 1a5d896..b8f2e6e 100644 --- a/src/emodules.c +++ b/src/emodules.c @@ -42,6 +42,8 @@ typedef struct _emodules_list dll_handle dlhandle; /* Dynamic lib handle */ } emodules_list; +static Lisp_Object Vmodule_extensions; + static int emodules_depth; static dll_handle dlhandle; static emodules_list *modules; @@ -334,7 +336,8 @@ emodules_load(CONST char *module, CONST char *modname, CONST char *modver) GCPRO2(filename, foundname); filename = build_string (tmod); - fd = locate_file(Vmodule_load_path, filename, ":.ell:.so:.dll", &foundname, -1); + fd = locate_file(Vmodule_load_path, filename, Vmodule_extensions, + &foundname, -1); UNGCPRO; if (fd < 0) @@ -567,6 +570,10 @@ the correctness of a dynamic module, which can have unpredictable results when a dynamic module is loaded. */); + /* #### Export this to Lisp */ + Vmodule_extensions = build_string (":.ell:.so:.dll"); + staticpro (&Vmodule_extensions); + load_modules_quietly = 0; emodules_depth = 0; modules = (emodules_list *)0; diff --git a/src/event-stream.c b/src/event-stream.c index b97a408..e294ae6 100644 --- a/src/event-stream.c +++ b/src/event-stream.c @@ -432,7 +432,7 @@ allocate_command_builder (Lisp_Object console) { Lisp_Object builder_obj; struct command_builder *builder = - alloc_lcrecord_type (struct command_builder, lrecord_command_builder); + alloc_lcrecord_type (struct command_builder, &lrecord_command_builder); builder->console = console; reset_command_builder_event_chain (builder); diff --git a/src/events.c b/src/events.c index 143782f..f484001 100644 --- a/src/events.c +++ b/src/events.c @@ -87,7 +87,7 @@ deinitialize_event (Lisp_Object ev) ((int *) event) [i] = 0xdeadbeef; event->event_type = dead_event; event->channel = Qnil; - set_lheader_implementation (&(event->lheader), lrecord_event); + set_lheader_implementation (&(event->lheader), &lrecord_event); XSET_EVENT_NEXT (ev, Qnil); } @@ -96,7 +96,7 @@ void zero_event (struct Lisp_Event *e) { xzero (*e); - set_lheader_implementation (&(e->lheader), lrecord_event); + set_lheader_implementation (&(e->lheader), &lrecord_event); e->event_type = empty_event; e->next = Qnil; e->channel = Qnil; diff --git a/src/extents.c b/src/extents.c index 1c7c5b3..6360a4d 100644 --- a/src/extents.c +++ b/src/extents.c @@ -934,7 +934,7 @@ allocate_extent_auxiliary (EXTENT ext) { Lisp_Object extent_aux; struct extent_auxiliary *data = - alloc_lcrecord_type (struct extent_auxiliary, lrecord_extent_auxiliary); + alloc_lcrecord_type (struct extent_auxiliary, &lrecord_extent_auxiliary); copy_lcrecord (data, &extent_auxiliary_defaults); XSETEXTENT_AUXILIARY (extent_aux, data); @@ -1033,7 +1033,7 @@ allocate_extent_info (void) { Lisp_Object extent_info; struct extent_info *data = - alloc_lcrecord_type (struct extent_info, lrecord_extent_info); + alloc_lcrecord_type (struct extent_info, &lrecord_extent_info); XSETEXTENT_INFO (extent_info, data); data->extents = allocate_extent_list (); @@ -3667,7 +3667,7 @@ copy_extent (EXTENT original, Bytind from, Bytind to, Lisp_Object object) one. */ struct extent_auxiliary *data = alloc_lcrecord_type (struct extent_auxiliary, - lrecord_extent_auxiliary); + &lrecord_extent_auxiliary); copy_lcrecord (data, XEXTENT_AUXILIARY (XCAR (original->plist))); XSETEXTENT_AUXILIARY (XCAR (e->plist), data); @@ -5009,10 +5009,10 @@ set_extent_glyph_1 (Lisp_Object extent_obj, Lisp_Object glyph, int endp, EXTENT extent = decode_extent (extent_obj, DE_MUST_HAVE_BUFFER); glyph_layout layout = symbol_to_glyph_layout (layout_obj); - /* Make sure we've actually been given a glyph or it's nil (meaning - we're deleting a glyph from an extent). */ + /* Make sure we've actually been given a valid glyph or it's nil + (meaning we're deleting a glyph from an extent). */ if (!NILP (glyph)) - CHECK_GLYPH (glyph); + CHECK_BUFFER_GLYPH (glyph); set_extent_glyph (extent, glyph, endp, layout); return glyph; diff --git a/src/faces.c b/src/faces.c index 44fbd98..7ce8d10 100644 --- a/src/faces.c +++ b/src/faces.c @@ -358,7 +358,7 @@ static struct Lisp_Face * allocate_face (void) { struct Lisp_Face *result = - alloc_lcrecord_type (struct Lisp_Face, lrecord_face); + alloc_lcrecord_type (struct Lisp_Face, &lrecord_face); reset_face (result); return result; @@ -1827,7 +1827,7 @@ vars_of_faces (void) syms[n++] = Qblinking; syms[n++] = Qreverse; - Vbuilt_in_face_specifiers = pure_list (n, syms); + Vbuilt_in_face_specifiers = Flist (n, syms); staticpro (&Vbuilt_in_face_specifiers); } } diff --git a/src/file-coding.c b/src/file-coding.c index ee0da8d..081f851 100644 --- a/src/file-coding.c +++ b/src/file-coding.c @@ -531,7 +531,7 @@ static Lisp_Coding_System * allocate_coding_system (enum coding_system_type type, Lisp_Object name) { Lisp_Coding_System *codesys = - alloc_lcrecord_type (Lisp_Coding_System, lrecord_coding_system); + alloc_lcrecord_type (Lisp_Coding_System, &lrecord_coding_system); zero_lcrecord (codesys); CODING_SYSTEM_PRE_WRITE_CONVERSION (codesys) = Qnil; @@ -949,6 +949,40 @@ be created. return new_coding_system; } +DEFUN ("define-coding-system-alias", Fdefine_coding_system_alias, 2, 2, 0, /* +Define symbol ALIAS as an alias for coding system CODING-SYSTEM. +*/ + (alias, coding_system)) +{ + CHECK_SYMBOL (alias); + if (!NILP (Ffind_coding_system (alias))) + signal_simple_error ("Symbol already names a coding system", alias); + coding_system = Fget_coding_system (coding_system); + Fputhash (alias, coding_system, Vcoding_system_hash_table); + + /* Set up aliases for subsidiaries. */ + if (XCODING_SYSTEM_EOL_TYPE (coding_system) == EOL_AUTODETECT) + { + Lisp_Object str; + XSETSTRING (str, symbol_name (XSYMBOL (alias))); +#define FROB(type, name) \ + do { \ + Lisp_Object subsidiary = XCODING_SYSTEM_EOL_##type (coding_system); \ + if (!NILP (subsidiary)) \ + Fdefine_coding_system_alias \ + (Fintern (concat2 (str, build_string (name)), Qnil), subsidiary); \ + } while (0) + FROB (LF, "-unix"); + FROB (CRLF, "-dos"); + FROB (CR, "-mac"); +#undef FROB + } + /* FSF return value is a vector of [ALIAS-unix ALIAS-doc ALIAS-mac], + but it doesn't look intentional, so I'd rather return something + meaningful or nothing at all. */ + return Qnil; +} + static Lisp_Object subsidiary_coding_system (Lisp_Object coding_system, enum eol_type type) { @@ -1718,10 +1752,12 @@ do { \ #define DECODE_HANDLE_END_OF_CONVERSION(flags, ch, dst) \ do { \ - DECODE_OUTPUT_PARTIAL_CHAR (ch); \ - if ((flags & CODING_STATE_END) && \ - (flags & CODING_STATE_CR)) \ - Dynarr_add (dst, '\r'); \ + if (flags & CODING_STATE_END) \ + { \ + DECODE_OUTPUT_PARTIAL_CHAR (ch); \ + if (flags & CODING_STATE_CR) \ + Dynarr_add (dst, '\r'); \ + } \ } while (0) #define DECODING_STREAM_DATA(stream) LSTREAM_TYPE_DATA (stream, decoding) @@ -3164,7 +3200,8 @@ Return the UCS code (a positive integer) corresponding to CHARACTER. } /* Decode a UCS-4 character into a buffer. If the lookup fails, use - JIS X 0208 double-width `=' instead. + (U+3013) of JIS X 0208, which means correct character + is not found, instead. #### do something more appropriate (use blob?) Danger, Will Robinson! Data loss. Should we signal user? */ static void @@ -5379,6 +5416,7 @@ syms_of_mule_coding (void) DEFSUBR (Fcoding_system_name); DEFSUBR (Fmake_coding_system); DEFSUBR (Fcopy_coding_system); + DEFSUBR (Fdefine_coding_system_alias); DEFSUBR (Fsubsidiary_coding_system); DEFSUBR (Fcoding_system_type); diff --git a/src/floatfns.c b/src/floatfns.c index 56a78a4..2965f52 100644 --- a/src/floatfns.c +++ b/src/floatfns.c @@ -194,7 +194,7 @@ extract_float (Lisp_Object num) if (INTP (num)) return (double) XINT (num); - return extract_float (wrong_type_argument (num, Qnumberp)); + return extract_float (wrong_type_argument (Qnumberp, num)); } #endif /* LISP_FLOAT_TYPE */ @@ -666,12 +666,12 @@ Return the absolute value of ARG. if (INTP (arg)) return (XINT (arg) >= 0) ? arg : make_int (- XINT (arg)); - return Fabs (wrong_type_argument (arg, Qnumberp)); + return Fabs (wrong_type_argument (Qnumberp, arg)); } #ifdef LISP_FLOAT_TYPE DEFUN ("float", Ffloat, 1, 1, 0, /* -Return the floating point number equal to ARG. +Return the floating point number numerically equal to ARG. */ (arg)) { @@ -681,7 +681,7 @@ Return the floating point number equal to ARG. if (FLOATP (arg)) /* give 'em the same float back */ return arg; - return Ffloat (wrong_type_argument (arg, Qnumberp)); + return Ffloat (wrong_type_argument (Qnumberp, arg)); } #endif /* LISP_FLOAT_TYPE */ @@ -757,7 +757,7 @@ Return the smallest integer no less than ARG. (Round toward +inf.) if (INTP (arg)) return arg; - return Fceiling (wrong_type_argument (arg, Qnumberp)); + return Fceiling (wrong_type_argument (Qnumberp, arg)); } @@ -834,7 +834,7 @@ Return the nearest integer to ARG. if (INTP (arg)) return arg; - return Fround (wrong_type_argument (arg, Qnumberp)); + return Fround (wrong_type_argument (Qnumberp, arg)); } DEFUN ("truncate", Ftruncate, 1, 1, 0, /* @@ -851,7 +851,7 @@ Rounds the value toward zero. if (INTP (arg)) return arg; - return Ftruncate (wrong_type_argument (arg, Qnumberp)); + return Ftruncate (wrong_type_argument (Qnumberp, arg)); } /* Float-rounding functions. */ diff --git a/src/fns.c b/src/fns.c index c1fa079..e4fb1a1 100644 --- a/src/fns.c +++ b/src/fns.c @@ -2678,7 +2678,7 @@ See also `get', `remprop', and `object-plist'. (object, propname, value)) { CHECK_SYMBOL (propname); - CHECK_IMPURE (object); + CHECK_LISP_WRITEABLE (object); if (SYMBOLP (object)) symbol_putprop (object, propname, value); @@ -2723,7 +2723,7 @@ was present in the property list). See also `get', `put', and int retval = 0; CHECK_SYMBOL (propname); - CHECK_IMPURE (object); + CHECK_LISP_WRITEABLE (object); if (SYMBOLP (object)) retval = symbol_remprop (object, propname); @@ -2786,47 +2786,12 @@ internal_equal (Lisp_Object obj1, Lisp_Object obj2, int depth) { if (depth > 200) error ("Stack overflow in equal"); -#ifndef LRECORD_CONS - do_cdr: -#endif QUIT; if (EQ_WITH_EBOLA_NOTICE (obj1, obj2)) return 1; /* Note that (equal 20 20.0) should be nil */ if (XTYPE (obj1) != XTYPE (obj2)) return 0; -#ifndef LRECORD_CONS - if (CONSP (obj1)) - { - if (!internal_equal (XCAR (obj1), XCAR (obj2), depth + 1)) - return 0; - obj1 = XCDR (obj1); - obj2 = XCDR (obj2); - goto do_cdr; - } -#endif -#ifndef LRECORD_VECTOR - if (VECTORP (obj1)) - { - Lisp_Object *v1 = XVECTOR_DATA (obj1); - Lisp_Object *v2 = XVECTOR_DATA (obj2); - int len = XVECTOR_LENGTH (obj1); - if (len != XVECTOR_LENGTH (obj2)) - return 0; - while (len--) - if (!internal_equal (*v1++, *v2++, depth + 1)) - return 0; - return 1; - } -#endif -#ifndef LRECORD_STRING - if (STRINGP (obj1)) - { - Bytecount len; - return (((len = XSTRING_LENGTH (obj1)) == XSTRING_LENGTH (obj2)) && - !memcmp (XSTRING_DATA (obj1), XSTRING_DATA (obj2), len)); - } -#endif if (LRECORDP (obj1)) { CONST struct lrecord_implementation @@ -2851,39 +2816,12 @@ internal_old_equal (Lisp_Object obj1, Lisp_Object obj2, int depth) { if (depth > 200) error ("Stack overflow in equal"); -#ifndef LRECORD_CONS - do_cdr: -#endif QUIT; if (HACKEQ_UNSAFE (obj1, obj2)) return 1; /* Note that (equal 20 20.0) should be nil */ if (XTYPE (obj1) != XTYPE (obj2)) return 0; -#ifndef LRECORD_CONS - if (CONSP (obj1)) - { - if (!internal_old_equal (XCAR (obj1), XCAR (obj2), depth + 1)) - return 0; - obj1 = XCDR (obj1); - obj2 = XCDR (obj2); - goto do_cdr; - } -#endif -#ifndef LRECORD_VECTOR - if (VECTORP (obj1)) - { - Lisp_Object *v1 = XVECTOR_DATA (obj1); - Lisp_Object *v2 = XVECTOR_DATA (obj2); - int len = XVECTOR_LENGTH (obj1); - if (len != XVECTOR_LENGTH (obj2)) - return 0; - while (len--) - if (!internal_old_equal (*v1++, *v2++, depth + 1)) - return 0; - return 1; - } -#endif return internal_equal (obj1, obj2, depth); } @@ -2929,7 +2867,7 @@ ARRAY is a vector, bit vector, or string. Charcount len = string_char_length (s); Charcount i; CHECK_CHAR_COERCE_INT (item); - CHECK_IMPURE (array); + CHECK_LISP_WRITEABLE (array); charval = XCHAR (item); for (i = 0; i < len; i++) set_string_char (s, i, charval); @@ -2939,7 +2877,7 @@ ARRAY is a vector, bit vector, or string. { Lisp_Object *p = XVECTOR_DATA (array); int len = XVECTOR_LENGTH (array); - CHECK_IMPURE (array); + CHECK_LISP_WRITEABLE (array); while (len--) *p++ = item; } @@ -2949,7 +2887,7 @@ ARRAY is a vector, bit vector, or string. int len = bit_vector_length (v); int bit; CHECK_BIT (item); - CHECK_IMPURE (array); + CHECK_LISP_WRITEABLE (array); bit = XINT (item); while (len--) set_bit_vector_bit (v, len, bit); @@ -3570,11 +3508,6 @@ base64_encode_1 (Lstream *istream, Bufbyte *to, int line_break) (ec = Lstream_get_emchar (stream), \ ec == -1 ? 0 : (c = (Bufbyte)ec, 1)) -#define INPUT_EOF_P(stream) \ - (ADVANCE_INPUT (c2, stream) \ - ? (Lstream_unget_emchar (stream, (Emchar)c2), 0) \ - : 1) - #define STORE_BYTE(pos, val) do { \ pos += set_charptr_emchar (pos, (Emchar)((unsigned char)(val))); \ ++*ccptr; \ @@ -3583,7 +3516,6 @@ base64_encode_1 (Lstream *istream, Bufbyte *to, int line_break) static Bytind base64_decode_1 (Lstream *istream, Bufbyte *to, Charcount *ccptr) { - EMACS_INT counter = 0; Emchar ec; Bufbyte *e = to; unsigned long value; @@ -3591,27 +3523,26 @@ base64_decode_1 (Lstream *istream, Bufbyte *to, Charcount *ccptr) *ccptr = 0; while (1) { - Bufbyte c, c2; + Bufbyte c; if (!ADVANCE_INPUT (c, istream)) break; - /* Accept wrapping lines, reversibly if at each 76 characters. */ + /* Accept wrapping lines. */ + if (c == '\r') + { + if (!ADVANCE_INPUT (c, istream) + || c != '\n') + return -1; + } if (c == '\n') { if (!ADVANCE_INPUT (c, istream)) break; - if (INPUT_EOF_P (istream)) - break; - /* FSF Emacs has this check, apparently inherited from - recode. However, I see no reason to be this picky about - line length -- why reject base64 with say 72-byte lines? - (yes, there are programs that generate them.) */ - /*if (counter != MIME_LINE_LENGTH / 4) return -1;*/ - counter = 1; + /* FSF checks for end of text here, but that's wrong. */ + /* FSF checks for correct line length here; that's also + wrong; some MIME encoders use different line lengths. */ } - else - counter++; /* Process first byte of a quadruplet. */ if (!IS_BASE64 (c)) @@ -3968,4 +3899,6 @@ A list of symbols which are the features of the executing emacs. Used by `featurep' and `require', and altered by `provide'. */ ); Vfeatures = Qnil; + + Fprovide (intern ("base64")); } diff --git a/src/frame-msw.c b/src/frame-msw.c index 653f53f..f48b7af 100644 --- a/src/frame-msw.c +++ b/src/frame-msw.c @@ -308,7 +308,7 @@ mswindows_set_frame_position (struct frame *f, int xoff, int yoff) static void mswindows_make_frame_visible (struct frame *f) { - if (f->iconified) + if (!FRAME_VISIBLE_P(f)) ShowWindow (FRAME_MSWINDOWS_HANDLE(f), SW_RESTORE); else ShowWindow (FRAME_MSWINDOWS_HANDLE(f), SW_SHOW); @@ -319,8 +319,11 @@ mswindows_make_frame_visible (struct frame *f) static void mswindows_make_frame_invisible (struct frame *f) { + if (!FRAME_VISIBLE_P(f)) + return; + ShowWindow (FRAME_MSWINDOWS_HANDLE(f), SW_HIDE); - f->visible = -1; + f->visible = 0; } static int diff --git a/src/frame.c b/src/frame.c index 6c7fde4..2fcd539 100644 --- a/src/frame.c +++ b/src/frame.c @@ -175,7 +175,7 @@ allocate_frame_core (Lisp_Object device) /* This function can GC */ Lisp_Object frame; Lisp_Object root_window; - struct frame *f = alloc_lcrecord_type (struct frame, lrecord_frame); + struct frame *f = alloc_lcrecord_type (struct frame, &lrecord_frame); zero_lcrecord (f); nuke_all_frame_slots (f); diff --git a/src/getloadavg.c b/src/getloadavg.c index 39c45e6..b8161e4 100644 --- a/src/getloadavg.c +++ b/src/getloadavg.c @@ -19,8 +19,6 @@ 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. */ -#ifndef __CYGWIN32__ - /* Compile-time symbols that this file uses: FIXUP_KERNEL_SYMBOL_ADDR() Adjust address in returned struct nlist. @@ -71,6 +69,9 @@ Boston, MA 02111-1307, USA. */ #include #endif +#ifndef WINDOWSNT +#ifndef __CYGWIN32__ + #include /* Both the Emacs and non-Emacs sections want this. Some @@ -1006,4 +1007,4 @@ getloadavg (double loadavg[], int nelem) } #endif /*__GNUWIN32__*/ - +#endif /* WINDOWSNT */ diff --git a/src/glyphs-msw.c b/src/glyphs-msw.c index e4d6a16..646cb54 100644 --- a/src/glyphs-msw.c +++ b/src/glyphs-msw.c @@ -247,13 +247,13 @@ mswindows_locate_pixmap_file (Lisp_Object name) return Qnil; } - if (locate_file (Vmswindows_bitmap_file_path, name, "", &found, R_OK) < 0) + if (locate_file (Vmswindows_bitmap_file_path, name, Qnil, &found, R_OK) < 0) { Lisp_Object temp = list1 (Vdata_directory); struct gcpro gcpro1; GCPRO1 (temp); - locate_file (temp, name, "", &found, R_OK); + locate_file (temp, name, Qnil, &found, R_OK); UNGCPRO; } diff --git a/src/glyphs-x.c b/src/glyphs-x.c index 6d5f750..bbe3cf1 100644 --- a/src/glyphs-x.c +++ b/src/glyphs-x.c @@ -513,13 +513,13 @@ x_locate_pixmap_file (Lisp_Object name) { Lisp_Object found; - if (locate_file (Vx_bitmap_file_path, name, "", &found, R_OK) < 0) + if (locate_file (Vx_bitmap_file_path, name, Qnil, &found, R_OK) < 0) { Lisp_Object temp = list1 (Vdata_directory); struct gcpro gcpro1; GCPRO1 (temp); - locate_file (temp, name, "", &found, R_OK); + locate_file (temp, name, Qnil, &found, R_OK); UNGCPRO; } diff --git a/src/glyphs.c b/src/glyphs.c index 5acac8d..d92508e 100644 --- a/src/glyphs.c +++ b/src/glyphs.c @@ -917,7 +917,7 @@ static Lisp_Object allocate_image_instance (Lisp_Object device) { struct Lisp_Image_Instance *lp = - alloc_lcrecord_type (struct Lisp_Image_Instance, lrecord_image_instance); + alloc_lcrecord_type (struct Lisp_Image_Instance, &lrecord_image_instance); Lisp_Object val; zero_lcrecord (lp); @@ -2940,7 +2940,7 @@ allocate_glyph (enum glyph_type type, /* This function can GC */ Lisp_Object obj = Qnil; struct Lisp_Glyph *g = - alloc_lcrecord_type (struct Lisp_Glyph, lrecord_glyph); + alloc_lcrecord_type (struct Lisp_Glyph, &lrecord_glyph); g->type = type; g->image = Fmake_specifier (Qimage); /* This function can GC */ diff --git a/src/gui-x.c b/src/gui-x.c index 9921504..3fb2e85 100644 --- a/src/gui-x.c +++ b/src/gui-x.c @@ -123,7 +123,7 @@ gcpro_popup_callbacks (LWLIB_ID id) Lisp_Object lpdata; assert (NILP (assq_no_quit (lid, Vpopup_callbacks))); - pdata = alloc_lcrecord_type (struct popup_data, lrecord_popup_data); + pdata = alloc_lcrecord_type (struct popup_data, &lrecord_popup_data); pdata->id = id; pdata->last_menubar_buffer = Qnil; pdata->menubar_contents_up_to_date = 0; diff --git a/src/keymap.c b/src/keymap.c index 2b5a18e..9f62801 100644 --- a/src/keymap.c +++ b/src/keymap.c @@ -742,7 +742,7 @@ static Lisp_Object make_keymap (size_t size) { Lisp_Object result; - Lisp_Keymap *keymap = alloc_lcrecord_type (Lisp_Keymap, lrecord_keymap); + Lisp_Keymap *keymap = alloc_lcrecord_type (Lisp_Keymap, &lrecord_keymap); XSETKEYMAP (result, keymap); @@ -4319,7 +4319,7 @@ Incremented for each change to any keymap. staticpro (&Vcurrent_global_map); - Vsingle_space_string = make_pure_string ((CONST Bufbyte *) " ", 1, Qnil, 1); + Vsingle_space_string = make_string_nocopy ((CONST Bufbyte *) " ", 1); staticpro (&Vsingle_space_string); } diff --git a/src/lisp-disunion.h b/src/lisp-disunion.h index 6ca10ef..f2c321b 100644 --- a/src/lisp-disunion.h +++ b/src/lisp-disunion.h @@ -25,8 +25,6 @@ Boston, MA 02111-1307, USA. */ /* Format of a non-union-type Lisp Object - For the USE_MINIMAL_TAGBITS implementation: - 3 2 1 0 bit 10987654321098765432109876543210 -------------------------------- @@ -39,61 +37,32 @@ Boston, MA 02111-1307, USA. */ -------------------------------- VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVT - For the non-USE_MINIMAL_TAGBITS implementation: - - 3 2 1 0 - bit 10987654321098765432109876543210 - -------------------------------- - TTTMVVVVVVVVVVVVVVVVVVVVVVVVVVVV - - V = value bits - T = type bits - M = mark bits - For integral Lisp types, i.e. integers and characters, the value bits are the Lisp object. - The object is obtained by masking off the type and mark - bits. In the USE_MINIMAL_TAGBITS implementation, bit 1 is - used as a value bit by splitting the Lisp integer type into - two subtypes, Lisp_Type_Int_Even and Lisp_Type_Int_Odd. By + The object is obtained by masking off the type and mark bits. + Bit 1 is used as a value bit by splitting the Lisp integer type + into two subtypes, Lisp_Type_Int_Even and Lisp_Type_Int_Odd. By this trickery we get 31 bits for integers instead of 30. - In the non-USE_MINIMAL_TAGBITS world, Lisp integers are 28 bits, - or more properly (BITS_PER_EMACS_INT - GCTYPEBITS - 1) bits. - For non-integral types, the value bits of a Lisp_Object contain a pointer to a structure containing the object. The pointer is obtained by masking off the type and mark bits. - In the USE_MINIMAL_TAGBITS implementation, all - pointer-based types are coalesced under a single type called + All pointer-based types are coalesced under a single type called Lisp_Type_Record. The type bits for this type are required by the implementation to be 00, just like the least significant bits of word-aligned struct pointers on 32-bit hardware. Because of this, Lisp_Object pointers don't have to be masked and are full-sized. - In the non-USE_MINIMAL_TAGBITS implementation, the type and - mark bits must be masked off and pointers are limited to 28 - bits (really BITS_PER_EMACS_INT - GCTYPEBITS - 1 bits). - - There are no mark bits in the USE_MINIMAL_TAGBITS implementation. + There are no mark bits. Integers and characters don't need to be marked. All other types are lrecord-based, which means they get marked by incrementing their ->implementation pointer. - In the non-USE_MINIMAL_TAGBITS implementation, the markbit is stored - in the Lisp_Object itself. It is stored in the middle so that the - type bits can be obtained by simply shifting them. - - Outside of garbage collection, all mark bits are always zero. - Here is a brief description of the following macros: - XMARKBIT Extract the mark bit (non-USE_MINIMAL_TAGBITS) - XMARK Set the mark bit of this Lisp_Object (non-USE_MINIMAL_TAGBITS) - XUNMARK Clear the mark bit of this Lisp_Object (non-USE_MINIMAL_TAGBITS) XTYPE The type bits of a Lisp_Object XPNTRVAL The value bits of a Lisp_Object storing a pointer XCHARVAL The value bits of a Lisp_Object storing a Emchar @@ -102,48 +71,22 @@ Boston, MA 02111-1307, USA. */ INTP Non-zero if this Lisp_Object an integer? Qzero Lisp Integer 0 EQ Non-zero if two Lisp_Objects are identical - GC_EQ Version of EQ used during garbage collection -*/ + GC_EQ Version of EQ used during garbage collection */ typedef EMACS_INT Lisp_Object; -#ifdef USE_MINIMAL_TAGBITS - -# define Lisp_Type_Int_Bit (Lisp_Type_Int_Even & Lisp_Type_Int_Odd) -# define XUNMARK(x) DO_NOTHING -# define make_obj(vartype, x) ((Lisp_Object) (x)) -# define make_int(x) ((Lisp_Object) (((x) << INT_GCBITS) | Lisp_Type_Int_Bit)) -# define make_char(x) ((Lisp_Object) (((x) << GCBITS) | Lisp_Type_Char)) -# define VALMASK (((1UL << VALBITS) - 1UL) << GCTYPEBITS) -# define XTYPE(x) ((enum Lisp_Type) (((EMACS_UINT)(x)) & ~VALMASK)) -# define XPNTRVAL(x) (x) /* This depends on Lisp_Type_Record == 0 */ -# define XCHARVAL(x) ((x) >> GCBITS) -# define GC_EQ(x,y) EQ (x,y) -# define XREALINT(x) ((x) >> INT_GCBITS) -# define XUINT(x) ((EMACS_UINT)(x) >> INT_GCBITS) -# define INTP(x) ((EMACS_UINT)(x) & Lisp_Type_Int_Bit) - -#else /* !USE_MINIMAL_TAGBITS */ - -# define MARKBIT (1UL << VALBITS) -# define XMARKBIT(x) (((x) & MARKBIT) != 0) -# define XMARK(x) ((void) ((x) |= MARKBIT)) -# define XUNMARK(x) ((void) ((x) &= ~MARKBIT)) -# define make_obj(vartype, value) \ - ((Lisp_Object) (((EMACS_UINT) (vartype) << (VALBITS + GCMARKBITS)) \ - + ((EMACS_UINT) (value) & VALMASK))) -# define make_int(value) make_obj (Lisp_Type_Int, value) -# define make_char(value) make_obj (Lisp_Type_Char, value) -# define VALMASK ((1UL << VALBITS) - 1UL) -# define XTYPE(x) ((enum Lisp_Type) (((EMACS_UINT)(x)) >> (VALBITS + GCMARKBITS))) -# define XPNTRVAL(x) ((x) & VALMASK) -# define XCHARVAL(x) XPNTRVAL(x) -# define GC_EQ(x,y) (((x) & ~MARKBIT) == ((y) & ~MARKBIT)) -# define XREALINT(x) (((x) << INT_GCBITS) >> INT_GCBITS) -# define XUINT(x) ((EMACS_UINT) ((x) & VALMASK)) -# define INTP(x) (XTYPE (x) == Lisp_Type_Int) - -#endif /* !USE_MINIMAL_TAGBITS */ +#define Lisp_Type_Int_Bit (Lisp_Type_Int_Even & Lisp_Type_Int_Odd) +#define make_obj(vartype, x) ((Lisp_Object) (x)) +#define make_int(x) ((Lisp_Object) (((x) << INT_GCBITS) | Lisp_Type_Int_Bit)) +#define make_char(x) ((Lisp_Object) (((x) << GCBITS) | Lisp_Type_Char)) +#define VALMASK (((1UL << VALBITS) - 1UL) << GCTYPEBITS) +#define XTYPE(x) ((enum Lisp_Type) (((EMACS_UINT)(x)) & ~VALMASK)) +#define XPNTRVAL(x) (x) /* This depends on Lisp_Type_Record == 0 */ +#define XCHARVAL(x) ((x) >> GCBITS) +#define GC_EQ(x,y) EQ (x,y) +#define XREALINT(x) ((x) >> INT_GCBITS) +#define XUINT(x) ((EMACS_UINT)(x) >> INT_GCBITS) +#define INTP(x) ((EMACS_UINT)(x) & Lisp_Type_Int_Bit) #define Qzero make_int (0) #define Qnull_pointer ((Lisp_Object) 0) diff --git a/src/lisp-union.h b/src/lisp-union.h index 94461e6..a04c689 100644 --- a/src/lisp-union.h +++ b/src/lisp-union.h @@ -23,20 +23,17 @@ Boston, MA 02111-1307, USA. */ /* Definition of Lisp_Object type as a union. The declaration order of the objects within the struct members - of the union is dependent on ENDIAN-ness and USE_MINIMAL_TAGBITS. + of the union is dependent on ENDIAN-ness. See lisp-disunion.h for more details. */ typedef union Lisp_Object { /* if non-valbits are at lower addresses */ -#if defined(WORDS_BIGENDIAN) == defined(USE_MINIMAL_TAGBITS) +#if defined(WORDS_BIGENDIAN) struct { EMACS_UINT val : VALBITS; -#if GCMARKBITS > 0 - unsigned int markbit: GCMARKBITS; -#endif enum_field (Lisp_Type) type : GCTYPEBITS; } gu; @@ -55,9 +52,6 @@ union Lisp_Object struct { enum_field (Lisp_Type) type : GCTYPEBITS; -#if GCMARKBITS > 0 - unsigned int markbit: GCMARKBITS; -#endif EMACS_UINT val : VALBITS; } gu; @@ -88,8 +82,6 @@ Lisp_Object; #define XCHARVAL(x) ((x).gu.val) -#ifdef USE_MINIMAL_TAGBITS - # define XSETINT(var, value) do { \ EMACS_INT xset_value = (value); \ Lisp_Object *xset_var = &(var); \ @@ -108,21 +100,6 @@ Lisp_Object; } while (0) # define XPNTRVAL(x) ((x).ui) -#else /* ! USE_MINIMAL_TAGBITS */ - -# define XSETOBJ(var, vartype, value) do { \ - EMACS_UINT xset_value = (EMACS_UINT) (value); \ - Lisp_Object *xset_var = &(var); \ - xset_var->gu.type = (vartype); \ - xset_var->gu.markbit = 0; \ - xset_var->gu.val = xset_value; \ -} while (0) -# define XSETINT(var, value) XSETOBJ (var, Lisp_Type_Int, value) -# define XSETCHAR(var, value) XSETOBJ (var, Lisp_Type_Char, value) -# define XPNTRVAL(x) ((x).gu.val) - -#endif /* ! USE_MINIMAL_TAGBITS */ - INLINE Lisp_Object make_int (EMACS_INT val); INLINE Lisp_Object make_int (EMACS_INT val) @@ -149,25 +126,8 @@ extern Lisp_Object Qnull_pointer, Qzero; #define XGCTYPE(x) XTYPE (x) #define EQ(x,y) ((x).v == (y).v) -#ifdef USE_MINIMAL_TAGBITS #define INTP(x) ((x).s.bits) #define GC_EQ(x,y) EQ (x, y) -#else -#define INTP(x) (XTYPE(x) == Lisp_Type_Int) -#define GC_EQ(x,y) ((x).gu.val == (y).gu.val && XTYPE (x) == XTYPE (y)) -#endif - -#if GCMARKBITS > 0 -/* XMARKBIT accesses the markbit. Markbits are used only in - particular slots of particular structure types. Other markbits are - always zero. Outside of garbage collection, all mark bits are - always zero. */ -# define XMARKBIT(x) ((x).gu.markbit) -# define XMARK(x) ((void) (XMARKBIT (x) = 1)) -# define XUNMARK(x) ((void) (XMARKBIT (x) = 0)) -#else -# define XUNMARK(x) DO_NOTHING -#endif /* Convert between a (void *) and a Lisp_Object, as when the Lisp_Object is passed to a toolkit callback function */ diff --git a/src/lisp.h b/src/lisp.h index 5a990c3..dfe1958 100644 --- a/src/lisp.h +++ b/src/lisp.h @@ -506,59 +506,10 @@ enum munge_me_out_the_door /* Definition of Lisp_Object data type */ /************************************************************************/ -#ifdef USE_MINIMAL_TAGBITS -# define LRECORD_CONS -# define LRECORD_VECTOR -# define LRECORD_SYMBOL -# define LRECORD_STRING -#endif - /* Define the fundamental Lisp data structures */ /* This is the set of Lisp data types */ -#ifndef USE_MINIMAL_TAGBITS - -enum Lisp_Type -{ - /* XRECORD_LHEADER (object) points to a struct lrecord_header - lheader->implementation determines the type (and GC behavior) - of the object. */ - Lisp_Type_Record, - - /* Integer. XINT(obj) is the integer value. */ - Lisp_Type_Int, - -#ifndef LRECORD_CONS - /* Cons. XCONS (object) points to a struct Lisp_Cons. */ - Lisp_Type_Cons, -#endif - -#ifndef LRECORD_STRING - /* String. XSTRING (object) points to a struct Lisp_String. - The length of the string, and its contents, are stored therein. */ - Lisp_Type_String, -#endif - -#ifndef LRECORD_VECTOR - /* Vector of Lisp objects. XVECTOR(object) points to a struct Lisp_Vector. - The length of the vector, and its contents, are stored therein. */ - Lisp_Type_Vector, -#endif /* !LRECORD_VECTOR */ - -#ifndef LRECORD_SYMBOL - /* Symbol. XSYMBOL (object) points to a struct Lisp_Symbol. */ - Lisp_Type_Symbol, -#endif /* !LRECORD_SYMBOL */ - - Lisp_Type_Char -}; - -# define POINTER_TYPE_P(type) \ - ((type) != Lisp_Type_Int && (type) != Lisp_Type_Char) - -#else /* USE_MINIMAL_TAGBITS */ - enum Lisp_Type { Lisp_Type_Record, @@ -569,8 +520,6 @@ enum Lisp_Type #define POINTER_TYPE_P(type) ((type) == Lisp_Type_Record) -#endif /* USE_MINIMAL_TAGBITS */ - /* EMACS_INT is the underlying integral type into which a Lisp_Object must fit. In particular, it must be large enough to contain a pointer. config.h can override this, e.g. to use `long long' for bigger lisp ints. */ @@ -602,17 +551,10 @@ enum Lisp_Type # define ASSERT_VALID_POINTER(pnt) (assert ((((EMACS_UINT) pnt) & 3) == 0)) #endif -#ifdef USE_MINIMAL_TAGBITS -# define GCMARKBITS 0 -# define GCTYPEBITS 2 -# define GCBITS 2 -# define INT_GCBITS 1 -#else -# define GCMARKBITS 1 -# define GCTYPEBITS 3 -# define GCBITS 4 -# define INT_GCBITS GCBITS -#endif +#define GCMARKBITS 0 +#define GCTYPEBITS 2 +#define GCBITS 2 +#define INT_GCBITS 1 #define INT_VALBITS (BITS_PER_EMACS_INT - INT_GCBITS) #define VALBITS (BITS_PER_EMACS_INT - GCBITS) @@ -624,25 +566,7 @@ enum Lisp_Type # include "lisp-disunion.h" #endif /* !USE_UNION_TYPE */ -#ifdef HAVE_SHM -/* In this representation, data is found in two widely separated segments. */ -extern int pure_size; -# define XPNTR(x) \ - ((void *)(XPNTRVAL(x)) | (XPNTRVAL(x) > pure_size ? DATA_SEG_BITS : PURE_SEG_BITS))) -#else /* not HAVE_SHM */ -# ifdef DATA_SEG_BITS -/* This case is used for the rt-pc and hp-pa. - In the diffs I was given, it checked for ptr = 0 - and did not adjust it in that case. - But I don't think that zero should ever be found - in a Lisp object whose data type says it points to something. - */ -# define XPNTR(x) ((void *)((XPNTRVAL(x)) | DATA_SEG_BITS)) -# else /* not DATA_SEG_BITS */ -# define XPNTR(x) ((void *) (XPNTRVAL(x))) -# endif /* not DATA_SEG_BITS */ -#endif /* not HAVE_SHM */ - +#define XPNTR(x) ((void *) (XPNTRVAL(x))) /* WARNING WARNING WARNING. You must ensure on your own that proper GC protection is provided for the elements in this array. */ @@ -693,9 +617,7 @@ int eq_with_ebola_notice (Lisp_Object, Lisp_Object); struct Lisp_Cons { -#ifdef LRECORD_CONS struct lrecord_header lheader; -#endif Lisp_Object car, cdr; }; typedef struct Lisp_Cons Lisp_Cons; @@ -712,8 +634,6 @@ struct Lisp_Buffer_Cons }; #endif -#ifdef LRECORD_CONS - DECLARE_LRECORD (cons, Lisp_Cons); #define XCONS(x) XRECORD (x, cons, Lisp_Cons) #define XSETCONS(x, p) XSETRECORD (x, p, cons) @@ -725,23 +645,6 @@ DECLARE_LRECORD (cons, Lisp_Cons); #define CONS_MARKED_P(c) MARKED_RECORD_HEADER_P(&((c)->lheader)) #define MARK_CONS(c) MARK_RECORD_HEADER (&((c)->lheader)) -#else /* ! LRECORD_CONS */ - -DECLARE_NONRECORD (cons, Lisp_Type_Cons, Lisp_Cons); -#define XCONS(a) XNONRECORD (a, cons, Lisp_Type_Cons, Lisp_Cons) -#define XSETCONS(c, p) XSETOBJ (c, Lisp_Type_Cons, p) -#define CONSP(x) (XTYPE (x) == Lisp_Type_Cons) -#define GC_CONSP(x) (XGCTYPE (x) == Lisp_Type_Cons) -#define CHECK_CONS(x) CHECK_NONRECORD (x, Lisp_Type_Cons, Qconsp) -#define CONCHECK_CONS(x) CONCHECK_NONRECORD (x, Lisp_Type_Cons, Qconsp) - -/* Define these because they're used in a few places, inside and - out of alloc.c */ -#define CONS_MARKED_P(c) XMARKBIT (c->car) -#define MARK_CONS(c) XMARK (c->car) - -#endif /* ! LRECORD_CONS */ - extern Lisp_Object Qnil; #define NILP(x) EQ (x, Qnil) @@ -1051,21 +954,15 @@ TRUE_LIST_P (Lisp_Object object) /*********** string ***********/ -/* In a string, the markbit of the plist is used as the gc mark bit */ - struct Lisp_String { -#ifdef LRECORD_STRING struct lrecord_header lheader; -#endif Bytecount size; Bufbyte *data; Lisp_Object plist; }; typedef struct Lisp_String Lisp_String; -#ifdef LRECORD_STRING - DECLARE_LRECORD (string, Lisp_String); #define XSTRING(x) XRECORD (x, string, Lisp_String) #define XSETSTRING(x, p) XSETRECORD (x, p, string) @@ -1074,18 +971,6 @@ DECLARE_LRECORD (string, Lisp_String); #define CHECK_STRING(x) CHECK_RECORD (x, string) #define CONCHECK_STRING(x) CONCHECK_RECORD (x, string) -#else /* ! LRECORD_STRING */ - -DECLARE_NONRECORD (string, Lisp_Type_String, Lisp_String); -#define XSTRING(x) XNONRECORD (x, string, Lisp_Type_String, Lisp_String) -#define XSETSTRING(x, p) XSETOBJ (x, Lisp_Type_String, p) -#define STRINGP(x) (XTYPE (x) == Lisp_Type_String) -#define GC_STRINGP(x) (XGCTYPE (x) == Lisp_Type_String) -#define CHECK_STRING(x) CHECK_NONRECORD (x, Lisp_Type_String, Qstringp) -#define CONCHECK_STRING(x) CONCHECK_NONRECORD (x, Lisp_Type_String, Qstringp) - -#endif /* ! LRECORD_STRING */ - #ifdef MULE Charcount bytecount_to_charcount (CONST Bufbyte *ptr, Bytecount len); @@ -1138,9 +1023,7 @@ void set_string_char (Lisp_String *s, Charcount i, Emchar c); struct Lisp_Vector { -#ifdef LRECORD_VECTOR struct lcrecord_header header; -#endif long size; /* next is now chained through v->contents[size], terminated by Qzero. This means that pure vectors don't need a "next" */ @@ -1149,8 +1032,6 @@ struct Lisp_Vector }; typedef struct Lisp_Vector Lisp_Vector; -#ifdef LRECORD_VECTOR - DECLARE_LRECORD (vector, Lisp_Vector); #define XVECTOR(x) XRECORD (x, vector, Lisp_Vector) #define XSETVECTOR(x, p) XSETRECORD (x, p, vector) @@ -1159,25 +1040,10 @@ DECLARE_LRECORD (vector, Lisp_Vector); #define CHECK_VECTOR(x) CHECK_RECORD (x, vector) #define CONCHECK_VECTOR(x) CONCHECK_RECORD (x, vector) -#else - -DECLARE_NONRECORD (vector, Lisp_Type_Vector, Lisp_Vector); -#define XVECTOR(x) XNONRECORD (x, vector, Lisp_Type_Vector, Lisp_Vector) -#define XSETVECTOR(x, p) XSETOBJ (x, Lisp_Type_Vector, p) -#define VECTORP(x) (XTYPE (x) == Lisp_Type_Vector) -#define GC_VECTORP(x) (XGCTYPE (x) == Lisp_Type_Vector) -#define CHECK_VECTOR(x) CHECK_NONRECORD (x, Lisp_Type_Vector, Qvectorp) -#define CONCHECK_VECTOR(x) CONCHECK_NONRECORD (x, Lisp_Type_Vector, Qvectorp) - -#endif - #define vector_length(v) ((v)->size) #define XVECTOR_LENGTH(s) vector_length (XVECTOR (s)) #define vector_data(v) ((v)->contents) #define XVECTOR_DATA(s) vector_data (XVECTOR (s)) -#ifndef LRECORD_VECTOR -# define vector_next(v) ((v)->contents[(v)->size]) -#endif /*********** bit vector ***********/ @@ -1257,29 +1123,25 @@ set_bit_vector_bit (Lisp_Bit_Vector *v, int i, int value) /*********** symbol ***********/ -/* In a symbol, the markbit of the plist is used as the gc mark bit */ - struct Lisp_Symbol { -#ifdef LRECORD_SYMBOL struct lrecord_header lheader; -#endif /* next symbol in this obarray bucket */ struct Lisp_Symbol *next; struct Lisp_String *name; Lisp_Object value; Lisp_Object function; - /* non-nil if the symbol is interned in Vobarray */ - Lisp_Object obarray; Lisp_Object plist; }; typedef struct Lisp_Symbol Lisp_Symbol; -#define SYMBOL_IS_KEYWORD(sym) (string_byte (XSYMBOL(sym)->name, 0) == ':') +#define SYMBOL_IS_KEYWORD(sym) \ + ((string_byte (symbol_name (XSYMBOL (sym)), 0) == ':') \ + && EQ (sym, oblookup (Vobarray, \ + string_data (symbol_name (XSYMBOL (sym))), \ + string_length (symbol_name (XSYMBOL (sym)))))) #define KEYWORDP(obj) (SYMBOLP (obj) && SYMBOL_IS_KEYWORD (obj)) -#ifdef LRECORD_SYMBOL - DECLARE_LRECORD (symbol, Lisp_Symbol); #define XSYMBOL(x) XRECORD (x, symbol, Lisp_Symbol) #define XSETSYMBOL(x, p) XSETRECORD (x, p, symbol) @@ -1288,18 +1150,6 @@ DECLARE_LRECORD (symbol, Lisp_Symbol); #define CHECK_SYMBOL(x) CHECK_RECORD (x, symbol) #define CONCHECK_SYMBOL(x) CONCHECK_RECORD (x, symbol) -#else - -DECLARE_NONRECORD (symbol, Lisp_Type_Symbol, Lisp_Symbol); -#define XSYMBOL(x) XNONRECORD (x, symbol, Lisp_Type_Symbol, Lisp_Symbol) -#define XSETSYMBOL(s, p) XSETOBJ ((s), Lisp_Type_Symbol, (p)) -#define SYMBOLP(x) (XTYPE (x) == Lisp_Type_Symbol) -#define GC_SYMBOLP(x) (XGCTYPE (x) == Lisp_Type_Symbol) -#define CHECK_SYMBOL(x) CHECK_NONRECORD (x, Lisp_Type_Symbol, Qsymbolp) -#define CONCHECK_SYMBOL(x) CONCHECK_NONRECORD (x, Lisp_Type_Symbol, Qsymbolp) - -#endif - #define symbol_next(s) ((s)->next) #define symbol_name(s) ((s)->name) #define symbol_value(s) ((s)->value) @@ -1528,10 +1378,16 @@ XCHAR_OR_INT (Lisp_Object obj) } while (0) -/*********** pure space ***********/ +/*********** readonly objects ***********/ + +#define CHECK_C_WRITEABLE(obj) \ + do { if (c_readonly (obj)) c_write_error (obj); } while (0) -#define CHECK_IMPURE(obj) \ - do { if (purified (obj)) pure_write_error (obj); } while (0) +#define CHECK_LISP_WRITEABLE(obj) \ + do { if (lisp_readonly (obj)) lisp_write_error (obj); } while (0) + +#define C_READONLY(obj) (C_READONLY_RECORD_HEADER_P(XRECORD_LHEADER (obj))) +#define LISP_READONLY(obj) (LISP_READONLY_RECORD_HEADER_P(XRECORD_LHEADER (obj))) /*********** structures ***********/ @@ -1693,11 +1549,7 @@ Lisp_Object,Lisp_Object,Lisp_Object /* Can't be const, because then subr->doc is read-only and Snarf_documentation chokes */ -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION -# define subr_lheader_initializer { 0, 0, 0 } -#else -# define subr_lheader_initializer { lrecord_subr } -#endif +#define subr_lheader_initializer { 0, { 0, 0, 0 } } #define DEFUN(lname, Fname, min_args, max_args, prompt, arglist) \ Lisp_Object Fname (EXFUN_##max_args); \ @@ -1932,7 +1784,7 @@ void debug_ungcpro(char *, int, struct gcpro *); #define NNGCPRO5(v1,v2,v3,v4,v5) \ debug_gcpro5 (__FILE__, __LINE__,&nngcpro1,&nngcpro2,&nngcpro3,&nngcpro4,\ &nngcpro5,&v1,&v2,&v3,&v4,&v5) -#define NUNNGCPRO \ +#define NNUNGCPRO \ debug_ungcpro(__FILE__, __LINE__,&nngcpro1) #else /* ! DEBUG_GCPRO */ @@ -2184,7 +2036,8 @@ extern int purify_flag; extern int gc_currently_forbidden; Lisp_Object restore_gc_inhibit (Lisp_Object); extern EMACS_INT gc_generation_number[1]; -int purified (Lisp_Object); +int c_readonly (Lisp_Object); +int lisp_readonly (Lisp_Object); Lisp_Object build_string (CONST char *); Lisp_Object build_ext_string (CONST char *, enum external_data_format); Lisp_Object build_translated_string (CONST char *); @@ -2193,13 +2046,7 @@ Lisp_Object make_ext_string (CONST Extbyte *, EMACS_INT, enum external_data_format); Lisp_Object make_uninit_string (Bytecount); Lisp_Object make_float (double); -size_t purespace_usage (void); -void report_pure_usage (int, int); -Lisp_Object make_pure_string (CONST Bufbyte *, Bytecount, Lisp_Object, int); -Lisp_Object make_pure_pname (CONST Bufbyte *, Bytecount, int); -Lisp_Object pure_cons (Lisp_Object, Lisp_Object); -Lisp_Object pure_list (int, Lisp_Object *); -Lisp_Object make_pure_vector (size_t, Lisp_Object); +Lisp_Object make_string_nocopy (CONST Bufbyte *, Bytecount); void free_cons (Lisp_Cons *); void free_list (Lisp_Object); void free_alist (Lisp_Object); @@ -2226,7 +2073,8 @@ char *egetenv (CONST char *); void stuff_buffered_input (Lisp_Object); /* Defined in data.c */ -DECLARE_DOESNT_RETURN (pure_write_error (Lisp_Object)); +DECLARE_DOESNT_RETURN (c_write_error (Lisp_Object)); +DECLARE_DOESNT_RETURN (lisp_write_error (Lisp_Object)); DECLARE_DOESNT_RETURN (args_out_of_range (Lisp_Object, Lisp_Object)); DECLARE_DOESNT_RETURN (args_out_of_range_3 (Lisp_Object, Lisp_Object, Lisp_Object)); @@ -2525,7 +2373,8 @@ void where_is_to_char (Lisp_Object, char *); /* Defined in lread.c */ void ebolify_bytecode_constants (Lisp_Object); void close_load_descs (void); -int locate_file (Lisp_Object, Lisp_Object, CONST char *, Lisp_Object *, int); +int locate_file (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object *, int); +EXFUN (Flocate_file_clear_hashing, 1); int isfloat_string (CONST char *); /* Well, I've decided to enable this. -- ben */ @@ -3049,7 +2898,7 @@ extern Lisp_Object Vmirror_ascii_eqv_table, Vmirror_ascii_upcase_table; extern Lisp_Object Vmodule_directory, Vmswindows_downcase_file_names; extern Lisp_Object Vmswindows_get_true_file_attributes, Vobarray; extern Lisp_Object Vprint_length, Vprint_level, Vprocess_environment; -extern Lisp_Object Vpure_uninterned_symbol_table, Vquit_flag; +extern Lisp_Object Vquit_flag; extern Lisp_Object Vrecent_keys_ring, Vshell_file_name, Vsite_directory; extern Lisp_Object Vsite_module_directory; extern Lisp_Object Vstandard_input, Vstandard_output, Vstdio_str; diff --git a/src/lread.c b/src/lread.c index 479ea25..481f664 100644 --- a/src/lread.c +++ b/src/lread.c @@ -63,9 +63,13 @@ Lisp_Object Qvariable_domain; /* I18N3 */ Lisp_Object Vvalues, Vstandard_input, Vafter_load_alist; Lisp_Object Qcurrent_load_list; Lisp_Object Qload, Qload_file_name; -Lisp_Object Qlocate_file_hash_table; Lisp_Object Qfset; +/* Hash-table that maps directory names to hashes of their contents. */ +static Lisp_Object Vlocate_file_hash_table; + +Lisp_Object Qexists, Qreadable, Qwritable, Qexecutable; + /* See read_escape() for an explanation of this. */ #if 0 int fail_on_bucky_bit_character_escapes; @@ -118,7 +122,7 @@ Lisp_Object Vload_read_function; Each member of the list has the form (n . object), and is used to look up the object for the corresponding #n# construct. It must be set to nil before all top-level calls to read0. */ -Lisp_Object read_objects; +Lisp_Object Vread_objects; /* Nonzero means load should forcibly load all dynamic doc strings. */ /* Note that this always happens (with some special behavior) when @@ -553,7 +557,6 @@ encoding detection or end-of-line detection. int message_p = NILP (nomessage); /*#ifdef DEBUG_XEMACS*/ static Lisp_Object last_file_loaded; - size_t pure_usage = 0; /*#endif*/ struct stat s1, s2; GCPRO3 (file, newer, found); @@ -565,7 +568,6 @@ encoding detection or end-of-line detection. { message_p = 1; last_file_loaded = file; - pure_usage = purespace_usage (); } /*#endif / * DEBUG_XEMACS */ @@ -593,9 +595,9 @@ encoding detection or end-of-line detection. int foundlen; fd = locate_file (Vload_path, file, - ((!NILP (nosuffix)) ? "" : - load_ignore_elc_files ? ".el:" : - ".elc:.el:"), + ((!NILP (nosuffix)) ? Qnil : + build_string (load_ignore_elc_files ? ".el:" : + ".elc:.el:")), &found, -1); @@ -786,12 +788,8 @@ encoding detection or end-of-line detection. /*#ifdef DEBUG_XEMACS*/ if (purify_flag && noninteractive) { - if (EQ (last_file_loaded, file)) - message_append (" (%ld)", - (unsigned long) (purespace_usage() - pure_usage)); - else - message ("Loading %s ...done (%ld)", XSTRING_DATA (file), - (unsigned long) (purespace_usage() - pure_usage)); + if (!EQ (last_file_loaded, file)) + message ("Loading %s ...done", XSTRING_DATA (file)); } /*#endif / * DEBUG_XEMACS */ @@ -803,26 +801,57 @@ encoding detection or end-of-line detection. } -#if 0 /* FSFmacs */ -/* not used */ +/* ------------------------------- */ +/* locate_file */ +/* ------------------------------- */ + static int -complete_filename_p (Lisp_Object pathname) +decode_mode_1 (Lisp_Object mode) { - REGISTER unsigned char *s = XSTRING_DATA (pathname); - return (IS_DIRECTORY_SEP (s[0]) - || (XSTRING_LENGTH (pathname) > 2 - && IS_DEVICE_SEP (s[1]) && IS_DIRECTORY_SEP (s[2])) -#ifdef ALTOS - || *s == '@' -#endif - ); + if (EQ (mode, Qexists)) + return F_OK; + else if (EQ (mode, Qexecutable)) + return X_OK; + else if (EQ (mode, Qwritable)) + return W_OK; + else if (EQ (mode, Qreadable)) + return R_OK; + else if (INTP (mode)) + { + check_int_range (XINT (mode), 0, 7); + return XINT (mode); + } + else + signal_simple_error ("Invalid value", mode); + return 0; /* unreached */ +} + +static int +decode_mode (Lisp_Object mode) +{ + if (NILP (mode)) + return R_OK; + else if (CONSP (mode)) + { + Lisp_Object tail; + int mask = 0; + EXTERNAL_LIST_LOOP (tail, mode) + mask |= decode_mode_1 (XCAR (tail)); + return mask; + } + else + return decode_mode_1 (mode); } -#endif /* 0 */ DEFUN ("locate-file", Flocate_file, 2, 4, 0, /* -Search for FILENAME through PATH-LIST, expanded by one of the optional -SUFFIXES (string of suffixes separated by ":"s), checking for access -MODE (0|1|2|4 = exists|executable|writeable|readable), default readable. +Search for FILENAME through PATH-LIST. + +If SUFFIXES is non-nil, it should be a list of suffixes to append to +file name when searching. + +If MODE is non-nil, it should be a symbol or a list of symbol representing +requirements. Allowed symbols are `exists', `executable', `writable', and +`readable'. If MODE is nil, it defaults to `readable'. `locate-file' keeps hash tables of the directories it searches through, in order to speed things up. It tries valiantly to not get confused in @@ -837,61 +866,207 @@ for details. Lisp_Object tp; CHECK_STRING (filename); - if (!NILP (suffixes)) + + if (LISTP (suffixes)) + { + Lisp_Object tail; + EXTERNAL_LIST_LOOP (tail, suffixes) + CHECK_STRING (XCAR (tail)); + } + else CHECK_STRING (suffixes); - if (!NILP (mode)) - CHECK_NATNUM (mode); - - locate_file (path_list, - filename, - NILP (suffixes) ? "" : (char *) XSTRING_DATA (suffixes), - &tp, - NILP (mode) ? R_OK : XINT (mode)); + + locate_file (path_list, filename, suffixes, &tp, decode_mode (mode)); return tp; } -/* recalculate the hash table for the given string */ +/* Recalculate the hash table for the given string. DIRECTORY should + better have been through Fexpand_file_name() by now. */ static Lisp_Object -locate_file_refresh_hashing (Lisp_Object str) +locate_file_refresh_hashing (Lisp_Object directory) { - Lisp_Object hash = make_directory_hash_table ((char *) XSTRING_DATA (str)); - Fput (str, Qlocate_file_hash_table, hash); + Lisp_Object hash = + make_directory_hash_table ((char *) XSTRING_DATA (directory)); + + if (!NILP (hash)) + Fputhash (directory, hash, Vlocate_file_hash_table); return hash; } -/* find the hash table for the given string, recalculating if necessary */ +/* find the hash table for the given directory, recalculating if necessary */ static Lisp_Object -locate_file_find_directory_hash_table (Lisp_Object str) +locate_file_find_directory_hash_table (Lisp_Object directory) { - Lisp_Object hash = Fget (str, Qlocate_file_hash_table, Qnil); - if (! HASH_TABLEP (hash)) - return locate_file_refresh_hashing (str); - return hash; + Lisp_Object hash = Fgethash (directory, Vlocate_file_hash_table, Qnil); + if (NILP (hash)) + return locate_file_refresh_hashing (directory); + else + return hash; } -/* look for STR in PATH, optionally adding suffixes in SUFFIX */ +/* The SUFFIXES argument in any of the locate_file* functions can be + nil, a list, or a string (for backward compatibility), with the + following semantics: + + a) nil - no suffix, just search for file name intact (semantically + different from "empty suffix list") + b) list - list of suffixes to append to file name. Each of these + must be a string. + c) string - colon-separated suffixes to append to file name (backward + compatibility). + + All of this got hairy, so I decided to use write a mapper. Calling + a function for each suffix shouldn't slow things down, since + locate_file is rarely call with enough suffixes for it to make a + difference. */ + +/* Map FUN over SUFFIXES, as described above. FUN will be called with a + char * containing the current file name, and ARG. Mapping stops when + FUN returns non-zero. */ +void +locate_file_map_suffixes (Lisp_Object filename, Lisp_Object suffixes, + int (*fun) (char *, void *), + void *arg) +{ + /* This function can GC */ + char *fn; + int fn_len, max; + + /* Calculate maximum size of any filename made from + this path element/specified file name and any possible suffix. */ + if (CONSP (suffixes)) + { + /* We must traverse the list, so why not do it right. */ + Lisp_Object tail; + max = 0; + LIST_LOOP (tail, suffixes) + { + if (XSTRING_LENGTH (XCAR (tail)) > max) + max = XSTRING_LENGTH (XCAR (tail)); + } + } + else if (NILP (suffixes)) + max = 0; + else + /* Just take the easy way out */ + max = XSTRING_LENGTH (suffixes); + + fn_len = XSTRING_LENGTH (filename); + fn = (char *) alloca (max + fn_len + 1); + memcpy (fn, (char *) XSTRING_DATA (filename), fn_len); + + /* Loop over suffixes. */ + if (!STRINGP (suffixes)) + { + if (NILP (suffixes)) + { + /* Case a) discussed in the comment above. */ + fn[fn_len] = 0; + if ((*fun) (fn, arg)) + return; + } + else + { + /* Case b) */ + Lisp_Object tail; + LIST_LOOP (tail, suffixes) + { + memcpy (fn + fn_len, XSTRING_DATA (XCAR (tail)), + XSTRING_LENGTH (XCAR (tail))); + fn[fn_len + XSTRING_LENGTH (XCAR (tail))] = 0; + if ((*fun) (fn, arg)) + return; + } + } + } + else + { + /* Case c) */ + CONST char *nsuffix = XSTRING_DATA (suffixes); + + while (1) + { + char *esuffix = (char *) strchr (nsuffix, ':'); + int lsuffix = ((esuffix) ? (esuffix - nsuffix) : strlen (nsuffix)); + + /* Concatenate path element/specified name with the suffix. */ + strncpy (fn + fn_len, nsuffix, lsuffix); + fn[fn_len + lsuffix] = 0; + + if ((*fun) (fn, arg)) + return; + + /* Advance to next suffix. */ + if (esuffix == 0) + break; + nsuffix += lsuffix + 1; + } + } +} + +struct locate_file_in_directory_mapper_closure { + int fd; + Lisp_Object *storeptr; + int mode; +}; static int -locate_file_in_directory (Lisp_Object path, Lisp_Object str, - CONST char *suffix, Lisp_Object *storeptr, +locate_file_in_directory_mapper (char *fn, void *arg) +{ + struct locate_file_in_directory_mapper_closure *closure = + (struct locate_file_in_directory_mapper_closure *)arg; + struct stat st; + + /* Ignore file if it's a directory. */ + if (stat (fn, &st) >= 0 + && (st.st_mode & S_IFMT) != S_IFDIR) + { + /* Check that we can access or open it. */ + if (closure->mode >= 0) + closure->fd = access (fn, closure->mode); + else + closure->fd = open (fn, O_RDONLY | OPEN_BINARY, 0); + + if (closure->fd >= 0) + { + /* We succeeded; return this descriptor and filename. */ + if (closure->storeptr) + *closure->storeptr = build_string (fn); + +#ifndef WINDOWSNT + /* If we actually opened the file, set close-on-exec flag + on the new descriptor so that subprocesses can't whack + at it. */ + if (closure->mode < 0) + (void) fcntl (closure->fd, F_SETFD, FD_CLOEXEC); +#endif + + return 1; + } + } + /* Keep mapping. */ + return 0; +} + + +/* look for STR in PATH, optionally adding SUFFIXES. DIRECTORY need + not have been expanded. */ + +static int +locate_file_in_directory (Lisp_Object directory, Lisp_Object str, + Lisp_Object suffixes, Lisp_Object *storeptr, int mode) { /* This function can GC */ - int fd; - int fn_size = 100; - char buf[100]; - char *fn = buf; - int want_size; - struct stat st; + struct locate_file_in_directory_mapper_closure closure; Lisp_Object filename = Qnil; struct gcpro gcpro1, gcpro2, gcpro3; - CONST char *nsuffix; - GCPRO3 (path, str, filename); + GCPRO3 (directory, str, filename); - filename = Fexpand_file_name (str, path); + filename = Fexpand_file_name (str, directory); if (NILP (filename) || NILP (Ffile_name_absolute_p (filename))) /* If there are non-absolute elts in PATH (eg ".") */ /* Of course, this could conceivably lose if luser sets @@ -905,142 +1080,73 @@ locate_file_in_directory (Lisp_Object path, Lisp_Object str, current_buffer->directory); if (NILP (Ffile_name_absolute_p (filename))) { - /* Give up on this path element! */ + /* Give up on this directory! */ UNGCPRO; return -1; } } - /* Calculate maximum size of any filename made from - this path element/specified file name and any possible suffix. */ - want_size = strlen (suffix) + XSTRING_LENGTH (filename) + 1; - if (fn_size < want_size) - fn = (char *) alloca (fn_size = 100 + want_size); - nsuffix = suffix; + closure.fd = -1; + closure.storeptr = storeptr; + closure.mode = mode; - /* Loop over suffixes. */ - while (1) - { - char *esuffix = (char *) strchr (nsuffix, ':'); - int lsuffix = ((esuffix) ? (esuffix - nsuffix) : strlen (nsuffix)); - - /* Concatenate path element/specified name with the suffix. */ - strncpy (fn, (char *) XSTRING_DATA (filename), - XSTRING_LENGTH (filename)); - fn[XSTRING_LENGTH (filename)] = 0; - if (lsuffix != 0) /* Bug happens on CCI if lsuffix is 0. */ - strncat (fn, nsuffix, lsuffix); - - /* Ignore file if it's a directory. */ - if (stat (fn, &st) >= 0 - && (st.st_mode & S_IFMT) != S_IFDIR) - { - /* Check that we can access or open it. */ - if (mode >= 0) - fd = access (fn, mode); - else - fd = open (fn, O_RDONLY | OPEN_BINARY, 0); - - if (fd >= 0) - { - /* We succeeded; return this descriptor and filename. */ - if (storeptr) - *storeptr = build_string (fn); - UNGCPRO; - -#ifndef WINDOWSNT - /* If we actually opened the file, set close-on-exec flag - on the new descriptor so that subprocesses can't whack - at it. */ - if (mode < 0) - (void) fcntl (fd, F_SETFD, FD_CLOEXEC); -#endif - - return fd; - } - } - - /* Advance to next suffix. */ - if (esuffix == 0) - break; - nsuffix += lsuffix + 1; - } + locate_file_map_suffixes (filename, suffixes, locate_file_in_directory_mapper, + &closure); UNGCPRO; - return -1; + return closure.fd; } /* do the same as locate_file() but don't use any hash tables. */ static int locate_file_without_hash (Lisp_Object path, Lisp_Object str, - CONST char *suffix, Lisp_Object *storeptr, + Lisp_Object suffixes, Lisp_Object *storeptr, int mode) { /* This function can GC */ - int absolute; - struct gcpro gcpro1; - - /* is this necessary? */ - GCPRO1 (path); + int absolute = !NILP (Ffile_name_absolute_p (str)); - absolute = !NILP (Ffile_name_absolute_p (str)); - - for (; !NILP (path); path = Fcdr (path)) + EXTERNAL_LIST_LOOP (path, path) { - int val = locate_file_in_directory (Fcar (path), str, suffix, - storeptr, mode); + int val = locate_file_in_directory (XCAR (path), str, suffixes, storeptr, + mode); if (val >= 0) - { - UNGCPRO; - return val; - } + return val; if (absolute) break; } - - UNGCPRO; return -1; } -/* Construct a list of all files to search for. */ +static int +locate_file_construct_suffixed_files_mapper (char *fn, void *arg) +{ + Lisp_Object *tail = (Lisp_Object *)arg; + *tail = Fcons (build_string (fn), *tail); + return 0; +} + +/* Construct a list of all files to search for. + It makes sense to have this despite locate_file_map_suffixes() + because we need Lisp strings to access the hash-table, and it would + be inefficient to create them on the fly, again and again for each + path component. See locate_file(). */ static Lisp_Object -locate_file_construct_suffixed_files (Lisp_Object str, CONST char *suffix) +locate_file_construct_suffixed_files (Lisp_Object filename, + Lisp_Object suffixes) { - int want_size; - int fn_size = 100; - char buf[100]; - char *fn = buf; - CONST char *nsuffix; - Lisp_Object suffixtab = Qnil; - - /* Calculate maximum size of any filename made from - this path element/specified file name and any possible suffix. */ - want_size = strlen (suffix) + XSTRING_LENGTH (str) + 1; - if (fn_size < want_size) - fn = (char *) alloca (fn_size = 100 + want_size); + Lisp_Object tail = Qnil; + struct gcpro gcpro1; + GCPRO1 (tail); - nsuffix = suffix; + locate_file_map_suffixes (filename, suffixes, + locate_file_construct_suffixed_files_mapper, + &tail); - while (1) - { - char *esuffix = (char *) strchr (nsuffix, ':'); - int lsuffix = ((esuffix) ? (esuffix - nsuffix) : strlen (nsuffix)); - - /* Concatenate path element/specified name with the suffix. */ - strncpy (fn, (char *) XSTRING_DATA (str), XSTRING_LENGTH (str)); - fn[XSTRING_LENGTH (str)] = 0; - if (lsuffix != 0) /* Bug happens on CCI if lsuffix is 0. */ - strncat (fn, nsuffix, lsuffix); - - suffixtab = Fcons (build_string (fn), suffixtab); - /* Advance to next suffix. */ - if (esuffix == 0) - break; - nsuffix += lsuffix + 1; - } - return Fnreverse (suffixtab); + UNGCPRO; + return Fnreverse (tail); } DEFUN ("locate-file-clear-hashing", Flocate_file_clear_hashing, 1, 1, 0, /* @@ -1056,23 +1162,31 @@ track the following environmental changes: `locate-file' will primarily get confused if you add a file that shadows \(i.e. has the same name as) another file further down in the directory list. In this case, you must call `locate-file-clear-hashing'. + +If PATH is t, it means to fully clear all the accumulated hashes. This +can be used if the internal tables grow too large, or when dumping. */ (path)) { - Lisp_Object pathtail; - - for (pathtail = path; !NILP (pathtail); pathtail = Fcdr (pathtail)) + if (EQ (path, Qt)) + Fclrhash (Vlocate_file_hash_table); + else { - Lisp_Object pathel = Fcar (pathtail); - if (!purified (pathel)) - Fput (pathel, Qlocate_file_hash_table, Qnil); + Lisp_Object pathtail; + EXTERNAL_LIST_LOOP (pathtail, path) + { + Lisp_Object pathel = Fexpand_file_name (XCAR (pathtail), Qnil); + Fremhash (pathel, Vlocate_file_hash_table); + } } return Qnil; } /* Search for a file whose name is STR, looking in directories - in the Lisp list PATH, and trying suffixes from SUFFIX. - SUFFIX is a string containing possible suffixes separated by colons. + in the Lisp list PATH, and trying suffixes from SUFFIXES. + SUFFIXES is a list of possible suffixes, or (for backward + compatibility) a string containing possible suffixes separated by + colons. On success, returns a file descriptor. On failure, returns -1. MODE nonnegative means don't open the files, @@ -1086,43 +1200,45 @@ In this case, you must call `locate-file-clear-hashing'. Called openp() in FSFmacs. */ int -locate_file (Lisp_Object path, Lisp_Object str, CONST char *suffix, +locate_file (Lisp_Object path, Lisp_Object str, Lisp_Object suffixes, Lisp_Object *storeptr, int mode) { /* This function can GC */ Lisp_Object suffixtab = Qnil; - Lisp_Object pathtail; + Lisp_Object pathtail, pathel_expanded; int val; - struct gcpro gcpro1, gcpro2, gcpro3; + struct gcpro gcpro1, gcpro2, gcpro3, gcpro4; if (storeptr) *storeptr = Qnil; + /* Is it really necessary to gcpro path and str? It shouldn't be + unless some caller has fucked up. There are known instances that + call us with build_string("foo:bar") as SUFFIXES, though. */ + GCPRO4 (path, str, suffixes, suffixtab); + /* if this filename has directory components, it's too complicated to try and use the hash tables. */ if (!NILP (Ffile_name_directory (str))) - return locate_file_without_hash (path, str, suffix, storeptr, - mode); - - /* Is it really necessary to gcpro path and str? It shouldn't be - unless some caller has fucked up. */ - GCPRO3 (path, str, suffixtab); + { + val = locate_file_without_hash (path, str, suffixes, storeptr, mode); + UNGCPRO; + return val; + } - suffixtab = locate_file_construct_suffixed_files (str, suffix); + suffixtab = locate_file_construct_suffixed_files (str, suffixes); - for (pathtail = path; !NILP (pathtail); pathtail = Fcdr (pathtail)) + EXTERNAL_LIST_LOOP (pathtail, path) { - Lisp_Object pathel = Fcar (pathtail); + Lisp_Object pathel = XCAR (pathtail); Lisp_Object hash_table; Lisp_Object tail; - int found; + int found = 0; - /* If this path element is relative, we have to look by hand. - Can't set string property in a pure string. */ - if (NILP (pathel) || NILP (Ffile_name_absolute_p (pathel)) || - purified (pathel)) + /* If this path element is relative, we have to look by hand. */ + if (NILP (Ffile_name_absolute_p (pathel))) { - val = locate_file_in_directory (pathel, str, suffix, storeptr, + val = locate_file_in_directory (pathel, str, suffixes, storeptr, mode); if (val >= 0) { @@ -1132,21 +1248,25 @@ locate_file (Lisp_Object path, Lisp_Object str, CONST char *suffix, continue; } - hash_table = locate_file_find_directory_hash_table (pathel); + pathel_expanded = Fexpand_file_name (pathel, Qnil); + hash_table = locate_file_find_directory_hash_table (pathel_expanded); - /* Loop over suffixes. */ - for (tail = suffixtab, found = 0; !found && CONSP (tail); - tail = XCDR (tail)) + if (!NILP (hash_table)) { - if (!NILP (Fgethash (XCAR (tail), hash_table, Qnil))) - found = 1; + /* Loop over suffixes. */ + LIST_LOOP (tail, suffixtab) + if (!NILP (Fgethash (XCAR (tail), hash_table, Qnil))) + { + found = 1; + break; + } } if (found) { /* This is a likely candidate. Look by hand in this directory so we don't get thrown off if someone byte-compiles a file. */ - val = locate_file_in_directory (pathel, str, suffix, storeptr, + val = locate_file_in_directory (pathel, str, suffixes, storeptr, mode); if (val >= 0) { @@ -1156,13 +1276,12 @@ locate_file (Lisp_Object path, Lisp_Object str, CONST char *suffix, /* Hmm ... the file isn't actually there. (Or possibly it's a directory ...) So refresh our hashing. */ - locate_file_refresh_hashing (pathel); + locate_file_refresh_hashing (pathel_expanded); } } /* File is probably not there, but check the hard way just in case. */ - val = locate_file_without_hash (path, str, suffix, storeptr, - mode); + val = locate_file_without_hash (path, str, suffixes, storeptr, mode); if (val >= 0) { /* Sneaky user added a file without telling us. */ @@ -1325,7 +1444,7 @@ readevalloop (Lisp_Object readcharfun, #else /* No "defun hack" -- Emacs 19 uses read-time syntax for bytecodes */ { unreadchar (readcharfun, c); - read_objects = Qnil; + Vread_objects = Qnil; if (NILP (Vload_read_function)) val = read0 (readcharfun); else @@ -1463,7 +1582,7 @@ STREAM or the value of `standard-input' may be: if (EQ (stream, Qt)) stream = Qread_char; - read_objects = Qnil; + Vread_objects = Qnil; #ifdef COMPILED_FUNCTION_ANNOTATION_HACK Vcurrent_compiled_function_annotation = Qnil; @@ -1504,7 +1623,7 @@ START and END optionally delimit a substring of STRING from which to read; lispstream = make_lisp_string_input_stream (string, startval, endval - startval); - read_objects = Qnil; + Vread_objects = Qnil; tem = read0 (lispstream); /* Yeah, it's ugly. Gonna make something of it? @@ -1539,9 +1658,8 @@ backquote_unwind (Lisp_Object ptr) static Lisp_Object read0 (Lisp_Object readcharfun) { - Lisp_Object val; + Lisp_Object val = read1 (readcharfun); - val = read1 (readcharfun); if (CONSP (val) && UNBOUNDP (XCAR (val))) { Emchar c = XCHAR (XCDR (val)); @@ -1681,10 +1799,14 @@ read_escape (Lisp_Object readcharfun) } case 'x': - /* A hex escape, as in ANSI C. */ + /* A hex escape, as in ANSI C, except that we only allow latin-1 + characters to be read this way. What is "\x4e03" supposed to + mean, anyways, if the internal representation is hidden? + This is also consistent with the treatment of octal escapes. */ { REGISTER Emchar i = 0; - while (1) + REGISTER int count = 0; + while (++count <= 2) { c = readchar (readcharfun); /* Remember, can't use isdigit(), isalpha() etc. on Emchars */ @@ -1822,23 +1944,12 @@ read_atom (Lisp_Object readcharfun, { Lisp_Object sym; if (uninterned_symbol) - sym = (Fmake_symbol ((purify_flag) - ? make_pure_pname ((Bufbyte *) read_ptr, len, 0) - : make_string ((Bufbyte *) read_ptr, len))); + sym = Fmake_symbol ( make_string ((Bufbyte *) read_ptr, len)); else { /* intern will purecopy pname if necessary */ Lisp_Object name = make_string ((Bufbyte *) read_ptr, len); sym = Fintern (name, Qnil); - - if (SYMBOL_IS_KEYWORD (sym)) - { - /* the LISP way is to put keywords in their own package, - but we don't have packages, so we do something simpler. - Someday, maybe we'll have packages and then this will - be reworked. --Stig. */ - XSYMBOL (sym)->value = sym; - } } return sym; } @@ -2421,7 +2532,7 @@ retry: n += c - '0'; c = readchar (readcharfun); } - found = assq_no_quit (make_int (n), read_objects); + found = assq_no_quit (make_int (n), Vread_objects); if (c == '=') { /* #n=object returns object, but associates it with @@ -2433,7 +2544,8 @@ retry: ("Multiply defined symbol label"), make_int (n))); obj = read0 (readcharfun); - read_objects = Fcons (Fcons (make_int (n), obj), read_objects); + Vread_objects = Fcons (Fcons (make_int (n), obj), + Vread_objects); return obj; } else if (c == '#') @@ -2559,18 +2671,10 @@ retry: return Qzero; Lstream_flush (XLSTREAM (Vread_buffer_stream)); -#if 0 /* FSFmacs defun hack */ - if (read_pure) - return - make_pure_string - (resizing_buffer_stream_ptr (XLSTREAM (Vread_buffer_stream)), - Lstream_byte_count (XLSTREAM (Vread_buffer_stream))); - else -#endif - return - make_string - (resizing_buffer_stream_ptr (XLSTREAM (Vread_buffer_stream)), - Lstream_byte_count (XLSTREAM (Vread_buffer_stream))); + return + make_string + (resizing_buffer_stream_ptr (XLSTREAM (Vread_buffer_stream)), + Lstream_byte_count (XLSTREAM (Vread_buffer_stream))); } default: @@ -3022,7 +3126,6 @@ syms_of_lread (void) defsymbol (&Qcurrent_load_list, "current-load-list"); defsymbol (&Qload, "load"); defsymbol (&Qload_file_name, "load-file-name"); - defsymbol (&Qlocate_file_hash_table, "locate-file-hash-table"); defsymbol (&Qfset, "fset"); #ifdef LISP_BACKQUOTES @@ -3032,6 +3135,11 @@ syms_of_lread (void) defsymbol (&Qcomma_at, ",@"); defsymbol (&Qcomma_dot, ",."); #endif + + defsymbol (&Qexists, "exists"); + defsymbol (&Qreadable, "readable"); + defsymbol (&Qwritable, "writable"); + defsymbol (&Qexecutable, "executable"); } void @@ -3196,6 +3304,15 @@ character escape syntaxes or just read them incorrectly. Vfile_domain = Qnil; #endif - read_objects = Qnil; - staticpro (&read_objects); + Vread_objects = Qnil; + staticpro (&Vread_objects); + + Vlocate_file_hash_table = make_lisp_hash_table (200, + HASH_TABLE_NON_WEAK, + HASH_TABLE_EQUAL); + staticpro (&Vlocate_file_hash_table); +#ifdef DEBUG_XEMACS + symbol_value (XSYMBOL (intern ("Vlocate-file-hash-table"))) + = Vlocate_file_hash_table; +#endif } diff --git a/src/lrecord.h b/src/lrecord.h index b15c1cb..5173df6 100644 --- a/src/lrecord.h +++ b/src/lrecord.h @@ -59,60 +59,28 @@ Boston, MA 02111-1307, USA. */ struct lrecord_header { - /* It would be better to put the mark-bit together with the - following datatype identification field in an 8- or 16-bit - integer rather than playing funny games with changing - header->implementation and "wasting" 32 bits on the below - pointer. The type-id would then be a 7 or 15 bit index into a - table of lrecord-implementations rather than a direct pointer. - There would be 24 (or 16) bits left over for datatype-specific - per-instance flags. - - The below is the simplest thing to do for the present, - and doesn't incur that much overhead as most Emacs records - are of such a size that the overhead isn't too bad. - (The marker datatype is the worst case.) - - It also has the very very very slight advantage that type-checking - involves one memory read (of the "implementation" slot) and a - comparison against a link-time constant address rather than a - read and a comparison against a variable value. (Variable since - it is a very good idea to assign the indices into the hypothetical - type-code table dynamically rather that pre-defining them.) - I think I remember that Elk Lisp does something like this. - Gee, I wonder if some cretin has patented it? */ - - /* - * If USE_INDEXED_LRECORD_IMPLEMENTATION is defined, we are - * implementing the scheme described in the 'It would be better - * ...' paragraph above. - */ -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION /* index into lrecord_implementations_table[] */ unsigned char type; - /* 1 if the object is marked during GC, 0 otherwise. */ - char mark; - /* 1 if the object resides in pure (read-only) space */ - char pure; -#else - CONST struct lrecord_implementation *implementation; -#endif + struct { + /* 1 if the object is marked during GC. */ + unsigned mark :1; + /* 1 if the object resides in read-only space */ + unsigned c_readonly : 1; + /* 1 if the object is readonly from lisp */ + unsigned lisp_readonly : 1; + } flags; }; struct lrecord_implementation; int lrecord_type_index (CONST struct lrecord_implementation *implementation); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION # define set_lheader_implementation(header,imp) do { \ struct lrecord_header* SLI_header = (header); \ (SLI_header)->type = lrecord_type_index (imp); \ - (SLI_header)->mark = 0; \ - (SLI_header)->pure = 0; \ + (SLI_header)->flags.mark = 0; \ + (SLI_header)->flags.c_readonly = 0; \ + (SLI_header)->flags.lisp_readonly = 0; \ } while (0) -#else -# define set_lheader_implementation(header,imp) \ - ((void) ((header)->implementation = (imp))) -#endif struct lcrecord_header { @@ -152,10 +120,6 @@ struct free_lcrecord_header Lisp_Object chain; }; -/* This as the value of lheader->implementation->finalizer - means that this record is already marked */ -void this_marks_a_marked_record (void *, int); - /* see alloc.c for an explanation */ Lisp_Object this_one_is_unmarkable (Lisp_Object obj, void (*markobj) (Lisp_Object)); @@ -212,46 +176,29 @@ struct lrecord_implementation int basic_p; }; -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION extern CONST struct lrecord_implementation *lrecord_implementations_table[]; -# define XRECORD_LHEADER_IMPLEMENTATION(obj) \ +#define XRECORD_LHEADER_IMPLEMENTATION(obj) \ (lrecord_implementations_table[XRECORD_LHEADER (obj)->type]) -# define LHEADER_IMPLEMENTATION(lh) (lrecord_implementations_table[(lh)->type]) -#else -# define XRECORD_LHEADER_IMPLEMENTATION(obj) \ - (XRECORD_LHEADER (obj)->implementation) -# define LHEADER_IMPLEMENTATION(lh) ((lh)->implementation) -#endif +#define LHEADER_IMPLEMENTATION(lh) (lrecord_implementations_table[(lh)->type]) extern int gc_in_progress; -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION -# define MARKED_RECORD_P(obj) (gc_in_progress && XRECORD_LHEADER (obj)->mark) -#else -# define MARKED_RECORD_P(obj) (gc_in_progress && \ - XRECORD_LHEADER (obj)->implementation->finalizer == \ - this_marks_a_marked_record) -#endif - -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION - -# define MARKED_RECORD_HEADER_P(lheader) ((lheader)->mark) -# define MARK_RECORD_HEADER(lheader) ((void) ((lheader)->mark = 1)) -# define UNMARK_RECORD_HEADER(lheader) ((void) ((lheader)->mark = 0)) - -#else /* ! USE_INDEXED_LRECORD_IMPLEMENTATION */ - -# define MARKED_RECORD_HEADER_P(lheader) \ - ((lheader)->implementation->finalizer == this_marks_a_marked_record) -# define MARK_RECORD_HEADER(lheader) ((void) (((lheader)->implementation)++)) -# define UNMARK_RECORD_HEADER(lheader) ((void) (((lheader)->implementation)--)) - -#endif /* ! USE_INDEXED_LRECORD_IMPLEMENTATION */ +#define MARKED_RECORD_P(obj) (gc_in_progress && XRECORD_LHEADER (obj)->flags.mark) +#define MARKED_RECORD_HEADER_P(lheader) ((lheader)->flags.mark) +#define MARK_RECORD_HEADER(lheader) ((void) ((lheader)->flags.mark = 1)) +#define UNMARK_RECORD_HEADER(lheader) ((void) ((lheader)->flags.mark = 0)) #define UNMARKABLE_RECORD_HEADER_P(lheader) \ (LHEADER_IMPLEMENTATION (lheader)->marker == this_one_is_unmarkable) +#define C_READONLY_RECORD_HEADER_P(lheader) ((lheader)->flags.c_readonly) +#define LISP_READONLY_RECORD_HEADER_P(lheader) ((lheader)->flags.lisp_readonly) +#define SET_C_READONLY_RECORD_HEADER(lheader) \ + ((void) ((lheader)->flags.c_readonly = (lheader)->flags.lisp_readonly = 1)) +#define SET_LISP_READONLY_RECORD_HEADER(lheader) \ + ((void) ((lheader)->flags.lisp_readonly = 1)) + /* Declaring the following structures as const puts them in the text (read-only) segment, which makes debugging inconvenient because this segment is not mapped when processing a core- @@ -294,23 +241,17 @@ MAKE_LRECORD_IMPLEMENTATION(name,c_name,marker,printer,nuker,equal,hash,getprop, #define MAKE_LRECORD_IMPLEMENTATION(name,c_name,marker,printer,nuker,equal,hash,getprop,putprop,remprop,props,size,sizer,basic_p,structtype) \ DECLARE_ERROR_CHECK_TYPECHECK(c_name, structtype) \ static int lrecord_##c_name##_lrecord_type_index; \ -CONST_IF_NOT_DEBUG struct lrecord_implementation lrecord_##c_name[2] = \ - { { name, marker, printer, nuker, equal, hash, \ - getprop, putprop, remprop, props, size, sizer, \ - &(lrecord_##c_name##_lrecord_type_index), basic_p }, \ - { 0, 0, 0, this_marks_a_marked_record, 0, 0, 0, 0, 0, 0, 0, 0, 0, basic_p } } +CONST_IF_NOT_DEBUG struct lrecord_implementation lrecord_##c_name = \ + { name, marker, printer, nuker, equal, hash, \ + getprop, putprop, remprop, props, size, sizer, \ + &(lrecord_##c_name##_lrecord_type_index), basic_p } \ #define LRECORDP(a) (XTYPE ((a)) == Lisp_Type_Record) #define XRECORD_LHEADER(a) ((struct lrecord_header *) XPNTR (a)) -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION -# define RECORD_TYPEP(x, ty) \ +#define RECORD_TYPEP(x, ty) \ (LRECORDP (x) && \ lrecord_implementations_table[XRECORD_LHEADER (x)->type] == (ty)) -#else -# define RECORD_TYPEP(x, ty) \ - (LRECORDP (x) && XRECORD_LHEADER (x)->implementation == (ty)) -#endif /* NOTE: the DECLARE_LRECORD() must come before the associated DEFINE_LRECORD_*() or you will get compile errors. @@ -325,13 +266,12 @@ CONST_IF_NOT_DEBUG struct lrecord_implementation lrecord_##c_name[2] = \ # define DECLARE_LRECORD(c_name, structtype) \ extern CONST_IF_NOT_DEBUG struct lrecord_implementation \ - lrecord_##c_name[]; \ + lrecord_##c_name; \ INLINE structtype *error_check_##c_name (Lisp_Object obj); \ INLINE structtype * \ error_check_##c_name (Lisp_Object obj) \ { \ - XUNMARK (obj); \ - assert (RECORD_TYPEP (obj, lrecord_##c_name) || \ + assert (RECORD_TYPEP (obj, &lrecord_##c_name) || \ MARKED_RECORD_P (obj)); \ return (structtype *) XPNTR (obj); \ } \ @@ -342,7 +282,6 @@ INLINE structtype *error_check_##c_name (Lisp_Object obj); \ INLINE structtype * \ error_check_##c_name (Lisp_Object obj) \ { \ - XUNMARK (obj); \ assert (XGCTYPE (obj) == type_enum); \ return (structtype *) XPNTR (obj); \ } \ @@ -354,7 +293,7 @@ extern Lisp_Object Q##c_name##p # define XSETRECORD(var, p, c_name) do \ { \ XSETOBJ (var, Lisp_Type_Record, p); \ - assert (RECORD_TYPEP (var, lrecord_##c_name) || \ + assert (RECORD_TYPEP (var, &lrecord_##c_name) || \ MARKED_RECORD_P (var)); \ } while (0) @@ -363,7 +302,7 @@ extern Lisp_Object Q##c_name##p # define DECLARE_LRECORD(c_name, structtype) \ extern Lisp_Object Q##c_name##p; \ extern CONST_IF_NOT_DEBUG struct lrecord_implementation \ - lrecord_##c_name[] + lrecord_##c_name # define DECLARE_NONRECORD(c_name, type_enum, structtype) \ extern Lisp_Object Q##c_name##p # define XRECORD(x, c_name, structtype) ((structtype *) XPNTR (x)) @@ -373,8 +312,8 @@ extern Lisp_Object Q##c_name##p #endif /* not ERROR_CHECK_TYPECHECK */ -#define RECORDP(x, c_name) RECORD_TYPEP (x, lrecord_##c_name) -#define GC_RECORDP(x, c_name) gc_record_type_p (x, lrecord_##c_name) +#define RECORDP(x, c_name) RECORD_TYPEP (x, &lrecord_##c_name) +#define GC_RECORDP(x, c_name) gc_record_type_p (x, &lrecord_##c_name) /* Note: we now have two different kinds of type-checking macros. The "old" kind has now been renamed CONCHECK_foo. The reason for @@ -400,7 +339,7 @@ extern Lisp_Object Q##c_name##p way out and disabled returning from a signal entirely. */ #define CONCHECK_RECORD(x, c_name) do { \ - if (!RECORD_TYPEP (x, lrecord_##c_name)) \ + if (!RECORD_TYPEP (x, &lrecord_##c_name)) \ x = wrong_type_argument (Q##c_name##p, x); \ } while (0) #define CONCHECK_NONRECORD(x, lisp_enum, predicate) do {\ @@ -408,7 +347,7 @@ extern Lisp_Object Q##c_name##p x = wrong_type_argument (predicate, x); \ } while (0) #define CHECK_RECORD(x, c_name) do { \ - if (!RECORD_TYPEP (x, lrecord_##c_name)) \ + if (!RECORD_TYPEP (x, &lrecord_##c_name)) \ dead_wrong_type_argument (Q##c_name##p, x); \ } while (0) #define CHECK_NONRECORD(x, lisp_enum, predicate) do { \ diff --git a/src/lstream.c b/src/lstream.c index 1624dbb..5a797fb 100644 --- a/src/lstream.c +++ b/src/lstream.c @@ -232,7 +232,7 @@ Lstream_new (CONST Lstream_implementation *imp, CONST char *mode) lstream_types[lstream_type_count] = imp; Vlstream_free_list[lstream_type_count] = make_lcrecord_list (sizeof (*p) + imp->size - 1, - lrecord_lstream); + &lrecord_lstream); lstream_type_count++; } diff --git a/src/m/intel386.h b/src/m/intel386.h index a36655f..c81c6b0 100644 --- a/src/m/intel386.h +++ b/src/m/intel386.h @@ -168,13 +168,6 @@ NOTE-END */ #define NO_REMAP #endif -#ifdef WINDOWSNT -#define VIRT_ADDR_VARIES -#define DATA_END get_data_end () -#define DATA_START get_data_start () -#define HAVE_ALLOCA -#endif - #ifdef linux /* libc-linux/sysdeps/linux/i386/ulimit.c says that due to shared library, */ /* we cannot get the maximum address for brk */ diff --git a/src/make-src-depend b/src/make-src-depend index a66f070..4f604f4 100644 --- a/src/make-src-depend +++ b/src/make-src-depend @@ -42,7 +42,7 @@ opendir SRCDIR, "." or die "$srcdir: $!"; for (grep (/\.[ch]$/, readdir (SRCDIR))) { $exists{$_} = 1; } closedir SRCDIR; -for (qw (config.h puresize-adjust.h sheap-adjust.h paths.h Emacs.ad.h)) { +for (qw (config.h sheap-adjust.h paths.h Emacs.ad.h)) { $generated_header{$_} = 1; } diff --git a/src/mem-limits.h b/src/mem-limits.h index f3d7226..3fb0e4e 100644 --- a/src/mem-limits.h +++ b/src/mem-limits.h @@ -101,12 +101,7 @@ typedef unsigned long SIZE; #endif extern POINTER start_of_data (void); -#ifdef DATA_SEG_BITS -#define EXCEEDS_LISP_PTR(ptr) \ - (((EMACS_UINT) (ptr) & ~DATA_SEG_BITS) >> VALBITS) -#else -#define EXCEEDS_LISP_PTR(ptr) ((EMACS_UINT) (ptr) >> VALBITS) -#endif +#define EXCEEDS_LISP_PTR(ptr) 0 #ifdef BSD #ifndef DATA_SEG_BITS diff --git a/src/menubar-x.c b/src/menubar-x.c index 36c1344..61258db 100644 --- a/src/menubar-x.c +++ b/src/menubar-x.c @@ -465,10 +465,12 @@ pre_activate_callback (Widget widget, LWLIB_ID id, XtPointer client_data) wv = xmalloc_widget_value (); wv->type = CASCADE_TYPE; wv->next = NULL; + wv->accel = LISP_TO_VOID (Qnil); wv->contents = xmalloc_widget_value (); wv->contents->type = TEXT_TYPE; wv->contents->name = (char *) "No menu"; wv->contents->next = NULL; + wv->contents->accel = LISP_TO_VOID (Qnil); } assert (wv && wv->type == CASCADE_TYPE && wv->contents); replace_widget_value_tree (hack_wv, wv->contents); @@ -572,7 +574,7 @@ set_frame_menubar (struct frame *f, int deep_p, int first_time_p) if (NILP (FRAME_MENUBAR_DATA (f))) { struct popup_data *mdata = - alloc_lcrecord_type (struct popup_data, lrecord_popup_data); + alloc_lcrecord_type (struct popup_data, &lrecord_popup_data); mdata->id = new_lwlib_id (); mdata->last_menubar_buffer = Qnil; diff --git a/src/mule-charset.c b/src/mule-charset.c index 96b01bc..8effd75 100644 --- a/src/mule-charset.c +++ b/src/mule-charset.c @@ -19,7 +19,7 @@ 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: Mule 2.3. Not in FSF. */ +/* Synched up with: FSF 20.3. Not in FSF. */ /* Rewritten by Ben Wing . */ @@ -41,23 +41,23 @@ Lisp_Object Vcharset_latin_iso8859_1; Lisp_Object Vcharset_latin_iso8859_2; Lisp_Object Vcharset_latin_iso8859_3; Lisp_Object Vcharset_latin_iso8859_4; -Lisp_Object Vcharset_cyrillic_iso8859_5; -Lisp_Object Vcharset_arabic_iso8859_6; +Lisp_Object Vcharset_thai_tis620; Lisp_Object Vcharset_greek_iso8859_7; +Lisp_Object Vcharset_arabic_iso8859_6; Lisp_Object Vcharset_hebrew_iso8859_8; -Lisp_Object Vcharset_latin_iso8859_9; -Lisp_Object Vcharset_thai_tis620; Lisp_Object Vcharset_katakana_jisx0201; Lisp_Object Vcharset_latin_jisx0201; +Lisp_Object Vcharset_cyrillic_iso8859_5; +Lisp_Object Vcharset_latin_iso8859_9; Lisp_Object Vcharset_japanese_jisx0208_1978; +Lisp_Object Vcharset_chinese_gb2312; Lisp_Object Vcharset_japanese_jisx0208; +Lisp_Object Vcharset_korean_ksc5601; Lisp_Object Vcharset_japanese_jisx0212; -Lisp_Object Vcharset_chinese_gb2312; -Lisp_Object Vcharset_chinese_big5_1; -Lisp_Object Vcharset_chinese_big5_2; Lisp_Object Vcharset_chinese_cns11643_1; Lisp_Object Vcharset_chinese_cns11643_2; -Lisp_Object Vcharset_korean_ksc5601; +Lisp_Object Vcharset_chinese_big5_1; +Lisp_Object Vcharset_chinese_big5_2; #ifdef ENABLE_COMPOSITE_CHARS Lisp_Object Vcharset_composite; @@ -113,31 +113,32 @@ Lisp_Object Qdirection; Lisp_Object Qreverse_direction_charset; Lisp_Object Qccl_program; Lisp_Object Qleading_byte; +Lisp_Object Qshort_name, Qlong_name; -Lisp_Object Qascii, Qcontrol_1, - +Lisp_Object Qascii, + Qcontrol_1, Qlatin_iso8859_1, Qlatin_iso8859_2, Qlatin_iso8859_3, Qlatin_iso8859_4, - Qcyrillic_iso8859_5, - Qarabic_iso8859_6, + Qthai_tis620, Qgreek_iso8859_7, + Qarabic_iso8859_6, Qhebrew_iso8859_8, + Qkatakana_jisx0201, + Qlatin_jisx0201, + Qcyrillic_iso8859_5, Qlatin_iso8859_9, - - Qthai_tis620, - - Qkatakana_jisx0201, Qlatin_jisx0201, Qjapanese_jisx0208_1978, + Qchinese_gb2312, Qjapanese_jisx0208, + Qkorean_ksc5601, Qjapanese_jisx0212, - - Qchinese_gb2312, - Qchinese_big5_1, Qchinese_big5_2, - Qchinese_cns11643_1, Qchinese_cns11643_2, - - Qkorean_ksc5601, Qcomposite; + Qchinese_cns11643_1, + Qchinese_cns11643_2, + Qchinese_big5_1, + Qchinese_big5_2, + Qcomposite; Lisp_Object Ql2r, Qr2l; @@ -398,6 +399,8 @@ mark_charset (Lisp_Object obj, void (*markobj) (Lisp_Object)) { struct Lisp_Charset *cs = XCHARSET (obj); + markobj (cs->short_name); + markobj (cs->long_name); markobj (cs->doc_string); markobj (cs->registry); markobj (cs->ccl_program); @@ -418,6 +421,10 @@ print_charset (Lisp_Object obj, Lisp_Object printcharfun, int escapeflag) write_c_string ("#name); + + if (NILP (long_name)) + long_name = doc_string; + if (columns == -1) columns = dimension; - charset = make_charset (-1, name, lb, dimension + 2, type, columns, graphic, - final, direction, doc_string, registry); + charset = make_charset (id, name, dimension + 2, type, columns, graphic, + final, direction, short_name, long_name, doc_string, registry); if (!NILP (ccl_program)) XCHARSET_CCL_PROGRAM (charset) = ccl_program; return charset; @@ -781,9 +811,9 @@ NEW-NAME is the name of the new charset. Return the new charset. (charset, new_name)) { Lisp_Object new_charset = Qnil; - int lb, dimension, columns, graphic, final; + int id, dimension, columns, graphic, final; int direction, type; - Lisp_Object registry, doc_string; + Lisp_Object registry, doc_string, short_name, long_name; struct Lisp_Charset *cs; charset = Fget_charset (charset); @@ -800,7 +830,7 @@ NEW-NAME is the name of the new charset. Return the new charset. type = CHARSET_TYPE (cs); columns = CHARSET_COLUMNS (cs); dimension = CHARSET_DIMENSION (cs); - lb = get_unallocated_leading_byte (dimension); + id = get_unallocated_leading_byte (dimension); graphic = CHARSET_GRAPHIC (cs); final = CHARSET_FINAL (cs); @@ -808,10 +838,13 @@ NEW-NAME is the name of the new charset. Return the new charset. if (CHARSET_DIRECTION (cs) == CHARSET_RIGHT_TO_LEFT) direction = CHARSET_LEFT_TO_RIGHT; doc_string = CHARSET_DOC_STRING (cs); + short_name = CHARSET_SHORT_NAME (cs); + long_name = CHARSET_LONG_NAME (cs); registry = CHARSET_REGISTRY (cs); - new_charset = make_charset (-1, new_name, lb, dimension + 2, type, columns, - graphic, final, direction, doc_string, registry); + new_charset = make_charset (id, new_name, dimension + 2, type, columns, + graphic, final, direction, short_name, long_name, + doc_string, registry); CHARSET_REVERSE_DIRECTION_CHARSET (cs) = new_charset; XCHARSET_REVERSE_DIRECTION_CHARSET (new_charset) = charset; @@ -891,8 +924,24 @@ will be returned if character sets exist for both directions). return obj; } -DEFUN ("charset-doc-string", Fcharset_doc_string, 1, 1, 0, /* -Return doc string of CHARSET. +DEFUN ("charset-short-name", Fcharset_short_name, 1, 1, 0, /* +Return short name of CHARSET. +*/ + (charset)) +{ + return XCHARSET_SHORT_NAME (Fget_charset (charset)); +} + +DEFUN ("charset-long-name", Fcharset_long_name, 1, 1, 0, /* +Return long name of CHARSET. +*/ + (charset)) +{ + return XCHARSET_LONG_NAME (Fget_charset (charset)); +} + +DEFUN ("charset-description", Fcharset_description, 1, 1, 0, /* +Return description of CHARSET. */ (charset)) { @@ -921,6 +970,8 @@ Recognized properties are those listed in `make-charset', as well as CHECK_SYMBOL (prop); if (EQ (prop, Qname)) return CHARSET_NAME (cs); + if (EQ (prop, Qshort_name)) return CHARSET_SHORT_NAME (cs); + if (EQ (prop, Qlong_name)) return CHARSET_LONG_NAME (cs); if (EQ (prop, Qdoc_string)) return CHARSET_DOC_STRING (cs); if (EQ (prop, Qdimension)) return make_int (CHARSET_DIMENSION (cs)); if (EQ (prop, Qcolumns)) return make_int (CHARSET_COLUMNS (cs)); @@ -929,7 +980,6 @@ Recognized properties are those listed in `make-charset', as well as if (EQ (prop, Qchars)) return make_int (CHARSET_CHARS (cs)); if (EQ (prop, Qregistry)) return CHARSET_REGISTRY (cs); if (EQ (prop, Qccl_program)) return CHARSET_CCL_PROGRAM (cs); - if (EQ (prop, Qleading_byte)) return make_char (CHARSET_LEADING_BYTE (cs)); if (EQ (prop, Qdirection)) return CHARSET_DIRECTION (cs) == CHARSET_LEFT_TO_RIGHT ? Ql2r : Qr2l; if (EQ (prop, Qreverse_direction_charset)) @@ -949,7 +999,7 @@ Return charset identification number of CHARSET. */ (charset)) { - return make_int(XCHARSET_ID (Fget_charset (charset))); + return make_int(XCHARSET_LEADING_BYTE (Fget_charset (charset))); } /* #### We need to figure out which properties we really want to @@ -1162,7 +1212,9 @@ syms_of_mule_charset (void) DEFSUBR (Fmake_reverse_direction_charset); /* DEFSUBR (Freverse_direction_charset); */ DEFSUBR (Fcharset_from_attributes); - DEFSUBR (Fcharset_doc_string); + DEFSUBR (Fcharset_short_name); + DEFSUBR (Fcharset_long_name); + DEFSUBR (Fcharset_description); DEFSUBR (Fcharset_dimension); DEFSUBR (Fcharset_property); DEFSUBR (Fcharset_id); @@ -1185,12 +1237,13 @@ syms_of_mule_charset (void) defsymbol (&Qdirection, "direction"); defsymbol (&Qreverse_direction_charset, "reverse-direction-charset"); defsymbol (&Qccl_program, "ccl-program"); - defsymbol (&Qleading_byte, "leading-byte"); + defsymbol (&Qshort_name, "short-name"); + defsymbol (&Qlong_name, "long-name"); defsymbol (&Ql2r, "l2r"); defsymbol (&Qr2l, "r2l"); - /* Charsets, compatible with Emacs/Mule 19.33-delta + /* Charsets, compatible with FSF 20.3 Naming convention is Script-Charset[-Edition] */ defsymbol (&Qascii, "ascii"); defsymbol (&Qcontrol_1, "control-1"); @@ -1198,26 +1251,24 @@ syms_of_mule_charset (void) defsymbol (&Qlatin_iso8859_2, "latin-iso8859-2"); defsymbol (&Qlatin_iso8859_3, "latin-iso8859-3"); defsymbol (&Qlatin_iso8859_4, "latin-iso8859-4"); - defsymbol (&Qcyrillic_iso8859_5, "cyrillic-iso8859-5"); - defsymbol (&Qarabic_iso8859_6, "arabic-iso8859-6"); + defsymbol (&Qthai_tis620, "thai-tis620"); defsymbol (&Qgreek_iso8859_7, "greek-iso8859-7"); + defsymbol (&Qarabic_iso8859_6, "arabic-iso8859-6"); defsymbol (&Qhebrew_iso8859_8, "hebrew-iso8859-8"); - defsymbol (&Qlatin_iso8859_9, "latin-iso8859-9"); - defsymbol (&Qthai_tis620, "thai-tis620"); - defsymbol (&Qkatakana_jisx0201, "katakana-jisx0201"); defsymbol (&Qlatin_jisx0201, "latin-jisx0201"); + defsymbol (&Qcyrillic_iso8859_5, "cyrillic-iso8859-5"); + defsymbol (&Qlatin_iso8859_9, "latin-iso8859-9"); defsymbol (&Qjapanese_jisx0208_1978, "japanese-jisx0208-1978"); + defsymbol (&Qchinese_gb2312, "chinese-gb2312"); defsymbol (&Qjapanese_jisx0208, "japanese-jisx0208"); + defsymbol (&Qkorean_ksc5601, "korean-ksc5601"); defsymbol (&Qjapanese_jisx0212, "japanese-jisx0212"); - - defsymbol (&Qchinese_gb2312, "chinese-gb2312"); - defsymbol (&Qchinese_big5_1, "chinese-big5-1"); - defsymbol (&Qchinese_big5_2, "chinese-big5-2"); defsymbol (&Qchinese_cns11643_1, "chinese-cns11643-1"); defsymbol (&Qchinese_cns11643_2, "chinese-cns11643-2"); + defsymbol (&Qchinese_big5_1, "chinese-big5-1"); + defsymbol (&Qchinese_big5_2, "chinese-big5-2"); - defsymbol (&Qkorean_ksc5601, "korean-ksc5601"); defsymbol (&Qcomposite, "composite"); } @@ -1251,170 +1302,208 @@ complex_vars_of_mule_charset (void) ease of access. */ Vcharset_ascii = - make_charset (0, Qascii, LEADING_BYTE_ASCII, 1, + make_charset (LEADING_BYTE_ASCII, Qascii, 1, CHARSET_TYPE_94, 1, 0, 'B', CHARSET_LEFT_TO_RIGHT, - build_string ("ASCII (ISO 646 IRV)"), - build_string ("iso8859-1")); + build_string ("ASCII"), + build_string ("ASCII)"), + build_string ("ASCII (ISO646 IRV)"), + build_string ("\\(iso8859-[0-9]*\\|-ascii\\)")); Vcharset_control_1 = - make_charset (-1, Qcontrol_1, LEADING_BYTE_CONTROL_1, 2, + make_charset (LEADING_BYTE_CONTROL_1, Qcontrol_1, 2, CHARSET_TYPE_94, 1, 1, 0, CHARSET_LEFT_TO_RIGHT, + build_string ("C1"), build_string ("Control characters"), + build_string ("Control characters 128-191"), build_string ("")); Vcharset_latin_iso8859_1 = - make_charset (129, Qlatin_iso8859_1, LEADING_BYTE_LATIN_ISO8859_1, 2, + make_charset (LEADING_BYTE_LATIN_ISO8859_1, Qlatin_iso8859_1, 2, CHARSET_TYPE_96, 1, 1, 'A', CHARSET_LEFT_TO_RIGHT, - build_string ("ISO 8859-1 (Latin-1)"), + build_string ("Latin-1"), + build_string ("ISO8859-1 (Latin-1)"), + build_string ("ISO8859-1 (Latin-1)"), build_string ("iso8859-1")); Vcharset_latin_iso8859_2 = - make_charset (130, Qlatin_iso8859_2, LEADING_BYTE_LATIN_ISO8859_2, 2, + make_charset (LEADING_BYTE_LATIN_ISO8859_2, Qlatin_iso8859_2, 2, CHARSET_TYPE_96, 1, 1, 'B', CHARSET_LEFT_TO_RIGHT, - build_string ("ISO 8859-2 (Latin-2)"), + build_string ("Latin-2"), + build_string ("ISO8859-2 (Latin-2)"), + build_string ("ISO8859-2 (Latin-2)"), build_string ("iso8859-2")); Vcharset_latin_iso8859_3 = - make_charset (131, Qlatin_iso8859_3, LEADING_BYTE_LATIN_ISO8859_3, 2, + make_charset (LEADING_BYTE_LATIN_ISO8859_3, Qlatin_iso8859_3, 2, CHARSET_TYPE_96, 1, 1, 'C', CHARSET_LEFT_TO_RIGHT, - build_string ("ISO 8859-3 (Latin-3)"), + build_string ("Latin-3"), + build_string ("ISO8859-3 (Latin-3)"), + build_string ("ISO8859-3 (Latin-3)"), build_string ("iso8859-3")); Vcharset_latin_iso8859_4 = - make_charset (132, Qlatin_iso8859_4, LEADING_BYTE_LATIN_ISO8859_4, 2, + make_charset (LEADING_BYTE_LATIN_ISO8859_4, Qlatin_iso8859_4, 2, CHARSET_TYPE_96, 1, 1, 'D', CHARSET_LEFT_TO_RIGHT, - build_string ("ISO 8859-4 (Latin-4)"), + build_string ("Latin-4"), + build_string ("ISO8859-4 (Latin-4)"), + build_string ("ISO8859-4 (Latin-4)"), build_string ("iso8859-4")); - Vcharset_cyrillic_iso8859_5 = - make_charset (140, Qcyrillic_iso8859_5, LEADING_BYTE_CYRILLIC_ISO8859_5, 2, - CHARSET_TYPE_96, 1, 1, 'L', + Vcharset_thai_tis620 = + make_charset (LEADING_BYTE_THAI_TIS620, Qthai_tis620, 2, + CHARSET_TYPE_96, 1, 1, 'T', CHARSET_LEFT_TO_RIGHT, - build_string ("ISO 8859-5 (Cyrillic)"), - build_string ("iso8859-5")); - Vcharset_arabic_iso8859_6 = - make_charset (135, Qarabic_iso8859_6, LEADING_BYTE_ARABIC_ISO8859_6, 2, - CHARSET_TYPE_96, 1, 1, 'G', - CHARSET_RIGHT_TO_LEFT, - build_string ("ISO 8859-6 (Arabic)"), - build_string ("iso8859-6")); + build_string ("TIS620"), + build_string ("TIS620 (Thai)"), + build_string ("TIS620.2529 (Thai)"), + build_string ("tis620")); Vcharset_greek_iso8859_7 = - make_charset (134, Qgreek_iso8859_7, LEADING_BYTE_GREEK_ISO8859_7, 2, + make_charset (LEADING_BYTE_GREEK_ISO8859_7, Qgreek_iso8859_7, 2, CHARSET_TYPE_96, 1, 1, 'F', CHARSET_LEFT_TO_RIGHT, - build_string ("ISO 8859-7 (Greek)"), + build_string ("ISO8859-7"), + build_string ("ISO8859-7 (Greek)"), + build_string ("ISO8859-7 (Greek)"), build_string ("iso8859-7")); + Vcharset_arabic_iso8859_6 = + make_charset (LEADING_BYTE_ARABIC_ISO8859_6, Qarabic_iso8859_6, 2, + CHARSET_TYPE_96, 1, 1, 'G', + CHARSET_RIGHT_TO_LEFT, + build_string ("ISO8859-6"), + build_string ("ISO8859-6 (Arabic)"), + build_string ("ISO8859-6 (Arabic)"), + build_string ("iso8859-6")); Vcharset_hebrew_iso8859_8 = - make_charset (136, Qhebrew_iso8859_8, LEADING_BYTE_HEBREW_ISO8859_8, 2, + make_charset (LEADING_BYTE_HEBREW_ISO8859_8, Qhebrew_iso8859_8, 2, CHARSET_TYPE_96, 1, 1, 'H', CHARSET_RIGHT_TO_LEFT, - build_string ("ISO 8859-8 (Hebrew)"), + build_string ("ISO8859-8"), + build_string ("ISO8859-8 (Hebrew)"), + build_string ("ISO8859-8 (Hebrew)"), build_string ("iso8859-8")); - Vcharset_latin_iso8859_9 = - make_charset (141, Qlatin_iso8859_9, LEADING_BYTE_LATIN_ISO8859_9, 2, - CHARSET_TYPE_96, 1, 1, 'M', - CHARSET_LEFT_TO_RIGHT, - build_string ("ISO 8859-9 (Latin-5)"), - build_string ("iso8859-9")); - Vcharset_thai_tis620 = - make_charset (133, Qthai_tis620, LEADING_BYTE_THAI_TIS620, 2, - CHARSET_TYPE_96, 1, 1, 'T', - CHARSET_LEFT_TO_RIGHT, - build_string ("TIS 620.2529 (Thai)"), - build_string ("tis620")); - - /* Japanese */ Vcharset_katakana_jisx0201 = - make_charset (137, Qkatakana_jisx0201, - LEADING_BYTE_KATAKANA_JISX0201, 2, + make_charset (LEADING_BYTE_KATAKANA_JISX0201, Qkatakana_jisx0201, 2, CHARSET_TYPE_94, 1, 1, 'I', CHARSET_LEFT_TO_RIGHT, - build_string ("JIS X0201-Katakana"), + build_string ("JISX0201 Kana"), + build_string ("JISX0201.1976 (Japanese Kana)"), + build_string ("JISX0201.1976 Japanese Kana"), build_string ("jisx0201.1976")); Vcharset_latin_jisx0201 = - make_charset (138, Qlatin_jisx0201, - LEADING_BYTE_LATIN_JISX0201, 2, + make_charset (LEADING_BYTE_LATIN_JISX0201, Qlatin_jisx0201, 2, CHARSET_TYPE_94, 1, 0, 'J', CHARSET_LEFT_TO_RIGHT, - build_string ("JIS X0201-Latin"), + build_string ("JISX0201 Roman"), + build_string ("JISX0201.1976 (Japanese Roman)"), + build_string ("JISX0201.1976 Japanese Roman"), build_string ("jisx0201.1976")); + Vcharset_cyrillic_iso8859_5 = + make_charset (LEADING_BYTE_CYRILLIC_ISO8859_5, Qcyrillic_iso8859_5, 2, + CHARSET_TYPE_96, 1, 1, 'L', + CHARSET_LEFT_TO_RIGHT, + build_string ("ISO8859-5"), + build_string ("ISO8859-5 (Cyrillic)"), + build_string ("ISO8859-5 (Cyrillic)"), + build_string ("iso8859-5")); + Vcharset_latin_iso8859_9 = + make_charset (LEADING_BYTE_LATIN_ISO8859_9, Qlatin_iso8859_9, 2, + CHARSET_TYPE_96, 1, 1, 'M', + CHARSET_LEFT_TO_RIGHT, + build_string ("Latin-5"), + build_string ("ISO8859-9 (Latin-5)"), + build_string ("ISO8859-9 (Latin-5)"), + build_string ("iso8859-9")); Vcharset_japanese_jisx0208_1978 = - make_charset (144, Qjapanese_jisx0208_1978, - LEADING_BYTE_JAPANESE_JISX0208_1978, 3, + make_charset (LEADING_BYTE_JAPANESE_JISX0208_1978, Qjapanese_jisx0208_1978, 3, CHARSET_TYPE_94X94, 2, 0, '@', CHARSET_LEFT_TO_RIGHT, + build_string ("JISX0208.1978"), + build_string ("JISX0208.1978 (Japanese)"), build_string - ("JIS X0208-1978 (Japanese Kanji; Old Version)"), + ("JISX0208.1978 Japanese Kanji (so called \"old JIS\")"), build_string ("\\(jisx0208\\|jisc6226\\).19")); + Vcharset_chinese_gb2312 = + make_charset (LEADING_BYTE_CHINESE_GB2312, Qchinese_gb2312, 3, + CHARSET_TYPE_94X94, 2, 0, 'A', + CHARSET_LEFT_TO_RIGHT, + build_string ("GB2312"), + build_string ("GB2312)"), + build_string ("GB2312 Chinese simplified"), + build_string ("gb2312")); Vcharset_japanese_jisx0208 = - make_charset (146, Qjapanese_jisx0208, - LEADING_BYTE_JAPANESE_JISX0208, 3, + make_charset (LEADING_BYTE_JAPANESE_JISX0208, Qjapanese_jisx0208, 3, CHARSET_TYPE_94X94, 2, 0, 'B', CHARSET_LEFT_TO_RIGHT, - build_string ("JIS X0208-1983 (Japanese Kanji)"), + build_string ("JISX0208"), + build_string ("JISX0208.1983/1990 (Japanese)"), + build_string ("JISX0208.1983/1990 Japanese Kanji"), build_string ("jisx0208.19\\(83\\|90\\)")); + Vcharset_korean_ksc5601 = + make_charset (LEADING_BYTE_KOREAN_KSC5601, Qkorean_ksc5601, 3, + CHARSET_TYPE_94X94, 2, 0, 'C', + CHARSET_LEFT_TO_RIGHT, + build_string ("KSC5601"), + build_string ("KSC5601 (Korean"), + build_string ("KSC5601 Korean Hangul and Hanja"), + build_string ("ksc5601")); Vcharset_japanese_jisx0212 = - make_charset (148, Qjapanese_jisx0212, - LEADING_BYTE_JAPANESE_JISX0212, 3, + make_charset (LEADING_BYTE_JAPANESE_JISX0212, Qjapanese_jisx0212, 3, CHARSET_TYPE_94X94, 2, 0, 'D', CHARSET_LEFT_TO_RIGHT, - build_string ("JIS X0212 (Japanese Supplement)"), + build_string ("JISX0212"), + build_string ("JISX0212 (Japanese)"), + build_string ("JISX0212 Japanese Supplement"), build_string ("jisx0212")); - /* Chinese */ - Vcharset_chinese_gb2312 = - make_charset (145, Qchinese_gb2312, LEADING_BYTE_CHINESE_GB2312, 3, - CHARSET_TYPE_94X94, 2, 0, 'A', - CHARSET_LEFT_TO_RIGHT, - build_string ("GB 2312 (Simplified Chinese)"), - build_string ("gb2312")); #define CHINESE_CNS_PLANE_RE(n) "cns11643[.-]\\(.*[.-]\\)?" n "$" Vcharset_chinese_cns11643_1 = - make_charset (149, Qchinese_cns11643_1, - LEADING_BYTE_CHINESE_CNS11643_1, 3, + make_charset (LEADING_BYTE_CHINESE_CNS11643_1, Qchinese_cns11643_1, 3, CHARSET_TYPE_94X94, 2, 0, 'G', CHARSET_LEFT_TO_RIGHT, + build_string ("CNS11643-1"), + build_string ("CNS11643-1 (Chinese traditional)"), build_string - ("CNS 11643 Plane 1 (Traditional Chinese for daily use)"), + ("CNS 11643 Plane 1 Chinese traditional"), build_string (CHINESE_CNS_PLANE_RE("1"))); Vcharset_chinese_cns11643_2 = - make_charset (150, Qchinese_cns11643_2, - LEADING_BYTE_CHINESE_CNS11643_2, 3, + make_charset (LEADING_BYTE_CHINESE_CNS11643_2, Qchinese_cns11643_2, 3, CHARSET_TYPE_94X94, 2, 0, 'H', CHARSET_LEFT_TO_RIGHT, + build_string ("CNS11643-2"), + build_string ("CNS11643-2 (Chinese traditional)"), build_string - ("CNS 11643 Plane 2 (Traditional Chinese for daily use)"), + ("CNS 11643 Plane 2 Chinese traditional"), build_string (CHINESE_CNS_PLANE_RE("2"))); Vcharset_chinese_big5_1 = - make_charset (152, Qchinese_big5_1, LEADING_BYTE_CHINESE_BIG5_1, 3, + make_charset (LEADING_BYTE_CHINESE_BIG5_1, Qchinese_big5_1, 3, CHARSET_TYPE_94X94, 2, 0, '0', CHARSET_LEFT_TO_RIGHT, + build_string ("Big5"), + build_string ("Big5 (Level-1)"), build_string - ("Big5 Level 1 (Traditional Chinese for daily use)"), + ("Big5 Level-1 Chinese traditional"), build_string ("big5")); Vcharset_chinese_big5_2 = - make_charset (153, Qchinese_big5_2, LEADING_BYTE_CHINESE_BIG5_2, 3, + make_charset (LEADING_BYTE_CHINESE_BIG5_2, Qchinese_big5_2, 3, CHARSET_TYPE_94X94, 2, 0, '1', CHARSET_LEFT_TO_RIGHT, + build_string ("Big5"), + build_string ("Big5 (Level-2)"), build_string - ("Big5 Level 2 (Traditional Chinese for daily use)"), + ("Big5 Level-2 Chinese traditional"), build_string ("big5")); - Vcharset_korean_ksc5601 = - make_charset (147, Qkorean_ksc5601, LEADING_BYTE_KOREAN_KSC5601, 3, - CHARSET_TYPE_94X94, 2, 0, 'C', - CHARSET_LEFT_TO_RIGHT, - build_string ("KS C5601 (Hangul and Korean Hanja)"), - build_string ("ksc5601")); #ifdef ENABLE_COMPOSITE_CHARS /* #### For simplicity, we put composite chars into a 96x96 charset. This is going to lead to problems because you can run out of room, esp. as we don't yet recycle numbers. */ Vcharset_composite = - make_charset (-1, Qcomposite, LEADING_BYTE_COMPOSITE, 3, + make_charset (LEADING_BYTE_COMPOSITE, Qcomposite, 3, CHARSET_TYPE_96X96, 2, 0, 0, CHARSET_LEFT_TO_RIGHT, + build_string ("Composite"), + build_string ("Composite characters"), build_string ("Composite characters"), build_string ("")); diff --git a/src/mule-charset.h b/src/mule-charset.h index b9faed8..5ee9061 100644 --- a/src/mule-charset.h +++ b/src/mule-charset.h @@ -448,14 +448,12 @@ struct Lisp_Charset int id; Lisp_Object name; - Lisp_Object doc_string, registry; + Lisp_Object doc_string, registry, short_name, long_name; Lisp_Object reverse_direction_charset; Lisp_Object ccl_program; - Bufbyte leading_byte; - /* Final byte of this character set in ISO2022 designating escape sequence */ Bufbyte final; @@ -500,9 +498,12 @@ DECLARE_LRECORD (charset, struct Lisp_Charset); #define CHARSET_LEFT_TO_RIGHT 0 #define CHARSET_RIGHT_TO_LEFT 1 +/* Leading byte and id have been regrouped. -- OG */ #define CHARSET_ID(cs) ((cs)->id) +#define CHARSET_LEADING_BYTE(cs) ((Bufbyte)(CHARSET_ID(cs))) #define CHARSET_NAME(cs) ((cs)->name) -#define CHARSET_LEADING_BYTE(cs) ((cs)->leading_byte) +#define CHARSET_SHORT_NAME(cs) ((cs)->short_name) +#define CHARSET_LONG_NAME(cs) ((cs)->long_name) #define CHARSET_REP_BYTES(cs) ((cs)->rep_bytes) #define CHARSET_COLUMNS(cs) ((cs)->columns) #define CHARSET_GRAPHIC(cs) ((cs)->graphic) @@ -521,6 +522,8 @@ DECLARE_LRECORD (charset, struct Lisp_Charset); #define XCHARSET_ID(cs) CHARSET_ID (XCHARSET (cs)) #define XCHARSET_NAME(cs) CHARSET_NAME (XCHARSET (cs)) +#define XCHARSET_SHORT_NAME(cs) CHARSET_SHORT_NAME (XCHARSET (cs)) +#define XCHARSET_LONG_NAME(cs) CHARSET_LONG_NAME (XCHARSET (cs)) #define XCHARSET_REP_BYTES(cs) CHARSET_REP_BYTES (XCHARSET (cs)) #define XCHARSET_COLUMNS(cs) CHARSET_COLUMNS (XCHARSET (cs)) #define XCHARSET_GRAPHIC(cs) CHARSET_GRAPHIC (XCHARSET (cs)) diff --git a/src/nt.c b/src/nt.c index e9d2961..793cc81 100644 --- a/src/nt.c +++ b/src/nt.c @@ -34,6 +34,7 @@ Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA #include "systime.h" #include "syssignal.h" #include "sysproc.h" +#include "sysfile.h" #include #include @@ -48,7 +49,20 @@ Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA #include #include +#ifndef __MINGW32__ #include +#else +typedef void (CALLBACK TIMECALLBACK)(UINT uTimerID, UINT uMsg, DWORD dwUser, DWORD dw1, DWORD dw2); + +typedef TIMECALLBACK FAR *LPTIMECALLBACK; +DWORD WINAPI timeGetTime(void); +MMRESULT WINAPI timeSetEvent(UINT uDelay, UINT uResolution, + LPTIMECALLBACK fptc, DWORD dwUser, UINT fuEvent); +MMRESULT WINAPI timeKillEvent(UINT uTimerID); +MMRESULT WINAPI timeGetDevCaps(TIMECAPS* ptc, UINT cbtc); +MMRESULT WINAPI timeBeginPeriod(UINT uPeriod); +MMRESULT WINAPI timeEndPeriod(UINT uPeriod); +#endif #include "nt.h" #include @@ -533,7 +547,6 @@ nt_get_resource (key, lpdwtype) LPBYTE lpvalue; HKEY hrootkey = NULL; DWORD cbData; - BOOL ok = FALSE; /* Check both the current user and the local machine to see if we have any resources. */ @@ -942,7 +955,7 @@ map_win32_filename (const char * name, const char ** pPath) static char shortname[MAX_PATH]; char * str = shortname; char c; - char * path; + const char * path; const char * save_name = name; if (is_fat_volume (name, &path)) /* truncate to 8.3 */ @@ -1052,7 +1065,7 @@ opendir (const char *filename) /* Opening is done by FindFirstFile. However, a read is inherent to this operation, so we defer the open until read time. */ - if (!(dirp = (DIR *) xmalloc (sizeof (DIR)))) + if (!(dirp = xnew_and_zero(DIR))) return NULL; if (dir_find_handle != INVALID_HANDLE_VALUE) return NULL; @@ -1077,7 +1090,7 @@ closedir (DIR *dirp) FindClose (dir_find_handle); dir_find_handle = INVALID_HANDLE_VALUE; } - xfree ((char *) dirp); + xfree (dirp); } struct direct * @@ -1527,67 +1540,6 @@ sys_pipe (int * phandles) return rc; } -/* From ntproc.c */ -extern Lisp_Object Vwin32_pipe_read_delay; - -/* Function to do blocking read of one byte, needed to implement - select. It is only allowed on sockets and pipes. */ -int -_sys_read_ahead (int fd) -{ - child_process * cp; - int rc; - - if (fd < 0 || fd >= MAXDESC) - return STATUS_READ_ERROR; - - cp = fd_info[fd].cp; - - if (cp == NULL || cp->fd != fd || cp->status != STATUS_READ_READY) - return STATUS_READ_ERROR; - - if ((fd_info[fd].flags & (FILE_PIPE | FILE_SOCKET)) == 0 - || (fd_info[fd].flags & FILE_READ) == 0) - { - /* fd is not a pipe or socket */ - abort (); - } - - cp->status = STATUS_READ_IN_PROGRESS; - - if (fd_info[fd].flags & FILE_PIPE) - { - rc = _read (fd, &cp->chr, sizeof (char)); - - /* Give subprocess time to buffer some more output for us before - reporting that input is available; we need this because Win95 - connects DOS programs to pipes by making the pipe appear to be - the normal console stdout - as a result most DOS programs will - write to stdout without buffering, ie. one character at a - time. Even some Win32 programs do this - "dir" in a command - shell on NT is very slow if we don't do this. */ - if (rc > 0) - { - int wait = XINT (Vwin32_pipe_read_delay); - - if (wait > 0) - Sleep (wait); - else if (wait < 0) - while (++wait <= 0) - /* Yield remainder of our time slice, effectively giving a - temporary priority boost to the child process. */ - Sleep (0); - } - } - - if (rc == sizeof (char)) - cp->status = STATUS_READ_SUCCEEDED; - else - cp->status = STATUS_READ_FAILED; - - return cp->status; -} - void term_ntproc (int unused) { @@ -1810,6 +1762,7 @@ int msw_raise (int nsig) exit (3); /* Other signals are ignored by default */ + return 0; } /*--------------------------------------------------------------------*/ @@ -1928,4 +1881,45 @@ int setitimer (int kind, const struct itimerval* itnew, return errno = EINVAL; } +int +open_input_file (file_data *p_file, CONST char *filename) +{ + HANDLE file; + HANDLE file_mapping; + void *file_base; + DWORD size, upper_size; + + file = CreateFile (filename, GENERIC_READ, FILE_SHARE_READ, NULL, + OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0); + if (file == INVALID_HANDLE_VALUE) + return FALSE; + + size = GetFileSize (file, &upper_size); + file_mapping = CreateFileMapping (file, NULL, PAGE_READONLY, + 0, size, NULL); + if (!file_mapping) + return FALSE; + + file_base = MapViewOfFile (file_mapping, FILE_MAP_READ, 0, 0, size); + if (file_base == 0) + return FALSE; + + p_file->name = (char*)filename; + p_file->size = size; + p_file->file = file; + p_file->file_mapping = file_mapping; + p_file->file_base = file_base; + + return TRUE; +} + +/* Close the system structures associated with the given file. */ +void +close_file_data (file_data *p_file) +{ + UnmapViewOfFile (p_file->file_base); + CloseHandle (p_file->file_mapping); + CloseHandle (p_file->file); +} + /* end of nt.c */ diff --git a/src/nt.h b/src/nt.h index 8c97e64..89798e3 100644 --- a/src/nt.h +++ b/src/nt.h @@ -34,6 +34,9 @@ Boston, MA 02111-1307, USA. */ #define R_OK 4 #define W_OK 2 +#ifdef X_OK +#undef X_OK +#endif #define X_OK 1 #define F_OK 0 diff --git a/src/ntheap.c b/src/ntheap.c index 5202196..ff5ef3a 100644 --- a/src/ntheap.c +++ b/src/ntheap.c @@ -189,20 +189,6 @@ sbrk (unsigned long increment) if (!data_region_base) return NULL; -#ifndef USE_MINIMAL_TAGBITS - /* Ensure that the addresses don't use the upper tag bits since - the Lisp type goes there. */ -#ifdef USE_UNION_TYPE - if (((unsigned long) data_region_base & ~((1U << VALBITS) - 1)) != 0) -#else - if (((unsigned long) data_region_base & ~VALMASK) != 0) -#endif - { - printf ("Error: The heap was allocated in upper memory.\n"); - exit (1); - } -#endif - data_region_end = data_region_base; real_data_region_end = data_region_end; data_region_size = get_reserved_heap_size (); @@ -261,7 +247,7 @@ sbrk (unsigned long increment) return result; } -#ifndef CANNOT_DUMP +#if !defined (CANNOT_DUMP) && !defined(HEAP_IN_DATA) /* Recreate the heap from the data that was dumped to the executable. EXECUTABLE_PATH tells us where to find the executable. */ diff --git a/src/ntheap.h b/src/ntheap.h index 8c28ff0..6bde266 100644 --- a/src/ntheap.h +++ b/src/ntheap.h @@ -103,12 +103,8 @@ typedef struct file_data { #define RVA_TO_PTR(var,section,filedata) \ ((void *)(RVA_TO_OFFSET(var,section) + (filedata).file_base)) -int open_input_file (file_data *p_file, char *name); -int open_output_file (file_data *p_file, char *name, unsigned long size); +int open_input_file (file_data *p_file, CONST char *name); +int open_output_file (file_data *p_file, CONST char *name, unsigned long size); void close_file_data (file_data *p_file); -/* Return pointer to section header for section containing the given - relative virtual address. */ -IMAGE_SECTION_HEADER * rva_to_section (DWORD rva, IMAGE_NT_HEADERS * nt_header); - #endif /* NTHEAP_H_ */ diff --git a/src/ntplay.c b/src/ntplay.c index 916168e..2b85ab8 100644 --- a/src/ntplay.c +++ b/src/ntplay.c @@ -25,7 +25,7 @@ Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA #include "sysfile.h" #include "lisp.h" -#ifdef __CYGWIN32__ +#if defined (__CYGWIN32__) || defined(__MINGW32__) extern BOOL WINAPI PlaySound(LPCSTR,HMODULE,DWORD); #else #include diff --git a/src/ntproc.c b/src/ntproc.c index aee5649..d20bb19 100644 --- a/src/ntproc.c +++ b/src/ntproc.c @@ -42,14 +42,18 @@ Boston, MA 02111-1307, USA. #include #include - +#ifdef HAVE_A_OUT_H +#include +#endif #include "lisp.h" #include "sysproc.h" #include "nt.h" #include "ntheap.h" /* From 19.34.6 */ #include "systime.h" #include "syssignal.h" +#include "sysfile.h" #include "syswait.h" +#include "buffer.h" #include "process.h" /*#include "w32term.h"*/ /* From 19.34.6: sync in ? --marcpa */ @@ -86,6 +90,8 @@ Lisp_Object Vwin32_generate_fake_inodes; Lisp_Object Qhigh, Qlow; +extern Lisp_Object Vlisp_EXEC_SUFFIXES; + #ifndef DEBUG_XEMACS __inline #endif @@ -223,6 +229,63 @@ find_child_pid (DWORD pid) return NULL; } +/* Function to do blocking read of one byte, needed to implement + select. It is only allowed on sockets and pipes. */ +static int +_sys_read_ahead (int fd) +{ + child_process * cp; + int rc = 0; + + if (fd < 0 || fd >= MAXDESC) + return STATUS_READ_ERROR; + + cp = fd_info[fd].cp; + + if (cp == NULL || cp->fd != fd || cp->status != STATUS_READ_READY) + return STATUS_READ_ERROR; + + if ((fd_info[fd].flags & (FILE_PIPE | FILE_SOCKET)) == 0 + || (fd_info[fd].flags & FILE_READ) == 0) + { + /* fd is not a pipe or socket */ + abort (); + } + + cp->status = STATUS_READ_IN_PROGRESS; + + if (fd_info[fd].flags & FILE_PIPE) + { + rc = _read (fd, &cp->chr, sizeof (char)); + + /* Give subprocess time to buffer some more output for us before + reporting that input is available; we need this because Win95 + connects DOS programs to pipes by making the pipe appear to be + the normal console stdout - as a result most DOS programs will + write to stdout without buffering, ie. one character at a + time. Even some Win32 programs do this - "dir" in a command + shell on NT is very slow if we don't do this. */ + if (rc > 0) + { + int wait = XINT (Vwin32_pipe_read_delay); + + if (wait > 0) + Sleep (wait); + else if (wait < 0) + while (++wait <= 0) + /* Yield remainder of our time slice, effectively giving a + temporary priority boost to the child process. */ + Sleep (0); + } + } + + if (rc == sizeof (char)) + cp->status = STATUS_READ_SUCCEEDED; + else + cp->status = STATUS_READ_FAILED; + + return cp->status; +} /* Thread proc for child process and socket reader threads. Each thread is normally blocked until woken by select() to check for input by @@ -330,7 +393,7 @@ reader_thread (void *arg) static const char * process_dir; static BOOL -create_child (char *exe, char *cmdline, char *env, +create_child (CONST char *exe, char *cmdline, char *env, int * pPid, child_process *cp) { STARTUPINFO start; @@ -402,8 +465,30 @@ create_child (char *exe, char *cmdline, char *env, return FALSE; } +#ifndef __MINGW32__ +/* Return pointer to section header for section containing the given + relative virtual address. */ +static IMAGE_SECTION_HEADER * +rva_to_section (DWORD rva, IMAGE_NT_HEADERS * nt_header) +{ + PIMAGE_SECTION_HEADER section; + int i; + + section = IMAGE_FIRST_SECTION (nt_header); + + for (i = 0; i < nt_header->FileHeader.NumberOfSections; i++) + { + if (rva >= section->VirtualAddress + && rva < section->VirtualAddress + section->SizeOfRawData) + return section; + section++; + } + return NULL; +} +#endif + void -win32_executable_type (char * filename, int * is_dos_app, int * is_cygnus_app) +win32_executable_type (CONST char * filename, int * is_dos_app, int * is_cygnus_app) { file_data executable; char * p; @@ -430,9 +515,9 @@ win32_executable_type (char * filename, int * is_dos_app, int * is_cygnus_app) /* Actually, I think it uses the program association for that extension, which is defined in the registry. */ p = egetenv ("COMSPEC"); - if (p) + if (p) win32_executable_type (p, is_dos_app, is_cygnus_app); - } + } else { /* Look for DOS .exe signature - if found, we must also check that @@ -440,57 +525,77 @@ win32_executable_type (char * filename, int * is_dos_app, int * is_cygnus_app) start with a DOS program stub. Note that 16-bit Windows executables use the OS/2 1.x format. */ - IMAGE_DOS_HEADER * dos_header; - IMAGE_NT_HEADERS * nt_header; - - dos_header = (PIMAGE_DOS_HEADER) executable.file_base; - if (dos_header->e_magic != IMAGE_DOS_SIGNATURE) - goto unwind; - - nt_header = (PIMAGE_NT_HEADERS) ((char *) dos_header + dos_header->e_lfanew); +#ifdef __MINGW32__ + /* mingw32 doesn't have enough headers to detect cygwin + apps, just do what we can. */ + FILHDR * exe_header; - if ((char *) nt_header > (char *) dos_header + executable.size) - { - /* Some dos headers (pkunzip) have bogus e_lfanew fields. */ - *is_dos_app = TRUE; - } - else if (nt_header->Signature != IMAGE_NT_SIGNATURE && - LOWORD (nt_header->Signature) != IMAGE_OS2_SIGNATURE) - { - *is_dos_app = TRUE; - } - else if (nt_header->Signature == IMAGE_NT_SIGNATURE) - { - /* Look for cygwin.dll in DLL import list. */ - IMAGE_DATA_DIRECTORY import_dir = - nt_header->OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_IMPORT]; - IMAGE_IMPORT_DESCRIPTOR * imports; - IMAGE_SECTION_HEADER * section; + exe_header = (FILHDR*) executable.file_base; + if (exe_header->e_magic != DOSMAGIC) + goto unwind; - section = rva_to_section (import_dir.VirtualAddress, nt_header); - imports = RVA_TO_PTR (import_dir.VirtualAddress, section, executable); - - for ( ; imports->Name; imports++) + if ((char *) exe_header->e_lfanew > (char *) executable.size) { - char * dllname = RVA_TO_PTR (imports->Name, section, executable); - - if (strcmp (dllname, "cygwin.dll") == 0) + /* Some dos headers (pkunzip) have bogus e_lfanew fields. */ + *is_dos_app = TRUE; + } + else if (exe_header->nt_signature != NT_SIGNATURE) + { + *is_dos_app = TRUE; + } +#else + IMAGE_DOS_HEADER * dos_header; + IMAGE_NT_HEADERS * nt_header; + + dos_header = (PIMAGE_DOS_HEADER) executable.file_base; + if (dos_header->e_magic != IMAGE_DOS_SIGNATURE) + goto unwind; + + nt_header = (PIMAGE_NT_HEADERS) ((char *) dos_header + dos_header->e_lfanew); + + if ((char *) nt_header > (char *) dos_header + executable.size) { - *is_cygnus_app = TRUE; - break; + /* Some dos headers (pkunzip) have bogus e_lfanew fields. */ + *is_dos_app = TRUE; + } + else if (nt_header->Signature != IMAGE_NT_SIGNATURE && + LOWORD (nt_header->Signature) != IMAGE_OS2_SIGNATURE) + { + *is_dos_app = TRUE; + } + else if (nt_header->Signature == IMAGE_NT_SIGNATURE) + { + /* Look for cygwin.dll in DLL import list. */ + IMAGE_DATA_DIRECTORY import_dir = + nt_header->OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_IMPORT]; + IMAGE_IMPORT_DESCRIPTOR * imports; + IMAGE_SECTION_HEADER * section; + + section = rva_to_section (import_dir.VirtualAddress, nt_header); + imports = RVA_TO_PTR (import_dir.VirtualAddress, section, executable); + + for ( ; imports->Name; imports++) + { + char * dllname = RVA_TO_PTR (imports->Name, section, executable); + + if (strcmp (dllname, "cygwin.dll") == 0) + { + *is_cygnus_app = TRUE; + break; + } } } +#endif } - } -unwind: - close_file_data (&executable); + unwind: + close_file_data (&executable); } int -compare_env (const char **strp1, const char **strp2) +compare_env (const void *strp1, const void *strp2) { - const char *str1 = *strp1, *str2 = *strp2; + const char *str1 = *(const char**)strp1, *str2 = *(const char**)strp2; while (*str1 && *str2 && *str1 != '=' && *str2 != '=') { @@ -544,7 +649,7 @@ sys_spawnve (int mode, CONST char *cmdname, child_process *cp; int is_dos_app, is_cygnus_app; int do_quoting = 0; - char escape_char; + char escape_char = 0; /* We pass our process ID to our children by setting up an environment variable in their environment. */ char ppid_env_var_buffer[64]; @@ -564,24 +669,26 @@ sys_spawnve (int mode, CONST char *cmdname, if (NILP (Ffile_executable_p (program))) { full = Qnil; - locate_file (Vexec_path, program, EXEC_SUFFIXES, &full, 1); + locate_file (Vexec_path, program, Vlisp_EXEC_SUFFIXES, &full, 1); if (NILP (full)) { UNGCPRO; errno = EINVAL; return -1; } - cmdname = XSTRING_DATA (full); - /* #### KLUDGE */ - *(char**)(argv[0]) = cmdname; + GET_C_STRING_FILENAME_DATA_ALLOCA (full, cmdname); + } + else + { + (char*)cmdname = alloca (strlen (argv[0]) + 1); + strcpy ((char*)cmdname, argv[0]); } UNGCPRO; /* make sure argv[0] and cmdname are both in DOS format */ - strcpy (cmdname = alloca (strlen (cmdname) + 1), argv[0]); - unixtodos_filename (cmdname); + unixtodos_filename ((char*)cmdname); /* #### KLUDGE */ - *(char**)(argv[0]) = cmdname; + ((CONST char**)argv)[0] = cmdname; /* Determine whether program is a 16-bit DOS executable, or a Win32 executable that is implicitly linked to the Cygnus dll (implying it @@ -597,13 +704,13 @@ sys_spawnve (int mode, CONST char *cmdname, { cmdname = alloca (MAXPATHLEN); if (egetenv ("CMDPROXY")) - strcpy (cmdname, egetenv ("CMDPROXY")); + strcpy ((char*)cmdname, egetenv ("CMDPROXY")); else { - strcpy (cmdname, XSTRING_DATA (Vinvocation_directory)); - strcat (cmdname, "cmdproxy.exe"); + strcpy ((char*)cmdname, XSTRING_DATA (Vinvocation_directory)); + strcat ((char*)cmdname, "cmdproxy.exe"); } - unixtodos_filename (cmdname); + unixtodos_filename ((char*)cmdname); } /* we have to do some conjuring here to put argv and envp into the @@ -649,7 +756,7 @@ sys_spawnve (int mode, CONST char *cmdname, /* do argv... */ arglen = 0; - targ = argv; + targ = (char**)argv; while (*targ) { char * p = *targ; @@ -695,7 +802,7 @@ sys_spawnve (int mode, CONST char *cmdname, arglen += strlen (*targ++) + 1; } cmdline = alloca (arglen); - targ = argv; + targ = (char**)argv; parg = cmdline; while (*targ) { @@ -776,7 +883,7 @@ sys_spawnve (int mode, CONST char *cmdname, /* and envp... */ arglen = 1; - targ = envp; + targ = (char**)envp; numenv = 1; /* for end null */ while (*targ) { @@ -791,7 +898,7 @@ sys_spawnve (int mode, CONST char *cmdname, /* merge env passed in and extra env into one, and sort it. */ targ = (char **) alloca (numenv * sizeof (char *)); - merge_and_sort_env (envp, extra_env, targ); + merge_and_sort_env ((char**)envp, extra_env, targ); /* concatenate env entries. */ env = alloca (arglen); @@ -882,7 +989,7 @@ sys_kill (int pid, int sig) pid = cp->procinfo.dwProcessId; /* Try to locate console window for process. */ - EnumWindows (find_child_console, (LPARAM) cp); + EnumWindows ((WNDENUMPROC)find_child_console, (LPARAM) cp); } if (sig == SIGINT) diff --git a/src/objects-msw.c b/src/objects-msw.c index 5ef4393..15abb2c 100644 --- a/src/objects-msw.c +++ b/src/objects-msw.c @@ -49,7 +49,7 @@ Boston, MA 02111-1307, USA. */ #include "device.h" #include "insdel.h" -#ifdef __CYGWIN32__ +#if defined(__CYGWIN32__) || defined(__MINGW32__) #define stricmp strcasecmp #define FONTENUMPROC FONTENUMEXPROC #define ntmTm ntmentm @@ -1438,6 +1438,51 @@ mswindows_list_fonts (Lisp_Object pattern, Lisp_Object device) return Fnreverse (result); } +/* Fill in missing parts of a font spec. This is primarily intended as a + * helper function for the functions below. + * mswindows fonts look like: + * fontname[:[weight][ style][:pointsize[:effects]]][:charset] + * A minimal mswindows font spec looks like: + * Courier New + * A maximal mswindows font spec looks like: + * Courier New:Bold Italic:10:underline strikeout:Western + * Missing parts of the font spec should be filled in with these values: + * Courier New:Regular:10::Western */ +static Lisp_Object +mswindows_font_instance_truename (struct Lisp_Font_Instance *f, Error_behavior errb) +{ + int nsep=0; + char *name = (char *) XSTRING_DATA (f->name); + char* ptr = name; + char* extname = alloca (strlen (name) + 19); + strcpy (extname, name); + + while ((ptr = strchr (ptr, ':')) != 0) + { + ptr++; + nsep++; + } + + switch (nsep) + { + case 0: + strcat (extname, ":Regular:10::Western"); + break; + case 1: + strcat (extname, ":10::Western"); + break; + case 2: + strcat (extname, "::Western"); + break; + case 3: + strcat (extname, ":Western"); + break; + default:; + } + + return build_ext_string (extname, FORMAT_OS); +} + #ifdef MULE static int @@ -1512,7 +1557,7 @@ console_type_create_objects_mswindows (void) /* CONSOLE_HAS_METHOD (mswindows, mark_font_instance); */ CONSOLE_HAS_METHOD (mswindows, print_font_instance); CONSOLE_HAS_METHOD (mswindows, finalize_font_instance); -/* CONSOLE_HAS_METHOD (mswindows, font_instance_truename); */ + CONSOLE_HAS_METHOD (mswindows, font_instance_truename); CONSOLE_HAS_METHOD (mswindows, list_fonts); #ifdef MULE CONSOLE_HAS_METHOD (mswindows, font_spec_matches_charset); diff --git a/src/objects.c b/src/objects.c index 10f5cf7..a876815 100644 --- a/src/objects.c +++ b/src/objects.c @@ -156,7 +156,7 @@ is deallocated as well. CHECK_STRING (name); XSETDEVICE (device, decode_device (device)); - c = alloc_lcrecord_type (struct Lisp_Color_Instance, lrecord_color_instance); + c = alloc_lcrecord_type (struct Lisp_Color_Instance, &lrecord_color_instance); c->name = name; c->device = device; c->data = 0; @@ -259,8 +259,9 @@ print_font_instance (Lisp_Object obj, Lisp_Object printcharfun, int escapeflag) print_internal (f->name, printcharfun, 1); write_c_string (" on ", printcharfun); print_internal (f->device, printcharfun, 0); - MAYBE_DEVMETH (XDEVICE (f->device), print_font_instance, - (f, printcharfun, escapeflag)); + if (!NILP (f->device)) + MAYBE_DEVMETH (XDEVICE (f->device), print_font_instance, + (f, printcharfun, escapeflag)); sprintf (buf, " 0x%x>", f->header.uid); write_c_string (buf, printcharfun); } @@ -328,7 +329,7 @@ these objects are GCed, the underlying X data is deallocated as well. XSETDEVICE (device, decode_device (device)); - f = alloc_lcrecord_type (struct Lisp_Font_Instance, lrecord_font_instance); + f = alloc_lcrecord_type (struct Lisp_Font_Instance, &lrecord_font_instance); f->name = name; f->device = device; @@ -417,8 +418,16 @@ font_instance_truename_internal (Lisp_Object font_instance, Error_behavior errb) { struct Lisp_Font_Instance *f = XFONT_INSTANCE (font_instance); - struct device *d = XDEVICE (f->device); - return DEVMETH_OR_GIVEN (d, font_instance_truename, (f, errb), f->name); + + if (NILP (f->device)) + { + maybe_signal_simple_error ("Couldn't determine font truename", + font_instance, Qfont, errb); + return Qnil; + } + + return DEVMETH_OR_GIVEN (XDEVICE (f->device), + font_instance_truename, (f, errb), f->name); } DEFUN ("font-instance-truename", Ffont_instance_truename, 1, 1, 0, /* @@ -443,6 +452,9 @@ Return the properties (an alist or nil) of FONT-INSTANCE. CHECK_FONT_INSTANCE (font_instance); f = XFONT_INSTANCE (font_instance); + if (NILP (f->device)) + return Qnil; + return MAYBE_LISP_DEVMETH (XDEVICE (f->device), font_instance_properties, (f)); } @@ -1063,7 +1075,7 @@ vars_of_objects (void) staticpro (&Vthe_null_color_instance); { struct Lisp_Color_Instance *c = - alloc_lcrecord_type (struct Lisp_Color_Instance, lrecord_color_instance); + alloc_lcrecord_type (struct Lisp_Color_Instance, &lrecord_color_instance); c->name = Qnil; c->device = Qnil; c->data = 0; @@ -1074,7 +1086,7 @@ vars_of_objects (void) staticpro (&Vthe_null_font_instance); { struct Lisp_Font_Instance *f = - alloc_lcrecord_type (struct Lisp_Font_Instance, lrecord_font_instance); + alloc_lcrecord_type (struct Lisp_Font_Instance, &lrecord_font_instance); f->name = Qnil; f->device = Qnil; f->data = 0; diff --git a/src/opaque.c b/src/opaque.c index c93805a..830dd1d 100644 --- a/src/opaque.c +++ b/src/opaque.c @@ -115,7 +115,7 @@ Lisp_Object make_opaque (size_t size, CONST void *data) { Lisp_Opaque *p = (Lisp_Opaque *) - alloc_lcrecord (offsetof (Lisp_Opaque, data) + size, lrecord_opaque); + alloc_lcrecord (offsetof (Lisp_Opaque, data) + size, &lrecord_opaque); p->markfun = 0; p->size_or_chain = make_int (size); @@ -195,7 +195,7 @@ make_opaque_list (size_t size, { Lisp_Object val; Lisp_Opaque_List *p = - alloc_lcrecord_type (Lisp_Opaque_List, lrecord_opaque_list); + alloc_lcrecord_type (Lisp_Opaque_List, &lrecord_opaque_list); p->markfun = markfun; p->size = size; diff --git a/src/print.c b/src/print.c index 663e3c4..98d4a84 100644 --- a/src/print.c +++ b/src/print.c @@ -1093,12 +1093,8 @@ print_internal (Lisp_Object obj, Lisp_Object printcharfun, int escapeflag) switch (XTYPE (obj)) { -#ifdef USE_MINIMAL_TAGBITS case Lisp_Type_Int_Even: case Lisp_Type_Int_Odd: -#else - case Lisp_Type_Int: -#endif { char buf[24]; long_to_string (buf, XINT (obj)); @@ -1146,68 +1142,11 @@ print_internal (Lisp_Object obj, Lisp_Object printcharfun, int escapeflag) break; } -#ifndef LRECORD_STRING - case Lisp_Type_String: - { - print_string (obj, printcharfun, escapeflag); - break; - } -#endif /* ! LRECORD_STRING */ - -#ifndef LRECORD_CONS - case Lisp_Type_Cons: - { - struct gcpro gcpro1, gcpro2; - - /* If deeper than spec'd depth, print placeholder. */ - if (INTP (Vprint_level) - && print_depth > XINT (Vprint_level)) - { - GCPRO2 (obj, printcharfun); - write_c_string ("...", printcharfun); - UNGCPRO; - break; - } - - print_cons (obj, printcharfun, escapeflag); - break; - } -#endif /* ! LRECORD_CONS */ - -#ifndef LRECORD_VECTOR - case Lisp_Type_Vector: - { - /* If deeper than spec'd depth, print placeholder. */ - if (INTP (Vprint_level) - && print_depth > XINT (Vprint_level)) - { - struct gcpro gcpro1, gcpro2; - GCPRO2 (obj, printcharfun); - write_c_string ("...", printcharfun); - UNGCPRO; - break; - } - - /* God intended that this be #(...), you know. */ - print_vector_internal ("[", "]", obj, printcharfun, escapeflag); - break; - } -#endif /* !LRECORD_VECTOR */ - -#ifndef LRECORD_SYMBOL - case Lisp_Type_Symbol: - { - print_symbol (obj, printcharfun, escapeflag); - break; - } -#endif /* !LRECORD_SYMBOL */ - case Lisp_Type_Record: { struct lrecord_header *lheader = XRECORD_LHEADER (obj); struct gcpro gcpro1, gcpro2; -#if defined(LRECORD_CONS) || defined(LRECORD_VECTOR) if (CONSP (obj) || VECTORP(obj)) { /* If deeper than spec'd depth, print placeholder. */ @@ -1220,7 +1159,6 @@ print_internal (Lisp_Object obj, Lisp_Object printcharfun, int escapeflag) break; } } -#endif GCPRO2 (obj, printcharfun); if (LHEADER_IMPLEMENTATION (lheader)->printer) @@ -1292,7 +1230,12 @@ print_symbol (Lisp_Object obj, Lisp_Object printcharfun, int escapeflag) /* If we print an uninterned symbol as part of a complex object and the flag print-gensym is non-nil, prefix it with #n= to read the object back with the #n# reader syntax later if needed. */ - if (!NILP (Vprint_gensym) && NILP (XSYMBOL (obj)->obarray)) + if (!NILP (Vprint_gensym) + /* #### Test whether this produces a noticable slow-down for + printing when print-gensym is non-nil. */ + && !EQ (obj, oblookup (Vobarray, + string_data (symbol_name (XSYMBOL (obj))), + string_length (symbol_name (XSYMBOL (obj)))))) { if (print_depth > 1) { diff --git a/src/process-nt.c b/src/process-nt.c index 08cf1a3..0582761 100644 --- a/src/process-nt.c +++ b/src/process-nt.c @@ -33,7 +33,11 @@ Boston, MA 02111-1307, USA. */ #include "sysdep.h" #include +#ifndef __MINGW32__ #include +#else +#include +#endif #include #ifdef HAVE_SOCKETS #include @@ -306,7 +310,8 @@ send_signal (HANDLE h_process, int signo) sigkill_data d; d.adr_ExitProcess = GetProcAddress (h_kernel, "ExitProcess"); assert (d.adr_ExitProcess); - retval = run_in_other_process (h_process, sigkill_proc, + retval = run_in_other_process (h_process, + (LPTHREAD_START_ROUTINE)sigkill_proc, &d, sizeof (d)); break; } @@ -317,7 +322,8 @@ send_signal (HANDLE h_process, int signo) GetProcAddress (h_kernel, "GenerateConsoleCtrlEvent"); assert (d.adr_GenerateConsoleCtrlEvent); d.event = CTRL_C_EVENT; - retval = run_in_other_process (h_process, sigint_proc, + retval = run_in_other_process (h_process, + (LPTHREAD_START_ROUTINE)sigint_proc, &d, sizeof (d)); break; } @@ -341,7 +347,7 @@ enable_child_signals (HANDLE h_process) d.adr_SetConsoleCtrlHandler = GetProcAddress (h_kernel, "SetConsoleCtrlHandler"); assert (d.adr_SetConsoleCtrlHandler); - run_in_other_process (h_process, sig_enable_proc, + run_in_other_process (h_process, (LPTHREAD_START_ROUTINE)sig_enable_proc, &d, sizeof (d)); } @@ -862,7 +868,7 @@ nt_open_network_stream (Lisp_Object name, Lisp_Object host, Lisp_Object service, /* We don't want to be blocked on connect */ { - unsigned int nonblock = 1; + unsigned long nonblock = 1; ioctlsocket (s, FIONBIO, &nonblock); } diff --git a/src/process.c b/src/process.c index a9a9131..e181db2 100644 --- a/src/process.c +++ b/src/process.c @@ -106,6 +106,8 @@ struct hash_table *usid_to_process; /* List of process objects. */ Lisp_Object Vprocess_list; +extern Lisp_Object Vlisp_EXEC_SUFFIXES; + static Lisp_Object @@ -415,7 +417,7 @@ make_process_internal (Lisp_Object name) Lisp_Object val, name1; int i; struct Lisp_Process *p = - alloc_lcrecord_type (struct Lisp_Process, lrecord_process); + alloc_lcrecord_type (struct Lisp_Process, &lrecord_process); /* If name is already in use, modify it until it is unused. */ name1 = name; @@ -591,8 +593,7 @@ INCODE and OUTCODE specify the coding-system objects used in input/output tem = Qnil; NGCPRO1 (tem); - locate_file (Vexec_path, program, EXEC_SUFFIXES, &tem, - X_OK); + locate_file (Vexec_path, program, Vlisp_EXEC_SUFFIXES, &tem, X_OK); if (NILP (tem)) report_file_error ("Searching for program", list1 (program)); program = Fexpand_file_name (tem, Qnil); diff --git a/src/rangetab.c b/src/rangetab.c index 0edf541..c580a47 100644 --- a/src/rangetab.c +++ b/src/rangetab.c @@ -208,7 +208,7 @@ You can manipulate it using `put-range-table', `get-range-table', { Lisp_Object obj; struct Lisp_Range_Table *rt = alloc_lcrecord_type (struct Lisp_Range_Table, - lrecord_range_table); + &lrecord_range_table); rt->entries = Dynarr_new (range_table_entry); XSETRANGE_TABLE (obj, rt); return obj; @@ -226,7 +226,7 @@ ranges as the given table. The values will not themselves be copied. CHECK_RANGE_TABLE (old_table); rt = XRANGE_TABLE (old_table); - rtnew = alloc_lcrecord_type (struct Lisp_Range_Table, lrecord_range_table); + rtnew = alloc_lcrecord_type (struct Lisp_Range_Table, &lrecord_range_table); rtnew->entries = Dynarr_new (range_table_entry); Dynarr_add_many (rtnew->entries, Dynarr_atp (rt->entries, 0), diff --git a/src/realpath.c b/src/realpath.c index 9f7489e..78ccc25 100644 --- a/src/realpath.c +++ b/src/realpath.c @@ -73,8 +73,8 @@ char resolved_path []; char copy_path[PATH_MAX]; char *new_path = resolved_path; char *max_path; - int readlinks = 0; #ifdef S_IFLNK + int readlinks = 0; char link_path[PATH_MAX]; int n; #endif diff --git a/src/redisplay.c b/src/redisplay.c index 73a5a15..6936acf 100644 --- a/src/redisplay.c +++ b/src/redisplay.c @@ -5253,8 +5253,9 @@ regeneration_done: Bufpos end = (w->window_end_pos[DESIRED_DISP] == -1 ? BUF_ZV (b) : BUF_Z (b) - w->window_end_pos[DESIRED_DISP] - 1); - - update_line_start_cache (w, start, end, pointm, 1); + /* Don't pollute the cache if not sure if we are correct */ + if (w->start_at_line_beg) + update_line_start_cache (w, start, end, pointm, 1); redisplay_output_window (w); /* * If we just displayed the echo area, the line start cache is @@ -6278,7 +6279,7 @@ update_internal_cache_list (struct window *w, int type) else { struct line_start_cache lsc; - + lsc.start = dl->bufpos; lsc.end = dl->end_bufpos; lsc.height = dl->ascent + dl->descent; diff --git a/src/sheap.c b/src/sheap.c index 49d7a32..1c389b5 100644 --- a/src/sheap.c +++ b/src/sheap.c @@ -85,8 +85,8 @@ void* more_static_core ( ptrdiff_t increment ) "\nRequested %d bytes, static heap exhausted! base is %p, current ptr is %p. You have exhausted the static heap. -If you are simply trying to compile, remove sheap-adjust.h and -puresize-adjust.h and recompile from the top level. If this doesn't +If you are simply trying to compile, remove sheap-adjust.h +and recompile from the top level. If this doesn't work then STATIC_HEAP_SLOP (defined in this file) is too small. If you want to run temacs, change SHEAP_ADJUSTMENT in sheap-adjust.h diff --git a/src/specifier.c b/src/specifier.c index 65fcdae..d1da5f5 100644 --- a/src/specifier.c +++ b/src/specifier.c @@ -415,7 +415,7 @@ make_specifier_internal (struct specifier_methods *spec_meths, Lisp_Object specifier; struct Lisp_Specifier *sp = (struct Lisp_Specifier *) alloc_lcrecord (sizeof (struct Lisp_Specifier) + - data_size - 1, lrecord_specifier); + data_size - 1, &lrecord_specifier); sp->methods = spec_meths; sp->global_specs = Qnil; diff --git a/src/src-headers b/src/src-headers index 843cb6c..cb0e337 100644 --- a/src/src-headers +++ b/src/src-headers @@ -43,7 +43,7 @@ for (grep (/\.[ch]$/, readdir (SRCDIR))) { $exists{$_} = 1; } closedir SRCDIR; { my %generated_header; - for (qw (config.h puresize-adjust.h sheap-adjust.h paths.h Emacs.ad.h)) { + for (qw (config.h sheap-adjust.h paths.h Emacs.ad.h)) { $generated_header{$_} = 1; } diff --git a/src/symbols.c b/src/symbols.c index 8c70d02..01bf684 100644 --- a/src/symbols.c +++ b/src/symbols.c @@ -86,8 +86,6 @@ static Lisp_Object follow_varalias_pointers (Lisp_Object symbol, Lisp_Object follow_past_lisp_magic); -#ifdef LRECORD_SYMBOL - static Lisp_Object mark_symbol (Lisp_Object obj, void (*markobj) (Lisp_Object)) { @@ -96,8 +94,6 @@ mark_symbol (Lisp_Object obj, void (*markobj) (Lisp_Object)) markobj (sym->value); markobj (sym->function); - /* No need to mark through ->obarray, because it only holds nil or t. */ - /* markobj (sym->obarray);*/ XSETSTRING (pname, sym->name); markobj (pname); if (!symbol_next (sym)) @@ -115,7 +111,6 @@ mark_symbol (Lisp_Object obj, void (*markobj) (Lisp_Object)) DEFINE_BASIC_LRECORD_IMPLEMENTATION ("symbol", symbol, mark_symbol, print_symbol, 0, 0, 0, struct Lisp_Symbol); -#endif /* LRECORD_SYMBOL */ /**********************************************************************/ @@ -161,10 +156,7 @@ intern (CONST char *str) return tem; } - return Fintern ((purify_flag - ? make_pure_pname (buf, len, 0) - : make_string (buf, len)), - obarray); + return Fintern (make_string (buf, len), obarray); } DEFUN ("intern", Fintern, 1, 2, 0, /* @@ -175,7 +167,8 @@ it defaults to the value of `obarray'. */ (string, obarray)) { - Lisp_Object sym, *ptr; + Lisp_Object object, *ptr; + struct Lisp_Symbol *symbol; Bytecount len; if (NILP (obarray)) obarray = Vobarray; @@ -184,52 +177,64 @@ it defaults to the value of `obarray'. CHECK_STRING (string); len = XSTRING_LENGTH (string); - sym = oblookup (obarray, XSTRING_DATA (string), len); - if (!INTP (sym)) + object = oblookup (obarray, XSTRING_DATA (string), len); + if (!INTP (object)) /* Found it */ - return sym; - - ptr = &XVECTOR_DATA (obarray)[XINT (sym)]; + return object; - if (purify_flag && ! purified (string)) - string = make_pure_pname (XSTRING_DATA (string), len, 0); - sym = Fmake_symbol (string); - /* FSFmacs places OBARRAY here, but it is pointless because we do - not mark through this slot, so it is not usable later (because - the obarray might have been collected). Marking through the - ->obarray slot is an even worse idea, because it would keep - obarrays from being collected because of symbols pointed to them. + ptr = &XVECTOR_DATA (obarray)[XINT (object)]; - NOTE: We place Qt here only if OBARRAY is actually Vobarray. It - is safer to do it this way, to avoid hosing with symbols within - pure objects. */ - if (EQ (obarray, Vobarray)) - XSYMBOL (sym)->obarray = Qt; + object = Fmake_symbol (string); + symbol = XSYMBOL (object); if (SYMBOLP (*ptr)) - symbol_next (XSYMBOL (sym)) = XSYMBOL (*ptr); + symbol_next (symbol) = XSYMBOL (*ptr); else - symbol_next (XSYMBOL (sym)) = 0; - *ptr = sym; - return sym; + symbol_next (symbol) = 0; + *ptr = object; + + if (string_byte (symbol_name (symbol), 0) == ':' && EQ (obarray, Vobarray)) + { + /* The LISP way is to put keywords in their own package, but we + don't have packages, so we do something simpler. Someday, + maybe we'll have packages and then this will be reworked. + --Stig. */ + symbol_value (symbol) = object; + } + + return object; } DEFUN ("intern-soft", Fintern_soft, 1, 2, 0, /* -Return the canonical symbol whose name is STRING, or nil if none exists. +Return the canonical symbol named NAME, or nil if none exists. +NAME may be a string or a symbol. If it is a symbol, that exact +symbol is searched for. A second optional argument specifies the obarray to use; it defaults to the value of `obarray'. */ - (string, obarray)) + (name, obarray)) { + /* #### Bug! (intern-soft "nil") returns nil. Perhaps we should + add a DEFAULT-IF-NOT-FOUND arg, like in get. */ Lisp_Object tem; + struct Lisp_String *string; if (NILP (obarray)) obarray = Vobarray; obarray = check_obarray (obarray); - CHECK_STRING (string); + if (!SYMBOLP (name)) + { + CHECK_STRING (name); + string = XSTRING (name); + } + else + string = symbol_name (XSYMBOL (name)); - tem = oblookup (obarray, XSTRING_DATA (string), XSTRING_LENGTH (string)); - return !INTP (tem) ? tem : Qnil; + tem = oblookup (obarray, string_data (string), string_length (string)); + if (INTP (tem) || (SYMBOLP (name) && !EQ (name, tem))) + return Qnil; + else + return tem; } DEFUN ("unintern", Funintern, 1, 2, 0, /* @@ -241,21 +246,22 @@ OBARRAY defaults to the value of the variable `obarray' */ (name, obarray)) { - Lisp_Object string, tem; + Lisp_Object tem; + struct Lisp_String *string; int hash; if (NILP (obarray)) obarray = Vobarray; obarray = check_obarray (obarray); if (SYMBOLP (name)) - XSETSTRING (string, XSYMBOL (name)->name); + string = symbol_name (XSYMBOL (name)); else { CHECK_STRING (name); - string = name; + string = XSTRING (name); } - tem = oblookup (obarray, XSTRING_DATA (string), XSTRING_LENGTH (string)); + tem = oblookup (obarray, string_data (string), string_length (string)); if (INTP (tem)) return Qnil; /* If arg was a symbol, don't delete anything but that symbol itself. */ @@ -287,7 +293,6 @@ OBARRAY defaults to the value of the variable `obarray' } } } - XSYMBOL (tem)->obarray = Qnil; return Qt; } @@ -310,11 +315,6 @@ oblookup (Lisp_Object obarray, CONST Bufbyte *ptr, Bytecount size) obarray = check_obarray (obarray); obsize = XVECTOR_LENGTH (obarray); } -#if 0 /* FSFmacs */ - /* #### Huh? */ - /* This is sometimes needed in the middle of GC. */ - obsize &= ~ARRAY_MARK_FLAG; -#endif hash = hash_string (ptr, size) % obsize; oblookup_last_bucket_number = hash; bucket = XVECTOR_DATA (obarray)[hash]; @@ -558,8 +558,7 @@ reject_constant_symbols (Lisp_Object sym, Lisp_Object newval, int function_p, sym); if (symbol_is_constant (sym, val) - || (SYMBOL_IS_KEYWORD (sym) && !EQ (newval, sym) - && !NILP (XSYMBOL (sym)->obarray))) + || (SYMBOL_IS_KEYWORD (sym) && !EQ (newval, sym))) signal_error (Qsetting_constant, UNBOUNDP (newval) ? list1 (sym) : list2 (sym, newval)); } @@ -2035,7 +2034,7 @@ sets it. { struct symbol_value_buffer_local *bfwd = alloc_lcrecord_type (struct symbol_value_buffer_local, - lrecord_symbol_value_buffer_local); + &lrecord_symbol_value_buffer_local); Lisp_Object foo; bfwd->magic.type = SYMVAL_BUFFER_LOCAL; @@ -2143,7 +2142,7 @@ Use `make-local-hook' instead. /* Make sure variable is set up to hold per-buffer values */ bfwd = alloc_lcrecord_type (struct symbol_value_buffer_local, - lrecord_symbol_value_buffer_local); + &lrecord_symbol_value_buffer_local); bfwd->magic.type = SYMVAL_SOME_BUFFER_LOCAL; bfwd->current_buffer = Qnil; @@ -2863,7 +2862,7 @@ pity, thereby invalidating your code. if (!SYMBOL_VALUE_LISP_MAGIC_P (valcontents)) { bfwd = alloc_lcrecord_type (struct symbol_value_lisp_magic, - lrecord_symbol_value_lisp_magic); + &lrecord_symbol_value_lisp_magic); bfwd->magic.type = SYMVAL_LISP_MAGIC; for (i = 0; i < MAGIC_HANDLER_MAX; i++) { @@ -2999,7 +2998,7 @@ has a buffer-local value in any buffer, or the symbols nil or t. reject_constant_symbols (variable, Qunbound, 0, Qt); bfwd = alloc_lcrecord_type (struct symbol_value_varalias, - lrecord_symbol_value_varalias); + &lrecord_symbol_value_varalias); bfwd->magic.type = SYMVAL_VARALIAS; bfwd->aliasee = alias; bfwd->shadowed = valcontents; @@ -3079,8 +3078,6 @@ static struct symbol_value_magic guts_of_unbound_marker = { { symbol_value_forward_lheader_initializer, 0, 69}, SYMVAL_UNBOUND_MARKER }; -Lisp_Object Vpure_uninterned_symbol_table; - void init_symbols_once_early (void) { @@ -3094,14 +3091,9 @@ init_symbols_once_early (void) XSETOBJ (Qnull_pointer, (enum Lisp_Type) 0, 0); #endif - /* see comment in Fpurecopy() */ - Vpure_uninterned_symbol_table = - make_lisp_hash_table (50, HASH_TABLE_NON_WEAK, HASH_TABLE_EQ); - staticpro (&Vpure_uninterned_symbol_table); - - Qnil = Fmake_symbol (make_pure_pname ((CONST Bufbyte *) "nil", 3, 1)); - /* Bootstrapping problem: Qnil isn't set when make_pure_pname is + /* Bootstrapping problem: Qnil isn't set when make_string_nocopy is called the first time. */ + Qnil = Fmake_symbol (make_string_nocopy ((CONST Bufbyte *) "nil", 3)); XSYMBOL (Qnil)->name->plist = Qnil; XSYMBOL (Qnil)->value = Qnil; /* Nihil ex nihil */ XSYMBOL (Qnil)->plist = Qnil; @@ -3113,7 +3105,6 @@ init_symbols_once_early (void) { int hash = hash_string (string_data (XSYMBOL (Qnil)->name), 3); XVECTOR_DATA (Vobarray)[hash % OBARRAY_SIZE] = Qnil; - XSYMBOL (Qnil)->obarray = Qt; } { @@ -3145,8 +3136,8 @@ init_symbols_once_early (void) void defsymbol (Lisp_Object *location, CONST char *name) { - *location = Fintern (make_pure_pname ((CONST Bufbyte *) name, - strlen (name), 1), + *location = Fintern (make_string_nocopy ((CONST Bufbyte *) name, + strlen (name)), Qnil); staticpro (location); } @@ -3372,8 +3363,8 @@ defvar_magic (CONST char *symbol_name, CONST struct symbol_value_forward *magic) sym = Fintern (build_string (symbol_name), Qnil); else #endif - sym = Fintern (make_pure_pname ((CONST Bufbyte *) symbol_name, - strlen (symbol_name), 1), Qnil); + sym = Fintern (make_string_nocopy ((CONST Bufbyte *) symbol_name, + strlen (symbol_name)), Qnil); XSETOBJ (XSYMBOL (sym)->value, Lisp_Type_Record, magic); } diff --git a/src/symeval.h b/src/symeval.h index effd36b..8aff8d2 100644 --- a/src/symeval.h +++ b/src/symeval.h @@ -293,12 +293,7 @@ void deferror (Lisp_Object *symbol, CONST char *name, void defvar_magic (CONST char *symbol_name, CONST struct symbol_value_forward *magic); -#ifdef USE_INDEXED_LRECORD_IMPLEMENTATION -# define symbol_value_forward_lheader_initializer { 1, 0, 0 } -#else -# define symbol_value_forward_lheader_initializer \ - { lrecord_symbol_value_forward } -#endif +#define symbol_value_forward_lheader_initializer { 1, { 0, 0, 0 } } #define DEFVAR_SYMVAL_FWD(lname, c_location, forward_type, magicfun) do { \ static CONST_IF_NOT_DEBUG struct symbol_value_forward I_hate_C \ diff --git a/src/symsinit.h b/src/symsinit.h index 7e05629..9195a25 100644 --- a/src/symsinit.h +++ b/src/symsinit.h @@ -115,6 +115,7 @@ void syms_of_mule_ccl (void); void syms_of_mule_charset (void); void syms_of_mule_coding (void); void syms_of_mule_wnn (void); +void syms_of_ntproc (void); void syms_of_objects_tty (void); void syms_of_objects_x (void); void syms_of_objects_mswindows (void); diff --git a/src/syntax.c b/src/syntax.c index 33b396e..82a8034 100644 --- a/src/syntax.c +++ b/src/syntax.c @@ -1652,8 +1652,8 @@ complex_vars_of_syntax (void) Vstandard_syntax_table = Fcopy_syntax_table (Qnil); staticpro (&Vstandard_syntax_table); - Vsyntax_designator_chars_string = make_pure_string (syntax_code_spec, - Smax, Qnil, 1); + Vsyntax_designator_chars_string = make_string_nocopy (syntax_code_spec, + Smax); staticpro (&Vsyntax_designator_chars_string); fill_char_table (XCHAR_TABLE (Vstandard_syntax_table), diff --git a/src/sysdep.c b/src/sysdep.c index 528665f..7024e35 100644 --- a/src/sysdep.c +++ b/src/sysdep.c @@ -33,6 +33,7 @@ Boston, MA 02111-1307, USA. */ #ifdef WINDOWSNT #include +#ifndef __MINGW32__ /* should not conflict with "process.h", as per ANSI definition. This is not true though with visual c though. The trick below works with VC4.2b and with VC5.0. It assumes that VC is installed in a kind of @@ -42,6 +43,9 @@ Boston, MA 02111-1307, USA. */ which will conflict with the macro defined in lisp.h */ #include <../include/process.h> +#else +#include +#endif #endif /* WINDOWSNT */ #include "lisp.h" @@ -2261,42 +2265,43 @@ init_system_name (void) # ifndef CANNOT_DUMP if (initialized) # endif /* not CANNOT_DUMP */ - { - struct hostent *hp = NULL; - int count; + if (!strchr (hostname, '.')) + { + struct hostent *hp = NULL; + int count; # ifdef TRY_AGAIN - for (count = 0; count < 10; count++) - { - h_errno = 0; + for (count = 0; count < 10; count++) + { + h_errno = 0; # endif - /* Some systems can't handle SIGALARM/SIGIO in gethostbyname(). */ - stop_interrupts (); - hp = gethostbyname (hostname); - start_interrupts (); + /* Some systems can't handle SIGALARM/SIGIO in gethostbyname(). */ + stop_interrupts (); + hp = gethostbyname (hostname); + start_interrupts (); # ifdef TRY_AGAIN - if (! (hp == 0 && h_errno == TRY_AGAIN)) - break; - Fsleep_for (make_int (1)); - } + if (! (hp == 0 && h_errno == TRY_AGAIN)) + break; + Fsleep_for (make_int (1)); + } # endif - if (hp) - { - CONST char *fqdn = (CONST char *) hp->h_name; - - if (!strchr (fqdn, '.')) - { - /* We still don't have a fully qualified domain name. - Try to find one in the list of alternate names */ - char **alias = hp->h_aliases; - while (*alias && !strchr (*alias, '.')) - alias++; - if (*alias) - fqdn = *alias; - } - hostname = (char *) alloca (strlen (fqdn) + 1); - strcpy (hostname, fqdn); - } - } + if (hp) + { + CONST char *fqdn = (CONST char *) hp->h_name; + + if (!strchr (fqdn, '.')) + { + /* We still don't have a fully qualified domain name. + Try to find one in the list of alternate names */ + char **alias = hp->h_aliases; + while (*alias && !strchr (*alias, '.')) + alias++; + if (*alias) + fqdn = *alias; + } + hostname = (char *) alloca (strlen (fqdn) + 1); + strcpy (hostname, fqdn); + } + } # endif /* HAVE_SOCKETS */ Vsystem_name = build_string (hostname); #endif /* HAVE_GETHOSTNAME */ diff --git a/src/sysdir.h b/src/sysdir.h index 3616ef6..aee0223 100644 --- a/src/sysdir.h +++ b/src/sysdir.h @@ -26,7 +26,7 @@ Boston, MA 02111-1307, USA. */ #ifdef SYSV_SYSTEM_DIR # include -#elif defined (NONSYSTEM_DIR_LIBRARY) +#elif defined (NONSYSTEM_DIR_LIBRARY) # include "ndir.h" #elif defined (MSDOS) # include diff --git a/src/systime.h b/src/systime.h index 40c559b..2f01157 100644 --- a/src/systime.h +++ b/src/systime.h @@ -231,7 +231,7 @@ int set_file_times (char *filename, EMACS_TIME atime, EMACS_TIME mtime); void get_process_times (double *user_time, double *system_time, double *real_time); -#if defined(WINDOWSNT) || defined(BROKEN_CYGWIN) +#if defined(WINDOWSNT) || defined(BROKEN_CYGWIN) || defined(__MINGW32__) /* setitimer emulation for Win32 (see nt.c) */ diff --git a/src/systty.h b/src/systty.h index 7251557..3f9efdb 100644 --- a/src/systty.h +++ b/src/systty.h @@ -337,6 +337,8 @@ Boston, MA 02111-1307, USA. */ No big loss -- it just means that ^Z won't work right if we're run from sh. */ # define EMACS_SET_PROCESS_GROUP(pg) +#elif defined(__MINGW32__) +# define EMACS_SEPARATE_PROCESS_GROUP() #else /* Under NeXTstep, a process group of 0 is not the same as specifying your own process ID, so we go ahead and specify it explicitly. */ diff --git a/src/toolbar-msw.c b/src/toolbar-msw.c index 1f978cc..ca86e9d 100644 --- a/src/toolbar-msw.c +++ b/src/toolbar-msw.c @@ -205,10 +205,11 @@ mswindows_output_toolbar (struct frame *f, enum toolbar_pos pos) { struct toolbar_button *tb = XTOOLBAR_BUTTON (button); - checksum = HASH4 (checksum, + checksum = HASH5 (checksum, internal_hash (get_toolbar_button_glyph(w, tb), 0), internal_hash (tb->callback, 0), - width); + width, + w->toolbar_buttons_captioned_p); button = tb->next; nbuttons++; } diff --git a/src/toolbar.c b/src/toolbar.c index 1fbb435..64ff6ed 100644 --- a/src/toolbar.c +++ b/src/toolbar.c @@ -303,7 +303,7 @@ update_toolbar_button (struct frame *f, struct toolbar_button *tb, if (!tb) { - tb = alloc_lcrecord_type (struct toolbar_button, lrecord_toolbar_button); + tb = alloc_lcrecord_type (struct toolbar_button, &lrecord_toolbar_button); tb->next = Qnil; XSETFRAME (tb->frame, f); tb->up_glyph = Qnil; diff --git a/src/tooltalk.c b/src/tooltalk.c index ac76e22..a7e0ed9 100644 --- a/src/tooltalk.c +++ b/src/tooltalk.c @@ -184,7 +184,7 @@ make_tooltalk_message (Tt_message m) Lisp_Object val; struct Lisp_Tooltalk_Message *msg = alloc_lcrecord_type (struct Lisp_Tooltalk_Message, - lrecord_tooltalk_message); + &lrecord_tooltalk_message); msg->m = m; msg->callback = Qnil; @@ -257,7 +257,7 @@ make_tooltalk_pattern (Tt_pattern p) { struct Lisp_Tooltalk_Pattern *pat = alloc_lcrecord_type (struct Lisp_Tooltalk_Pattern, - lrecord_tooltalk_pattern); + &lrecord_tooltalk_pattern); Lisp_Object val; pat->p = p; diff --git a/src/unexcw.c b/src/unexcw.c index 6d65e61..276f5ff 100644 --- a/src/unexcw.c +++ b/src/unexcw.c @@ -21,7 +21,7 @@ Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA */ /* This is a complete rewrite, some code snarfed from unexnt.c and - unexec.c, Andy Piper (andyp@parallax.co.uk) 13-1-98 */ + unexec.c, Andy Piper (andy@xemacs.org) 13-1-98 */ #include #include diff --git a/src/unexnt.c b/src/unexnt.c index d8d613a..60c8fe4 100644 --- a/src/unexnt.c +++ b/src/unexnt.c @@ -261,38 +261,6 @@ unexec (char *new_name, char *old_name, void *start_data, void *start_bss, int -open_input_file (file_data *p_file, char *filename) -{ - HANDLE file; - HANDLE file_mapping; - void *file_base; - unsigned long size, upper_size; - - file = CreateFile (filename, GENERIC_READ, FILE_SHARE_READ, NULL, - OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0); - if (file == INVALID_HANDLE_VALUE) - return FALSE; - - size = GetFileSize (file, &upper_size); - file_mapping = CreateFileMapping (file, NULL, PAGE_READONLY, - 0, size, NULL); - if (!file_mapping) - return FALSE; - - file_base = MapViewOfFile (file_mapping, FILE_MAP_READ, 0, 0, size); - if (file_base == 0) - return FALSE; - - p_file->name = filename; - p_file->size = size; - p_file->file = file; - p_file->file_mapping = file_mapping; - p_file->file_base = file_base; - - return TRUE; -} - -int open_output_file (file_data *p_file, char *filename, unsigned long size) { HANDLE file; @@ -322,16 +290,6 @@ open_output_file (file_data *p_file, char *filename, unsigned long size) return TRUE; } -/* Close the system structures associated with the given file. */ -void -close_file_data (file_data *p_file) -{ - UnmapViewOfFile (p_file->file_base); - CloseHandle (p_file->file_mapping); - CloseHandle (p_file->file); -} - - /* Routines to manipulate NT executable file sections. */ #ifndef DUMP_SEPARATE_SECTION @@ -375,27 +333,6 @@ get_bss_info_from_map_file (file_data *p_infile, PUCHAR *p_bss_start, } #endif -/* Return pointer to section header for section containing the given - relative virtual address. */ -IMAGE_SECTION_HEADER * -rva_to_section (DWORD rva, IMAGE_NT_HEADERS * nt_header) -{ - PIMAGE_SECTION_HEADER section; - int i; - - section = IMAGE_FIRST_SECTION (nt_header); - - for (i = 0; i < nt_header->FileHeader.NumberOfSections; i++) - { - if (rva >= section->VirtualAddress - && rva < section->VirtualAddress + section->SizeOfRawData) - return section; - section++; - } - return NULL; -} - - /* Flip through the executable and cache the info necessary for dumping. */ static void get_section_info (file_data *p_infile) diff --git a/src/window.c b/src/window.c index 2f3a6b8..868156c 100644 --- a/src/window.c +++ b/src/window.c @@ -252,7 +252,7 @@ Lisp_Object allocate_window (void) { Lisp_Object val; - struct window *p = alloc_lcrecord_type (struct window, lrecord_window); + struct window *p = alloc_lcrecord_type (struct window, &lrecord_window); zero_lcrecord (p); XSETWINDOW (val, p); @@ -3319,7 +3319,7 @@ make_dummy_parent (Lisp_Object window) { Lisp_Object new; struct window *o = XWINDOW (window); - struct window *p = alloc_lcrecord_type (struct window, lrecord_window); + struct window *p = alloc_lcrecord_type (struct window, &lrecord_window); XSETWINDOW (new, p); copy_lcrecord (p, o); @@ -4621,8 +4621,8 @@ struct saved_window struct window_config { struct lcrecord_header header; - int frame_width; - int frame_height; + /* int frame_width; No longer needed, JV + int frame_height; */ #if 0 /* FSFmacs */ Lisp_Object selected_frame; #endif @@ -4630,6 +4630,7 @@ struct window_config Lisp_Object current_buffer; Lisp_Object minibuffer_scroll_window; Lisp_Object root_window; + int minibuf_height; /* 0 = no minibuffer, <0, size in lines, >0 in pixels */ /* Record the values of window-min-width and window-min-height so that window sizes remain consistent with them. */ int min_width, min_height; @@ -4761,9 +4762,10 @@ window_config_equal (Lisp_Object conf1, Lisp_Object conf2) EQ (fig1->current_window, fig2->current_window) && EQ (fig1->current_buffer, fig2->current_buffer) && EQ (fig1->root_window, fig2->root_window) && - EQ (fig1->minibuffer_scroll_window, fig2->minibuffer_scroll_window) && + EQ (fig1->minibuffer_scroll_window, fig2->minibuffer_scroll_window))) + /* && fig1->frame_width == fig2->frame_width && - fig1->frame_height == fig2->frame_height)) + fig1->frame_height == fig2->frame_height)) */ return 0; for (i = 0; i < fig1->saved_windows_count; i++) @@ -4859,8 +4861,15 @@ by `current-window-configuration' (which see). struct frame *f; struct gcpro gcpro1; Lisp_Object old_window_config; - int previous_frame_height; - int previous_frame_width; + /* int previous_frame_height; + int previous_frame_width;*/ + int previous_pixel_top; + int previous_pixel_height; + int previous_pixel_left; + int previous_pixel_width; + int previous_minibuf_height, previous_minibuf_top,previous_minibuf_width; + int real_font_height; + int converted_minibuf_height,target_minibuf_height; int specpdl_count = specpdl_depth (); GCPRO1 (configuration); @@ -4925,6 +4934,20 @@ by `current-window-configuration' (which see). mark_windows_in_use (f, 1); +#if 0 + /* JV: This is bogus, + First of all, the units are inconsistent. The frame sizes are measured + in characters but the window sizes are stored in pixels. So if a + font size change happened between saving and restoring, the + frame "sizes" maybe equal but the windows still should be + resized. This is tickled alot by the new "character size + stays constant" policy in 21.0. It leads to very wierd + glitches (and possibly craches when asserts are tickled). + + Just changing the units doens't help because changing the + toolbar configuration can also change the pixel positions. + Luckily there is a much simpler way of doing this, see below. + */ previous_frame_width = FRAME_WIDTH (f); previous_frame_height = FRAME_HEIGHT (f); /* If the frame has been resized since this window configuration was @@ -4934,7 +4957,37 @@ by `current-window-configuration' (which see). if (config->frame_height != FRAME_HEIGHT (f) || config->frame_width != FRAME_WIDTH (f)) change_frame_size (f, config->frame_height, config->frame_width, 0); - +#endif + + previous_pixel_top = XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_top; + previous_pixel_height = XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_height; + previous_pixel_left = XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_left; + previous_pixel_width = XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_width; + + /* remember some properties of the minibuffer */ + + default_face_height_and_width (frame, &real_font_height, 0); + assert(real_font_height > 0); + + if (FRAME_HAS_MINIBUF_P (f) && ! FRAME_MINIBUF_ONLY_P (f)) + { + previous_minibuf_height + = XWINDOW(FRAME_MINIBUF_WINDOW(f))->pixel_height; + previous_minibuf_top + = XWINDOW(FRAME_MINIBUF_WINDOW(f))->pixel_top; + previous_minibuf_width + = XWINDOW(FRAME_MINIBUF_WINDOW(f))->pixel_width; + } + else + { + previous_minibuf_height = 0; + previous_minibuf_width = 0; + } + converted_minibuf_height = + (previous_minibuf_height % real_font_height) == 0 ? + - (previous_minibuf_height / real_font_height ) : /* lines */ + previous_minibuf_height; /* pixels */ + /* Temporarily avoid any problems with windows that are smaller than they are supposed to be. */ window_min_height = 1; @@ -5100,11 +5153,61 @@ by `current-window-configuration' (which see). currently selected, or just set the selected window of the window config's frame. */ +#if 0 /* Set the frame height to the value it had before this function. */ if (previous_frame_height != FRAME_HEIGHT (f) || previous_frame_width != FRAME_WIDTH (f)) change_frame_size (f, previous_frame_height, previous_frame_width, 0); - +#endif + /* We just reset the size and position of the minibuffer, to its old + value, which needn't be valid. So we do some magic to see which value + to actually take. Then we set it. + + The magic: + We take the old value if is in the same units but differs from the + current value. + + #### Now we get more cases correct then ever before, but + are we treating all? For instance what if the frames minibuf window + is no longer the same one? + */ + target_minibuf_height = previous_minibuf_height; + if (converted_minibuf_height && + (converted_minibuf_height * config->minibuf_height) > 0 && + (converted_minibuf_height != config->minibuf_height)) + { + target_minibuf_height = config->minibuf_height < 0 ? + - (config->minibuf_height * real_font_height) : + config->minibuf_height; + target_minibuf_height = + max(target_minibuf_height,real_font_height); + } + if (previous_minibuf_height) + { + XWINDOW (FRAME_MINIBUF_WINDOW (f))->pixel_top + = previous_minibuf_top - + (target_minibuf_height - previous_minibuf_height); + set_window_pixheight (FRAME_MINIBUF_WINDOW (f), + target_minibuf_height, 0); + set_window_pixwidth (FRAME_MINIBUF_WINDOW (f), + previous_minibuf_width, 0); + } + + /* This is a better way to deal with frame resizing, etc. + What we _actually_ want is for the old (just restored) + root window to fit + into the place of the new one. So we just do that. Simple! */ + XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_top = previous_pixel_top; + /* Note that this function also updates the subwindow + "pixel_top"s */ + set_window_pixheight (FRAME_ROOT_WINDOW (f), + previous_pixel_height - + (target_minibuf_height - previous_minibuf_height), 0); + XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_left = previous_pixel_left; + /* Note that this function also updates the subwindow + "pixel_left"s */ + set_window_pixwidth (FRAME_ROOT_WINDOW (f), previous_pixel_width, 0); + /* If restoring in the current frame make the window current, otherwise just update the frame selected_window slot to be the restored current_window. */ @@ -5319,6 +5422,8 @@ its value is -not- saved. struct frame *f = decode_frame (frame); struct window_config *config; int n_windows = count_windows (XWINDOW (FRAME_ROOT_WINDOW (f))); + int minibuf_height; + int real_font_height; if (n_windows <= countof (Vwindow_configuration_free_list)) config = XWINDOW_CONFIGURATION (allocate_managed_lcrecord @@ -5328,11 +5433,11 @@ its value is -not- saved. /* More than ten windows; just allocate directly */ config = (struct window_config *) alloc_lcrecord (sizeof_window_config_for_n_windows (n_windows), - lrecord_window_configuration); + &lrecord_window_configuration); XSETWINDOW_CONFIGURATION (result, config); - + /* config->frame_width = FRAME_WIDTH (f); - config->frame_height = FRAME_HEIGHT (f); + config->frame_height = FRAME_HEIGHT (f); */ config->current_window = FRAME_SELECTED_WINDOW (f); XSETBUFFER (config->current_buffer, current_buffer); config->minibuffer_scroll_window = Vminibuffer_scroll_window; @@ -5341,6 +5446,22 @@ its value is -not- saved. config->min_width = window_min_width; config->saved_windows_count = n_windows; save_window_save (FRAME_ROOT_WINDOW (f), config, 0); + + /* save the minibuffer height using the heuristics from + change_frame_size_1 */ + + XSETFRAME (frame, f); /* frame could have been nil ! */ + default_face_height_and_width (frame, &real_font_height, 0); + assert(real_font_height > 0); + + if (FRAME_HAS_MINIBUF_P (f) && ! FRAME_MINIBUF_ONLY_P (f)) + minibuf_height = XWINDOW(FRAME_MINIBUF_WINDOW(f))->pixel_height; + else + minibuf_height = 0; + config->minibuf_height = (minibuf_height % real_font_height) == 0 ? + - (minibuf_height / real_font_height ) : /* lines */ + minibuf_height; /* pixels */ + return result; } @@ -5577,7 +5698,7 @@ If non-nil, this is a buffer and \\[scroll-other-window] should scroll its windo { Vwindow_configuration_free_list[i] = make_lcrecord_list (sizeof_window_config_for_n_windows (i + 1), - lrecord_window_configuration); + &lrecord_window_configuration); staticpro (&Vwindow_configuration_free_list[i]); } } diff --git a/tests/ChangeLog b/tests/ChangeLog index 5e76e0a..909e4df 100644 --- a/tests/ChangeLog +++ b/tests/ChangeLog @@ -1,3 +1,30 @@ +1999-05-14 XEmacs Build Bot + + * XEmacs 21.2.14 is released + +1999-05-06 Hrvoje Niksic + + * automated/symbol-tests.el: Add many more tests. + +1999-05-06 Hrvoje Niksic + + * automated/lisp-tests.el: Ditto. + + * automated/hash-table-tests.el: Ditto. + + * automated/database-tests.el: Don't use backquote where quote + would suffice. + + * automated/symbol-tests.el: Add tests for magic symbols. + +1999-05-04 Hrvoje Niksic + + * automated/hash-table-tests.el: Fix comment. + +1999-04-22 Hrvoje Niksic + + * automated/test-harness.el (batch-test-emacs): Minor fixes. + 1999-03-12 XEmacs Build Bot * XEmacs 21.2.13 is released diff --git a/tests/automated/byte-compiler-tests.el b/tests/automated/byte-compiler-tests.el index efd7bf5..87612ae 100644 --- a/tests/automated/byte-compiler-tests.el +++ b/tests/automated/byte-compiler-tests.el @@ -22,7 +22,7 @@ ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ;; 02111-1307, USA. -;;; Synched up with: not in FSF Emacs. +;;; Synched up with: Not in FSF. ;;; Commentary: diff --git a/tests/automated/database-tests.el b/tests/automated/database-tests.el index 62296e0..3c489a8 100644 --- a/tests/automated/database-tests.el +++ b/tests/automated/database-tests.el @@ -22,7 +22,7 @@ ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ;; 02111-1307, USA. -;;; Synched up with: not in FSF Emacs. +;;; Synched up with: Not in FSF. ;;; Commentary: @@ -52,7 +52,7 @@ (let ((filename (expand-file-name "test-harness" (temp-directory)))) - (dolist (db-type `(dbm berkeley-db)) + (dolist (db-type '(dbm berkeley-db)) (when (featurep db-type) (princ "\n") (delete-database-files filename) diff --git a/tests/automated/hash-table-tests.el b/tests/automated/hash-table-tests.el index c813f5f..d68e399 100644 --- a/tests/automated/hash-table-tests.el +++ b/tests/automated/hash-table-tests.el @@ -22,11 +22,11 @@ ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ;; 02111-1307, USA. -;;; Synched up with: not in FSF Emacs. +;;; Synched up with: Not in FSF. ;;; Commentary: -;;; Test database functionality +;;; Test hash tables implementation ;;; See test-harness.el (condition-case err @@ -37,12 +37,12 @@ (require 'test-harness)))) ;; Test all combinations of make-hash-table keywords -(dolist (type `(non-weak weak key-weak value-weak)) - (dolist (test `(eq eql equal)) - (dolist (size `(0 1 100)) - (dolist (rehash-size `(1.1 9.9)) - (dolist (rehash-threshold `(0.2 .9)) - (dolist (data `(() (1 2) (1 2 3 4))) +(dolist (type '(non-weak weak key-weak value-weak)) + (dolist (test '(eq eql equal)) + (dolist (size '(0 1 100)) + (dolist (rehash-size '(1.1 9.9)) + (dolist (rehash-threshold '(0.2 .9)) + (dolist (data '(() (1 2) (1 2 3 4))) (let ((ht (make-hash-table :test test :type type :size size @@ -56,7 +56,7 @@ (Assert (eql rehash-size (hash-table-rehash-size ht))) (Assert (eql rehash-threshold (hash-table-rehash-threshold ht)))))))))) -(loop for (fun type) in `((make-hashtable non-weak) +(loop for (fun type) in '((make-hashtable non-weak) (make-weak-hashtable weak) (make-key-weak-hashtable key-weak) (make-value-weak-hashtable value-weak)) @@ -194,7 +194,7 @@ ;; Test that weak hash-tables are properly handled (loop for (type expected-count expected-k-sum expected-v-sum) in - `((non-weak 6 38 25) + '((non-weak 6 38 25) (weak 3 6 9) (key-weak 4 38 9) (value-weak 4 6 25)) diff --git a/tests/automated/lisp-tests.el b/tests/automated/lisp-tests.el index 3a45ce1..1349070 100644 --- a/tests/automated/lisp-tests.el +++ b/tests/automated/lisp-tests.el @@ -22,7 +22,7 @@ ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ;; 02111-1307, USA. -;;; Synched up with: not in FSF Emacs. +;;; Synched up with: Not in FSF. ;;; Commentary: @@ -119,7 +119,7 @@ (Check-Error wrong-type-argument (nconc 'foo nil)) -(dolist (length `(1 2 3 4 1000 2000)) +(dolist (length '(1 2 3 4 1000 2000)) (Check-Error circular-list (nconc (make-circular-list length) 'foo)) (Check-Error circular-list (nconc '(1 . 2) (make-circular-list length) 'foo)) (Check-Error circular-list (nconc '(1 . 2) '(3 . 4) (make-circular-list length) 'foo))) @@ -158,7 +158,7 @@ (Assert (eq (last x 3) (cdr x))) (Assert (eq (last x 4) x)) (Assert (eq (last x 9) x)) - (Assert (eq (last `(1 . 2) 0) 2)) + (Assert (eq (last '(1 . 2) 0) 2)) ) ;;----------------------------------------------------- @@ -213,7 +213,7 @@ (Check-Error circular-list (copy-list (make-circular-list 1))) (Check-Error circular-list (copy-list (make-circular-list 2000))) (Assert (eq '() (copy-list '()))) -(dolist (x `((1) (1 2) (1 2 3) (1 2 . 3))) +(dolist (x '((1) (1 2) (1 2 3) (1 2 . 3))) (let ((y (copy-list x))) (Assert (and (equal x y) (not (eq x y)))))) @@ -242,7 +242,7 @@ (Assert (= (- one one) 0)) (Assert (= (- one one one) -1)) (Assert (= (+ one 1) 2)) - (dolist (zero `(0 0.0 ?\0)) + (dolist (zero '(0 0.0 ?\0)) (Assert (= (+ 1 zero) 1)) (Assert (= (+ zero 1) 1)) (Assert (= (- zero) zero)) @@ -256,7 +256,7 @@ ;; Test `/' ;; Test division by zero errors -(dolist (zero `(0 0.0 ?\0)) +(dolist (zero '(0 0.0 ?\0)) (Check-Error arith-error (/ zero)) (dolist (n1 `(42 42.0 ?\042 ,(Int-to-Marker 42))) (Check-Error arith-error (/ n1 zero)) @@ -269,14 +269,14 @@ (Assert (= (/ (setq x 2)) 0)) (Assert (= (/ (setq x 2.0)) 0.5))) -(dolist (six `(6 6.0 ?\06)) - (dolist (two `(2 2.0 ?\02)) - (dolist (three `(3 3.0 ?\03)) +(dolist (six '(6 6.0 ?\06)) + (dolist (two '(2 2.0 ?\02)) + (dolist (three '(3 3.0 ?\03)) (Assert (= (/ six two) three))))) -(dolist (three `(3 3.0 ?\03)) +(dolist (three '(3 3.0 ?\03)) (Assert (= (/ three 2.0) 1.5))) -(dolist (two `(2 2.0 ?\02)) +(dolist (two '(2 2.0 ?\02)) (Assert (= (/ 3.0 two) 1.5))) ;; Test `*' @@ -285,18 +285,18 @@ (dolist (one `(1 1.0 ?\01 ,(Int-to-Marker 1))) (Assert (= 1 (* one)))) -(dolist (two `(2 2.0 ?\02)) +(dolist (two '(2 2.0 ?\02)) (Assert (= 2 (* two)))) -(dolist (six `(6 6.0 ?\06)) - (dolist (two `(2 2.0 ?\02)) - (dolist (three `(3 3.0 ?\03)) +(dolist (six '(6 6.0 ?\06)) + (dolist (two '(2 2.0 ?\02)) + (dolist (three '(3 3.0 ?\03)) (Assert (= (* three two) six))))) -(dolist (three `(3 3.0 ?\03)) - (dolist (two `(2 2.0 ?\02)) +(dolist (three '(3 3.0 ?\03)) + (dolist (two '(2 2.0 ?\02)) (Assert (= (* 1.5 two) three)) - (dolist (five `(5 5.0 ?\05)) + (dolist (five '(5 5.0 ?\05)) (Assert (= 30 (* five two three)))))) ;; Test `+' @@ -305,12 +305,12 @@ (dolist (one `(1 1.0 ?\01 ,(Int-to-Marker 1))) (Assert (= 1 (+ one)))) -(dolist (two `(2 2.0 ?\02)) +(dolist (two '(2 2.0 ?\02)) (Assert (= 2 (+ two)))) -(dolist (five `(5 5.0 ?\05)) - (dolist (two `(2 2.0 ?\02)) - (dolist (three `(3 3.0 ?\03)) +(dolist (five '(5 5.0 ?\05)) + (dolist (two '(2 2.0 ?\02)) + (dolist (three '(3 3.0 ?\03)) (Assert (= (+ three two) five)) (Assert (= 10 (+ five two three)))))) @@ -341,7 +341,7 @@ (Check-Error wrong-type-argument (logior 3.0)) (Check-Error wrong-type-argument (logand 3.0)) -(dolist (three `(3 ?\03)) +(dolist (three '(3 ?\03)) (Assert (eq 3 (logand three))) (Assert (eq 3 (logxor three))) (Assert (eq 3 (logior three))) @@ -350,11 +350,11 @@ (Assert (eq 3 (logior three three)))) (dolist (one `(1 ?\01 ,(Int-to-Marker 1))) - (dolist (two `(2 ?\02)) + (dolist (two '(2 ?\02)) (Assert (eq 0 (logand one two))) (Assert (eq 3 (logior one two))) (Assert (eq 3 (logxor one two)))) - (dolist (three `(3 ?\03)) + (dolist (three '(3 ?\03)) (Assert (eq 1 (logand one three))) (Assert (eq 3 (logior one three))) (Assert (eq 2 (logxor one three))))) @@ -468,7 +468,7 @@ ;; Meat (dolist (one `(1 1.0 ,(Int-to-Marker 1) ?\01)) - (dolist (two `(2 2.0 ?\02)) + (dolist (two '(2 2.0 ?\02)) (Assert (< one two)) (Assert (<= one two)) (Assert (<= two two)) @@ -489,7 +489,7 @@ )) (dolist (one `(1 1.0 ,(Int-to-Marker 1) ?\01)) - (dolist (two `(2 2.0 ?\02)) + (dolist (two '(2 2.0 ?\02)) (Assert (< one two)) (Assert (<= one two)) (Assert (<= two two)) @@ -537,7 +537,7 @@ (Check-Error wrong-number-of-arguments (,fun)) (Check-Error wrong-number-of-arguments (,fun nil)) (Check-Error malformed-list (,fun nil 1)) - ,@(loop for n in `(1 2 2000) + ,@(loop for n in '(1 2 2000) collect `(Check-Error circular-list (,fun 1 (make-circular-list ,n)))))) (test-funs (&rest funs) `(progn ,@(loop for fun in funs collect `(test-fun ,fun))))) diff --git a/tests/automated/md5-tests.el b/tests/automated/md5-tests.el index 1ebde76..16dba19 100644 --- a/tests/automated/md5-tests.el +++ b/tests/automated/md5-tests.el @@ -22,7 +22,7 @@ ;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ;; 02111-1307, USA. -;;; Synched up with: not in FSF Emacs. +;;; Synched up with: Not in FSF. ;;; Commentary: diff --git a/tests/automated/test-harness.el b/tests/automated/test-harness.el index a5c8b8a..52093f4 100644 --- a/tests/automated/test-harness.el +++ b/tests/automated/test-harness.el @@ -22,7 +22,7 @@ ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, ;; Boston, MA 02111-1307, USA. -;;; Synched up with: Not in FSF +;;; Synched up with: Not in FSF. ;;; Commentary: @@ -31,7 +31,7 @@ ;;; Basically you just create files of emacs-lisp, and use the ;;; Assert, Check-Error, and Check-Message functions to create tests. ;;; You run the tests using M-x test-emacs-test-file, -;;; or $(EMACS) -l .../test-harness.el -f batch-test-emacs file ... +;;; or $(EMACS) -batch -l .../test-harness.el -f batch-test-emacs file ... ;;; which is run for you by the `make check' target in the top-level Makefile. (require 'bytecomp) @@ -42,7 +42,7 @@ (defvar test-harness-current-file nil) -(defvar emacs-lisp-file-regexp (purecopy "\\.el$") +(defvar emacs-lisp-file-regexp (purecopy "\\.el\\'") "*Regexp which matches Emacs Lisp source files.") ;;;###autoload @@ -342,21 +342,17 @@ For example, invoke \"xemacs -batch -f batch-test-emacs tests/*.el\"" (if (not noninteractive) (error "`batch-test-emacs' is to be used only with -batch")) (let ((error nil)) - (loop for file in command-line-args-left - do - (if (file-directory-p (expand-file-name file)) - (let ((files (directory-files file)) - source) - (while files - (if (and (string-match emacs-lisp-file-regexp (car files)) - (not (auto-save-file-name-p (car files))) - (setq source (expand-file-name - (car files) - file)) - (if (null (batch-test-emacs-1 source)) - (setq error t))) - (setq files (cdr files))))) - (if (null (batch-test-emacs-1 file)) + (dolist (file command-line-args-left) + (if (file-directory-p file) + (dolist (file-in-dir (directory-files file t)) + (when (and (string-match emacs-lisp-file-regexp file-in-dir) + (not (or (auto-save-file-name-p file-in-dir) + (backup-file-name-p file-in-dir) + (equal (file-name-nondirectory file-in-dir) + "test-harness.el")))) + (or (batch-test-emacs-1 file-in-dir) + (setq error t)))) + (or (batch-test-emacs-1 file) (setq error t)))) ;;(message "%s" (buffer-string nil nil "*Test-Log*")) (message "Done") diff --git a/version.sh b/version.sh index cc194b8..73ba99c 100644 --- a/version.sh +++ b/version.sh @@ -1,8 +1,8 @@ #!/bin/sh emacs_major_version=21 emacs_minor_version=2 -emacs_beta_version=13 -xemacs_codename="Demeter" +emacs_beta_version=14 +xemacs_codename="Dionysos" infodock_major_version=4 infodock_minor_version=0 -infodock_build_version=1 +infodock_build_version=7 -- 1.7.10.4