summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorDenis Davydov <davydden@gmail.com>2016-08-23 22:24:16 +0200
committerDenis Davydov <davydden@gmail.com>2016-08-23 22:24:16 +0200
commitdae219d5c3b08e50f04c14508638a3ba30f3b615 (patch)
tree338c97ba746a02f52b2bd890b0aa2b4a513f3c47 /var
parent459b6eae1105aaeefa2f86f925caa8ccb3fcdc16 (diff)
downloadspack-dae219d5c3b08e50f04c14508638a3ba30f3b615.tar.gz
spack-dae219d5c3b08e50f04c14508638a3ba30f3b615.tar.bz2
spack-dae219d5c3b08e50f04c14508638a3ba30f3b615.tar.xz
spack-dae219d5c3b08e50f04c14508638a3ba30f3b615.zip
nwchem: add another patch
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/nwchem/Gcc6_macs_optfix.patch40
-rw-r--r--var/spack/repos/builtin/packages/nwchem/package.py1
2 files changed, 41 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/nwchem/Gcc6_macs_optfix.patch b/var/spack/repos/builtin/packages/nwchem/Gcc6_macs_optfix.patch
new file mode 100644
index 0000000000..6d903923b5
--- /dev/null
+++ b/var/spack/repos/builtin/packages/nwchem/Gcc6_macs_optfix.patch
@@ -0,0 +1,40 @@
+Index: src/config/makefile.h
+===================================================================
+--- src/config/makefile.h (revision 28470)
++++ src/config/makefile.h (revision 28471)
+@@ -910,6 +910,7 @@
+ GNUMINOR=$(shell $(FC) -dM -E - < /dev/null 2> /dev/null | egrep __VERS | cut -c24)
+ GNU_GE_4_6 = $(shell [ $(GNUMAJOR) -gt 4 -o \( $(GNUMAJOR) -eq 4 -a $(GNUMINOR) -ge 6 \) ] && echo true)
+ GNU_GE_4_8 = $(shell [ $(GNUMAJOR) -gt 4 -o \( $(GNUMAJOR) -eq 4 -a $(GNUMINOR) -ge 8 \) ] && echo true)
++ GNU_GE_6 = $(shell [ $(GNUMAJOR) -ge 6 ] && echo true)
+ endif
+ ifeq ($(GNU_GE_4_6),true)
+ DEFINES += -DGCC46
+@@ -921,6 +922,9 @@
+
+ FOPTIONS += -Warray-bounds
+ endif
++ ifeq ($(GNU_GE_6),true)
++ FOPTIMIZE += -fno-tree-dominator-opts # solvation/hnd_cosmo_lib breaks
++ endif
+ ifdef USE_OPENMP
+ FOPTIONS += -fopenmp
+ LDOPTIONS += -fopenmp
+@@ -1067,6 +1071,7 @@
+ GNUMINOR=$(shell $(FC) -dM -E - < /dev/null 2> /dev/null | egrep __VERS | cut -c24)
+ GNU_GE_4_6 = $(shell [ $(GNUMAJOR) -gt 4 -o \( $(GNUMAJOR) -eq 4 -a $(GNUMINOR) -ge 6 \) ] && echo true)
+ GNU_GE_4_8 = $(shell [ $(GNUMAJOR) -gt 4 -o \( $(GNUMAJOR) -eq 4 -a $(GNUMINOR) -ge 8 \) ] && echo true)
++ GNU_GE_6 = $(shell [ $(GNUMAJOR) -ge 6 ] && echo true)
+ ifeq ($(GNU_GE_4_6),true)
+ DEFINES += -DGCC46
+ endif
+@@ -1076,6 +1081,9 @@
+ #gone FFLAGS_FORGA += -fno-aggressive-loop-optimizations
+ FOPTIONS += -Warray-bounds
+ endif # GNU_GE_4_8
++ ifeq ($(GNU_GE_6),true)
++ FOPTIMIZE += -fno-tree-dominator-opts # solvation/hnd_cosmo_lib breaks
++ endif
+ endif # GNUMAJOR
+
+ ifdef USE_OPENMP
diff --git a/var/spack/repos/builtin/packages/nwchem/package.py b/var/spack/repos/builtin/packages/nwchem/package.py
index 06816429f5..43619c143a 100644
--- a/var/spack/repos/builtin/packages/nwchem/package.py
+++ b/var/spack/repos/builtin/packages/nwchem/package.py
@@ -62,6 +62,7 @@ class Nwchem(Package):
patch('Util_getppn.patch', when='@6.6', level=0)
patch('xccvs98.patch', when='@6.6', level=0)
patch('zgesdv.patch', when='@6.6', level=0)
+ patch('Gcc6_macs_optfix.patch', when='@6.6', level=0)
def install(self, spec, prefix):
# see http://www.nwchem-sw.org/index.php/Compiling_NWChem