[OE-core] [PATCH 2/2] populate_sdk_base: ensure that filenames with empty space character are handled

Otavio Salvador otavio at ossystems.com.br
Wed Jul 9 01:33:40 UTC 2014


Hello Saul,

On Tue, Jul 8, 2014 at 9:19 PM, Saul Wold <sgw at linux.intel.com> wrote:
> On 07/01/2014 06:58 PM, João Henrique Ferreira de Freitas wrote:
>>
>> When extracting toolchain, if the list $executable_files has filenames
>> with empty space character, the list will created but relocate_sdk.sh
>> will not handle it well. This will lead to the below erro:
>>
>>
>> ./tmp/deploy/sdk/buildtools-mytools-x86_64-nativesdk-standalone-1.6.1.0.sh
>>      Enter target directory for SDK (default:
>> /opt/mydistro/mytoolset/1.6.1.0):
>>      You are about to install the SDK to
>> "/opt/mydistro/mytoolset/1.6.1.0". Proceed[Y/n]?
>>      Extracting SDK...done
>>      Setting it up.../opt/mydistro/mytoolset/1.6.1.0/relocate_sdk.sh: line
>> 2: sintaxe error `token'  `('
>>      /opt/mydistro/mytoolset/1.6.1.0/relocate_sdk.sh: line 2: `e
>>
>> The same occurs with replacement of ${SDKPATH} in configs/scripts/etc
>> files.
>>
>> We should ensure that full path is protected before relocate_sdk.sh
>> and ${SDKPATH} replacement calls.
>>
>
> I am not sure about this one, there are other cases where spaces in
> filenames/directory pathes just don't work, so fixing one place may not
> address all issues, I thought this was documented someplace, but I can't
> seem to find the associated bug or wiki entries.
>
> Maybe someone else can remind me also where we talk about whitespace in
> pathe, obviously my search-fu is off right now.

I agree this problem should exist in other places but I think this
does not invalidate Joao's patch and it should be reviewed and merged
if correct.

Now talking about  the patch itself, Joao, did you try to avoid the
extra fork calling echo? Using '-print0' option in find might help.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750



More information about the Openembedded-core mailing list