Make files clean-up
[o-du/l2.git] / build / common / mt.mak
1 ################################################################################
2 #   Copyright (c) [2017-2019] [Radisys]                                        #
3 #                                                                              #
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                                    #
7 #                                                                              #
8 #       http://www.apache.org/licenses/LICENSE-2.0                             #
9 #                                                                              #
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.                                             #
15 ################################################################################
16 #
17 ##-------------------------------------------------------------#
18 #Makefile for product mt - script generated.
19 #Only the $(CCmtFLAGS) may be modified.
20 #-------------------------------------------------------------#
21 include ../common/rsys_fancy.mak
22 include ../common/env.mak
23
24 #-------------------------------------------------------------#
25 #User macros (to be modified)
26 #-------------------------------------------------------------#
27
28 CCmtFLAGS=-DSS_MT_TMR -USS_LOGGER_SUPPORT -DEGTP_U#<---Insert mt specific defines here
29
30 #-------------------------------------------------------------#
31 #File/Obj macros             
32 #-------------------------------------------------------------#
33 SRC_DIR=$(ROOT_DIR)/src/mt
34
35 C_SRCS=$(wildcard $(SRC_DIR)/*.c)
36 C_SRCS:=$(filter-out %ss_acc.c,$(C_SRCS))
37 C_SRCS:=$(filter-out %mt_tst.c,$(C_SRCS))
38 C_SRCS:=$(filter-out %sol.c, $(C_SRCS))
39 C_SRCS:=$(filter-out %diag.c, $(C_SRCS))
40 C_SRCS:=$(filter-out %mtsp.c, $(C_SRCS))
41 C_SRCS:=$(filter-out %tskent.c, $(C_SRCS))
42
43 ifeq ($(PLTFRM),PAL)
44 C_SRCS:=$(filter-out %4gmx.c, $(C_SRCS))
45 endif
46 ifneq ($(BOARD), T33H)
47 C_SRCS:=$(filter-out %t33.c, $(C_SRCS))
48 endif
49
50 C_OBJS_WO_LOG=$(patsubst $(SRC_DIR)/%.c,$(OBJ_DIR)/%.o,$(C_SRCS))
51 I_OPTS+=-isystem $(BSPPATH)/usr/include/brcm
52 I_OPTS+=-I$(SRC_DIR)/security
53 I-OPTS+=-I$(ROOT_DIR)/src/wls_lib
54
55 HDR_FILES+=$(wildcard $(CM_DIR)/env*.[hx])
56 HDR_FILES+=$(wildcard $(CM_DIR)/gen*.[hx])
57 HDR_FILES+=$(wildcard $(CM_DIR)/ssi*.[hx])
58 HDR_FILES+=$(wildcard $(CM_DIR)/cm*.[hx])
59 HDR_FILES+=$(wildcard $(SRC_DIR)/*.[hx])
60 HDR_FILES+=$(wildcard $(SRC_DIR)/*.[hx])
61
62 lib:$(LIB_DIR)/libmt.a
63
64 include $(COM_BUILD_DIR)/compile.mak
65
66 #-------------------------------------------------------------#
67 #Linker macros             
68 #-------------------------------------------------------------#
69 $(LIB_DIR)/libmt.a:$(C_OBJS_WO_LOG)
70         $(Q)ar -cr $(LIB_DIR)/libmt.a $(C_OBJS_WO_LOG)  
71
72 #-------------------------------------------------------------#
73 #Clean macros             
74 #-------------------------------------------------------------#
75 clean:
76         @echo -e "$(COLOR_RED)Cleaning SSI from $(OBJ_DIR)$(REVERT_COLOR)"
77         $(Q)\rm -f $(LIB_DIR)/libmt.a $(C_OBJS_WO_LOG)
78
79 #**********************************************************************
80 #         End of file
81 #**********************************************************************