-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMake.config
59 lines (42 loc) · 1.1 KB
/
Make.config
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
# Make.config
#
# See the README file for copyright information and how to reach the author.
#
#
# user defined stuff
PREFIX = /usr/local
DEBUG = 1
# -----------------------
# internals
SQLCFG = mariadb_config
ifdef MYSQL
SQLCFG = mysql_config
endif
#USE_CLANG = 1
ifdef USE_CLANG
CC = clang++
else
CC = g++
endif
doCompile = $(CC) -c $(CFLAGS) $(DEFINES)
doLink = $(CC) $(LFLAGS)
doLib = ar -rs
TMPDIR = /tmp
USES = -DVDR_PLUGIN -DUSEUUID -DUSEMD5
#DEFINES += -D_GNU_SOURCE -DTARGET='"$(TARGET)"' -DLOG_PREFIX='""' -DPLGDIR='"$(PLGDEST)"' $(USES)
ifdef DEBUG
CXXFLAGS += -ggdb -O0
endif
CXXFLAGS += -fPIC -Wreturn-type -Wall -Wno-parentheses -Wformat -pedantic \
-Wno-long-long -Wunused-variable -Wunused-label -Wno-unused-result \
-Wunused-value -Wunused-but-set-variable -Wunused-function \
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
CXXFLAGS += -std=c++11 -D__STDC_FORMAT_MACROS
ifdef USE_CLANG
CXXFLAGS += -x c++ -Wunused-const-variable
else
CXXFLAGS += -Wunused-but-set-variable
endif
CFLAGS += $(CXXFLAGS)
%.o: %.c
$(doCompile) -o $@ $<