mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-24 11:16:51 +00:00
libgpiod: build python bindings
This commit is contained in:
parent
8fa330dc87
commit
bf6e76c2c8
@ -7,9 +7,21 @@ PKG_SHA256="ae35329db7027c740e90c883baf27c26311f0614e6a7b115771b28188b992aec"
|
||||
PKG_LICENSE="GPLv2+"
|
||||
PKG_SITE="https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git/about/"
|
||||
PKG_URL="https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git/snapshot/libgpiod-${PKG_VERSION}.tar.gz"
|
||||
PKG_DEPENDS_TARGET="toolchain"
|
||||
PKG_DEPENDS_TARGET="toolchain Python3 distutilscross:host"
|
||||
PKG_LONGDESC="Tools for interacting with the linux GPIO character device."
|
||||
PKG_TOOLCHAIN="autotools"
|
||||
PKG_BUILD_FLAGS="+pic"
|
||||
PKG_BUILD_FLAGS="+pic -sysroot"
|
||||
|
||||
PKG_CONFIGURE_OPTS_TARGET="--enable-tools --disable-shared"
|
||||
|
||||
post_make_target() {
|
||||
(
|
||||
export PYTHONXCPREFIX="${SYSROOT_PREFIX}/usr"
|
||||
export LDFLAGS+=" -L${PKG_BUILD}/.${TARGET_NAME}/lib/.libs"
|
||||
export LDSHARED="${CC} -shared"
|
||||
export CFLAGS+=" -fcommon -I${PKG_BUILD}/include"
|
||||
export CPPFLAGS="${TARGET_CPPFLAGS} -I${SYSROOT_PREFIX}/usr/include/${PKG_PYTHON_VERSION}"
|
||||
cd ../bindings/python
|
||||
python3 setup.py build
|
||||
)
|
||||
}
|
||||
|
@ -0,0 +1,11 @@
|
||||
--- a/bindings/python/setup.py 2024-11-12 14:29:25.000000000 +0100
|
||||
+++ b/bindings/python/setup.py 2025-01-05 17:00:00.000000000 +0100
|
||||
@@ -8,7 +8,7 @@
|
||||
from setuptools.command.build_ext import build_ext as orig_build_ext
|
||||
from setuptools.command.sdist import log
|
||||
from setuptools.command.sdist import sdist as orig_sdist
|
||||
-from setuptools.errors import BaseError
|
||||
+from distutils.errors import DistutilsError as BaseError
|
||||
|
||||
LINK_SYSTEM_LIBGPIOD = getenv("LINK_SYSTEM_LIBGPIOD") == "1"
|
||||
LIBGPIOD_MINIMUM_VERSION = "2.1"
|
Loading…
x
Reference in New Issue
Block a user