aboutsummaryrefslogtreecommitdiffstats
path: root/main/grep/APKBUILD
blob: d55345e1e1c3bfc058e30a43103a12368645597b (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
# Contributor: Michael Mason <ms13sp@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=grep
pkgver=2.19
pkgrel=0
pkgdesc="Searches input files for lines containing a match to a specified pattern"
url="http://www.gnu.org/software/grep/grep.html"
arch="all"
license="GPL"
depends=
makedepends="pcre-dev"
install=
subpackages="$pkgname-doc"
source="http://mirrors.kernel.org/gnu/$pkgname/$pkgname-$pkgver.tar.xz"

_builddir="$srcdir/$pkgname-$pkgver"

prepare() {
	cd "$_builddir"
}

build() {
	cd "$_builddir"

	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--disable-nls \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
	rm -rf "$pkgdir"/usr/lib/charset.alias
	rmdir -p "$pkgdir"/usr/lib 2>/dev/null
	return 0
}

md5sums="ac732142227d9fe9567d71301e127979  grep-2.19.tar.xz"
sha256sums="6388295be48cfcaf7665d9cd3914e6625ea000e9414132bfefd45cf1d8eec34d  grep-2.19.tar.xz"
sha512sums="1672ffc64dcb6085d18ac829b8af30d74fbc84d895869a0f152f103bc44c40a7db43c69cf0ee9e3f923cc1eddd68803220f041cc919663efcbdd697a3d4ef15e  grep-2.19.tar.xz"