]> rtime.felk.cvut.cz Git - linux-conf-perf.git/blob - conf.py
kernel configuration now calling write_conf instead of make odlconfig hack
[linux-conf-perf.git] / conf.py
1 import os
2 from exceptions import MissingFile
3
4 def pf(rfile):
5         "Relative patch of file is decoded to absolute acording to working tree."
6         return os.path.dirname(os.path.realpath(__file__)) + '/' + rfile
7
8 def checkXf(f, message):
9         "Check if file is executable. If not, raise MissingFile exception."
10         if os.path.isfile(f) and os.access(f, os.X_OK):
11                 return f
12         else:
13                 raise MissingFile(f, message)
14
15 # Global configs
16 SRCARCH = 'x86' # Kernel architecture
17 ARCH = SRCARCH
18 linux_make_args = ['-j8']
19
20 # Path settings
21 linux_sources = pf('linux')
22 linux_kconfig_head = 'Kconfig'
23 linux_dot_config = linux_sources + '/.config'
24
25 build_folder = pf('build/')
26 phase_file = build_folder + '/phase'
27 symbol_map_file = build_folder + '/symbol_map' # Also defined in kconfig_parser
28 rules_file = build_folder + '/rules' # Also defined in kconfig_parser
29 solved_file = build_folder + '/solved'
30 required_file = build_folder + '/required'
31 dot_config_fragment_file = build_folder + '/dot_config_fragment'
32 dot_config_back_file = build_folder + '/dot_config_back'
33 solution_file = build_folder + '/solution'
34 iteration_file = build_folder + '/iteration'
35
36 # Programs paths
37 parse_kconfig = checkXf(pf('scripts/parse_kconfig/parse'), 'You must build programs first.')
38 write_config = checkXf(pf('scripts/write_config/write'), 'You must build programs first.')
39
40 # Programs output show/hide
41 parse_kconfig_output = False
42 minisat_output = False
43 kernel_config_output = True
44 kernel_make_output = True