summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Scogland <scogland1@llnl.gov>2016-05-14 18:06:22 -0700
committerTom Scogland <scogland1@llnl.gov>2016-05-14 18:06:42 -0700
commit0816e9554d108498cdb419d71f3bac1375622ad1 (patch)
treec907ebdce08e8cc6cfbf057efcbede1322d506c3
parent915f91a6199dfe77481742330194e0f6ee17fb8b (diff)
downloadspack-0816e9554d108498cdb419d71f3bac1375622ad1.tar.gz
spack-0816e9554d108498cdb419d71f3bac1375622ad1.tar.bz2
spack-0816e9554d108498cdb419d71f3bac1375622ad1.tar.xz
spack-0816e9554d108498cdb419d71f3bac1375622ad1.zip
adding go_compiler providers
-rw-r--r--var/spack/repos/builtin/packages/gcc/package.py3
-rw-r--r--var/spack/repos/builtin/packages/go/package.py6
2 files changed, 7 insertions, 2 deletions
diff --git a/var/spack/repos/builtin/packages/gcc/package.py b/var/spack/repos/builtin/packages/gcc/package.py
index 47dbeb2a99..f630b9b61a 100644
--- a/var/spack/repos/builtin/packages/gcc/package.py
+++ b/var/spack/repos/builtin/packages/gcc/package.py
@@ -62,6 +62,9 @@ class Gcc(Package):
depends_on("binutils~libiberty", when='+binutils ~gold')
depends_on("binutils~libiberty+gold", when='+binutils +gold')
+ if sys.platform != 'darwin':
+ provides('go_compiler' when='@4.7.1:')
+
# TODO: integrate these libraries.
#depends_on("ppl")
#depends_on("cloog")
diff --git a/var/spack/repos/builtin/packages/go/package.py b/var/spack/repos/builtin/packages/go/package.py
index 05fce90534..71b1b9c18f 100644
--- a/var/spack/repos/builtin/packages/go/package.py
+++ b/var/spack/repos/builtin/packages/go/package.py
@@ -12,12 +12,14 @@ class Go(Package):
version('1.4.2', git='https://go.googlesource.com/go', tag='go1.4.2')
version('1.5.0', git='https://go.googlesource.com/go', tag='go1.5.0')
+
+ provides('go_compiler')
# to-do, make non-c self-hosting compilers possible
- depends_on('go@:1.4.2', when='@1.5:')
+ # should be go_compiler, but that creates an infinite loop
+ depends_on('gcc', when='@1.5:')
def install(self, spec, prefix):
os.environ['GOROOT'] = os.getcwd()
- os.environ['GOBIN'] = join_path(os.getcwd(), 'bin')
os.environ['GOROOT_FINAL'] = prefix
bash = which('bash')
bash('-c', 'env')