python_install_dir
authorKees Cook <kees@debian.org>
Thu, 18 Jul 2019 22:03:34 +0000 (23:03 +0100)
committerFelix Geyer <fgeyer@debian.org>
Thu, 18 Jul 2019 22:03:34 +0000 (23:03 +0100)
From 830929096665eab2b910d676ccab1df90908cb02 Mon Sep 17 00:00:00 2001
From: Felix Geyer <debfx@fobos.de>
Date: Mon, 15 Jul 2019 21:12:05 +0200
Subject: [PATCH] Install the python extension to the root package dir

Commit 8ad3638ea9023c3948976dfadebd1554380a31c9 effectively added libseccomp/
to the install path of the python extension.
This changed the import module name from "seccomp" to "libseccomp.seccomp",
breaking existing users.

Revert the install path like it was before 2.4.0

Signed-off-by: Felix Geyer <debfx@fobos.de>
Gbp-Pq: Name python_install_dir.patch

src/python/Makefile.am

index 3a34b0a898352382c865e8c224a1d9a63bea50ee..f71ec24f801e6d0fbd63be446d5c6cd586551bac 100644 (file)
@@ -40,12 +40,12 @@ build: ../libseccomp.la libseccomp.pxd seccomp.pyx setup.py
        ${PY_BUILD} && touch build
 
 install-exec-local: build
-       ${PY_INSTALL} --install-lib=${DESTDIR}/${pkgpythondir} \
-               --record=${DESTDIR}/${pkgpythondir}/install_files.txt
+       ${PY_INSTALL} --install-lib=${DESTDIR}/${pyexecdir} \
+               --record=${DESTDIR}/${pyexecdir}/install_files.txt
 
 uninstall-local:
-       cat ${DESTDIR}/${pkgpythondir}/install_files.txt | xargs ${RM} -f
-       ${RM} -f ${DESTDIR}/${pkgpythondir}/install_files.txt
+       cat ${DESTDIR}/${pyexecdir}/install_files.txt | xargs ${RM} -f
+       ${RM} -f ${DESTDIR}/${pyexecdir}/install_files.txt
 
 clean-local:
        [ ${srcdir} == ${builddir} ] || ${RM} -f ${builddir}/seccomp.pyx