automake-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[FYI] {micro} lisp: fix a failure with Solaris /usr/xpg4/bin/sh


From: Stefano Lattarini
Subject: [FYI] {micro} lisp: fix a failure with Solaris /usr/xpg4/bin/sh
Date: Sat, 18 May 2013 15:19:48 +0200

* lib/am/lisp.am (.el.elc): By initializing the 'am__dir' properly
here.  For most shells, the lacking initialization, while technically
incorrect, didn't cause any issue in practice, because in those shells
"test -d" returns an exit status of 0. But with /usr/xpg4/bin/sh, the
shell complains like this: "test: argument expected", and returns a
non-zero exit status.  This caused testsuite failures in several lisp
tests.
Also, while we are at it, use more proper quoting in the recipe, to
ensure a missing initialization to now be caught by more forgiving
shells as well.
* NEWS: Update.

Signed-off-by: Stefano Lattarini <address@hidden>
---
 NEWS           | 9 +++++++++
 lib/am/lisp.am | 4 ++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/NEWS b/NEWS
index 493b535..3b6814d 100644
--- a/NEWS
+++ b/NEWS
@@ -80,6 +80,15 @@
 
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
+New in 1.13.3:
+
+* Bugs fixed:
+
+  - Byte-compilation of Emacs lisp files could fail spuriously on Solaris,
+    when /bin/ksh or /usr/xpg4/bin/sh were used as shell.
+
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
 New in 1.13.2:
 
 * Obsolescent features:
diff --git a/lib/am/lisp.am b/lib/am/lisp.am
index de9e5bb..bfb023f 100644
--- a/lib/am/lisp.am
+++ b/lib/am/lisp.am
@@ -31,13 +31,13 @@ endif %?INSTALL%
 ## input (which would erronously put it in $(srcdir) in VPATH builds),
 ## so we override that, too.
        if test "$(EMACS)" != "no"; then \
-         am__subdir_includes=''; \
+         am__dir=. am__subdir_includes=''; \
          case $@ in */*) \
            am__dir=`echo '$@' | sed 's,/[^/]*$$,,'`; \
            am__subdir_includes="-L $$am__dir -L $(srcdir)/$$am__dir"; \
          esac; \
 ## Emacs byte-compilation won't create this automatically, sadly.
-         test -d $$am__dir || $(MKDIR_P) $$am__dir || exit 1; \
+         test -d "$$am__dir" || $(MKDIR_P) "$$am__dir" || exit 1; \
          $(EMACS) --batch \
            $(AM_ELCFLAGS) $(ELCFLAGS) \
            $$am__subdir_includes -L $(builddir) -L $(srcdir) \
-- 
1.8.3.rc2




reply via email to

[Prev in Thread] Current Thread [Next in Thread]