def _handle_idl_manager(self, manager):#For CommonBackend to call for idl in manager.idls.values(): idl_manifest, idl_reltarget = self._get_manifest_from_target('dist/idl') idl_manifest.add_symlink(idl['source'], mozpath.join(idl_reltarget, idl['basename'])) self._idl_set.add(idl['basename']) xpt_path = self._get_xpt_path_from_idl_module(manager, idl['module']) # These .h files are generated by xpt genearting procedure idl_header_manifest, idl_header_reltarget = self._get_manifest_from_target('dist/include') header_dest = mozpath.join(idl_header_reltarget, '%s.h' % idl['root']) idl_header_manifest.add_optional_exists(header_dest, [mozpath.join(self.environment.topobjdir, xpt_path)]) xpt_modules = sorted(manager.modules.keys()) for module in xpt_modules: install_target, sources = manager.modules[module] deps =[mozpath.join(self.environment.topobjdir, 'dist/idl', p + '.idl') for p in sorted(sources)] xpt_path = self._get_xpt_path_from_idl_module(manager, module) install_manifest, reltarget = self._get_manifest_from_target(xpt_path) install_manifest.add_optional_exists(reltarget) dep_file = mozpath.join(self.dep_path, xpt_path + '.pp') self._xpt_list.append((xpt_path, deps, dep_file)) interfaces_path = mozpath.join(self.environment.topobjdir, install_target, 'components', 'interfaces.manifest') jar.addEntryToListFile(interfaces_path, self._chrome_set) jar.addStringToListFile(interfaces_path, 'interfaces {0}'.format(module + '.xpt'), self._chrome_set)
def consume_finished(self): CommonBackend.consume_finished(self) for dist_dir in self._paths_components_files.keys(): chromeFile = mozpath.join(self.environment.topobjdir, dist_dir, 'chrome.manifest') for f in self._paths_components_files[dist_dir]: manifestName = mozpath.basename(f) if not manifestName.endswith('.manifest'): continue jar.addStringToListFile(chromeFile, 'manifest components/%s' % manifestName, self._chrome_set) chromeFile = mozpath.join(self.environment.topobjdir, 'dist/bin', 'chrome.manifest') jar.addStringToListFile(chromeFile, 'manifest shell/shell.manifest', self._chrome_set) sdk_path = self.environment.substs['LIBXUL_DIST'] build_manifest, build_target = self._get_manifest_from_target('build') build_manifest.add_symlink(mozpath.join(sdk_path, 'automation.py'), mozpath.join(build_target, 'automation.py')) build_manifest.add_optional_exists(mozpath.join(build_target, 'configStatus.py')) build_manifest.add_optional_exists(mozpath.join(build_target, 'configStatus.pyc')) dist_list = [ 'bin/mozglue.dll', 'sdk/bin/ply/__init__.py', 'sdk/bin/ply/lex.py', 'sdk/bin/ply/yacc.py', 'sdk/bin/header.py', 'sdk/bin/typelib.py', 'sdk/bin/xpidl.py', 'sdk/bin/xpidllex.py', 'sdk/bin/xpidlyacc.py', 'sdk/bin/xpt.py', ] dist_manifest, target = self._get_manifest_from_target('dist') for dist_item in dist_list: dist_manifest.add_symlink(mozpath.join(sdk_path, dist_item), mozpath.join(target, dist_item)) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/.purgecaches')) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/wpsmail.exe')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/wpsmail.pdb')) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/app.xpi')) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/helper.exe')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/helper.pdb')) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/WSEnable.exe')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/WSEnable.pdb')) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/mozMapi32.dll')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/mozMapi32.exp')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/mozMapi32.pdb')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/mozMapi32.lib')) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/bolt.dll')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/bolt.exp')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/bolt.pdb')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/bolt.lib')) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/shell.dll')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/shell.exp')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/shell.pdb')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/shell.lib')) dist_manifest.add_optional_exists(mozpath.join(target, 'bin/MapiProxy.dll')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/MapiProxy.exp')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/MapiProxy.pdb')) dist_manifest.add_optional_exists(mozpath.join(target, 'lib/MapiProxy.lib')) print(self.typeSet) #print(self.all_configs) #self.print_list(self._garbages) #self.print_list(self._python_unit_tests) #self.print_list(self.backend_input_files) # moz.build files #self.print_list(self._extra_pp_components) #self.print_list(self._js_preference_files) chrome_files = sorted([mozpath.relpath(p, self.environment.topobjdir) for p in self._chrome_set]) self._process_files(None, chrome_files, '', optional=True) # Make the master test manifest files. for flavor, t in self._test_manifests.items(): install_prefix, manifests = t manifest_stem = mozpath.join(install_prefix, '%s.ini' % flavor) self._write_master_test_manifest(mozpath.join( self.environment.topobjdir, '_tests', manifest_stem), manifests) # Catch duplicate inserts. try: self._install_manifests['tests'].add_optional_exists(manifest_stem) except ValueError: pass self._write_manifests('install', self._install_manifests) ensureParentDir(mozpath.join(self.environment.topobjdir, 'dist', 'foo')) savePickle(self.all_configs_path, self.all_configs) self.build()