aboutsummaryrefslogtreecommitdiffstats
path: root/main/lighttpd/APKBUILD
blob: b1371e73a1ed41c3bb57bfa5a898e12c99f6be57 (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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
# Contributor: Valery Kartel <valery.kartel@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=lighttpd
pkgver=1.4.45
pkgrel=1
pkgdesc="A secure, fast, compliant and very flexible web-server"
url="http://www.lighttpd.net/"
arch="all"
license="custom"
install="$pkgname.pre-install $pkgname.pre-upgrade"
pkgusers="lighttpd"
pkggroups="lighttpd"
makedepends="flex pcre-dev libressl-dev zlib-dev bzip2-dev lua5.3-dev
	automake autoconf openldap-dev libxml2-dev sqlite-dev libev-dev
	gamin-dev"
subpackages="$pkgname-doc $pkgname-dbg $pkgname-mod_auth
	$pkgname-mod_webdav"
source="http://download.lighttpd.net/lighttpd/releases-1.4.x/$pkgname-$pkgver.tar.xz
	$pkgname.initd
	$pkgname.confd
	$pkgname.logrotate
	lighttpd.conf
	mime-types.conf
	mod_cgi.conf
	mod_fastcgi.conf
	mod_fastcgi_fpm.conf"
builddir="$srcdir/$pkgname-$pkgver"

build() {
	cd "$builddir"

	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--disable-dependency-tracking \
		--enable-lfs \
		--libdir=/usr/lib/lighttpd \
		--without-mysql \
		--without-attr \
		--without-kerberos5 \
		--with-fam \
		--with-webdav-props \
		--with-webdav-locks \
		--without-gdbm \
		--with-bzip2 \
		--with-ldap \
		--with-openssl \
		--with-libev \
		--with-lua \
		|| return 1
	make
}

package() {
	cd "$builddir"

	make DESTDIR="$pkgdir" install || return 1

	# create dirs
	install -d -m755 -o lighttpd -g lighttpd \
		"$pkgdir"/var/log/lighttpd/ || return 1
	install -d -m755 \
		"$pkgdir"/etc/lighttpd/ \
		"$pkgdir"/var/www/localhost/htdocs || return 1

	# lighttpd
	install -D -m755 "$srcdir"/lighttpd.initd \
		"$pkgdir"/etc/init.d/lighttpd || return 1
	install -D -m644 "$srcdir"/lighttpd.confd \
		"$pkgdir"/etc/conf.d/lighttpd || return 1
	install -D -m644 "$srcdir"/lighttpd.logrotate \
		"$pkgdir"/etc/logrotate.d/lighttpd || return 1

	# config files
	local i; for i in lighttpd.conf mime-types.conf mod_cgi.conf \
		mod_fastcgi.conf mod_fastcgi_fpm.conf
	do
		install -m644 "$srcdir"/$i "$pkgdir"/etc/lighttpd/$i
	done
}

_mv_mod() {
	mkdir -p "$subpkgdir"/usr/lib/lighttpd
	while [ $# -gt 0 ]; do
		mv "$pkgdir"/usr/lib/lighttpd/$1.so \
			"$subpkgdir"/usr/lib/lighttpd/ || return 1
		shift
	done
}

mod_auth() {
	pkgdesc="Authentication module for lighttpd"
	_mv_mod mod_auth
}

mod_webdav() {
	pkgdesc="WebDAV module for lighttpd"
	_mv_mod mod_webdav
}

md5sums="a128e1eda76899ce3fd115efae5fe631  lighttpd-1.4.45.tar.xz
454fcefb873a08b7556d77ade17387ef  lighttpd.initd
61a416bbbc504843142bdfe8077964e0  lighttpd.confd
6846f00fff531bb3883904810264decf  lighttpd.logrotate
3bc7358a02ca684b0924ec7e21d56f06  lighttpd.conf
f3353baa4577703ec3a30c03482df986  mime-types.conf
9c1407e95f62ed22da66c4ef5f69c3b5  mod_cgi.conf
32bda92c408640c4c72123cbf1175172  mod_fastcgi.conf
aee5947a1abf380b0685a534ca384b42  mod_fastcgi_fpm.conf"
sha256sums="1c97225deea33eefba6d4158c2cef27913d47553263516bbe9d2e2760fc43a3f  lighttpd-1.4.45.tar.xz
4ce8a56c47bffb6b7b03e88cfb7a2ceb1d396e8bc7502d0de66d81e732c861af  lighttpd.initd
80e03abc267b163f332718545b5ec3a21adef74ecd60098c4e4f7d7c88c21a76  lighttpd.confd
0fff2602a2809662f7fcfe78be52bebc71338f545b26fd41e5c1d74e20486104  lighttpd.logrotate
818b04cbd4fbb1a908466cb4c8d76c86376ee53114f46005399d6f1005d31690  lighttpd.conf
75a6fce072250ebccde2320996fdace0ebfeb525b03322f0b454f8f4e0e29a85  mime-types.conf
322656b4cfd22ca9f1f8ab160e0b932f1646622422fd49c6fc82ab416223eecf  mod_cgi.conf
799e3b61cae677e71f95fa0483bd4cd35d9f28adf79ce680c687d2b476eb677d  mod_fastcgi.conf
e7eb047360e09d1a2b693f08d4a912b99954090c5bdea706f46a33554e867043  mod_fastcgi_fpm.conf"
sha512sums="d030674a8c55aab12d32ac75f8df2628ba2332a5263c8bd2dd4f39342530080edc6ba2a6fee749c1301d601ab766a265d3c630b04d38bb26bba3cf045935573d  lighttpd-1.4.45.tar.xz
f2f3c5c7731550237fd75a8de66275f427eaf897cffff7ac7ef44178328ad8fad6c4ec6654759bfc665cbaf7991ddcdf0aaa916831c8b6aa440192d57b242038  lighttpd.initd
9d2ab5deb7353ebf290e90936b511941df440859c78589d0bcf130ef69a5e9c79e4d318548b6b118df002083c46f7476230a28954b7a10a9dbd05040e02b1291  lighttpd.confd
0536b4f21d2e8659f7831b45998c13d9f6051ae7ecde13be01f372f837d255bfc4e211de48a7686cc743d53aa9c08ab3f10ec19788896dcf8356b90053ca7a16  lighttpd.logrotate
0aab94cb49ef5a96c1b5dbcf142b41acf49286ed6e2a252210f3f7fb6ee0639ebc5b8f4ddc89eb4b9a2bde38af07b8f008473aef2a460488ac806844f398350d  lighttpd.conf
a3f2f5763885d7e4f510491b24164e34aaf62bb02daa12991575dc64335c12668355af5bb8d6ce191eb4e9cce95324b1f7c9ba61b323b4e7b50a1e03e021afcf  mime-types.conf
27cc638d8068dcf47bd9db44943d1db6c6f4e8e6abd6b42af7cea004b1c093440068541d98c68f8bea70b956713adaf8ed59a4b642dea826ee8620a05f8cfde5  mod_cgi.conf
1d15b84c03fb648a0e67ab5c5411b85478b4454c44bc2959cc96d1700eeadd7ff429520a5f1550db6527267646622dccd3d47d3fd1258869fccaf5c22d4ad4b2  mod_fastcgi.conf
f9efc4b70d825600f5356c30e57d0b6cac11c01739337f7192c09c2cfd96cb76c8328b11d818ea4c2addc1a6d253975b84700106ae75854d55d0df73e220bd2b  mod_fastcgi_fpm.conf"