basic_config.hpp 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. #ifndef BOOST_ARCHIVE_DETAIL_BASIC_CONFIG_HPP
  2. #define BOOST_ARCHIVE_DETAIL_BASIC_CONFIG_HPP
  3. // MS compatible compilers support #pragma once
  4. #if defined(_MSC_VER) && (_MSC_VER >= 1020)
  5. # pragma once
  6. #endif
  7. // basic_config.hpp ---------------------------------------------//
  8. // (c) Copyright Robert Ramey 2004
  9. // Use, modification, and distribution is subject to the Boost Software
  10. // License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  11. // http://www.boost.org/LICENSE_1_0.txt)
  12. // See library home page at http://www.boost.org/libs/serialization
  13. //----------------------------------------------------------------------------//
  14. // This header implements separate compilation features as described in
  15. // http://www.boost.org/more/separate_compilation.html
  16. #include <boost/config.hpp>
  17. #ifdef BOOST_HAS_DECLSPEC // defined in config system
  18. // we need to import/export our code only if the user has specifically
  19. // asked for it by defining either BOOST_ALL_DYN_LINK if they want all boost
  20. // libraries to be dynamically linked, or BOOST_ARCHIVE_DYN_LINK
  21. // if they want just this one to be dynamically linked:
  22. #if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_ARCHIVE_DYN_LINK)
  23. // export if this is our own source, otherwise import:
  24. #ifdef BOOST_ARCHIVE_SOURCE
  25. # define BOOST_ARCHIVE_DECL __declspec(dllexport)
  26. #else
  27. # define BOOST_ARCHIVE_DECL __declspec(dllimport)
  28. #endif // BOOST_ARCHIVE_SOURCE
  29. #endif // DYN_LINK
  30. #endif // BOOST_HAS_DECLSPEC
  31. //
  32. // if BOOST_ARCHIVE_DECL isn't defined yet define it now:
  33. #ifndef BOOST_ARCHIVE_DECL
  34. #define BOOST_ARCHIVE_DECL
  35. #endif
  36. #endif // BOOST_ARCHIVE_DETAIL_BASIC_CONFIG_HPP