diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2009-07-24 08:01:31 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2009-07-24 08:01:31 +0000 |
commit | b70981b68efcce5256eb11c6cd26ae123b10b6ea (patch) | |
tree | a38be6efae5e2ba15c2e839504632f9b7bfd5f91 /main/mini_httpd | |
parent | 2b4df81538b8398442d5296650905c70341dd8d3 (diff) | |
download | aports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.bz2 aports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.xz |
moved extra/* to main/
and fixed misc build issues
Diffstat (limited to 'main/mini_httpd')
-rw-r--r-- | main/mini_httpd/APKBUILD | 42 | ||||
-rw-r--r-- | main/mini_httpd/mini_httpd.conf.sample | 50 | ||||
-rw-r--r-- | main/mini_httpd/mini_httpd.initd | 25 |
3 files changed, 117 insertions, 0 deletions
diff --git a/main/mini_httpd/APKBUILD b/main/mini_httpd/APKBUILD new file mode 100644 index 000000000..4f7167e70 --- /dev/null +++ b/main/mini_httpd/APKBUILD @@ -0,0 +1,42 @@ +# Maintainer: Natanael Copa <ncopa@alpinelinux.org> +pkgname=mini_httpd +pkgver=1.19 +pkgrel=1 +pkgdesc="Small forking webserver with ssl and ipv6 support" +url="http://www.acme.com/software/mini_httpd/" +license="BSD" +depends= +makedepends="openssl-dev" +subpackages="$pkgname-doc" +source="http://www.acme.com/software/mini_httpd/$pkgname-$pkgver.tar.gz + $pkgname.conf.sample + $pkgname.initd + " + +build() { + cd "$srcdir/$pkgname-$pkgver" + make CFLAGS="${CFLAGS} -DUSE_SSL" \ + LDFLAGS="${LDFLAGS}" \ + SSL_LIBS="-lssl -lcrypto" \ + || return 1 +# SSL_DEFS="-DUSE_SSL" \ + + # does not respect DESTDIR + make install \ + BINDIR="$pkgdir"/usr/sbin \ + MANDIR="$pkgdir"/usr/share/man + + # rename htpasswd to mini_htpasswd + mv "$pkgdir"/usr/sbin/htpasswd "$pkgdir"/usr/sbin/mini_htpasswd + mv "$pkgdir"/usr/share/man/man1/htpasswd.1 \ + "$pkgdir"/usr/share/man/man1/mini_htpasswd.1 + + mkdir -p "$pkgdir"/var/www/localhost/htdocs + install -D -m644 ../mini_httpd.conf.sample \ + "$pkgdir"/etc/mini_httpd.conf + install -D -m755 ../mini_httpd.initd "$pkgdir"/etc/init.d/mini_httpd +} + +md5sums="7c68293ad265ecfe2edea917912f6f1f mini_httpd-1.19.tar.gz +ec656aadd4751a3f4f6e8c788a5237f2 mini_httpd.conf.sample +804e5cba1537bddac195e64b5b50d609 mini_httpd.initd" diff --git a/main/mini_httpd/mini_httpd.conf.sample b/main/mini_httpd/mini_httpd.conf.sample new file mode 100644 index 000000000..397a331ad --- /dev/null +++ b/main/mini_httpd/mini_httpd.conf.sample @@ -0,0 +1,50 @@ +## /etc/mini_httpd.conf +## +## do not leave empty lines in here! +## format is: key=value +## +## run in debug-mode? +#debug +## +## what interface to bind to? +## (default is binding to any interface) +#host=www.example.org +port=80 +#port=443 +user=nobody +## +## The DOCROOT +dir=/var/www/localhost/htdocs +## +## CGI: +## ? match a single char +## * matches any string excluding "/" +## ** matches any string including "/" +## separate multiple patterns with "|" +#cgipat=**.sh|**.cgi +## +## chroot: +chroot +#nochroot +## +logfile=/var/log/mini_httpd.log +## +#charset=iso-8859-1 +## +## control the caching: (in secs) +#maxage 60 +## +## useless setting (just modifies the http-header) +## (see mini_httpd(8) and http://www.w3.org/P3P/ for more info) +#p3p +## +## virtual hosting: +#vhost +## +## cache-control: send this "max-age" in all HTTP-responses: +#max-age=0 +## +## ssl: +#nossl +#ssl +#certfile=/etc/mini_httpd/mini_httpd.pem diff --git a/main/mini_httpd/mini_httpd.initd b/main/mini_httpd/mini_httpd.initd new file mode 100644 index 000000000..4460a539e --- /dev/null +++ b/main/mini_httpd/mini_httpd.initd @@ -0,0 +1,25 @@ +#!/sbin/runscript +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/www-servers/mini_httpd/files/mini_httpd.init,v 1.2 2007/08/26 21:20:21 bangert Exp $ + +pidfile=/var/run/${SVCNAME}.pid + +depend() { + need net +} + +start() { + ebegin "Starting $SVCNAME" + start-stop-daemon --quiet --start --exec /usr/sbin/mini_httpd \ + --pidfile $pidfile -- -i $pidfile \ + ${MINI_HTTPD_OPTS:--C /etc/${SVCNAME}.conf} + eend $? +} + +stop() { + ebegin "Stopping $SVCNAME" + start-stop-daemon --quiet --stop --pidfile $pidfile + eend $? +} + |