Remove optional dependencies on Boost.

Standard smart pointers are now common among the latest compilers.
This commit is contained in:
Tsuda Kageyu 2017-06-09 11:31:22 +09:00
parent 10e8866fec
commit 7e9f019a49
3 changed files with 1 additions and 21 deletions

View File

@ -122,18 +122,6 @@ check_cxx_source_compiles("
}
" HAVE_STD_SMART_PTR)
if(NOT HAVE_STD_SMART_PTR)
check_cxx_source_compiles("
#include <boost/shared_ptr.hpp>
#include <boost/scoped_ptr.hpp>
int main() {
boost::shared_ptr<int> x;
boost::scoped_ptr<int> y;
return 0;
}
" HAVE_BOOST_SMART_PTR)
endif()
# Determine which kind of byte swap functions your compiler supports.
check_cxx_source_compiles("

View File

@ -24,7 +24,6 @@
/* Defined if your compiler supports shared_ptr */
#cmakedefine HAVE_STD_SMART_PTR 1
#cmakedefine HAVE_BOOST_SMART_PTR 1
/* Defined if your compiler supports some safer version of vsprintf */
#cmakedefine HAVE_VSNPRINTF 1

View File

@ -43,14 +43,7 @@
# define SHARED_PTR std::shared_ptr
# define SCOPED_PTR std::unique_ptr
#elif defined(HAVE_BOOST_SMART_PTR)
# include <boost/shared_ptr.hpp>
# include <boost/scoped_ptr.hpp>
# define SHARED_PTR boost::shared_ptr
# define SCOPED_PTR boost::scoped_ptr
#else // !HAVE_STD_SMART_PTR && !HAVE_BOOST_SMART_PTR
#else // !HAVE_STD_SMART_PTR
# include <algorithm>
# include <trefcounter.h>