[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/
commit: 437dd07ebf11db8a8babbf70c317dbbe7abad168 Author: Sam James gentoo org> AuthorDate: Sat Sep 2 17:35:27 2023 + Commit: Sam James gentoo org> CommitDate: Sat Sep 2 17:35:30 2023 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=437dd07e sys-apps/dbus: fixup elogind patch Signed-off-by: Sam James gentoo.org> sys-apps/dbus/files/dbus-1.15.8-enable-elogind.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys-apps/dbus/files/dbus-1.15.8-enable-elogind.patch b/sys-apps/dbus/files/dbus-1.15.8-enable-elogind.patch index 1cf9094990e6..543eac5b30f2 100644 --- a/sys-apps/dbus/files/dbus-1.15.8-enable-elogind.patch +++ b/sys-apps/dbus/files/dbus-1.15.8-enable-elogind.patch @@ -9,7 +9,7 @@ particularly required. The only known consumer at the moment is hplip. #ifdef HAVE_SYSTEMD #include #endif -+#if HAVE_ELOGIND ++#ifdef HAVE_ELOGIND +#include +#endif @@ -40,7 +40,7 @@ particularly required. The only known consumer at the moment is hplip. endif endif -+elogind = dependency('elogind', version: '>=209', required: get_option('elogind')) ++elogind = dependency('libelogind', version: '>=209', required: get_option('elogind')) +use_elogind = elogind.found() +config.set('HAVE_ELOGIND', use_elogind) +
[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/, sys-apps/dbus/
commit: c4f4edf10c8483631a77948a50f2b9308adf5cef Author: Sam James gentoo org> AuthorDate: Sat Sep 2 16:14:01 2023 + Commit: Sam James gentoo org> CommitDate: Sat Sep 2 16:17:12 2023 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c4f4edf1 sys-apps/dbus: add 1.15.8 Upstream have dropped non-meson support, so here we go! Rebased the elogind patch reluctantly, but I've dropped the REQUIRED_USE for one-of systemd/elogind, given floppym's analysis on the bug. The functionality provided by elogind here is pretty minimal and it doesn't appear required at all, so it doesn't make sense to force it. Bug: https://bugs.gentoo.org/599494 Signed-off-by: Sam James gentoo.org> sys-apps/dbus/Manifest | 1 + sys-apps/dbus/dbus-1.15.8.ebuild | 232 + .../dbus/files/dbus-1.15.8-enable-elogind.patch| 65 ++ 3 files changed, 298 insertions(+) diff --git a/sys-apps/dbus/Manifest b/sys-apps/dbus/Manifest index e0263135e574..38dd813835d5 100644 --- a/sys-apps/dbus/Manifest +++ b/sys-apps/dbus/Manifest @@ -1,2 +1,3 @@ DIST dbus-1.15.4.tar.xz 1404576 BLAKE2B 6007be414497ef95f1e6a7e937c6a0a9b590c163b6b3a1c3e61b6726b988192728aa85a328d89472f34613d48ca1bb6844e86bee997acb4f377a228b2072fbce SHA512 53a5b7161940c5d4432b902c3c0ac1f1965978e3791a640d1a71f2d819474b727497f7a13c95d7c5850baef659062f1434296a3f5e56701383cc573dfbf187ee DIST dbus-1.15.6.tar.xz 1406672 BLAKE2B 5c2b876ede784a82c43096e82c3fa4b905cab26aa8f27e5553d07c53bde6120854cd9b109f3f179e9b47ecd7e2b69c08655b96d821c7790c1c9f52bb6356d331 SHA512 8c2e207d98245d5f8d358e9824be9e8646af8147958e8bd56e18d478e8976e58a6645ee1aba62451fcc58443157e2a39c4a6ed9c2e440e7b6b05053d022f0113 +DIST dbus-1.15.8.tar.xz 1149088 BLAKE2B 7c1962dfccc6a1b6250e80b0706d7f44536fabeff009013865ec4b1edaec6d4b47dcbe8f78caa61ef7aef4bac6b79f0e2027dd16bbb2baae328429e648bf8b8c SHA512 84b8ac194ede3bf300f4501395b7253538469a4f9d59ea4adaf800282e359ef43494d81941b338081d3704317d39f0aba14906c6490419f04f946eb9d815f46c diff --git a/sys-apps/dbus/dbus-1.15.8.ebuild b/sys-apps/dbus/dbus-1.15.8.ebuild new file mode 100644 index ..c783689b9742 --- /dev/null +++ b/sys-apps/dbus/dbus-1.15.8.ebuild @@ -0,0 +1,232 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +# Be careful with packaging odd-version-number branches! +# After >1.15, we should at least keep stable as an upstream stable branch, +# possibly even ~arch too, given the note about security releases on their website. +# See https://www.freedesktop.org/wiki/Software/dbus/#download. + +PYTHON_COMPAT=( python3_{10..12} ) +TMPFILES_OPTIONAL=1 + +inherit linux-info meson-multilib python-any-r1 readme.gentoo-r1 systemd tmpfiles virtualx + +DESCRIPTION="A message bus system, a simple way for applications to talk to each other" +HOMEPAGE="https://www.freedesktop.org/wiki/Software/dbus/"; +SRC_URI="https://dbus.freedesktop.org/releases/dbus/${P}.tar.xz"; + +LICENSE="|| ( AFL-2.1 GPL-2 )" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris" +# TODO: USE=daemon +IUSE="debug doc elogind selinux static-libs systemd test valgrind X" +RESTRICT="!test? ( test )" + +BDEPEND=" + acct-user/messagebus + app-text/xmlto + app-text/docbook-xml-dtd:4.4 + sys-devel/autoconf-archive + virtual/pkgconfig + doc? ( app-doc/doxygen ) +" +COMMON_DEPEND=" + >=dev-libs/expat-2.1.0 + elogind? ( sys-auth/elogind ) + selinux? ( + sys-process/audit + sys-libs/libselinux + ) + systemd? ( sys-apps/systemd:= ) + X? ( + x11-libs/libX11 + x11-libs/libXt + ) +" +DEPEND=" + ${COMMON_DEPEND} + dev-libs/expat + test? ( + ${PYTHON_DEPS} + >=dev-libs/glib-2.40:2 + ) + valgrind? ( >=dev-util/valgrind-3.6 ) + X? ( x11-base/xorg-proto ) +" +RDEPEND=" + ${COMMON_DEPEND} + acct-user/messagebus + selinux? ( sec-policy/selinux-dbus ) + systemd? ( virtual/tmpfiles ) +" + +DOC_CONTENTS=" + Some applications require a session bus in addition to the system + bus. Please see \`man dbus-launch\` for more information. +" + +PATCHES=( + "${FILESDIR}"/${PN}-1.15.8-enable-elogind.patch # bug #599494 +) + +pkg_setup() { + use test && python-any-r1_pkg_setup + + if use kernel_linux; then + CONFIG_CHECK="~EPOLL" + linux-info_pkg_setup + fi +} + +src_configure() { + local rundir=$(usex kernel_linux /run /var/run) + + sed -e "s;@rundir@;${EPREFIX}${rundir};g" "${FILESDIR}"/dbus.initd.in \ + > "${T}"/dbus.initd || die + + meson-multilib_src_configure +} + +multilib_src_configure() { +
[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/
commit: ba0af321b32d067cf6f79ff0b6449d0db74b91ce Author: Michael Mair-Keimberger levelnine at> AuthorDate: Sat Nov 12 08:08:12 2022 + Commit: Conrad Kostecki gentoo org> CommitDate: Sun Nov 13 18:33:54 2022 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ba0af321 sys-apps/dbus: remove unused patches Signed-off-by: Michael Mair-Keimberger levelnine.at> Closes: https://github.com/gentoo/gentoo/pull/28242 Signed-off-by: Conrad Kostecki gentoo.org> sys-apps/dbus/files/dbus-daemon-optional.patch | 75 -- sys-apps/dbus/files/dbus-enable-elogind.patch | 73 - 2 files changed, 148 deletions(-) diff --git a/sys-apps/dbus/files/dbus-daemon-optional.patch b/sys-apps/dbus/files/dbus-daemon-optional.patch deleted file mode 100644 index 353dcb5761be.. --- a/sys-apps/dbus/files/dbus-daemon-optional.patch +++ /dev/null @@ -1,75 +0,0 @@ -From 3c08d28fbae8b0ef3839ef26f8d2a713a9a684f9 Mon Sep 17 00:00:00 2001 -From: Andreas Sturmlechner -Date: Thu, 21 Feb 2019 23:53:19 +0100 -Subject: [PATCH] Make dbus daemon build optional - - bus/Makefile.am | 2 ++ - configure.ac| 17 - - 2 files changed, 18 insertions(+), 1 deletion(-) - -diff --git a/bus/Makefile.am b/bus/Makefile.am -index 9ae3071..26a770c 100644 a/bus/Makefile.am -+++ b/bus/Makefile.am -@@ -70,6 +70,7 @@ agentdir=$(LAUNCHD_AGENT_DIR) - agent_DATA=org.freedesktop.dbus-session.plist - endif - -+if DBUS_DAEMON - if DBUS_BUS_ENABLE_KQUEUE - DIR_WATCH_SOURCE=dir-watch-kqueue.c - else -@@ -241,6 +242,7 @@ test_bus_LDADD = \ - $(top_builddir)/dbus/libdbus-internal.la \ - $(DBUS_BUS_LIBS) \ - $(NULL) -+endif DBUS_DAEMON - - install-data-hook: - $(mkinstalldirs) $(DESTDIR)$(dbusdatadir)/session.d -diff --git a/configure.ac b/configure.ac -index be6b065..854e846 100644 a/configure.ac -+++ b/configure.ac -@@ -202,6 +202,7 @@ AC_ARG_ENABLE([apparmor], - [enable_apparmor=$enableval], - [enable_apparmor=auto]) - AC_ARG_ENABLE(libaudit,AS_HELP_STRING([--enable-libaudit],[build audit daemon support for SELinux]),enable_libaudit=$enableval,enable_libaudit=auto) -+AC_ARG_ENABLE(daemon, AS_HELP_STRING([--enable-daemon],[build with the dbus daemon]),enable_daemon=$enableval,enable_daemon=yes) - AC_ARG_ENABLE(inotify, AS_HELP_STRING([--enable-inotify],[build with inotify support (linux only)]),enable_inotify=$enableval,enable_inotify=auto) - AC_ARG_ENABLE(kqueue, AS_HELP_STRING([--enable-kqueue],[build with kqueue support]),enable_kqueue=$enableval,enable_kqueue=auto) - AC_ARG_ENABLE(console-owner-file, AS_HELP_STRING([--enable-console-owner-file],[enable console owner file]),enable_console_owner_file=$enableval,enable_console_owner_file=auto) -@@ -830,7 +831,20 @@ AC_CHECK_FUNCS(getpeerucred getpeereid) - - AC_CHECK_FUNCS(pipe2 accept4) - --PKG_CHECK_MODULES([EXPAT], [expat]) -+# dbusdaemon checks -+if test x$enable_daemon = xno ; then -+have_daemon=no -+else -+have_daemon=yes -+fi -+ -+dnl check if daemon shall be built -+if test x$have_daemon = xyes; then -+ AC_DEFINE(DBUS_DAEMON,1,[Use daemon]) -+ PKG_CHECK_MODULES([EXPAT], [expat]) -+fi -+ -+AM_CONDITIONAL(DBUS_DAEMON, test x$have_daemon = xyes) - - save_cflags="$CFLAGS" - save_libs="$LIBS" -@@ -1824,6 +1838,7 @@ echo " - Building bus stats API: ${enable_stats} - Building SELinux support: ${have_selinux} - Building AppArmor support: ${have_apparmor} -+Building daemon: ${have_daemon} - Building inotify support: ${have_inotify} - Building kqueue support: ${have_kqueue} - Building systemd support: ${have_systemd} --- -2.20.1 - diff --git a/sys-apps/dbus/files/dbus-enable-elogind.patch b/sys-apps/dbus/files/dbus-enable-elogind.patch deleted file mode 100644 index 5cb5d649cd91.. --- a/sys-apps/dbus/files/dbus-enable-elogind.patch +++ /dev/null @@ -1,73 +0,0 @@ a/dbus/dbus-userdb-util.c 2015-09-30 16:48:40.0 +0200 -+++ b/dbus/dbus-userdb-util.c 2016-11-03 11:09:42.550520587 +0100 -@@ -32,6 +32,9 @@ - #if HAVE_SYSTEMD - #include - #endif -+#if HAVE_ELOGIND -+#include -+#endif - - /** - * @addtogroup DBusInternalsUtils -@@ -54,7 +57,7 @@ - const DBusUserInfo *info; - dbus_bool_t result = FALSE; - --#ifdef HAVE_SYSTEMD -+#if defined(HAVE_SYSTEMD) || defined(HAVE_ELOGIND) - /* check if we have logind */ - if (access ("/run/systemd/seats/", F_OK) >= 0) - { a/configure.ac 2016-11-03 11:13:58.286528265 +0100 -+++ b/configure.ac 2016-11-03 11:22:11.210543063 +0100 -@@ -185,6 +185,7 @@ - AC_ARG_ENABLE(kqueue, AS_HELP_STRING([--enable-kqueue],[build with kqueue support]),enable_kqueue=$enableval,enable_kqueue=auto) - AC_ARG_ENABLE(console-owner-file, AS_HELP_STRING([--enable-console-owner-file],[enable console owner file]),enable_console_owner_file=$enableval,enable_console_owner_file=auto) - AC_ARG_ENABLE(launchd, AS_HELP_STR
[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/
commit: 8b47d1aa4f2c87e2293fad2aed57ad9102226db7 Author: Michael Mair-Keimberger levelnine at> AuthorDate: Fri Oct 7 20:26:14 2022 + Commit: Conrad Kostecki gentoo org> CommitDate: Sat Oct 15 19:33:37 2022 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8b47d1aa sys-apps/dbus: remove unused patch Signed-off-by: Michael Mair-Keimberger levelnine.at> Closes: https://github.com/gentoo/gentoo/pull/27681 Signed-off-by: Conrad Kostecki gentoo.org> .../files/dbus-1.14.0-clang-15-configure.patch | 26 -- 1 file changed, 26 deletions(-) diff --git a/sys-apps/dbus/files/dbus-1.14.0-clang-15-configure.patch b/sys-apps/dbus/files/dbus-1.14.0-clang-15-configure.patch deleted file mode 100644 index 821279c50ee9.. --- a/sys-apps/dbus/files/dbus-1.14.0-clang-15-configure.patch +++ /dev/null @@ -1,26 +0,0 @@ -https://gitlab.freedesktop.org/dbus/dbus/-/merge_requests/339 - -From 88c96ff6a351758cb7c69a25e3a8464b5164a19c Mon Sep 17 00:00:00 2001 -From: Sam James -Date: Mon, 12 Sep 2022 18:37:35 +0100 -Subject: [PATCH] configure.ac: fix configure tests broken with Clang 15 - (implicit function declarations) - -Clang 15 makes implicit function declarations fatal by default which -leads to some configure tests silently failing/returning -the wrong result. - -Signed-off-by: Sam James a/configure.ac -+++ b/configure.ac -@@ -613,7 +613,8 @@ AS_IF([test -n "$dbus_va_copy_func"], - AC_CACHE_CHECK([whether $CC knows __sync_sub_and_fetch()], - dbus_cv_sync_sub_and_fetch, - [AC_LINK_IFELSE([ -- AC_LANG_PROGRAM([[]], [[int a = 4; int b = __sync_sub_and_fetch(&a, 4); exit(b); ]])], -+ AC_LANG_PROGRAM([[]], [[#include -+ int a = 4; int b = __sync_sub_and_fetch(&a, 4); exit(b); ]])], - [dbus_cv_sync_sub_and_fetch=yes], - [dbus_cv_sync_sub_and_fetch=no]) - ]) -GitLab
[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/, sys-apps/dbus/
commit: d1a79e781bbe17899a96df6137118e6a03076737 Author: Sam James gentoo org> AuthorDate: Mon Sep 12 17:39:27 2022 + Commit: Sam James gentoo org> CommitDate: Mon Sep 12 18:04:15 2022 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d1a79e78 sys-apps/dbus: fix configure tests with Clang 15 Signed-off-by: Sam James gentoo.org> sys-apps/dbus/dbus-1.14.0-r5.ebuild| 294 + .../files/dbus-1.14.0-clang-15-configure.patch | 26 ++ 2 files changed, 320 insertions(+) diff --git a/sys-apps/dbus/dbus-1.14.0-r5.ebuild b/sys-apps/dbus/dbus-1.14.0-r5.ebuild new file mode 100644 index ..64f28fbcc48f --- /dev/null +++ b/sys-apps/dbus/dbus-1.14.0-r5.ebuild @@ -0,0 +1,294 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{8..10} ) +TMPFILES_OPTIONAL=1 + +# At least at the moment, while a CMake port exists, it's not recommended +# for distributions. +# https://gitlab.freedesktop.org/dbus/dbus/-/blob/master/CONTRIBUTING.md#L189 +inherit autotools flag-o-matic linux-info python-any-r1 readme.gentoo-r1 systemd tmpfiles virtualx multilib-minimal + +DESCRIPTION="A message bus system, a simple way for applications to talk to each other" +HOMEPAGE="https://www.freedesktop.org/wiki/Software/dbus/"; +SRC_URI="https://dbus.freedesktop.org/releases/dbus/${P}.tar.xz"; + +LICENSE="|| ( AFL-2.1 GPL-2 )" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="debug doc elogind selinux static-libs systemd test X" +RESTRICT="!test? ( test )" + +REQUIRED_USE="?? ( elogind systemd )" + +BDEPEND=" + acct-user/messagebus + app-text/xmlto + app-text/docbook-xml-dtd:4.4 + sys-devel/autoconf-archive + virtual/pkgconfig + doc? ( app-doc/doxygen ) +" +COMMON_DEPEND=" + >=dev-libs/expat-2.1.0 + elogind? ( sys-auth/elogind ) + selinux? ( sys-libs/libselinux ) + systemd? ( sys-apps/systemd:0= ) + X? ( + x11-libs/libX11 + x11-libs/libXt + ) +" +DEPEND="${COMMON_DEPEND} + dev-libs/expat + test? ( + ${PYTHON_DEPS} + >=dev-libs/glib-2.40:2 + ) +" +RDEPEND="${COMMON_DEPEND} + acct-user/messagebus + selinux? ( sec-policy/selinux-dbus ) + systemd? ( virtual/tmpfiles ) +" + +DOC_CONTENTS=" + Some applications require a session bus in addition to the system + bus. Please see \`man dbus-launch\` for more information. +" + +# out of sources build dir for make check +TBD="${WORKDIR}/${P}-tests-build" + +PATCHES=( + "${FILESDIR}/dbus-enable-elogind.patch" + "${FILESDIR}/dbus-daemon-optional.patch" # bug #653136 + + "${FILESDIR}/dbus-1.14.0-x-autoconf-fixes.patch" + "${FILESDIR}/dbus-1.12.22-check-fd.patch" + + # https://bugs.gentoo.org/836560 + "${FILESDIR}/dbus-1.14.0-oom_score_adj.patch" + + "${FILESDIR}/dbus-1.14.0-clang-15-configure.patch" +) + +pkg_setup() { + use test && python-any-r1_pkg_setup + + if use kernel_linux; then + CONFIG_CHECK="~EPOLL" + linux-info_pkg_setup + fi +} + +src_prepare() { + default + + if [[ ${CHOST} == *-solaris* ]]; then + # fix standards conflict, due to gcc being c99 by default nowadays + sed -i \ + -e 's/_XOPEN_SOURCE=500/_XOPEN_SOURCE=600/' \ + configure.ac || die + fi + + # required for bug #263909, cross-compile so don't remove eautoreconf + eautoreconf +} + +src_configure() { + local rundir=$(usex kernel_linux /run /var/run) + + sed -e "s;@rundir@;${EPREFIX}${rundir};g" "${FILESDIR}"/dbus.initd.in \ + > "${T}"/dbus.initd || die + + multilib-minimal_src_configure +} + +multilib_src_configure() { + local docconf myconf testconf + + # so we can get backtraces from apps + case ${CHOST} in + *-mingw*) + # error: unrecognized command line option '-rdynamic', bug #488036 + ;; + *) + append-flags -rdynamic + ;; + esac + + # libaudit is *only* used in DBus wrt SELinux support, so disable it, if + # not on an SELinux profile. + myconf=( + --localstatedir="${EPREFIX}/var" + $(use_enable static-libs static) + $(use_enable debug verbose-mode) + --disable-asserts + --disable-checks + $(use_enable selinux) + $(use_enable selinux libaudit) + --disable-apparmor + $(use_enable kernel_linux inotify) +
[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/, sys-apps/dbus/
commit: d312126538f24aed777addc15e0a572f9e670f58 Author: Andrew Udvare gmail com> AuthorDate: Mon Jun 20 02:59:41 2022 + Commit: Sam James gentoo org> CommitDate: Mon Jun 20 03:02:20 2022 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d3121265 sys-apps/dbus: minor shellcheck fixes * [x] Run shellcheck * [x] Use `$(...)` syntax instead of backticks * [x] Quote eval arguments Bug: https://bugs.gentoo.org/845141 Package-Manager: Portage-3.0.30, Repoman-3.0.3 Signed-off-by: Andrew Udvare gmail.com> Closes: https://github.com/gentoo/gentoo/pull/25988 Signed-off-by: Sam James gentoo.org> sys-apps/dbus/{dbus-1.14.0-r3.ebuild => dbus-1.14.0-r4.ebuild} | 0 sys-apps/dbus/files/80-dbus-r1 | 4 ++-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sys-apps/dbus/dbus-1.14.0-r3.ebuild b/sys-apps/dbus/dbus-1.14.0-r4.ebuild similarity index 100% rename from sys-apps/dbus/dbus-1.14.0-r3.ebuild rename to sys-apps/dbus/dbus-1.14.0-r4.ebuild diff --git a/sys-apps/dbus/files/80-dbus-r1 b/sys-apps/dbus/files/80-dbus-r1 index edef88a3c30c..3499a6a12eca 100644 --- a/sys-apps/dbus/files/80-dbus-r1 +++ b/sys-apps/dbus/files/80-dbus-r1 @@ -2,12 +2,12 @@ # launches a session dbus instance -dbuslaunch="`command -v dbus-launch 2>/dev/null`" +dbuslaunch=$(command -v dbus-launch 2>/dev/null) if [ -n "$dbuslaunch" ] && [ -x "$dbuslaunch" ] && [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then if [ -n "$command" ]; then command="$dbuslaunch --exit-with-session $command" else -eval `$dbuslaunch --sh-syntax --exit-with-session` +eval "$($dbuslaunch --sh-syntax --exit-with-session)" fi fi
[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/, sys-apps/dbus/
commit: 7c17fe616d1b710aa29c84bcc32c3f22417fb201 Author: Mike Gilbert gentoo org> AuthorDate: Fri Apr 22 23:51:44 2022 + Commit: Mike Gilbert gentoo org> CommitDate: Fri Apr 22 23:54:14 2022 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7c17fe61 sys-apps/dbus: do not open /proc/self/oom_score_adj for writing Bug: https://bugs.gentoo.org/836560 Closes: https://bugs.gentoo.org/839795 Bug: https://bugs.gentoo.org/839807 Closes: https://bugs.gentoo.org/839834 Closes: https://bugs.gentoo.org/839837 Closes: https://bugs.gentoo.org/840119 Closes: https://bugs.gentoo.org/840125 Closes: https://bugs.gentoo.org/840161 Signed-off-by: Mike Gilbert gentoo.org> ...{dbus-1.12.22.ebuild => dbus-1.12.22-r1.ebuild} | 6 +- .../{dbus-1.14.0.ebuild => dbus-1.14.0-r1.ebuild} | 6 +- .../dbus/files/dbus-1.14.0-oom_score_adj.patch | 115 + 3 files changed, 121 insertions(+), 6 deletions(-) diff --git a/sys-apps/dbus/dbus-1.12.22.ebuild b/sys-apps/dbus/dbus-1.12.22-r1.ebuild similarity index 99% rename from sys-apps/dbus/dbus-1.12.22.ebuild rename to sys-apps/dbus/dbus-1.12.22-r1.ebuild index 0491fc1085d8..6490a2e922d7 100644 --- a/sys-apps/dbus/dbus-1.12.22.ebuild +++ b/sys-apps/dbus/dbus-1.12.22-r1.ebuild @@ -64,6 +64,9 @@ PATCHES=( "${FILESDIR}/dbus-daemon-optional.patch" # bug #653136 "${FILESDIR}/dbus-1.12.22-check-fd.patch" + + # https://bugs.gentoo.org/836560 + "${FILESDIR}/dbus-1.14.0-oom_score_adj.patch" ) pkg_setup() { @@ -207,9 +210,6 @@ multilib_src_compile() { } src_test() { - # https://bugs.gentoo.org/836560 - addwrite /proc/self - DBUS_VERBOSE=1 virtx emake -j1 -C "${TBD}" check } diff --git a/sys-apps/dbus/dbus-1.14.0.ebuild b/sys-apps/dbus/dbus-1.14.0-r1.ebuild similarity index 99% rename from sys-apps/dbus/dbus-1.14.0.ebuild rename to sys-apps/dbus/dbus-1.14.0-r1.ebuild index 2cddb00c4761..ce9df1f58e2e 100644 --- a/sys-apps/dbus/dbus-1.14.0.ebuild +++ b/sys-apps/dbus/dbus-1.14.0-r1.ebuild @@ -68,6 +68,9 @@ PATCHES=( "${FILESDIR}/dbus-1.14.0-x-autoconf-fixes.patch" "${FILESDIR}/dbus-1.12.22-check-fd.patch" + + # https://bugs.gentoo.org/836560 + "${FILESDIR}/dbus-1.14.0-oom_score_adj.patch" ) pkg_setup() { @@ -207,9 +210,6 @@ multilib_src_compile() { } src_test() { - # https://bugs.gentoo.org/836560 - addwrite /proc - # DBUS_TEST_MALLOC_FAILURES=0 to avoid huge test logs # https://gitlab.freedesktop.org/dbus/dbus/-/blob/master/CONTRIBUTING.md#L231 DBUS_TEST_MALLOC_FAILURES=0 DBUS_VERBOSE=1 virtx emake -j1 -C "${TBD}" check diff --git a/sys-apps/dbus/files/dbus-1.14.0-oom_score_adj.patch b/sys-apps/dbus/files/dbus-1.14.0-oom_score_adj.patch new file mode 100644 index ..094529708088 --- /dev/null +++ b/sys-apps/dbus/files/dbus-1.14.0-oom_score_adj.patch @@ -0,0 +1,115 @@ +From 499cdfde1b3f5d812912e89b1a1a0d7a4fb83306 Mon Sep 17 00:00:00 2001 +From: Simon McVittie +Date: Fri, 1 Apr 2022 18:58:34 +0100 +Subject: [PATCH 1/2] activation-helper: Never crash if unable to write + oom_score_adj + +_dbus_warn() normally only logs a warning, but can be made fatal by +environment variables. In particular, we do that during unit testing, +which can result in a build-time test failure if dbus is built in a +sandbox environment that prevents write access. + +_dbus_log() does only the logging part of _dbus_warn(), which seems +more appropriate here. + +Signed-off-by: Simon McVittie +--- + bus/activation-helper.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/bus/activation-helper.c b/bus/activation-helper.c +index 8a4fd732..df0472ce 100644 +--- a/bus/activation-helper.c b/bus/activation-helper.c +@@ -348,7 +348,7 @@ exec_for_correct_user (char *exec, char *user, DBusError *error) + /* Resetting the OOM score adjustment is best-effort, so we don't +* treat a failure to do so as fatal. */ + if (!_dbus_reset_oom_score_adj (&error_str)) +-_dbus_warn ("%s: %s", error_str, strerror (errno)); ++_dbus_log (DBUS_SYSTEM_LOG_WARNING, "%s: %s", error_str, strerror (errno)); + + if (!switch_user (user, error)) + return FALSE; +-- +GitLab + + +From 5c8e5b7140c4f1f88684c7a83ce9587fff2def0c Mon Sep 17 00:00:00 2001 +From: Simon McVittie +Date: Fri, 1 Apr 2022 18:56:26 +0100 +Subject: [PATCH 2/2] sysdeps: Only open oom_score_adj read/write if we need to + write it + +If we're running in a sandbox, we might not have write access to +oom_score_adj. In the common case where we don't have any special +protection from the OOM-killer, we can detect that with only read +access, and skip the part where we open it for writing. + +(We would also not have write access to oom_score_adj if we're running +with elevated Linux capabilities while not root, but that should never +actually happen for dbus-daemon-launch-helper, which is setuid root +for production use or has no ca
[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/, sys-apps/dbus/
commit: 74020795b5786fd4963fdd1823c2aa302273a3c5 Author: Sam James gentoo org> AuthorDate: Sun Mar 27 22:38:49 2022 + Commit: Sam James gentoo org> CommitDate: Sun Mar 27 22:40:46 2022 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=74020795 sys-apps/dbus: add 1.14.0 Signed-off-by: Sam James gentoo.org> sys-apps/dbus/Manifest | 1 + sys-apps/dbus/dbus-1.14.0.ebuild | 287 + .../dbus/files/dbus-1.14.0-x-autoconf-fixes.patch | 147 +++ 3 files changed, 435 insertions(+) diff --git a/sys-apps/dbus/Manifest b/sys-apps/dbus/Manifest index e530cbf7268b..19ec71675e81 100644 --- a/sys-apps/dbus/Manifest +++ b/sys-apps/dbus/Manifest @@ -1,2 +1,3 @@ DIST dbus-1.12.20.tar.gz 2095511 BLAKE2B b467526e7e0281db7b8c7c178469fe006dab29ccb1ea197c02495bd297e8de766230b68ed86c4a7e05dbe09ca30ce941a15e0bf8030fe0df66c04febf0534b3b SHA512 0964683bc6859374cc94e42e1ec0cdb542cca67971c205fcba4352500b6c0891665b0718e7d85eb060c81cb82e3346c313892bc02384da300ddd306c7eef0056 DIST dbus-1.12.22.tar.gz 2108231 BLAKE2B 40c30ad9e48d8ac6b5f1c67726015eb17cb3501372ef2c8ffcd8ad73e4a2f186b80a7bbba094460d4093d1d0a3f1bbb8d83a27724397a8f5312bb8542237e6b7 SHA512 0a716022f9d693fcaf871b6dfb5f242b49a8dd05d3316ec3e530f5129f1d81a2fa9caec795fa62cfdcba6ed21549fdd2f896f9bf1cc9a96e2a7d04f2c7ec7be6 +DIST dbus-1.14.0.tar.xz 1360228 BLAKE2B ae0ebc2779e840e2d83f633029f81fba0e35969648dddce0280640dd9bee3f9508aa7fb6aef696d1c4c56d40f91b754941f847525afaee5cc3170ad23a7eddbf SHA512 9bf17a3ebb3cf44722c6fbf24ee56e9dc14d6882fc312f26c7f07459d969424bc2fb63a229139e011804ecc479a8f0eb1a0c83286f8d5a664c5979d12634179f diff --git a/sys-apps/dbus/dbus-1.14.0.ebuild b/sys-apps/dbus/dbus-1.14.0.ebuild new file mode 100644 index ..03e772f142c6 --- /dev/null +++ b/sys-apps/dbus/dbus-1.14.0.ebuild @@ -0,0 +1,287 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{8..10} ) +TMPFILES_OPTIONAL=1 + +# At least at the moment, while a CMake port exists, it's not recommended +# for distributions. +# https://gitlab.freedesktop.org/dbus/dbus/-/blob/master/CONTRIBUTING.md#L189 +inherit autotools flag-o-matic linux-info python-any-r1 readme.gentoo-r1 systemd tmpfiles virtualx multilib-minimal + +DESCRIPTION="A message bus system, a simple way for applications to talk to each other" +HOMEPAGE="https://www.freedesktop.org/wiki/Software/dbus/"; +SRC_URI="https://dbus.freedesktop.org/releases/dbus/${P}.tar.xz"; + +LICENSE="|| ( AFL-2.1 GPL-2 )" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="debug doc elogind selinux static-libs systemd test X" +RESTRICT="!test? ( test )" + +REQUIRED_USE="?? ( elogind systemd )" + +BDEPEND=" + acct-user/messagebus + app-text/xmlto + app-text/docbook-xml-dtd:4.4 + sys-devel/autoconf-archive + virtual/pkgconfig + doc? ( app-doc/doxygen ) +" +COMMON_DEPEND=" + >=dev-libs/expat-2.1.0 + elogind? ( sys-auth/elogind ) + selinux? ( sys-libs/libselinux ) + systemd? ( sys-apps/systemd:0= ) + X? ( + x11-libs/libX11 + x11-libs/libXt + ) +" +DEPEND="${COMMON_DEPEND} + dev-libs/expat + test? ( + ${PYTHON_DEPS} + >=dev-libs/glib-2.40:2 + ) +" +RDEPEND="${COMMON_DEPEND} + acct-user/messagebus + selinux? ( sec-policy/selinux-dbus ) + systemd? ( virtual/tmpfiles ) +" + +DOC_CONTENTS=" + Some applications require a session bus in addition to the system + bus. Please see \`man dbus-launch\` for more information. +" + +# out of sources build dir for make check +TBD="${WORKDIR}/${P}-tests-build" + +PATCHES=( + "${FILESDIR}/${PN}-enable-elogind.patch" + "${FILESDIR}/${PN}-daemon-optional.patch" # bug #653136 + + "${FILESDIR}/${P}-x-autoconf-fixes.patch" +) + +pkg_setup() { + use test && python-any-r1_pkg_setup + + if use kernel_linux; then + CONFIG_CHECK="~EPOLL" + linux-info_pkg_setup + fi +} + +src_prepare() { + default + + if [[ ${CHOST} == *-solaris* ]]; then + # fix standards conflict, due to gcc being c99 by default nowadays + sed -i \ + -e 's/_XOPEN_SOURCE=500/_XOPEN_SOURCE=600/' \ + configure.ac || die + fi + + # required for bug #263909, cross-compile so don't remove eautoreconf + eautoreconf +} + +src_configure() { + local rundir=$(usex kernel_linux /run /var/run) + + sed -e "s;@rundir@;${EPREFIX}${rundir};g" "${FILESDIR}"/dbus.initd.in \ + > "${T}"/dbus.initd || die + + multilib-minimal_src_configure +}
[gentoo-commits] repo/gentoo:master commit in: sys-apps/dbus/files/
commit: a1a3bb0fc62b6944db42955147d3c954a44394aa Author: Michael Mair-Keimberger gmail com> AuthorDate: Mon Jun 22 18:16:48 2020 + Commit: Conrad Kostecki gentoo org> CommitDate: Thu Jun 25 07:30:39 2020 + URL:https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a1a3bb0f sys-apps/dbus: remove unused file Closes: https://github.com/gentoo/gentoo/pull/16376 Package-Manager: Portage-2.3.101, Repoman-2.3.22 Signed-off-by: Michael Mair-Keimberger gmail.com> Signed-off-by: Conrad Kostecki gentoo.org> sys-apps/dbus/files/dbus.initd-r1 | 36 1 file changed, 36 deletions(-) diff --git a/sys-apps/dbus/files/dbus.initd-r1 b/sys-apps/dbus/files/dbus.initd-r1 deleted file mode 100644 index bd3542381a7..000 --- a/sys-apps/dbus/files/dbus.initd-r1 +++ /dev/null @@ -1,36 +0,0 @@ -#!/sbin/openrc-run -# Copyright 1999-2016 Gentoo Foundation -# Distributed under the terms of the GNU General Public License, v2 or later - -extra_started_commands="reload" - -description="An IPC message bus daemon" -pidfile="/var/run/dbus.pid" -command="/usr/bin/dbus-daemon" -command_args="--system" - -dbus_socket="/var/run/dbus/system_bus_socket" - -depend() { - need localmount - after bootmisc -} - -start_pre() { - /usr/bin/dbus-uuidgen --ensure=/etc/machine-id - - # We need to test if /var/run/dbus exists, since script will fail if it does not - checkpath -q -d /var/run/dbus -} - -stop_post() { - [ ! -S "${dbus_socket}" ] || rm -f "${dbus_socket}" -} - -reload() { - ebegin "Reloading D-BUS messagebus config" - /usr/bin/dbus-send --print-reply --system --type=method_call \ - --dest=org.freedesktop.DBus \ - / org.freedesktop.DBus.ReloadConfig > /dev/null - eend $? -}