commit: 3596d78eecd4444b6792662c00b92e8b7214c3ca Author: David Michael <fedora.dm0 <AT> gmail <DOT> com> AuthorDate: Mon Jun 28 18:00:42 2021 +0000 Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> CommitDate: Tue Jun 29 16:20:31 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3596d78e
systemd.eclass: drop deprecated tmpfiles functions Closes: https://bugs.gentoo.org/740638 Signed-off-by: David Michael <fedora.dm0 <AT> gmail.com> Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org> Closes: https://github.com/gentoo/gentoo/pull/21462 eclass/systemd.eclass | 65 --------------------------------------------------- 1 file changed, 65 deletions(-) diff --git a/eclass/systemd.eclass b/eclass/systemd.eclass index ab0d6561984..397a863cf25 100644 --- a/eclass/systemd.eclass +++ b/eclass/systemd.eclass @@ -237,48 +237,6 @@ systemd_install_serviced() { ) } -# @FUNCTION: systemd_dotmpfilesd -# @USAGE: <tmpfilesd>... -# @DESCRIPTION: -# Deprecated in favor of tmpfiles.eclass. -# -# Install systemd tmpfiles.d files. Uses doins, thus it is fatal -# in EAPI 4 and non-fatal in earlier EAPIs. -systemd_dotmpfilesd() { - debug-print-function ${FUNCNAME} "${@}" - - for f; do - [[ ${f} == *.conf ]] \ - || die 'tmpfiles.d files need to have .conf suffix.' - done - - ( - insopts -m 0644 - insinto /usr/lib/tmpfiles.d/ - doins "${@}" - ) -} - -# @FUNCTION: systemd_newtmpfilesd -# @USAGE: <old-name> <new-name>.conf -# @DESCRIPTION: -# Deprecated in favor of tmpfiles.eclass. -# -# Install systemd tmpfiles.d file under a new name. Uses newins, thus it -# is fatal in EAPI 4 and non-fatal in earlier EAPIs. -systemd_newtmpfilesd() { - debug-print-function ${FUNCNAME} "${@}" - - [[ ${2} == *.conf ]] \ - || die 'tmpfiles.d files need to have .conf suffix.' - - ( - insopts -m 0644 - insinto /usr/lib/tmpfiles.d/ - newins "${@}" - ) -} - # @FUNCTION: systemd_enable_service # @USAGE: <target> <service> # @DESCRIPTION: @@ -436,29 +394,6 @@ systemd_is_booted() { return ${ret} } -# @FUNCTION: systemd_tmpfiles_create -# @USAGE: <tmpfilesd> ... -# @DESCRIPTION: -# Deprecated in favor of tmpfiles.eclass. -# -# Invokes systemd-tmpfiles --create with given arguments. -# Does nothing if ROOT != / or systemd-tmpfiles is not in PATH. -# This function should be called from pkg_postinst. -# -# Generally, this function should be called with the names of any tmpfiles -# fragments which have been installed, either by the build system or by a -# previous call to systemd_dotmpfilesd. This ensures that any tmpfiles are -# created without the need to reboot the system. -systemd_tmpfiles_create() { - debug-print-function ${FUNCNAME} "${@}" - - [[ ${EBUILD_PHASE} == postinst ]] || die "${FUNCNAME}: Only valid in pkg_postinst" - [[ ${#} -gt 0 ]] || die "${FUNCNAME}: Must specify at least one filename" - [[ ${ROOT:-/} == / ]] || return 0 - type systemd-tmpfiles &> /dev/null || return 0 - systemd-tmpfiles --create "${@}" -} - # @FUNCTION: systemd_reenable # @USAGE: <unit> ... # @DESCRIPTION:
