summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1ea871c)
raw | patch | inline | side by side (parent: 1ea871c)
author | Ajay Jayaraj <ajayj@ti.com> | |
Mon, 25 Jun 2018 21:10:25 +0000 (16:10 -0500) | ||
committer | Ajay Jayaraj <ajayj@ti.com> | |
Mon, 25 Jun 2018 21:15:30 +0000 (16:15 -0500) |
Update Makefile(s) in the examples directory to use tidl-api headers and
libraries from /usr/share/ti/tidl/tidl_api.
(MCT-1005)
libraries from /usr/share/ti/tidl/tidl_api.
(MCT-1005)
examples/Makefile | patch | blob | history | |
examples/make.common | patch | blob | history | |
makefile | [new file with mode: 0644] | patch | blob |
readme.md | patch | blob | history | |
tidl_api/make.buildid | patch | blob | history |
diff --git a/examples/Makefile b/examples/Makefile
index 512e2edbb6984fdafb8afbe2bdc4b2bb9cba1933..69c708600066f1dbd22ac98d8b7a7552ddba0dda 100644 (file)
--- a/examples/Makefile
+++ b/examples/Makefile
.PHONY: clean
clean:
$(call make_in_dirs, $(DIRS), clean)
-
-realclean: clean
- make -C ../tidl_api clean
diff --git a/examples/make.common b/examples/make.common
index aca5ece94e7fb79123d837f2efd11708936ed1e0..e0111173572380e0ddc4c2c2ec0419829204ce25 100644 (file)
--- a/examples/make.common
+++ b/examples/make.common
AR = ar
CP = cp
-TIDL_API_DIR = ../../tidl_api
+TIDL_API_DIR ?= ${TARGET_ROOTDIR}/usr/share/ti/tidl/tidl_api
TIDL_API_LIB_NAME = tidl_api.a
TIDL_API_LIB = $(TIDL_API_DIR)/$(TIDL_API_LIB_NAME)
TIDL_API_LIB_IMGUTIL_NAME = tidl_imgutil.a
all: $(EXE)
-.PHONY: $(TIDL_API_LIB)
-$(TIDL_API_LIB):
- $(MAKE) -C $(TIDL_API_DIR) $(TIDL_API_LIB_NAME)
-
-.PHONY: $(TIDL_API_LIB_IMGUTIL)
-$(TIDL_API_LIB_IMGUTIL):
- $(MAKE) -C $(TIDL_API_DIR) $(TIDL_API_LIB_IMGUTIL_NAME)
-
-realclean: clean
- $(MAKE) -C $(TIDL_API_DIR) clean
- $(MAKE) -C $(TIDL_API_DIR)/dsp clean
-
clean::
$(RM) -f $(EXE) stats_tool_out.* *.out
diff --git a/makefile b/makefile
--- /dev/null
+++ b/makefile
@@ -0,0 +1,55 @@
+
+# Copyright (c) 2018 Texas Instruments Incorporated - http://www.ti.com/
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+# * Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# * Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+# * Neither the name of Texas Instruments Incorporated nor the
+# names of its contributors may be used to endorse or promote products
+# derived from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+# THE POSSIBILITY OF SUCH DAMAGE.
+
+
+# makefile for TI internal use
+
+ifneq (,$(findstring 86, $(shell uname -m)))
+DEST_DIR ?= $(CURDIR)/install/am57
+endif
+
+INSTALL_DIR_API = $(DEST_DIR)/usr/share/ti/tidl
+INSTALL_DIR_EXAMPLES = $(DEST_DIR)/usr/share/ti/examples/tidl
+
+CP_ARGS=-Prf --preserve=mode,timestamps --no-preserve=ownership
+
+build-api:
+ $(MAKE) -C tidl_api
+
+build-examples: install-api
+ $(MAKE) -C examples
+
+install-api: build-api
+ mkdir -p $(INSTALL_DIR_API)
+ cp $(CP_ARGS) tidl_api $(INSTALL_DIR_API)/
+
+install-examples: build-examples
+ mkdir -p $(INSTALL_DIR_EXAMPLES)
+ cp $(CP_ARGS) examples/* $(INSTALL_DIR_EXAMPLES)/
+
+clean:
+ $(MAKE) -C tidl_api clean
diff --git a/readme.md b/readme.md
index 91f447ca65cf73ba1fe93cff4974b898c15e3ab0..092f09b7e4670107c000555617f96af32999a0e4 100644 (file)
--- a/readme.md
+++ b/readme.md
TI Deep Learning (TIDL) API
---------------------------
-TIDL API brings Deep Learning to the edge and enables Linux applications to leverage TI’s proprietary CNN/DNN implementation on Deep Learning Accelerators (DLAs) and C66x DSPs in AM57x SoCs. It requires OpenCL v1.1.15.1 or newer. Refer the User's Guide for details: http://software-dl.ti.com/mctools/esd/docs/tidl-api/index.html
+TIDL API brings Deep Learning to the edge and enables Linux applications to leverage TI’s proprietary CNN/DNN implementation on EVEs and C66x DSPs in AM57x SoCs. It requires OpenCL v1.1.15.1 or newer. Refer the User's Guide for details: http://software-dl.ti.com/mctools/esd/docs/tidl-api/index.html
diff --git a/tidl_api/make.buildid b/tidl_api/make.buildid
index d5658e948c2681eeafea3a5a7841120a54cdf608..600c3c0212ff8d4930e680c8d52d5f7cea394b7f 100644 (file)
--- a/tidl_api/make.buildid
+++ b/tidl_api/make.buildid
MAJOR_VER=1
MINOR_VER=0
PATCH_VER=0
+BUILD_VER=2
ifeq ($(shell git rev-parse --short HEAD 2>&1 1>/dev/null; echo $$?),0)
BUILD_SHA?=$(shell git rev-parse --short HEAD)
.PHONY: $(BUILD_ID)
BUILD_ID := -D_BUILD_VER=$(shell echo "" | \
- awk '{ printf ("%02d.%02d.%02d", $(MAJOR_VER), \
- $(MINOR_VER), $(PATCH_VER)); }') \
+ awk '{ printf ("%02d.%02d.%02d.%02d", $(MAJOR_VER), \
+ $(MINOR_VER), $(PATCH_VER), $(BUILD_VER)); }') \
-D_BUILD_SHA=$(BUILD_SHA)