From f595e889b91a674eb94db7ca4d832da54f5194cd Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Thu, 17 Aug 2017 15:01:09 +0200 Subject: Use int64_t for public file API offsets. Don't mess with conditional compilation with LARGEFILE -- always expose 64-bit file offsets in our public API. --- scripts/cmapdump.c | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'scripts') diff --git a/scripts/cmapdump.c b/scripts/cmapdump.c index c82ac114..a59532e8 100644 --- a/scripts/cmapdump.c +++ b/scripts/cmapdump.c @@ -3,11 +3,15 @@ /* We never want to build memento versions of the cmapdump util */ #undef MEMENTO -/* We never want large file access here */ -#undef FZ_LARGEFILE - -#include -#include +#ifndef _LARGEFILE64_SOURCE +#ifdef _MSC_VER +#if _MSC_VER >= 1400 /* MSVC 8 (Visual Studio 2005) or newer */ +#define _LARGEFILE64_SOURCE +#endif +#else +#define _LARGEFILE64_SOURCE +#endif +#endif #include "mupdf/fitz.h" #include "mupdf/pdf.h" @@ -32,6 +36,9 @@ #include "../source/pdf/pdf-cmap.c" #include "../source/pdf/pdf-cmap-parse.c" +#include +#include + static void clean(char *p) { -- cgit v1.2.3