added my Recipes
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
From b0526a9b5325bd4758dad8d14efd85c98ef2ebff Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Fri, 14 Jul 2017 18:25:23 -0700
|
||||
Subject: [PATCH] configure: Respect LIBS variable from env
|
||||
|
||||
For musl we need to pass -lexecinfo from env
|
||||
this change accomodates that
|
||||
|
||||
Upstream-Status: Inappropriate [OE-specific]
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
configure | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/configure b/configure
|
||||
index 4286c34..f1c65db 100755
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -620,7 +620,7 @@ LIBDEFS = -DSHAREDLIB -fPIC \$(DEFS)
|
||||
INCDIR = ./include
|
||||
LDFLAGS = $LDFLAGS
|
||||
DESTDIR = ../bin/monkey
|
||||
-LIBS = -ldl $libs
|
||||
+LIBS = -ldl $libs ${LIBS}
|
||||
OBJ = monkey.o mk_method.o mk_mimetype.o mk_vhost.o mk_request.o \\
|
||||
mk_header.o mk_config.o mk_signals.o \\
|
||||
mk_user.o mk_utils.o mk_epoll.o mk_scheduler.o \\
|
||||
--
|
||||
2.13.3
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
From 7f724bbafbb1e170401dd5de201273ab8c8bc75f Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Sun, 28 Aug 2022 14:24:02 -0700
|
||||
Subject: [PATCH] fastcgi: Use value instead of address of sin6_port
|
||||
|
||||
This seems to be wrongly assigned where ipv4 sin_port is
|
||||
equated to address of sin6_port and not value of sin6_port
|
||||
|
||||
Upstream-Status: Submitted [https://github.com/monkey/monkey/pull/375]
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
plugins/fastcgi/fcgi_handler.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/plugins/fastcgi/fcgi_handler.c b/plugins/fastcgi/fcgi_handler.c
|
||||
index 9e095e3c..e8e1eec1 100644
|
||||
--- a/plugins/fastcgi/fcgi_handler.c
|
||||
+++ b/plugins/fastcgi/fcgi_handler.c
|
||||
@@ -245,7 +245,7 @@ static inline int fcgi_add_param_net(struct fcgi_handler *handler)
|
||||
struct sockaddr_in *s4 = (struct sockaddr_in *)&addr4;
|
||||
memset(&addr4, 0, sizeof(addr4));
|
||||
addr4.sin_family = AF_INET;
|
||||
- addr4.sin_port = &s->sin6_port;
|
||||
+ addr4.sin_port = s->sin6_port;
|
||||
memcpy(&addr4.sin_addr.s_addr,
|
||||
s->sin6_addr.s6_addr + 12,
|
||||
sizeof(addr4.sin_addr.s_addr));
|
||||
--
|
||||
2.37.2
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
#!/bin/sh
|
||||
|
||||
PATH=/sbin:/bin:/usr/sbin:/usr/bin
|
||||
DAEMON=/usr/sbin/monkey
|
||||
NAME=monkey
|
||||
DESC="Monkey HTTP Server"
|
||||
OPTS="--daemon"
|
||||
|
||||
case "$1" in
|
||||
start)
|
||||
echo -n "Starting $DESC: "
|
||||
start-stop-daemon --start -x "$DAEMON" -- $OPTS
|
||||
echo "$NAME."
|
||||
;;
|
||||
stop)
|
||||
echo -n "Stopping $DESC: "
|
||||
start-stop-daemon --stop -x "$DAEMON"
|
||||
echo "$NAME."
|
||||
;;
|
||||
restart|force-reload)
|
||||
echo -n "Restarting $DESC: "
|
||||
start-stop-daemon --stop -x "$DAEMON"
|
||||
sleep 1
|
||||
start-stop-daemon --start -x "$DAEMON" -- $OPTS
|
||||
echo "$NAME."
|
||||
;;
|
||||
*)
|
||||
N=/etc/init.d/$NAME
|
||||
echo "Usage: $N {start|stop|restart|force-reload}" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
exit 0
|
||||
@@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=Monkey HTTP Server
|
||||
After=network.target remote-fs.target
|
||||
|
||||
[Service]
|
||||
Type=forking
|
||||
ExecStart=/usr/sbin/monkey --daemon
|
||||
PIDFile=/var/run/monkey.pid.2001
|
||||
TimeoutSec=10
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
@@ -0,0 +1,88 @@
|
||||
SUMMARY = "Fast and Lightweight HTTP Server for Linux"
|
||||
HOMEPAGE = "http://monkey-project.com"
|
||||
BUGTRACKER = "https://github.com/monkey/monkey/issues"
|
||||
|
||||
LICENSE = "Apache-2.0"
|
||||
LIC_FILES_CHKSUM = "file://LICENSE;md5=2ee41112a44fe7014dce33e26468ba93"
|
||||
|
||||
SECTION = "net"
|
||||
|
||||
SRC_URI = "git://github.com/monkey/monkey;branch=1.6;protocol=https \
|
||||
file://0001-fastcgi-Use-value-instead-of-address-of-sin6_port.patch \
|
||||
file://monkey.service \
|
||||
file://monkey.init"
|
||||
|
||||
SRCREV = "7999b487fded645381d387ec0e057e92407b0d2c"
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
UPSTREAM_CHECK_URI = "https://github.com/monkey/monkey/releases"
|
||||
UPSTREAM_CHECK_REGEX = "v(?P<pver>\d+(\.\d+)+).tar.gz"
|
||||
|
||||
EXTRA_OECMAKE = "-DINSTALL_LOGDIR=${localstatedir}/log/monkey/ \
|
||||
-DPID_FILE=/run/monkey.pid \
|
||||
-DINSTALL_SYSCONFDIR=${sysconfdir}/monkey/ \
|
||||
-DWITH_PLUGINS=* \
|
||||
-DWITHOUT_PLUGINS=mbedtls \
|
||||
-DWITH_DEBUG=1 \
|
||||
-DDEFAULT_USER='www-data' \
|
||||
-DWITH_SYSTEM_MALLOC=1 \
|
||||
"
|
||||
|
||||
EXTRA_OECMAKE:append:libc-musl = " -DWITH_MUSL=1 "
|
||||
|
||||
# GCC-10+ defaults to -fno-common
|
||||
CFLAGS += "-fcommon"
|
||||
|
||||
DISABLE_STATIC = ""
|
||||
|
||||
inherit cmake pkgconfig update-rc.d systemd
|
||||
|
||||
OECMAKE_GENERATOR = "Unix Makefiles"
|
||||
|
||||
do_install:append() {
|
||||
rmdir ${D}${localstatedir}/log/${BPN} ${D}${localstatedir}/run ${D}${localstatedir}/log
|
||||
rmdir --ignore-fail-on-non-empty ${D}${localstatedir}
|
||||
install -Dm 0755 ${WORKDIR}/monkey.init ${D}${sysconfdir}/init.d/monkey
|
||||
# Create /var/log/monkey in runtime.
|
||||
if [ "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" ]; then
|
||||
install -d ${D}${nonarch_libdir}/tmpfiles.d
|
||||
echo "d ${localstatedir}/log/${BPN} 0755 ${BPN} ${BPN} -" > ${D}${nonarch_libdir}/tmpfiles.d/${BPN}.conf
|
||||
fi
|
||||
if [ "${@bb.utils.filter('DISTRO_FEATURES', 'sysvinit', d)}" ]; then
|
||||
install -d ${D}${sysconfdir}/default/volatiles
|
||||
echo "d ${BPN} ${BPN} 0755 ${localstatedir}/log/${BPN} none" > ${D}${sysconfdir}/default/volatiles/99_${BPN}
|
||||
fi
|
||||
if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
|
||||
install -Dm 644 ${WORKDIR}/monkey.service ${D}/${systemd_unitdir}/system/monkey.service
|
||||
fi
|
||||
}
|
||||
|
||||
INITSCRIPT_NAME = "monkey"
|
||||
INITSCRIPT_PARAMS = "defaults 70"
|
||||
|
||||
SYSTEMD_SERVICE:${PN} = "monkey.service"
|
||||
|
||||
PACKAGES += "${PN}-plugins"
|
||||
|
||||
FILES:${PN}-plugins = "${libdir}/monkey-*.so"
|
||||
|
||||
FILES:${PN} += "${nonarch_libdir}/tmpfiles.d"
|
||||
|
||||
CONFFILES:${PN} = "${sysconfdir}/monkey/monkey.conf \
|
||||
${sysconfdir}/monkey/sites/default \
|
||||
${sysconfdir}/monkey/monkey.mime \
|
||||
${sysconfdir}/monkey/plugins.load \
|
||||
${sysconfdir}/monkey/plugins/proxy_reverse/proxy_reverse.conf \
|
||||
${sysconfdir}/monkey/plugins/mandril/mandril.conf \
|
||||
${sysconfdir}/monkey/plugins/fastcgi/fastcgi.conf \
|
||||
${sysconfdir}/monkey/plugins/logger/logger.conf \
|
||||
${sysconfdir}/monkey/plugins/cgi/cgi.conf \
|
||||
${sysconfdir}/monkey/plugins/cheetah/cheetah.conf \
|
||||
${sysconfdir}/monkey/plugins/dirlisting/dirhtml.conf \
|
||||
${sysconfdir}/monkey/plugins/dirlisting/themes/guineo/header.theme \
|
||||
${sysconfdir}/monkey/plugins/dirlisting/themes/guineo/footer.theme \
|
||||
${sysconfdir}/monkey/plugins/dirlisting/themes/guineo/entry.theme \
|
||||
${sysconfdir}/monkey/plugins/auth/README \
|
||||
${sysconfdir}/monkey/plugins/auth/monkey.users \
|
||||
"
|
||||
|
||||
Reference in New Issue
Block a user