powerpc: Fix build errors with xlf

This patch fixes errors when using xlf as fortran compiler on Linux.
Tested with gcc/xlf and clang/xlf compiler combinations.
This commit is contained in:
Rajalakshmi Srinivasaraghavan 2023-09-29 10:32:34 -05:00
parent e2ca22f8d8
commit a11e1e10f4
3 changed files with 8 additions and 1 deletions

View File

@ -70,8 +70,12 @@ else
FCOMMON_OPT += -O1 -frecursive -mcpu=power8 -mtune=power8 -fno-fast-math
endif
else
ifeq ($(F_COMPILER), IBM)
FCOMMON_OPT += -O2 -qrecur -qnosave
else
FCOMMON_OPT += -O2 -frecursive -mcpu=power8 -mtune=power8 -fno-fast-math
endif
endif
else
FCOMMON_OPT += -O2 -Mrecursive
endif

View File

@ -1168,7 +1168,7 @@ endif
ifeq ($(F_COMPILER), IBM)
CCOMMON_OPT += -DF_INTERFACE_IBM
FEXTRALIB += -lxlf90
ifeq ($(C_COMPILER), GCC)
ifeq ($(C_COMPILER), $(filter $(C_COMPILER),GCC CLANG))
FCOMMON_OPT += -qextname
endif
# FCOMMON_OPT += -qarch=440

View File

@ -117,6 +117,9 @@ else
vendor=PGI
openmp='-mp'
;;
*xlf*)
vendor=IBM
;;
*)
vendor=G77
openmp=''