Solaris 10中的C ++ 11

时间:2015-03-19 16:48:11

标签: c++11 solaris

我正在使用我下载的新Studio 12.4评估Solaris 10中的C ++ 11,将其提取到子目录中,并将其bin目录添加到PATH环境变量中。

我可以编译" Hello world!"程序,但如果我尝试添加" -std = c ++ 11"参数一切都会中断,即使程序中没有C ++ 11特定功能。

有人知道我做错了什么吗?提前谢谢!

/tmp/jarodrigues/cpp11>CC -V
CC: Sun C++ 5.13 SunOS_i386 2014/10/20
/tmp/jarodrigues/cpp11>CC hello.cpp -o hello
/tmp/jarodrigues/cpp11>./hello
Hello, world!
/tmp/jarodrigues/cpp11>CC -std=c++11 hello.cpp -o hello
ld: fatal: /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/CC-gcc/gcc_version.map: 1: expected a `=', `:', `|', or `@'
/tmp/jarodrigues/cpp11>CC -v -std=c++11 hello.cpp -o hello 2>&1 | grep gcc_version.map
/usr/ccs/bin/ld -zld32=-S/tmp/lib_link.1426884246.22089.05/libldstab_ws.so -zld64=-S/tmp/lib_link.1426884246.22089.05/amd64/libldstab_ws.so -zld32=-S/tmp/lib_link.1426884246.22089.05/libld_annotate.so -zld64=-S/tmp/lib_link.1426884246.22089.05/amd64/libld_annotate.so -zld32=-S/tmp/lib_link.1426884246.22089.05/libCCexcept.so.1 /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/crti.o /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/CCgrti.o /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/crt1x.o /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/values-xa.o -M /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/CC-gcc/gcc_version.map hello.o -o hello -Y "P,/tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/sse2:/tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers:/tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib:/usr/ccs/lib:/tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/CC-gcc/lib/:/lib:/usr/lib" -Qy "-R/tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib:/tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/CC-gcc/lib/" -lstdc++ -lgcc_s -lCrunG3 -lm -lc /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/CCgrtn.o /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/crtn.o 2> /tmp/ld.1426884246.22089.06.err
ld: fatal: /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/CC-gcc/gcc_version.map: 1: expected a `=', `:', `|', or `@'
/tmp/jarodrigues/cpp11>head -n 1 /tmp/jarodrigues/cpp11/SolarisStudio12.4-solaris-x86-bin/solarisstudio12.4/lib/compilers/CC-gcc/gcc_version.map
$mapfile_version 2
/tmp/jarodrigues/cpp11>/usr/ccs/bin/ld -V
ld: Software Generation Utilities - Solaris Link Editors: 5.10-1.497
/tmp/jarodrigues/cpp11>cat /etc/release
                       Solaris 10 10/09 s10x_u8wos_08a X86
           Copyright 2009 Sun Microsystems, Inc.  All Rights Reserved.
                        Use is subject to license terms.
                           Assembled 16 September 2009

0 个答案:

没有答案