xref: /minix/external/mit/lua/dist/src/lprefix.h (revision 0a6a1f1d)
1 /*	$NetBSD: lprefix.h,v 1.2 2015/02/02 14:03:05 lneto Exp $	*/
2 
3 /*
4 ** Id: lprefix.h,v 1.2 2014/12/29 16:54:13 roberto Exp
5 ** Definitions for Lua code that must come before any other header file
6 ** See Copyright Notice in lua.h
7 */
8 
9 #ifndef lprefix_h
10 #define lprefix_h
11 
12 
13 #ifndef _KERNEL
14 /*
15 ** Allows POSIX/XSI stuff
16 */
17 #if !defined(LUA_USE_C89)	/* { */
18 
19 #if !defined(_XOPEN_SOURCE)
20 #define _XOPEN_SOURCE           600
21 #elif _XOPEN_SOURCE == 0
22 #undef _XOPEN_SOURCE  /* use -D_XOPEN_SOURCE=0 to undefine it */
23 #endif
24 
25 /*
26 ** Allows manipulation of large files in gcc and some other compilers
27 */
28 #if !defined(LUA_32BITS) && !defined(_FILE_OFFSET_BITS)
29 #define _LARGEFILE_SOURCE       1
30 #define _FILE_OFFSET_BITS       64
31 #endif
32 
33 #endif				/* } */
34 #endif
35 
36 
37 /*
38 ** Windows stuff
39 */
40 #if defined(_WIN32) 	/* { */
41 
42 #if !defined(_CRT_SECURE_NO_WARNINGS)
43 #define _CRT_SECURE_NO_WARNINGS  /* avoid warnings about ISO C functions */
44 #endif
45 
46 #endif			/* } */
47 
48 #endif
49 
50