summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Junghans <junghans@lanl.gov>2020-01-31 12:35:20 -0700
committerGitHub <noreply@github.com>2020-01-31 13:35:20 -0600
commit47ee690076508edc48740bac16b529a06d0be1a0 (patch)
tree980f91467d6a0b8f704d8857cb37b49fb64706e8
parent09e318fc84de2abbc39c6b40aa325d34964bf9eb (diff)
downloadspack-47ee690076508edc48740bac16b529a06d0be1a0.tar.gz
spack-47ee690076508edc48740bac16b529a06d0be1a0.tar.bz2
spack-47ee690076508edc48740bac16b529a06d0be1a0.tar.xz
spack-47ee690076508edc48740bac16b529a06d0be1a0.zip
portage: fix compile on icc (#14707)
-rw-r--r--var/spack/repos/builtin/packages/portage/p_intel_ice.patch24
-rw-r--r--var/spack/repos/builtin/packages/portage/package.py3
2 files changed, 27 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/portage/p_intel_ice.patch b/var/spack/repos/builtin/packages/portage/p_intel_ice.patch
new file mode 100644
index 0000000000..98832ea8b7
--- /dev/null
+++ b/var/spack/repos/builtin/packages/portage/p_intel_ice.patch
@@ -0,0 +1,24 @@
+--- portage.orig/portage/search/pairs.cc 2018-07-16 13:42:12.000000000 -0600
++++ portage/portage/search/pairs.cc 2020-01-09 15:32:43.289085000 -0700
+@@ -323,8 +323,8 @@
+ // check for completely outside source boxes
+ bool outside = false;
+ for (size_t m=0;m<dim;m++) {
+- if (y[m][j]<=cminmax[0][m]) outside=true;
+- if (y[m][j]>=cminmax[1][m]) outside=true;
++ if (y[m][j]<=cminmax[0][m]) { outside=true; break; }
++ if (y[m][j]>=cminmax[1][m]) { outside=true; break; }
+ }
+ if (outside) return pairlist;
+
+@@ -347,8 +347,8 @@
+ // check that y is contained
+ bool inside = true;
+ for(size_t m=0; m<dim; m++) {
+- if (y[m][j] <= xll[m]) inside = false;
+- if (y[m][j] >= xur[m]) inside = false;
++ if (y[m][j] <= xll[m]) { inside = false; break; }
++ if (y[m][j] >= xur[m]) { inside = false; break; }
+ }
+
+ // add pair: put x's in this y-cell onto neighbor list, if inside
diff --git a/var/spack/repos/builtin/packages/portage/package.py b/var/spack/repos/builtin/packages/portage/package.py
index 075c3b0742..097ec9aab1 100644
--- a/var/spack/repos/builtin/packages/portage/package.py
+++ b/var/spack/repos/builtin/packages/portage/package.py
@@ -31,6 +31,9 @@ class Portage(CMakePackage):
# fixed in version above 1.2.2
patch('rel-with-deb-info.patch', when='@1.2.2')
+ # intel/19.0.4 got an ICE (internal compiler error) compiling pairs.cc
+ patch('p_intel_ice.patch', when='@1.2.2')
+
variant('mpi', default=True, description='Support MPI')
depends_on("cmake@3.1:", type='build')