bug-libtool
[Top][All Lists]
Advanced

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

Re: [0/3] Different sed program could be used in libtool script


From: Yann Droneaud
Subject: Re: [0/3] Different sed program could be used in libtool script
Date: Thu, 11 Dec 2008 10:29:28 +0100

Hi,

Le mercredi 10 décembre 2008 à 21:36 +0100, Ralf Wildenhues a écrit :
> Hello Yann,
> 
> first off, thank you for the report and the patches.  Please
> note that, in order to accept nontrivial patches, the FSF needs
> a copyright assignment from you, more off-list.  Also please
> send further patches to the libtool-patches list, thank you.
> 

Wow, considering my patches non-trivial, anyone could run sed 's/\<sed
\>/$SED' on the libtool file.

So these patches are trivials or are not patches after all but just
detailled bug reports.

> * Yann Droneaud wrote on Wed, Dec 10, 2008 at 05:30:14PM CET:
> > Through out the libtool script, $SED is used, but sometimes 'sed' is
> > used directly.
> > 
> > Libtool should be consistent regarding to which sed is used in the
> > script.
> 
> This may sound like a dumb question, but is meant to be honest: why?
> 

These patches are dumb so dumb question are welcome :)

So see the following commands:

> libtool: link: /usr/bin/nm
-B  .libs/gdk-pixbuf.o .libs/gdk-pixbuf-animation.o .libs/gdk-pixbuf-data.o 
.libs/gdk-pixbuf-io.o .libs/gdk-pixbuf-loader.o .libs/gdk-pixbuf-scale.o 
.libs/gdk-pixbuf-simple-anim.o .libs/gdk-pixbuf-scaled-anim.o 
.libs/gdk-pixbuf-util.o .libs/gdk-pixdata.o .libs/gdk-pixbuf-enum-types.o   
pixops/.libs/libpixops.a | sed -n -e 's/^.*[     
]\([ABCDGIRSTW][ABCDGIRSTW]*\)[     ][     ]*\([_A-Za-z][_A-Za-z0-9]*\)$/  /p' 
| /bin/sed 's/.* //' | sort | uniq > .libs/libgdk_pixbuf-2.0.exp

Here two different sed are used in the same command.

For me, it's unpretty and could reveal bugs.
Using the same sed command inside libtool seems better: same behavor
accross command, less bug.


> Autotools generally assume a mostly sane environment that has certain
> unixy tools available.  Indirections like $SED cater to actual
> limitations in existing (mostly proprietary) implementations, like line
> length limits, bugs, or slow execution speed.  However, many uses of sed
> in Libtool are not really relevant to these issues.
> 
> Remains bugs we don't know about yet, and maybe things like "why let
> /bin/sed in the file cache when /opt/bin/gsed already is".  Maybe a
> minor point but not all that relevant with today's systems.
> 
> Mind you, there are disadvantages of using $SED: you have to ensure
> that each macro that executes $SED has require'd _LT_DECL_SED (you
> seem to have taken care of this in the patches).  Each libtool
> variable that contains $SED (quoted) needs to have the right escaping
> done at config.status time.  Errors here do not happen often, but they
> have happened, so there needs to be some actual advantage to making
> the change.
> 

Thanks for the explaination.

-- 
Yann Droneaud






reply via email to

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