diff options
Diffstat (limited to 'manifest_xml.py')
| -rw-r--r-- | manifest_xml.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/manifest_xml.py b/manifest_xml.py index fa3e1034..a14cc526 100644 --- a/manifest_xml.py +++ b/manifest_xml.py | |||
| @@ -237,8 +237,13 @@ class _XmlSubmanifest: | |||
| 237 | if self.remote and not self.project: | 237 | if self.remote and not self.project: |
| 238 | raise ManifestParseError( | 238 | raise ManifestParseError( |
| 239 | f'Submanifest {name}: must specify project when remote is given.') | 239 | f'Submanifest {name}: must specify project when remote is given.') |
| 240 | # Construct the absolute path to the manifest file using the parent's | ||
| 241 | # method, so that we can correctly create our repo_client. | ||
| 242 | manifestFile = parent.SubmanifestInfoDir( | ||
| 243 | os.path.join(parent.path_prefix, self.relpath), | ||
| 244 | os.path.join('manifests', manifestName or 'default.xml')) | ||
| 240 | rc = self.repo_client = RepoClient( | 245 | rc = self.repo_client = RepoClient( |
| 241 | parent.repodir, manifestName, parent_groups=','.join(groups) or '', | 246 | parent.repodir, manifestFile, parent_groups=','.join(groups) or '', |
| 242 | submanifest_path=self.relpath, outer_client=outer_client) | 247 | submanifest_path=self.relpath, outer_client=outer_client) |
| 243 | 248 | ||
| 244 | self.present = os.path.exists(os.path.join(self.repo_client.subdir, | 249 | self.present = os.path.exists(os.path.join(self.repo_client.subdir, |
| @@ -337,6 +342,8 @@ class XmlManifest(object): | |||
| 337 | self.repodir = os.path.abspath(repodir) | 342 | self.repodir = os.path.abspath(repodir) |
| 338 | self._CheckLocalPath(submanifest_path) | 343 | self._CheckLocalPath(submanifest_path) |
| 339 | self.topdir = os.path.join(os.path.dirname(self.repodir), submanifest_path) | 344 | self.topdir = os.path.join(os.path.dirname(self.repodir), submanifest_path) |
| 345 | if manifest_file != os.path.abspath(manifest_file): | ||
| 346 | raise ManifestParseError('manifest_file must be abspath') | ||
| 340 | self.manifestFile = manifest_file | 347 | self.manifestFile = manifest_file |
| 341 | self.local_manifests = local_manifests | 348 | self.local_manifests = local_manifests |
| 342 | self._load_local_manifests = True | 349 | self._load_local_manifests = True |
