59 lines
1.9 KiB
Bash
59 lines
1.9 KiB
Bash
# This is an example PKGBUILD file. Use this as a start to creating your own,
|
|
# and remove these comments. For more information, see 'man PKGBUILD'.
|
|
# NOTE: Please fill out the license field for your package! If it is unknown,
|
|
# then please put 'unknown'.
|
|
|
|
# Maintainer: Future Linux Team <future_linux@163.com>
|
|
pkgname=cracklib
|
|
pkgver=2.10.2
|
|
pkgrel=2
|
|
pkgdesc="Password Checking Library"
|
|
arch=('x86_64')
|
|
url="https://github.com/cracklib/cracklib"
|
|
license=('GPL-2.0-or-later')
|
|
depends=('glibc' 'zlib' 'bzip2' 'grep' 'gzip')
|
|
install=${pkgname}.install
|
|
source=(https://github.com/cracklib/cracklib/releases/download/v${pkgver}/${pkgname}-${pkgver}.tar.bz2
|
|
https://github.com/cracklib/cracklib/releases/download/v${pkgver}/${pkgname}-words-${pkgver}.bz2
|
|
cracklib.default.zh_CN.po)
|
|
sha256sums=(e157c78e6f26a97d05e04b6fe9ced468e91fa015cc2b2b7584889d667a958887
|
|
ec25ac4a474588c58d901715512d8902b276542b27b8dd197e9c2ad373739ec4
|
|
a976bdb6884fa50244373624f89a143275eac4bf3183e044a9b83521ae3d6c9b)
|
|
|
|
prepare() {
|
|
cd ${pkgname}-${pkgver}
|
|
|
|
install -p -m 644 ${srcdir}/cracklib.default.zh_CN.po po/zh_CN.po
|
|
|
|
autoreconf -fiv
|
|
}
|
|
|
|
build() {
|
|
cd ${pkgname}-${pkgver}
|
|
|
|
${CONFIGURE} \
|
|
--with-pic \
|
|
--without-python \
|
|
--disable-static \
|
|
--with-default-dict=/usr/share/cracklib/pw_dict
|
|
|
|
make -C po update-gmo
|
|
make
|
|
}
|
|
|
|
package() {
|
|
cd ${pkgname}-${pkgver}
|
|
|
|
make DESTDIR=${pkgdir} install
|
|
|
|
bunzip2 -dc ${srcdir}/${pkgname}-words-${pkgver}.bz2 > cracklib-words
|
|
install -vdm755 ${pkgdir}/usr/share/dict
|
|
install -vDm644 cracklib-words ${pkgdir}/usr/share/cracklib/cracklib-words
|
|
ln -s /usr/share/cracklib/cracklib-words ${pkgdir}/usr/share/dict/cracklib-words
|
|
ln -s /usr/share/cracklib/cracklib-words ${pkgdir}/usr/share/dict/words
|
|
ln -s /usr/share/cracklib/cracklib-small ${pkgdir}/usr/share/dict/cracklib-small
|
|
|
|
#install -vdm755 ${pkgdir}/usr/share/cracklib
|
|
|
|
}
|