void-packages/srcpkgs/libgit2/template

44 lines
1.1 KiB
Bash

# Template file for 'libgit2'
pkgname=libgit2
version=1.6.5
revision=1
build_style=cmake
configure_args="-DENABLE_REPRODUCIBLE_BUILDS=ON -DUSE_SSH=ON -DUSE_HTTP_PARSER=system"
hostmakedepends="python3 pkg-config"
makedepends="zlib-devel openssl-devel http-parser-devel libssh2-devel"
short_desc="Git linkable library"
maintainer="Orphaned <orphan@voidlinux.org>"
license="custom:GPL-2.0-or-later WITH GCC-exception-2.0"
homepage="https://libgit2.org"
distfiles="https://github.com/libgit2/libgit2/archive/refs/tags/v${version}.tar.gz"
checksum=0f09dd49e409913c94df00eeb5b54f8b597905071b454c7f614f8c6e1ddb8d75
if [ "$XBPS_CHECK_PKGS" ]; then
configure_args+=" -DBUILD_TESTS=ON"
else
configure_args+=" -DBUILD_TESTS=OFF"
fi
CFLAGS="-D_LARGE_FILE_SOURCE=1 -D_FILE_OFFSET_BITS=64"
post_patch() {
# no online tests
vsed \
-i tests/libgit2/CMakeLists.txt \
-e '/-sonline/s/^/#/'
}
post_install() {
vlicense COPYING
}
libgit2-devel_package() {
depends="${makedepends} ${sourcepkg}>=${version}_${revision}"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
vmove usr/lib/pkgconfig
vmove "usr/lib/*.so"
}
}