Github user jeking3 commented on a diff in the pull request:

    https://github.com/apache/thrift/pull/1448#discussion_r173620082
  
    --- Diff: build/cmake/DefineOptions.cmake ---
    @@ -91,11 +91,26 @@ if(WITH_CPP)
         option(WITH_STDTHREADS "Build with C++ std::thread support" OFF)
         CMAKE_DEPENDENT_OPTION(WITH_BOOSTTHREADS "Build with Boost threads 
support" OFF
             "NOT WITH_STDTHREADS;Boost_FOUND" OFF)
    +
    +    set(WITH_CPP_SUPPORT OFF)
    --- End diff --
    
    I think we would be better off testing for C++11 features and ensuring that 
if we find what we need, we can enable certain things.  For example if we ask 
cmake to check for support of cxx_defaulted_functions then we can enable the 
boost-less noncopyable.  One can typically check for cxx_nullptr in order to 
determine if there is smart pointer support, or write a custom check for 
std::shared_ptr detection.  Relying on checking compiler versions is 
error-prone and not as portable.
    
    This is a good start to optionally eliminating boost from the C++ runtime 
library.  I can work on the feature checks as an extension to this work.


---

Reply via email to