blob: 3ed09fab9ef1b556521d8461c550f235aba8674e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
# Works like entering "make menuconfig" and immediately saving and exiting
import kconfiglib
import os
import sys
conf = kconfiglib.Config(sys.argv[1])
if os.path.exists(".config"):
conf.load_config(".config")
else:
defconfig = conf.get_defconfig_filename()
if defconfig is not None:
print "Using " + defconfig
conf.load_config(defconfig)
conf.write_config(".config")
|