• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2022 Huawei Technologies Co., Ltd.
2# Licensed under the Mulan PSL v2.
3# You can use this software according to the terms and conditions of the Mulan PSL v2.
4# You may obtain a copy of Mulan PSL v2 at:
5#     http://license.coscl.org.cn/MulanPSL2
6# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR
7# IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR
8# PURPOSE.
9# See the Mulan PSL v2 for more details.
10ROOT_DIR := ../../../../../
11TOOLCHAIN_ROOT := $(ROOT_DIR)/tools/open_source/gcc-toolchains/aarch64/
12TOOLCHAIN_DIR := $(TOOLCHAIN_ROOT)/gcc-linaro-7.5.0-2019.12-x86_64_aarch64-linux-gnu/bin
13CC := $(TOOLCHAIN_DIR)/aarch64-linux-gnu-gcc
14AR := $(TOOLCHAIN_DIR)/aarch64-linux-gnu-ar
15
16CFLAGS := -Wall -Werror
17
18DEBUG ?= 0
19ifeq ($(DEBUG), 1)
20CFLAGS += -O0 -g
21CFLAGS += -DDEBUG
22endif
23
24RM := rm -f
25
26define rm_dirs
27if [ -d "$(1)" ] ; then rmdir --ignore-fail-on-non-empty $(1) ; fi
28endef
29