Fix build on Windows: winsock2.h requires WIN32_LEAN_AND_MEAN

This is required for the next commit.

Change-Id: I73fa1e59a4844c43a109fffd148c8c3e3a100c79
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
This commit is contained in:
Thiago Macieira 2016-12-02 13:02:56 -08:00
parent 7ca66b1e66
commit c7b0f56fb1
3 changed files with 8 additions and 0 deletions

View File

@ -37,6 +37,9 @@
**
****************************************************************************/
// see comment in ../platformdefs_win.h.
#define WIN32_LEAN_AND_MEAN 1
#include "qgenericengine.h"
#include "../qnetworksession_impl.h"

View File

@ -40,6 +40,8 @@
#ifndef QPLATFORMDEFS_WIN_H
#define QPLATFORMDEFS_WIN_H
// Since we need to include winsock2.h, we need to define WIN32_LEAN_AND_MEAN
// somewhere above so windows.h won't include winsock.h.
#include <winsock2.h>
#include <mswsock.h>
#undef interface

View File

@ -37,6 +37,9 @@
**
****************************************************************************/
// see comment in ../platformdefs_win.h.
#define WIN32_LEAN_AND_MEAN 1
#include "qnetworksession_impl.h"
#include "qbearerengine_impl.h"