Add missing header for Windows 8, Windows Server 2012, and Windows Phone 8
parent
e06b50f564
commit
500c312a58
|
|
@ -10,6 +10,13 @@
|
||||||
|
|
||||||
#include "wait.h"
|
#include "wait.h"
|
||||||
|
|
||||||
|
// Windows 8, Windows Server 2012, and Windows Phone 8.1 need <synchapi.h>
|
||||||
|
#if defined(CRYPTOPP_WIN32_AVAILABLE)
|
||||||
|
# if defined(_WIN32_WINNT_WIN8) && ((WINVER >= _WIN32_WINNT_WIN8) || (_WIN32_WINNT >= _WIN32_WINNT_WIN8))
|
||||||
|
# include <synchapi.h>
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef USE_BERKELEY_STYLE_SOCKETS
|
#ifdef USE_BERKELEY_STYLE_SOCKETS
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <netdb.h>
|
#include <netdb.h>
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,13 @@
|
||||||
|
|
||||||
#ifdef SOCKETS_AVAILABLE
|
#ifdef SOCKETS_AVAILABLE
|
||||||
|
|
||||||
|
// Windows 8, Windows Server 2012, and Windows Phone 8.1 need <synchapi.h>
|
||||||
|
#if defined(CRYPTOPP_WIN32_AVAILABLE)
|
||||||
|
# if defined(_WIN32_WINNT_WIN8) && ((WINVER >= _WIN32_WINNT_WIN8) || (_WIN32_WINNT >= _WIN32_WINNT_WIN8))
|
||||||
|
# include <synchapi.h>
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef USE_BERKELEY_STYLE_SOCKETS
|
#ifdef USE_BERKELEY_STYLE_SOCKETS
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
|
|
||||||
|
|
@ -1,14 +1,15 @@
|
||||||
|
// wait.h - written and placed in the public domain by Wei Dai
|
||||||
|
|
||||||
#ifndef CRYPTOPP_WAIT_H
|
#ifndef CRYPTOPP_WAIT_H
|
||||||
#define CRYPTOPP_WAIT_H
|
#define CRYPTOPP_WAIT_H
|
||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
#include "cryptlib.h"
|
||||||
|
#include "misc.h"
|
||||||
|
#include "stdcpp.h"
|
||||||
|
|
||||||
#ifdef SOCKETS_AVAILABLE
|
#ifdef SOCKETS_AVAILABLE
|
||||||
|
|
||||||
#include "misc.h"
|
|
||||||
#include "cryptlib.h"
|
|
||||||
#include <vector>
|
|
||||||
|
|
||||||
#ifdef USE_WINDOWS_STYLE_SOCKETS
|
#ifdef USE_WINDOWS_STYLE_SOCKETS
|
||||||
#include <winsock2.h>
|
#include <winsock2.h>
|
||||||
#else
|
#else
|
||||||
|
|
@ -16,6 +17,12 @@
|
||||||
#include <sys/select.h>
|
#include <sys/select.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// For defintions of VOID, PVOID, HANDLE, PHANDLE, etc.
|
||||||
|
#if defined(CRYPTOPP_WIN32_AVAILABLE)
|
||||||
|
#define WIN32_LEAN_AND_MEAN
|
||||||
|
#include <windows.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "hrtimer.h"
|
#include "hrtimer.h"
|
||||||
|
|
||||||
#if defined(__has_feature)
|
#if defined(__has_feature)
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,13 @@
|
||||||
|
|
||||||
#include "wait.h"
|
#include "wait.h"
|
||||||
|
|
||||||
|
// Windows 8, Windows Server 2012, and Windows Phone 8.1 need <synchapi.h>
|
||||||
|
#if defined(CRYPTOPP_WIN32_AVAILABLE)
|
||||||
|
# if defined(_WIN32_WINNT_WIN8) && ((WINVER >= _WIN32_WINNT_WIN8) || (_WIN32_WINNT >= _WIN32_WINNT_WIN8))
|
||||||
|
# include <synchapi.h>
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
NAMESPACE_BEGIN(CryptoPP)
|
NAMESPACE_BEGIN(CryptoPP)
|
||||||
|
|
||||||
WindowsHandle::WindowsHandle(HANDLE h, bool own)
|
WindowsHandle::WindowsHandle(HANDLE h, bool own)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue