2 # @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
17 # QCC arm COMPILER SETTINGS
18 # Standard form of tool.mk file configured for PosixBasedOS001 vmware
31 # Add addtion Linker Flags....
32 # If your application contains c++ code you will need
36 # Compile options and commands
37 TARGET_FLG = -Vgcc_ntoarmle
50 # Set Optimization Flag
51 ifeq ($(OPTIMIZATION),OPTIMIZE)
54 ifeq ($(OPTIMIZATION),FULL_OPTIMIZE)
57 ifeq ($(OPTIMIZATION),NONE)
67 CC_FLAGS = $(TARGET_FLG) -w9 -Wc,-Wall -shared $(CC_OPT_FLG) $(CC_PROFILING_FLG) $(CC_DEBUG_FLG)
69 CC_CMD = $(CC) $(CC_FLAGS) $(DEFS) $(INCLUDES) $(@F:.$(OBJ_EXT)=.c) -o $(@)
70 CPP_CMD = $(CPP) $(CC_FLAGS) $(DEFS) $(INCLUDES) $(@F:.$(OBJ_EXT)=.cpp) -o $(@)
72 # Archive Options (Static Library)
75 AR_CMD = $(AR) $(AR_FLAGS) $(AR_OFLAG)$(@) $^
79 # Used in the form of $(LD_CMD) -L[Library Paths] -l[libraries] [objects] $(LD_OFLAG) executable_name.$(BIN_EXT)
80 LD_FLAGS = $(TARGET_FLG) $(CC_PROFILING_FLG) $(CC_DEBUG_FLG) $(LD_CPP)
82 LD_CMD = $(LD) -L$(LIB_PATH) $(LD_FLAGS)
83 EXEC_CMD = $(LD_CMD) $(LD_OFLAG) $(@) $(OBJECTS) $(addprefix -L , $(LIB_PATHS)) -Bstatic $(addprefix -l , $(STATIC_LIBS)) -Bdynamic $(addprefix -l , $(DYNAMIC_LIBS))
85 # To create shared objects use the linker command but add -shared
86 SO_CMD = $(LD) $(LD_FLAGS) -shared
87 SLIB_CMD = $(SO_CMD) $^ $(LD_OFLAG) $(@) $(addprefix -L, $(LIB_PATHS)) \
88 -Bstatic $(addprefix -l,$(STATIC_LIBS)) -Bdynamic $(addprefix -l,$(DYNAMIC_LIBS))