summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorOlivier Cessenat <cessenat@gmail.com>2021-02-22 10:17:46 +0100
committerGitHub <noreply@github.com>2021-02-22 09:17:46 +0000
commit830ee07874905033d1707046ff2eff8c451b335c (patch)
treea05fbe04db0b304367353346b0ec13eae2bb887a /var
parent7c65f03db7614ddba33141206fb940383e3ec638 (diff)
downloadspack-830ee07874905033d1707046ff2eff8c451b335c.tar.gz
spack-830ee07874905033d1707046ff2eff8c451b335c.tar.bz2
spack-830ee07874905033d1707046ff2eff8c451b335c.tar.xz
spack-830ee07874905033d1707046ff2eff8c451b335c.zip
qrupdate: use the requested compiler from Spack (#21841)
qrupdate did hard set FC=gfortran Parallel compilation is now allowed calling $(MAKE) instead of make for subprocess see: https://stackoverflow.com/questions/24818095/warning-forced-in-submake-in-parallel-execution-of-make The build phase is split since the process always requires a target.
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/qrupdate/package.py22
1 files changed, 19 insertions, 3 deletions
diff --git a/var/spack/repos/builtin/packages/qrupdate/package.py b/var/spack/repos/builtin/packages/qrupdate/package.py
index 0d229a2585..cea9590dfb 100644
--- a/var/spack/repos/builtin/packages/qrupdate/package.py
+++ b/var/spack/repos/builtin/packages/qrupdate/package.py
@@ -23,12 +23,22 @@ class Qrupdate(MakefilePackage, SourceforgePackage):
def edit(self, spec, prefix):
# BSD "install" does not understand GNU -D flag.
# We will create the parent directory ourselves.
- makefile = FileFilter('src/Makefile')
if (sys.platform == 'darwin'):
+ makefile = FileFilter('src/Makefile')
makefile.filter('-D', '')
+
+ # Concurrent (parallel) Compilation requires calling $(MAKE) not make
+ makefile = FileFilter('Makefile')
+ makefile.filter('make', '$(MAKE)')
+
+ # We may like to compile with any Forran compiler, not always gfortran
+ makefile = FileFilter('Makeconf')
+ makefile.filter('FC=gfortran', 'FC ?= gfortran')
+
return
- def install(self, spec, prefix):
+ # The Makefile does not take the simple "make" rule
+ def build(self, spec, prefix):
lapack_blas = spec['lapack'].libs + spec['blas'].libs
@@ -41,11 +51,17 @@ class Qrupdate(MakefilePackage, SourceforgePackage):
if (spec.satisfies('^openblas+ilp64') or
spec.satisfies('^intel-mkl+ilp64') or
spec.satisfies('^intel-parallel-studio+mkl+ilp64')):
- make_args.append('FFLAGS=-fdefault-integer-8')
+ if (spec.satisfies('%intel') or spec.satisfies('%oneapi')
+ or spec.satisfies('%nvhpc')):
+ # 64bits integer for ifort and nvfortran are promoted by:
+ make_args.append('FFLAGS=-i8')
+ else:
+ make_args.append('FFLAGS=-fdefault-integer-8')
# Build static and dynamic libraries:
make('lib', 'solib', *make_args)
+ def install(self, spec, prefix):
# "INSTALL" confuses "make install" on case-insensitive filesystems:
if os.path.isfile("INSTALL"):
os.remove("INSTALL")