Add temporary hack to avoid UTF-8 for Bodhi
This commit is contained in:
parent
dfd2085303
commit
cf661a4081
35
0001-core-Don-t-use-g_format_size.patch
Normal file
35
0001-core-Don-t-use-g_format_size.patch
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
From 0c96b9281c518d242062a6f574bd1e6c7cb64111 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Jonathan Lebon <jonathan@jlebon.com>
|
||||||
|
Date: Mon, 6 May 2019 16:48:02 -0400
|
||||||
|
Subject: [PATCH] core: Don't use `g_format_size`
|
||||||
|
|
||||||
|
Pungi right now is not completely UTF-8 aware, which makes it fail when
|
||||||
|
trying to decode rpm-ostree output (the `g_format_size()` glib function
|
||||||
|
uses a no-break space between the size value and its unit).
|
||||||
|
|
||||||
|
For now, just drop that call in the only path that pungi will hit so
|
||||||
|
that our output is ASCII compliant. This is a quick hack until pungi
|
||||||
|
correctly supports UTF-8.
|
||||||
|
---
|
||||||
|
src/libpriv/rpmostree-core.c | 4 +++-
|
||||||
|
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/src/libpriv/rpmostree-core.c b/src/libpriv/rpmostree-core.c
|
||||||
|
index dc74e2d1..8390bc45 100644
|
||||||
|
--- a/src/libpriv/rpmostree-core.c
|
||||||
|
+++ b/src/libpriv/rpmostree-core.c
|
||||||
|
@@ -2209,8 +2209,10 @@ rpmostree_context_download (RpmOstreeContext *self,
|
||||||
|
{
|
||||||
|
guint64 size =
|
||||||
|
dnf_package_array_get_download_size (self->pkgs_to_download);
|
||||||
|
+ /* https://pagure.io/releng/issue/8330#comment-569246
|
||||||
|
g_autofree char *sizestr = g_format_size (size);
|
||||||
|
- rpmostree_output_message ("Will download: %u package%s (%s)", n, _NS(n), sizestr);
|
||||||
|
+ */
|
||||||
|
+ rpmostree_output_message ("Will download: %u package%s (%" G_GUINT64_FORMAT " bytes)", n, _NS(n), size);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
return TRUE;
|
||||||
|
--
|
||||||
|
2.21.0
|
||||||
|
|
@ -1,7 +1,7 @@
|
|||||||
Summary: Hybrid image/package system
|
Summary: Hybrid image/package system
|
||||||
Name: rpm-ostree
|
Name: rpm-ostree
|
||||||
Version: 2019.3.5.g0da9f997
|
Version: 2019.3.5.g0da9f997
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
#VCS: https://github.com/cgwalters/rpm-ostree
|
#VCS: https://github.com/cgwalters/rpm-ostree
|
||||||
# This tarball is generated via "cd packaging && make -f Makefile.dist-packaging dist-snapshot"
|
# This tarball is generated via "cd packaging && make -f Makefile.dist-packaging dist-snapshot"
|
||||||
# in the upstream git. If rust is enabled, it contains vendored sources.
|
# in the upstream git. If rust is enabled, it contains vendored sources.
|
||||||
@ -9,6 +9,8 @@ Source0: rpm-ostree-%{version}.tar.xz
|
|||||||
License: LGPLv2+
|
License: LGPLv2+
|
||||||
URL: https://github.com/projectatomic/rpm-ostree
|
URL: https://github.com/projectatomic/rpm-ostree
|
||||||
|
|
||||||
|
Patch0: 0001-core-Don-t-use-g_format_size.patch
|
||||||
|
|
||||||
%if !%{defined rust_arches}
|
%if !%{defined rust_arches}
|
||||||
# It's not defined yet in the base CentOS7 root
|
# It's not defined yet in the base CentOS7 root
|
||||||
%define rust_arches x86_64 i686 armv7hl aarch64 ppc64 ppc64le s390x
|
%define rust_arches x86_64 i686 armv7hl aarch64 ppc64 ppc64le s390x
|
||||||
@ -181,6 +183,10 @@ $PYTHON autofiles.py > files.devel \
|
|||||||
%files devel -f files.devel
|
%files devel -f files.devel
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon May 06 2019 Jonathan Lebon <jonathan@jlebon.com> - 2019.3.5.g0da9f997-2
|
||||||
|
- Add temporary hack to avoid UTF-8 for Bodhi
|
||||||
|
https://pagure.io/releng/issue/8330
|
||||||
|
|
||||||
* Tue Apr 09 2019 Jonathan Lebon <jonathan@jlebon.com> - 2019.3.5.g0da9f997-1
|
* Tue Apr 09 2019 Jonathan Lebon <jonathan@jlebon.com> - 2019.3.5.g0da9f997-1
|
||||||
- git master snapshot to test coreos-continuous tag
|
- git master snapshot to test coreos-continuous tag
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user