[cfe-dev] [libcxx] Linux support status?

Larry Evans cppljevans at suddenlink.net
Mon Mar 14 09:54:52 PDT 2011


On 03/14/11 11:15, John Myers wrote:
> 
> 
> On Mon, Mar 14, 2011 at 7:38 AM, Marc Glisse
> <marc.glisse at inria.fr
> <mailto:marc.glisse at inria.fr>> wrote:
> 
>     Hello,
> 
> 
>     On Sun, 13 Mar 2011, John Myers wrote:
> 
>         I was wondering if libcxx works on Linux machines. From reading
>         the archives
>         it seems like some people have got it to work.
> 
> 
>     no, it doesn't. At least, anything related to streams or wchar_t
>     will break. Other parts that don't involve as much platform specific
>     code work much better.
> 
> 
>         john at ubuntu:~/src$ clang++ --version
>         clang version 3.0 (trunk 127576)
>         Target: x86_64-unknown-linux-gnu
>         Thread model: posix
>         john at ubuntu:~/src$ clang++ -std=c++0x -stdlib=libc++ -emit-llvm
>         -c -o
>         world.bc world.cc
>         john at ubuntu:~/src$ chmod +x world.bc
>         john at ubuntu:~/src$ ./world.bc
> 
> 
>     Is that really supposed to work?
> 
> 
> Yeah, somewhere on llvm.org <http://llvm.org> there was instructions on
> setting up Linux to run bitcode directly.
> 
>         john at ubuntu:~/src$ cat world.cc
>         #include <iostream>
> 
>         using namespace std;
> 
>         int main() {
> 
>           cout << "hello world!\n";
> 
>           return 0;
>         }
> 
> 
>     Sorry, hello world is broken and will output some garbage after the
>     normal text.
> 
There was a small patch to get a hello world to work without printing
garbage:

  http://llvm.org/bugs/show_bug.cgi?id=8992#c7

The more general problem of missing locale functions that have _l
subscript was proposed here:

  http://article.gmane.org/gmane.comp.compilers.clang.devel/13258

However, there's been no feedback to that proposal, and hence, no
follow up to that proposal :(

-Larry





More information about the cfe-dev mailing list