BVB Source Codes

mars Show bsd.hpp Source code

Return Download mars: download bsd.hpp Source code - Download mars Source code - Type:.hpp
  1. //  (C) Copyright John Maddock 2001 - 2003.
  2. //  (C) Copyright Darin Adler 2001.
  3. //  (C) Copyright Douglas Gregor 2002.
  4. //  Use, modification and distribution are subject to the
  5. //  Boost Software License, Version 1.0. (See accompanying file
  6. //  LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  7.  
  8. //  See http://www.boost.org for most recent version.
  9.  
  10. //  generic BSD config options:
  11.  
  12. #if !defined(__FreeBSD__) && !defined(__NetBSD__) && !defined(__OpenBSD__) && !defined(__DragonFly__)
  13. #error "This platform is not BSD"
  14. #endif
  15.  
  16. #ifdef __FreeBSD__
  17. #define BOOST_PLATFORM "FreeBSD " BOOST_STRINGIZE(__FreeBSD__)
  18. #elif defined(__NetBSD__)
  19. #define BOOST_PLATFORM "NetBSD " BOOST_STRINGIZE(__NetBSD__)
  20. #elif defined(__OpenBSD__)
  21. #define BOOST_PLATFORM "OpenBSD " BOOST_STRINGIZE(__OpenBSD__)
  22. #elif defined(__DragonFly__)
  23. #define BOOST_PLATFORM "DragonFly " BOOST_STRINGIZE(__DragonFly__)
  24. #endif
  25.  
  26. //
  27. // is this the correct version check?
  28. // FreeBSD has <nl_types.h> but does not
  29. // advertise the fact in <unistd.h>:
  30. //
  31. #if (defined(__FreeBSD__) && (__FreeBSD__ >= 3)) || defined(__DragonFly__)
  32. #  define BOOST_HAS_NL_TYPES_H
  33. #endif
  34.  
  35. //
  36. // FreeBSD 3.x has pthreads support, but defines _POSIX_THREADS in <pthread.h>
  37. // and not in <unistd.h>
  38. //
  39. #if (defined(__FreeBSD__) && (__FreeBSD__ <= 3))\
  40.    || defined(__OpenBSD__) || defined(__DragonFly__)
  41. #  define BOOST_HAS_PTHREADS
  42. #endif
  43.  
  44. //
  45. // No wide character support in the BSD header files:
  46. //
  47. #if defined(__NetBSD__)
  48. #define __NetBSD_GCC__ (__GNUC__         * 1000000 \
  49.                        + __GNUC_MINOR__ *    1000 \
  50.                        + __GNUC_PATCHLEVEL__)
  51. // XXX - the following is required until c++config.h
  52. //       defines _GLIBCXX_HAVE_SWPRINTF and friends
  53. //       or the preprocessor conditionals are removed
  54. //       from the cwchar header.
  55. #define _GLIBCXX_HAVE_SWPRINTF 1
  56. #endif
  57.  
  58. #if !((defined(__FreeBSD__) && (__FreeBSD__ >= 5)) \
  59.       || (defined(__NetBSD_GCC__) && (__NetBSD_GCC__ >= 2095003)) || defined(__DragonFly__))
  60. #  define BOOST_NO_CWCHAR
  61. #endif
  62. //
  63. // The BSD <ctype.h> has macros only, no functions:
  64. //
  65. #if !defined(__OpenBSD__) || defined(__DragonFly__)
  66. #  define BOOST_NO_CTYPE_FUNCTIONS
  67. #endif
  68.  
  69. //
  70. // thread API's not auto detected:
  71. //
  72. #define BOOST_HAS_SCHED_YIELD
  73. #define BOOST_HAS_NANOSLEEP
  74. #define BOOST_HAS_GETTIMEOFDAY
  75. #define BOOST_HAS_PTHREAD_MUTEXATTR_SETTYPE
  76. #define BOOST_HAS_SIGACTION
  77.  
  78. // boilerplate code:
  79. #define BOOST_HAS_UNISTD_H
  80. #include <boost/config/posix_features.hpp>
  81.  
  82.  
  83.  
  84.  
  85.  
  86.  
  87.  
downloadbsd.hpp Source code - Download mars Source code
Related Source Codes/Software:
Hero - Elegant transition library for iOS & tvOS 2017-06-09
deep-photo-styletransfer - Code and data for paper "Deep Photo Style Transfer... 2017-06-09
mastodon - A GNU Social-compatible microblogging server ... 2017-06-09
plyr - A simple HTML5, YouTube and Vimeo player ... 2017-06-08
prepack - Prepack is a partial evaluator for JavaScript. Pre... 2017-06-08
Public-APIs - 2017-06-09
lottie-ios - An iOS library to natively render After Effects ve... 2017-06-09
Awesome-Hacking - A collection of various awesome lists for hackers,... 2017-06-09
algorithms - Minimal examples of data structures and algorithms... 2017-06-10
lectures - Oxford Deep NLP 2017 course 2017-06-10
CRYENGINE - CRYENGINE is a powerful real-time game development... 2017-06-11
postal - 2017-06-11
reactide - Reactide is the first dedicated IDE for React web ... 2017-06-11
rkt - rkt is a pod-native container engine for Linux. It... 2017-06-11
uWebSockets - Tiny WebSockets https://for... 2017-06-11
realworld - TodoMVC for the RealWorld - Exemplary fullstack Me... 2017-06-11
goreplay - GoReplay is an open-source tool for capturing and ... 2017-06-10
pyenv - Simple Python version management 2017-06-10
redux-saga - An alternative side effect model for Redux apps ... 2017-06-10
angular-starter - 2017-06-10

 Back to top