mumps: Add '-DMAIN_COMP' when using Fujitsu compiler. (#13480)

This commit is contained in:
t-karatsu 2019-10-30 03:32:36 +09:00 committed by Adam J. Stewart
parent 944ef2f690
commit e29a6c532c

View File

@ -119,6 +119,7 @@ def write_makefile_inc(self):
using_pgi = self.compiler.name == "pgi" using_pgi = self.compiler.name == "pgi"
using_intel = self.compiler.name == "intel" using_intel = self.compiler.name == "intel"
using_xl = self.compiler.name in ['xl', 'xl_r'] using_xl = self.compiler.name in ['xl', 'xl_r']
using_fj = self.compiler.name == "fj"
# The llvm compiler suite does not contain a Fortran compiler by # The llvm compiler suite does not contain a Fortran compiler by
# default. Its possible that a Spack user may have configured # default. Its possible that a Spack user may have configured
@ -183,10 +184,11 @@ def write_makefile_inc(self):
# TODO: change the value to the correct one according to the # TODO: change the value to the correct one according to the
# compiler possible values are -DAdd_, -DAdd__ and/or -DUPPER # compiler possible values are -DAdd_, -DAdd__ and/or -DUPPER
if using_intel or using_pgi: if using_intel or using_pgi or using_fj:
# Intel & PGI Fortran compiler provides the main() function so # Intel, PGI, and Fujitsu Fortran compiler provides
# C examples linked with the Fortran compiler require a # the main() function so C examples linked with the Fortran
# hack defined by _DMAIN_COMP (see examples/c_example.c) # compiler require a hack defined by _DMAIN_COMP
# (see examples/c_example.c)
makefile_conf.append("CDEFS = -DAdd_ -DMAIN_COMP") makefile_conf.append("CDEFS = -DAdd_ -DMAIN_COMP")
else: else:
if not using_xlf: if not using_xlf: