73 lines
1.9 KiB
Bash
73 lines
1.9 KiB
Bash
# Maintainer: Alexey Pavlov <alexpux@gmail.com>
|
|
|
|
pkgname=('libssh2' 'libssh2-devel')
|
|
pkgver=1.11.0
|
|
pkgrel=1
|
|
pkgdesc="A library implementing the SSH2 protocol as defined by Internet Drafts"
|
|
url="https://libssh2.org/"
|
|
msys2_references=(
|
|
"cpe: cpe:/a:libssh2:libssh2"
|
|
)
|
|
groups=('libraries')
|
|
arch=('i686' 'x86_64')
|
|
license=('BSD')
|
|
makedepends=('openssl-devel' 'zlib-devel' 'autotools' 'gcc')
|
|
options=('!libtool')
|
|
source=("https://libssh2.org/download/${pkgname}-${pkgver}.tar.gz"{,.asc})
|
|
sha256sums=('3736161e41e2693324deb38c26cfdc3efe6209d634ba4258db1cecff6a5ad461'
|
|
'SKIP')
|
|
validpgpkeys=('914C533DF9B2ADA2204F586D78E11C6B279D5C91'
|
|
'27EDEAF22F3ABCEB50DB9A125CC908FDB71E12C2')
|
|
|
|
prepare() {
|
|
cd "${pkgname}-${pkgver}"
|
|
|
|
autoreconf -ivf
|
|
}
|
|
|
|
build() {
|
|
cd "${pkgname}-${pkgver}"
|
|
|
|
export MSYSTEM=CYGWIN
|
|
local CYGWIN_CHOST="${CHOST/-msys/-cygwin}"
|
|
./configure \
|
|
--prefix=/usr \
|
|
--build=${CYGWIN_CHOST} \
|
|
--enable-shared \
|
|
--enable-static \
|
|
--with-openssl \
|
|
--with-libz \
|
|
--without-libz-prefix \
|
|
--without-libssl-prefix \
|
|
--without-libgcrypt-prefix
|
|
make
|
|
make DESTDIR="${srcdir}/dest" install
|
|
}
|
|
|
|
check() {
|
|
cd "${pkgname}-${pkgver}"
|
|
make check || true
|
|
}
|
|
|
|
package_libssh2() {
|
|
pkgdesc="Multi-protocol file transfer library (runtime)"
|
|
depends=('ca-certificates' 'openssl' 'zlib')
|
|
groups=('libraries')
|
|
|
|
mkdir -p ${pkgdir}/usr/bin
|
|
cp -f ${srcdir}/dest/usr/bin/*.dll ${pkgdir}/usr/bin/
|
|
cp -rf ${srcdir}/dest/usr/share ${pkgdir}/usr/
|
|
install -Dm644 ${srcdir}/${pkgname}-${pkgver}/COPYING "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
|
|
}
|
|
|
|
package_libssh2-devel() {
|
|
pkgdesc="Libssh2 headers and libraries"
|
|
options=('staticlibs')
|
|
depends=("libssh2=${pkgver}" 'openssl-devel' 'zlib-devel')
|
|
groups=('development')
|
|
|
|
mkdir -p ${pkgdir}/usr
|
|
cp -rf ${srcdir}/dest/usr/include ${pkgdir}/usr/
|
|
cp -rf ${srcdir}/dest/usr/lib ${pkgdir}/usr/
|
|
}
|