Home
last modified time | relevance | path

Searched refs:self (Results 1 – 25 of 73) sorted by relevance

123

/build/hb/resources/
Dconfig.py40 def __init__(self): argument
41 self.config_json = ""
42 self._root_path = ""
43 self._board = ""
44 self._kernel = ""
45 self._product = ""
46 self._product_path = ""
47 self._device_path = ""
48 self._device_company = ""
49 self._patch_cache = ""
[all …]
/build/
Dgn_helpers.py170 def __init__(self, string: str): argument
171 self.input = string
172 self.cur = 0
174 def IsDone(self) -> bool: argument
175 return self.cur == len(self.input)
177 def ConsumeWhitespace(self): argument
178 while not self.IsDone() and self.input[self.cur] in ' \t\n':
179 self.cur += 1
181 def Parse(self): argument
199 result = self._ParseAllowTrailing()
[all …]
/build/scripts/
Dcargo2gn.py136 def __init__(self, runner, outfile_name: str): argument
138 self.runner = runner
139 self.debug = runner.args.debug
140 self.cargo_dir = '' # directory of my Cargo.toml
141 self.outfile = None # open file handle of outfile_name during dump*
142 self.outfile_name = outfile_name # path to BUILD.gn
144 self.module_type = '' # lib,crate_name,test etc.
145 self.root_pkg_name = '' # parent package name of a sub/test packge
147 self.error_infos = '' # all errors found during parsing
148 self.line = '' # original rustc command line parameters
[all …]
/build/hb/services/interface/
Dload_interface.py25 def __init__(self): argument
27 self._config = Config()
30 def config(self): argument
31 return self._config
34 def outputs(self): argument
35 return self._outputs
37 def regist_arg(self, arg_name: str, arg_value: str): argument
38 if arg_name in self._args_dict.keys() and self._args_dict[arg_name] != arg_value:
40 arg_name, self._args_dict[arg_name], arg_value))
42 self._args_dict[arg_name] = arg_value
[all …]
Dpreload_interface.py26 def __init__(self): argument
28 self._config = Config()
31 def outputs(self): argument
32 return self._preloader_outputs
35 def config(self): argument
36 return self._config
38 def regist_arg(self, arg_name: str, arg_value: str): argument
39 if arg_name in self._args_dict.keys() and self._args_dict[arg_name] != arg_value:
41 arg_name, self._args_dict[arg_name], arg_value))
43 self._args_dict[arg_name] = arg_value
[all …]
/build/hb/services/
Dpreloader.py30 def __init__(self): argument
32 self._dirs = ""
33 self._outputs = ""
34 self._product = ""
35 self._os_level = ""
36 self._target_cpu = ""
37 self._target_os = ""
38 self._toolchain_label = ""
39 self._subsystem_info = {}
40 self._all_parts = {}
[all …]
Dloader.py34 def __init__(self): argument
36 self.source_root_dir = ""
37 self.gn_root_out_dir = ""
38 self.os_level = ""
39 self.target_cpu = ""
40 self.target_os = ""
41 self.config_output_relpath = ""
42 self.config_output_dir = ""
43 self.target_arch = ""
44 self.subsystem_config_file = ""
[all …]
Dninja.py32 def __init__(self): argument
34 self.config = Config()
35 self._regist_ninja_path()
37 def run(self): argument
38 self._execute_ninja_cmd()
40 def _execute_ninja_cmd(self): argument
44 ninja_cmd = [self.exec, '-w', 'dupbuild=warn',
45 '-C', self.config.out_path] + self._convert_args()
46 LogUtil.write_log(self.config.log_path,
52 self.config.root_path,
[all …]
/build/hb/util/preloader/
Dpreloader_process_data.py27 def __init__(self, output_dir): argument
28 self.__post_init__(output_dir)
30 def __post_init__(self, output_dir): argument
32 self.build_prop = os.path.join(output_dir, 'build.prop')
33 self.build_config_json = os.path.join(output_dir, 'build_config.json')
34 self.parts_json = os.path.join(output_dir, 'parts.json')
35 self.parts_config_json = os.path.join(output_dir, 'parts_config.json')
36 self.build_gnargs_prop = os.path.join(output_dir, 'build_gnargs.prop')
37 self.features_json = os.path.join(output_dir, 'features.json')
38 self.syscap_json = os.path.join(output_dir, 'syscap.json')
[all …]
/build/scripts/util/
Dmd5_check.py135 def __init__(self, old_metadata, new_metadata, force, missing_outputs): argument
136 self.old_metadata = old_metadata
137 self.new_metadata = new_metadata
138 self.force = force
139 self.missing_outputs = missing_outputs
141 def _get_old_tag(self, path, subpath=None): argument
142 return self.old_metadata and self.old_metadata.get_tag(path, subpath)
144 def has_changes(self): argument
147 self.force or not self.old_metadata or
148 self.old_metadata.strings_md5() != self.new_metadata.strings_md5()
[all …]
Dpyd.py34 def log_message(self, format, *args): # pylint: disable=redefined-builtin argument
40 def do_cache_hit(self): argument
41 self.server.hit_times += 1
42 self.send_response(200)
44 def do_cache_miss(self): argument
45 self.server.miss_times += 1
46 self.send_response(200)
48 def do_cache_manage(self): argument
49 self.send_response(200)
50 self.server.cache_manage()
[all …]
/build/hb/modules/
Dohos_tool_module.py29 …def __init__(self, args_dict: dict, args_resolver: ArgsResolverInterface, gn: BuildFileGeneratorIn… argument
31 self._gn = gn
32 OHOSToolModule._instance = self
43 def gn(self): argument
44 return self._gn
46 def list_targets(self): argument
47 self.args_resolver.resolve_arg(self.args_dict['ls'], self)
49 def desc_targets(self): argument
50 self.args_resolver.resolve_arg(self.args_dict['desc'], self)
52 def path_targets(self): argument
[all …]
Dohos_build_module.py37 def __init__(self, argument
47 OHOSBuildModule._instance = self
48 self._start_time = SystemUtil.get_current_time()
51 def build_time(self): argument
52 return SystemUtil.get_current_time() - self._start_time
63 def run(self): argument
70 self.args_dict.get('product_name').arg_value))
71 LogUtil.hb_info('Cost time: {}'.format(self.build_time))
73 def _prebuild(self): argument
74 self._run_phase(BuildPhase.PRE_BUILD)
[all …]
/build/hb/modules/interface/
Dbuild_module_interface.py31 def __init__(self, argument
40 self._loader = loader
41 self._preloader = preloader
42 self._target_generator = target_generator
43 self._target_compiler = target_compiler
46 def preloader(self): argument
47 return self._preloader
50 def loader(self): argument
51 return self._loader
54 def target_generator(self): argument
[all …]
Dtool_module_interface.py28 def __init__(self, args_dict: dict, args_resolver: ArgsResolverInterface): argument
32 def list_targets(self): argument
36 def desc_targets(self): argument
40 def path_targets(self): argument
44 def refs_targets(self): argument
48 def format_targets(self): argument
52 def clean_targets(self): argument
55 def run(self): argument
56 if self.args_dict['ls'].arg_value:
57 self.list_targets()
[all …]
/build/tools/component_tools/
Dcomponent_node.py22 …def __init__(self, module_name: str, subsystem_name: str, part_name: str, deps: set, external_deps… argument
23 self._module_name = module_name
24 self._subsystem_name = subsystem_name
25 self._part_name = part_name
26 self._deps = deps
27 self._external_deps = external_deps
28 self._raw_data = raw_data
31 def module_name(self): argument
32 return self._module_name
35 def module_name(self, value): argument
[all …]
/build/test/example/
Dperformance_test.py64 def __init__(self, performance_cmd, output_path, report_title, ptyflag=False): argument
65 self.performance_cmd = script_path + performance_cmd
66 self.output_path = script_path + output_path
67 self.report_title = report_title
68 self.ptyflag = ptyflag
69 self.out_queue = queue.Queue()
70 self.system_info = list()
71 self.ninjia_trace_list = list()
72 self.gn_exec_li = list()
73 self.gn_script_li = list()
[all …]
Dmylogger.py29 def __init__(self, filename, mode="a", encoding="utf-8", delay=0, suffix="%Y-%m-%d_%H"): argument
33 FileHandler.__init__(self, filename + "." + current_time, mode, encoding, delay)
35 self.filename = os.fspath(filename)
37 self.mode = mode
38 self.encoding = encoding
39 self.suffix = suffix
40 self.suftime = current_time
42 def emit(self, record): argument
44 if self.parse_file_name():
45 self.gen_file_name()
[all …]
/build/ohos/packages/
Dprocess_field_validate.py30 def __init__(self, name, reason): argument
32 self.name = name
33 self.reason = reason
41 def __init__(self): argument
42 self.uid = ""
43 self.gid = []
44 self.need_verified = False
45 self.enabled_critical = False
46 self.loc = ""
47 self.critical = []
[all …]
Dfs_process.py33 def __init__(self, packer_args) -> None: argument
34 self.config = Config()
35 self.replace_items = {
36 r'${product_name}': self.config.product,
37 r'${root_path}': self.config.root_path,
38 r'${out_path}': self.config.out_path
40 self.packing_process = [
41 self.mv_usr_libs, self.create_fs_dirs, self.fs_link,
42 self.fs_filemode, self.fs_make_cmd, self.fs_tear_down
44 self.fs_cfg = None
[all …]
/build/ohos/sa_profile/sa_info_process/
Dmerge_sa_info.py30 def __init__(self, process_name, wdir): argument
31 self.process_name = process_name
32 self.systemabilities = []
33 self.wdir = wdir
36 def output_filename(self): argument
37 basename = self.process_name + '.json'
38 return os.path.join(self.wdir, basename)
40 def add_systemability_info(self, systemability): argument
41 self.systemabilities += systemability
43 def merge_sa_info(self): argument
[all …]
Dsort_sa_by_bootphase.py36 def __init__(self): argument
37 self.bootphase_categories = {
45 def __init__(self): argument
46 self.rearranged_systemabilities = []
47 self.ordered_systemability_names = []
48 self.name_node_dict = {}
49 self.systemability_deps_dict = {}
50 self.bootphase_dict = {}
51 self.creation_dict = {}
52 self.policy = RearrangementPolicy()
[all …]
/build/hb/util/loader/
Dload_ohos_build.py110 def __init__(self, part_name, variant_name, part_config, toolchain, argument
112 self._origin_name = part_name
117 self._part_name = _real_name
118 self._variant_name = variant_name
119 self._subsystem_name = subsystem_name
120 self._feature_list = []
121 self._toolchain = toolchain
122 self._inner_kits_info = {}
123 self._kits = []
124 self._target_arch = target_arch
[all …]
/build/hb/test/unitTest/services/
Dpreloader_test.py26 def setUp(self): argument
27 self.preloader = OHOSPreloader(Config())
30 def tearDown(self): argument
33 def test_generate_build_prop(self): argument
36 def test_generate_build_config_json(self): argument
39 def test_generate_parts_json(self): argument
42 def test_generate_parts_config_json(self): argument
45 def test_generate_build_gnargs_prop(self): argument
48 def test_generate_features_json(self): argument
51 def test_generate_syscap_json(self): argument
[all …]
/build/tools/component_tools/static_check/gn_check/
Dcheck_gn.py41 def __init__(self, ohos_root: str, black_dir: tuple = tuple(), check_path='') -> None: argument
49 self.ohos_root = ohos_root
50 self.check_path = check_path
51 self.black_dir = black_dir
54 self.abs_check_path = self.ohos_root
56 self.abs_check_path = os.path.join(self.ohos_root, check_path)
57 self.all_gn_files = GnCommon.find_files(
58 self.abs_check_path, black_dirs=black_dir)
59 self.subsystem_info = get_subsystem_components_modified(ohos_root)
61 def get_all_gn_data(self) -> dict: argument
[all …]

123