summaryrefslogtreecommitdiff
path: root/main/bash-completion/APKBUILD
blob: d8dc08a14e9e44e18ae1a1478ec5499f4522e051 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Contributor: Kiyoshi Aman <kiyoshi.aman@gmail.com>
# Maintainer: Lucas Ramage <ramage.lucas@openmailbox.org>
pkgname=bash-completion
pkgver=2.7
pkgrel=3
pkgdesc="Command-line tab-completion for bash"
url="https://github.com/scop/bash-completion"
arch="noarch"
license="GPL-2.0-or-later"
depends="bash"
depends_dev=
makedepends="$depends_dev"
install=""
source="https://github.com/scop/${pkgname}/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.xz"
builddir="$srcdir"/$pkgname-$pkgver

# Provided with util-linux and networkmanager:
_conflicting="
	cal
	chsh
	dmesg
	eject
	hd
	hexdump
	hwclock
	ionice
	look
	ncal
	newgrp
	renice
	rfkill
	rtcwake
	su
	nmcli
	umount
	mount
	"

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var
	make
}

check() {
	cd "$builddir"
	make check
}

package() {
	cd "$builddir"
	make -j1 DESTDIR="$pkgdir" install

	mkdir -p "$pkgdir"/usr/share/doc/$pkgname/
	install -m644 AUTHORS CHANGES CONTRIBUTING.md README.md \
		"$pkgdir"/usr/share/doc/$pkgname/

	cd "$pkgdir"/usr/share/bash-completion/completions
	for c in $_conflicting; do
		rm -f $c
	done
}

sha512sums="514709ad2e5f6bd4e20027c7049a1144c1854a37b653d5c11fad1cdf7a46d0e1afca725d6ce75d49691149e0de57be85747f704ac1c429ef4cea114bfbff8fcd  bash-completion-2.7.tar.xz"