summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrahmajit das <brahmajit.xyz@gmail.com>2023-03-11 20:14:48 +0530
committerJoonas Niilola <juippis@gentoo.org>2023-04-04 10:53:07 +0300
commit22032423541019de6e98183ad25f6216f587d231 (patch)
treee806d2fce800e9a99f45e581bf762b47a40054a0 /sys-process/daemontools
parentnet-p2p/mldonkey: Disable building the GUI (diff)
downloadgentoo-22032423541019de6e98183ad25f6216f587d231.tar.gz
gentoo-22032423541019de6e98183ad25f6216f587d231.tar.bz2
gentoo-22032423541019de6e98183ad25f6216f587d231.zip
sys-process/daemontools: fix build w/ clang 16
Signed-off-by: brahmajit das <brahmajit.xyz@gmail.com> Closes: https://github.com/gentoo/gentoo/pull/30054 Signed-off-by: Joonas Niilola <juippis@gentoo.org>
Diffstat (limited to 'sys-process/daemontools')
-rw-r--r--sys-process/daemontools/daemontools-0.76-r11.ebuild54
-rw-r--r--sys-process/daemontools/files/0.76-implicit-func-decl-clang16.patch13
2 files changed, 67 insertions, 0 deletions
diff --git a/sys-process/daemontools/daemontools-0.76-r11.ebuild b/sys-process/daemontools/daemontools-0.76-r11.ebuild
new file mode 100644
index 000000000000..3390cd179a7d
--- /dev/null
+++ b/sys-process/daemontools/daemontools-0.76-r11.ebuild
@@ -0,0 +1,54 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit flag-o-matic toolchain-funcs
+
+DESCRIPTION="Collection of tools for managing UNIX services"
+HOMEPAGE="https://cr.yp.to/daemontools.html"
+SRC_URI="
+ https://cr.yp.to/daemontools/${P}.tar.gz
+ http://smarden.org/pape/djb/manpages/${P}-man-20020131.tar.gz"
+S="${WORKDIR}/admin/${P}/src"
+
+LICENSE="public-domain GPL-2" # GPL-2 for init script
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
+IUSE="selinux static"
+
+RDEPEND="selinux? ( sec-policy/selinux-daemontools )"
+
+PATCHES=(
+ "${FILESDIR}"/${PV}-errno.patch
+ "${FILESDIR}"/${PV}-C99-decls.patch
+ "${FILESDIR}"/${PV}-makefile.patch
+ "${FILESDIR}"/${PV}-implicit-func-decl-clang16.patch
+)
+
+src_configure() {
+ tc-export AR CC
+ use static && append-ldflags -static
+
+ touch home || die
+}
+
+src_install() {
+ keepdir /service
+
+ dobin $(<../package/commands)
+ dodoc CHANGES ../package/README TODO
+ doman "${WORKDIR}"/${PN}-man/*.8
+
+ newinitd "${FILESDIR}"/svscan.init-0.76-r7 svscan
+}
+
+pkg_postinst() {
+ einfo
+ einfo "You can run daemontools using the svscan init.d script,"
+ einfo "or you could run it through inittab."
+ einfo "To use inittab, emerge supervise-scripts and run:"
+ einfo "svscan-add-to-inittab"
+ einfo "Then you can hup init with the command telinit q"
+ einfo
+}
diff --git a/sys-process/daemontools/files/0.76-implicit-func-decl-clang16.patch b/sys-process/daemontools/files/0.76-implicit-func-decl-clang16.patch
new file mode 100644
index 000000000000..06fe93b5d410
--- /dev/null
+++ b/sys-process/daemontools/files/0.76-implicit-func-decl-clang16.patch
@@ -0,0 +1,13 @@
+diff --git a/sig_pause.c b/sig_pause.c
+index 3d1a793..5280934 100644
+--- a/sig_pause.c
++++ b/sig_pause.c
+@@ -1,5 +1,7 @@
+ /* Public domain. */
+-
++#ifndef _XOPEN_SOURCE
++#define _XOPEN_SOURCE 500
++#endif
+ #include <signal.h>
+ #include "sig.h"
+ #include "hassgprm.h"