unable to make fatal error: xlocale.h: No such file or directory
Followed instructions for "Ubuntu 14.04 LTS Build Guide" from https://meta-toolkit.org/setup-guide.html#ubuntu-build-guide
Ubuntu 17.10 g++ (Ubuntu 7.2.0-8ubuntu3) 7.2.0 cmake version 3.9.1
meta/build/deps/icu-58.2/src/ExternalICU/source/i18n/digitlst.cpp:67:13: fatal error: xlocale.h: No such file or directory
# include <xlocale.h>
^~~~~~~~~~~
compilation terminated.
c++ ... /meta/build/deps/icu-58.2/src/ExternalICU/source/i18n/fmtable_cnv.cpp
*** Failed compilation command follows: ----------------------------------------------------------
/usr/bin/c++ -ffunction-sections -fdata-sections -D_REENTRANT -DU_HAVE_ELF_H=1 -DU_ENABLE_DYLOAD=0 -DU_HAVE_ATOMIC=1 -DU_HAVE_STRTOD_L=1 -I/meta/build/deps/icu-58.2/src/ExternalICU/source/i18n -I/meta/build/deps/icu-58.2/src/ExternalICU/source/common -DU_ATTRIBUTE_DEPRECATED= -DU_I18N_IMPLEMENTATION -fPIC -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long --std=c++0x -c -o digitlst.ao /meta/build/deps/icu-58.2/src/ExternalICU/source/i18n/digitlst.cpp
--- ( rebuild with "make VERBOSE=1 all" to show all parameters ) --------
/meta/build/deps/icu-58.2/src/ExternalICU/source/config/mh-linux:49: recipe for target 'digitlst.ao' failed
make[4]: *** [digitlst.ao] Error 1
make[4]: *** Waiting for unfinished jobs....
Makefile:143: recipe for target 'all-recursive' failed
make[3]: *** [all-recursive] Error 2
CMakeFiles/ExternalICU.dir/build.make:113: recipe for target 'deps/icu-58.2/src/ExternalICU-stamp/ExternalICU-build' failed
make[2]: *** [deps/icu-58.2/src/ExternalICU-stamp/ExternalICU-build] Error 2
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/ExternalICU.dir/all' failed
make[1]: *** [CMakeFiles/ExternalICU.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2\
Looks like a problem with ICU. We probably need to bump its version for the next release.
Quickfix for now until I bump the ICU version:
# from your build directory
sed -i 's/xlocale/locale/' deps/icu-58.2/src/ExternalICU/source/i18n/digitlst.cpp
Thank you @skystrife it seemed that the above sed command worked!
make // generates above error
sed -i 's/xlocale/locale/' deps/icu-58.2/src/ExternalICU/source/i18n/digitlst.cpp
make
You have to make before executing the sed command
Hi!
Looks like xlocale.h has been removed in glibc 2.26.
See:
- https://www.linuxquestions.org/questions/slackware-14/no-luck-with-libc-on-current-xlocale-h-missing-4175612648/
- https://sourceware.org/glibc/wiki/Release/2.26#Removal_of_.27xlocale.h.27
Looks like MeTA is using a custom FindICU that hasn't been updated for ~2 years. However, it seems that cmake 3.7 has it's own FindICU. Maybe switching to that will pull in a more up-to-date ICU that has been patched for glibc 2.26?
Im very beginer to linux.. Im using ubuntu 18.04v Im facing the same issue can u please help me what should i have to do with above code
Thank you @skystrife it seemed that the above
sedcommand worked!make // generates above error sed -i 's/xlocale/locale/' deps/icu-58.2/src/ExternalICU/source/i18n/digitlst.cpp makeYou have to make before executing the
sedcommand Im very beginer to linux.. Im using ubuntu 18.04v Im facing the same issue can u please help me what should i have to do with above code