Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r50557 - in trunk/boost/test: impl utils/runtime utils/runtime/env utils/runtime/file
From: DDeakins_at_[hidden]
Date: 2009-01-12 12:19:39


Author: davedeakins
Date: 2009-01-12 12:19:38 EST (Mon, 12 Jan 2009)
New Revision: 50557
URL: http://svn.boost.org/trac/boost/changeset/50557

Log:
Flag WinCE's lack of environment variable support for WinCE builds.
Text files modified:
   trunk/boost/test/impl/unit_test_parameters.ipp | 10 +++++++++-
   trunk/boost/test/utils/runtime/config.hpp | 4 ++++
   trunk/boost/test/utils/runtime/env/environment.hpp | 4 ++++
   trunk/boost/test/utils/runtime/env/fwd.hpp | 4 ++++
   trunk/boost/test/utils/runtime/env/variable.hpp | 4 ++++
   trunk/boost/test/utils/runtime/file/config_file_iterator.cpp | 5 +++++
   6 files changed, 30 insertions(+), 1 deletions(-)

Modified: trunk/boost/test/impl/unit_test_parameters.ipp
==============================================================================
--- trunk/boost/test/impl/unit_test_parameters.ipp (original)
+++ trunk/boost/test/impl/unit_test_parameters.ipp 2009-01-12 12:19:38 EST (Mon, 12 Jan 2009)
@@ -30,11 +30,17 @@
 // Boost.Runtime.Param
 #include <boost/test/utils/runtime/cla/dual_name_parameter.hpp>
 #include <boost/test/utils/runtime/cla/parser.hpp>
-#include <boost/test/utils/runtime/env/variable.hpp>
 
 namespace rt = boost::runtime;
 namespace cla = rt::cla;
+
+
+#ifndef UNDER_CE
+#include <boost/test/utils/runtime/env/variable.hpp>
+
 namespace env = rt::env;
+#endif
+
 
 // Boost
 #include <boost/config.hpp>
@@ -214,7 +220,9 @@
 
     boost::optional<T> v;
 
+ #ifndef UNDER_CE
     env::get( parameter_2_env_var[parameter_name], v );
+ #endif
 
     return v? *v : default_value;
 }

Modified: trunk/boost/test/utils/runtime/config.hpp
==============================================================================
--- trunk/boost/test/utils/runtime/config.hpp (original)
+++ trunk/boost/test/utils/runtime/config.hpp 2009-01-12 12:19:38 EST (Mon, 12 Jan 2009)
@@ -63,6 +63,7 @@
 typedef std::basic_ostream<char_type> out_stream;
 #endif
 
+#ifndef UNDER_CE
 #if defined(__COMO__)
 inline void
 putenv_impl( cstring name, cstring value )
@@ -85,6 +86,7 @@
     putenv( const_cast<char*>( fs.str().c_str() ) );
 }
 #endif
+#endif
 
 #define BOOST_RT_PARAM_LITERAL( l ) l
 #define BOOST_RT_PARAM_CSTRING_LITERAL( l ) cstring( l, sizeof( l ) - 1 )
@@ -103,6 +105,7 @@
 typedef wrap_wstringstream format_stream;
 typedef std::wostream out_stream;
 
+#ifndef UNDER_CE
 inline void
 putenv_impl( cstring name, cstring value )
 {
@@ -115,6 +118,7 @@
     using namespace std;
     wputenv( const_cast<wchar_t*>( fs.str().c_str() ) );
 }
+#endif
 
 #define BOOST_RT_PARAM_LITERAL( l ) L ## l
 #define BOOST_RT_PARAM_CSTRING_LITERAL( l ) cstring( L ## l, sizeof( L ## l )/sizeof(wchar_t) - 1 )

Modified: trunk/boost/test/utils/runtime/env/environment.hpp
==============================================================================
--- trunk/boost/test/utils/runtime/env/environment.hpp (original)
+++ trunk/boost/test/utils/runtime/env/environment.hpp 2009-01-12 12:19:38 EST (Mon, 12 Jan 2009)
@@ -15,6 +15,10 @@
 #ifndef BOOST_RT_ENV_ENVIRONMENT_HPP_062604GER
 #define BOOST_RT_ENV_ENVIRONMENT_HPP_062604GER
 
+#ifdef UNDER_CE
+#error Windows CE does not support environment variables.
+#endif
+
 // Boost.Runtime.Parameter
 #include <boost/test/utils/runtime/config.hpp>
 #include <boost/test/utils/runtime/fwd.hpp>

Modified: trunk/boost/test/utils/runtime/env/fwd.hpp
==============================================================================
--- trunk/boost/test/utils/runtime/env/fwd.hpp (original)
+++ trunk/boost/test/utils/runtime/env/fwd.hpp 2009-01-12 12:19:38 EST (Mon, 12 Jan 2009)
@@ -15,6 +15,10 @@
 #ifndef BOOST_RT_ENV_FWD_HPP_062604GER
 #define BOOST_RT_ENV_FWD_HPP_062604GER
 
+#ifdef UNDER_CE
+#error Windows CE does not support environment variables.
+#endif
+
 // Boost.Runtime.Parameter
 #include <boost/test/utils/runtime/config.hpp>
 

Modified: trunk/boost/test/utils/runtime/env/variable.hpp
==============================================================================
--- trunk/boost/test/utils/runtime/env/variable.hpp (original)
+++ trunk/boost/test/utils/runtime/env/variable.hpp 2009-01-12 12:19:38 EST (Mon, 12 Jan 2009)
@@ -15,6 +15,10 @@
 #ifndef BOOST_RT_ENV_VARIABLE_HPP_062604GER
 #define BOOST_RT_ENV_VARIABLE_HPP_062604GER
 
+#ifdef UNDER_CE
+#error Windows CE does not support environment variables.
+#endif
+
 // Boost.Runtime.Parameter
 #include <boost/test/utils/runtime/config.hpp>
 #include <boost/test/utils/runtime/fwd.hpp>

Modified: trunk/boost/test/utils/runtime/file/config_file_iterator.cpp
==============================================================================
--- trunk/boost/test/utils/runtime/file/config_file_iterator.cpp (original)
+++ trunk/boost/test/utils/runtime/file/config_file_iterator.cpp 2009-01-12 12:19:38 EST (Mon, 12 Jan 2009)
@@ -18,7 +18,10 @@
 #include <boost/test/utils/runtime/file/config_file_iterator.hpp>
 #include <boost/test/utils/runtime/validation.hpp>
 
+#ifndef UNDER_CE
 #include <boost/test/utils/runtime/env/environment.hpp>
+#endif
+
 
 // Boost
 #include <boost/utility.hpp>
@@ -352,7 +355,9 @@
     if( it == m_symbols_table.end() ) {
         boost::optional<cstring> macro_value; // !! variable actually may have different type
 
+ #ifndef UNDER_CE
         env::get( macro_name, macro_value );
+ #endif
 
         BOOST_RT_PARAM_VALIDATE_LOGIC( macro_value || ignore_missing || !m_detect_missing_macro,
             BOOST_RT_PARAM_LITERAL( "Unknown macro \"" ) << macro_name << BOOST_RT_PARAM_LITERAL( "\"" ) );


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk