[OE-core] [PATCH V2] e2fsprogs: fix test f_detect_junk print error msg

Changqing Li changqing.li at windriver.com
Fri Oct 12 02:10:33 UTC 2018



On 10/12/2018 06:15 AM, Richard Purdie wrote:
> On Thu, 2018-10-11 at 18:16 +0800, changqing.li at windriver.com wrote:
>> From: Changqing Li <changqing.li at windriver.com>
>>
>> 1. This test need to check config.h, so install it
>>
>> 2. Test script have problem when the file want to grep
>> don't exist, change the check command to fix this problem
>>
>> even we install the config.h,  but the script use relative path,
>> and will find the config.h decide by in which folder you run
>> the test scirpt. like below 2 cases, if without the fix of
>> check command, it will also met error msg in case (b). But, with
>> the fix, the problem can be fixed
>>
>> a) root at qemux86-64:/usr/lib/e2fsprogs/ptest/test# ./test_one
>> ./f_detect_junk
>> f_detect_junk: detect non-fs file data: ok
>>
>> b) root at qemux86-64:/usr/lib/e2fsprogs/ptest# ./test/test_one
>> ./test/f_detect_junk
>> grep: ../lib/config.h: No such file or directory
>> ./test/f_detect_junk/script: line 3: [: : integer expression expected
>> f_detect_junk: detect non-fs file data: ok
>>
>> Signed-off-by: Changqing Li <changqing.li at windriver.com>
> If you've fixed 1) then we don't need to carry the patch for 2)?
I agree with you. we can first do like this, I will resend a patch.
case b) is rare and not critial.
>
> Perhaps it should be sent upstream as an improvement to their code? I'm
> not sure I agree with the Upstream-Status.
>
> Regardless, I don't want to add a patch which we don't really need
> though...
I will report the patch as improvement to upstream.  Anyway,  the check 
command
change only can see as workaround,  the correct way should  not use 
relative path
, but use like top_builddir/lib/config.h.


//Sandy

> Cheers,
>
> Richard
>
>

-- 
BRs

Sandy(Li Changqing)
Wind River Linux




More information about the Openembedded-core mailing list