
mgorny at gentoo
Aug 20, 2012, 3:24 PM
Post #1 of 1
(69 views)
Permalink
|
|
[PATCH systemd.eclass 1/3] Add systemd_newtmpfilesd().
|
|
In pair with systemd_dotmpfilesd(), they will be the canonical functions to install tmpfiles.d files. I've talked with Sergei and we agreed to not move the functions around but leave systemd.eclass as the canonical source of locations for systemd-related files. The eclass will not introduce any dependencies or other side effects. Uses inline ( insinto; newins ) because of Diego's disapproval of newinto function into eutils. Feel free to fix it as soon as we get such a thing into EAPI and remove all EAPIs up to 4. --- gx86/eclass/systemd.eclass | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/gx86/eclass/systemd.eclass b/gx86/eclass/systemd.eclass index 1ddc9b0..4066e31 100644 --- a/gx86/eclass/systemd.eclass +++ b/gx86/eclass/systemd.eclass @@ -95,6 +95,20 @@ systemd_dotmpfilesd() { ) } +# @FUNCTION: systemd_newtmpfilesd +# @USAGE: oldname newname.conf +# @DESCRIPTION: +# 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} "${@}" + + ( + insinto /usr/lib/tmpfiles.d/ + newins "${@}" + ) +} + # @FUNCTION: systemd_enable_service # @USAGE: target service # @DESCRIPTION: -- 1.7.11.1
|