diff options
-rw-r--r-- | conf.py | 3 | ||||
-rw-r--r-- | scripts/initialize.py | 4 | ||||
-rw-r--r-- | scripts/solution.py | 9 |
3 files changed, 10 insertions, 6 deletions
@@ -7,9 +7,10 @@ ARCH = SRCARCH linux_make_args = ['-j8'] novaboot_args = ['--qemu=qemu-system-x86_64'] +minisat_args = ['-verb=2'] # Programs output show/hide parse_kconfig_output = False -minisat_output = False +minisat_output = True kernel_config_output = True kernel_make_output = False boot_output = False diff --git a/scripts/initialize.py b/scripts/initialize.py index 8fb06df..40d9eb5 100644 --- a/scripts/initialize.py +++ b/scripts/initialize.py @@ -6,7 +6,7 @@ import shutil import utils from conf import conf from conf import sf -from exceptions import MissingFile +import exceptions def parse_kconfig(): "Execute parse_kconfig in linux_sources directory." @@ -24,7 +24,7 @@ def gen_requred(): "Generates required depenpency from .config file in linux source tree." if not os.path.isfile(sf(conf.linux_dot_config)): - raise MissingFile(sf(conf.linux_dot_config), + raise exceptions.MissingFile(sf(conf.linux_dot_config), 'Generate initial configuration. Execute make defconfig in linux folder. Or use make menuconfig and change configuration.') utils.build_symbol_map() # Ensure smap existence diff --git a/scripts/solution.py b/scripts/solution.py index 21f6d88..a09257a 100644 --- a/scripts/solution.py +++ b/scripts/solution.py @@ -36,7 +36,7 @@ def generate(): if ln not in lines: lines.add(ln) if os.path.isfile(sf(conf.required_file)): - for lnn in open((conf.required_file), 'r'): + for lnn in open(sf(conf.required_file), 'r'): ln = lnn.rstrip() if ln not in lines: lines.add(ln) @@ -54,9 +54,11 @@ def generate(): # Execute minisat if conf.minisat_output: - subprocess.call(['minisat', w_file.name, sf(conf.solution_file)]) + subprocess.call(['minisat', w_file.name, sf(conf.solution_file)] + + conf.minisat_args) else: - subprocess.call(['minisat', w_file.name, sf(conf.solution_file)], stdout=subprocess.DEVNULL) + subprocess.call(['minisat', w_file.name, sf(conf.solution_file)] + + conf.minisat_args, stdout=subprocess.DEVNULL) os.remove(w_file.name) @@ -98,6 +100,7 @@ def apply(): f.write( ntx + txt + " ") f.write("\n") + # Load variable count with open(sf(conf.symbol_map_file)) as f: for var_num, l in enumerate(f): pass |