aboutsummaryrefslogtreecommitdiffstats
path: root/testing/outils/APKBUILD
blob: 4dbb5bf13d2fb5e2df80b55a6a08e6a102162c60 (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
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Maintainer: Sören Tempel <soeren+alpine@soeren-tempel.net>
pkgname=outils
pkgver=0.3
pkgrel=0
pkgdesc="Port of some non-standard OpenBSD tools to Linux"
url="https://github.com/chneukirchen/outils"
arch="all"
license="BSD ISC"
depends=""
depends_dev=""
makedepends="openssl-dev linux-headers"
install=""
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/chneukirchen/$pkgname/archive/v$pkgver.tar.gz"

_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
	find "$_builddir"/src -type f -exec sed -i \{\} -e "s;u_int;uint;g" \
		-e "s;u_char;uint8_t;g" \; || return 1
	sed -i "$_builddir"/src/liboutils/sha1.c \
		-e "s;uint i;uint32_t i;" || return 1
}

build() {
	make CC="$CC" CFLAGS="$CFLAGS" \
		-C "$_builddir" || return 1
}

package() {
	make DESTDIR="$pkgdir" install \
		-C "$_builddir" || return 1

	# Don't conflict with main/coreutils
	rm -f "$pkgdir"/usr/bin/cksum || return 1
	rm -f "$pkgdir"/usr/share/man/man1/cksum.1 || return 1
}

md5sums="cb5d6274c78fd5dab8d5612668db08a3  outils-0.3.tar.gz"
sha256sums="de4c947f8b71513c01a07e7f8e0958a891d3484cea0485d29ec531fa75042d64  outils-0.3.tar.gz"
sha512sums="cd6d4bb92d1a867fbc9447b8ff993a21c65daa1b0ed46ea1911cdd461e466384b688cb5137dd62996c4980ef6fb9276651132703bbcdd1f61518dd68d2bcbbe4  outils-0.3.tar.gz"