Subject: Re: bug#17478: "No such file or directoryn" due to incorrect escaping

From: Egmont Koblinger <[email-masked]>
Date: Tue, 13 May 2014 12:59:43 +0200

Hi,

Thanks very much, it works as expected.

I've applied the patch to the system-wide /usr/share/libtool/config/ltmain.sh.

The only change in the generated vte-2.91 script is:
-    printf %s\n "$relink_command_output" >&2
+    $ECHO "$relink_command_output" >&2

Given that the script contains a couple more $ECHO's here and there to
print stuff, I assume this is the desired result.

Running the script produces the proper error message formatted
correctly, with newline instead of 'n':

PROMPT$ ./src/vte-2.91
gcc: error: vte_2_91-app.o: No such file or directory
gcc: error: vte_2_91-appresources.o: No such file or directory
gcc: error: ./.libs/libvte-2.91.so: No such file or directory
PROMPT$

thx again,
egmont

On Tue, May 13, 2014 at 11:50 AM, Peter Rosin <[email-masked]> wrote:
> On 2014-05-13 11:36, Peter Rosin wrote:
>> On 2014-05-13 10:57, Egmont Koblinger wrote:
>>>> I believe this line is generated from these lines of libtool.m4 and
>>>> ltmain.sh (attaching these too):
>>>> libtool.m4:1183:   ECHO='printf %s\n'
>>>> ltmain.sh:4069:      $ECHO \"\$relink_command_output\" >&2
>>
>> Looks likely.
>>
>> I think you should try to prepend \ to that $ECHO, I'll send a patch
>> for libtool proper shortly. Not sure how you should test this though,
>> when you are using the system libtool...
>>
>> I.e. try to change that line to:
>>       \$ECHO \"\$relink_command_output\" >&2
>
> Patch attached, as promised.
>
> I'll hold of pushing this until I get some feedback.
>
> Cheers,
> Peter
>