summaryrefslogtreecommitdiffstats
path: root/main/irssi/APKBUILD
blob: 71f06671778c958b99c1d8b4f95caa84801ce76e (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
48
49
50
51
52
53
54
55
56
# Maintainer: Kiyoshi Aman <kiyoshi.aman at gmail.com>
pkgname=irssi
pkgver=0.8.15
pkgrel=3
pkgdesc="A modular textUI IRC client with IPv6 support"
url="http://irssi.org/"
arch="all"
license='GPL'
depends=
makedepends="glib-dev openssl-dev ncurses-dev perl-dev pkgconfig"
source="http://irssi.org/files/irssi-${pkgver}.tar.bz2"
subpackages="$pkgname-doc $pkgname-dev $pkgname-perl $pkgname-proxy"

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

build() {
	cd "$_builddir"

	./configure --prefix=/usr \
	--sysconfdir=/etc \
	--mandir=/usr/share/man \
	--with-perl=module \
        --with-proxy
	make || return 1
	make DESTDIR="$pkgdir" install
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install
}

perl() {
	depends="$pkgname perl"
	pkgdesc="Irssi perl support and scripts"
	mkdir -p "$subpkgdir"/usr/share/irssi
	mv "$pkgdir"/usr/share/irssi/scripts "$subpkgdir"/usr/share/irssi/
	mkdir -p "$subpkgdir"/usr/lib/irssi/modules
	mv "$pkgdir"/usr/lib/irssi/modules/libfe_perl.* \
            "$pkgdir"/usr/lib/irssi/modules/libperl_core.* "$subpkgdir"/usr/lib/irssi/modules/
	mv "$pkgdir"/usr/lib/perl5 "$subpkgdir"/usr/lib/
	#need write permission when stripping
	chmod +w "$subpkgdir"/usr/lib/perl5/core_perl/auto/Irssi/TextUI/TextUI.so
	chmod +w "$subpkgdir"/usr/lib/perl5/core_perl/auto/Irssi/Irssi.so
	chmod +w "$subpkgdir"/usr/lib/perl5/core_perl/auto/Irssi/Irc/Irc.so
	chmod +w "$subpkgdir"/usr/lib/perl5/core_perl/auto/Irssi/UI/UI.so
}

proxy() {
        depends="$pkgname"
        pkgdesc="Irssi module for enabling bouncer-like functionality"
        mkdir -p "$subpkgdir"/usr/lib/irssi/modules
        mv "$pkgdir"/usr/lib/irssi/modules/libirc_proxy.* "$subpkgdir"/usr/lib/irssi/modules/
}

md5sums="1dcb3f511b88df94b0c996f36668c7da  irssi-0.8.15.tar.bz2"