From 436b2ccb5a619f41e41d973ada417d47cb7839dd Mon Sep 17 00:00:00 2001
From: Leah Rowe <leah@libreboot.org>
Date: Sat, 2 Sep 2023 17:02:17 +0100
Subject: handle/make/config -m/-u: actually copy configs

they weren't being copied back, after running the
make command. i overlooked this when testing in
the previous optimisations, because i only tested
building, not modification or updating of configs

Signed-off-by: Leah Rowe <leah@libreboot.org>
---
 script/handle/make/config | 4 ++++
 1 file changed, 4 insertions(+)

(limited to 'script/handle/make/config')

diff --git a/script/handle/make/config b/script/handle/make/config
index d976e529..1b395600 100755
--- a/script/handle/make/config
+++ b/script/handle/make/config
@@ -240,6 +240,10 @@ run_make_command()
 	fi
 	make -C "${codedir}" -j$(nproc) ${mode} || \
 	    fail "run_make_command: make-all: ${codedir} (${project}/${target})"
+	if [ "${mode}" = "oldconfig" ] || [ "${mode}" = "menuconfig" ]; then	
+		cp "${codedir}/.config" "${config}" || \
+		    fail "run_make: can't edit config: ${project}/${target}"
+	fi
 }
 
 copy_elf()
-- 
cgit v1.2.1