Compare commits
10 Commits
2e3563907b
...
c125171ba8
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c125171ba8 | ||
|
|
55ad7871bd | ||
|
|
70b7736661 | ||
|
|
9e79422c48 | ||
|
|
e1264a25e4 | ||
|
|
ba2a6c18a1 | ||
|
|
dbf10f5acd | ||
|
|
85e18f5593 | ||
|
|
74750cc6da | ||
|
|
6882ad82d7 |
12
msgfmt-dont-convert-the-messages-to-UTF-8-encoding.patch
Normal file
12
msgfmt-dont-convert-the-messages-to-UTF-8-encoding.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff -Nur a/tests/tests.py b/tests/tests.py
|
||||
--- a/tests/tests.py 2023-02-24 01:02:41.000000000 +0800
|
||||
+++ b/tests/tests.py 2024-06-06 11:09:59.961135920 +0800
|
||||
@@ -643,7 +643,7 @@
|
||||
os.close(fd)
|
||||
po = polib.pofile(reffile, autodetect_encoding=False, encoding=encoding)
|
||||
po.save_as_mofile(tmpfile1)
|
||||
- subprocess.call([msgfmt, '--no-hash', '-o', tmpfile2, reffile])
|
||||
+ subprocess.call([msgfmt, '--no-convert', '--no-hash', '-o', tmpfile2, reffile])
|
||||
try:
|
||||
f = open(tmpfile1, 'rb')
|
||||
s1 = f.read()
|
||||
Binary file not shown.
BIN
polib-1.2.0.tar.gz
Normal file
BIN
polib-1.2.0.tar.gz
Normal file
Binary file not shown.
@ -1,12 +1,13 @@
|
||||
Name: python-polib
|
||||
Version: 1.1.0
|
||||
Version: 1.2.0
|
||||
Release: 2
|
||||
Summary: A library to manipulate gettext files (po and mo files)
|
||||
License: MIT
|
||||
URL: https://pypi.org/project/polib/
|
||||
Source0: https://pypi.python.org/packages/source/p/polib/polib-1.1.0.tar.gz
|
||||
Source0: https://pypi.python.org/packages/source/p/polib/polib-%{version}.tar.gz
|
||||
Patch0: msgfmt-dont-convert-the-messages-to-UTF-8-encoding.patch
|
||||
|
||||
BuildRequires: python2-devel python3-devel
|
||||
BuildRequires: python3-devel gettext
|
||||
BuildArch: noarch
|
||||
|
||||
%description
|
||||
@ -14,19 +15,6 @@ polib is a library to manipulate, create, modify gettext files (pot, po and mo f
|
||||
existing files, iterate through it’s entries, add, modify entries, comments or metadata, etc… or
|
||||
create new po files from scratch.
|
||||
|
||||
polib supports out of the box any version of python ranging from 2.5 to latest 3.X version.
|
||||
|
||||
%package -n python2-polib
|
||||
Summary: A library to manipulate gettext files (po and mo files)
|
||||
%{?python_provide:%python_provide python2-polib}
|
||||
|
||||
%description -n python2-polib
|
||||
polib is a library to manipulate, create, modify gettext files (pot, po and mo files). You can load
|
||||
existing files, iterate through it’s entries, add, modify entries, comments or metadata, etc… or
|
||||
create new po files from scratch.
|
||||
|
||||
polib supports out of the box any version of python ranging from 2.5 to latest 3.X version.
|
||||
|
||||
%package -n python3-polib
|
||||
Summary: A library to manipulate gettext files (po and mo files)
|
||||
%{?python_provide:%python_provide python3-polib}
|
||||
@ -36,37 +24,40 @@ polib is a library to manipulate, create, modify gettext files (pot, po and mo f
|
||||
existing files, iterate through it’s entries, add, modify entries, comments or metadata, etc… or
|
||||
create new po files from scratch.
|
||||
|
||||
polib supports out of the box any version of python ranging from 2.5 to latest 3.X version.
|
||||
|
||||
%prep
|
||||
%autosetup -n polib-1.1.0 -p1
|
||||
%autosetup -n polib-%{version} -p1
|
||||
rm -rf polib.egg-info
|
||||
|
||||
%build
|
||||
%py2_build
|
||||
%py3_build
|
||||
|
||||
%install
|
||||
%py2_install
|
||||
%py3_install
|
||||
|
||||
%check
|
||||
%{__python2} tests/tests.py
|
||||
%{__python3} tests/tests.py
|
||||
|
||||
%files -n python2-polib
|
||||
%doc README.rst
|
||||
%license LICENSE
|
||||
%{python2_sitelib}/polib-1.1.0-py2.7.egg-info
|
||||
%{python2_sitelib}/polib.{py,pyc,pyo}
|
||||
|
||||
%files -n python3-polib
|
||||
%doc README.rst
|
||||
%license LICENSE
|
||||
%{python3_sitelib}/polib-1.1.0-py3.7.egg-info
|
||||
%{python3_sitelib}/polib.py
|
||||
%{python3_sitelib}/__pycache__/polib.cpython-37*.pyc
|
||||
%{python3_sitelib}/*
|
||||
|
||||
%changelog
|
||||
* Thu Jun 6 2024 wangqiang <wangqiang1@kylinos.con> - 1.2.0-2
|
||||
- Add build require gettext, and fix test case test_save_as_mofile
|
||||
|
||||
* Tue Aug 22 2023 wulei <wu_lei@hoperun.com> - 1.2.0-1
|
||||
- Update to 1.2.0
|
||||
|
||||
* Thu Jun 09 2022 SimpleUpdate Robot <tc@openeuler.org> - 1.1.1-1
|
||||
- Upgrade to version 1.1.1
|
||||
|
||||
* Wed Oct 21 2020 wangxiao <wangxiao65@huawei.com> - 1.1.0-4
|
||||
- drop python2 subpackage
|
||||
|
||||
* Thu Jun 18 2020 hanhui <hanhui15@huawei.com> - 1.1.0-3
|
||||
- bugfix
|
||||
- fix python3.8 can not find path
|
||||
|
||||
* Mon Jan 6 2020 lingsheng <lingsheng@huawei.com> - 1.1.0-2
|
||||
- Package init
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user