summaryrefslogtreecommitdiffstats
path: root/main/coova-chilli/APKBUILD
blob: e955287b3ac6b6b7e280ac136327efac0bf61ad6 (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
# Contributor: grharry
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=coova-chilli
pkgver=1.2.9
pkgrel=0
pkgdesc="CoovaChilli is an open source access controller for wireless LAN"
url="http://www.coova.org/"
arch="all"
license="GPL"
depends=
makedepends="perl openssl-dev autoconf automake libtool"
install= 
subpackages="$pkgname-doc $pkgname-dev"
source="http://ap.coova.org/chilli/coova-chilli-$pkgver.tar.gz
	coova-chilli-ssl.patch"

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

prepare() {
	cd $_builddir
#	patch -p1 -i ../coova-chilli-ssl.patch || return 1
	sed -i 's/-Werror//g' src/Makefile.am || return 1
	sed -i 's/-Werror//g' src/Makefile.in || return 1
	sed -i 's%(localstatedir)/run%(localstatedir)%' src/Makefile.am || return 1
	sed -i 's%(localstatedir)/run%(localstatedir)%' src/Makefile.in || return 1
	aclocal && autoconf && automake && libtoolize || return 1
}

build() {
	cd $_builddir
	./configure --prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--localstatedir=/var/run/chilli \
		--libdir=/usr/lib \
		--sysconfdir=/etc \
		--with-openssl \
		--enable-layer3 \
		--enable-dhcpopt \
		--enable-largelimits 
	make -j1  || return 1
}

package() {
	cd $_builddir
	make DESTDIR="$pkgdir" install || return 1
	rm "$pkgdir"/usr/lib/*.la || return 1
	install -D -m755 ../../chilli.initd $pkgdir/etc/init.d/chilli
	mkdir -p $pkgdir/var/run/chilli
}

md5sums="a493d0562fc3b05fe86d8ad65f7f2dc0  coova-chilli-1.2.9.tar.gz
4135e6e19bafdad777b8ca7388ff4101  coova-chilli-ssl.patch"