APKBUILD 1.76 KB
Newer Older
1
# Contributor: Valery Kartel <valery.kartel@gmail.com>
Natanael Copa's avatar
Natanael Copa committed
2 3
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=xfsprogs
4
pkgver=4.19.0
5
pkgrel=1
Natanael Copa's avatar
Natanael Copa committed
6
pkgdesc="XFS filesystem utilities"
7
url="http://xfs.org/index.php/Main_Page"
8
arch="all"
Natanael Copa's avatar
Natanael Copa committed
9
license="LGPL"
10
makedepends="linux-headers attr-dev util-linux-dev bash gzip python3"
11
options="!check"  # no test suite
12
subpackages="$pkgname-dev $pkgname-doc $pkgname-libs $pkgname-extra"
13
source="https://www.kernel.org/pub/linux/utils/fs/xfs/$pkgname/$pkgname-$pkgver.tar.gz
14
	fix-mmap.patch
15
	musl-MAP_SYNC-fix.patch
Natanael Copa's avatar
Natanael Copa committed
16 17
	"

18
builddir="$srcdir/$pkgname-$pkgver"
19

20
build() {
21
	cd "$builddir"
Natanael Copa's avatar
Natanael Copa committed
22 23
	export DEBUG=-DNDEBUG
	export OPTIMIZER="$CFLAGS"
24 25 26 27
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
Natanael Copa's avatar
Natanael Copa committed
28 29
		--sbindir=/sbin \
		--libexecdir=/usr/lib \
30 31
		--enable-gettext=no
	make SHELL=/bin/bash
32 33 34
}

package() {
35 36
	cd "$builddir"
	make -j1 DIST_ROOT="$pkgdir" install install-dev
37
	find "$pkgdir" -name *.la -delete
38 39 40 41 42
	mv "$pkgdir"/sbin "$pkgdir"/usr
	mkdir -p "$pkgdir"/sbin
	for i in mkfs.xfs fsck.xfs xfs_repair; do
		mv "$pkgdir"/usr/sbin/$i "$pkgdir"/sbin/
	done
43
	chown -R root:root "$pkgdir"/*
44 45 46
}

extra() {
47
	depends="$pkgname python3" # python3 for xfs_scrub_all
48
	pkgdesc="XFS filesystem extra utilities"
49
	mkdir -p "$subpkgdir"
50
	rm -rf "$pkgdir"/lib "$pkgdir"/usr/lib
51
	mv "$pkgdir"/usr "$subpkgdir"/
Natanael Copa's avatar
Natanael Copa committed
52
}
53

54
sha512sums="48ffcdb60a3bd332d5a5837824eb629759ec2d9015b94ac7ee7eef1dab507b2663f3223efc7885cbbe6ef6d721521953d32327688abd7d01f00c66ac5f5c9d29  xfsprogs-4.19.0.tar.gz
55 56
080161b211e20277e44f714961b36064536bb5cce72a6f93fef4996e296a3953d33c1a066ef371ccd5551622357105f9be9086ef917386f5d43f6a211b0bd7c9  fix-mmap.patch
bc7971207a296d8112f8993f6a266533135aae59a4438bb511f472931c37b8ce3033c597d67abbd3664f4405317aeb049e747c1811c9495c1a24d98935f799cc  musl-MAP_SYNC-fix.patch"