- Bump to version 12
- Introduce %sysusers_create_package
%sysusers_create and %sysusers_create_inline are now deprecated and
the new macro should be used instead.
Upstream commit 07a7d4a0040d221ff09e527e91c112b4ffab1dba.
- Introduce %tmpfiles_create_package
%%tmpfiles_create is now deprecreated and the new macros should be
used instead.
Upstream commit 0f78fee8d039000b987848a558fbaa15d916e14e.
- %sysusers_create_inline: use here-docs instead of echo (bsc#1186282)
Upstream commit dd2490ae12ad1e1795ecbf8f8944b950da9c8d06.
OBS-URL: https://build.opensuse.org/request/show/894598
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=35
%sysusers_create and %sysusers_create_inline are now deprecated and
the new macro should be used instead.
Upstream commit 07a7d4a0040d221ff09e527e91c112b4ffab1dba.
- Introduce %tmpfiles_create_package
%%tmpfiles_create is now deprecreated and the new macros should be
used instead.
Upstream commit 0f78fee8d039000b987848a558fbaa15d916e14e.
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=67
- Bump to version 11
- Don't pass -f to rm in %service_add_post nor %systemd_user_post
- Add a %systemd_user_pre macro that creates a
/run/systemd/rpm/needs-user-preset/$service file for each new
service being installed so %systemd_user_post can call
`systemctl --global preset $service` properly for newly
installed user services (boo#1183051, boo#1183012).
- Fix %systemd_user_post. The --global parameter was handled as if
it was another service name so %systemd_user_post wasn't working
properly. Replace %systemd_user_post with the code from
%service_add_post it was being expanded to but correctly passing
--global to systemctl (boo#1183051, boo#1182661).
OBS-URL: https://build.opensuse.org/request/show/877267
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=34
- Bump version to 10
- Make upstream %systemd_{pre,post,preun,postun} aliases to their SUSE
counterparts
Packagers can now choose to use the upstream or the SUSE variants
indifferently. For consistency the SUSE variants should be preferred
since almost all SUSE packages already use them but the upstream
versions might be usefull in certain cases where packages need to
support multiple distros based on RPM.
- Improve the logic used to apply the presets (bsc#1177039)
Before presests were applied at a) package installation b) new units
introduced via a package update (but after making sure that it was
not a SysV initscript being converted).
The problem is that a) didn't handle package a renaming or split
properly since the package with the new name is installed rather
being updated and therefore the presets were applied even if they
were already with the old name.
We now cover this case (and the other ones) by applying presets only
if the units are new and the services are not being migrated. This
regardless of whether this happens during an install or an update.
OBS-URL: https://build.opensuse.org/request/show/871420
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=33
counterparts
Packagers can now choose to use the upstream or the SUSE variants
indifferently. For consistency the SUSE variants should be preferred
since almost all SUSE packages already use them but the upstream
versions might be usefull in certain cases where packages need to
support multiple distros based on RPM.
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=60
Before presests were applied at a) package installation b) new units
introduced via a package update (but after making sure that it was
not a SysV initscript being converted).
The problem is that a) didn't handle package a renaming or split
properly since the package with the new name is installed rather
being updated and therefore the presets were applied even if they
were already with the old name.
We now cover this case (and the other ones) by applying presets only
if the units are new and the services are not being migrated. This
regardless of whether this happens during an install or an update.
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=59
- Bump version to 9
- daemon-reload is not needed in %service_add_post
Applying presets, ie enabling/disabling units, doesn't require to
update units loaded in PID1 memory. It's actually needed after and
it's done implicitly by `systemctl preset`.
- Rename the tag file used to detect when presets need to be applied
Rather than placing these tags directly under /run, let's place them
under /run/systemd/rpm. This also has the benefit to make the
workaround for bsc#1059627 no more needed.
- %service_del_preun doesn't accept -f/-n options anymore
The few package calling %service_del_preun with '-f' or '-n' option
have been fixed. These options are not needed anymore.
OBS-URL: https://build.opensuse.org/request/show/850414
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=32
- Bump version to 8
- Introduce %service_del_postun_with_restart()
It's the counterpart of %service_del_postun_without_restart() and
replaces the '-f' option of %service_del_postun().
- Expand %service_del_postun_without_restart in %service_del_postun
- Add a missing space in %_restart_on_update()
- Bump version to 7
- Dont apply presets when migrating from a disabled initscript (bsc#1178481)
- Bump version to 6
- Test for the presence of systemd only once in %service_add_post
- No need to run 'systemd-sysv-convert --save' in %service_add_pre anymore
Due to the fact that the initscripts being removed during package
updates are still available in %post, systemd-sysv-convert has been
reworked so it's only needed to call it in %post.
- Make rpmbuild load our own macros.systemd to import %{%_unitdir} properly
Ideally we should also own other %{_*dir} paths...
- Stop owning /usr/lib/systemd directory as no package other than
systemd is supposed to put files there.
- DISABLE_RESTART_ON_UDPATE is no more read from the (build) environment
%service_del_postun_without_restart is the interface that should be
used by packages that need to prevent theirs services from being
OBS-URL: https://build.opensuse.org/request/show/847458
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=31