• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#/*
2# * Copyright (c) 2022 HiSilicon (Shanghai) Technologies CO., LIMITED.
3# * Licensed under the Apache License, Version 2.0 (the "License");
4# * you may not use this file except in compliance with the License.
5# * You may obtain a copy of the License at
6# *
7# * http://www.apache.org/licenses/LICENSE-2.0
8# *
9# * Unless required by applicable law or agreed to in writing, software
10# * distributed under the License is distributed on an "AS IS" BASIS,
11# * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# * See the License for the specific language governing permissions and
13# * limitations under the License.
14# */
15
16TOOL_DIR := $(shell pwd)/../tool/
17LAN_DIR = $(shell pwd)/../res/lan
18LAN_DIR_EXIST = $(shell if [ -d $(LAN_DIR) ]; then echo "exist"; else echo "notexist"; fi;)
19
20all: build
21build: lan_dir
22	rm -rf higv.bin
23	rm -rf *.c *.h
24	rm -rf xml2bin
25	cp $(TOOL_DIR)/xml2bin  ./
26	chmod +x xml2bin
27	./xml2bin -b ./higv.bin -e ./ -t c -x ./ -l ../res/lan
28	chmod +x ../res/lan/*.lang
29	cp *.bin ../ -rf
30	cp higv*.c ../ -rf
31	cp higv*.h ../ -rf
32clean:
33	rm -rf *.c *.h
34	rm -rf higv.bin
35	rm -rf xml2bin
36	rm -rf ../res/lan/*.lang
37
38.PHONY: lan_dir
39lan_dir:
40	if [ $(LAN_DIR_EXIST) = notexist ]; then  mkdir $(LAN_DIR);fi
41