macos_endian.c 665 B

123456789101112131415161718192021
  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 define the BSD symbols if sys/param.h is included
  9. * before detection. This causes the endian detection to misfire
  10. * as both MACOS and BSD are "detected" (currently). This just
  11. * tests that the sys/param.h include can be included before
  12. * endian detection and still have it work correctly.
  13. */
  14. #if defined(__APPLE__)
  15. # include <sys/param.h>
  16. # include <boost/predef/os/bsd.h>
  17. # include <boost/predef/os/macos.h>
  18. # include <boost/predef/other/endian.h>
  19. #endif