bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: po/Makefile.in.in overrides SHELL to /bin/sh


From: Bruno Haible
Subject: Re: po/Makefile.in.in overrides SHELL to /bin/sh
Date: Fri, 27 Feb 2009 21:11:25 +0100
User-agent: KMail/1.9.9

Hello,

Scott James Remnant wrote:
> The po/Makefile.in.in included with gettext explicitly sets SHELL
> to /bin/sh, instead of @address@hidden
> 
> It then calls various tools with this hardcoded shell, when some of
> those tools are generated by Autoconf/m4sh with another shell in mind.
> 
> Absolutely worst is calling config.status with /bin/sh, as that can
> result in other tools being regenerated improperly.
> 
> (We see this attempting to reconfigure GTK+ - the libtool script becomes
>  mangled as /bin/sh--which is dash in Ubuntu--turns the \1 in the sed
>  scripts to ^A--the config.status was written with SHELL=/bin/bash in
>  mind).

Thank you for reporting this. install-sh, mkinstalldirs and similar should
be invoked via /bin/sh, since that's the first line of these scripts.
But for config.status, you're right: it depends on autoconf's "preferred
shell" CONFIG_SHELL. I'm applying this patch, in order to use it.


2009-02-27  Bruno Haible  <address@hidden>

        * Makefile.in.in (Makefile): Use @SHELL@, not $(SHELL).
        Reported by Scott James Remnant <address@hidden>.

Index: Makefile.in.in
===================================================================
RCS file: /sources/gettext/gettext/gettext-runtime/po/Makefile.in.in,v
retrieving revision 1.36
diff -c -3 -r1.36 Makefile.in.in
*** Makefile.in.in      19 Jan 2009 00:28:15 -0000      1.36
--- Makefile.in.in      27 Feb 2009 20:06:32 -0000
***************
*** 431,439 ****
  update-gmo: Makefile $(GMOFILES)
        @:
  
  Makefile: Makefile.in.in Makevars $(top_builddir)/config.status 
@POMAKEFILEDEPS@
        cd $(top_builddir) \
!         && $(SHELL) ./config.status $(subdir)/address@hidden po-directories
  
  force:
  
--- 431,443 ----
  update-gmo: Makefile $(GMOFILES)
        @:
  
+ # Recreate Makefile by invoking config.status. Explicitly invoke the shell,
+ # because execution permission bits may not work on the current file system.
+ # Use @SHELL@, which is the shell determined by autoconf for the use by its
+ # scripts, not $(SHELL) which is hardwired to /bin/sh and may be deficient.
  Makefile: Makefile.in.in Makevars $(top_builddir)/config.status 
@POMAKEFILEDEPS@
        cd $(top_builddir) \
!         && @SHELL@ ./config.status $(subdir)/address@hidden po-directories
  
  force:
  




reply via email to

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