blob: 128837dd1d00f0703c479b8bd6c80bbb9c601dc9 (
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
|
# $Id: PKGBUILD 100429 2013-11-04 09:06:17Z arodseth $
# Maintainer: Alexander Rødseth <rodseth@gmail.com>
# Maintainer: Vesa Kaihlavirta <vegai@iki.fi>
# Contributor: Patrick Smits <mail@patricksmits.net>
pkgname=yaws
pkgver=1.97
pkgrel=1
pkgdesc='Pure Erlang HTTP web server/framework'
arch=('x86_64' 'i686')
url='http://yaws.hyber.org/'
license=('BSD')
depends=('pam' 'erlang-nox')
backup=('etc/yaws/yaws.conf')
options=('!emptydirs')
install="$pkgname.install"
source=("http://yaws.hyber.org/download/$pkgname-$pkgver.tar.gz"
"$pkgname.service")
sha256sums=('a792478564866393f3e901bf4ec33272c22d7c01a8c5493b33856729d25b026e'
'09bd1f9f17833c83b4d82d3ac9dc2bf539c8e20ef92d438fced6e70b2aea61bc')
prepare() {
cd "$pkgname-$pkgver"
# python2 fix
for file in cgi.yaws cgi-bin/foo.py; do
sed -i '0,/on/s//on2/' "www/$file"
done
# R16B1 fix
sed -i 's/:sha(Salted)/:hash(sha, Salted)/' src/yaws_websockets.erl
}
build() {
cd "$pkgname-$pkgver"
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
make
}
package() {
make -C "$pkgname-$pkgver" DESTDIR="$pkgdir" install
install -d "$pkgdir/usr/lib/erlang/lib"
ln -s /usr/lib/yaws "$pkgdir/usr/lib/erlang/lib/$pkgname-$pkgver"
install -Dm644 "$pkgname.service" \
"$pkgdir/usr/lib/systemd/system/$pkgname.service"
install -Dm644 "$pkgname-$pkgver/LICENSE" \
"$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}
# vim:set ts=2 sw=2 et:
|