mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-24 19:55:26 +03:00
87 lines
2.6 KiB
Text
87 lines
2.6 KiB
Text
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
|
|
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
|
|
pkgname=mercurial
|
|
pkgver=5.7
|
|
pkgrel=0
|
|
pkgdesc="Scalable distributed SCM tool"
|
|
url="https://www.mercurial-scm.org/"
|
|
arch="all !x86" # tests fails on x86 https://bz.mercurial-scm.org/show_bug.cgi?id=6506
|
|
license="GPL-2.0-or-later"
|
|
depends="python3"
|
|
makedepends="python3-dev"
|
|
checkdepends="bash unzip diffutils xz sqlite gettext py3-docutils"
|
|
subpackages="
|
|
$pkgname-doc
|
|
$pkgname-vim:vim:noarch
|
|
$pkgname-zsh-completion:zshcomp:noarch
|
|
$pkgname-bash-completion:bashcomp:noarch
|
|
"
|
|
source="https://www.mercurial-scm.org/release/mercurial-$pkgver.tar.gz
|
|
blacklist.txt
|
|
tests-include-deprecation-warning-in-expected-output.patch
|
|
"
|
|
case "$CARCH" in
|
|
ppc64le|mips64|aarch64|armv7|armhf) options="$options !check" ;; # around 400 of 919 tests time out
|
|
esac
|
|
case "$CARCH" in
|
|
# Oxidation, limited by Rust
|
|
x86_64|armv7|armhf|aarch64|x86|ppc64le) makedepends="$makedepends cargo" ;;
|
|
esac
|
|
|
|
# secfixes:
|
|
# 4.9-r0:
|
|
# - CVE-2019-3902
|
|
|
|
build() {
|
|
HGPYTHON3=1 python3 setup.py build
|
|
}
|
|
|
|
check() {
|
|
make PYTHON=python3 TESTFLAGS=--blacklist="$srcdir/blacklist.txt" tests
|
|
}
|
|
|
|
package() {
|
|
HGPYTHON3=1 python3 setup.py install --root="$pkgdir"
|
|
install -m755 contrib/hgk contrib/hg-ssh hgeditor "$pkgdir"/usr/bin
|
|
|
|
local man
|
|
for man in doc/*.?; do
|
|
install -Dm644 "$man" \
|
|
"$pkgdir"/usr/share/man/man${man##*.}/${man##*/}
|
|
done
|
|
}
|
|
|
|
vim() {
|
|
depends=""
|
|
pkgdesc="Vim syntax for $pkgname"
|
|
install_if="vim $pkgname=$pkgver-r$pkgrel"
|
|
|
|
cd "$builddir"/contrib/vim/
|
|
mkdir -p "$subpkgdir"/usr/share/vim/vimfiles/syntax/
|
|
install -Dm644 HGAnnotate.vim hgtest.vim \
|
|
"$subpkgdir"/usr/share/vim/vimfiles/syntax/
|
|
}
|
|
|
|
zshcomp() {
|
|
depends=""
|
|
pkgdesc="Zsh completion for $pkgname"
|
|
install_if="$pkgname=$pkgver-r$pkgrel zsh"
|
|
|
|
install -Dm644 "$builddir"/contrib/zsh_completion \
|
|
"$subpkgdir"/usr/share/zsh/site-functions/_$pkgname
|
|
}
|
|
|
|
bashcomp() {
|
|
depends=""
|
|
pkgdesc="Bash completion for $pkgname"
|
|
install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
|
|
|
|
install -Dm644 "$builddir"/contrib/bash_completion \
|
|
"$subpkgdir"/usr/share/bash-completion/completions/$pkgname
|
|
}
|
|
|
|
sha512sums="
|
|
ecf1fb38e372acb5e29998cbe1105ecfb846a2bb43254419c89395c52fd28c37abe8eb850584f32f6ef53b539e6a7ef5a4dae10b816b747d20c6b0b4933f4b62 mercurial-5.7.tar.gz
|
|
93612774fd8c47920232440a516b68d121ac66c5c22d86d7220f50556ad79f97b8139dda58c1af04050b7677aff03ed51f4cae0c3207296fb5f2a03b6d4941c8 blacklist.txt
|
|
a86d9008ae952f5957b52492d20a22a493b7b7f810ccb28b54d88780c1a22af4c006f6ee60e9e8c43fe33a9dc0b89c940aa20e85a379026dc2b02218bf92d5c6 tests-include-deprecation-warning-in-expected-output.patch
|
|
"
|