From 3396e861b697184b5ba9a43e48b8fb7e6246b253 Mon Sep 17 00:00:00 2001 From: Jaeyun Jung Date: Sat, 26 Jan 2019 12:15:27 +0900 Subject: [PATCH] [Build/Deb] enable tensorflow protobuf packaging done, enable tensorflow option. Signed-off-by: Jaeyun Jung --- debian/control | 10 ++++++---- debian/rules | 10 ++++++++-- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/debian/control b/debian/control index 00ed995..9ff65c4 100644 --- a/debian/control +++ b/debian/control @@ -2,12 +2,14 @@ Source: nnstreamer Section: libs Priority: optional Maintainer: MyungJoo Ham -Build-Depends: gcc (>=5), ninja-build, meson (>=0.40), libgstreamer1.0-dev, libgstreamer-plugins-base1.0-dev, libglib2.0-dev, - libgtest-dev, +Build-Depends: gcc (>=5), ninja-build, meson (>=0.40), debhelper (>=9), + libgstreamer1.0-dev, libgstreamer-plugins-base1.0-dev, libglib2.0-dev, gstreamer1.0-tools, gstreamer1.0-plugins-base, gstreamer1.0-plugins-good, - libpng-dev, tensorflow-lite-dev, tensorflow-dev [amd64 arm64], libopencv-dev, - liborc-0.4-dev, ssat, python, python-numpy, libprotobuf-dev [amd64 arm64] + libgtest-dev, ssat, libpng-dev, libopencv-dev, liborc-0.4-dev, + python, python-numpy, + tensorflow-lite-dev, + tensorflow-dev [amd64 arm64], python2.7-dev, libprotobuf-dev [amd64 arm64] Standards-Version: 3.9.6 Homepage: https://github.com/nnsuite/nnstreamer diff --git a/debian/rules b/debian/rules index b349c5b..40b01e3 100755 --- a/debian/rules +++ b/debian/rules @@ -15,6 +15,13 @@ ROOT_DIR:=$(shell pwd) export DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) +export DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH) + +ifneq ($(filter $(DEB_HOST_ARCH),amd64 arm64),) +enable_tf=true +else +enable_tf=false +endif %: dh $@ --parallel @@ -24,8 +31,7 @@ override_dh_auto_clean: override_dh_auto_configure: mkdir -p build - meson --buildtype=plain --werror --prefix=/usr --libdir=lib/$(DEB_HOST_MULTIARCH) --bindir=lib/nnstreamer/bin --includedir=include -Dinstall-example=true -Denable-tensorflow=false build -# @todo @hello-ahn Enablet tensorflow after the update of protobuf packaging + meson --buildtype=plain --werror --prefix=/usr --libdir=lib/$(DEB_HOST_MULTIARCH) --bindir=lib/nnstreamer/bin --includedir=include -Dinstall-example=true -Denable-tensorflow=$(enable_tf) build override_dh_auto_build: ninja -C build -- 2.7.4