Bug#219156: tetex-bin: postinst script fails to run texconfig under dash
Hilmar Preusse <hille42@web.de> schrieb:
> On 04.11.03 Michel Casabona (michel.casabona@free.fr) wrote:
>
> Hi all,
>
>> "texconfig init" fails when called by tetex-bin.postinst, run under
>> ash/dash. There is no problem when /bin/sh points to bash.
>>
>> The problem occurs in the check_environ() procedure while parsing
>> $envvars, and seems to be caused by the variable contents split on
>> multiple lines (contains embedded "newline").
>>
>> IFS is changed by the postinst script not to include "newline"
>> before texconfig is called. bash and dash seem to behave
>> differently on word expansion wrt IFS (dunno which one is posixly
>> correct ;)
>>
>> A simple patch to save/restore IFS in the postinst script seemed to
>> cure the problem (note that texconfig does the same) :
>>
> Anybody able to reproduce that?
No.
I did the following: In an up-to-date sid pbuilder environment I
installed the ash and dash packages, pointed the /bin/sh symlink to dash
and then apt-get install'ed tetex-bin, with all the dependencies.
Then I purged only tetex-bin, pointed /bin/sh to ash (which, of course,
itself points to dash) and installed tetex-bin again.
In both cases, there were no errors in postinst, and initex was run.
Michel, you have indicated a suspect line, but as far as I see this line
is in texconfig, and you said that texconfig does the same change to IFS
that you needed in postinst to get around the problem. Therefore I
don't quite understand. Could you please post code that works and code
that doesn't, ideally in a script that can be run separately from
package installation?
Thanks, Frank
--
Frank Küster, Biozentrum der Univ. Basel
Abt. Biophysikalische Chemie
Reply to: