Pyrogenesis  trunk
no_crt_posix.h
Go to the documentation of this file.
1 /* Copyright (c) 2010 Wildfire Games
2  *
3  * Permission is hereby granted, free of charge, to any person obtaining
4  * a copy of this software and associated documentation files (the
5  * "Software"), to deal in the Software without restriction, including
6  * without limitation the rights to use, copy, modify, merge, publish,
7  * distribute, sublicense, and/or sell copies of the Software, and to
8  * permit persons to whom the Software is furnished to do so, subject to
9  * the following conditions:
10  *
11  * The above copyright notice and this permission notice shall be included
12  * in all copies or substantial portions of the Software.
13  *
14  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15  * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
17  * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
18  * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
19  * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
20  * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21  */
22 
23 /**
24  * see rationale in wposix.h.
25  * prevent subsequent includes of CRT headers (e.g. <io.h>) from
26  * interfering with previous declarations made by wposix headers (e.g. open).
27  * this is accomplished by \#defining their include guards.
28  * note: \#include "crt_posix.h" can undo the effects of this header and
29  * pull in those headers.
30  **/
31 
32 #ifndef _INC_IO // <io.h> include guard
33 # define _INC_IO
34 # define WPOSIX_DEFINED_IO_INCLUDE_GUARD
35 #endif
36 #ifndef _INC_DIRECT // <direct.h> include guard
37 # define _INC_DIRECT
38 # define WPOSIX_DEFINED_DIRECT_INCLUDE_GUARD
39 #endif