1 # Copyright (c) 2005-2017 Intel Corporation
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
19 COMPILE_ONLY = -c -MMD
20 PREPROC_ONLY = -E -x c++
26 WARNING_AS_ERROR_KEY = -Werror
28 TEST_WARNING_KEY = -Wextra -Wshadow -Wcast-qual -Woverloaded-virtual -Wnon-virtual-dtor
29 WARNING_SUPPRESS = -Wno-parentheses -Wno-non-virtual-dtor -Wno-dangling-else
31 EXPORT_KEY = -Wl,--version-script,
36 LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
37 LIBS += -lpthread -lrt
38 LINK_FLAGS = -Wl,-rpath-link=. -Wl,-rpath=. -rdynamic
39 C_FLAGS = $(CPLUS_FLAGS)
41 ifeq ($(cfg), release)
42 CPLUS_FLAGS = $(ITT_NOTIFY) -g -O2 -DUSE_PTHREAD
45 CPLUS_FLAGS = -DTBB_USE_DEBUG $(ITT_NOTIFY) -g -O0 -DUSE_PTHREAD
49 CPLUS_FLAGS += -stdlib=$(stdlib)
50 LIB_LINK_FLAGS += -stdlib=$(stdlib)
56 ifeq (intel64,$(arch))
57 ITT_NOTIFY = -DDO_ITT_NOTIFY
59 LIB_LINK_FLAGS += -m64
63 ITT_NOTIFY = -DDO_ITT_NOTIFY
64 CPLUS_FLAGS += -m32 -march=pentium4
65 LIB_LINK_FLAGS += -m32
70 LIB_LINK_FLAGS += -m64
75 LIB_LINK_FLAGS += -m32
83 #------------------------------------------------------------------------------
84 # Setting assembler data.
85 #------------------------------------------------------------------------------
87 ifeq (intel64,$(arch))
97 ASSEMBLY_SOURCE=$(arch)-gas
98 #------------------------------------------------------------------------------
99 # End of setting assembler data.
100 #------------------------------------------------------------------------------
102 #------------------------------------------------------------------------------
103 # Setting tbbmalloc data.
104 #------------------------------------------------------------------------------
106 M_CPLUS_FLAGS = $(CPLUS_FLAGS) -fno-rtti -fno-exceptions
108 #------------------------------------------------------------------------------
109 # End of setting tbbmalloc data.
110 #------------------------------------------------------------------------------