diff options
Diffstat (limited to 'meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.0.bb')
| -rw-r--r-- | meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.0.bb | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.0.bb b/meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.0.bb new file mode 100644 index 0000000000..efa533a7d4 --- /dev/null +++ b/meta-webserver/recipes-httpd/sthttpd/sthttpd_2.27.0.bb | |||
| @@ -0,0 +1,52 @@ | |||
| 1 | SUMMARY = "A simple, small, portable, fast, and secure HTTP server" | ||
| 2 | DESCRIPTION = "A simple, small, portable, fast, and secure HTTP server (supported fork of thttpd)." | ||
| 3 | HOMEPAGE = "http://opensource.dyc.edu/sthttpd" | ||
| 4 | LICENSE = "BSD-2-Clause" | ||
| 5 | LIC_FILES_CHKSUM = "file://src/thttpd.c;beginline=1;endline=26;md5=0c5762c2c34dcbe9eb18815516502872" | ||
| 6 | |||
| 7 | SRC_URI = "http://opensource.dyc.edu/pub/sthttpd/sthttpd-${PV}.tar.gz \ | ||
| 8 | file://thttpd.service \ | ||
| 9 | file://thttpd.conf \ | ||
| 10 | file://init" | ||
| 11 | |||
| 12 | SRC_URI[md5sum] = "f7dd2d506dc5fad2ad8794b1800d2634" | ||
| 13 | SRC_URI[sha256sum] = "97d660a881331e93818e872ce11536f461105d70a18dfc5de5895851c4b2afdb" | ||
| 14 | |||
| 15 | S = "${WORKDIR}/sthttpd-${PV}" | ||
| 16 | |||
| 17 | inherit autotools update-rc.d systemd | ||
| 18 | |||
| 19 | SRV_DIR ?= "${servicedir}/www" | ||
| 20 | |||
| 21 | # Note that `${sbindir}/makeweb' is installed setgid to this group, | ||
| 22 | # but ${SRV_DIR} is not installed chgrp'd to the group by default. | ||
| 23 | WEBGROUP ?= "www-data" | ||
| 24 | |||
| 25 | do_configure_prepend () { | ||
| 26 | export WEBDIR=${SRV_DIR} | ||
| 27 | export WEBGROUP=${WEBGROUP} | ||
| 28 | } | ||
| 29 | |||
| 30 | do_install_append () { | ||
| 31 | install -d ${D}${sysconfdir}/init.d | ||
| 32 | install -c -m 755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/thttpd | ||
| 33 | install -c -m 755 ${WORKDIR}/thttpd.conf ${D}${sysconfdir} | ||
| 34 | sed -i -e 's,@@CONFFILE,${sysconfdir}/thttpd.conf,g' ${D}${sysconfdir}/init.d/thttpd | ||
| 35 | sed -i -e 's,@@SRVDIR,${SRV_DIR},g' ${D}${sysconfdir}/thttpd.conf | ||
| 36 | sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/thttpd | ||
| 37 | |||
| 38 | install -d ${D}${systemd_unitdir}/system | ||
| 39 | install -m 0644 ${WORKDIR}/thttpd.service ${D}${systemd_unitdir}/system | ||
| 40 | sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${systemd_unitdir}/system/thttpd.service | ||
| 41 | sed -i 's!/var/!${localstatedir}/!g' ${D}${systemd_unitdir}/system/thttpd.service | ||
| 42 | sed -i -e 's,@@CONFFILE,${sysconfdir}/thttpd.conf,g' ${D}${systemd_unitdir}/system/thttpd.service | ||
| 43 | } | ||
| 44 | |||
| 45 | INITSCRIPT_NAME = "thttpd" | ||
| 46 | INITSCRIPT_PARAMS = "defaults" | ||
| 47 | |||
| 48 | SYSTEMD_SERVICE_${PN} = "thttpd.service" | ||
| 49 | |||
| 50 | FILES_${PN} += "${SRV_DIR}" | ||
| 51 | FILES_${PN}-dbg += "${SRV_DIR}/cgi-bin/.debug" | ||
| 52 | |||
