You might consider using code from Boost's config subsystem. There's a list of 
dozens of macros they define to set what features are available in what 
compilers here: 
http://www.boost.org/doc/libs/1_53_0/libs/config/doc/html/boost_config/boost_macro_reference.html#boost_config.boost_macro_reference.macros_that_describe_c__11_features_not_supported

--
Todd Greer
Principal Scientist, Affinegy, Inc.

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of 
Theodore Papadopoulo
Sent: Wednesday, February 20, 2013 4:16 AM
To: Benjamin Eikel
Cc: [email protected]
Subject: Re: [CMake] detecting if c++11 available

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Nowadays, asking for c++-11 is probably too coarse as implementations are 
usually uncomplete. So you have a stdc++-11 switch and still missing some 
features on which you rely.

Another technique is to test features instead of the whole standard, that would 
be more robust...

I did something like that to get a cmake build of a library used to build with 
automake/autoconf (which have such a facility). It might not be very 
complicated to extend to new features....

        Theo.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.13 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iEYEARECAAYFAlEkolIACgkQEr8WrU8nPV2AGgCgoXf6NcHIltBs2RuF4XLDcIgk
k0EAn3XVl5xsgaAw6SU2ZUugnj7OdKQL
=YSl4
-----END PGP SIGNATURE-----
--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to