Make files clean-up
[o-du/l2.git] / build / common / asn_common.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 ASN
18
19 include ../common/rsys_fancy.mak
20 include ../common/env.mak
21 COLOR=$(COLOR_RED)
22
23 SRC_DIR=$(ROOT_DIR)/src/codec_utils/common
24 C_SRCS=$(wildcard $(SRC_DIR)/*.c)
25 C_OBJS=$(patsubst $(SRC_DIR)/%.c,$(OBJ_DIR)/%.o,$(C_SRCS))
26
27 lib: $(LIB_DIR)/libasn_common.a
28 include $(COM_BUILD_DIR)/compile.mak
29
30 #-------------------------------------------------------------#
31 #Linker macros
32 #-------------------------------------------------------------#
33 $(LIB_DIR)/libasn_common.a:$(C_OBJS)
34                   @echo -e "Creating Archive $(COLOR) $@ $(REVERT_COLOR)"
35                   $(Q)ar -cr $(LIB_DIR)/libasn_common.a $(C_OBJS)
36
37
38 #-------------------------------------------------------------#
39 #Clean macros
40 #-------------------------------------------------------------#
41 clean:
42                   @echo -e "$(COLOR_RED)Cleaning ASN$(REVERT_COLOR)"
43                   @echo $(SRC_DIR) $(CM_DIR)
44                   $(Q)\rm -f $(LIB_DIR)/libasn_common.a $(C_OBJS)
45
46 #**********************************************************************
47 #         End of file
48 #**********************************************************************