mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-12-27 04:41:23 +00:00
add HAVE_ZLIB around the rest of the zlib stuff in w_wad.c/h, move zlib.h inclusion down below doomdef.h etc includes in case that does anything for compiling (?)
This commit is contained in:
parent
b7f7c2ecf7
commit
1889c36dea
2 changed files with 20 additions and 16 deletions
34
src/w_wad.c
34
src/w_wad.c
|
@ -26,22 +26,6 @@
|
|||
#include "lzf.h"
|
||||
#endif
|
||||
|
||||
#ifndef _MSC_VER
|
||||
#ifndef _LARGEFILE64_SOURCE
|
||||
#define _LARGEFILE64_SOURCE
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef _LFS64_LARGEFILE
|
||||
#define _LFS64_LARGEFILE
|
||||
#endif
|
||||
|
||||
#ifndef _FILE_OFFSET_BITS
|
||||
#define _FILE_OFFSET_BITS 0
|
||||
#endif
|
||||
|
||||
#include "zlib.h"
|
||||
|
||||
#include "doomdef.h"
|
||||
#include "doomstat.h"
|
||||
#include "doomtype.h"
|
||||
|
@ -79,6 +63,24 @@ int snprintf(char *str, size_t n, const char *fmt, ...);
|
|||
#define O_BINARY 0
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_ZLIB
|
||||
#ifndef _MSC_VER
|
||||
#ifndef _LARGEFILE64_SOURCE
|
||||
#define _LARGEFILE64_SOURCE
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef _LFS64_LARGEFILE
|
||||
#define _LFS64_LARGEFILE
|
||||
#endif
|
||||
|
||||
#ifndef _FILE_OFFSET_BITS
|
||||
#define _FILE_OFFSET_BITS 0
|
||||
#endif
|
||||
|
||||
#include "zlib.h"
|
||||
#endif
|
||||
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
|
|
@ -154,7 +154,9 @@ size_t W_LumpLength(lumpnum_t lumpnum);
|
|||
|
||||
boolean W_IsLumpWad(lumpnum_t lumpnum); // for loading maps from WADs in PK3s
|
||||
|
||||
#ifdef HAVE_ZLIB
|
||||
void zerr(int ret); // zlib error checking
|
||||
#endif
|
||||
|
||||
size_t W_ReadLumpHeaderPwad(UINT16 wad, UINT16 lump, void *dest, size_t size, size_t offset);
|
||||
size_t W_ReadLumpHeader(lumpnum_t lump, void *dest, size_t size, size_t offest); // read all or a part of a lump
|
||||
|
|
Loading…
Reference in a new issue