146 Commits

Author SHA256 Message Date
e505f87a5f Accepting request 1094319 from Base:System
- Bump to version 24

- Drop %tmpfiles_create_package
  It can't work during transactional updates because the paths that
  systemd-tmpfiles usually operates on (such as /var) can't be changed. It
  appears that the only user of this macro doesn't really need this macro so
  let's drop it.

- Drop %sysusers_create_inline
  It's deprecated and the only user of this macro is being converted to
  %sysusers_create_package. So drop it now before the deprecated macro attracts
  more users.

- Unlike systemd-tmpfiles call in %tmpfiles_create_package(), systemd-sysusers
  must always be called by %sysusers_create_package() even on transactional
  systems since it's part of the macro contract. Writing to /etc is not
  recommended on such systems but it has to work anyways.

OBS-URL: https://build.opensuse.org/request/show/1094319
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=47
2023-06-23 19:52:20 +00:00
0cc0342925 - Bump to version 24
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=101
2023-06-21 08:51:21 +00:00
4dc045d4df - Drop %tmpfiles_create_package
It can't work during transactional updates because the paths that
  systemd-tmpfiles usually operates on (such as /var) can't be changed. It
  appears that the only user of this macro doesn't really need this macro so
  let's drop it.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=100
2023-06-20 16:04:19 +00:00
ca23be8300 - Drop %sysusers_create_inline
It's deprecated and the only user of this macro is being converted to
  %sysusers_create_package. So drop it now before the deprecated macro attracts
  more users.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=99
2023-06-20 16:00:45 +00:00
ff6965c5cb - Unlike systemd-tmpfiles call in %tmpfiles_create_package(), systemd-sysusers
must always be called by %sysusers_create_package() even on transactional
  systems since it's part of the macro contract. Writing to /etc is not
  recommended on such systems but it has to work anyways.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=98
2023-06-20 15:01:29 +00:00
3f53730fbd Accepting request 1093498 from Base:System
- Bump to version 23

- Restore the check that prevents systemd-tmpfiles to run during transactional updates
  The check has been mistakenly dropped during the switch to file-triggers.

OBS-URL: https://build.opensuse.org/request/show/1093498
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=46
2023-06-16 14:53:13 +00:00
695ae9a4b5 - Bump to version 23
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=97
2023-06-16 13:11:51 +00:00
8cd9f77cbf - Restore the check that prevents systemd-tmpfiles to run during transactional updates
The check has been mistakenly dropped during the switch to file-triggers.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=96
2023-06-16 13:11:13 +00:00
5c9fe37785 Accepting request 1087187 from Base:System
- Bump to version 22

- Make sure that (future) users of %sysctl_apply() and %binfmt_apply() will call
  the macros with arguments.

- Test the presence of /run/systemd/system to check whether we're operating
  during transactional updates. Hence the behavior is the same when operating in
  a chroot or during transactional updates.
- Leave %sysctl_apply() and %binfmt_apply() empty (bsc#1211272)
  Only the former has very few users currently and none of them has specific
  code relying on the new sysctl values to be effective between the macros and
  the file triggers.

- Bump to version 21

- Rely on 'systemd-update-helper' shell script to implement %service_* macros
  The helper was introduced by upstream commit 6d825ab2d42d3219e49a1. The main
  advantage is that we no more need to rebuild all packages to update the macro
  definitions.
  Internally the script relies on file triggers for 'daemon-reload' operations
  and for restarting units (when needed).
- Update other macros to reflect the fact that systemd package provides file
  triggers for sysusers, tmpfiles, hwdb, and journal catalog.

OBS-URL: https://build.opensuse.org/request/show/1087187
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=45
2023-05-24 18:21:22 +00:00
25a2295a3a - Bump to version 22
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=95
2023-05-15 09:21:44 +00:00
db8376beab fix %tmpfiles_create_package and drop 'fi' leftover
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=94
2023-05-15 09:21:10 +00:00
ba6e5f27b2 avoid macros with empty bodies
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=93
2023-05-11 09:29:22 +00:00
9fee5b69d2 adjust the 2 last entries of the changlog
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=92
2023-05-10 16:28:52 +00:00
c32fb55b29 - Make sure that (futur) users of %sysctl_apply() and %binfmt_apply() will call
the macros with arguments.
- Leave %sysctl_apply() and %binfmt_apply() empty (bsc#1211272)
  Only the former has very few users currently and none of them has specific
  code relying on the new sysctl values between the macros and the file
  triggers.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=91
2023-05-10 12:40:05 +00:00
2aa56d936f update previous changelog entry
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=90
2023-05-10 10:00:07 +00:00
1ac61c191a - Test the presence of /run/systemd/system to check whether we're operating
during transactional updates. Hence the behavior is the same when operating in
  a chroot or during transactional updates.
- Leave %sysctl_apply() and %binfmt_apply() empty as there's no (interesting)
  user of these macros for now.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=89
2023-05-10 09:30:02 +00:00
d7c94ee34f - Bump to version 21
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=88
2023-05-09 14:09:59 +00:00
a97f9f97e5 - Rely on 'systemd-update-helper' shell script to implement %service_* macros
The helper was introduced by upstream commit 6d825ab2d42d3219e49a1. The main
  advantage is that we no more need to rebuild all packages to update the macro
  definitions.
  Internally the script relies on file triggers for 'daemon-reload' operations
  and for restarting units (when needed).
- Update other macros to reflect the fact that systemd package provides file
  triggers for sysusers, tmpfiles, hwdb, and journal catalog.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=87
2023-05-09 14:09:13 +00:00
65e4499aad Accepting request 1075207 from Base:System
- Bump to version 20

- %service_del_postun: make sure to restart services if /etc/sysconfig/service
  is not present.

- Drop support for -n/-f options in %service_del_postun
  These options have been deprecated since a long time and the last package
  relying on them (drkonqi5) in the Factory repository has been updated.

OBS-URL: https://build.opensuse.org/request/show/1075207
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=44
2023-04-03 15:45:18 +00:00
bd396a705f - Bump to version 20
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=86
2023-03-29 11:38:28 +00:00
3b2c7f4694 - %service_del_postun: make sure to restart services if /etc/sysconfig/service
is not present.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=85
2023-03-29 11:35:52 +00:00
3d2aa53763 - Drop support for -n/-f options in %service_del_postun
These options have been deprecated since a long time and the last package
  relying on them (drkonqi5) in the Factory repository has been updated.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=84
2023-03-29 10:42:15 +00:00
ee0e9c503a Accepting request 1061222 from Base:System
- Bump to version 19

- `udevadm hwdb` is deprecated, use `systemd-hwdb` instead.

OBS-URL: https://build.opensuse.org/request/show/1061222
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=43
2023-01-28 17:42:42 +00:00
a8a48f191f - Bump to version 19
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=83
2023-01-26 14:12:56 +00:00
ef8c808e84 - udevadm hwdb is deprecated, use systemd-hwdb instead.
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=82
2023-01-26 14:11:52 +00:00
5e6ce41a2e Accepting request 1037703 from Base:System
- Bump to version 18

- Add %_user_tmpfilesdir macro

OBS-URL: https://build.opensuse.org/request/show/1037703
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=42
2022-11-25 12:11:09 +00:00
c89bcb87a5 - Bump to version 18
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=81
2022-11-23 17:14:27 +00:00
ccdb965aa5 Accepting request 1037656 from home:dancermak:branches:Base:System
Add %_user_tmpfilesdir macro

OBS-URL: https://build.opensuse.org/request/show/1037656
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=80
2022-11-23 17:12:56 +00:00
4d32552d81 Accepting request 1007693 from Base:System
- Bump to version 17

- Fix syntax error in %tmpfiles_create_package() (bsc#1203945)

OBS-URL: https://build.opensuse.org/request/show/1007693
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=41
2022-10-10 16:43:05 +00:00
756bd2c050 - Bump to version 17
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=79
2022-10-03 13:08:03 +00:00
4680d9ecb7 - Fix syntax error in %tmpfiles_create_package() (bsc#1203945)
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=78
2022-10-03 13:00:50 +00:00
4179f1a8d5 Accepting request 955694 from Base:System
- Bump to version 16

- Drop enablement symlink migration support of SysV init scripts
  This was announced here:
  https://lists.opensuse.org/archives/list/factory@lists.opensuse.org/thread/3ERUP5ZZJ6PPA36L3HVN46BH6U6JL74O/

OBS-URL: https://build.opensuse.org/request/show/955694
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=40
2022-02-19 18:21:13 +00:00
5b629403ed - Bump to version 16
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=77
2022-02-17 18:53:38 +00:00
8609970ea8 - Drop enablement symlink migration support of SysV init scripts
This was announced here:
  https://lists.opensuse.org/archives/list/factory@lists.opensuse.org/thread/3ERUP5ZZJ6PPA36L3HVN46BH6U6JL74O/

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=76
2022-02-17 18:53:00 +00:00
af577426eb Accepting request 947356 from Base:System
- Bump to version 15

- %sysusers_create_inline was wrongly marked as deprecated
- %sysusers_create can be useful in certain cases and won't go away until we'll
  move to file triggers. So don't mark it as deprecated too

OBS-URL: https://build.opensuse.org/request/show/947356
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=39
2022-01-22 07:17:46 +00:00
ccdcf965ab - Bump to version 15
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=75
2022-01-19 08:27:38 +00:00
ccdbdfce8d - %sysusers_create_inline was wrongly marked as deprecated
- %sysusers_create can be useful in certain cases and won't go away until we'll
  move to file triggers. So don't mark it as deprecated too

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=74
2022-01-18 21:06:57 +00:00
c89bed18ac Accepting request 931955 from Base:System
- Bump version to 14

- Introduce %_systemd_util_dir
  It's a backport of upstream commit 3bc66bfa0136e370a8f7b06c3b69a52f5636ef82.

OBS-URL: https://build.opensuse.org/request/show/931955
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=38
2021-11-21 22:51:15 +00:00
6f9fe0af97 - Bump version to 14
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=73
2021-11-17 12:31:01 +00:00
bbea6a0733 - Introduce %_systemd_util_dir
It's a backport of upstream commit 3bc66bfa0136e370a8f7b06c3b69a52f5636ef82.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=72
2021-11-17 12:27:43 +00:00
e39be33398 Accepting request 922188 from Base:System
OBS-URL: https://build.opensuse.org/request/show/922188
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=37
2021-10-25 13:16:41 +00:00
818d21e58d Accepting request 922165 from home:dimstar:Factory
- Use %{load:} instead of %{?load:}: fix build with RPM 4.17.

OBS-URL: https://build.opensuse.org/request/show/922165
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=71
2021-09-29 13:21:24 +00:00
efa0f81b4c Accepting request 903200 from Base:System
- Bump to version 13

- Make use of "Suggests:" in %systemd_ordering
  Until libzypp supports "OrderWithRequires:", we need to specify a
  similar ordering constraint that can be understood by the dep solver
  as well. Hence the use of "Suggests:" in %systemd_ordering
  (workaround for bsc#1187332).

OBS-URL: https://build.opensuse.org/request/show/903200
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd-rpm-macros?expand=0&rev=36
2021-07-03 18:50:32 +00:00
4a8a20b75d - Bump to version 13
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=70
2021-06-30 09:59:52 +00:00
ad43e5ad9f - Make use of "Suggests:" in %systemd_ordering
Until libzypp supports "OrderWithRequires:", we need to specify a
  similar ordering constraint that can be understood by the dep solver
  as well. Hence the use of "Suggests:" in %systemd_ordering
  (workaround for bsc#1187332).

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=69
2021-06-30 09:59:17 +00:00
a42dcffc95 Accepting request 894598 from Base:System
- 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
2021-05-23 21:30:19 +00:00
bbc4a5b794 - Bump to version 12
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=68
2021-05-20 10:18:45 +00:00
37d00203df - 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.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=67
2021-05-20 10:17:34 +00:00
f0c8ea9afc - %sysusers_create_inline: use here-docs instead of echo (bsc#1186282)
Upstream commit dd2490ae12ad1e1795ecbf8f8944b950da9c8d06.

OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd-rpm-macros?expand=0&rev=66
2021-05-20 09:47:35 +00:00
35bb9dbe84 Accepting request 877267 from Base:System
- 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
2021-03-11 19:06:48 +00:00