diff options
author | Adam J. Stewart <ajstewart426@gmail.com> | 2017-02-16 13:21:24 -0600 |
---|---|---|
committer | Todd Gamblin <tgamblin@llnl.gov> | 2018-07-25 23:10:10 -0700 |
commit | 5792a805fc0a3867df30f14234e62a983cb0d395 (patch) | |
tree | 074672e317ce1405004193835cb07cfc4548deef /lib | |
parent | f59666587bf0eb853fc1b47576a71d3f4c20ec3c (diff) | |
download | spack-5792a805fc0a3867df30f14234e62a983cb0d395.tar.gz spack-5792a805fc0a3867df30f14234e62a983cb0d395.tar.bz2 spack-5792a805fc0a3867df30f14234e62a983cb0d395.tar.xz spack-5792a805fc0a3867df30f14234e62a983cb0d395.zip |
core: quick fix for packages without URLs
Some packages do not have a `url` and are instead downloaded via `git`,
`hg`, or `svn`. Some packages like `spectrum-mpi` cannot be downloaded at
all, and are placeholder packages for system installations. Previously,
`__init__()` in `PackageBase` crashed if a package did not have a `url`
attribute defined.
I hacked this section of code out, but I have no idea what the
repercussions of that are.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/spack/spack/package.py | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/lib/spack/spack/package.py b/lib/spack/spack/package.py index 3b4c5fa394..8d6b2b99f5 100644 --- a/lib/spack/spack/package.py +++ b/lib/spack/spack/package.py @@ -494,17 +494,6 @@ class PackageBase(with_metaclass(PackageMeta, PackageViewMixin, object)): self._fetcher = None self.url = getattr(self.__class__, 'url', None) - # Fix up self.url if this package fetches with a URLFetchStrategy. - # This makes self.url behave sanely. - if self.spec.versions.concrete: - # TODO: this is a really roundabout way of determining the type - # TODO: of fetch to do. figure out a more sane fetch - # TODO: strategy/package init order (right now it's conflated with - # TODO: stage, package, and the tests make assumptions) - f = fs.for_package_version(self, self.version) - if isinstance(f, fs.URLFetchStrategy): - self.url = self.url_for_version(self.spec.version) - # Set a default list URL (place to find available versions) if not hasattr(self, 'list_url'): self.list_url = None |