commit 7a56e5a44a390aaa29711d63f125f4b802df07c1 (HEAD, refs/remotes/origin/master) Author: Lars Ingebrigtsen Date: Thu Aug 6 09:09:57 2020 +0200 Mark two cconv tests as :unstable * test/lisp/emacs-lisp/cconv-tests.el (cconv-tests-cl-iter-defun-:documentation): Mark as unstable (bug#42723). (cconv-tests-iter-defun-:documentation): Ditto. diff --git a/test/lisp/emacs-lisp/cconv-tests.el b/test/lisp/emacs-lisp/cconv-tests.el index 148bcd69be..0ea9742be4 100644 --- a/test/lisp/emacs-lisp/cconv-tests.el +++ b/test/lisp/emacs-lisp/cconv-tests.el @@ -82,6 +82,7 @@ (ert-deftest cconv-tests-cl-iter-defun-:documentation () "Docstring for cl-iter-defun can be specified with :documentation." ;; FIXME: See Bug#28557. + :tags '(:unstable) :expected-result :failed (should (string= (documentation 'cconv-tests-cl-iter-defun) "cl-iter-defun documentation")) @@ -94,6 +95,7 @@ (ert-deftest cconv-tests-iter-defun-:documentation () "Docstring for iter-defun can be specified with :documentation." ;; FIXME: See Bug#28557. + :tags '(:unstable) :expected-result :failed (should (string= (documentation 'cconv-tests-iter-defun) "iter-defun documentation")) commit 47910420c0fd62976ffa075e35da8a8e3398a836 Author: Lars Ingebrigtsen Date: Thu Aug 6 08:24:56 2020 +0200 Tweak the autoloads scrape output slightly * lisp/emacs-lisp/autoload.el (batch-update-autoloads--summary): Output " ..." at the end of the non-concluding lines to signify that the output continues. diff --git a/lisp/emacs-lisp/autoload.el b/lisp/emacs-lisp/autoload.el index 222a378566..c76de43be9 100644 --- a/lisp/emacs-lisp/autoload.el +++ b/lisp/emacs-lisp/autoload.el @@ -1170,8 +1170,8 @@ write its autoloads into the specified file instead." (defun batch-update-autoloads--summary (strings) (let ((message "")) (while strings - (when (> (length (concat message " " (car strings))) 68) - (byte-compile-info message t "SCRAPE") + (when (> (length (concat message " " (car strings))) 64) + (byte-compile-info (concat message " ...") t "SCRAPE") (setq message "")) (setq message (if (zerop (length message)) (car strings) commit 104dd3b641142671669fc52d33cbcf6cf5f29891 Author: Lars Ingebrigtsen Date: Thu Aug 6 08:20:09 2020 +0200 Make the loaddefs scraping compilation output look more regular * lisp/Makefile.in ($(lisp)/loaddefs.el): Don't output the directories here. * lisp/emacs-lisp/autoload.el (batch-update-autoloads--summary): New function. (batch-update-autoloads): Use it to output the directories we're scraping. This changes the compilation output from: Directories for loaddefs: . ./calc ./calendar ./cedet ./cedet/ede ./cedet/semantic ./cedet/semantic/analyze ./cedet/semantic/bovine ./cedet/semantic/decorate ./cedet/semantic/symref ./cedet/semantic/wisent ./cedet/srecode ./emacs-lisp ./emulation ./erc ./eshell ./gnus ./image ./international ./language ./leim ./leim/ja-dic ./leim/quail ./mail ./mh-e ./net ./nxml ./org ./play ./progmodes ./textmodes ./url ./vc (but all on one long line) To: SCRAPE . ./calc ./calendar ./cedet ./cedet/ede ./cedet/semantic SCRAPE ./cedet/semantic/analyze ./cedet/semantic/bovine SCRAPE ./cedet/semantic/decorate ./cedet/semantic/symref SCRAPE ./cedet/semantic/wisent ./cedet/srecode ./emacs-lisp ./emulation SCRAPE ./erc ./eshell ./gnus ./image ./international ./language ./leim SCRAPE ./leim/ja-dic ./leim/quail ./mail ./mh-e ./net ./nxml ./org ./play SCRAPE ./progmodes ./textmodes ./url ./vc Compilation output with very long lines can be mistaken for errors when they scroll by fast in the compilation output. Making it look more like normal informational output avoids this confusion. diff --git a/lisp/Makefile.in b/lisp/Makefile.in index 57527bb5af..84c5733918 100644 --- a/lisp/Makefile.in +++ b/lisp/Makefile.in @@ -196,7 +196,6 @@ $(lisp)/finder-inf.el: autoloads .PHONY: $(lisp)/loaddefs.el $(lisp)/loaddefs.el: gen-lisp $(LOADDEFS) - @echo Directories for loaddefs: ${SUBDIRS_ALMOST} $(AM_V_GEN)$(emacs) -l autoload \ --eval '(setq autoload-ensure-writable t)' \ --eval '(setq autoload-builtin-package-versions t)' \ diff --git a/lisp/emacs-lisp/autoload.el b/lisp/emacs-lisp/autoload.el index ede4edcd57..222a378566 100644 --- a/lisp/emacs-lisp/autoload.el +++ b/lisp/emacs-lisp/autoload.el @@ -1124,7 +1124,7 @@ write its autoloads into the specified file instead." ;; Elements remaining in FILES have no existing autoload sections yet. (let ((no-autoloads-time (or last-time '(0 0 0 0))) (progress (make-progress-reporter - (byte-compile-info-string + (byte-compile-info (concat "Scraping files for " (file-relative-name generated-autoload-file))) @@ -1167,6 +1167,19 @@ write its autoloads into the specified file instead." ;; file-local autoload-generated-file settings. (autoload-save-buffers)))) +(defun batch-update-autoloads--summary (strings) + (let ((message "")) + (while strings + (when (> (length (concat message " " (car strings))) 68) + (byte-compile-info message t "SCRAPE") + (setq message "")) + (setq message (if (zerop (length message)) + (car strings) + (concat message " " (car strings)))) + (setq strings (cdr strings))) + (when (> (length message) 0) + (byte-compile-info message t "SCRAPE")))) + ;;;###autoload (defun batch-update-autoloads () "Update loaddefs.el autoloads in batch mode. @@ -1190,6 +1203,7 @@ should be non-nil)." (or (string-match "\\`site-" file) (push (expand-file-name file) autoload-excludes))))))) (let ((args command-line-args-left)) + (batch-update-autoloads--summary args) (setq command-line-args-left nil) (apply #'update-directory-autoloads args))) commit 7384f194bebb161b8f4ef7617f8c328721cd433f Author: Lars Ingebrigtsen Date: Thu Aug 6 08:12:31 2020 +0200 Make 'byte-compile-info*' functions more logical * lisp/emacs-lisp/byte-run.el (byte-compile-info): New function that's more flexible that replaces 'byte-compile-info-string' and 'byte-compile-info-message'. (byte-compile-info-string): Make obsolete. (byte-compile-info-message): Ditto. * lisp/international/ja-dic-cnv.el (skkdic-convert-okuri-ari) (skkdic-convert-postfix, skkdic-convert-prefix) (skkdic-collect-okuri-nasi, skkdic-set-okuri-nasi): * lisp/finder.el (finder-compile-keywords): * lisp/cus-dep.el (custom-make-dependencies): Adjust callers to use the new function. diff --git a/lisp/cus-dep.el b/lisp/cus-dep.el index fd307a5c04..f1061a8621 100644 --- a/lisp/cus-dep.el +++ b/lisp/cus-dep.el @@ -70,7 +70,7 @@ Usage: emacs -batch -l ./cus-dep.el -f custom-make-dependencies DIRS" (directory-files subdir nil "\\`[^=.].*\\.el\\'")))) (progress (make-progress-reporter - (byte-compile-info-string "Scanning files for custom") + (byte-compile-info "Scanning files for custom") 0 (length files) nil 10))) (with-temp-buffer (dolist (elem files) @@ -127,8 +127,8 @@ Usage: emacs -batch -l ./cus-dep.el -f custom-make-dependencies DIRS" type))))))))))) (error nil))))))) (progress-reporter-done progress)) - (byte-compile-info-message "Generating %s..." - generated-custom-dependencies-file) + (byte-compile-info + (format "Generating %s..." generated-custom-dependencies-file) t) (set-buffer (find-file-noselect generated-custom-dependencies-file)) (setq buffer-undo-list t) (erase-buffer) @@ -217,8 +217,8 @@ elements the files that have variables or faces that contain that version. These files should be loaded before showing the customization buffer that `customize-changed-options' generates.\")\n\n")) (save-buffer) - (byte-compile-info-message "Generating %s...done" - generated-custom-dependencies-file)) + (byte-compile-info + (format "Generating %s...done" generated-custom-dependencies-file) t)) (provide 'cus-dep) diff --git a/lisp/emacs-lisp/byte-run.el b/lisp/emacs-lisp/byte-run.el index 88e21b73fe..5279a57cd0 100644 --- a/lisp/emacs-lisp/byte-run.el +++ b/lisp/emacs-lisp/byte-run.el @@ -576,13 +576,26 @@ Otherwise, return nil. For internal use only." (mapconcat (lambda (char) (format "`?\\%c'" char)) sorted ", "))))) +(defun byte-compile-info (string &optional message type) + "Format STRING in a way that looks pleasing in the compilation output. +If MESSAGE, output the message, too. + +If TYPE, it should be a string that says what the information +type is. This defaults to \"INFO\"." + (let ((string (format " %-9s%s" (or type "INFO") string))) + (when message + (message "%s" string)) + string)) + (defun byte-compile-info-string (&rest args) "Format ARGS in a way that looks pleasing in the compilation output." - (format " %-9s%s" "INFO" (apply #'format args))) + (declare (obsolete byte-compile-info "28.1")) + (byte-compile-info (apply #'format args))) (defun byte-compile-info-message (&rest args) "Message format ARGS in a way that looks pleasing in the compilation output." - (message "%s" (apply #'byte-compile-info-string args))) + (declare (obsolete byte-compile-info "28.1")) + (byte-compile-info (apply #'format args) t)) ;; I nuked this because it's not a good idea for users to think of using it. diff --git a/lisp/finder.el b/lisp/finder.el index f04d73e098..820d6d0a3b 100644 --- a/lisp/finder.el +++ b/lisp/finder.el @@ -197,7 +197,7 @@ from; the default is `load-path'." (cons d f)) (directory-files d nil el-file-regexp)))) (progress (make-progress-reporter - (byte-compile-info-string "Scanning files for finder") + (byte-compile-info "Scanning files for finder") 0 (length files))) package-override base-name ; processed summary keywords package version entry desc) diff --git a/lisp/international/ja-dic-cnv.el b/lisp/international/ja-dic-cnv.el index 45e1346265..f5e70ce702 100644 --- a/lisp/international/ja-dic-cnv.el +++ b/lisp/international/ja-dic-cnv.el @@ -48,7 +48,7 @@ (defvar ja-dic-filename "ja-dic.el") (defun skkdic-convert-okuri-ari (skkbuf buf) - (byte-compile-info-message "Processing OKURI-ARI entries") + (byte-compile-info "Processing OKURI-ARI entries" t) (goto-char (point-min)) (with-current-buffer buf (insert ";; Setting okuri-ari entries.\n" @@ -97,7 +97,7 @@ ("ゆき" "行"))) (defun skkdic-convert-postfix (skkbuf buf) - (byte-compile-info-message "Processing POSTFIX entries") + (byte-compile-info "Processing POSTFIX entries" t) (goto-char (point-min)) (with-current-buffer buf (insert ";; Setting postfix entries.\n" @@ -151,7 +151,7 @@ (defconst skkdic-prefix-list '(skkdic-prefix-list)) (defun skkdic-convert-prefix (skkbuf buf) - (byte-compile-info-message "Processing PREFIX entries") + (byte-compile-info "Processing PREFIX entries" t) (goto-char (point-min)) (with-current-buffer buf (insert ";; Setting prefix entries.\n" @@ -273,7 +273,7 @@ (defun skkdic-collect-okuri-nasi () (save-excursion (let ((progress (make-progress-reporter - (byte-compile-info-message "Collecting OKURI-NASI entries") + (byte-compile-info "Collecting OKURI-NASI entries" t) (point) (point-max) nil 10))) (while (re-search-forward "^\\(\\cH+\\) \\(/\\cj.*\\)/$" @@ -301,7 +301,7 @@ "(skkdic-set-okuri-nasi\n") (let ((l (nreverse skkdic-okuri-nasi-entries)) (progress (make-progress-reporter - (byte-compile-info-message "Processing OKURI-NASI entries") + (byte-compile-info "Processing OKURI-NASI entries" t) 0 skkdic-okuri-nasi-entries-count nil 10)) (count 0)) @@ -531,8 +531,7 @@ To get complete usage, invoke: ',(let ((l entries) (map '(skdic-okuri-nasi)) (progress (make-progress-reporter - (byte-compile-info-message - "Extracting OKURI-NASI entries") + (byte-compile-info "Extracting OKURI-NASI entries") 0 (length entries))) (count 0) entry) commit 155b2c8a8d51a492a8c350b92bd3e83187d72b78 Author: Paul Eggert Date: Wed Aug 5 17:36:50 2020 -0700 Simplify Solaris port This should avoid some configuration confusion as exemplified by Jeffrey Walton’s recent bug report (Bug#42675). * configure.ac (opsys): Simplify Solaris configuration by not worrying about Solaris 9 and earlier, as they are no longer supported by the Solaris developers. This should support Walton’s ‘./configure --build=x86_64-sun-solaris’. Instead of bothering with ‘opsys=sol2-6’ and ‘opsys=sol2-10’, just use ‘opsys=solaris’. All uses changed. (emacs_check_sunpro_c): Remove unused var. * doc/misc/tramp.texi (Remote programs): * etc/MACHINES, etc/PROBLEMS: Modernize PATH for Oracle Developer Studio. * etc/PROBLEMS: Move Solaris-related problems to legacy area, except those that are still relevant. diff --git a/configure.ac b/configure.ac index 4ee4517e11..c9aa076eb3 100644 --- a/configure.ac +++ b/configure.ac @@ -748,44 +748,21 @@ case "${canonical}" in opsys=aix4-2 ;; - ## Suns - *-sun-solaris* \ - | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \ - | x86_64-*-solaris2* | x86_64-*-sunos5*) + ## Solaris + *-*-solaris* | *-*-sunos*) case "${canonical}" in i[3456]86-*-* ) ;; amd64-*-*|x86_64-*-*) ;; sparc* ) ;; * ) unported=yes ;; esac - case "${canonical}" in - *-sunos5.[1-9][0-9]* | *-solaris2.[1-9][0-9]* ) - opsys=sol2-10 - emacs_check_sunpro_c=yes - ;; - *-sunos5.[1-5]* | *-solaris2.[1-5]* ) unported=yes ;; - ## Note that Emacs 23.1's NEWS said the following would be dropped. - *-sunos5.6* | *-solaris2.6* ) - opsys=sol2-6 - RANLIB="ar -ts" - ;; - ## 5.7 EOL Aug 2008, 5.8 EOL Mar 2012. - *-sunos5.[7-9]* | *-solaris2.[7-9]* ) - opsys=sol2-6 - emacs_check_sunpro_c=yes - ;; - esac + opsys=solaris ## Watch out for a compiler that we know will not work. - case "${canonical}" in - *-solaris* | *-sunos5* ) - if [ "x$CC" = x/usr/ucb/cc ]; then - ## /usr/ucb/cc doesn't work; - ## we should find some other compiler that does work. - unset CC - fi - ;; - *) ;; - esac + if [ "$CC" = /usr/ucb/cc ]; then + ## /usr/ucb/cc doesn't work; + ## we should find some other compiler that does work. + unset CC + fi ;; ## QNX Neutrino @@ -1476,14 +1453,11 @@ case "$opsys" in mingw32) UNEXEC_OBJ=unexw32.o ;; - sol2-10) + solaris) # Use the Solaris dldump() function, called from unexsol.c, to dump # emacs, instead of the generic ELF dump code found in unexelf.c. # The resulting binary has a complete symbol table, and is better # for debugging and other observability tools (debuggers, pstack, etc). - # - # It is likely that dldump() works with older Solaris too, but this has - # not been tested, so for now this change is for Solaris 10 or newer. UNEXEC_OBJ=unexsol.o ;; *) @@ -1586,7 +1560,7 @@ case "$opsys" in qnxnto) LIBS_SYSTEM="-lsocket" ;; - sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;; + solaris) LIBS_SYSTEM="-lsocket -lnsl" ;; ## Motif needs -lgen. unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;; @@ -1647,7 +1621,7 @@ case $opsys in SYSTEM_TYPE=berkeley-unix ;; - sol2* | unixware ) + solaris | unixware ) SYSTEM_TYPE=usg-unix-v ;; @@ -2291,7 +2265,7 @@ system_malloc=yes test $with_unexec = yes && case "$opsys" in ## darwin ld insists on the use of malloc routines in the System framework. - darwin | mingw32 | nacl | sol2-10) ;; + darwin | mingw32 | nacl | solaris) ;; cygwin | qnxnto | freebsd) hybrid_malloc=yes system_malloc= ;; @@ -2427,7 +2401,7 @@ if test "$ac_cv_header_pthread_h" && test "$opsys" != "mingw32"; then # need special flags to disable these optimizations. For example, the # definition of 'errno' in . case $opsys in - hpux* | sol*) + hpux* | solaris) AC_DEFINE([_REENTRANT], 1, [Define to 1 if your system requires this in multithreaded code.]);; aix4-2) @@ -2557,7 +2531,7 @@ fail; ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style ## XIM support. case "$opsys" in - sol2-*) : ;; + solaris) : ;; *) AC_DEFINE(HAVE_X11R6_XIM, 1, [Define if you have usable X11R6-style XIM support.]) ;; @@ -4692,7 +4666,7 @@ if test "$USE_X_TOOLKIT" != "none"; then fi case $opsys in - sol2* | unixware ) + solaris | unixware ) dnl Some SVr4s don't define NSIG in sys/signal.h for ANSI environments; dnl instead, there's a system variable _sys_nsig. Unfortunately, we dnl need the constant to dimension an array. So wire in the appropriate @@ -4705,7 +4679,7 @@ emacs_broken_SIGIO=no case $opsys in dnl SIGIO exists, but the feature doesn't work in the way Emacs needs. - hpux* | nacl | openbsd | sol2* | unixware ) + hpux* | nacl | openbsd | solaris | unixware ) emacs_broken_SIGIO=yes ;; @@ -4754,7 +4728,7 @@ case $opsys in esac case $opsys in - gnu-* | sol2-10 ) + gnu-* | solaris ) dnl FIXME Can't we test if this exists (eg /proc/$$)? AC_DEFINE(HAVE_PROCFS, 1, [Define if you have the /proc filesystem.]) ;; @@ -4883,7 +4857,7 @@ case $opsys in AC_DEFINE(PTY_TTY_NAME_SPRINTF, [sprintf (pty_name, "/dev/pty/tty%c%x", c, i);]) ;; - sol2* ) + solaris ) dnl On SysVr4, grantpt(3) forks a subprocess, so do not use dnl O_CLOEXEC when opening the pty, and keep the SIGCHLD handler dnl from intercepting that death. If any child but grantpt's should die @@ -4893,7 +4867,7 @@ case $opsys in ;; unixware ) - dnl Comments are as per sol2*. + dnl Comments are as per solaris. AC_DEFINE(PTY_OPEN, [fd = open (pty_name, O_RDWR | O_NONBLOCK)]) AC_DEFINE(PTY_TTY_NAME_SPRINTF, [{ char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1) fatal("could not grant slave pty"); if (unlockpt(fd) == -1) fatal("could not unlock slave pty"); if (!(ptyname = ptsname(fd))) fatal ("could not enable slave pty"); snprintf (pty_name, PTY_NAME_SIZE, "%s", ptyname); }]) ;; @@ -4901,7 +4875,7 @@ esac case $opsys in - sol2* | unixware ) + solaris | unixware ) dnl This change means that we don't loop through allocate_pty too dnl many times in the (rare) event of a failure. AC_DEFINE(FIRST_PTY_LETTER, ['z']) @@ -4996,7 +4970,7 @@ if test x$GCC = xyes; then AC_DEFINE(GC_SETJMP_WORKS, 1) else case $opsys in - aix* | dragonfly | freebsd | netbsd | openbsd | sol2* ) + aix* | dragonfly | freebsd | netbsd | openbsd | solaris ) AC_DEFINE(GC_SETJMP_WORKS, 1) ;; esac @@ -5043,7 +5017,7 @@ case $emacs_cv_func_sigsetjmp,$emacs_cv_alternate_stack,$opsys in esac case $opsys in - sol2* | unixware ) + solaris | unixware ) dnl TIOCGPGRP is broken in SysVr4, so we can't send signals to PTY dnl subprocesses the usual way. But TIOCSIGNAL does work for PTYs, dnl and this is all we need. @@ -5053,7 +5027,7 @@ esac case $opsys in - hpux* | sol2* ) + hpux* | solaris ) dnl Used in xfaces.c. AC_DEFINE(XOS_NEEDS_TIME_H, 1, [Compensate for a bug in Xos.h on some systems, where it requires time.h.]) @@ -5108,7 +5082,7 @@ case $opsys in fi ;; - sol2*) + solaris) AC_DEFINE(USG, []) AC_DEFINE(USG5_4, []) AC_DEFINE(SOLARIS2, [], [Define if the system is Solaris.]) @@ -5173,7 +5147,7 @@ case $opsys in reopen it in the child.]) ;; - sol2-10) + solaris) AC_DEFINE(_STRUCTURED_PROC, 1, [Needed for system_process_attributes on Solaris.]) ;; diff --git a/doc/misc/tramp.texi b/doc/misc/tramp.texi index 91b1e996f4..56cd220e20 100644 --- a/doc/misc/tramp.texi +++ b/doc/misc/tramp.texi @@ -2105,7 +2105,7 @@ To improve performance and accuracy of remote file access, @file{/usr/bin}, which are reasonable for most hosts. To accommodate differences in hosts and paths, for example, @file{/bin:/usr/bin} on Debian GNU/Linux or -@file{/usr/xpg4/bin:/usr/ccs/bin:/usr/bin:/opt/SUNWspro/bin} on +@file{/usr/xpg4/bin:/usr/ccs/bin:/usr/bin:/opt/developerstudio12.6/bin} on Solaris, @value{tramp} queries the remote host with @command{getconf PATH} and updates the symbol @code{tramp-default-remote-path}. diff --git a/etc/MACHINES b/etc/MACHINES index 1bb244b49b..78e9cef0fd 100644 --- a/etc/MACHINES +++ b/etc/MACHINES @@ -81,25 +81,26 @@ the list at the end of this file. ** Solaris - On Solaris it is also possible to use either GCC or Solaris Studio - to build Emacs, by pointing ./configure to the right compiler: + On Solaris it is also possible to use either GCC or Oracle Developer + Studio to build Emacs, by pointing ./configure to the right compiler: - ./configure CC='/usr/sfw/bin/gcc' # GCC - ./configure CC='cc' # Solaris Studio + ./configure # Defaults to 'gcc' if available. + ./configure CC='cc' # Oracle Developer Studio - On Solaris, do not use /usr/ucb/cc. Use /opt/SUNWspro/bin/cc. Make - sure that /usr/ccs/bin and /opt/SUNWspro/bin are in your PATH before - /usr/ucb. (Most free software packages have the same requirement on - Solaris.) With this compiler, use '/opt/SUNWspro/bin/cc -E' as the + On Solaris, do not use /usr/ucb/cc. Use Oracle Developer Studio. + Make sure that /usr/ccs/bin and the Oracle Developer Studio bin + directory (e.g., /opt/developerstudio12.6/bin) are in your PATH + before /usr/ucb. (Most free software packages have the same + requirement on Solaris.) With this compiler, use 'cc -E' as the preprocessor. If this inserts extra whitespace into its output (see - the PROBLEMS file) then add the option '-Xs'. + the PROBLEMS file), add the option '-Xs'. To build a 64-bit Emacs (with larger maximum buffer size) on a - Solaris system which supports 64-bit executables, specify the -m64 + Solaris system that defaults to 32-bit executables, specify the -m64 compiler option. For example: - ./configure CC='/usr/sfw/bin/gcc -m64' # GCC - ./configure CC='cc -m64' # Solaris Studio + ./configure CC='gcc -m64' # GCC + ./configure CC='cc -m64' # Oracle Developer Studio * Obsolete platforms diff --git a/etc/PROBLEMS b/etc/PROBLEMS index 4ce738d9a5..598a79f978 100644 --- a/etc/PROBLEMS +++ b/etc/PROBLEMS @@ -2222,6 +2222,7 @@ We list bugs in current versions here. See also the section on legacy systems. *** On Solaris 10, Emacs crashes during the build process. +(This applies only with './configure --with-unexec=yes', which is rare.) This was reported for Emacs 25.2 on i386-pc-solaris2.10 with Sun Studio 12 (Sun C 5.9) and with Oracle Developer Studio 12.6 (Sun C 5.15), and intermittently for sparc-sun-solaris2.10 with Oracle @@ -2239,66 +2240,6 @@ Solaris. See Bug#26638. This is a Solaris feature (at least on Intel x86 cpus). Type C-r C-r C-t, to toggle whether C-x gets through to Emacs. -*** Problem with remote X server on Suns. - -On a Sun, running Emacs on one machine with the X server on another -may not work if you have used the unshared system libraries. This -is because the unshared libraries fail to use YP for host name lookup. -As a result, the host name you specify may not be recognized. - -*** Solaris 2.6: Emacs crashes with SIGBUS or SIGSEGV on Solaris after you delete a frame. - -We suspect that this is a bug in the X libraries provided by -Sun. There is a report that one of these patches fixes the bug and -makes the problem stop: - -105216-01 105393-01 105518-01 105621-01 105665-01 105615-02 105216-02 -105667-01 105401-08 105615-03 105621-02 105686-02 105736-01 105755-03 -106033-01 105379-01 105786-01 105181-04 105379-03 105786-04 105845-01 -105284-05 105669-02 105837-01 105837-02 105558-01 106125-02 105407-01 - -Another person using a newer system (kernel patch level Generic_105181-06) -suspects that the bug was fixed by one of these more recent patches: - -106040-07 SunOS 5.6: X Input & Output Method patch -106222-01 OpenWindows 3.6: filemgr (ff.core) fixes -105284-12 Motif 1.2.7: sparc Runtime library patch - -*** Solaris 7 or 8: Emacs reports a BadAtom error (from X) - -This happens when Emacs was built on some other version of Solaris. -Rebuild it on Solaris 8. - -*** When using M-x dbx with the SparcWorks debugger, the 'up' and 'down' -commands do not move the arrow in Emacs. - -You can fix this by adding the following line to '~/.dbxinit': - - dbxenv output_short_file_name off - -*** On Solaris, CTRL-t is ignored by Emacs when you use -the fr.ISO-8859-15 locale (and maybe other related locales). - -You can fix this by editing the file: - - /usr/openwin/lib/locale/iso8859-15/Compose - -Near the bottom there is a line that reads: - - Ctrl : "\276" threequarters - -while it should read: - - Ctrl : "\276" threequarters - -Note the lower case . Changing this line should make C-t work. - -*** On Solaris, Emacs fails to set menu-bar-update-hook on startup, with error -"Error in menu-bar-update-hook: (error Point before start of properties)". -This seems to be a GCC optimization bug that occurs for GCC 4.1.2 (-g -and -g -O2) and GCC 4.2.3 (-g -O and -g -O2). You can fix this by -compiling with GCC 4.2.3 or CC 5.7, with no optimizations. - * Runtime problems specific to MS-Windows ** Emacs on Windows 9X requires UNICOWS.DLL @@ -2733,13 +2674,13 @@ Libxpm is available for macOS as part of the XQuartz project. This indicates a mismatch between the C compiler and preprocessor that configure is using. For example, on Solaris 10 trying to use -CC=/opt/SUNWspro/bin/cc (the Sun Studio compiler) together with -CPP=/usr/ccs/lib/cpp can result in errors of this form (you may also -see the error '"/usr/include/sys/isa_defs.h", line 500: undefined control'). +CC=/opt/developerstudio12.6/bin/cc (the Oracle Developer Studio +compiler) together with CPP=/usr/lib/cpp can result in errors of +this form. The solution is to tell configure to use the correct C preprocessor -for your C compiler (CPP="/opt/SUNWspro/bin/cc -E" in the above -example). +for your C compiler (CPP="/opt/developerstudio12.6/bin/cc -E" in the +above example). ** Compilation @@ -3110,7 +3051,69 @@ This section covers bugs reported on very old hardware or software. If you are using hardware and an operating system shipped after 2000, it is unlikely you will see any of these. -*** Solaris 2.x +** Solaris + +*** Problem with remote X server on Suns. + +On a Sun, running Emacs on one machine with the X server on another +may not work if you have used the unshared system libraries. This +is because the unshared libraries fail to use YP for host name lookup. +As a result, the host name you specify may not be recognized. + +*** Solaris 2.6: Emacs crashes with SIGBUS or SIGSEGV on Solaris after you delete a frame. + +We suspect that this is a bug in the X libraries provided by +Sun. There is a report that one of these patches fixes the bug and +makes the problem stop: + +105216-01 105393-01 105518-01 105621-01 105665-01 105615-02 105216-02 +105667-01 105401-08 105615-03 105621-02 105686-02 105736-01 105755-03 +106033-01 105379-01 105786-01 105181-04 105379-03 105786-04 105845-01 +105284-05 105669-02 105837-01 105837-02 105558-01 106125-02 105407-01 + +Another person using a newer system (kernel patch level Generic_105181-06) +suspects that the bug was fixed by one of these more recent patches: + +106040-07 SunOS 5.6: X Input & Output Method patch +106222-01 OpenWindows 3.6: filemgr (ff.core) fixes +105284-12 Motif 1.2.7: sparc Runtime library patch + +*** Solaris 7 or 8: Emacs reports a BadAtom error (from X) + +This happens when Emacs was built on some other version of Solaris. +Rebuild it on Solaris 8. + +*** When using M-x dbx with the SparcWorks debugger, the 'up' and 'down' +commands do not move the arrow in Emacs. + +You can fix this by adding the following line to '~/.dbxinit': + + dbxenv output_short_file_name off + +*** On Solaris, CTRL-t is ignored by Emacs when you use +the fr.ISO-8859-15 locale (and maybe other related locales). + +You can fix this by editing the file: + + /usr/openwin/lib/locale/iso8859-15/Compose + +Near the bottom there is a line that reads: + + Ctrl : "\276" threequarters + +while it should read: + + Ctrl : "\276" threequarters + +Note the lower case . Changing this line should make C-t work. + +*** On Solaris, Emacs fails to set menu-bar-update-hook on startup, with error +"Error in menu-bar-update-hook: (error Point before start of properties)". +This seems to be a GCC optimization bug that occurs for GCC 4.1.2 (-g +and -g -O2) and GCC 4.2.3 (-g -O and -g -O2). You can fix this by +compiling with GCC 4.2.3 or CC 5.7, with no optimizations. + +*** Other legacy Solaris problems **** Strange results from format %d in a few cases, on a Sun. diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index 806a3955e4..777df79a6e 100644 --- a/lisp/dired-aux.el +++ b/lisp/dired-aux.el @@ -1014,8 +1014,8 @@ To undo the killing, the undo command can be used as normally." (defvar dired-compress-file-suffixes '( ;; "tar -zxf" isn't used because it's not available on the - ;; Solaris10 version of tar. Solaris10 becomes obsolete in 2021. - ;; Same thing on AIX 7.1. + ;; Solaris 10 version of tar (obsolete in 2024?). + ;; Same thing on AIX 7.1 (obsolete 2023?) and 7.2 (obsolete 2022?). ("\\.tar\\.gz\\'" "" "gzip -dc %i | tar -xf -") ("\\.tgz\\'" "" "gzip -dc %i | tar -xf -") ("\\.gz\\'" "" "gunzip") commit 1a99697b4d8c11a10d5e6a306103740d92cc08a1 Author: Lars Ingebrigtsen Date: Wed Aug 5 21:30:12 2020 +0200 Skip epg tests if gpg isn't installed diff --git a/test/lisp/gnus/mml-sec-tests.el b/test/lisp/gnus/mml-sec-tests.el index d9ed96ff1d..917e627c7e 100644 --- a/test/lisp/gnus/mml-sec-tests.el +++ b/test/lisp/gnus/mml-sec-tests.el @@ -36,6 +36,9 @@ Mostly, the empty passphrase is used. However, the keys for \"No Expiry two UIDs\" have the passphrase \"Passphrase\" (for OpenPGP as well as S/MIME).") +(defun test-conf () + (ignore-errors (epg-configuration))) + (defun enc-standards () (if with-smime '(enc-pgp enc-pgp-mime enc-smime) '(enc-pgp enc-pgp-mime))) @@ -200,6 +203,7 @@ In both cases, the first key is customized for signing and encryption." (ert-deftest mml-secure-key-checks () "Test mml-secure-check-user-id and mml-secure-check-sub-key on sample keys." + (skip-unless (test-conf)) (mml-secure-test-fixture (lambda () (let* ((context (epg-make-context 'OpenPGP)) @@ -267,6 +271,7 @@ In both cases, the first key is customized for signing and encryption." (ert-deftest mml-secure-find-usable-keys-1 () "Make sure that expired and disabled keys and revoked UIDs are not used." + (skip-unless (test-conf)) (mml-secure-test-fixture (lambda () (let ((context (epg-make-context 'OpenPGP))) @@ -305,6 +310,7 @@ In both cases, the first key is customized for signing and encryption." (ert-deftest mml-secure-find-usable-keys-2 () "Test different ways to search for keys." + (skip-unless (test-conf)) (mml-secure-test-fixture (lambda () (let ((context (epg-make-context 'OpenPGP))) @@ -356,6 +362,7 @@ In both cases, the first key is customized for signing and encryption." (ert-deftest mml-secure-select-preferred-keys-1 () "If only one key exists for an e-mail address, it is the preferred one." + (skip-unless (test-conf)) (mml-secure-test-fixture (lambda () (let ((context (epg-make-context 'OpenPGP))) @@ -366,6 +373,7 @@ In both cases, the first key is customized for signing and encryption." (ert-deftest mml-secure-select-preferred-keys-2 () "If multiple keys exists for an e-mail address, customization is necessary." + (skip-unless (test-conf)) (mml-secure-test-fixture (lambda () (let* ((context (epg-make-context 'OpenPGP)) @@ -392,6 +400,7 @@ In both cases, the first key is customized for signing and encryption." (ert-deftest mml-secure-select-preferred-keys-3 () "Expired customized keys are removed if multiple keys are available." + (skip-unless (test-conf)) (mml-secure-test-fixture (lambda () (let ((context (epg-make-context 'OpenPGP)) @@ -416,6 +425,7 @@ In both cases, the first key is customized for signing and encryption." (ert-deftest mml-secure-select-preferred-keys-4 () "Multiple keys can be recorded per recipient or signature." + (skip-unless (test-conf)) (mml-secure-test-fixture (lambda () (let ((pcontext (epg-make-context 'OpenPGP)) @@ -559,6 +569,7 @@ If optional EXPECTFAIL is non-nil, a decryption failure is expected." (ert-deftest mml-secure-en-decrypt-1 () "Encrypt message; then decrypt and test for expected result. In this test, the single matching key is chosen automatically." + (skip-unless (test-conf)) (dolist (method (enc-standards) nil) ;; no-exp@example.org with single encryption key (mml-secure-test-en-decrypt @@ -568,6 +579,7 @@ In this test, the single matching key is chosen automatically." (ert-deftest mml-secure-en-decrypt-2 () "Encrypt message; then decrypt and test for expected result. In this test, the encryption key needs to fixed among multiple ones." + (skip-unless (test-conf)) ;; sub@example.org with multiple candidate keys, ;; fixture customizes preferred ones. (mml-secure-test-key-fixture @@ -580,6 +592,7 @@ In this test, the encryption key needs to fixed among multiple ones." (ert-deftest mml-secure-en-decrypt-3 () "Encrypt message; then decrypt and test for expected result. In this test, encrypt-to-self variables are set to t." + (skip-unless (test-conf)) ;; sub@example.org with multiple candidate keys, ;; fixture customizes preferred ones. (mml-secure-test-key-fixture @@ -595,6 +608,7 @@ In this test, encrypt-to-self variables are set to t." (ert-deftest mml-secure-en-decrypt-4 () "Encrypt message; then decrypt and test for expected result. In this test, encrypt-to-self variables are set to lists." + (skip-unless (test-conf)) ;; Send from sub@example.org, which has two keys; encrypt to both. (let ((mml-secure-openpgp-encrypt-to-self '("C3999CF1268DBEA2" "F7E79AB7AE31D471")) @@ -609,6 +623,7 @@ In this test, encrypt-to-self variables are set to lists." (ert-deftest mml-secure-en-decrypt-sign-1-1-single () "Sign and encrypt message; then decrypt and test for expected result. In this test, just multiple encryption and signing keys may be available." + (skip-unless (test-conf)) (mml-secure-test-key-fixture (lambda () (let ((mml-secure-openpgp-sign-with-sender t) @@ -631,6 +646,7 @@ In this test, just multiple encryption and signing keys may be available." (ert-deftest mml-secure-en-decrypt-sign-1-2-double () "Sign and encrypt message; then decrypt and test for expected result. In this test, just multiple encryption and signing keys may be available." + (skip-unless (test-conf)) (mml-secure-test-key-fixture (lambda () (let ((mml-secure-openpgp-sign-with-sender t) @@ -646,6 +662,7 @@ In this test, just multiple encryption and signing keys may be available." (ert-deftest mml-secure-en-decrypt-sign-1-3-double () "Sign and encrypt message; then decrypt and test for expected result. In this test, just multiple encryption and signing keys may be available." + (skip-unless (test-conf)) (mml-secure-test-key-fixture (lambda () ;; Now use both keys for sub@example.org to sign an e-mail from @@ -662,6 +679,7 @@ In this test, just multiple encryption and signing keys may be available." (ert-deftest mml-secure-en-decrypt-sign-2 () "Sign and encrypt message; then decrypt and test for expected result. In this test, lists of encryption and signing keys are customized." + (skip-unless (test-conf)) (mml-secure-test-key-fixture (lambda () (let ((mml-secure-key-preferences @@ -695,6 +713,7 @@ In this test, lists of encryption and signing keys are customized." (ert-deftest mml-secure-en-decrypt-sign-3 () "Sign and encrypt message; then decrypt and test for expected result. Use sign-with-sender and encrypt-to-self." + (skip-unless (test-conf)) (mml-secure-test-key-fixture (lambda () (let ((mml-secure-openpgp-sign-with-sender t) @@ -710,6 +729,7 @@ Use sign-with-sender and encrypt-to-self." (ert-deftest mml-secure-sign-verify-1 () "Sign message with sender; then verify and test for expected result." + (skip-unless (test-conf)) (mml-secure-test-key-fixture (lambda () (dolist (method (sign-standards) nil) @@ -731,6 +751,7 @@ Use sign-with-sender and encrypt-to-self." (ert-deftest mml-secure-sign-verify-2 () "Sign message without sender; then verify and test for expected result." + (skip-unless (test-conf)) (mml-secure-test-key-fixture (lambda () (dolist (method (sign-standards) nil) @@ -762,6 +783,7 @@ Use sign-with-sender and encrypt-to-self." (ert-deftest mml-secure-sign-verify-3 () "Try to sign message with expired OpenPGP subkey, which raises an error. With Ma Gnus v0.14 and earlier a signature would be created with a wrong key." + (skip-unless (test-conf)) (should-error (mml-secure-test-key-fixture (lambda () @@ -784,6 +806,7 @@ With Ma Gnus v0.14 and earlier a signature would be created with a wrong key." In this test, a key is used that requires the passphrase \"Passphrase\". In the first decryption this passphrase is hardcoded, in the second one it is taken from a cache." + (skip-unless (test-conf)) (ert-skip "Requires passphrase") (mml-secure-test-key-fixture (lambda () @@ -814,6 +837,7 @@ So the second decryption fails." (ert-deftest mml-secure-en-decrypt-passphrase-no-cache-openpgp-todo () "Passphrase caching with OpenPGP only for GnuPG 1.x." + (skip-unless (test-conf)) (skip-unless (string< (cdr (assq 'version (epg-configuration))) "2")) (mml-secure-en-decrypt-passphrase-no-cache 'enc-pgp) (mml-secure-en-decrypt-passphrase-no-cache 'enc-pgp-mime)) @@ -821,6 +845,7 @@ So the second decryption fails." (ert-deftest mml-secure-en-decrypt-passphrase-no-cache-smime-todo () "Passphrase caching does not work with S/MIME (and gpgsm)." :expected-result :failed + (skip-unless (test-conf)) (if with-smime (mml-secure-en-decrypt-passphrase-no-cache 'enc-smime) (should nil))) commit 1669cf2f286649ea62991371fd19bbc592ca21bb Author: Lars Ingebrigtsen Date: Wed Aug 5 21:17:55 2020 +0200 Split sometimes-failing test into three tests to ease debugging diff --git a/test/lisp/gnus/mml-sec-tests.el b/test/lisp/gnus/mml-sec-tests.el index 50bb6e6b27..d9ed96ff1d 100644 --- a/test/lisp/gnus/mml-sec-tests.el +++ b/test/lisp/gnus/mml-sec-tests.el @@ -606,7 +606,7 @@ In this test, encrypt-to-self variables are set to lists." (list (cons "C3999CF1268DBEA2" "EF25402B479DC6E2") (cons "F7E79AB7AE31D471" "4035D59B5F88E9FC")))))) -(ert-deftest mml-first-secure-en-decrypt-sign-1 () +(ert-deftest mml-secure-en-decrypt-sign-1-1-single () "Sign and encrypt message; then decrypt and test for expected result. In this test, just multiple encryption and signing keys may be available." (mml-secure-test-key-fixture @@ -626,17 +626,28 @@ In this test, just multiple encryption and signing keys may be available." ;; customized choice for both keys (mml-secure-test-en-decrypt method "sub@example.org" "sub@example.org" 1 t) - ) + ))))) +(ert-deftest mml-secure-en-decrypt-sign-1-2-double () + "Sign and encrypt message; then decrypt and test for expected result. +In this test, just multiple encryption and signing keys may be available." + (mml-secure-test-key-fixture + (lambda () + (let ((mml-secure-openpgp-sign-with-sender t) + (mml-secure-smime-sign-with-sender t)) ;; Now use both keys to sign. The customized one via sign-with-sender, ;; the other one via the following setting. (let ((mml-secure-openpgp-signers '("F7E79AB7AE31D471")) (mml-secure-smime-signers '("0x5F88E9FC"))) (dolist (method (enc-sign-standards) nil) (mml-secure-test-en-decrypt - method "no-exp@example.org" "sub@example.org" 2 t) - ))) + method "no-exp@example.org" "sub@example.org" 2 t))))))) +(ert-deftest mml-secure-en-decrypt-sign-1-3-double () + "Sign and encrypt message; then decrypt and test for expected result. +In this test, just multiple encryption and signing keys may be available." + (mml-secure-test-key-fixture + (lambda () ;; Now use both keys for sub@example.org to sign an e-mail from ;; a different address (without associated keys). (let ((mml-secure-openpgp-sign-with-sender nil) @@ -646,8 +657,7 @@ In this test, just multiple encryption and signing keys may be available." (mml-secure-smime-signers '("0x5F88E9FC" "0x479DC6E2"))) (dolist (method (enc-sign-standards) nil) (mml-secure-test-en-decrypt - method "no-exp@example.org" "no-keys@example.org" 2 t) - ))))) + method "no-exp@example.org" "no-keys@example.org" 2 t)))))) (ert-deftest mml-secure-en-decrypt-sign-2 () "Sign and encrypt message; then decrypt and test for expected result. commit 2194284c55ba3f4f9859d2b65d21314446fc6a09 Author: Christophe Troestler Date: Wed Aug 5 18:01:27 2020 +0200 Enable replying to an ical event even when not an attendee * lisp/gnus/gnus-icalendar.el (gnus-icalendar-event--build-reply-event-body): Display a warning instead of barfing when user is missing from attendee list. When the user identity is not present in the attendee list, an error is triggered making replying to such an event impossible (the reply message not being even composed). This replaces it with a warning. This is necessary because one may receive events that the organizer did not set up well and it is up to the user to decide whether or not to reply to them (bug#41723). Copyright-paperwork-exempt: yes diff --git a/lisp/gnus/gnus-icalendar.el b/lisp/gnus/gnus-icalendar.el index 305e17fd8f..29d3e30780 100644 --- a/lisp/gnus/gnus-icalendar.el +++ b/lisp/gnus/gnus-icalendar.el @@ -312,7 +312,8 @@ status will be retrieved from the first matching attendee record." (unless (gnus-icalendar-find-if (lambda (x) (string-match "^ATTENDEE" x)) reply-event-lines) - (error "Could not find an event attendee matching given identity")) + (lwarn 'gnus-icalendar :warning + "Could not find an event attendee matching given identity")) (mapconcat #'identity `("BEGIN:VEVENT" ,@(nreverse reply-event-lines) commit 283fce4c3cdb89745a62fdeee83dcd7c2189fba3 Author: Harald Jörg Date: Wed Aug 5 17:19:06 2020 +0200 cperl-mode.el: Correctly terminate HERE-docs * lisp/progmodes/cperl-mode.el (cperl-find-pods-heres): cperl-mode in the master branch wrongly uses the first occurrence of "HERE" to terminate the string, resulting in badly fontified / indented code which follows (bug#42251). diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el index 6fe0c018b1..5ecd5668b3 100644 --- a/lisp/progmodes/cperl-mode.el +++ b/lisp/progmodes/cperl-mode.el @@ -3560,19 +3560,18 @@ the sections using `cperl-pod-head-face', `cperl-pod-face', "\\(\\`\n?\\|^\n\\)=" ; POD "\\|" ;; One extra () before this: - "<<~?" ; HERE-DOC - "\\(" ; 1 + 1 + "<<\\(~?\\)" ; HERE-DOC, indented-p = capture 2 + "\\(" ; 2 + 1 ;; First variant "BLAH" or just ``. "[ \t]*" ; Yes, whitespace is allowed! - "\\([\"'`]\\)" ; 2 + 1 = 3 - "\\([^\"'`\n]*\\)" ; 3 + 1 - "\\3" + "\\([\"'`]\\)" ; 3 + 1 = 4 + "\\([^\"'`\n]*\\)" ; 4 + 1 + "\\4" "\\|" ;; Second variant: Identifier or \ID (same as 'ID') or empty - "\\\\?\\(\\([a-zA-Z_][a-zA-Z_0-9]*\\)?\\)" ; 4 + 1, 5 + 1 + "\\\\?\\(\\([a-zA-Z_][a-zA-Z_0-9]*\\)?\\)" ; 5 + 1, 6 + 1 ;; Do not have <<= or << 30 or <<30 or << $blah. ;; "\\([^= \t0-9$@%&]\\|[ \t]+[^ \t\n0-9$@%&]\\)" ; 6 + 1 - "\\(\\)" ; To preserve count of pars :-( 6 + 1 "\\)" "\\|" ;; 1+6 extra () before this: @@ -3762,11 +3761,11 @@ the sections using `cperl-pod-head-face', `cperl-pod-face', ;; ;; "\\([^= \t0-9$@%&]\\|[ \t]+[^ \t\n0-9$@%&]\\)" ; 6 + 1 ;; "\\(\\)" ; To preserve count of pars :-( 6 + 1 ;; "\\)" - ((match-beginning 2) ; 1 + 1 + ((match-beginning 3) ; 2 + 1 (setq b (point) tb (match-beginning 0) c (and ; not HERE-DOC - (match-beginning 5) + (match-beginning 6) (save-match-data (or (looking-at "[ \t]*(") ; << function_call() (save-excursion ; 1 << func_name, or $foo << 10 @@ -3793,17 +3792,17 @@ the sections using `cperl-pod-head-face', `cperl-pod-face', (looking-at "\\(printf?\\|say\\|system\\|exec\\|sort\\)\\>"))) (error t))))))) (error nil))) ; func(< Date: Wed Aug 5 16:07:41 2020 +0200 Wrap skeleton logic in atomic-change-group * lisp/skeleton.el (define-skeleton): Use an atomic change group so that if the user `C-g's in the middle of it, we're not left with half a skeleton in the buffer (bug#42311). diff --git a/lisp/skeleton.el b/lisp/skeleton.el index 8c694c128b..3609d6ba6a 100644 --- a/lisp/skeleton.el +++ b/lisp/skeleton.el @@ -135,7 +135,8 @@ A prefix argument of -1 says to wrap around region, even if not highlighted. A prefix argument of zero says to wrap around zero words---that is, nothing. This is a way of overriding the use of a highlighted region.") (interactive "*P\nP") - (skeleton-proxy-new ',skeleton str arg)))) + (atomic-change-group + (skeleton-proxy-new ',skeleton str arg))))) ;;;###autoload (defun skeleton-proxy-new (skeleton &optional str arg) commit 7389a9ef0954d61bf5a85221da7c919aee3451a0 Author: Harald Jörg Date: Wed Aug 5 15:55:00 2020 +0200 cperl-mode: Fix bad parameter construction in cperl-etags * lisp/progmodes/cperl-mode.el (cperl-etags): This fails with (wrong-type-argument stringp cperl-sub-regexp). The error came with incorporating Jonathan Rockway's work (bug#42355). Copyright-paperwork-exempt: yes diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el index 6755d10f1a..6fe0c018b1 100644 --- a/lisp/progmodes/cperl-mode.el +++ b/lisp/progmodes/cperl-mode.el @@ -6499,9 +6499,10 @@ If optional argument ALL is `recursive', will process Perl files in subdirectories too." (interactive) (let ((cmd "etags") - (args '("-l" "none" "-r" + (args `("-l" "none" "-r" ;; 1=fullname 2=package? 3=name 4=proto? 5=attrs? (VERY APPROX!) - "/\\<" cperl-sub-regexp "[ \\t]+\\(\\([a-zA-Z0-9:_]*::\\)?\\([a-zA-Z0-9_]+\\)\\)[ \\t]*\\(([^()]*)[ \t]*\\)?\\([ \t]*:[^#{;]*\\)?\\([{#]\\|$\\)/\\3/" + ,(concat + "/\\<" cperl-sub-regexp "[ \\t]+\\(\\([a-zA-Z0-9:_]*::\\)?\\([a-zA-Z0-9_]+\\)\\)[ \\t]*\\(([^()]*)[ \t]*\\)?\\([ \t]*:[^#{;]*\\)?\\([{#]\\|$\\)/\\3/") "-r" "/\\ Date: Wed Aug 5 15:37:13 2020 +0200 cperl-mode: Workaround for failure of cperl-write-tags * lisp/progmodes/cperl-mode.el (cperl-mode): Accomodate recent changes in etags (bug#42356). diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el index cdbb59a5ad..6755d10f1a 100644 --- a/lisp/progmodes/cperl-mode.el +++ b/lisp/progmodes/cperl-mode.el @@ -6786,6 +6786,7 @@ Use as (or topdir (setq topdir default-directory)) (let ((tags-file-name "TAGS") + (inhibit-read-only t) (case-fold-search nil) xs rel) (save-excursion commit 4b3f44fc97d3cb29fceb47ec5ba16009b6de7152 Author: Lars Ingebrigtsen Date: Wed Aug 5 15:02:28 2020 +0200 Fix max-width/height for Message screenshots * lisp/gnus/message.el (message-insert-screenshot): :max-width/height apparently has to be integers. diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index 378c3b0467..cf2b8eebc3 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el @@ -8693,8 +8693,8 @@ used to take the screenshot." (set-mark (point)) (insert-image (create-image image 'png t - :max-width (* (frame-pixel-width) 0.8) - :max-height (* (frame-pixel-height) 0.8) + :max-width (truncate (* (frame-pixel-width) 0.8)) + :max-height (truncate (* (frame-pixel-height) 0.8)) :scale 1) (format "<#part type=\"image/png\" disposition=inline content-transfer-encoding=base64 raw=t>\n%s\n<#/part>" ;; Get a base64 version of the image -- this avoids later commit dc47bc77dc1c9d34c4c1e2830fe2bfd6be6e241a Author: Lars Ingebrigtsen Date: Wed Aug 5 12:49:14 2020 +0200 mouse-drag-copy-region doc string clarification * lisp/mouse.el (mouse-drag-copy-region): Clarify that the variable only applies to selections in Emacs (bug#41856). diff --git a/lisp/mouse.el b/lisp/mouse.el index 640f10af4e..d369545f18 100644 --- a/lisp/mouse.el +++ b/lisp/mouse.el @@ -49,7 +49,10 @@ "If non-nil, copy to kill-ring upon mouse adjustments of the region. This affects `mouse-save-then-kill' (\\[mouse-save-then-kill]) in -addition to mouse drags." +addition to mouse drags. + +This variable applies only to mouse adjustments in Emacs, not +selecting and adjusting regions in other windows." :type 'boolean :version "24.1") commit a937d50a7e039088d493d8f6b8b5be9799b7d7ad Author: Lars Ingebrigtsen Date: Wed Aug 5 12:43:18 2020 +0200 Mention C-y in the manual for yanking the primary selection * doc/emacs/killing.texi (Primary Selection): Mention C-y here for yanking the primary selection (bug#41857). diff --git a/doc/emacs/killing.texi b/doc/emacs/killing.texi index 6b1f35e615..bd7dbb6f51 100644 --- a/doc/emacs/killing.texi +++ b/doc/emacs/killing.texi @@ -577,7 +577,9 @@ regions to the primary selection entirely. To insert the primary selection into an Emacs buffer, click @kbd{mouse-2} (@code{mouse-yank-primary}) where you want to insert it. -@xref{Mouse Commands}. +@xref{Mouse Commands}. You can also use the normal Emacs yank command +(@kbd{C-y}) to insert this text if @code{select-enable-primary} is set +(@pxref{Clipboard}). @cindex MS-Windows, and primary selection MS-Windows provides no primary selection, but Emacs emulates it commit 38ad404ba58e83292b3b566a64d8c655aa126cf7 Author: Basil L. Contovounesios Date: Wed Aug 5 11:40:27 2020 +0100 ; Silence recent byte-compiler warning in subr.el * lisp/subr.el (save-match-data-internal): Declare before first use. diff --git a/lisp/subr.el b/lisp/subr.el index 3c8dbd1614..6bd06a0b82 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -883,6 +883,10 @@ side-effects, and the argument LIST is not modified." ;;;; Keymap support. +;; Declare before first use of `save-match-data', +;; where it is used internally. +(defvar save-match-data-internal) + (defun kbd (keys) "Convert KEYS to the internal Emacs key representation. KEYS should be a string in the format returned by commands such @@ -4105,8 +4109,6 @@ MODES is as for `set-default-file-modes'." ;;; Matching and match data. -(defvar save-match-data-internal) - ;; We use save-match-data-internal as the local variable because ;; that works ok in practice (people should not use that variable elsewhere). ;; We used to use an uninterned symbol; the compiler handles that properly commit 1b7eb828644a13259ff072e3464c6e8493571e6e Author: Lars Ingebrigtsen Date: Wed Aug 5 12:31:44 2020 +0200 Tweak the Message screenshot insertion * lisp/gnus/message.el (message-insert-screenshot): Force scaling to 1, since the screenshot image will already be suitable for displaying directly (it's the same resolution). diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index 1453cbe643..378c3b0467 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el @@ -8694,9 +8694,12 @@ used to take the screenshot." (insert-image (create-image image 'png t :max-width (* (frame-pixel-width) 0.8) - :max-height (* (frame-pixel-height) 0.8)) + :max-height (* (frame-pixel-height) 0.8) + :scale 1) (format "<#part type=\"image/png\" disposition=inline content-transfer-encoding=base64 raw=t>\n%s\n<#/part>" - ;; Get a base64 version of the image. + ;; Get a base64 version of the image -- this avoids later + ;; complications if we're auto-saving the buffer and + ;; restoring from a file. (with-temp-buffer (set-buffer-multibyte nil) (insert image) commit a06f41ad2ca786a70940297fd832a649196be9be Author: Lars Ingebrigtsen Date: Wed Aug 5 12:21:35 2020 +0200 Implement a screenshot command for Message mode * doc/misc/message.texi (MIME): Document it. * lisp/gnus/message.el (message-screenshot-command): New variable. (message-mode-map): New keystroke and menu item. Also add mml-attach-file to the menu. (message-insert-screenshot): New command. * lisp/gnus/mml.el (mml-parse-1): Allow having content-transfer-encoding already in the part, so that we can have inline base64-encoded binaries in the Message buffers. diff --git a/doc/misc/message.texi b/doc/misc/message.texi index bdd31b1fe4..7a66422b17 100644 --- a/doc/misc/message.texi +++ b/doc/misc/message.texi @@ -883,6 +883,18 @@ is a list, valid members are @code{type}, @code{description} and @code{nil}, don't ask for options. If it is @code{t}, ask the user whether or not to specify options. +@vindex message-screenshot-command +@findex message-insert-screenshot +@cindex screenshots +@kindex C-c C-p +If your system supports it, you can also insert screenshots directly +into the Message buffer. The @kbd{C-c C-p} +(@code{message-insert-screenshot}) command inserts the image into the +buffer as an @acronym{MML} part, and puts an image text property on +top. The @code{message-screenshot-command} variable says what +external command to use to take the screenshot. It defaults to +@code{"import png:-"}, which is an ImageMagick command. + You can also create arbitrarily complex multiparts using the @acronym{MML} language (@pxref{Composing, , Composing, emacs-mime, The Emacs MIME Manual}). diff --git a/etc/NEWS b/etc/NEWS index 670e97f52c..8c6e3e7813 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -228,6 +228,14 @@ The names of the commands 'gnus-slave', 'gnus-slave-no-server' and *** The 'W Q' summary mode command now takes a numerical prefix to allow adjusting the fill width. ++++ +*** New variable 'mm-inline-font-lock'. +This variable is supposed to be bound by callers to determine whether +inline MIME parts (that support it) are supposed to be font-locked or +not. + +** Message + --- *** Change to default value of 'message-draft-headers' user option. The 'Date' symbol has been removed from the default value, meaning that @@ -237,10 +245,10 @@ from when it is first saved or delayed, add the symbol 'Date' back to this user option. +++ -*** New variable 'mm-inline-font-lock'. -This variable is supposed to be bound by callers to determine whether -inline MIME parts (that support it) are supposed to be font-locked or -not. +*** New command to take screenshots. +In Message mode buffers, the 'C-c C-p' ('message-insert-screenshot') +command has been added. It depends on using an external program to +take the actual screenshot, and defaults to ImageMagick "import". ** Help diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index fb560f0eab..1453cbe643 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el @@ -303,6 +303,13 @@ any confusion." :link '(custom-manual "(message)Message Headers") :type 'regexp) +(defcustom message-screenshot-command '("import" "png:-") + "Command to take a screenshot. +The command should insert a PNG in the current buffer." + :group 'message-various + :type '(list string) + :version "28.1") + ;;; Start of variables adopted from `message-utils.el'. (defcustom message-subject-trailing-was-query t @@ -2810,6 +2817,7 @@ systematically send encrypted emails when possible." (define-key message-mode-map [remap split-line] 'message-split-line) (define-key message-mode-map "\C-c\C-a" 'mml-attach-file) + (define-key message-mode-map "\C-c\C-p" 'message-insert-screenshot) (define-key message-mode-map "\C-a" 'message-beginning-of-line) (define-key message-mode-map "\t" 'message-tab) @@ -2839,6 +2847,8 @@ systematically send encrypted emails when possible." :active (message-mark-active-p) :help "Mark region with enclosing tags"] ["Insert File Marked..." message-mark-insert-file :help "Insert file at point marked with enclosing tags"] + ["Attach File..." mml-attach-file t] + ["Insert Screenshot" message-insert-screenshot t] "----" ["Send Message" message-send-and-exit :help "Send this message"] ["Postpone Message" message-dont-send @@ -8652,6 +8662,49 @@ Used in `message-simplify-recipients'." (* 0.5 (- (nth 3 edges) (nth 1 edges))))) string))))))) +(defun message-insert-screenshot (delay) + "Take a screenshot and insert in the current buffer. +DELAY (the numeric prefix) says how many seconds to wait before +starting the screenshotting process. + +The `message-screenshot-command' variable says what command is +used to take the screenshot." + (interactive "p") + (unless (executable-find (car message-screenshot-command)) + (error "Can't find %s to take the screenshot" + (car message-screenshot-command))) + (cl-decf delay) + (unless (zerop delay) + (dotimes (i delay) + (message "Sleeping %d second%s..." + (- delay i) + (if (= (- delay i) 1) + "" + "s")) + (sleep-for 1))) + (message "Take screenshot") + (let ((image + (with-temp-buffer + (set-buffer-multibyte nil) + (apply #'call-process + (car message-screenshot-command) nil (current-buffer) nil + (cdr message-screenshot-command)) + (buffer-string)))) + (set-mark (point)) + (insert-image + (create-image image 'png t + :max-width (* (frame-pixel-width) 0.8) + :max-height (* (frame-pixel-height) 0.8)) + (format "<#part type=\"image/png\" disposition=inline content-transfer-encoding=base64 raw=t>\n%s\n<#/part>" + ;; Get a base64 version of the image. + (with-temp-buffer + (set-buffer-multibyte nil) + (insert image) + (base64-encode-region (point-min) (point-max) t) + (buffer-string)))) + (insert "\n\n") + (message ""))) + (provide 'message) (run-hooks 'message-load-hook) diff --git a/lisp/gnus/mml.el b/lisp/gnus/mml.el index 21491499eb..1d348f3a6f 100644 --- a/lisp/gnus/mml.el +++ b/lisp/gnus/mml.el @@ -295,6 +295,17 @@ part. This is for the internal use, you should never modify the value.") (t (mm-find-mime-charset-region point (point) mm-hack-charsets)))) + ;; We have a part that already has a transfer encoding. Undo + ;; that so that we don't double-encode later. + (when (and raw + (cdr (assq 'content-transfer-encoding tag))) + (with-temp-buffer + (set-buffer-multibyte nil) + (insert contents) + (mm-decode-content-transfer-encoding + (intern (cdr (assq 'content-transfer-encoding tag))) + (cdr (assq 'type tag))) + (setq contents (buffer-string)))) (when (and (not raw) (memq nil charsets)) (if (or (memq 'unknown-encoding mml-confirmation-set) (message-options-get 'unknown-encoding) @@ -313,8 +324,8 @@ Message contains characters with unknown encoding. Really send? ") (eq 'mml (car tag)) (< (length charsets) 2)) (if (or (not no-markup-p) + ;; Don't create blank parts. (string-match "[^ \t\r\n]" contents)) - ;; Don't create blank parts. (push (nconc tag (list (cons 'contents contents))) struct)) (let ((nstruct (mml-parse-singlepart-with-multiple-charsets commit c9d550a301d3a5e62b3296804ccf42efc69d0796 Author: Lars Ingebrigtsen Date: Wed Aug 5 11:34:56 2020 +0200 Fontize $(...) slightly better in bash mode * lisp/progmodes/sh-script.el (sh-font-lock-keywords-var): Fontize $(...) slightly better (bug#42417). Instead of just fontizing the first word in the expression, fontize until the closing parenthesis. This doesn't work well if you have nested $(...) expressions. diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index 044d7820ee..5a47594878 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el @@ -838,7 +838,7 @@ See `sh-feature'.") font-lock-variable-name-face)) (rc sh-append es) - (bash sh-append sh ("\\$(\\(\\sw+\\)" (1 'sh-quoted-exec t) )) + (bash sh-append sh ("\\$(\\([^)\n]+\\)" (1 'sh-quoted-exec t) )) (sh sh-append shell ;; Variable names. ("\\$\\({#?\\)?\\([[:alpha:]_][[:alnum:]_]*\\|[-#?@!]\\)" 2 commit 3f358fc172c50868321b0ef246adb66a7ea795c9 Author: Lars Ingebrigtsen Date: Wed Aug 5 11:27:54 2020 +0200 Mention undo in the doc string of dired-do-kill-lines * lisp/dired-aux.el (dired-do-kill-lines): Mention that this can be undone (bug#42707). diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index efb214088d..806a3955e4 100644 --- a/lisp/dired-aux.el +++ b/lisp/dired-aux.el @@ -952,13 +952,17 @@ With a prefix argument, kill that many lines starting with the current line. "Kill all marked lines (not the files). With a prefix argument, kill that many lines starting with the current line. \(A negative argument kills backward.) + If you use this command with a prefix argument to kill the line for a file that is a directory, which you have inserted in the Dired buffer as a subdirectory, then it deletes that subdirectory from the buffer as well. + To kill an entire subdirectory \(without killing its line in the parent directory), go to its directory header line and use this -command with a prefix argument (the value does not matter)." +command with a prefix argument (the value does not matter). + +To undo the killing, the undo command can be used as normally." ;; Returns count of killed lines. FMT="" suppresses message. (interactive "P") (if arg commit c72b734c917f635fac09f691e91d3391b00b96f2 Author: Kevin Brubeck Unhammer Date: Wed Aug 5 11:13:51 2020 +0200 Further fix for erc-generate-new-buffer-name * lisp/erc/erc.el (erc-generate-new-buffer-name): Fix buffer name generation when there's two networks on the same server:port (bug#40121). diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index 927546abc3..62aa76d25c 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el @@ -1630,9 +1630,10 @@ symbol, it may have these values: (and (erc-server-buffer-p) (not (erc-server-process-alive))))) ;; Channel buffer; check that it's from the right server. - (with-current-buffer (get-buffer candidate) - (and (string= erc-session-server server) - (erc-port-equal erc-session-port port))))) + (and target + (with-current-buffer (get-buffer candidate) + (and (string= erc-session-server server) + (erc-port-equal erc-session-port port)))))) (setq buffer-name candidate))) ;; if buffer-name is unset, neither candidate worked out for us, ;; fallback to the old uniquification method: