This thread is locked.Only browsing is available.
Top Page > Browsing
Installation openmx3.9 error: with Ubuntu 22 + ifort 2020
Date: 2022/11/08 04:31
Name: Shahram   <yalameha93@gmail.com>

Dear developers,

I am trying to install OpenMX3.9 + patch3.9.9 using Intel parallel studio 2020.
I have used the following setting in Makefile:
----------------------------------------------------------------------------------
MKLROOT = /opt/intel/compilers_and_libraries_2020.2.254/linux/mkl/
FFTW = -I/opt/intel/compilers_and_libraries_2020.2.254/linux/mkl/include/fftw
CC = mpiicc -qopenmp -O3 -ip $(FFTW)
FC = mpiifort -qopenmp -O3 -ip $(FFTW)
LIB= -L${MKLROOT}/lib/intel64 -mkl=parallel -lmkl_scalapack_lp64 -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -lmkl_blacs_intelmpi_lp64 -lgfortran -lmpi -liomp5 -lpthread -lm -ldl -lifcore
----------------------------------------------------------------------------------
then run "make all".
However, I got the following error:
==================================================================================
mpiicc -qopenmp -O3 -ip -I/opt/intel/compilers_and_libraries_2020.2.254/linux/mkl/include/fftw -I./elpa-2018.05.001 -c openmx.c
In file included from openmx.c(57):
/usr/include/stdio.h(189): error: attribute "__malloc__" does not take arguments
__attribute_malloc__ __attr_dealloc_fclose __wur;
^

In file included from openmx.c(57):
/usr/include/stdio.h(223): error: attribute "__malloc__" does not take arguments
__THROW __attribute_malloc__ __wur __attr_dealloc_free;
^

In file included from openmx.c(57):
/usr/include/stdio.h(260): error: attribute "__malloc__" does not take arguments
__attribute_malloc__ __attr_dealloc_fclose __wur;
^

In file included from openmx.c(57):
/usr/include/stdio.h(294): error: attribute "__malloc__" does not take arguments
__attribute_malloc__ __attr_dealloc_fclose __wur;
^

In file included from openmx.c(57):
/usr/include/stdio.h(309): error: attribute "__malloc__" does not take arguments
__THROW __attribute_malloc__ __attr_dealloc_fclose __wur;
^

In file included from openmx.c(57):
/usr/include/stdio.h(315): error: attribute "__malloc__" does not take arguments
__attribute_malloc__ __attr_dealloc_fclose __wur;
^

In file included from openmx.c(57):
/usr/include/stdio.h(830): error: attribute "__malloc__" does not take arguments
__attribute_malloc__ __attr_dealloc (pclose, 1) __wur;
^

In file included from openmx.c(58):
/usr/include/stdlib.h(566): error: attribute "__malloc__" does not take arguments
__attr_dealloc_free;
^

In file included from openmx.c(58):
/usr/include/stdlib.h(570): error: attribute "__malloc__" does not take arguments
__THROW __attr_dealloc (reallocarray, 1);
^

compilation aborted for openmx.c (code 2)
make: *** [makefile:222: openmx.o] Error 2
==================================================================================

I have also included the following settings in the .bashrc file in my system:
##########################################################
source /opt/intel/bin/compilervars.sh intel64
source /opt/intel/bin/ifortvars.sh intel64
export PATH=$PATH:/opt/intel/vtune_amplifier_2019/
export MKLROOT=/opt/intel/compilers_and_libraries_2020.2.254/linux/mkl/
export LD_LIBRARY_PATH=/opt/intel/mkl/lib/intel64:$LD_LIBRARY_PATH
export MKL_INTERFACE_LAYER=ILP64

##########################################################

Thank you for helping me to fix this error.

Regards
shahram
メンテ
Page: [1]

Re: Installation openmx3.9 error: with Ubuntu 22 + ifort 2020 ( No.1 )
Date: 2022/11/08 16:45
Name: Naoya Yamaguchi

Hi,

Can you show output for the following command?
$ mpiicc -v

Regards,
Naoya Yamaguchi
メンテ
Re: Installation openmx3.9 error: with Ubuntu 22 + ifort 2020 ( No.2 )
Date: 2022/11/09 00:05
Name: Shahram   <yalameha93@gmail.com>

Hi, Naoya,

Thank you for your response.

The output of this command is as follows:
=================================================================
$ mpiicc -v
mpiicc for the Intel(R) MPI Library 2019 Update 8 for Linux*
Copyright 2003-2020, Intel Corporation.
icc version 19.1.2.254 (gcc version 11.3.0 compatibility)
=================================================================

Regards,
Shahram
メンテ
Re: Installation openmx3.9 error: with Ubuntu 22 + ifort 2020 ( No.3 )
Date: 2022/11/09 16:55
Name: Naoya Yamaguchi

Dear Shahram,

Your issue is the same as reported in https://stackoverflow.com/questions/69404834/intel-compiler-fails-c14-check-with-attribute-malloc-does-not-take-argu .
I think that a simple workaround is to rebuild the Intel compilers with an older version of `gcc`.

Regards,
Naoya Yamaguchi
メンテ
Re: Installation openmx3.9 error: with Ubuntu 22 + ifort 2020 ( No.4 )
Date: 2022/11/10 03:04
Name: Shahram   <yalameha93@gmail.com>

Dear Naoya,

Thanks for your tips. I will try to fix it.

Kind regards,
Shahram.
メンテ

Page: [1]