setup_config.hpp 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. /*
  2. * Copyright Andrey Semashev 2007 - 2015.
  3. * Distributed under the Boost Software License, Version 1.0.
  4. * (See accompanying file LICENSE_1_0.txt or copy at
  5. * http://www.boost.org/LICENSE_1_0.txt)
  6. */
  7. /*!
  8. * \file setup_config.hpp
  9. * \author Andrey Semashev
  10. * \date 14.09.2009
  11. *
  12. * \brief This header is the Boost.Log library implementation, see the library documentation
  13. * at http://www.boost.org/doc/libs/release/libs/log/doc/html/index.html. In this file
  14. * internal configuration macros are defined.
  15. */
  16. #ifndef BOOST_LOG_DETAIL_SETUP_CONFIG_HPP_INCLUDED_
  17. #define BOOST_LOG_DETAIL_SETUP_CONFIG_HPP_INCLUDED_
  18. #include <boost/log/detail/config.hpp>
  19. #ifdef BOOST_HAS_PRAGMA_ONCE
  20. #pragma once
  21. #endif
  22. #if !defined(BOOST_LOG_SETUP_BUILDING_THE_LIB)
  23. // Detect if we're dealing with dll
  24. # if defined(BOOST_LOG_SETUP_DYN_LINK) || defined(BOOST_ALL_DYN_LINK)
  25. # define BOOST_LOG_SETUP_DLL
  26. # endif
  27. # if defined(BOOST_LOG_SETUP_DLL)
  28. # define BOOST_LOG_SETUP_API BOOST_SYMBOL_IMPORT
  29. # else
  30. # define BOOST_LOG_SETUP_API
  31. # endif
  32. //
  33. // Automatically link to the correct build variant where possible.
  34. //
  35. # if !defined(BOOST_ALL_NO_LIB) && !defined(BOOST_LOG_SETUP_NO_LIB)
  36. # define BOOST_LIB_NAME boost_log_setup
  37. # if defined(BOOST_LOG_SETUP_DLL)
  38. # define BOOST_DYN_LINK
  39. # endif
  40. # include <boost/config/auto_link.hpp>
  41. # endif // auto-linking disabled
  42. #else // !defined(BOOST_LOG_SETUP_BUILDING_THE_LIB)
  43. # if defined(BOOST_LOG_SETUP_DLL)
  44. # define BOOST_LOG_SETUP_API BOOST_SYMBOL_EXPORT
  45. # else
  46. # define BOOST_LOG_SETUP_API BOOST_SYMBOL_VISIBLE
  47. # endif
  48. #endif // !defined(BOOST_LOG_SETUP_BUILDING_THE_LIB)
  49. #endif // BOOST_LOG_DETAIL_SETUP_CONFIG_HPP_INCLUDED_