O1 IP PORT configuration for CM .[Issue-Id: ODUHIGH-196]
[o-du/l2.git] / build / common / cu_stub.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 # This is makefile for CU STUB
18
19 include ../common/rsys_fancy.mak
20 include ../common/env.mak
21 COLOR=$(COLOR_RED)
22
23 SRC_DIR=$(ROOT_DIR)/src/cu_stub/
24 C_SRCS=$(wildcard $(SRC_DIR)/*.c)
25 C_OBJS=$(patsubst $(SRC_DIR)/%.c,$(OBJ_DIR)/%.o,$(C_SRCS))
26
27 # prepare the list of common header files
28 HDR_FILES+=$(wildcard $(CM_DIR)/env*.[hx])
29 HDR_FILES+=$(wildcard $(CM_DIR)/gen*.[hx])
30 HDR_FILES+=$(wildcard $(CM_DIR)/ssi*.[hx])
31 HDR_FILES+=$(wildcard $(CM_DIR)/cm*.[hx])
32
33
34 lib: $(LIB_DIR)/libcu.a
35 include $(COM_BUILD_DIR)/compile.mak
36
37 I_OPTS+=-I$(ROOT_DIR)/src/mt
38 I_OPTS+=-I$(ROOT_DIR)/src/codec_utils/common
39 I_OPTS+=-I$(ROOT_DIR)/src/codec_utils/F1AP
40 I_OPTS+=-I$(ROOT_DIR)/src/codec_utils/RRC
41
42 ifeq ($(O1_ENABLE),YES)
43 I_OPTS+=-I$(ROOT_DIR)/src/o1/o1_client
44 endif
45
46 #-------------------------------------------------------------#
47 #Linker macros
48 #-------------------------------------------------------------#
49 $(LIB_DIR)/libcu.a:$(C_OBJS) 
50                   @echo -e "Creating Archive $(COLOR) $@ $(REVERT_COLOR)"
51                   $(Q)ar -cr $(LIB_DIR)/libcu.a $(C_OBJS)
52
53 #-------------------------------------------------------------#
54 #Clean macros
55 #-------------------------------------------------------------#
56 clean:
57                   @echo -e "$(COLOR_RED)Cleaning CU STUB$(REVERT_COLOR)"
58                   @echo $(SRC_DIR) $(CM_DIR)
59                   $(Q)\rm -f $(LIB_DIR)/libcu.a $(C_OBJS) 
60
61 #**********************************************************************
62 #         End of file
63 #**********************************************************************