Skip to content

Commit a89f098

Browse files
committed
Fix mmdb library on Windows and use it by default
1 parent 3c71a03 commit a89f098

3 files changed

Lines changed: 7 additions & 3 deletions

File tree

Makefile.windows

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,7 @@ DLL_FILES=\
275275
src/modules/geoip_base.dll \
276276
src/modules/geoip_classic.dll \
277277
src/modules/geoip_csv.dll \
278+
src/modules/geoip_mmdb.dll \
278279
src/modules/geoip-tag.dll \
279280
src/modules/globops.dll \
280281
src/modules/help.dll \

include/mmdb.h

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,11 @@
3333
#include <stddef.h>
3434

3535
#ifdef _WIN32
36-
#include <winsock2.h>
37-
#include <ws2tcpip.h>
36+
#ifndef _WIN32_WINNT
37+
#define _WIN32_WINNT 0x0601
38+
#endif
39+
#include <winsock2.h>
40+
#include <ws2tcpip.h>
3841
#else
3942
#include <sys/socket.h>
4043
#include <netinet/in.h>

include/windows/setup.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
#define _WIN32_WINNT 0x0601
6464

6565
/* What geoip engine to use */
66-
#define GEOIP_ENGINE "geoip_classic"
66+
#define GEOIP_ENGINE "geoip_mmdb"
6767

6868
/* Generation version number (e.g.: 3 for Unreal3*) */
6969
#define UNREAL_VERSION_GENERATION 6

0 commit comments

Comments
 (0)