Python API: Fixup of debian package after cFFI changes. 99/5799/6
authorOle Troan <ot@cisco.com>
Mon, 20 Mar 2017 20:38:37 +0000 (21:38 +0100)
committerEd Warnicke <hagbard@gmail.com>
Mon, 27 Mar 2017 18:58:11 +0000 (18:58 +0000)
Change-Id: I4c2a1a818f28d4c6cf52af45f3b7dbfa41d77ccb
Signed-off-by: Ole Troan <ot@cisco.com>
build-data/platforms.mk
build-root/deb/debian/control
build-root/deb/debian/rules
build-root/deb/debian/vpp-api-python.postinst [deleted file]
build-root/deb/debian/vpp-api-python.prerm [deleted file]

index 2351898..f491ee5 100644 (file)
@@ -59,10 +59,6 @@ install-deb: $(patsubst %,%-find-source,$(ROOT_PACKAGES))
        ./scripts/find-vpp-api-java-contents $(INSTALL_PREFIX)$(ARCH)   \
         deb/debian/vpp-api-java.install ;                              \
                                                                        \
-       : vpp-api-python package ;                                      \
-       ./scripts/find-vpp-api-python-contents $(INSTALL_PREFIX)$(ARCH) \
-        deb/debian/vpp-api-python.install ;                            \
-                                                                       \
        : bin package needs startup config ;                            \
        echo ../../src/vpp/conf/startup.conf /etc/vpp                   \
           >> deb/debian/vpp.install ;                                  \
index e90cfca..4ed42b3 100644 (file)
@@ -2,7 +2,7 @@ Source: vpp
 Section: net
 Priority: extra
 Maintainer: Cisco OpenVPP Packaging Team <bogus.address@cisco.com>
-Build-Depends: debhelper (>= 9), dh-systemd, dh-python, chrpath
+Build-Depends: debhelper (>= 9), dh-systemd, dh-python, chrpath, python-all
 Standards-Version: 3.9.4
 
 Package: vpp
index 7046105..3a1dd29 100755 (executable)
@@ -16,9 +16,15 @@ include /usr/share/dpkg/default.mk
 # package maintainers to append LDFLAGS
 #export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
 
+export PYBUILD_NAME = vpp-api-python
+export PYBUILD_DIR = ../../src/vpp-api/python
+export PYBUILD_DESTDIR_python2=debian/vpp-api-python/
+export PYBUILD_DISABLE_python2=test
+export PYBUILD_SYSTEM=distutils
+
 # main packaging script based on dh7 syntax
 %:
-       dh $@ --with systemd,python2
+       dh $@ --with systemd,python2 --buildsystem=pybuild
 
 override_dh_install:
        dh_install --exclude .git
diff --git a/build-root/deb/debian/vpp-api-python.postinst b/build-root/deb/debian/vpp-api-python.postinst
deleted file mode 100644 (file)
index ca1c856..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh -e
-
-# after installing python-api files
-python2_sitedir=$(python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")
-easy_install --install-dir=$python2_sitedir  -z $python2_sitedir/vpp_papi/vpp_papi-*.egg
diff --git a/build-root/deb/debian/vpp-api-python.prerm b/build-root/deb/debian/vpp-api-python.prerm
deleted file mode 100644 (file)
index e6d92df..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/bin/sh -e
-
-# before removing python-api files
-python2_sitedir=$(python -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")
-easy_install --install-dir=$python2_sitedir -mxNq vpp_papi
-
-# the egg has been copied during install
-rm $python2_sitedir/vpp_papi-*.egg