libpwquality: enable python3 binding
This commit is contained in:
parent
e13ca9707c
commit
9de5dbec62
3 changed files with 31 additions and 5 deletions
1
srcpkgs/libpwquality-python3
Symbolic link
1
srcpkgs/libpwquality-python3
Symbolic link
|
@ -0,0 +1 @@
|
||||||
|
libpwquality
|
12
srcpkgs/libpwquality/patches/pythoncross.patch
Normal file
12
srcpkgs/libpwquality/patches/pythoncross.patch
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
--- python/Makefile.am.orig
|
||||||
|
+++ python/Makefile.am
|
||||||
|
@@ -11,7 +11,7 @@
|
||||||
|
EXTRA_DIST = pwquality.c setup.py
|
||||||
|
|
||||||
|
all-local:
|
||||||
|
- CFLAGS="${CFLAGS} -fno-strict-aliasing" @PYTHONBINARY@ setup.py build --build-lib=.
|
||||||
|
+ LDSHARED="${CC} -pthread -shared" CFLAGS="${CFLAGS} -fno-strict-aliasing" @PYTHONBINARY@ setup.py build --build-lib=.
|
||||||
|
|
||||||
|
install-exec-local:
|
||||||
|
- CFLAGS="${CFLAGS} -fno-strict-aliasing" @PYTHONBINARY@ setup.py install --prefix=${DESTDIR}${prefix}
|
||||||
|
+ LDSHARED="${CC} -pthread -shared" CFLAGS="${CFLAGS} -fno-strict-aliasing" @PYTHONBINARY@ setup.py install --prefix=${DESTDIR}${prefix}
|
|
@ -1,20 +1,24 @@
|
||||||
# Template file for 'libpwquality'
|
# Template file for 'libpwquality'
|
||||||
pkgname=libpwquality
|
pkgname=libpwquality
|
||||||
version=1.4.0
|
version=1.4.0
|
||||||
revision=1
|
revision=2
|
||||||
build_style=gnu-configure
|
build_style=gnu-configure
|
||||||
configure_args="--disable-static --enable-pam --disable-python-bindings
|
configure_args="--disable-static --enable-pam --with-securedir=/usr/lib/security"
|
||||||
--with-securedir=/usr/lib/security"
|
|
||||||
hostmakedepends="libtool automake gettext-devel"
|
hostmakedepends="libtool automake gettext-devel"
|
||||||
makedepends="cracklib-devel pam-devel"
|
makedepends="cracklib-devel pam-devel python3-devel"
|
||||||
conf_files="/etc/security/pwquality.conf"
|
conf_files="/etc/security/pwquality.conf"
|
||||||
short_desc="Library for password quality checking and generating random passwords"
|
short_desc="Library for password quality checking and generating random passwords"
|
||||||
maintainer="Orphaned <orphan@voidlinux.org>"
|
maintainer="Orphaned <orphan@voidlinux.org>"
|
||||||
|
license="GPL-2.0-or-later"
|
||||||
homepage="https://github.com/libpwquality/libpwquality"
|
homepage="https://github.com/libpwquality/libpwquality"
|
||||||
license="GPL-2"
|
|
||||||
distfiles="${homepage}/releases/download/libpwquality-${version}/libpwquality-${version}.tar.bz2"
|
distfiles="${homepage}/releases/download/libpwquality-${version}/libpwquality-${version}.tar.bz2"
|
||||||
checksum=1de6ff046cf2172d265a2cb6f8da439d894f3e4e8157b056c515515232fade6b
|
checksum=1de6ff046cf2172d265a2cb6f8da439d894f3e4e8157b056c515515232fade6b
|
||||||
|
|
||||||
|
if [ "$CROSS_BUILD" ]; then
|
||||||
|
hostmakedepends+=" python3"
|
||||||
|
CFLAGS+=" -I${XBPS_CROSS_BASE}/${py3_inc}"
|
||||||
|
fi
|
||||||
|
|
||||||
pre_configure() {
|
pre_configure() {
|
||||||
autoreconf -fi
|
autoreconf -fi
|
||||||
}
|
}
|
||||||
|
@ -26,5 +30,14 @@ libpwquality-devel_package() {
|
||||||
vmove usr/include
|
vmove usr/include
|
||||||
vmove usr/lib/pkgconfig
|
vmove usr/lib/pkgconfig
|
||||||
vmove "usr/lib/*.so"
|
vmove "usr/lib/*.so"
|
||||||
|
vmove usr/share/man/man3
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
libpwquality-python3_package() {
|
||||||
|
lib32disabled=yes
|
||||||
|
short_desc+=" - Python3 bindings"
|
||||||
|
pkg_install() {
|
||||||
|
vmove "usr/lib/python3*"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue