Commit graph

8 commits

Author SHA1 Message Date
H. Peter Anvin
3118429089 Windows: clean up the handling of stat on Windows
[f]stat on Windows is messy: we need to use _stati64 for maximum
compatibility, but because there is a bunch of stuff wrapped in
macros, autoconf sometimes gets the wrong answers.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2017-04-06 15:48:51 -07:00
H. Peter Anvin
675e7b7d79 MSVC compatibility: clean up the handling of _stati64/_fstati64
On Windows we need to use _stati64/_fstati64 in order to handle large
file sizes, but the handling was broken in the canned MSVC++
configuration.  Clean it up and fix it.

This addresses BR 3392398.

Reported-by: Nikolai Saoukh <nms@otdel-1.org>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2017-04-05 21:19:03 -07:00
H. Peter Anvin
9b4b92b014 watcom.h: horrific hack to support OpenWatcom switch limitations
OpenWatcom still doesn't have proper support for 64-bit switch
statements.  Hack around it in a truly vile way.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2017-02-20 00:36:53 -08:00
H. Peter Anvin
f5287231c1 Move canned OpenWatcom config to config/watcom.h.
Move the canned OpenWatcom configuration file to config/watcom.h.
Also exclude config/config.h from being a dependency for MSVC.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2016-10-19 13:23:04 -07:00
H. Peter Anvin
4c9132e3a0 compiler.h: include <sys/types.h>
Apparently, at least on some OS/2 compilers, <sys/types.h> needs to be
included for off_t to be defined.  This seems like a generically good
idea to include this header whenever it is available.

Remove reference to <types.h>.  This was supposedly for MSVC, but
there is no actual evidence that it is useful beyond <sys/types.h>.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2016-10-19 13:13:38 -07:00
H. Peter Anvin
2024ae60d6 config/msvc.h: inttypes.h and stdbool.h introduced in MSVS 2013
<inttypes.h> and <stdbool.h> were introduced in MS Visual Studio 2013,
not 2015.  See:

https://blogs.msdn.microsoft.com/vcblog/2013/07/19/c99-library-support-in-visual-studio-2013/

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2016-10-04 17:50:53 -07:00
H. Peter Anvin
276785a8ff config: add configuration file for unknown compilers
Add a config header file for the most conservative case of a totally
unknown compiler.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2016-10-04 17:13:50 -07:00
H. Peter Anvin
397c169736 Move config.h to a subdirectory, add MSVC-specific config file
Instead of trying to do hacks in the Makefiles, define header files
for specific compilers if they can't use autoconf.  Currently defined
for Microsoft Visual Studio, based on MSDN documentation.  It is
currently untested.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2016-10-04 17:01:59 -07:00