pycryptodome: Don't use distutilscross

This commit is contained in:
Jernej Skrabec 2024-08-20 21:26:58 +02:00
parent d62cd7717d
commit 07e981c855

View File

@ -7,24 +7,21 @@ PKG_SHA256="35019dff66c25db80d0c739b9c7b59bb0f61551897681c6dbdbdd0f7198f780f"
PKG_LICENSE="BSD"
PKG_SITE="https://pypi.org/project/pycryptodome"
PKG_URL="https://github.com/Legrandin/${PKG_NAME}/archive/v${PKG_VERSION}.tar.gz"
PKG_DEPENDS_TARGET="toolchain Python3 distutilscross:host"
PKG_DEPENDS_TARGET="toolchain Python3"
PKG_LONGDESC="PyCryptodome is a self-contained Python package of low-level cryptographic primitives."
PKG_TOOLCHAIN="manual"
pre_configure_target() {
cd ${PKG_BUILD}
rm -rf .${TARGET_NAME}
export PYTHONXCPREFIX="${SYSROOT_PREFIX}/usr"
export LDSHARED="${CC} -shared"
}
make_target() {
python3 setup.py build --cross-compile
python_target_env python3 setup.py build
}
makeinstall_target() {
python3 setup.py install --root=${INSTALL} --prefix=/usr
exec_thread_safe python_target_env python3 setup.py install --root=${INSTALL} --prefix=/usr
# Remove SelfTest bloat
find ${INSTALL} -type d -name SelfTest -exec rm -fr "{}" \; 2>/dev/null || true