aboutsummaryrefslogtreecommitdiffstats
path: root/testing/gnu-libiconv/APKBUILD
blob: 7c9330d4bffeab2bf3b6946d73549384bb02d95d (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=gnu-libiconv
pkgver=1.15
pkgrel=0
pkgdesc="GNU charset conversion library for libc which doesn't implement it"
url="http://www.gnu.org/software/libiconv"
arch="all"
license='LGPL'
depends=""
source="http://ftp.gnu.org/pub/gnu/libiconv/libiconv-$pkgver.tar.gz"
subpackages="$pkgname-doc $pkgname-dev"

builddir="$srcdir"/libiconv-$pkgver
build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--mandir=/usr/share/man \
		--disable-nls \
		--disable-static \
		|| return 1
	# work around rpath issue
	sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
	sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
	make || return 1
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir/" install
	rm "$pkgdir"/usr/lib/charset.alias

	# move headers so they dont clash with libc headers
	mkdir "$pkgdir"/usr/include/gnu-libiconv
	mv "$pkgdir"/usr/include/*.h "$pkgdir"/usr/include/gnu-libiconv
	mv "$pkgdir"/usr/bin/iconv "$pkgdir"/usr/bin/gnu-iconv

}

sha512sums="1233fe3ca09341b53354fd4bfe342a7589181145a1232c9919583a8c9979636855839049f3406f253a9d9829908816bb71fd6d34dd544ba290d6f04251376b1a  libiconv-1.15.tar.gz"