I am attempting to compile a code that includes some Perl scripts. Config was successful. However, when building the software, I encountered the following error:
/opt/ebsofts/Perl/5.34.0-GCCcore-11.3.0/lib/perl5/5.34.0/x86_64-linux-thread-multi/CORE/perl.h:922:13: fatal error: xlocale.h: No such file or directory
922 | # include <xlocale.h>
| ^~~~~~~~~~~
compilation terminated.
I looked this up and it appears that the perl.h library linked above contains an include statement for xlocale.h, which doesn’t exist. Can you please tell me how to deal with this?
Note: other Perl versions installed on Yggdrasil also appear to contain this include statement to the non-existent xlocale.h.
Hi @Yann.Sagon . I sent a request to the HEASOFT helpdesk and got the following reply:
Hi Dominique, The CFITSIO Perl interface code includes “perl.h” which was found on your system in /opt/ebsofts/Perl/5.34.0-GCCcore-11.3.0/lib/perl5/5.34.0/x86_64-linux-thread-multi/CORE/, and it’s that system perl.h file that is trying to include xlocale.h.
So it sounds like there’s a problem in the Perl installation, i.e. that it includes a perl.h which tries to include a file that isn’t there. Does Rocky Linux use the Red Hat package manager ‘dnf’? I’ve tried to discern which dnf package might include xlocale.h but without success so far. My best guess is that it’s in the “perl-devel” package. If that doesn’t work, my best suggestion is to try to install and use a different version of Perl.
(yggdrasil)-[rossigng@login1 ~]$ module spider HEASoft
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
HEASoft: HEASoft/6.34
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Description:
HEASOFT is the HEASARC's software suite that currently encompasses both new and legacy mission-independent or multi-mission FTOOLS, the XANADU suite (XSPEC, XRONOS, and XIMAGE),
XSTAR, and numerous mission-specific packages.
You will need to load all module(s) on any one of the lines below before the "HEASoft/6.34" module is available to load.
GCC/13.3.0
Help:
Description
===========
HEASOFT is the HEASARC's software suite that currently encompasses both new and legacy mission-independent or multi-mission FTOOLS, the XANADU suite (XSPEC, XRONOS, and XIMAGE), XSTAR,
and numerous mission-specific packages.
More information
================
- Homepage: https://heasarc.gsfc.nasa.gov/lheasoft/
You can load with command :
(yggdrasil)-[rossigng@login1 ~]$ ml GCC/13.3.0 GCC/13.3.0
Could you please test if this version is working fine?
Hi @Gael.Rossignol . There are files missing in your HEASoft installation:
Failed to read continuum data from 3.0.9_coco.fits
Failed to read 3.0.9_coco.fits
I searched for this file (which is called apec_v3.0.9_coco.fits) and other similar files in the directory where HEASoft was installed and could not find them. These files are absolutely needed for a functional installation of HEASoft.