Update debian/rules for ION allocator
Change-Id: I0fff88ce4af802f314b94b346fb4085bef5ac715
diff --git a/debian/control b/debian/control
index 5b38594..cdf7f23 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@
Maintainer: Coral <coral-support@google.com>
Section: python
Priority: optional
-Build-Depends: dh-python, python3-setuptools, python3-all, debhelper (>= 9), libgstreamer-plugins-base1.0-dev, pkg-config, librsvg2-dev, libcairo2-dev
+Build-Depends: dh-python, python3-setuptools, python3-all, debhelper (>= 9), libgstreamer-plugins-base1.0-dev, pkg-config, librsvg2-dev, libcairo2-dev, libdrm-dev
Standards-Version: 3.9.8
Homepage: https://coral.ai/
diff --git a/debian/rules b/debian/rules
index 2d838db..f30bbde 100755
--- a/debian/rules
+++ b/debian/rules
@@ -4,10 +4,24 @@
PLUGINSDIR := $(shell pkg-config --variable=pluginsdir gstreamer-1.0)
PY_DESTDIR := debian/python3-edgetpuvision/$(PLUGINSDIR)/python
SO_DESTDIR := debian/gstreamer1.0-plugins-coral/$(PLUGINSDIR)
-SO_SRCS := $(addprefix plugins/, gstcoral.c gstglbox.c gstglsvgoverlay.c)
SO_DEST := $(SO_DESTDIR)/libgstcoral.so
-SO_DEPS := gstreamer-plugins-base-1.0 gstreamer-video-1.0 gstreamer-gl-1.0 \
- librsvg-2.0 cairo
+SO_CFLAGS := -shared -Wno-deprecated-declarations -Wl,--no-undefined
+SO_DEPS := \
+ gstreamer-1.0 \
+ gstreamer-allocators-1.0 \
+ gstreamer-video-1.0 \
+ gstreamer-plugins-base-1.0 \
+ gstreamer-gl-1.0 \
+ librsvg-2.0 \
+ cairo \
+ gobject-2.0 \
+ glib-2.0 \
+ libdrm
+SO_SRCS := $(addprefix plugins/, \
+ gstcoral.c \
+ gstglbox.c \
+ gstglsvgoverlay.c \
+ gstionallocator.c)
export PYBUILD_NAME=edgetpuvision
@@ -20,5 +34,6 @@
install -g 0 -o 0 plugins/python/*.py $(PY_DESTDIR)
install -d $(SO_DESTDIR)
- $(DEB_HOST_GNU_TYPE)-gcc `$(DEB_HOST_GNU_TYPE)-pkg-config --libs --cflags $(SO_DEPS)` \
- $(CFLAGS) -shared -o $(SO_DEST) -DCORAL_VERSION=$(DEB_VERSION) $(SO_SRCS)
+ $(DEB_HOST_GNU_TYPE)-gcc $(CFLAGS) $(SO_CFLAGS) -o $(SO_DEST) \
+ -DCORAL_VERSION=$(DEB_VERSION) $(SO_SRCS) \
+ `$(DEB_HOST_GNU_TYPE)-pkg-config --libs --cflags $(SO_DEPS)`