Re: [PATCH 0/6] restore compatibility with pre-POSIX shells in config.guess

2021-05-22 Thread Jacob Bachmeyer
Zack Weinberg wrote: On Sat, May 22, 2021 at 9:06 PM Jacob Bachmeyer > wrote: This patch series tidies config.guess and reverts to classic backtick command substitutions. I fully endorse reverting config.{sub,guess} to classic backtick command substitutions. Tha

Re: [PATCH 0/6] restore compatibility with pre-POSIX shells in config.guess

2021-05-22 Thread Zack Weinberg
On Sat, May 22, 2021 at 9:06 PM Jacob Bachmeyer wrote: > This patch series tidies config.guess and reverts to classic backtick > command substitutions. I fully endorse reverting config.{sub,guess} to classic backtick command substitutions. However, Autoconf proper (in 2.70+) will continue to lo

[PATCH 3/6] config.guess: remove unneeded variable quotes

2021-05-22 Thread Jacob Bachmeyer
This is further cleanup and is a separate patch due to its size and mostly automated origin. This patch was mostly produced using the following Emacs Lisp: (defun tidy-guess-variables () (interactive) (while (search-forward "GUESS=" nil t) (while (re-search-forward "\"\\(\\$

[PATCH 6/6] config.guess: minor cleanups noticed during previous pass

2021-05-22 Thread Jacob Bachmeyer
This patch is a few "stragglers" that did not match the patterns used in earlier passes through the script, and were noticed while completing the reversion of command substitutions to traditional form. (No ChangeLog entry for this patch; these belong to earlier changes.) --- config.guess | 24 +++

[PATCH 5/6] config.guess: replace POSIX $( ) with classic ` ` throughout

2021-05-22 Thread Jacob Bachmeyer
The previous replacement of backticks with POSIX command substitutions was ill-considered and illogical: this script recognizes many archaic machine types that probably never had POSIX shells, therefore it needs to be able to run successfully under pre-POSIX shells. Nor was there any significant

[PATCH 1/6] config.guess: remove unneeded quotes in case constructs

2021-05-22 Thread Jacob Bachmeyer
* config.guess: Tidy case constructs by removing quotes around the argument; the Autoconf portable shell guidelines note that no shell splits that argument in any case. --- config.guess | 34 +- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/config.

[PATCH 2/6] config.guess: use intermediate variable with uname results

2021-05-22 Thread Jacob Bachmeyer
This will allow quoting to be significantly simplified in another pass through the file. This was done with some manual cleanup after running this Emacs Lisp: (defun edit-all-exits () (interactive) (while (re-search-forward "^\\([[:space:]]+\\)echo[[:space:]]+\\([^\n]+

[PATCH 4/6] config.guess: factor out command substitutions setting GUESS

2021-05-22 Thread Jacob Bachmeyer
This simplifies some constructs that can confuse Emacs' syntax highlighting and generally reduces the amount of quoting required. This patch also somewhat standardizes spacing in a fairly common pattern of applying some sed pattern to $UNAME_RELEASE. * config.guess: factor out some command substi

[PATCH 0/6] restore compatibility with pre-POSIX shells in config.guess

2021-05-22 Thread Jacob Bachmeyer
This patch series tidies config.guess and reverts to classic backtick command substitutions. No shell splits the WORD in "case WORD in ... esac", so instances where WORD was quoted were changed. Quotes while forming the output are pointless, since no valid GNU configuration tuple contains whitesp