summaryrefslogtreecommitdiff
path: root/src/lprefix.h
diff options
context:
space:
mode:
authorLua Team <team@lua.org>2015-01-02 12:00:00 +0000
committerrepogen <>2015-01-02 12:00:00 +0000
commit6b0dd2d3885d020d3154e0da84de92e9ee8b2c82 (patch)
treea5513d60b8154b2855e8246087520fde146516e7 /src/lprefix.h
parent65cb014c87f5ecfee995afc9babba930d6a9f0bc (diff)
downloadlua-github-6b0dd2d3885d020d3154e0da84de92e9ee8b2c82.tar.gz
Lua 5.3.0-rc35.3.0-rc3
Diffstat (limited to 'src/lprefix.h')
-rw-r--r--src/lprefix.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/lprefix.h b/src/lprefix.h
index c2a78cd7..02daa837 100644
--- a/src/lprefix.h
+++ b/src/lprefix.h
@@ -1,5 +1,5 @@
/*
-** $Id: lprefix.h,v 1.1 2014/11/03 15:12:44 roberto Exp $
+** $Id: lprefix.h,v 1.2 2014/12/29 16:54:13 roberto Exp $
** Definitions for Lua code that must come before any other header file
** See Copyright Notice in lua.h
*/
@@ -11,18 +11,24 @@
/*
** Allows POSIX/XSI stuff
*/
+#if !defined(LUA_USE_C89) /* { */
+
#if !defined(_XOPEN_SOURCE)
#define _XOPEN_SOURCE 600
+#elif _XOPEN_SOURCE == 0
+#undef _XOPEN_SOURCE /* use -D_XOPEN_SOURCE=0 to undefine it */
#endif
/*
** Allows manipulation of large files in gcc and some other compilers
*/
-#if !defined(_FILE_OFFSET_BITS)
+#if !defined(LUA_32BITS) && !defined(_FILE_OFFSET_BITS)
#define _LARGEFILE_SOURCE 1
#define _FILE_OFFSET_BITS 64
#endif
+#endif /* } */
+
/*
** Windows stuff