]> code.ossystems Code Review - openembedded-core.git/commitdiff
cml1: correct diffconfig output format
authorStefan Müller-Klieser <s.mueller-klieser@phytec.de>
Mon, 28 Jul 2014 08:14:44 +0000 (10:14 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 29 Jul 2014 08:57:04 +0000 (09:57 +0100)
If used with some packages using kconfig mechanism, the diffconfig
command generates wrong output format. Diff provides all options to
format the output correctly. This method formats as intended, is more
robust and works with the merge_config.h script from yocto-kernel-tools.

Signed-off-by: Stefan Müller-Klieser <s.mueller-klieser@phytec.de>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/cml1.bbclass

index 34c0c4e6c740adb68c60b3ec2eba82959b8b0826..0d4b10b51451814a16298e0dc121014f72804e74 100644 (file)
@@ -58,7 +58,7 @@ python do_diffconfig() {
         bb.fatal("No config files found. Did you do menuconfig ?\n%s" % e)
 
     if isdiff:
-        statement = 'diff -Nurp ' + configorig + ' ' + config + '| sed -n "s/^\+//p" >' + fragment
+        statement = 'diff --unchanged-line-format= --old-line-format= --new-line-format="%L"' + configorig + ' ' + config + '>' + fragment
         subprocess.call(statement, shell=True)
 
         shutil.copy(configorig, config)