Support for Intel oneAPI2022
Hi James,
I have trying to compile some Fortran90 modules, which I have used in the past with the Intel Compilers 2018, with the new Intel oneAPI2022 compilers. Apparently the "-fscomp logicals" is no longer supported, and as it is required by the example Makefile you provide with the package, it continously fails during compilation time. Are you aware of ways to solve this? Have you tried yourself for compatibility issues with the new oneAPI2022 compilers?
Just so you can reproduce the problem, this is the Makefile I am using:
`COMMONS = /mnt/extraspace/currodri/Codes/ozymandias/ozy/fortran_commons
#=======================================================================
define the compiler names
#=======================================================================
CC = gcc #F90 = gfortran F90 = ifort #F90 = /opt/intel/composer_xe_2015.3.187/bin/intel64/ifort PYTHON = python
#=======================================================================
additional flags
#=======================================================================
ifeq ($(F90),gfortran) FPP = gfortran -E FPP_F90FLAGS = -x f95-cpp-input -fPIC F90FLAGS = -fPIC FCOMP = gfortran LIBS = endif
ifeq ($(F90),ifort)
FPP = gfortran -E # gfortran f90wrap temp files only. not compilation
FPP_F90FLAGS = -x f95-cpp-input -fPIC -I $(COMMONS)
F90FLAGS = -g -traceback -cpp -fpscomp logicals -fPIC -I $(COMMONS) # use 1 and 0 for True and False
FCOMP = intelem # for f2py
LIBS =
endif
CFLAGS = -fPIC # ==> universal for ifort, gfortran, pgi
#======================================================================= #=======================================================================
UNAME = $(shell uname)
ifeq (${UNAME}, Darwin) LIBTOOL = libtool -static -o else LIBTOOL = ar src endif
======================================================================
PROJECT CONFIG, do not put spaced behind the variables
======================================================================
Python module name
PYTHON_MODN = amr2
mapping between Fortran and C types
KIND_MAP = kind_map
#=======================================================================
#=======================================================================
VPATH = ${COMMONS}
#=======================================================================
List all source files required for the project
#=======================================================================
names (without suffix), f90 sources
LIBSRC_SOURCES = local linalg_module coordinates_module read_amr_module
profiles_module integrator_module export_module
file names
LIBSRC_FILES = $(addsuffix .f90,${LIBSRC_SOURCES})
object files
LIBSRC_OBJECTS = $(addsuffix .o,${LIBSRC_SOURCES})
only used when cleaning up
LIBSRC_FPP_FILES = $(addsuffix .fpp,${LIBSRC_SOURCES})
#=======================================================================
List all source files that require a Python interface
#=======================================================================
names (without suffix), f90 sources
LIBSRC_WRAP_SOURCES = linalg_module coordinates_module read_amr_module
profiles_module integrator_module export_module
file names
LIBSRC_WRAP_FILES = $(addsuffix .f90,${LIBSRC_WRAP_SOURCES})
object files
LIBSRC_WRAP_OBJECTS = $(addsuffix .o,${LIBSRC_WRAP_SOURCES})
fpp files
LIBSRC_WRAP_FPP_FILES = $(addsuffix .fpp,${LIBSRC_WRAP_SOURCES})
#=======================================================================
Relevant suffixes
#=======================================================================
.SUFFIXES: .f90 .fpp
#=======================================================================
#=======================================================================
.PHONY: all clean
all: _${PYTHON_MODN}.so _${PYTHON_MODN}_pkg.so
clean:
-rm -f ${LIBSRC_OBJECTS} ${LIBSRC_FPP_FILES} libsrc.a _${PYTHON_MODN}*.so
_${PYTHON_MODN}_pkg.so .mod .fpp f90wrap.f90 f90wrap.o .o ${PYTHON_MODN}.py
-rm -rf ${PYTHON_MODN}_pkg/
-rm -rf src./ .f2py_f2cmap .libs/ pycache/
.f90.o: ${F90} ${F90FLAGS} -c $< -o $@
.c.o: ${CC} ${CFLAGS} -c $< -o $@
.f90.fpp: ${FPP} ${FPP_F90FLAGS} $< -o $@
libsrc.a: ${LIBSRC_OBJECTS} ${LIBTOOL} $@ $?
_${PYTHON_MODN}.so: libsrc.a ${LIBSRC_FPP_FILES} f90wrap -m ${PYTHON_MODN} ${LIBSRC_WRAP_FPP_FILES} -k ${KIND_MAP} -v f2py-f90wrap --fcompiler=$(FCOMP) --build-dir . -c -m _${PYTHON_MODN} -L. -lsrc f90wrap*.f90
_${PYTHON_MODN}_pkg.so: libsrc.a ${LIBSRC_FPP_FILES} f90wrap -m ${PYTHON_MODN}_pkg ${LIBSRC_WRAP_FPP_FILES} -k ${KIND_MAP} -v -P f2py-f90wrap --fcompiler=$(FCOMP) --build-dir . -c -m _${PYTHON_MODN}_pkg -L. -lsrc f90wrap*.f90
`
Thank you for your time!
Curro