-
Notifications
You must be signed in to change notification settings - Fork 0
/
libmaxminddb.inc
68 lines (58 loc) · 1.93 KB
/
libmaxminddb.inc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# -*- mode: mak; indent-tabs-mode: t; tab-width: 8 -*-
# $Id: libmaxminddb.inc,v 1.2 2022/06/05 11:08:39 cvsuser Exp $
# libmaxmindb support
#
#
# Copyright (c) 2022, Adam Young.
# All rights reserved.
#
# The applications are free software: you can redistribute it
# and/or modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, version 3.
#
# Redistributions of source code must retain the above copyright
# notice, and must be distributed with the license document above.
#
# Redistributions in binary form must reproduce the above copyright
# notice, and must include the license document above in
# the documentation and/or other materials provided with the
# distribution.
#
# The applications are distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# ==end==
#
INCMAXMINDDB=
DEFMAXMINDDB=
LIBMAXMINDDB=
################################################################################
# MingGW
ifeq (mingw,$(findstring mingw,"@TOOLCHAIN@"))
################################################################################
# Visual studio
else ifeq (vs,$(findstring vs,"@TOOLCHAIN@"))
ifeq ("$(MAXMINDDB)","")
MAXMINDDB =../vcpkg_installed/x86-windows
ifeq ("$(wildcard $(MAXMINDDB)/include/maxminddb/*)","")
MAXMINDDB =../../vcpkg/installed/x86-windows
ifeq ("$(wildcard $(MAXMINDDB)/include/maxminddb/*)","")
MAXMINDDB =
endif
endif
endif
ifneq ("$(MAXMINDDB)","")
INCMAXMINDDB= -I$(MAXMINDDB)/include
DEFMAXMINDDB= -DHAVE_LIBMAXMINDDB
ifeq ("$(BUILD_TYPE)","release")
LIBMAXMINDDB= $(MAXMINDDB)/lib/libmaxminddb.lib
else
LIBMAXMINDDB= $(MAXMINDDB)/debug/lib/libmaxminddbd.lib
endif
endif
endif
#