From 9a171b220f992fa0ce2aa46da4eef2669882544b Mon Sep 17 00:00:00 2001 From: Colin Walters <walters> Date: Tue, 16 Aug 2016 16:41:56 -0400 Subject: [PATCH] Port away from Lua for %posttrans Since we know we have a shell, there's no good reason to use Lua here. This ensures we work with rpm-ostree, which doesn't implement Lua right now, and I'd like to avoid doing so as long as possible. http://lists.rpm.org/pipermail/rpm-ecosystem/2016-August/000391.html --- glibc.spec | 35 +++++++++++++++-------------------- 1 file changed, 15 insertions(+), 20 deletions(-) diff --git a/glibc.spec b/glibc.spec index f9d8ca7..7813fd6 100644 --- a/glibc.spec +++ b/glibc.spec @@ -1,6 +1,6 @@ %define glibcsrcdir glibc-2.24-47-gf792117 %define glibcversion 2.24.90 -%define glibcrelease 2%{?dist} +%define glibcrelease 42.nolua%{?dist} # Pre-release tarballs are pulled in from git using a command that is # effectively: # @@ -2064,26 +2064,21 @@ end %postun -p /sbin/ldconfig -%posttrans all-langpacks -e -p <lua> --- If at the end of the transaction we are still installed --- (have a template of non-zero size), then we rebuild the --- locale cache (locale-archive) from the pre-populated --- locale cache (locale-archive.tmpl) i.e. template. -if posix.stat("%{_prefix}/lib/locale/locale-archive.tmpl", "size") > 0 then - pid = posix.fork() - if pid == 0 then - posix.exec("%{_prefix}/sbin/build-locale-archive", "--install-langs", "%%{_install_langs}") - elseif pid > 0 then - posix.wait(pid) - end -end +# If at the end of the transaction we are still installed +# (have a template of non-zero size), then we rebuild the +# locale cache (locale-archive) from the pre-populated +# locale cache (locale-archive.tmpl) i.e. template. +%posttrans all-langpacks -e +if test -s "%{_prefix}/lib/locale/locale-archive.tmpl"; then + %{_prefix}/sbin/build-locale-archive --install-langs "%%{_install_langs}" +fi -%postun all-langpacks -p <lua> --- In the postun we always remove the locale cache. --- We are being uninstalled and if this is an upgrade --- then the new packages template will be used to --- recreate a new copy of the cache. -os.remove("%{_prefix}/lib/locale/locale-archive") +# In the postun we always remove the locale cache. +# We are being uninstalled and if this is an upgrade +# then the new packages template will be used to +# recreate a new copy of the cache. +%postun all-langpacks +rm -f %{_prefix}/lib/locale/locale-archive %if %{with docs} %post devel -- 2.7.4
This bug appears to have been reported against 'rawhide' during the Fedora 26 development cycle. Changing version to '26'.
Can someone review this please?
(In reply to Colin Walters from comment #2) > Can someone review this please? Sure, we can review and test this. When do you need this fixed by?
It's not an immediate need, but it blocks https://github.com/projectatomic/rpm-ostree/issues/729 and also `rpm-ostree ex container`, which can be dramatically faster than traditional dnf/yum rootfs assembly - the primary target is using it for buildroots.
(In reply to Carlos O'Donell from comment #3) > (In reply to Colin Walters from comment #2) > > Can someone review this please? > > Sure, we can review and test this. When do you need this fixed by? Any ETA?
(In reply to Dusty Mabe from comment #5) > (In reply to Carlos O'Donell from comment #3) > > (In reply to Colin Walters from comment #2) > > > Can someone review this please? > > > > Sure, we can review and test this. When do you need this fixed by? > > Any ETA? Probably some time in the next rawhide cycle we'll cleanup a few of these outstanding patches. Do you have a workaround for this? Is it blocking your progress?
This bug appears to have been reported against 'rawhide' during the Fedora 27 development cycle. Changing version to '27'.
https://github.com/projectatomic/rpm-ostree/pull/980
This bug appears to have been reported against 'rawhide' during the Fedora 28 development cycle. Changing version to '28'.
This message is a reminder that Fedora 28 is nearing its end of life. On 2019-May-28 Fedora will stop maintaining and issuing updates for Fedora 28. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '28'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 28 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 28 changed to end-of-life (EOL) status on 2019-05-28. Fedora 28 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle. Changing version to '31'.
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle. Changing version to 31.
We need one Lua %posttrans for backwards compatibility with older glibc packages. This is not an issue for your use-case, though? I think it will work just to ignore the script.
> We need one Lua %posttrans for backwards compatibility with older glibc packages. This is not an issue for your use-case, though? I think it will work just to ignore the script. Sounds fine, yeah - rpm-ostree always constructs a *new* rootfs today, there's no live mutation of an existing root. Do you have a link to the (proposed?) code change though?
The change went into Fedora 31, as bug 1715891.