[config] compiler/gcc.hpp version 4.5 to update

Hi, in gcc.hpp the last know version is 4.4 // last known and checked version is 4.4 (Pre-release): #if (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ > 4)) # if defined(BOOST_ASSERT_CONFIG) # error "Unknown compiler version - please run the configure tests and report the results" Is there any new features that should be updated for gcc-4.5? Even if gcc-4.6 has not been released yet it will be useful to update the file for this version also. In particular I'm interested in the consexpr feature. How can I help? Best, _____________________ Vicente Juan Botet Escribá http://viboes.blogspot.com/

in gcc.hpp the last know version is 4.4
Oops, do you want to go ahead and fix that in Trunk?
Is there any new features that should be updated for gcc-4.5?
I don't believe so, I did a quick check of the gcc-4.5 config last week, I didn't double check in C++0x mode though if you want to check that.
Even if gcc-4.6 has not been released yet it will be useful to update the file for this version also. In particular I'm interested in the consexpr feature.
We don't normally introduce config changes for unreleased compilers - but if you can test this then by all means fix Trunk. John.

----- Original Message ----- From: "John Maddock" <boost.regex@virgin.net> To: <boost@lists.boost.org> Sent: Saturday, November 13, 2010 10:44 AM Subject: Re: [boost] [config] compiler/gcc.hpp version 4.5 to update
in gcc.hpp the last know version is 4.4
Oops, do you want to go ahead and fix that in Trunk?
Unfortunately I have no access to the Trunk yet. But I will provide you a path on the meantime.
Is there any new features that should be updated for gcc-4.5?
I don't believe so, I did a quick check of the gcc-4.5 config last week, I didn't double check in C++0x mode though if you want to check that.
gcc-4.5 includes: New wording for C++0x lambdas N2927 GCC 4.5 Explicit conversion operators N2437 GCC 4.5 Unicode string literals N2442 GCC 4.5 Raw string literals N2442 GCC 4.5 Universal character name literals N2170 GCC 4.5 No Standard Layout Types N2342 GCC 4.5 Local and unnamed types as template arguments N2657 GCC 4.5 I guess the test don't take care of all these features.
Even if gcc-4.6 has not been released yet it will be useful to update the file for this version also. In particular I'm interested in the consexpr feature.
We don't normally introduce config changes for unreleased compilers - but if you can test this then by all means fix Trunk.
I have some doubts about the procedure. In order to check the flags that must be defined, should I run the bjam config_info config_test toolset=gcc-4.4.0 cxxflags="-std=c++0x bjam config_info config_test toolset=gcc-4.5.0 cxxflags="-std=c++0x bjam config_info config_test toolset=gcc-4.6.0 cxxflags="-std=c++0x and compare the outputs? Best, Vicente

----- Original Message ----- From: "vicente.botet" <vicente.botet@wanadoo.fr> To: <boost@lists.boost.org> Sent: Saturday, November 13, 2010 2:07 PM Subject: Re: [boost] [config] compiler/gcc.hpp version 4.5 to update
I have some doubts about the procedure. In order to check the flags that must be defined, should I run the
bjam config_info config_test toolset=gcc-4.4.0 cxxflags="-std=c++0x bjam config_info config_test toolset=gcc-4.5.0 cxxflags="-std=c++0x bjam config_info config_test toolset=gcc-4.6.0 cxxflags="-std=c++0x
and compare the outputs?
Hi again, unfortunately I don't reach to get the config_info for my installed gcc-4.4. I get the following error \boost\trunk\libs\config\test> bjam -a config_info toolset=gcc cxxflags="-std=c++0x" > gcc440x.log In file included from c:\cygwin\gcc-4.4.0\bin\../lib/gcc/i386-pc-mingw32/4.4.0/../../../../include/c++/4.4.0/bits/postypes.h:42, from c:\cygwin\gcc-4.4.0\bin\../lib/gcc/i386-pc-mingw32/4.4.0/../../../../include/c++/4.4.0/iosfwd:42, from c:\cygwin\gcc-4.4.0\bin\../lib/gcc/i386-pc-mingw32/4.4.0/../../../../include/c++/4.4.0/ios:39, from c:\cygwin\gcc-4.4.0\bin\../lib/gcc/i386-pc-mingw32/4.4.0/../../../../include/c++/4.4.0/ostream:40, from c:\cygwin\gcc-4.4.0\bin\../lib/gcc/i386-pc-mingw32/4.4.0/../../../../include/c++/4.4.0/iostream:40, from config_info.cpp:19: c:\cygwin\gcc-4.4.0\bin\../lib/gcc/i386-pc-mingw32/4.4.0/../../../../include/c++/4.4.0/cwchar:159: error: '::swprintf' has not been declared c:\cygwin\gcc-4.4.0\bin\../lib/gcc/i386-pc-mingw32/4.4.0/../../../../include/c++/4.4.0/cwchar:166: error: '::vswprintf' has not been declared "g++" -ftemplate-depth-128 -O0 -fno-inline -Wall -g -std=c++0x -DBOOST_ALL_NO_LIB=1 -I"..\..\.." -c -o "..\..\..\bin.v2\libs\config\test\config_info.test\gcc-mingw-4.4.0\debug\config_info.o" "config_info.cpp" I gues I have a problem with wide charracters on my config :( Surprisingly the outputs for 4.5 and 4.6 are the same. See attached files. There is a common line BOOST_NO_CONSTEXPR [no value] I guess this means that BOOST_NO_CONSTEXPR is defined with no value. But when I run the following with gcc4.5.0 or gcc 4.6.0 \boost\trunk\libs\config\test\all> bjam -a BOOST_NO_CONSTEXPR toolset=gcc cxxflags="-std=c++0x" > gcc460x.log I get the following logs gcc.compile.c++ ..\..\..\..\bin.v2\libs\config\test\all\no_constexpr_fail.test\gcc-mingw-4.5.0\debug\threading-multi\no_constexpr_fail.o In file included from ..\no_constexpr_fail.cpp:28:0: ..\/boost_no_constexpr.ipp: In function 'int boost_no_constexpr::test()': ..\/boost_no_constexpr.ipp:19:7: warning: unused variable 'i' "g++" -ftemplate-depth-128 -O0 -fno-inline -Wall -g -mthreads -std=c++0x -DBOOST_ALL_NO_LIB=1 -I"..\..\..\.." -c -o "..\..\..\..\bin.v2\libs\config\test\all\no_constexpr_fail.test\gcc-mingw-4.5.0\debug\threading-multi\no_constexpr_fail.o" "..\no_constexpr_fail.cpp" ...failed gcc.compile.c++ ..\..\..\..\bin.v2\libs\config\test\all\no_constexpr_fail.test\gcc-mingw-4.5.0\debug\threading-multi\no_constexpr_fail.o... or gcc.compile.c++ ..\..\..\..\bin.v2\libs\config\test\all\no_constexpr_fail.test\gcc-mingw-4.6.0\debug\threading-multi\no_constexpr_fail.o In file included from ..\no_constexpr_fail.cpp:28:0: ..\/boost_no_constexpr.ipp: In function 'int boost_no_constexpr::test()': ..\/boost_no_constexpr.ipp:19:7: warning: unused variable 'i' [-Wunused-variable] "g++" -ftemplate-depth-128 -O0 -fno-inline -Wall -g -mthreads -std=c++0x -DBOOST_ALL_NO_LIB=1 -I"..\..\..\.." -c -o "..\..\..\..\bin.v2\libs\config\test\all\no_constexpr_fail.test\gcc-mingw-4.6.0\debug\threading-multi\no_constexpr_fail.o" "..\no_constexpr_fail.cpp" ...failed gcc.compile.c++ ..\..\..\..\bin.v2\libs\config\test\all\no_constexpr_fail.test\gcc-mingw-4.6.0\debug\threading-multi\no_constexpr_fail.o... These log let me think that constexpr is provided. How these reports can be interpreted? BTW I see also BOOST_NO_0X_HDR_FUTURE [no value] But there is no such <future> file. So I think this check should be removed. Best, Vicente P.S I have taken the care to check the gcc version before running each test :) gcc (GCC) 4.4.0 Copyright (C) 2009 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. gcc (GCC) 4.5.0 Copyright (C) 2010 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. \boost\trunk\libs\config\test>gcc --version gcc (GCC) 4.5.0 Copyright (C) 2010 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

vicente.botet <vicente.botet <at> wanadoo.fr> writes:
unfortunately I don't reach to get the config_info for my installed gcc-4.4.
I think some versions of Mingw have had bugs in the headers that prevent them from compiling in pure C++0x mode (due to missing ifdefs and such). You could try using -std=gnu++0x instead of -std=c++0x.

----- Original Message ----- From: "Richard Webb" <richard.webb@boldonjames.com> To: <boost@lists.boost.org> Sent: Saturday, November 13, 2010 4:08 PM Subject: Re: [boost] [config] compiler/gcc.hpp version 4.5 to update
vicente.botet <vicente.botet <at> wanadoo.fr> writes:
unfortunately I don't reach to get the config_info for my installed gcc-4.4.
I think some versions of Mingw have had bugs in the headers that prevent them from compiling in pure C++0x mode (due to missing ifdefs and such).
You could try using -std=gnu++0x instead of -std=c++0x.
Thanks. This works. John, the differences between 4.5 an 4.4 seems to be all already in place. BOOST_NO_EXPLICIT_CONVERSION_OPERATORS [no value] BOOST_NO_LAMBDAS [no value] BOOST_NO_NUMERIC_LIMITS_LOWEST [no value] BOOST_NO_RAW_LITERALS [no value] BOOST_NO_SCOPED_ENUMS [no value] BOOST_NO_UNICODE_LITERALS [no value] I have made the test for gcc4.6 for BOOST_NO_CONSTEXPR and BOOT_NO_NULLPTR that seems to work. I have attached the patch in case you want to update the gcc.hpp file for gcc-4.6. I don't know if someone is interested in macros for these features. * Universal character name literals N2170 GCC 4.5 * No Standard Layout Types N2342 GCC 4.5 * Local and unnamed types as template arguments N2657 GCC 4.5 Thanks for all, Vicente

----- Original Message ----- From: "vicente.botet" <vicente.botet@wanadoo.fr> To: <boost@lists.boost.org> Sent: Saturday, November 13, 2010 5:31 PM Subject: Re: [boost] [config] compiler/gcc.hpp version 4.5 to update I have made the test for gcc4.6 for BOOST_NO_CONSTEXPR and BOOT_NO_NULLPTR that seems to work. -------------------------------------------------------------------------------- Hi again, I had updated the config_info.cpp file also. See attached file. Best, Vicente

I had updated the config_info.cpp file also. See attached file.
Can you please not modify the machine generated part of config_info - it get's blown away when new defect/feature macros are added. We should also add those changes as part of your full constexp patch when you have it? Cheers, John.

----- Original Message ----- From: "John Maddock" <boost.regex@virgin.net> To: <boost@lists.boost.org> Sent: Monday, November 15, 2010 10:30 AM Subject: Re: [boost] [config] compiler/gcc.hpp version 4.5 to update
I had updated the config_info.cpp file also. See attached file.
Can you please not modify the machine generated part of config_info - it get's blown away when new defect/feature macros are added.
We should also add those changes as part of your full constexp patch when you have it?
I think that I had already sent it :( See attache files. Vicente

I had updated the config_info.cpp file also. See attached file.
Can you please not modify the machine generated part of config_info - it get's blown away when new defect/feature macros are added.
We should also add those changes as part of your full constexp patch when you have it?
I think that I had already sent it :(
Quite possibly I missed it!
See attache files.
Applied, cheers, John.

I think some versions of Mingw have had bugs in the headers that prevent them from compiling in pure C++0x mode (due to missing ifdefs and such).
You could try using -std=gnu++0x instead of -std=c++0x.
Thanks. This works. John, the differences between 4.5 an 4.4 seems to be all already in place. BOOST_NO_EXPLICIT_CONVERSION_OPERATORS [no value] BOOST_NO_LAMBDAS [no value] BOOST_NO_NUMERIC_LIMITS_LOWEST [no value] BOOST_NO_RAW_LITERALS [no value] BOOST_NO_SCOPED_ENUMS [no value] BOOST_NO_UNICODE_LITERALS [no value]
I have made the test for gcc4.6 for BOOST_NO_CONSTEXPR and BOOT_NO_NULLPTR that seems to work.
Fixed in Trunk.
I have attached the patch in case you want to update the gcc.hpp file for gcc-4.6. I don't know if someone is interested in macros for these features. * Universal character name literals N2170 GCC 4.5 * No Standard Layout Types N2342 GCC 4.5 * Local and unnamed types as template arguments N2657 GCC 4.5
Generally we only add detection macros when someone actually needs them, basically we don't actually go looking for work ;-) Thanks for checking this, John.

----- Original Message ----- From: "John Maddock" <boost.regex@virgin.net> To: <boost@lists.boost.org> Sent: Monday, November 15, 2010 10:28 AM Subject: Re: [boost] [config] compiler/gcc.hpp version 4.5 to update
Generally we only add detection macros when someone actually needs them, basically we don't actually go looking for work ;-)
I agree.
Thanks for checking this, John.
You are welcome. Vicente
participants (3)
-
John Maddock
-
Richard Webb
-
vicente.botet