[llvm-dev] Fw: Configure error on Solaris 10

Oscar Guido via llvm-dev llvm-dev at lists.llvm.org
Thu Jul 7 14:29:51 PDT 2016

     Hi Stefan,    Yes, it does not build out of the box on Solaris 10.
It's GCC 5.4.0. I made it past cmake with this command line:
LD_LIBRARY_PATH=/export/home/netrac_fam/gtk3/lib:$LD_LIBRARY_PATH cmake -G 'Unix Makefiles' -DCMAKE_INSTALL_PREFIX=/export/home/netrac_fam/gtk3 -DCMAKE_CXX_COMPILER=/export/home/netrac_fam/gtk3/bin/g++ -DCMAKE_C_COMPILER=/export/home/netrac_fam/gtk3/bin/gcc -DCMAKE_C_FLAGS='-mcpu=v9 -I/export/home/netrac_fam/gtk3/include' -DCMAKE_CXX_FLAGS='-mcpu=v9 -I/export/home/netrac_fam/gtk3/include -I/export/home/netrac_fam/gtk3/src/llvm/include' -DCMAKE_EXE_LINKER_FLAGS='-L/export/home/netrac_fam/gtk3/lib -R/export/home/netrac_fam/gtk3/lib' /export/home/netrac_fam/gtk3/src/llvm
Then, I did a quick and dirty replacement because of incompatible ld flags:
find ./ -name link.txt -exec perl -pi -e 's/-Wl,-z -Wl,discard-unused=sections/-Wl,-z,ignore/g' {} \;
Now, gmake gets stuck with this error (missing xlocale.h):
[ 13%] Linking CXX executable ../../bin/not
gmake[2]: *** [projects/libcxx/lib/CMakeFiles/cxx.dir/__/src/support/solaris/xlocale.c.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
[ 13%] Built target obj.clang-tblgen
[ 13%] Linking CXX static library ../libLLVMMC.a
In file included from /export/home/netrac_fam/gtk3/src/llvm/projects/libcxx/include/ios:216:0,
                 from /export/home/netrac_fam/gtk3/src/llvm/projects/libcxx/include/ostream:138,
                 from /export/home/netrac_fam/gtk3/src/llvm/projects/libcxx/include/__std_stream:15,
                 from /export/home/netrac_fam/gtk3/src/llvm/projects/libcxx/src/iostream.cpp:10:
/export/home/netrac_fam/gtk3/src/llvm/projects/libcxx/include/__locale:33:22: fatal error: xlocale.h: No such file or directory
g++ is able to find the xlocale.h under projects/libcxx/projects/include, but it seems that another xlocale.h is required as well (maybe one that ships with Solaris 11?)

      From: Stefan Teleman <stefan.teleman at gmail.com>
 To: Oscar Guido <osc_gui at yahoo.com> 
Cc: "llvm-dev at lists.llvm.org" <llvm-dev at lists.llvm.org>
 Sent: Thursday, July 7, 2016 4:52 PM
 Subject: Re: [llvm-dev] Configure error on Solaris 10
On Thu, Jul 7, 2016 at 1:36 PM, Oscar Guido via llvm-dev
<llvm-dev at lists.llvm.org> wrote:
> Hello,
>    I get the following error while trying to configure an llvm build on
> Solaris 10-SPARC:
> CMake Error at projects/libcxx/CMakeLists.txt:268 (message):
>  C++11 is required but the compiler does not support -std=c++11
> However, the error is about a missing header file (llvm/Support/Solaris.h)
> as reported in build/CMakeFiles/CMakeError.log:

> cc1plus: fatal error: llvm/Support/Solaris.h: No such file or directory
> compilation terminated.
> gmake[1]: *** [CMakeFiles/cmTC_67861.dir/src.cxx.o] Error 1

I am not sure that clang/llvm will build out-of-the-box on Solaris 10.
At least not without some major interventions.

Which version of GCC is this?

Stefan Teleman
KDE e.V.
stefan.teleman at gmail.com


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160707/93bccd37/attachment.html>

More information about the llvm-dev mailing list