aports

Custom Alpine Linux aports

git clone https://git.8pit.net/aports.git

 1# Contributor: Leo <thinkabit.ukim@gmail.com>
 2# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
 3# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
 4pkgname=mandoc
 5pkgver=1.14.6
 6pkgrel=18
 7pkgdesc="mandoc (formerly mdocml) UNIX manpage compiler toolset"
 8url="https://mandoc.bsd.lv/"
 9arch="all"
10license="ISC"
11# Requires a BusyBox version which accept's -T in less(1).
12depends="busybox>=1.38.0-r5"
13makedepends="zlib-dev"
14checkdepends="perl"
15install="$pkgname-apropos.post-deinstall"
16replaces="mdocml"
17subpackages="$pkgname-doc $pkgname-dev $pkgname-apropos $pkgname-soelim"
18source="https://mandoc.bsd.lv/snapshots/mandoc-$pkgver.tar.gz
19	fix-core-dump-tag-put-assertion.patch
20	shared-libmandoc.patch
21	outdated-warn-disable.patch
22	empty-title.patch
23	$pkgname.cron
24	"
25
26# higher than community/man-db for this
27provides="doc-provider mdocml=$pkgver-r$pkgrel"
28provider_priority=100
29
30prepare() {
31	default_prepare
32
33	cat >configure.local<<-__EOF__
34	PREFIX=/usr
35	MANDIR=/usr/share/man
36	LIBDIR=/usr/lib
37	CFLAGS="$CFLAGS"
38	LDFLAGS="$LDFLAGS"
39	UTF8_LOCALE="en_US.UTF-8"
40	MANPATH_DEFAULT="/usr/share/man:/usr/local/man:/usr/local/share/man"
41	MANPATH_BASE="/usr/share/man"
42	LN="ln -sf"
43__EOF__
44}
45
46build() {
47	./configure
48	[ "$(awk '/HAVE_LESS_T/ {print $3}' config.h)" -eq 1 ] || \
49		die "Failed to correctly detect tagfile support"
50	make
51}
52
53check() {
54	LD_LIBRARY_PATH="$builddir" make regress
55}
56
57package() {
58	make -j1 DESTDIR="$pkgdir" base-install lib-install
59}
60
61apropos() {
62	pkgdesc="makewhatis/whatis and apropos tools and index"
63	amove usr/bin/apropos usr/bin/whatis usr/sbin/makewhatis
64	install -Dm755 "$srcdir"/$pkgname.cron \
65		"$subpkgdir"/etc/periodic/daily/makewhatis
66}
67
68soelim() {
69	pkgdesc="so elimination tool"
70	depends=""
71	amove usr/bin/soelim
72}
73
74sha512sums="
7554286070812a47b629f68757046d3c9a1bdd2b5d1c3b84a5c8e4cb92f1331afa745443f7238175835d8cfbe5b8dd442e00c75c3a5b5b8f8efd8d2ec8f636dad4  mandoc-1.14.6.tar.gz
765b71606015fab924612a6c22ec46ac0df06b28cf1c92e1ff24829aec8c206fb22bd2961c928d1a1f056fa7064b22f016dc0ece5f4d1dd28b6ce562417c505fed  fix-core-dump-tag-put-assertion.patch
77b512bcb8bae11853a3006e2122d7e652806d4bf2234638d8809fd823375b5b0bd590f7d6a90412baffcc3b7b6a0f197a10986728a70f24fe628f91bfb651d266  shared-libmandoc.patch
786eda39920cccb1238b104bb90ac4be2c32883897c72363560d8d39345819cdeff535680e78396052b2b8f981e169ad9b3c30da724def80a1501785d82ce7fa25  outdated-warn-disable.patch
790bad44e3640f5521df6bb510a7fe9053bebf3df9213ca8f249abbdf1144eafd533d67c4f22e34cd86e53e12648a2cd1cf6d873892640d7c82ce93bbc382c303c  empty-title.patch
801af9627ee519ecf7d4962db52c83b28f3eb4e9fc6bf38e674bd5e17b21076c3c74c9eed2a1161812f8ac0c75471986b73fcf0acfc7065bc2c15280e1d696a00b  mandoc.cron
81"