diff options
Diffstat (limited to 'boost/archive/detail/decl.hpp')
-rw-r--r-- | boost/archive/detail/decl.hpp | 68 |
1 files changed, 24 insertions, 44 deletions
diff --git a/boost/archive/detail/decl.hpp b/boost/archive/detail/decl.hpp index 44e22be96b..bb386d86f8 100644 --- a/boost/archive/detail/decl.hpp +++ b/boost/archive/detail/decl.hpp @@ -22,58 +22,38 @@ // http://www.boost.org/more/separate_compilation.html #include <boost/config.hpp> -#include <boost/preprocessor/facilities/empty.hpp> -#if defined(BOOST_HAS_DECLSPEC) - #if (defined(BOOST_ALL_DYN_LINK) || defined(BOOST_SERIALIZATION_DYN_LINK)) - #if defined(BOOST_ARCHIVE_SOURCE) - #if defined(__BORLANDC__) - #define BOOST_ARCHIVE_DECL(T) T __export - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) T __export - #else - #define BOOST_ARCHIVE_DECL(T) __declspec(dllexport) T - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) __declspec(dllexport) T - #endif - #else - #if defined(__BORLANDC__) - #define BOOST_ARCHIVE_DECL(T) T __import - #else - #define BOOST_ARCHIVE_DECL(T) __declspec(dllimport) T - #endif - #endif - #if defined(BOOST_WARCHIVE_SOURCE) - #if defined(__BORLANDC__) - #define BOOST_WARCHIVE_DECL(T) T __export - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) T __export - #else - #define BOOST_WARCHIVE_DECL(T) __declspec(dllexport) T - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) __declspec(dllexport) T - #endif - #else - #if defined(__BORLANDC__) - #define BOOST_WARCHIVE_DECL(T) T __import - #else - #define BOOST_WARCHIVE_DECL(T) __declspec(dllimport) T - #endif - #endif - #if !defined(BOOST_WARCHIVE_SOURCE) && !defined(BOOST_ARCHIVE_SOURCE) - #if defined(__BORLANDC__) - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) T __import - #else - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) __declspec(dllimport) T - #endif - #endif +#if (defined(BOOST_ALL_DYN_LINK) || defined(BOOST_SERIALIZATION_DYN_LINK)) + #if defined(BOOST_ARCHIVE_SOURCE) + #define BOOST_ARCHIVE_DECL BOOST_SYMBOL_EXPORT + #else + #define BOOST_ARCHIVE_DECL BOOST_SYMBOL_IMPORT #endif -#endif // BOOST_HAS_DECLSPEC + #if defined(BOOST_WARCHIVE_SOURCE) + #define BOOST_WARCHIVE_DECL BOOST_SYMBOL_EXPORT + #else + #define BOOST_WARCHIVE_DECL BOOST_SYMBOL_IMPORT + #endif + #if !defined(BOOST_WARCHIVE_SOURCE) && !defined(BOOST_ARCHIVE_SOURCE) + #define BOOST_ARCHIVE_OR_WARCHIVE_DECL BOOST_SYMBOL_IMPORT + #endif + + #if defined(BOOST_WARCHIVE_SOURCE) || defined(BOOST_ARCHIVE_SOURCE) + #define BOOST_ARCHIVE_OR_WARCHIVE_DECL BOOST_SYMBOL_EXPORT + #else + #define BOOST_ARCHIVE_OR_WARCHIVE_DECL BOOST_SYMBOL_IMPORT + #endif + +#endif #if ! defined(BOOST_ARCHIVE_DECL) - #define BOOST_ARCHIVE_DECL(T) T + #define BOOST_ARCHIVE_DECL #endif #if ! defined(BOOST_WARCHIVE_DECL) - #define BOOST_WARCHIVE_DECL(T) T + #define BOOST_WARCHIVE_DECL #endif #if ! defined(BOOST_ARCHIVE_OR_WARCHIVE_DECL) - #define BOOST_ARCHIVE_OR_WARCHIVE_DECL(T) T + #define BOOST_ARCHIVE_OR_WARCHIVE_DECL #endif #endif // BOOST_ARCHIVE_DETAIL_DECL_HPP |