$(SHELL) config.status broken

Bug #332840 reported by Loïc Minier
4
Affects Status Importance Assigned to Milestone
GLib
Fix Released
Medium
GTK+
Fix Released
Medium
Gnulib
Fix Released
Undecided
auto-bug-gnulib
gettext
Fix Released
Undecided
auto-bug-gnu-gettext
intltool
Fix Released
Medium
autoconf (Ubuntu)
Invalid
High
Unassigned
dash (Ubuntu)
Invalid
High
Unassigned
gettext (Ubuntu)
Fix Released
Undecided
Unassigned
glib2.0 (Ubuntu)
Fix Released
Low
Ubuntu Desktop Bugs
gnulib (Ubuntu)
Fix Released
Undecided
Unassigned
gtk+2.0 (Ubuntu)
Fix Released
Low
Ubuntu Desktop Bugs
intltool (Ubuntu)
Fix Released
Low
Unassigned

Bug Description

Hi,

My "libtool" script in a random project (gtk+) was full of "^A" chars (\001); examining the build log, I could see that some Makefile.in.in would call: $(SHELL) ./config.status

I confirmed that after ./configure, libtool was ok (no ^A), but after "/bin/sh config.status" it was broken (with ^A). /bin/dash gives the same result, /bin/bash and /bin/zsh work fine.

I'm not sure that this is a dash regression, it could also be a new autoconf.

NB: I think the Makefile.in.in shouldn't have to use $(SHELL), but there are so many weird usages that I don't think I care to fight, also this is in at least gettext, intltool, glib, and copied in some custom Makefile.in.in (such as gtk+/po-properties/Makefile.in.in); I don't think it's worth fighting not to use $(SHELL) to call config.status -- even if config.status is +x and has a shebang generated at configure time.

Bye

Loïc Minier (lool)
Changed in dash:
importance: Undecided → High
Changed in autoconf:
importance: Undecided → High
Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

Please provide a tarball containing the problem package, and instructions to replicate.

Clearly you're the only person seeing this, and so it must be something about the program you're using.

Revision history for this message
Loïc Minier (lool) wrote :

I just reproduced in a clean new jaunty up-to-date vm.

sudo apt-get install subversion
svn co svn://svn.gnome.org/svn/gtk+/trunk gtk+ && cd gtk+
sudo apt-get install --without-recommends build-essential libtool gtk-doc-tools autoconf automake1.7 libglib2.0-dev libatk1.0-dev libpango1.0-dev libcairo2-dev
# --help is to disable the configure run
./autogen --help
mkdir build && cd build
../configure --without-libtiff --without-libjasper
make

This fails with:
...
/usr/bin/ld:.libs/libgdk_pixbuf-2.0.ver:2: ignoring invalid character `\001' in script
/usr/bin/ld:.libs/libgdk_pixbuf-2.0.ver:2: syntax error in VERSION script
and indeed the build/ libtool as odd characters in it. Note that the libtool script is fine after "configure" and is also fine if one reruns config.status.

This is regular jaunty so /bin/sh is dash and the above is run under bash.

Bye,

Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote : Re: [Bug 332840] Re: $(SHELL) config.status broken

On Fri, 2009-02-27 at 11:10 +0000, Loïc Minier wrote:

> ./autogen --help
>
What happens if you use "autoreconf -i" instead of autogen.sh ?

(You may need to run gtkdocize by hand first)

Scott
--
Scott James Remnant
<email address hidden>

Revision history for this message
Loïc Minier (lool) wrote :

Same error with gtkdocize + autoreconf.

Revision history for this message
Loïc Minier (lool) wrote :

I could reproduce with gtk+-2.14.4 from intrepid (just the .orig tarball) with "autoreconf -fi" followed by configure and make (as previously described).

Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

This is a bug in the gtk+2.0 source package, specifically the po-properties sub-directory.

The Makefile there recalls config.status (probably wrongly), but has the SHELL variable hardcoded to /bin/sh

At the very least, the original Makefile.in.in needs to have SHELL = @SHELL@, which will pass on to the Makefile.in and then have SHELL replaced with the correct local value.

I'd strongly suggest someone review the mess though ;-)

Changed in dash:
status: New → Invalid
Changed in autoconf:
status: New → Invalid
Revision history for this message
Loïc Minier (lool) wrote :

Scott, I understand that the SHELL usage is incorrect, I even outlined it in my report, but it's duplicated in many tarballs as it's present in gettext's and intltool's Makefile.in.in, so we need to revert the change which exposes this bug first.

Changed in autoconf:
status: Invalid → Triaged
Changed in dash:
status: Invalid → Triaged
Revision history for this message
Loïc Minier (lool) wrote :

19:28 < lool> Keybuk: Ah
19:28 < lool> Keybuk: after configure, po-properties doesn't have a POTFILES
              while po has!
19:28 < Keybuk> lool: ah!
19:28 < Keybuk> lool: that's probably a bug ;)
19:28 < Keybuk> I've just tested here btw, general gettext fails here too
19:28 < Keybuk> but it's quite hard to replicate
19:28 -!- sabdfl [n=sabdfl@ubuntu/member/sabdfl] has joined #ubuntu-devel
19:29 < Keybuk> ohhhhhhhhhhhhhhhh
19:29 < Keybuk> I've just realised why general gettext doesn't replicate this ;)
19:30 < Keybuk> gettext upstream only calls config.status with its own
                directory name
19:30 < Keybuk> so it only regenerates po/Makefile
19:30 < lool> Which is cleaner
19:30 < Keybuk> so it doesn't smash libtool
19:30 < lool> Keybuk: Ok, the po/POTFILES generation is in glib-gettext.m4, so
              it's specific to this implementation as well
19:30 < Keybuk> it's still a bug that SHELL is overwritten, but it minimises it
19:30 < lool> Keybuk: I think we have a bunch of bugs to fix here; thanks for
              debugging!

=> affects gettext (SHELL), intltool (SHELL), glib x 2 (SHELL and config.status usage), gtk+ (missing configure snippet like for po/), gnulib (SHELL) ...

Changed in dash:
status: Triaged → Invalid
Changed in autoconf:
status: Triaged → Invalid
Revision history for this message
Loïc Minier (lool) wrote :

I'm attaching the patch against SVN which I sent upstream and which fixes the build for me; it only fixes the gtk+/po-properties/-specific bug; the general use of config.status in Makefile.in.in is still poor, but I'll wait for gettext's folks take on this issue before patching these files.

Revision history for this message
Loïc Minier (lool) wrote :
Revision history for this message
Loïc Minier (lool) wrote :

Just FYI, intltool and glib-gettext lack it but upstream gettext has support for multiple po directories.

Loïc Minier (lool)
Changed in gettext:
status: New → Fix Committed
Revision history for this message
Loïc Minier (lool) wrote :
Loïc Minier (lool)
Changed in gnulib:
status: New → Fix Committed
status: Fix Committed → In Progress
Revision history for this message
Sebastien Bacher (seb128) wrote :

the new glib version in jaunty fixes the issue

Changed in glib2.0:
assignee: nobody → desktop-bugs
importance: Undecided → Low
status: New → Fix Released
Revision history for this message
Sebastien Bacher (seb128) wrote :

the bug is fixed upstream now

Changed in gtk+2.0:
assignee: nobody → desktop-bugs
importance: Undecided → Low
status: New → Fix Committed
Revision history for this message
Sebastien Bacher (seb128) wrote :

the issue has been fixed upstream now

Changed in intltool:
importance: Undecided → Low
status: New → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gettext - 0.17-6ubuntu2

---------------
gettext (0.17-6ubuntu2) jaunty; urgency=low

  * Cherry-pick df8857c0472c33bd786a967569c4b3c9c4c177b2 from upstream to use
    autoconf's preferred shell when invoking config.status; LP: #332840.

 -- Loic Minier <email address hidden> Tue, 03 Mar 2009 10:04:46 +0100

Changed in gettext:
status: New → Fix Released
Revision history for this message
Sebastien Bacher (seb128) wrote :

new gtk uploaded

Changed in gtk+2.0:
status: Fix Committed → Fix Released
Changed in glib:
status: Unknown → Fix Released
Changed in gtk:
status: Unknown → Fix Released
Changed in intltool:
status: Unknown → Fix Released
Revision history for this message
Sebastien Bacher (seb128) wrote :

the new version is in jaunty now

Changed in intltool (Ubuntu):
status: Fix Committed → Fix Released
Changed in glib:
importance: Unknown → Medium
Changed in intltool:
importance: Unknown → Medium
Changed in gtk:
importance: Unknown → Medium
Revision history for this message
Colin Watson (cjwatson) wrote :

This was fixed in Gnulib a while back:

commit 681846cee55a407a08a2bbdc7e1484870ba1a79f
Author: Bruno Haible <email address hidden>
Date: Tue May 25 21:35:22 2010 +0200

    Update to GNU gettext 0.18, part 2.

This means it's also fixed in the gnulib package in natty (though not maverick, by the looks of things).

Changed in gnulib:
status: In Progress → Fix Released
Changed in gnulib (Ubuntu):
status: New → Fix Released
Revision history for this message
Colin Watson (cjwatson) wrote :

And, as implied by my last comment, it's fixed in gettext 0.18 too.

commit f12d1cd1d765dd7bf20986d3882884b561ee8820
Author: Bruno Haible <email address hidden>
Date: Fri Feb 27 20:07:34 2009 +0000

    Use autoconf's preferred shell when invoking config.status.

Changed in gettext:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.