Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r84429 - trunk/tools/inspect
From: dnljms_at_[hidden]
Date: 2013-05-22 16:48:45


Author: danieljames
Date: 2013-05-22 16:48:44 EDT (Wed, 22 May 2013)
New Revision: 84429
URL: http://svn.boost.org/trac/boost/changeset/84429

Log:
Make using execution monitor optional in inspect.

And turned off by default. I'm having problems on the computer I use to build
documentation on the release branch. The old version worked okay on release but
not trunk. So I'm disabling the use of the execution monitor until inspect can
use the same version of Boost.Test everywhere,
Text files modified:
   trunk/tools/inspect/inspect.cpp | 23 ++++++++++++++++++++---
   1 files changed, 20 insertions(+), 3 deletions(-)

Modified: trunk/tools/inspect/inspect.cpp
==============================================================================
--- trunk/tools/inspect/inspect.cpp (original)
+++ trunk/tools/inspect/inspect.cpp 2013-05-22 16:48:44 EDT (Wed, 22 May 2013)
@@ -61,7 +61,13 @@
 
 #include "cvs_iterator.hpp"
 
+#if !defined(INSPECT_USE_BOOST_TEST)
+#define INSPECT_USE_BOOST_TEST 0
+#endif
+
+#if INSPECT_USE_BOOST_TEST
 #include "boost/test/included/prg_exec_monitor.hpp"
+#endif
 
 namespace fs = boost::filesystem;
 
@@ -183,12 +189,15 @@
 
   string info( const fs::path & inspect_root )
   {
+ svn_check check(inspect_root);
+
+#if !INSPECT_USE_BOOST_TEST
+ check();
+#else
+
     try {
       boost::execution_monitor e;
- svn_check check(inspect_root);
-
       e.execute(nullary_function_ref<svn_check, int>(check));
- return check.result;
     }
     catch(boost::execution_exception const& e) {
       if (e.code() == boost::execution_exception::system_error) {
@@ -200,6 +209,10 @@
         throw;
       }
     }
+
+#endif
+
+ return check.result;
   }
 
 // visit_predicate (determines which directories are visited) --------------//
@@ -781,7 +794,11 @@
 
 // cpp_main() --------------------------------------------------------------//
 
+#if !INSPECT_USE_BOOST_TEST
+int main( int argc_param, char * argv_param[] )
+#else
 int cpp_main( int argc_param, char * argv_param[] )
+#endif
 {
   // <hack> for the moment, let's be on the safe side
   // and ensure we don't modify anything being pointed to;


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