/build/hb/resolver/ |
H A D | set_args_resolver.py | 25 from resources.config import Config 37 config = Config() 49 config.product = product_info.get('name') 50 config.product_path = product_info.get('product_path') 51 config.version = product_info.get('version') 52 config.os_level = product_info.get('os_level') 53 config.product_json = product_info.get('config') 54 config.component_type = product_info.get('component_type') 56 config [all...] |
H A D | build_args_resolver.py | 32 from resources.config import Config 66 config = Config() 68 target_generator.regist_arg('product_name', config.product) 69 target_generator.regist_arg('product_path', config.product_path) 71 'product_config_path', config.product_config_path) 73 target_generator.regist_arg('device_name', config.board) 74 target_generator.regist_arg('device_path', config.device_path) 75 target_generator.regist_arg('device_company', config.device_company) 77 'device_config_path', config.device_config_path) 79 target_generator.regist_arg('target_cpu', config [all...] |
H A D | clean_args_resolver.py | 26 from resources.config import Config 45 config = Config() 46 if config.out_path is not None and config.out_path != '' \ 47 and config.out_path.startswith(CURRENT_OHOS_ROOT) and os.path.exists(config.out_path): 49 'Clean {} directory that generated by last compilation'.format(config.out_path)) 50 shutil.rmtree(config.out_path)
|
/build/hb/util/preloader/ |
H A D | preloader_process_data.py | 19 from resources.config import Config 54 def __init__(self, config): 55 self.__post_init__(config) 57 def __post_init__(self, config): 58 self.source_root_dir = config.root_path 59 self.built_in_product_dir = config.built_in_product_path 65 self.vendor_dir = config.vendor_path 67 self.device_dir = os.path.join(config.root_path, 'device') 70 config.root_path, config [all...] |
H A D | parse_vendor_product_config.py | 108 def transform(config): 109 subsystems = config.get('subsystems') 111 config.pop('subsystems') 113 config['parts'] = parts 114 return config 117 def save_transformed_config(config, output_file): 118 new_config = json.dumps(config, indent=2, sort_keys=True) 130 config_json = os.path.join(product_path, 'config.json') 134 config = json.load(fin) 135 if product_name == config [all...] |
H A D | parse_lite_subsystems_config.py | 51 def _save_as_ohos_build(config, ohos_build): 52 new_config = json.dumps(config, indent=2, sort_keys=True)
|
/build/hb/util/prebuild/ |
H A D | patch_process.py | 18 from resources.config import Config 29 self.config = Config() 31 self.patch_cfg = os.path.join(self.config.product_path, 'patch.yml') 43 patch_cfg = self.config.patch_cache 71 src_path = os.path.join(self.config.root_path, src_path) 77 patch_path = os.path.join(self.config.root_path, patch_item) 79 patch_path = os.path.join(self.config.root_path, 89 SystemUtil.exec_command(cmd, log_path=self.config.log_path, 93 self.config.patch_cache = None 102 if self.config [all...] |
/build/hb/services/ |
H A D | ninja.py | 24 from resources.config import Config 34 self.config = Config() 45 '-C', self.config.out_path] + self._convert_args() 46 LogUtil.write_log(self.config.log_path, 52 self.config.root_path, 54 self.config.product, 63 self.config.log_path, 71 self.config.log_path, 74 log_mode=self.config.log_mode 97 ninja_path = os.path.join(self.config [all...] |
H A D | preloader.py | 67 config = { 74 platform_config = {'version': 2, 'platforms': {'phone': config}} 78 self._dirs.preloader_output_dir), mode=self.config.log_mode) 108 self._dirs.preloader_output_dir), mode=self.config.log_mode) 132 self._dirs.preloader_output_dir), mode=self.config.log_mode) 154 self._dirs.preloader_output_dir), mode=self.config.log_mode) 172 self._dirs.preloader_output_dir), mode=self.config.log_mode) 174 '''Description: generate build config info to "out/preloader/product_name/build_config.json" 183 'generated build config info to {}/build_config.json'.format( 184 self._dirs.preloader_output_dir), mode=self.config [all...] |
H A D | loader.py | 32 from resources.config import Config 63 self.source_root_dir = self.config.root_path + '/' 64 self.gn_root_out_dir = self.config.out_path if not self.config.out_path.startswith( 65 '/') else os.path.relpath(self.config.out_path, self.config.root_path) 66 self.os_level = self.config.os_level if self.config.os_level else "standard" 67 self.target_cpu = self.config.target_cpu if self.config [all...] |
H A D | gn.py | 29 from resources.config import Config 50 self.config = Config() 83 gn_path = os.path.join(self.config.root_path, 'prebuilts/build-tools/{}-x86/bin/gn' 100 self.config.out_path] + self._convert_flags() 101 if self.config.os_level == 'mini' or self.config.os_level == 'small': 103 LogUtil.write_log(self.config.log_path, 'Excuting gn command: {} {} --args="{}" {}'.format( 108 if self.config.log_mode == 'silent': 119 SystemUtil.exec_command(gn_gen_cmd, self.config.log_path, log_mode=self.config [all...] |
/build/hb/util/ |
H A D | product_util.py | 24 from resources.config import Config 34 config = Config() 36 _ext_scan_path = os.path.join(config.root_path, 46 config_path = os.path.join(p_config_path, 'config.json') 53 config.root_path, info.get('product_path')) 72 'config': config_path, 86 'config': config_path, 89 if config.vendor_path != '': 90 for company in os.listdir(config.vendor_path): 91 company_path = os.path.join(config [all...] |
H A D | device_util.py | 34 'config.gni' in os.listdir(kernel_path) 53 kernel_config = os.path.join(kernel_path, 'config.gni') 59 def match_kernel(config: str, kernel: str, version: str): 63 with open(config, 'rt', encoding='utf-8') as config_file: 70 def get_kernel_info(config: str): 74 with open(config, 'rt', encoding='utf-8') as config_file: 80 f'not found in {config}', '0005') 94 config = os.path.join(config_path, 'config.gni') 95 if not os.path.isfile(config) [all...] |
/build/ohos/packages/ |
H A D | fs_process.py | 26 from hb.resources.config import Config 34 self.config = Config() 36 r'${product_name}': self.config.product, 37 r'${root_path}': self.config.root_path, 38 r'${out_path}': self.config.out_path 79 src_path = self.config.out_path 90 fs_path = os.path.join(self.config.out_path, 105 self.config.out_path) 184 log_path = self.config.log_path 203 if attr_key in self.config [all...] |
/build/scripts/ |
H A D | build_js_assets.py | 38 parser.add_option('--webpack-config-js', help='path to webpack.config.js') 39 parser.add_option('--webpack-config-ets', help='path to webpack.rich.config.js') 86 def make_manifest_data(config: dict, options, js2abc: bool, asset_index: int, assets_cnt: int, src_path: str) -> dict: 88 data['appID'] = config['app']['bundleName'] 90 data['versionName'] = config['app']['versionName'] 91 data['versionCode'] = config['app']['versionCode'] 92 data['pages'] = config['module']['pages'] 93 data['deviceType'] = config['modul [all...] |
H A D | hapbuilder.py | 107 config_name = 'config.json' 113 config = {} 115 config = json.load(fileobj) 117 config.get('module')['virtualMachine'] = 'ark{}'.format( 120 config.get('module').get('distro')['virtualMachine'] = 'ark{}'.format( 122 build_utils.write_json(config, hap_profile)
|
/build/hb/util/loader/ |
H A D | subsystem_info.py | 21 from resources.config import Config 75 config = Config() 77 config.product_path, "subsystem_config_overlay.json")
|
/build/templates/common/ |
H A D | include_relative_path_check.py | 74 def analysis(cls, config: str, project_path: str, components_info: str, output_path: str): 75 if not os.path.exists(config): 76 print("error: {} is inaccessible or not found".format(config)) 84 components = cls.__get_components(config, project_path) 117 def __get_components(cls, config: str, project: str): 119 with open(config, 'r', encoding='utf-8') as r:
|
/build/build_scripts/ |
H A D | build.sh | 124 npm config set registry https://repo.huaweicloud.com/repository/npm/ 125 npm config set @ohos:registry https://repo.harmonyos.com/npm/ 126 npm config set strict-ssl false 127 npm config set lockfile false 144 ohpm config set registry https://repo.harmonyos.com/ohpm/ 145 ohpm config set strict_ssl false 146 ohpm config set log_level debug 183 ./build.py --product-name ohos-sdk $ccache_args $xcache_args --load-test-config=false --get-warning-list=false --stat-ccache=false --compute-overlap-rate=false --deps-guard=false --generate-ninja-trace=false --gn-args skip_generate_module_list_file=true sdk_platform=linux ndk_platform=linux use_cfi=false use_thin_lto=false enable_lto_O0=true sdk_check_flag=false enable_ndk_doxygen=false archive_ndk=false sdk_for_hap_build=true enable_archive_sdk=false enable_notice_collection=false enable_process_notice=false
|
/build/ |
H A D | prebuilts_download.py | 75 def _config_parse(config: dict, tool_repo: str, glibc_version: str) -> dict: 77 parse_dict['unzip_dir'] = config.get('unzip_dir') 78 file_path = config.get('file_path') 82 parse_dict['unzip_filename'] = config.get('unzip_filename') 166 def _hwcloud_download(args, config: dict, bin_dir: str, code_dir: str, glibc_version: str): 173 for config_info in config: 227 skip_ssl_cmd = '{} config set strict-ssl false;'.format(npm) 232 npm_package_lock_cmd = '{} config set package-lock true'.format(npm) 267 def _node_modules_copy(config: dict, code_dir: str, enable_symlink: bool): 268 for config_info in config [all...] |
/build/hb/services/interface/ |
H A D | load_interface.py | 20 from resources.config import Config 35 def config(self): member in LoadInterface
|
H A D | preload_interface.py | 20 from resources.config import Config 39 def config(self): member in PreloadInterface
|
/build/tools/component_tools/ |
H A D | parse_kconf.py | 173 --out=./product.json --deps={$repo}/out/{your_product}/part_deps_info/part_deps_info.json --config=./.config' 181 parser.add_argument('--config', type=str, default="./.config", 182 help='config file which is generated by kconfig operation, default is .config') 187 print("read kconfig file: ", os.path.abspath(args.config)) 190 generate_config_with_full_deps(args.deps, args.base_product, args.config, args.out)
|
/build/ohos/images/mkimage/ |
H A D | mkimages.py | 124 config = {} 126 config = json.load(f) 138 if config.get('component_type', '') == 'system_component':
|
/build/test/example/ |
H A D | test_gn_template.py | 33 config = parse_json().get("gn_template") variable 34 if not config: 35 log_error("config file: build_example.json error") 41 TEMPLATE_SOURCE_PATH = config.get("template_source_path") 42 RESULT_BUILT_FILE = config.get("result_build_file") 44 RESULT_OBJ_FILE = config.get("result_obj_file") 46 RUST_PATH = config.get("rust_path") 47 RESULT_RUST_FILE = config.get("result_rust_file") 49 EXCLUDE_LIST = config.get("exclude") 50 TEST_BUILD = config [all...] |