macos_vs_bsd.c 574 B

12345678910111213141516171819
  1. /*
  2. Copyright Rene Rivera 2013
  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. * OSX can masquerade as BSD when sys/param.h is previously included.
  9. * So we test that we only detect OSX in this combination.
  10. */
  11. #if defined(__APPLE__)
  12. # include <sys/param.h>
  13. # include <boost/predef/os/bsd.h>
  14. # include <boost/predef/os/macos.h>
  15. # if !BOOST_OS_MACOS || BOOST_OS_BSD
  16. # error "BOOST_OS_MACOS not detected and/or BOOST_OS_BSD mis-detected."
  17. # endif
  18. #endif