Go to the documentation of this file.
18 #include <boost/config.hpp>
19 #include <boost/system/config.hpp>
20 #include <boost/system/error_code.hpp>
21 #include <boost/system/system_error.hpp>
23 #if defined(BOOST_POSIX_API)
25 #define BOOST_PROCESS_LAST_ERROR errno
26 #define BOOST_PROCESS_PLATFORM posix
27 #elif defined(BOOST_WINDOWS_API)
29 #define BOOST_PROCESS_LAST_ERROR GetLastError()
30 #define BOOST_PROCESS_PLATFORM windows
34 #define BOOST_PROCESS_PLATFORM_PROMOTE_PATH(COMPONENT) \
35 <boost/process/BOOST_PROCESS_PLATFORM/COMPONENT.hpp>
36 #define BOOST_PROCESS_PLATFORM_PROMOTE_NAMESPACE(COMPONENT) \
37 namespace boost::process \
39 using BOOST_PROCESS_PLATFORM::COMPONENT; \
41 #define BOOST_PROCESS_PLATFORM_PROMOTE_INITIALIZERS_NAMESPACE \
42 namespace boost::process::initializers \
44 using namespace boost::process::BOOST_PROCESS_PLATFORM::initializers; \
48 #if defined(BOOST_PROCESS_DOXYGEN)
54 #define BOOST_POSIX_API
60 #define BOOST_WINDOWS_API
69 #define BOOST_PROCESS_THROW(EX) throw EX
72 #define BOOST_PROCESS_SOURCE_LOCATION "in file '" __FILE__ "', line " BOOST_STRINGIZE(__LINE__) ": "
74 #define BOOST_PROCESS_THROW_LAST_SYSTEM_ERROR(what) \
75 BOOST_PROCESS_THROW(boost::system::system_error( \
76 boost::system::error_code(BOOST_PROCESS_LAST_ERROR, boost::system::system_category()), \
77 BOOST_PROCESS_SOURCE_LOCATION what))
79 #define BOOST_PROCESS_RETURN_LAST_SYSTEM_ERROR(ec) \
80 ec = boost::system::error_code(BOOST_PROCESS_LAST_ERROR, boost::system::system_category())