improved MinGW support
This commit is contained in:
parent
9546ba62d0
commit
64cbc4e1dc
@ -506,6 +506,9 @@ int main(int argc, const char** argv)
|
|||||||
#endif
|
#endif
|
||||||
#ifdef PLATFORM_POSIX_VERSION
|
#ifdef PLATFORM_POSIX_VERSION
|
||||||
DISPLAYLEVEL(4, "PLATFORM_POSIX_VERSION defined: %ldL\n", (long) PLATFORM_POSIX_VERSION);
|
DISPLAYLEVEL(4, "PLATFORM_POSIX_VERSION defined: %ldL\n", (long) PLATFORM_POSIX_VERSION);
|
||||||
|
#endif
|
||||||
|
#ifdef _FILE_OFFSET_BITS
|
||||||
|
DISPLAYLEVEL(4, "_FILE_OFFSET_BITS defined: %ldL\n", (long) _FILE_OFFSET_BITS);
|
||||||
#endif
|
#endif
|
||||||
if ((mode == om_compress) || (mode == om_bench)) DISPLAYLEVEL(4, "Blocks size : %i KB\n", (U32)(blockSize>>10));
|
if ((mode == om_compress) || (mode == om_bench)) DISPLAYLEVEL(4, "Blocks size : %i KB\n", (U32)(blockSize>>10));
|
||||||
|
|
||||||
|
@ -30,12 +30,6 @@
|
|||||||
- The license of this source file is GPLv2.
|
- The license of this source file is GPLv2.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**************************************
|
|
||||||
* Compiler Options
|
|
||||||
**************************************/
|
|
||||||
#if defined(__MINGW32__) && !defined(_POSIX_SOURCE)
|
|
||||||
# define _POSIX_SOURCE 1 /* disable %llu warnings with MinGW on Windows */
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/*****************************
|
/*****************************
|
||||||
* Includes
|
* Includes
|
||||||
|
@ -42,6 +42,9 @@ extern "C" {
|
|||||||
# define fseek _fseeki64
|
# define fseek _fseeki64
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
#if defined(__MINGW32__) && !defined(_POSIX_SOURCE)
|
||||||
|
# define _POSIX_C_SOURCE 1 /* enable __VA_ARGS__ and disable %llu warnings with MinGW on Windows */
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/* **************************************
|
/* **************************************
|
||||||
|
@ -92,7 +92,7 @@ static clock_t g_clockTime = 0;
|
|||||||
*****************************************/
|
*****************************************/
|
||||||
static U32 no_prompt = 0;
|
static U32 no_prompt = 0;
|
||||||
static U32 displayLevel = 2;
|
static U32 displayLevel = 2;
|
||||||
static U32 pause = 0;
|
static U32 use_pause = 0;
|
||||||
|
|
||||||
|
|
||||||
/*-*******************************************************
|
/*-*******************************************************
|
||||||
@ -705,7 +705,7 @@ _end:
|
|||||||
free(compressedBuffer);
|
free(compressedBuffer);
|
||||||
free(decodedBuffer);
|
free(decodedBuffer);
|
||||||
|
|
||||||
if (pause) {
|
if (use_pause) {
|
||||||
DISPLAY("press enter to finish \n");
|
DISPLAY("press enter to finish \n");
|
||||||
(void)getchar();
|
(void)getchar();
|
||||||
}
|
}
|
||||||
@ -777,7 +777,7 @@ int main(int argc, const char** argv)
|
|||||||
break;
|
break;
|
||||||
case 'p': /* pause at the end */
|
case 'p': /* pause at the end */
|
||||||
argument++;
|
argument++;
|
||||||
pause = 1;
|
use_pause = 1;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'i':
|
case 'i':
|
||||||
|
Loading…
Reference in New Issue
Block a user