menuconfig: support mtk kernel directory style (!1790)

(Some?) Mediatek kernels don't have the kernel in the top-level
directory but in a subdirectory called 'kernel' next to a folder
'mediatek' containing most device-specific code.

Adjust the menuconfig code to be able to work with that.
This commit is contained in:
Luca Weiss 2019-05-26 15:12:37 +02:00 committed by Oliver Smith
parent 4daf991640
commit fef10fd5ed
No known key found for this signature in database
GPG Key ID: 5AE7F5513E0885CB
1 changed files with 3 additions and 0 deletions

View File

@ -81,6 +81,9 @@ def get_outputdir(args, pkgname):
output_return=True).rstrip()
if os.path.exists(chroot + ret + "/.config"):
return ret
# Some Mediatek kernels use a 'kernel' subdirectory
if os.path.exists(chroot + ret + "/kernel/.config"):
return os.path.join(ret, "kernel")
# Not found
raise RuntimeError("Could not find the kernel config. Consider making a"