diff --git a/lib/spack/spack/cmd/info.py b/lib/spack/spack/cmd/info.py index 9115ada39d..0940220ea2 100644 --- a/lib/spack/spack/cmd/info.py +++ b/lib/spack/spack/cmd/info.py @@ -1,5 +1,9 @@ +import re +import textwrap + import spack import spack.packages as packages +from spack.colify import colify description = "Build and install packages" @@ -9,5 +13,31 @@ def setup_parser(subparser): def info(parser, args): package = packages.get(args.name) + print "Package: ", package.name print "Homepage: ", package.homepage print "Download: ", package.url + + print + print "Dependencies:" + if package.dependencies: + colify(package.dependencies, indent=4) + else: + print " None" + + print + print "Virtual packages: " + if package.provided: + for spec, when in package.provided.items(): + print " %s provides %s" % (when, spec) + else: + print " None" + + print + print "Description:" + if package.__doc__: + doc = re.sub(r'\s+', ' ', package.__doc__) + lines = textwrap.wrap(doc, 72) + for line in lines: + print " " + line + else: + print " None" diff --git a/lib/spack/spack/packages/mpich.py b/lib/spack/spack/packages/mpich.py index c8e84901e6..865d6cb95e 100644 --- a/lib/spack/spack/packages/mpich.py +++ b/lib/spack/spack/packages/mpich.py @@ -1,6 +1,9 @@ from spack import * class Mpich(Package): + """MPICH is a high performance and widely portable implementation of + the Message Passing Interface (MPI) standard.""" + homepage = "http://www.mpich.org" url = "http://www.mpich.org/static/downloads/3.0.4/mpich-3.0.4.tar.gz" md5 = "9c5d5d4fe1e17dd12153f40bc5b6dbc0" @@ -8,6 +11,11 @@ class Mpich(Package): list_url = "http://www.mpich.org/static/downloads/" list_depth = 2 + versions = ['3.0.4', '3.0.3', '3.0.2', '3.0.1', '3.0'] + + provides('mpi@:3', when='@3:') + provides('mpi@:1', when='@1:') + def install(self, prefix): configure("--prefix=%s" % prefix) make()