1
mirror of https://github.com/hashcat/hashcat synced 2024-12-27 05:13:45 +01:00

Simplify common.h a bit.

This commit is contained in:
Rosen Penev 2017-02-21 22:08:50 -08:00
parent f302576a79
commit abd7b2bfcc
No known key found for this signature in database
GPG Key ID: 8B5A63249D3D4CE7

View File

@ -8,16 +8,11 @@
#define PROGNAME "hashcat"
#if defined (__linux__) || defined (__CYGWIN__)
#if defined (__unix__) || defined (__APPLE__)
#define _POSIX
#elif defined (__APPLE__)
#define _POSIX
#elif defined (__FreeBSD__)
#define _POSIX
#elif defined (_WIN32) || defined (_WIN64)
#elif defined (__WINNT__)
#define _WIN 1
#define WIN 1
#define _POSIX_THREAD_SAFE_FUNCTIONS 200112L //for *time_r functions
#else
#error Your Operating System is not supported or detected
#endif
@ -26,7 +21,15 @@
#define _GNU_SOURCE
#endif
// needed for *time_r functions under MinGW
#ifndef _POSIX_THREAD_SAFE_FUNCTIONS
#define _POSIX_THREAD_SAFE_FUNCTIONS 200112L
#endif
// needed for 64-bit off_t on 32-bit OSes
#ifndef _FILE_OFFSET_BITS
#define _FILE_OFFSET_BITS 64
#endif
#define NOMINMAX 1