-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathmakefile.options
More file actions
122 lines (103 loc) · 4.71 KB
/
Copy pathmakefile.options
File metadata and controls
122 lines (103 loc) · 4.71 KB
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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# This file is part of SECONDO.
#
# Copyright (C) 2004, University in Hagen, Department of Computer Science,
# Database Systems for New Applications.
#
# SECONDO is 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; either version 2 of the License, or
# (at your option) any later version.
#
# SECONDO is 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 SECONDO; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
# Configuration file for some important compiler switches
#
# April 2006, M. Spiekermann
#
# Uncomment next line to compile with debugging information:
DEBUG = -ggdb
# The next flag instructs the preprocessor to report the hierachy
# of include instructions.
#DEBUG += -Wp, -H
# Note: The flags below print out all defined symbols the preprocessor knows
# gcc -dM -E <file>
# Optimization level for the whole tree, overridable from the command line:
#
# make # the default below, -Og
# make SECONDO_OPTIMIZE="-O2" # production build
# make SECONDO_OPTIMIZE="-O3 -march=native"
# make SECONDO_OPTIMIZE="" # no optimization at all
#
# -Og is the default because it is the level GCC intends for code that is
# going to be debugged.
#
# One thing to know before raising it for a production build: objects built at
# different levels must not be mixed, so run "make clean" first.
SECONDO_OPTIMIZE ?= -Og
OPTIMIZE += $(SECONDO_OPTIMIZE)
# From -O1 upwards GCC emits false -Wmaybe-uninitialized reports out of
# libstdc++ headers -- <regex> moving a std::function inside _NFA::_M_insert_*
# is one, and there is nothing to initialize at the call site because the
# variable belongs to the header.
OPTIMIZE_IS_HIGH := $(filter -O -O1 -O2 -O3 -Ofast,$(SECONDO_OPTIMIZE))
ifneq ($(OPTIMIZE_IS_HIGH),)
OPTIMIZE += -Wno-error=maybe-uninitialized
endif
# Every -O level, -Og included, lets GCC drop the frame pointer; only -O0 keeps
# it. Keep it in all builds: perf call graphs and the fast unwinder ASan uses
# for allocation stacks walk that chain.
# To give it up in a production build, pass the opposite flag.
# make SECONDO_OPTIMIZE=-O2 SECONDO_ADDITIONAL_DEFAULTCCFLAGS=-fomit-frame-pointer
DEFAULTCCFLAGS += -fno-omit-frame-pointer
# Do not use assertions.
# Assertions may
# only check logical constraints without doing any program
# logic! NEVER use functions having side-effects within an assert(...)!
#OPTIMIZE += -DNDEBUG
# Uncomment next lines to generate profiling data used by gprof
# Run make realclean; make
#DEBUG += -pg
#LDFLAGS += -pg
# Set up default flags for the compiler
DEFAULTCCFLAGS += $(DEBUG) $(OPTIMIZE) $(TEMPLATEFLAGS) -I. -I$(INCLUDEDIR)
# Show all warnings
DEFAULTCCFLAGS += -Wall
# -pedantic -Wunreachable-code -Wunknown-pragmas -Wshadow -Wformat=2 -Wundef -Wbad-function-cast -Wcast-qual -Wsign-compare -fbounds-check -fstack-check -fcheck-new
CPPSTDOPTION = -std=c++17
#On 32 bit systems, the file size is restrictec to 2GB
#when handling huge data sets, this may be not sufficient
#thereby we set the file system to support much larger files
DEFAULTCCFLAGS += -D_FILE_OFFSET_BITS=64
# Flag for compiling code of operator value mappings which supports progress measurement.
DEFAULTCCFLAGS += -DUSE_PROGRESS
# Flag for compiling code which uses serialization instead of copying class instances
# on block. After changing this flag you need to do a make clean, rebuild secondo, and
# restore your databases!
#
DEFAULTCCFLAGS += -DUSE_SERIALIZATION
# The next flag activates trace messages. Alternatively you may define it
# only in some subordinated makefiles to avoid to many messages.
#DEFAULTCCFLAGS += -DTRACE_ON
# macOS/clang: several subdirectories build with -Werror, and Apple clang
# errors on things gcc (the Linux reference compiler) does not, on code that is
# valid and works. Downgrade only these to keep the -Werror build meaningful:
# - variable-length arrays in C++: a SUPPORTED clang/gcc extension, not a defect.
# - deprecated-declarations: the macOS SDK annotates POSIX functions such as
# sprintf() as deprecated (~460 call sites); glibc does not.
MACOS_WNO := -Wno-vla-cxx-extension -Wno-vla-extension
MACOS_WNO += -Wno-deprecated-declarations
ifeq ($(platform),mac_osx)
CPPSTDOPTION += $(MACOS_WNO)
DEFAULTCCFLAGS += $(MACOS_WNO)
endif
INC_FILES := $(wildcard $(SECONDO_BUILD_DIR)/makefile.n*c)
ifdef INC_FILES
include $(INC_FILES)
endif