aboutsummaryrefslogtreecommitdiffstats
path: root/testing/apache2/APKBUILD
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2010-08-04 07:58:35 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2010-08-04 07:58:35 +0000
commitbc5d0beacc17d14bc85b8631fa469adeb8d1606d (patch)
treedb987b988e99aa4606a40f15bd85adaeaacb5c73 /testing/apache2/APKBUILD
parent6d34b2ee19f12a36c7797cfc693df5d5f0fdc578 (diff)
testing/apache2: renamed from apache
Upstream seems to use "apache2"
Diffstat (limited to 'testing/apache2/APKBUILD')
-rw-r--r--testing/apache2/APKBUILD154
1 files changed, 154 insertions, 0 deletions
diff --git a/testing/apache2/APKBUILD b/testing/apache2/APKBUILD
new file mode 100644
index 00000000000..40cf16b0359
--- /dev/null
+++ b/testing/apache2/APKBUILD
@@ -0,0 +1,154 @@
+# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
+pkgname=apache2
+pkgver=2.2.16
+pkgrel=0
+pkgdesc="A high performance Unix-based HTTP server"
+url="http://httpd.apache.org/"
+license="APACHE"
+depends=""
+pkgusers="apache"
+pkggroups="apache"
+makedepends="openssl-dev zlib-dev apr-util-dev apr-dev pcre-dev
+ autoconf automake"
+subpackages="$pkgname-dev $pkgname-doc $pkgname-utils"
+source="http://archive.apache.org/dist/httpd/httpd-$pkgver.tar.bz2
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/02-rename-prefork-to-itk.patch
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/03-add-mpm-to-build-system.patch
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/04-correct-output-makefile-location.patch
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/05-add-copyright.patch
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/06-hook-just-after-merging-perdir-config.patch
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/07-base-functionality.patch
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/08-max-clients-per-vhost.patch
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/09-capabilities.patch
+ http://mpm-itk.sesse.net/apache2.2-mpm-itk-2.2.11-02/10-nice.patch
+ apache2.confd
+ apache2.logrotate
+ apache2.initd
+ alpine.layout"
+
+prepare() {
+ cd "$srcdir"/httpd-$pkgver
+ sed -e 's#User daemon#User apache#' \
+ -e 's#Group daemon#Group apache#' \
+ -i docs/conf/httpd.conf.in || return 1
+ cat "$srcdir/alpine.layout" >> config.layout
+
+ cd "$srcdir"
+
+ # create symlinks to soruces for prefork and worker
+ ln -s httpd-$pkgver prefork
+ ln -s httpd-$pkgver worker
+
+ # make a patched clone of itk sources
+ cp -ra httpd-$pkgver itk
+ cd itk
+ mkdir -p server/mpm/experimental/itk
+ cp -r server/mpm/prefork/* \
+ server/mpm/experimental/itk/ || return 1
+ mv server/mpm/experimental/itk/prefork.c \
+ server/mpm/experimental/itk/itk.c || return 1
+ patch -Np1 -i "$srcdir/02-rename-prefork-to-itk.patch" || return 1
+ patch -Np1 -i "$srcdir/03-add-mpm-to-build-system.patch" || return 1
+ patch -Np1 -i "$srcdir/04-correct-output-makefile-location.patch" || return 1
+ patch -Np1 -i "$srcdir/05-add-copyright.patch" || return 1
+ patch -Np1 -i "$srcdir/06-hook-just-after-merging-perdir-config.patch" || return 1
+ patch -Np1 -i "$srcdir/07-base-functionality.patch" || return 1
+ patch -Np1 -i "$srcdir/08-max-clients-per-vhost.patch" || return 1
+ patch -Np1 -i "$srcdir/09-capabilities.patch" || return 1
+ patch -Np1 -i "$srcdir/10-nice.patch" || return 1
+ autoconf || return 1
+}
+
+build () {
+ local mpm
+ for mpm in prefork worker itk; do
+ mkdir "$srcdir"/build-${mpm}
+ cd "$srcdir"/build-${mpm}
+
+ "$srcdir"/$mpm/configure --prefix=/usr \
+ --enable-layout=Alpine \
+ --enable-modules=all \
+ --enable-mods-shared=all \
+ --enable-so \
+ --enable-suexec \
+ --with-suexec-caller=http \
+ --with-suexec-docroot=/var/www/localhost/htdocs \
+ --with-suexec-logfile=/var/log/httpd/suexec.log \
+ --with-suexec-bin=/usr/sbin/suexec \
+ --with-suexec-uidmin=99 \
+ --with-suexec-gidmin=99 \
+ --enable-ldap \
+ --enable-authnz-ldap \
+ --enable-cache \
+ --enable-disk-cache \
+ --enable-mem-cache \
+ --enable-file-cache \
+ --enable-ssl \
+ --with-ssl \
+ --enable-deflate \
+ --enable-cgid \
+ --enable-proxy \
+ --enable-proxy-connect \
+ --enable-proxy-http \
+ --enable-proxy-ftp \
+ --enable-dbd \
+ --with-apr=/usr/bin/apr-1-config \
+ --with-apr-util=/usr/bin/apu-1-config \
+ --with-pcre=/usr \
+ --with-mpm=${mpm} \
+ || return 1
+ make || return 1
+ done
+}
+
+package() {
+ cd "$srcdir"/build-prefork
+ make -j1 DESTDIR="$pkgdir" install || return 1
+ for mpm in worker itk; do
+ install -m755 "$srcdir"/build-$mpm/httpd \
+ "$pkgdir/usr/sbin/httpd.${mpm}" || return 1
+ done
+
+ install -D -m755 "$srcdir/apache2.initd" \
+ "$pkgdir/etc/init.d/apache2" || return 1
+ install -D -m644 "$srcdir/apache2.logrotate" \
+ "$pkgdir/etc/logrotate.d/apache2" || return 1
+ install -D -m644 "$srcdir/apache2.confd" \
+ "$pkgdir/etc/conf.d/apache2" || return 1
+
+ install -d "$pkgdir"/var/www
+ ln -fs /var/log/httpd "$pkgdir/var/www/logs"
+ ln -fs /var/run/httpd "$pkgdir/var/www/run"
+ ln -fs /usr/lib/httpd/modules "$pkgdir/var/www/modules"
+ sed -e 's#/usr/lib/httpd/modules/#modules/#' \
+ -e 's|#\(Include conf/extra/httpd-multilang-errordoc.conf\)|\1|'\
+ -e 's|#\(Include conf/extra/httpd-autoindex.conf\)|\1|' \
+ -e 's|#\(Include conf/extra/httpd-languages.conf\)|\1|' \
+ -e 's|#\(Include conf/extra/httpd-userdir.conf\)|\1|' \
+ -e 's|#\(Include conf/extra/httpd-default.conf\)|\1|' \
+ -e 's|/srv/http|/var/www/localhost|g' \
+ -i "$pkgdir/etc/apache2/httpd.conf" || return 1
+}
+
+utils() {
+ pkgdesc="Apache utility programs for webservers"
+ install -d "$subpkgdir"/usr/bin "$subpkgdir"/usr/sbin
+ cd "$pkgdir"/usr/sbin
+ mv ab dbmmanage htdbm htdigest htpasswd logresolve "$subpkgdir"/usr/bin
+ mv checkgid htcacheclean rotatelogs "$subpkgdir"/usr/sbin
+}
+
+md5sums="c8ff2a07c884300bc7766a2e7f662d33 httpd-2.2.16.tar.bz2
+db42cfcc18ae1c32aaaff2347e35b79d 02-rename-prefork-to-itk.patch
+131408ad4dc7b18547b4e062e7e495ab 03-add-mpm-to-build-system.patch
+ee488f391054d528547c3a372faa2aa7 04-correct-output-makefile-location.patch
+b202944761b2f0516196488b12504236 05-add-copyright.patch
+78fa15f8ca3a284b7d71f942e24e47fb 06-hook-just-after-merging-perdir-config.patch
+d33e39350e987721d50e6fb8e164ab6b 07-base-functionality.patch
+9f7a8935f9cabc7b46d0052906634cef 08-max-clients-per-vhost.patch
+1b28e3363e1b0d05b738a21e7ddd264f 09-capabilities.patch
+d9667fcd2ffecc63e446edd4d6666731 10-nice.patch
+f3e4f5eed88d97d1bbadd0597562bc28 apache2.confd
+d91a9a7196b10ef0bc4ab5b98ea9ccd9 apache2.logrotate
+0261136ff734c3ae8dcf878a46ed5830 apache2.initd
+af943bf52cec8088974084639661ba34 alpine.layout"