Page 1 of 2

Compilation error of 5.2.x related to libxc

Posted: Tue May 07, 2024 5:05 pm
by Franz Fischer
Hi all,

I am experiencing quite some weird behaviour when compiling yambo.
I had a yambo version 5.2.0 working for quite some time on my universities hpc facility and I compiled it myself some time ago.
Now that we had a hardware issue that deleted all user related software packages I wanted to recompile yambo with the exact same configure options as last time, namely:

Code: Select all

./configure CC=mpiicc FC=mpiifort --enable-mpi --enable-hdf5-p2y-support
make core
My compilation fails at the libxc step spitting out these lines:

Code: Select all

\t[libxc-5.2.3] download

gzip: stdin: not in gzip format
tar: This does not look like a tar archive
tar: Exiting with failure status due to previous errors
gtar: This does not look like a tar archive
gtar: Exiting with failure status due to previous errors
WARNING: I can't seem to be able to run `tar' with the given arguments.
         You may want to install GNU tar or Free paxutils, or check the
         command line arguments.
\t[libxc-5.2.3] installation
/bin/sh: line 0: cd: libxc-5.2.3: No such file or directory
The compilation finally fails when trying to include the libxc library:

Code: Select all

make[2]: *** [mod_xc_functionals.o] Error 1
mod_xc_functionals.f90(29): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
mod_xc_functionals.f90(180): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
\t[driver] yambo (setup)
yambo linking failed. Check log/compile_yambo.log
mod_xc_functionals.f90(29): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
mod_xc_functionals.f90(180): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
make[1]: *** [yambo] Error 1
yambo build failed
I would be really happy if you could tell me what I can try to fix that. I will also attach the configure.log and the compile_yambo.log.

Thanks in advance.

Best,
Franz

Re: Compilation error of 5.2.x related to libxc

Posted: Thu May 09, 2024 10:16 am
by Nicola Spallanzani
Dear Franz,
unfortunately, the issue is related to changes in the repository of the libxc libraries. Currently, it can be solved by the patch I'm sending you. I recommend downloading the YAMBO sources from GitHub and then applying the patch using git:

Code: Select all

git clone https://github.com/yambo-code/yambo.git
cd yambo
git checkout 5.2.3
git apply libxc.patch.txt
As soon as possible, we will create a new release including the patch.

Best,
Nicola

Re: Compilation error of 5.2.x related to libxc

Posted: Fri May 10, 2024 11:48 am
by Franz Fischer
Hi Nicola,

I tried what you suggested, but I am still experiencing some issues.

The installation step of libxc library still seems to fail, I am getting this in the make step:

Code: Select all

\t[libxc-5.2.3] download
\t[libxc-5.2.3] autoreconf
\t[libxc-5.2.3] configuration
\t[libxc-5.2.3]  compilation
\t[libxc-5.2.3] installation
chmod: cannot access ‘/usw/bbb2414/codes/yambo/lib/external/intel/mpiifort/lib*/*xc*a’: No such file or directory
Maybe just a typo in the chmod command?

and then the compilation breaks at this:

Code: Select all

make[2]: *** [mod_xc_functionals.o] Error 1
mod_xc_functionals.f90(13): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
mod_xc_functionals.f90(164): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
\t[driver] yambo (setup)
yambo linking failed. Check log/compile_yambo.log
mod_xc_functionals.f90(13): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
mod_xc_functionals.f90(164): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
make[1]: *** [yambo] Error 1
yambo build failed
Any further help would be nice!
Thanks again.

Best,
Franz

Re: Compilation error of 5.2.x related to libxc

Posted: Fri May 10, 2024 1:00 pm
by Daniele Varsano
Dear Franz,

it could be useful to have a look to:
./log/compile_libxc-5.2.3.log

to check what went wrong with the libxc installation.

Best,
Daniele

Re: Compilation error of 5.2.x related to libxc

Posted: Fri May 10, 2024 2:08 pm
by Franz Fischer
Hi Daniele,

see all the libxc related logs attached.

Best,
Franz

Re: Compilation error of 5.2.x related to libxc

Posted: Mon May 13, 2024 8:31 am
by Daniele Varsano
Dear Franz,

it seems that libxc are correctly downloaded, but then the configure file to install them is not present. I do not know why this is happening.
Can you try to do a
>make distclean
and try again?

Best,
Daniele

Re: Compilation error of 5.2.x related to libxc

Posted: Mon May 13, 2024 4:46 pm
by Franz Fischer
Hi Daniele,

I experience the same issues after doing:

Code: Select all

make distclean
During compilation I see these lines again:

Code: Select all

\t[libxc-5.2.3] download
\t[libxc-5.2.3] autoreconf
\t[libxc-5.2.3] configuration
\t[libxc-5.2.3]  compilation
\t[libxc-5.2.3] installation
chmod: cannot access ‘/usw/bbb2414/codes/yambo/lib/external/intel/mpiifort/lib*/*xc*a’: No such file or directory
and then the build fails:

Code: Select all

make[2]: *** [mod_xc_functionals.o] Error 1
mod_xc_functionals.f90(13): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
mod_xc_functionals.f90(164): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
\t[driver] yambo (setup)
yambo linking failed. Check log/compile_yambo.log
mod_xc_functionals.f90(13): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
mod_xc_functionals.f90(164): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [XC_F03_LIB_M]
make[1]: *** [yambo] Error 1
yambo build failed
When inspecting the

Code: Select all

~/log/autoreconf_libxc-5.2.3.log
it says:

Code: Select all

/bin/sh: autoreconf: command not found
Also, the configure script does not seem to be in the libxc directory:

Code: Select all

/usw/bbb2414/codes/yambo/lib/libxc/libxc-5.2.3
Is there anything else I could try?

Best,
Franz

Re: Compilation error of 5.2.x related to libxc

Posted: Mon May 13, 2024 5:29 pm
by Franz Fischer
Hi all,

I actually found the error when trying to compile libxc on my own.

The issue was that I had to load some modules on my hpc, namely:

Code: Select all

module load autoconf/2.69
module load automake/1.16.1
module load libtool/2.4.6
in order to generate the ./configure.sh file needed to configure libxc.

After that everything worked like a charm and I compiled yambo 5.2.3 using:

Code: Select all

git clone https://github.com/yambo-code/yambo.git
cd yambo
git checkout 5.2.3
git apply libxc.patch.txt

./configure CC=mpiicc FC=mpiifort --enable-mpi --enable-hdf5-p2y-support

make core

For completeness, I also tried to compile yambo without

Code: Select all

git apply libxc.patch.txt
, but this was still raising the error from the beginning of this post.

Thank you all for your help.

Best,
Franz

Re: Compilation error of 5.2.x related to libxc

Posted: Tue May 14, 2024 8:06 am
by Daniele Varsano
Dear Franz,

the patch is needed to download the libxc as they recently changed the repository address.
From what you say, it could be enough to install the autoconf package in your machine:

Code: Select all

sudo apt-get install autoconf
and then try again to compile. Hopefully this should solve the problem.

Best,
Daniele

Re: Compilation error of 5.2.x related to libxc

Posted: Tue May 14, 2024 1:02 pm
by AzulineSky
Hello,

I still have the same error as Franz.

\t[libxc-5.2.3] installation
chmod: cannot access ‘/home/magr4985/Apps/yambo/lib/external/intel/mpiifort/lib*/*xc*a’: No such file or directory

The config_libxc-5.2.3.log shows the following message:

checking for a BSD-compatible install... /bin/install -c
checking whether build environment is sane... configure: error: newly created file is older than distributed files!
Check your system clock

What can I do when this happens?

Thanks for your help!

Best regards,
Max