diff mbox

[PATCH/autobuild,v2,3/7] autobuild-run: use 'olddefconfig' instead of 'oldconfig'

Message ID 20170410220003.30421-3-arnout@mind.be
State Accepted
Headers show

Commit Message

Arnout Vandecappelle April 10, 2017, 9:59 p.m. UTC
Back in the days that autobuild-run was created, we didn't have an
olddefconfig target so we had to pipe yes into oldconfig instead.
Nowadays, however, we can use the olddefconfig target.

Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
v2: Also use 'olddefconfig' for the second call to 'oldconfig'
---
 scripts/autobuild-run | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
diff mbox

Patch

diff --git a/scripts/autobuild-run b/scripts/autobuild-run
index 2f0463d..521b2c9 100755
--- a/scripts/autobuild-run
+++ b/scripts/autobuild-run
@@ -558,8 +558,8 @@  def gen_config(**kwargs):
 
     devnull = open(os.devnull, "w")
 
-    ret = subprocess.call(["yes '' 2>/dev/null| make O=%s -C %s oldconfig" % \
-                           (outputdir, srcdir)], shell=True, stdout=devnull, stderr=devnull)
+    ret = subprocess.call(["make", "O=%s" % outputdir, "-C", srcdir, "olddefconfig"],
+                          stdout=devnull, stderr=devnull)
     if ret != 0:
         log_write(log, "ERROR: cannot oldconfig")
         return -1
@@ -586,8 +586,8 @@  def gen_config(**kwargs):
         if fixup_config(**kwargs):
             break
 
-    ret = subprocess.call(["yes '' 2>/dev/null| make O=%s -C %s oldconfig" % \
-                           (outputdir, srcdir)], shell=True, stdout=devnull, stderr=devnull)
+    ret = subprocess.call(["make", "O=%s" % outputdir, "-C", srcdir, "olddefconfig"],
+                          stdout=devnull, stderr=devnull)
     if ret != 0:
         log_write(log, "ERROR: cannot oldconfig")
         return -1