-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile.config
executable file
·98 lines (77 loc) · 1.88 KB
/
Makefile.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
# -*- Makefile -*-
# $Id: Makefile.config,v 1.12 2009/06/08 12:06:51 akotov2 Exp $
BUILD_MODE=release
PROJ_DIR=.
# compilers
CC=gcc
CXX=g++
# compiler flags
CCFLAGS=-Wall
CXXFLAGS=-Wall
# compiler options for debug mode
ifeq "$(strip $(BUILD_MODE))" "debug"
CCOPT+=-gstabs+3 -D_DEBUG
CXXOPT+=-gstabs+3 -D_DEBUG
endif
# compiler options for release mode
ifeq "$(strip $(BUILD_MODE))" "release"
CCOPT+=-O3
CXXOPT+=-O3
endif
# compiler options for shared libraries
CCSH=-fPIC
CXXSH=-fPIC
# directories
# distribution directory
DISTR_DIR=$(PROJ_DIR)/distr/$(BUILD_MODE)/bin
# project-wide include directory
INCLUDE_DIR=$(PROJ_DIR)/include
# libraries directory
LIBS_DIR=$(PROJ_DIR)/distr/$(BUILD_MODE)/lib
# indexer
INDEXER_DIR=$(PROJ_DIR)/index
INDEXER_BUILD_DIR=$(INDEXER_DIR)/_obj/$(BUILD_MODE)
# query processor
QPROC_DIR=$(PROJ_DIR)/qproc
QPROC_BUILD_DIR=$(QPROC_DIR)/_obj/$(BUILD_MODE)
# search box
SBOX_DIR=$(PROJ_DIR)/sbox
SBOX_BUILD_DIR=$(SBOX_DIR)/_obj/$(BUILD_MODE)
# index I/O library
INDIO_DIR=$(PROJ_DIR)/indio
INDIO_BUILD_DIR=$(INDIO_DIR)/_obj/$(BUILD_MODE)
# support library
UTILS_DIR=$(PROJ_DIR)/utils
UTILS_BUILD_DIR=$(UTILS_DIR)/_obj/$(BUILD_MODE)
# include project-wide headers
CCINCLUDE=-I$(INCLUDE_DIR)
# include utilities headers
CCUTILS=-I$(UTILS_DIR)/include
#include index I/O header
CCINDIO=-I$(INDIO_DIR)/include
# include indexer headers
CCINDEXER=-I$(INDEXER_DIR)/include
# include query processor headers
CCQPROC=-I$(QPROC_DIR)/include
# to include MySQL++ headers
CCMYSQLPP=-I/usr/include/mysql++
# to include MySQL headers
CCMYSQL=-I/usr/include/mysql
# linker
LD=gcc
# output directory specifier
OUT=-o
# linker options
LDSHARED=-shared -fPIC
LDSTL=-lstdc++
LDFLAGS=-pipe
LDTHREAD=-lpthread
LDEXPAT=-lexpat
LDMYSQLPP=-lmysqlpp
LDFCGI=-lfcgi
LDMATH=-lm
LDL=-ldl
# link utilities library
LDUTILS=-L$(LIBS_DIR) -lutils
# link index I/O library
LDINDIO=-L$(LIBS_DIR) -lindio