]> rtime.felk.cvut.cz Git - pes-rpp/rpp-simulink.git/blob - rpp/rpp/target_tools.mk
Remove unnecessary blocks
[pes-rpp/rpp-simulink.git] / rpp / rpp / target_tools.mk
1 # Copyright (C) 2013-2014 Czech Technical University in Prague
2 #
3 # Authors:
4 #     - Carlos Jenkins <carlos@jenkins.co.cr>
5 #
6 # This document contains proprietary information belonging to Czech
7 # Technical University in Prague. Passing on and copying of this
8 # document, and communication of its contents is not permitted
9 # without prior written authorization.
10 #
11 # File : target_tools.mk
12 # Abstract:
13 #     Makefile for CCS toolchain support.
14 #
15 #     This file set variables to CCS tools to support build for this toolchain.
16 #     This file is included by rpp.tmf before declaring the rules for source
17 #     code.
18 #
19 # References:
20 #     "Include a tool specification settings" comment block in rpp.tmf
21 #      Compiler options documentation available in refs/armcl.pdf
22
23
24 include $(START_DIR)/slprj/target_paths.mk
25
26 # RPP options
27 RPP_STATIC_LIB   = rpp-lib.lib
28 RPP_OS_LAYER_INC = $(RPP_LIB_ROOT)/os/7.0.2_tms570/include/
29
30 # Options for target source files
31 TARGET_INCS      =
32 TARGET_SRCS      =
33
34 # Compiler command and options
35 CC      = "$(COMPILER_ROOT)/bin/armcl"
36 CFLAGS  = -mv7R4 -me --code_state=32 --float_support=VFPv3D16           \
37           --abi=eabi --compile_only -O2 --gcc --diag_wrap=on            \
38           --diag_warning=225 --display_error_number                     \
39           --enum_type=packed --gen_func_subsections                     \
40           -DEXTMODE_DISABLEPRINTF                                       \
41           --include_path="$(RPP_LIB_ROOT)/rpp/include"                  \
42           --include_path="$(RPP_LIB_ROOT)/lwip/src/include"             \
43           --include_path="$(RPP_LIB_ROOT)/lwip/src/include/ipv4"        \
44           --include_path="$(RPP_LIB_ROOT)/lwip/src/include/ipv6"        \
45           --include_path="$(RPP_OS_LAYER_INC)"                          \
46           --include_path="$(COMPILER_ROOT)/include"
47
48 # Define when external mode should wait for host connection
49 # CFLAGS += -DON_TARGET_WAIT_FOR_START
50
51 CFLAGS          += $(EXT_CC_OPTS)
52 CFLAGS          += $(OPTS)
53 CDEBUG           = -g
54 CCOUTPUTFLAG     = --output_file=
55
56 CXX              =
57 CXXFLAGS         =
58 CXXDEBUG         =
59
60 # Linker command and options
61 LD      = $(CC)
62 LDFLAGS = -mv7R4 --code_state=32 --float_support=VFPv3D16 --abi=eabi    \
63           -O2 --diag_warning=225 --display_error_number                 \
64           --enum_type=packed --run_linker -m"$(MODEL).map"              \
65           --diag_wrap=on --stack_size=$(RPP_STACK_SIZE)                 \
66           --heap_size=$(RPP_HEAP_SIZE) --reread_libs --warn_sections    \
67           --display_error_number --rom_model                            \
68           --search_path="$(RPP_LIB_ROOT)"                               \
69           --library="$(RPP_STATIC_LIB)"                                 \
70           --retain="$(RPP_STATIC_LIB)<sys_intvecs.obj>(.intvecs)"       \
71           --search_path="$(COMPILER_ROOT)/lib"                          \
72           --library="rtsv7R4_T_le_v3D16_eabi.lib"                       \
73           "$(RPP_LIB_ROOT)/rpp/TMS570LS313xFlashLnk.cmd"                \
74           --generate_dead_funcs_list=$(MODEL)-deadfuncs.xml
75
76 LDDEBUG          = -g
77 LDOUTPUTFLAG     = --output_file=
78
79 # Archiver command and options
80 AR               = "$(COMPILER_ROOT)/bin/armar"
81 ARFLAGS          = -r
82
83 # Binary file format converter command and options
84 ifeq ($(OS),Windows_NT)
85 OBJCOPY          = copy
86 else
87 OBJCOPY          = cp
88 endif
89 OBJCOPYFLAGS     =
90
91 # Specify the output extension from compiler
92 OBJ_EXT          = .obj
93
94 # Specify extension from linker
95 PROGRAM_FILE_EXT = .o
96
97 # Specify extension for final product at end of build
98 EXE_FILE_EXT     = .out